:root {
    --navy: #0c174d;
    --navy-deep: #050b27;
    --cyan: #00ffff;
    --gold: #ffcc00;
    --white: #ffffff;
    --hud-h: 62px;
    font-family: "Cairo", sans-serif;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
    height: 100%;
}

body {
    background:
        radial-gradient(circle at top, rgba(0, 255, 255, 0.12), transparent 35%),
        linear-gradient(180deg, #07103a 0%, #020617 100%);
    color: var(--white);
    overflow: hidden;
    font-family: "Cairo", sans-serif;
}

.gallery-hud {
    position: fixed;
    inset: 0 0 auto 0;
    height: var(--hud-h);
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 18px;
    background: linear-gradient(180deg, rgba(5, 11, 39, 0.92), rgba(5, 11, 39, 0.35), transparent);
    border-bottom: 1px solid rgba(0, 255, 255, 0.12);
    backdrop-filter: blur(10px);
}

.hud-home {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.hud-logo {
    height: 32px;
    filter: drop-shadow(0 0 8px rgba(0, 255, 255, 0.7));
}

.hud-center {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    line-height: 1.25;
}

.hud-title {
    display: block;
    font-size: 15px;
    font-weight: 900;
    color: var(--gold);
}

.hud-count {
    display: block;
    font-size: 12px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.65);
}

.hud-hints {
    display: flex;
    align-items: center;
    gap: 7px;
}

.hint-key {
    border: 1px solid rgba(0, 255, 255, 0.35);
    color: var(--cyan);
    background: rgba(0, 255, 255, 0.12);
    padding: 2px 9px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 900;
}

.hint-label {
    color: rgba(255, 255, 255, 0.55);
    font-size: 12px;
}

.reels-page,
.reels-container {
    height: 100dvh;
}

.reels-page {
    overflow: hidden;
}

.reels-container {
    overflow-y: auto;
    scroll-snap-type: y mandatory;
    scroll-behavior: smooth;
    scrollbar-width: none;
}

.reels-container::-webkit-scrollbar {
    display: none;
}

.reel-card {
    height: 100dvh;
    scroll-snap-align: start;
    scroll-snap-stop: always;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: calc(var(--hud-h) + 10px) 52px 22px 18px;
}

.reel-inner {
    width: min(430px, 92vw);
    height: min(760px, calc(100dvh - var(--hud-h) - 32px));
    min-height: 460px;
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    background:
        linear-gradient(rgba(0, 255, 255, 0.035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 255, 255, 0.035) 1px, transparent 1px),
        radial-gradient(circle at 50% 38%, rgba(0, 255, 255, 0.2), transparent 34%),
        linear-gradient(145deg, #122579 0%, #07103a 62%, #030817 100%);
    background-size: 28px 28px, 28px 28px, auto, auto;
    border: 1px solid rgba(0, 255, 255, 0.23);
    box-shadow:
        0 30px 70px rgba(0, 0, 0, 0.55),
        inset 0 0 0 1px rgba(255, 255, 255, 0.04),
        0 0 35px rgba(0, 255, 255, 0.12);
}

.reel-inner::after {
    content: "";
    position: absolute;
    inset: auto 0 0;
    height: 45%;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.55), transparent);
    pointer-events: none;
    z-index: 1;
}

.reel-counter,
.reel-year {
    position: absolute;
    top: 14px;
    z-index: 6;
    padding: 5px 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 900;
    backdrop-filter: blur(8px);
}

.reel-counter {
    left: 14px;
    color: rgba(255, 255, 255, 0.8);
    background: rgba(0, 0, 0, 0.42);
    border: 1px solid rgba(0, 255, 255, 0.25);
}

.reel-year {
    right: 14px;
    color: var(--gold);
    background: rgba(255, 204, 0, 0.14);
    border: 1px solid rgba(255, 204, 0, 0.35);
}

.reel-placeholder {
    position: relative;
    overflow: hidden;

    z-index: 3;
    width: 100%;
    height: 100%;
    border: 0;
    background: transparent;
    color: var(--white);
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 18px;
    padding: 32px 24px;
    text-align: center;
    font-family: "Cairo", sans-serif;
}

.reel-placeholder::before {
    content: "";
    width: 190px;
    height: 190px;
    border-radius: 50%;
    position: absolute;
    background: radial-gradient(circle, rgba(0, 255, 255, 0.22), transparent 68%);
    filter: blur(1px);
    z-index: -1;
}

.reel-play {
    width: 84px;
    height: 84px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.72);
    background: rgba(255, 255, 255, 0.12);
    display: grid;
    place-items: center;
    font-size: 34px;
    padding-right: 5px;
    box-shadow: 0 0 30px rgba(0, 255, 255, 0.22);
    transition: transform 0.25s ease, background 0.25s ease, box-shadow 0.25s ease;
}

.reel-placeholder:hover .reel-play {
    transform: scale(1.08);
    background: rgba(0, 255, 255, 0.18);
    box-shadow: 0 0 38px rgba(0, 255, 255, 0.4);
}

.reel-title {
    max-width: 310px;
    font-size: clamp(18px, 2.4vw, 23px);
    line-height: 1.45;
    font-weight: 900;
    text-shadow: 0 0 18px rgba(0, 255, 255, 0.35);
}

.reel-hint {
    font-size: 13px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.65);
    padding: 6px 16px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.reel-inner iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
    z-index: 5;
    border-radius: 28px;
    background: #000;
}

.reel-loading {
    position: absolute;
    inset: 0;
    z-index: 7;
    display: grid;
    place-items: center;
    background: rgba(5, 11, 39, 0.78);
    color: var(--cyan);
    font-weight: 900;
    font-size: 15px;
}

.progress-nav {
    position: fixed;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 90;
    display: flex;
    flex-direction: column;
    gap: 7px;
    margin-left: 10px;
}

.progress-dot {
    width: 8px;
    height: 8px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.25);
    cursor: pointer;
    padding: 0;
    transition: 0.25s ease;
}

.progress-dot.active {
    height: 26px;
    background: var(--cyan);
    box-shadow: 0 0 10px var(--cyan);
}

.scroll-hint {
    position: fixed;
    left: 50%;
    bottom: 24px;
    transform: translateX(-50%);
    z-index: 80;
    pointer-events: none;
    transition: opacity 0.35s ease;
}

.scroll-hint.hidden {
    opacity: 0;
}

.scroll-hint__inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    color: rgba(255, 255, 255, 0.58);
    font-size: 13px;
    font-weight: 700;
}

.scroll-hint__arrow {
    color: var(--cyan);
    font-size: 24px;
    animation: bounceDown 1.4s infinite ease-in-out;
}

@keyframes bounceDown {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(7px);
    }
}

@media (max-width: 700px) {
    .gallery-hud {
        padding: 0 12px;
    }

    .hint-label {
        display: none;
    }

    .reel-card {
        height: 100dvh;
        padding: calc(var(--hud-h) + 8px) 10px 14px 10px;
        align-items: center;
        justify-content: center;
    }

    .reel-inner {
        width: min(390px, 94vw);
        border-radius: 22px;
        aspect-ratio: 9 / 16;
        height: auto !important;
        max-height: calc(100dvh - var(--hud-h) - 24px);
        min-height: unset !important;
        position: relative;
        overflow: hidden;
    }

    .reel-placeholder {
        height: 100%;
        min-height: unset;
    }

    .reel-inner iframe {
        border-radius: 22px;
        width: 100% !important;
        height: 100% !important;
    }

    .progress-nav {
        right: 9px;
        gap: 5px;
    }

    .progress-dot {
        width: 6px;
        height: 6px;
    }

    .progress-dot.active {
        height: 20px;
    }

    .reel-play {
        width: 74px;
        height: 74px;
        font-size: 30px;
    }

    .reel-title {
        font-size: 18px;
    }
}

.reel-thumb {
    position: absolute;
    inset: 0;
    z-index: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    filter: brightness(0.75);
    transform: scale(1.02);
}

.reel-placeholder {
    position: relative;
    z-index: 2;
}

.reel-inner::after {
    z-index: 1;
}