/* ================================================
   HERO SECTION — Nintendo Switch Style
   ================================================ */

.hero-section {
    position: relative;
    width: 100%;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    /* CLIP cards at the bottom edge — no bleed into next section */
    overflow: hidden;
    padding-top: 100px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-color: #0a0a0a;
}

.hero-bg-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom,
            rgba(10, 10, 10, 0.65) 0%,
            rgba(10, 10, 10, 0.85) 50%,
            rgba(10, 10, 10, 0.98) 100%);
    backdrop-filter: blur(8px);
    z-index: 0;
    pointer-events: none;
}

.hero-bg-grid {
    position: absolute;
    inset: -50%;
    width: 200%;
    height: 200%;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    transform: perspective(500px) rotateX(60deg) translateY(-100px) translateZ(-200px);
    animation: gridMove 20s linear infinite;
    pointer-events: none;
    z-index: 1;
}

@keyframes gridMove {
    0% {
        transform: perspective(500px) rotateX(60deg) translateY(0) translateZ(-200px);
    }

    100% {
        transform: perspective(500px) rotateX(60deg) translateY(60px) translateZ(-200px);
    }
}

/* ================================================
   TYPOGRAPHY
   ================================================ */
.hero-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.hero-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.6rem;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #fbbf24;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.hero-title {
    font-size: 4rem;
    line-height: 1.05;
    font-weight: 800;
    color: white;
    letter-spacing: -1px;
}

.highlight-text {
    color: white;
}

.hero-subtitle {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.5);
    max-width: 480px;
    line-height: 1.6;
    margin-bottom: 0.5rem;
}

.hero-cta-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 16px 44px;
    font-size: 1.05rem;
    font-weight: 700;
    color: #fff;
    background: rgba(255, 255, 255, 0.06);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(251, 191, 36, 0.35);
    border-radius: 50px;
    cursor: pointer;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    box-shadow:
        0 0 15px rgba(251, 191, 36, 0.25),
        0 0 30px rgba(251, 191, 36, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    overflow: hidden;
    z-index: 1;
}

.hero-cta-btn::before {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: 52px;
    background: linear-gradient(135deg, #fbbf24, #f59e0b, #fbbf24, #ef4444, #fbbf24);
    background-size: 300% 300%;
    animation: neonBorderShift 4s ease infinite;
    z-index: -2;
    opacity: 0.6;
}

.hero-cta-btn::after {
    content: '';
    position: absolute;
    inset: 1px;
    border-radius: 50px;
    background: rgba(10, 10, 10, 0.75);
    backdrop-filter: blur(16px);
    z-index: -1;
}

.hero-cta-btn:hover {
    transform: translateY(-3px) scale(1.03);
    border-color: rgba(251, 191, 36, 0.6);
    box-shadow:
        0 0 25px rgba(251, 191, 36, 0.5),
        0 0 50px rgba(251, 191, 36, 0.2),
        0 0 80px rgba(251, 191, 36, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
    color: #fbbf24;
}

@keyframes neonBorderShift {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

/* ================================================
   3D NINTENDO FAN CAROUSEL — BIG CARDS
   Cards are clipped at the hero bottom edge.
   This gives the "rising from below" effect naturally.
   ================================================ */

.fan-carousel {
    position: relative;
    width: 100%;
    height: 600px;
    margin-top: 1rem;
    /* Allow cards to extend within this container */
    overflow: visible;
}

.fan-track {
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: flex-end;
}

/* ── BIG CARDS ── */
.fan-card {
    position: absolute;
    /* Cards sit at the bottom of the track, hero-section clips them */
    bottom: -40px;
    left: 50%;
    width: 380px;
    height: 540px;
    margin-left: -190px;
    background: #1a1a1a;
    border-radius: 22px;
    overflow: hidden;
    cursor: pointer;
    user-select: none;
    border: 2px solid rgba(255, 255, 255, 0.06);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.7);
    will-change: transform, opacity;
    opacity: 0;
    transform-origin: center bottom;
    transition: box-shadow 0.4s ease, border-color 0.4s ease;
}

.fan-card.active {
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow:
        0 25px 60px rgba(0, 0, 0, 0.9),
        0 0 40px rgba(255, 255, 255, 0.04);
}

.card-image-full {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.6s ease;
}

.fan-card.active:hover .card-image-full {
    transform: scale(1.06);
}

.card-overlay-gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top,
            rgba(0, 0, 0, 0.9) 0%,
            rgba(0, 0, 0, 0.3) 50%,
            transparent 100%);
    pointer-events: none;
    z-index: 1;
}

.card-content {
    position: absolute;
    bottom: 28px;
    left: 0;
    width: 100%;
    padding: 1.4rem 1.2rem;
    z-index: 2;
}

.game-title {
    font-size: 1.6rem;
    font-weight: 800;
    color: white;
    margin: 0;
    line-height: 1;
    text-transform: uppercase;
}

.game-subtitle {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.6);
    margin-top: 4px;
    display: block;
}

.card-rating-badge {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 10;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(8px);
    padding: 5px 12px;
    border-radius: 20px;
    font-weight: 700;
    font-size: 0.85rem;
    color: #fbbf24;
    display: flex;
    align-items: center;
    gap: 4px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* ── Navigation Dots ── */
.carousel-dots {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 20;
}

.dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    cursor: pointer;
    transition: all 0.3s;
}

.dot.active {
    background: #fff;
    transform: scale(1.4);
    box-shadow: 0 0 8px rgba(255, 255, 255, 0.5);
}

/* ================================================
   RESPONSIVE
   ================================================ */

/* ── Tall screens (large desktops) ── */
@media (min-height: 900px) {
    .fan-card {
        width: 420px;
        height: 600px;
        margin-left: -210px;
    }

    .fan-carousel {
        height: 660px;
    }
}

/* ── Tablets & small laptops ── */
@media (max-width: 1024px) {
    .hero-title {
        font-size: 3.2rem;
    }

    .fan-card {
        width: 320px;
        height: 450px;
        margin-left: -160px;
    }

    .fan-carousel {
        height: 500px;
    }
}

/* ── Tablets portrait ── */
@media (max-width: 768px) {
    .hero-section {
        padding-top: 80px;
        min-height: auto;
    }

    .hero-title {
        font-size: 2.5rem;
        letter-spacing: -0.5px;
    }

    .hero-subtitle {
        font-size: 0.85rem;
        max-width: 380px;
        padding: 0 1rem;
    }

    .hero-container {
        gap: 0.3rem;
    }

    .fan-carousel {
        height: 380px;
        margin-top: 0.5rem;
    }

    .fan-card {
        width: 260px;
        height: 370px;
        margin-left: -130px;
        bottom: -20px;
        border-radius: 18px;
    }

    .card-content {
        bottom: 18px;
        padding: 1.2rem 1rem;
    }

    .game-title {
        font-size: 1.3rem;
    }

    .game-subtitle {
        font-size: 0.8rem;
    }

    .card-rating-badge {
        top: 10px;
        right: 10px;
        padding: 4px 10px;
        font-size: 0.75rem;
    }
}

/* ── Phones ── */
@media (max-width: 480px) {
    .hero-section {
        padding-top: 65px;
        min-height: auto;
    }

    .hero-title {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 0.78rem;
        max-width: 300px;
    }

    .hero-badge {
        font-size: 0.72rem;
    }

    .fan-carousel {
        height: 300px;
    }

    .fan-card {
        width: 220px;
        height: 310px;
        margin-left: -110px;
        bottom: -10px;
        border-radius: 16px;
    }

    .card-content {
        bottom: 12px;
        padding: 1rem 0.8rem;
    }

    .game-title {
        font-size: 1.1rem;
    }

    .game-subtitle {
        font-size: 0.7rem;
    }

    .card-rating-badge {
        top: 8px;
        right: 8px;
        padding: 3px 8px;
        font-size: 0.7rem;
    }

    .card-overlay-gradient {
        background: linear-gradient(to top,
                rgba(0, 0, 0, 0.95) 0%,
                rgba(0, 0, 0, 0.35) 50%,
                transparent 100%);
    }
}

/* ── Very small phones (360px and below) ── */
@media (max-width: 360px) {
    .hero-section {
        padding-top: 55px;
    }

    .hero-title {
        font-size: 1.7rem;
    }

    .hero-subtitle {
        font-size: 0.72rem;
        max-width: 260px;
    }

    .hero-badge {
        font-size: 0.65rem;
    }

    .fan-carousel {
        height: 260px;
    }

    .fan-card {
        width: 180px;
        height: 260px;
        margin-left: -90px;
        bottom: -5px;
        border-radius: 14px;
    }

    .card-content {
        bottom: 8px;
        padding: 0.8rem 0.6rem;
    }

    .game-title {
        font-size: 0.95rem;
    }

    .game-subtitle {
        font-size: 0.65rem;
    }
}

/* ── Landscape phones ── */
@media (max-height: 500px) and (orientation: landscape) {
    .hero-section {
        padding-top: 50px;
        min-height: auto;
    }

    .hero-title {
        font-size: 1.8rem;
    }

    .hero-subtitle {
        display: none;
    }

    .hero-header {
        gap: 0.3rem;
    }

    .fan-carousel {
        height: 280px;
        margin-top: 0;
    }

    .fan-card {
        width: 180px;
        height: 250px;
        margin-left: -90px;
        bottom: 0;
    }

    .card-content {
        bottom: 6px;
        padding: 0.6rem 0.5rem;
    }

    .game-title {
        font-size: 0.9rem;
    }

    .game-subtitle {
        font-size: 0.6rem;
    }
}