/* :root {
    --animeZctrl: 0;
} */

.anime {
    height: 300vh;
    width: 100%;
    /* overflow: auto; */
    position: relative;
}

.gradientShading {
    background: linear-gradient(180deg, #18171d 0%, #18171d00 100%);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 40vh;
}

.animeContent {
    
    /* color: #fff; */
}


#animeContainer {
    width: 100%;
    height: 100%;
    position: relative;
}

.animeViewport {
    width: 100%;
    height: 100vh;
    perspective: 2000px;
    overflow: hidden;
    position: relative;
}

.animeScene {
    position: absolute;
    top: 50%;
    left: 50%;
    transform-style: preserve-3d;
    transform: translateZ(calc(var(--animeZctrl) * 1px));
    transition: transform 0.8s cubic-bezier(0.17, 0.67, 0.83, 0.67);
}

.animeCard {
    position: absolute;
    width: 220px;
    height: 320px;
    background: linear-gradient(135deg, #0c2461, #1e3799);
    border-radius: 12px;
    box-shadow: 0 15px 25px rgba(0, 0, 0, 0.4);
    transform-style: preserve-3d;
    overflow: hidden;
    backface-visibility: visible;
    border: 2px solid rgba(255, 255, 255, 0.15);
    margin-left: -110px;
    margin-top: -160px;
}

.animeCardImage {
    width: 100%;
    height: 130px;
    object-fit: cover;
    border-bottom: 2px solid rgba(255, 255, 255, 0.1);
}

.animeCardContent {
    padding: 15px;
    height: 190px;
    display: flex;
    flex-direction: column;
}

.animeCardTitle {
    font-size: 16px;
    font-weight: bold;
    margin-bottom: 8px;
    color: white;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.animeCardDescription {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.4;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 5;
    -webkit-box-orient: vertical;
    mask-image: linear-gradient(180deg,black 0,transparent);
    -webkit-mask-image: linear-gradient(180deg,black 0,transparent);
    flex-grow: 1;
}

.animeCardLoading {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
}

.animeControls {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.85);
    padding: 20px;
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    display: flex;
    flex-direction: column;
    gap: 15px;
    z-index: 100;
}

.animeControlGroup {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.animeAxisControl {
    flex: 1;
    margin: 0 15px;
}

.animeAxisControl label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    color: #aaa;
}

.animeSliderContainer {
    display: flex;
    align-items: center;
}

input[type="range"] {
    flex: 1;
    height: 6px;
    -webkit-appearance: none;
    background: linear-gradient(to right, #5184f1, #3a6bd3);
    border-radius: 5px;
    outline: none;
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #fff;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(81, 132, 241, 0.8);
}

.animeValueDisplay {
    width: 60px;
    text-align: right;
    margin-left: 10px;
    font-size: 14px;
    color: #5184f1;
    font-weight: bold;
}

.animeButton {
    padding: 8px 16px;
    background: #5184f1;
    border: none;
    border-radius: 4px;
    color: white;
    cursor: pointer;
    font-weight: bold;
    transition: background 0.2s, transform 0.2s;
}

.animeButton:hover {
    background: #3a6bd3;
    transform: translateY(-2px);
}

.animeTitle {
    text-align: center;
    margin-bottom: 10px;
    color: #5184f1;
    font-size: 18px;
    text-shadow: 0 0 10px rgba(81, 132, 241, 0.5);
}

.animeInstructions {
    text-align: center;
    font-size: 12px;
    color: #aaa;
    margin-top: 10px;
}

.animeInfoPanel {
    position: fixed;
    top: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.7);
    padding: 15px;
    border-radius: 8px;
    font-size: 14px;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.animeInfoPanel p {
    margin: 5px 0;
    color: #ccc;
}

.animeInfoPanel span {
    color: #5184f1;
    font-weight: bold;
}

.animeLoadingOverlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    flex-direction: column;
}

.animeLoadingSpinner {
    width: 50px;
    height: 50px;
    border: 5px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #5184f1;
    animation: animeSpin 1s ease-in-out infinite;
}

@keyframes animeSpin {
    to {
        transform: rotate(360deg);
    }
}

.animeLoadingText {
    margin-top: 20px;
    font-size: 16px;
    color: white;
}