/* ================================================
   XBOX GAME PASS — Premium Subscription Section
   ================================================ */
.xbox-section {
    position: relative;
    padding: 6rem 0;
    overflow: hidden;
}

/* ── Background image layer ── */
.xbox-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: 0;
    filter: blur(4px) brightness(0.25);
    transform: scale(1.05);
    animation: xboxBgPulse 8s ease-in-out infinite alternate;
}

.xbox-bg-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg,
            rgba(10, 10, 10, 0.85) 0%,
            rgba(10, 10, 10, 0.65) 40%,
            rgba(10, 10, 10, 0.80) 100%);
    z-index: 1;
    pointer-events: none;
}

/* ── Neon Overlay & Animations ── */
.xbox-neon-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background:
        radial-gradient(circle at 20% 30%, rgba(57, 255, 20, 0.12) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(6, 182, 212, 0.08) 0%, transparent 50%);
    animation: xboxNeonPulse 6s ease-in-out infinite alternate;
    mix-blend-mode: screen;
}

@keyframes xboxBgPulse {
    0% {
        transform: scale(1.05);
        filter: blur(4px) brightness(0.25);
    }

    100% {
        transform: scale(1.08);
        filter: blur(5px) brightness(0.32);
    }
}

@keyframes xboxNeonPulse {
    0% {
        opacity: 0.5;
    }

    100% {
        opacity: 1;
    }
}

/* ── Container ── */
.xbox-container {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3rem;
}

/* ================================================
   HEADER
   ================================================ */
.xbox-header {
    text-align: center;
    max-width: 600px;
}

.xbox-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #107C10;
    border: 1px solid rgba(16, 124, 16, 0.4);
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 1.5px;
    margin-bottom: 1.2rem;
    background: rgba(16, 124, 16, 0.08);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.xbox-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 900;
    line-height: 1.1;
    color: #fff;
    margin-bottom: 1rem;
}

.xbox-highlight {
    color: #107C10;
    text-shadow: 0 0 30px rgba(16, 124, 16, 0.5);
}

.xbox-desc {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.95rem;
    line-height: 1.7;
    max-width: 480px;
    margin: 0 auto;
}

/* ================================================
   PRIVATE / SHARED TOGGLE
   ================================================ */
.xbox-toggle-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.8rem;
}

.xbox-toggle {
    position: relative;
    display: flex;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 50px;
    padding: 4px;
    overflow: hidden;
}

.xbox-toggle-btn {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 28px;
    border: none;
    border-radius: 50px;
    background: transparent;
    color: rgba(255, 255, 255, 0.45);
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    transition: color 0.3s ease;
    white-space: nowrap;
}

.xbox-toggle-btn--active {
    color: #fff;
}

.xbox-toggle-slider {
    position: absolute;
    top: 4px;
    left: 4px;
    width: calc(50% - 4px);
    height: calc(100% - 8px);
    border-radius: 50px;
    background: linear-gradient(135deg, #107C10 0%, #0e9e0e 100%);
    box-shadow: 0 4px 15px rgba(16, 124, 16, 0.3);
    transition: transform 0.35s cubic-bezier(0.25, 0.8, 0.25, 1);
    z-index: 1;
}

.xbox-toggle-hint {
    color: rgba(255, 255, 255, 0.3);
    font-size: 0.78rem;
    margin: 0;
    text-align: center;
    transition: opacity 0.3s ease;
}

/* ================================================
   CARD SELECTION INDICATOR
   ================================================ */
.xbox-plan-check-ring {
    position: absolute;
    top: 16px;
    left: 16px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 5;
    transition: all 0.3s ease;
    color: #fff;
    background: transparent;
}

.xbox-plan-card--popular .xbox-plan-check-ring {
    top: 42px;
}

.xbox-plan-card--selected .xbox-plan-check-ring {
    border-color: #107C10;
    background: #107C10;
    box-shadow: 0 0 12px rgba(16, 124, 16, 0.4);
}

/* ================================================
   SUBSCRIPTION PLAN CARDS
   ================================================ */
.xbox-plans-viewport {
    width: 100%;
    max-width: 960px;
    overflow: visible;
    cursor: grab;
    -webkit-user-select: none;
    user-select: none;
}

.xbox-plans-viewport:active {
    cursor: grabbing;
}

.xbox-plans-track {
    display: flex;
    gap: 1.5rem;
    transition: transform 0.5s cubic-bezier(0.25, 0.8, 0.25, 1);
    /* On desktop, show all 3 cards without transform */
    transform: none !important;
    justify-content: center;
    padding: 1rem 0;
}

/* ── Individual Card ── */
.xbox-plan-card {
    position: relative;
    flex: 0 0 calc(33.333% - 1rem);
    max-width: 300px;
    min-width: 260px;
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 24px;
    padding: 2rem 1.8rem;
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    overflow: hidden;
}

.xbox-plan-card:hover {
    transform: translateY(-6px);
    border-color: rgba(16, 124, 16, 0.25);
    box-shadow:
        0 20px 60px rgba(0, 0, 0, 0.4),
        0 0 0 1px rgba(16, 124, 16, 0.1);
}

.xbox-plan-card--selected {
    border-color: rgba(16, 124, 16, 0.35);
    background: rgba(16, 124, 16, 0.06);
    transform: translateY(-8px);
    box-shadow:
        0 25px 70px rgba(0, 0, 0, 0.5),
        0 0 40px rgba(16, 124, 16, 0.08),
        inset 0 1px 0 rgba(16, 124, 16, 0.15);
}

/* ── Ambient light beams ── */
.xbox-card-light {
    position: absolute;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
    opacity: 0;
    filter: blur(40px);
    transition: opacity 0.5s ease;
}

.xbox-card-light--1 {
    background: radial-gradient(circle, rgba(16, 124, 16, 0.25) 0%, transparent 70%);
    animation: xboxLightOrbit1 8s ease-in-out infinite;
}

.xbox-card-light--2 {
    background: radial-gradient(circle, rgba(14, 158, 14, 0.2) 0%, transparent 70%);
    animation: xboxLightOrbit2 10s ease-in-out infinite;
}

.xbox-plan-card:hover .xbox-card-light,
.xbox-plan-card--selected .xbox-card-light {
    opacity: 1;
}

@keyframes xboxLightOrbit1 {
    0% {
        top: -30px;
        left: -30px;
    }

    25% {
        top: -30px;
        left: calc(100% - 60px);
    }

    50% {
        top: calc(100% - 90px);
        left: calc(100% - 60px);
    }

    75% {
        top: calc(100% - 90px);
        left: -30px;
    }

    100% {
        top: -30px;
        left: -30px;
    }
}

@keyframes xboxLightOrbit2 {
    0% {
        top: calc(100% - 80px);
        right: -20px;
        left: auto;
    }

    25% {
        top: -20px;
        right: -20px;
        left: auto;
    }

    50% {
        top: -20px;
        right: calc(100% - 80px);
        left: auto;
    }

    75% {
        top: calc(100% - 80px);
        right: calc(100% - 80px);
        left: auto;
    }

    100% {
        top: calc(100% - 80px);
        right: -20px;
        left: auto;
    }
}

/* ── Popular badge ── */
.xbox-plan-card--popular {
    border-color: rgba(16, 124, 16, 0.4);
}

.xbox-plan-popular {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    padding: 6px 0;
    text-align: center;
    background: linear-gradient(135deg, #107C10 0%, #0e9e0e 100%);
    color: #fff;
    font-size: 0.65rem;
    font-weight: 800;
    letter-spacing: 2px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    border-radius: 24px 24px 0 0;
}

.xbox-plan-save {
    position: absolute;
    top: 16px;
    right: 16px;
    background: rgba(16, 124, 16, 0.15);
    color: #0bdd0b;
    font-size: 0.65rem;
    font-weight: 800;
    padding: 4px 10px;
    border-radius: 20px;
    border: 1px solid rgba(16, 124, 16, 0.3);
    letter-spacing: 0.5px;
}

.xbox-plan-card--popular .xbox-plan-save {
    top: 42px;
}

/* ── Plan Header ── */
.xbox-plan-header {
    text-align: center;
    padding-top: 0.5rem;
}

.xbox-plan-card--popular .xbox-plan-header {
    padding-top: 1.2rem;
}

.xbox-plan-icon {
    width: 52px;
    height: 52px;
    border-radius: 16px;
    background: rgba(16, 124, 16, 0.08);
    border: 1px solid rgba(16, 124, 16, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.xbox-plan-card:hover .xbox-plan-icon,
.xbox-plan-card--selected .xbox-plan-icon {
    transform: scale(1.1);
    box-shadow: 0 0 20px rgba(16, 124, 16, 0.15);
}

.xbox-plan-duration {
    font-size: 1.1rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.8);
    margin: 0 0 0.8rem;
    letter-spacing: 0.5px;
}

.xbox-plan-price {
    font-size: 2.4rem;
    font-weight: 900;
    color: #fff;
    line-height: 1;
    margin-bottom: 0.3rem;
}

.xbox-plan-permonth {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.4);
    font-weight: 500;
}

/* ── Divider ── */
.xbox-plan-divider {
    height: 1px;
    background: linear-gradient(90deg,
            transparent 0%,
            rgba(16, 124, 16, 0.2) 50%,
            transparent 100%);
    margin: 0.3rem 0;
}

/* ── Features List ── */
.xbox-plan-features {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.xbox-plan-features li {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.82rem;
    color: rgba(255, 255, 255, 0.6);
    font-weight: 500;
}

.xbox-check-icon {
    color: #107C10;
    flex-shrink: 0;
}

/* ── Card glow ── */
.xbox-plan-glow {
    position: absolute;
    bottom: -60%;
    left: -20%;
    width: 140%;
    height: 80%;
    pointer-events: none;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.xbox-plan-card:hover .xbox-plan-glow,
.xbox-plan-card--selected .xbox-plan-glow {
    opacity: 1;
}

/* ── Dot navigation ── */
.xbox-dots {
    display: none;
    justify-content: center;
    gap: 10px;
    margin-top: 1.5rem;
}

.xbox-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.2);
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
}

.xbox-dot--active {
    background: #107C10;
    transform: scale(1.5);
    box-shadow: 0 0 10px rgba(16, 124, 16, 0.5);
}

/* ================================================
   CTA — Below cards
   ================================================ */
.xbox-cta {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.8rem;
}

.xbox-btn {
    background: linear-gradient(135deg, #107C10 0%, #0e9e0e 100%);
    color: #fff;
    padding: 1rem 3rem;
    border-radius: 50px;
    border: none;
    font-weight: 800;
    font-size: 1.1rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow:
        0 6px 30px rgba(16, 124, 16, 0.3),
        0 0 0 1px rgba(16, 124, 16, 0.2);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    position: relative;
    overflow: hidden;
}

.xbox-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.15) 0%, transparent 50%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.xbox-btn:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow:
        0 12px 40px rgba(16, 124, 16, 0.45),
        0 0 60px rgba(16, 124, 16, 0.15);
}

.xbox-btn:hover::before {
    opacity: 1;
}

.xbox-btn:active {
    transform: translateY(-1px) scale(0.98);
}

.xbox-cta-sub {
    color: rgba(255, 255, 255, 0.35);
    font-size: 0.8rem;
    margin: 0;
}

/* ================================================
   RESPONSIVE — Mobile swipe mode
   ================================================ */
@media (max-width: 820px) {
    .xbox-section {
        padding: 4rem 0;
    }

    .xbox-container {
        gap: 2rem;
    }

    .xbox-plans-viewport {
        overflow: visible;
        padding: 0 1rem;
    }

    .xbox-plans-track {
        /* Enable horizontal scroll-snap on mobile */
        transform: none !important;
        justify-content: flex-start;
        gap: 1rem;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        padding: 1rem 0;
    }

    .xbox-plans-track::-webkit-scrollbar {
        display: none;
    }

    .xbox-plan-card {
        flex: 0 0 85%;
        max-width: 85%;
        min-width: auto;
        scroll-snap-align: center;
    }

    .xbox-dots {
        display: flex;
    }
}

@media (max-width: 480px) {
    .xbox-section {
        padding: 3rem 0;
    }

    .xbox-container {
        gap: 1.5rem;
    }

    .xbox-desc {
        font-size: 0.85rem;
        padding: 0 0.5rem;
    }

    .xbox-plan-card {
        flex: 0 0 88%;
        max-width: 88%;
        padding: 1.5rem 1.3rem;
        border-radius: 20px;
    }

    .xbox-plan-price {
        font-size: 2rem;
    }

    .xbox-btn {
        padding: 0.85rem 2.4rem;
        font-size: 1rem;
    }
}

@media (max-width: 360px) {
    .xbox-plan-card {
        flex: 0 0 92%;
        max-width: 92%;
        padding: 1.3rem 1rem;
    }

    .xbox-plan-price {
        font-size: 1.8rem;
    }

    .xbox-plan-features li {
        font-size: 0.75rem;
    }
}
