/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Colors */
    --bg-body: #242828;
    --bg-content: #262A2B;
    --bg-topbar: #2B3432;
    --bg-sidebar: #3A3D3D;
    --surface-0: #232626;
    --surface-1: #282B2B;
    --surface-2: #2C3030;
    --surface-3: #323738;
    --surface-nav-mobile: #3C4548;
    --pill-fill: #373C3C;
    --divider-subtle: rgba(255, 255, 255, 0.06);
    --stroke-subtle: rgba(255, 255, 255, 0.08);
    --stroke-outline: #616768;
    --shadow-color: rgba(0, 0, 0, 0.35);
    
    --text-primary: #FFFFFF;
    --text-secondary: #B0B8C0;
    --text-muted: #808890;
    --text-disabled: rgba(255, 255, 255, 0.38);
    --text-inverse-on-mint: #0B1511;
    
    --accent-mint: #24EE89;
    --accent-mint-hover: #25DF82;
    --accent-mint-pressed: #24EB88;
    --focus-ring-mint: rgba(36, 238, 137, 0.35);
    --status-dot-green: #28C422;
    --icon-light: #B3BEC1;
    
    --overlay-hover: rgba(255, 255, 255, 0.04);
    --overlay-pressed: rgba(0, 0, 0, 0.18);
    --scrim: rgba(0, 0, 0, 0.40);
    
    /* Typography */
    --font-ui: system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
    
    /* Spacing */
    --base-unit: 8px;
    
    /* Radii */
    --radius-xs: 8px;
    --radius-sm: 12px;
    --radius-md: 16px;
    --radius-lg: 20px;
    --radius-xl: 24px;
    --radius-pill: 999px;
    
    /* Shadows */
    --shadow-card: 0 12px 24px rgba(0, 0, 0, 0.35);
    --shadow-card-hover: 0 16px 30px rgba(0, 0, 0, 0.42);
    --shadow-floating-action: 0 10px 22px rgba(0, 0, 0, 0.40);
    --shadow-inset-hairline: inset 0 1px 0 rgba(255, 255, 255, 0.03);
    
    /* Motion */
    --duration-fast: 120ms;
    --duration-base: 160ms;
    --duration-slow: 220ms;
    --easing-standard: cubic-bezier(0.2, 0.8, 0.2, 1);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-ui);
    background-color: var(--bg-body);
    color: var(--text-primary);
    line-height: 1.6;
    font-size: 14px;
    line-height: 20px;
    font-weight: 500;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 16px;
}

/* Typography */
h1 {
    font-size: 32px;
    line-height: 40px;
    font-weight: 800;
    letter-spacing: -0.2px;
    margin-bottom: 16px;
}

h2 {
    font-size: 24px;
    line-height: 32px;
    font-weight: 800;
    letter-spacing: -0.1px;
    margin-bottom: 16px;
}

h3 {
    font-size: 18px;
    line-height: 24px;
    font-weight: 700;
    margin-bottom: 12px;
}

h4 {
    font-size: 16px;
    line-height: 22px;
    font-weight: 700;
    margin-bottom: 8px;
}

p {
    margin-bottom: 16px;
    color: var(--text-secondary);
}

a {
    color: var(--accent-mint);
    text-decoration: none;
    transition: color var(--duration-base) var(--easing-standard);
}

a:hover {
    color: var(--accent-mint-hover);
}

a:focus {
    outline: 2px solid var(--focus-ring-mint);
    outline-offset: 2px;
}

ul, ol {
    margin-bottom: 16px;
    padding-left: 24px;
}

li {
    margin-bottom: 8px;
    color: var(--text-secondary);
}

/* Header */
.header {
    background-color: var(--bg-topbar);
    border-bottom: 1px solid var(--divider-subtle);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header__top {
    padding: 12px 0;
    border-bottom: 1px solid var(--divider-subtle);
}

.header__top-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header__logo img {
    height: 40px;
    width: auto;
}

.header__cta-buttons {
    display: flex;
    gap: 12px;
}

.header__bottom {
    padding: 12px 0;
}

.header__nav {
    display: flex;
    justify-content: center;
}

.nav-list {
    display: flex;
    list-style: none;
    gap: 24px;
    padding: 0;
    margin: 0;
}

.nav-list a {
    color: var(--text-primary);
    font-weight: 600;
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    transition: background-color var(--duration-base) var(--easing-standard);
}

.nav-list a:hover {
    background-color: var(--overlay-hover);
    color: var(--text-primary);
}

.header__burger {
    display: none;
    flex-direction: column;
    gap: 4px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 8px;
    position: static;
    margin-left: auto;
}

.header__burger span {
    width: 24px;
    height: 2px;
    background-color: var(--text-primary);
    transition: all var(--duration-base) var(--easing-standard);
}

/* ToC */
.header__toc {
    background-color: var(--bg-content);
    border-top: 1px solid var(--divider-subtle);
    padding: 8px 0;
}

.header__toc .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 16px;
}

.toc-nav {
    max-width: 1100px;
    margin: 0 auto;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.toc-nav::-webkit-scrollbar {
    display: none;
}

.toc-list {
    display: flex;
    list-style: none;
    gap: 16px;
    padding: 0;
    margin: 0;
    white-space: nowrap;
    justify-content: flex-start;
    min-width: fit-content;
}

.toc-list li {
    margin: 0;
}

.toc-list a {
    display: inline-block;
    padding: 6px 12px;
    color: var(--text-secondary);
    font-size: 12px;
    border-radius: var(--radius-pill);
    background-color: var(--pill-fill);
    transition: all var(--duration-base) var(--easing-standard);
    white-space: nowrap;
}

.toc-list a:hover,
.toc-list a.active {
    background-color: var(--surface-3);
    color: var(--accent-mint);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 14px;
    line-height: 20px;
    text-align: center;
    cursor: pointer;
    border: none;
    transition: all var(--duration-base) var(--easing-standard);
    min-width: 60px;
    font-family: var(--font-ui);
}

.btn__icon {
    display: none;
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.btn__text {
    display: inline;
}

.btn--primary {
    background-color: var(--accent-mint);
    color: var(--text-inverse-on-mint);
}

.btn--primary:hover {
    background-color: var(--accent-mint-hover);
    transform: translateY(-2px);
}

.btn--primary:active {
    background-color: var(--accent-mint-pressed);
    transform: translateY(1px) scale(0.99);
}

.btn--primary:focus {
    outline: 2px solid var(--focus-ring-mint);
    outline-offset: 2px;
}

.btn--outline {
    background-color: transparent;
    border: 1px solid var(--stroke-outline);
    color: var(--text-primary);
}

.btn--outline:hover {
    background-color: var(--overlay-hover);
    border-color: rgba(255, 255, 255, 0.18);
}

.btn--outline:active {
    background-color: var(--overlay-pressed);
}

.btn--outline:focus {
    outline: 2px solid var(--focus-ring-mint);
    outline-offset: 2px;
}

/* Hero Section */
.hero {
    padding: 48px 0;
    background-color: var(--bg-content);
}

.hero__content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
    align-items: start;
}

.hero__text {
    display: flex;
    flex-direction: column;
}

.hero__lead {
    font-size: 16px;
    line-height: 24px;
    color: var(--text-secondary);
    margin-bottom: 16px;
}

.hero__meta {
    margin-top: 16px;
}

.reading-time {
    color: var(--text-muted);
    font-size: 12px;
}

.reading-time__label {
    margin-right: 4px;
}

.reading-time__value {
    color: var(--accent-mint);
    font-weight: 600;
}

.hero__image {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
}

.hero__image figure {
    width: 100%;
    max-width: 500px;
}

.hero__image img {
    width: 100%;
    height: auto;
    border-radius: var(--radius-lg);
    object-fit: contain;
}

.hero__fact-check {
    text-align: center;
    margin-top: 24px;
    color: var(--text-muted);
    font-size: 12px;
}

/* Games Section */
.games {
    padding: 48px 0;
    background-color: var(--bg-body);
}

.section-title {
    text-align: center;
    margin-bottom: 32px;
}

.games-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 16px;
}

.game-card {
    position: relative;
    aspect-ratio: 16 / 9;
    border-radius: var(--radius-md);
    overflow: hidden;
    background-color: var(--surface-0);
    cursor: pointer;
    transition: transform var(--duration-base) var(--easing-standard), box-shadow var(--duration-base) var(--easing-standard);
}

.game-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-card-hover);
}

.game-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.game-card__overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity var(--duration-base) var(--easing-standard);
}

.game-card:hover .game-card__overlay {
    opacity: 1;
}

/* Content Sections */
.content-section {
    padding: 48px 0;
    background-color: var(--bg-content);
}

.content-section:nth-child(even) {
    background-color: var(--bg-body);
}

.content-section h2 {
    margin-bottom: 24px;
}

.section-image {
    margin: 24px 0;
    text-align: center;
}

.section-image img {
    max-width: 600px;
    width: 100%;
    height: auto;
    border-radius: var(--radius-lg);
    object-fit: contain;
}

.content {
    max-width: 800px;
    margin: 0 auto;
}

.content h3 {
    margin-top: 24px;
    margin-bottom: 12px;
}

/* Tables */
.table-wrapper {
    overflow-x: auto;
    margin: 24px 0;
}

table {
    width: 100%;
    border-collapse: collapse;
    background-color: var(--surface-0);
    border-radius: var(--radius-md);
    overflow: hidden;
}

thead {
    background-color: var(--surface-2);
}

th {
    padding: 12px;
    text-align: left;
    font-weight: 700;
    color: var(--text-primary);
    font-size: 14px;
}

td {
    padding: 12px;
    color: var(--text-secondary);
    font-size: 14px;
    border-top: 1px solid var(--divider-subtle);
}

tbody tr:hover {
    background-color: var(--overlay-hover);
}

/* Bonuses Section */
.bonuses-section {
    background-color: var(--bg-content);
}

.bonus-slider {
    position: relative;
    margin: 32px 0;
    padding: 0 40px;
}

.bonus-cards {
    display: flex;
    gap: 16px;
    list-style: none;
    padding: 0;
    margin: 0;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.bonus-cards::-webkit-scrollbar {
    display: none;
}

.bonus-card {
    flex: 0 0 calc(33.333% - 11px);
    min-width: 280px;
    background: linear-gradient(180deg, #2E3333 0%, #2D3132 50%, #282B2B 100%);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow-card);
    scroll-snap-align: start;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.bonus-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.bonus-desc {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 16px;
    flex-grow: 1;
}

.bonus-card .btn {
    margin-top: auto;
    align-self: flex-start;
}

.slider-prev,
.slider-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: var(--surface-2);
    border: none;
    color: var(--text-primary);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color var(--duration-base) var(--easing-standard);
    z-index: 10;
}

.slider-prev {
    left: 0;
}

.slider-next {
    right: 0;
}

.slider-prev:hover,
.slider-next:hover {
    background-color: var(--surface-3);
}

/* Pros & Cons */
.pros-cons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin: 24px 0;
}

.pros-list,
.cons-list {
    list-style: none;
    padding: 0;
}

.pros-list li,
.cons-list li {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-bottom: 12px;
    padding: 12px;
    background-color: var(--surface-0);
    border-radius: var(--radius-sm);
}

.pros-list li {
    border-left: 3px solid var(--accent-mint);
}

.cons-list li {
    border-left: 3px solid #FF4444;
}

.icon-check,
.icon-cross {
    flex-shrink: 0;
    margin-top: 2px;
}

/* Author Section */
.author-section {
    padding: 48px 0;
    background-color: var(--bg-content);
}

.author-block {
    display: flex;
    flex-direction: column;
    gap: 16px;
    align-items: center;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
    padding: 24px;
    background-color: var(--surface-0);
    border-radius: var(--radius-lg);
}

.author-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.author-name {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.author-bio {
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.author-updated {
    color: var(--text-muted);
    font-size: 12px;
}

/* FAQ Section */
.faq-section {
    padding: 48px 0;
    background-color: var(--bg-body);
}

.faq-list {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    background-color: var(--surface-0);
    border-radius: var(--radius-md);
    margin-bottom: 16px;
    overflow: hidden;
}

.faq-question {
    padding: 16px 20px;
    font-weight: 700;
    color: var(--text-primary);
    cursor: pointer;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color var(--duration-base) var(--easing-standard);
}

.faq-question:hover {
    background-color: var(--overlay-hover);
}

.faq-question::-webkit-details-marker {
    display: none;
}

.faq-question::after {
    content: '+';
    font-size: 24px;
    color: var(--accent-mint);
    transition: transform var(--duration-base) var(--easing-standard);
}

.faq-item[open] .faq-question::after {
    transform: rotate(45deg);
}

.faq-answer {
    padding: 0 20px 20px;
    color: var(--text-secondary);
}

.faq-answer p {
    margin-bottom: 0;
}

/* Footer */
.footer {
    background-color: var(--bg-topbar);
    border-top: 1px solid var(--divider-subtle);
    padding: 48px 0 24px;
}

.footer__content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 32px;
    margin-bottom: 32px;
}

.footer__logo img {
    height: 40px;
    width: auto;
}

.footer__links {
    list-style: none;
    padding: 0;
}

.footer__links li {
    margin-bottom: 8px;
}

.footer__links a {
    color: var(--text-secondary);
    transition: color var(--duration-base) var(--easing-standard);
}

.footer__links a:hover {
    color: var(--accent-mint);
}

.payment-icons {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.payment-icon {
    padding: 8px 12px;
    background-color: var(--surface-0);
    border-radius: var(--radius-sm);
    font-size: 12px;
    color: var(--text-secondary);
}

.footer__copyright {
    text-align: center;
    padding-top: 24px;
    border-top: 1px solid var(--divider-subtle);
    color: var(--text-muted);
    font-size: 12px;
}

/* Back to Top */
.back-to-top {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 48px;
    height: 48px;
    background-color: var(--accent-mint);
    color: var(--text-inverse-on-mint);
    border: none;
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    box-shadow: var(--shadow-floating-action);
    opacity: 0;
    visibility: hidden;
    transition: all var(--duration-base) var(--easing-standard);
    z-index: 999;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background-color: var(--accent-mint-hover);
    transform: translateY(-2px);
}

.back-to-top:active {
    transform: translateY(1px) scale(0.99);
}

.back-to-top:focus {
    outline: 2px solid var(--focus-ring-mint);
    outline-offset: 2px;
}

/* Utility Classes */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .header__top-content {
        flex-wrap: nowrap;
        align-items: center;
        justify-content: space-between;
    }
    
    .header__logo {
        flex-shrink: 0;
    }
    
    .header__cta-buttons {
        order: 0;
        width: auto;
        margin-top: 0;
        margin-left: 0;
        margin-right: 0;
        gap: 4px;
        display: flex;
        flex-shrink: 0;
    }
    
    .header__cta-buttons .btn {
        width: 40px;
        height: 40px;
        padding: 0;
        min-width: 40px;
        border-radius: var(--radius-sm);
    }
    
    .header__cta-buttons .btn__text {
        display: none;
    }
    
    .header__cta-buttons .btn__icon {
        display: block;
    }
    
    .header__burger {
        display: flex;
        position: static;
        order: 1;
        margin-left: 4px;
        flex-shrink: 0;
    }
    
    .header__bottom {
        display: none;
    }
    
    .header__bottom.active {
        display: block;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background-color: var(--bg-topbar);
        border-top: 1px solid var(--divider-subtle);
    }
    
    .nav-list {
        flex-direction: column;
        gap: 0;
        padding: 16px;
    }
    
    .nav-list li {
        width: 100%;
    }
    
    .nav-list a {
        display: block;
        padding: 12px;
    }
    
    .hero__content {
        grid-template-columns: 1fr;
    }
    
    .hero__image {
        order: -1;
    }
    
    .games-grid {
        grid-template-columns: repeat(2, 1fr);
        overflow-x: visible;
        scroll-snap-type: none;
        padding-bottom: 0;
        gap: 12px;
    }
    
    .game-card {
        scroll-snap-align: none;
    }
    
    .bonus-card {
        flex: 0 0 85%;
    }
    
    .pros-cons {
        grid-template-columns: 1fr;
    }
    
    .author-block {
        flex-direction: column;
        text-align: center;
    }
    
    .footer__content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    h1 {
        font-size: 24px;
        line-height: 32px;
    }
    
    h2 {
        font-size: 20px;
        line-height: 28px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 12px;
    }
    
    .hero {
        padding: 32px 0;
    }
    
    .content-section {
        padding: 32px 0;
    }
    
    .btn {
        padding: 8px 16px;
        font-size: 12px;
    }
}
