@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
    --home-background: #f6f7ff;
    --home-surface: #ffffff;
    --home-text: #11142d;
    --home-muted: #747990;
    --home-primary: #e11d48;
    --home-accent: #facc15;
    --home-line: #e4e6f1;
    --home-hover: #f0efff;
    --home-art: #e9eaf2;
    --home-outer: #0a102d;
    --home-radius: 12px;
}

* { box-sizing: border-box; }

.dark {
    --home-background: #11131a;
    --home-surface: #1a1d27;
    --home-text: #f5f6ff;
    --home-muted: #a8adc2;
    --home-primary: #fb7185;
    --home-accent: #fde047;
    --home-line: #303443;
    --home-hover: #272b39;
    --home-art: #242835;
    --home-outer: #070b1f;
    color-scheme: dark;
}

body.zontal-home {
    margin: 0;
    min-width: 320px;
    min-height: 100vh;
    color: var(--home-text);
    background: var(--home-outer) !important;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    -webkit-font-smoothing: antialiased;
}

html.dark,
html.dark body.zontal-home { background: var(--home-outer) !important; }
.dark .home-header { background: rgba(26, 29, 39, .98); }
.dark .home-shell,
.dark .home-content { background: var(--home-background); }
.dark .home-sidebar,
.dark .nexaplay-footer { color: var(--home-text); background: var(--home-surface); }
.dark .home-search { background: #222633; box-shadow: 0 5px 14px rgba(0, 0, 0, .2); }
.dark .home-search > i { color: var(--home-text); }
.dark .home-category-dropdown,
.dark .home-user-menu .profile-dropdown { box-shadow: 0 18px 45px rgba(0, 0, 0, .34); }
.dark .home-category-dropdown a:hover,
.dark .home-user-menu .profile-dropdown a:hover,
.dark .sidebar-link:hover { background: #272b39; }
.dark .category-card,
.dark .game-card,
.dark .popular-card,
.dark .section-heading a { box-shadow: 0 7px 16px rgba(0, 0, 0, .2); }
.dark .category-card:hover,
.dark .game-card:hover,
.dark .popular-card:hover { box-shadow: 0 12px 24px rgba(0, 0, 0, .32); }
.dark .game-art { background: #242835; }
.dark .content-card { box-shadow: 0 18px 48px rgba(0, 0, 0, .28); }
.dark .category-hero { border-color: var(--home-line); background: var(--home-surface); }
.dark .category-hero h1 { color: var(--home-text); }
.dark .category-hero p,
.dark .game-breadcrumb { color: var(--home-muted); }

.zontal-home a { text-decoration: none; }
.zontal-home button,
.zontal-home input { font: inherit; }
.zontal-home button { cursor: pointer; }

.home-header {
    position: sticky;
    top: 0;
    z-index: 50;
    display: grid;
    grid-template-columns: 205px auto minmax(280px, 540px) auto;
    align-items: center;
    gap: 22px;
    min-height: 62px;
    margin: 0;
    padding: 0 24px;
    border-radius: 0;
    border-bottom: 1px solid var(--home-line);
    background: var(--home-surface);
}

.home-brand img { display: block; width: auto; max-width: 148px; height: 38px; object-fit: contain; }
.home-primary-nav,
.home-header-actions { display: flex; align-items: center; gap: 10px; }
.home-nav-link {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    min-height: 38px;
    padding: 0 15px;
    border: 0;
    border-radius: 9px;
    color: var(--home-text);
    background: transparent;
    font-size: 13px;
    font-weight: 500;
}
.home-nav-link.active { color: var(--home-surface); background: var(--home-primary); box-shadow: 0 8px 18px rgba(86, 65, 239, .24); }
.home-category-menu { position: relative; }
.home-category-trigger i { font-size: 9px; }
.home-category-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    display: none;
    grid-template-columns: repeat(2, minmax(120px, 1fr));
    width: 300px;
    padding: 10px;
    border: 1px solid var(--home-line);
    border-radius: var(--home-radius);
    background: var(--home-surface);
    box-shadow: 0 18px 45px rgba(35, 38, 76, .15);
}
.home-category-menu:hover .home-category-dropdown,
.home-category-menu:focus-within .home-category-dropdown { display: grid; }
.home-category-dropdown a { padding: 10px 11px; border-radius: 8px; color: var(--home-text); font-size: 12px; }
.home-category-dropdown a:hover { color: var(--home-primary); background: #f0efff; }
.home-search {
    display: flex;
    align-items: center;
    width: 100%;
    height: 40px;
    padding: 0 14px;
    border: 1px solid var(--home-line);
    border-radius: 13px;
    background: #fbfbfe;
    box-shadow: 0 5px 14px rgba(31, 35, 74, .06);
}
.home-search > i { color: #242740; font-size: 14px; }
.home-search input { min-width: 0; flex: 1; height: 100%; padding: 0 12px; border: 0; outline: 0; color: var(--home-text); background: transparent; font-size: 12px; }
.home-search input::placeholder { color: #777c98; }
.home-search button { display: none; }
.home-header-actions { justify-content: flex-end; }
.home-theme-button,
.home-mobile-menu { display: grid; place-items: center; width: 38px; height: 38px; border: 1px solid var(--home-line); border-radius: 9px; color: var(--home-text); background: var(--home-surface); }
.home-signin { display: inline-flex; align-items: center; gap: 8px; min-height: 38px; padding: 0 15px; border-radius: 9px; color: var(--home-surface); background: var(--home-primary); font-size: 12px; font-weight: 600; white-space: nowrap; }
.home-mobile-menu { display: none !important; }
.home-user-menu button { border: 0; background: transparent; }
.home-user-menu button img { width: 38px; height: 38px; border-radius: 50%; object-fit: cover; }
.home-user-menu .profile-dropdown { position: absolute; top: 48px; right: 0; width: 180px; padding: 8px; border: 1px solid var(--home-line); border-radius: 10px; background: var(--home-surface); box-shadow: 0 15px 35px rgba(35, 38, 76, .14); }
.home-user-menu .profile-dropdown a { display: block; padding: 9px 10px; border-radius: 7px; color: var(--home-text); font-size: 12px; }
    .home-user-menu .profile-dropdown a:hover { color: var(--home-primary); background: var(--home-hover); }
.home-mobile-search { display: none !important; }

.home-shell {
    display: flex;
    align-items: stretch;
    width: 100%;
    min-height: calc(100vh - 62px);
    margin: 0;
    border-radius: 0;
    overflow: visible;
    background: var(--home-background);
}
.home-sidebar {
    position: sticky;
    top: 62px;
    z-index: 10;
    display: flex;
    flex: 0 0 235px;
    flex-direction: column;
    align-self: flex-start;
    padding: 14px 12px 12px;
    border-right: 1px solid var(--home-line);
    border-radius: 0 0 0 14px;
    background: var(--home-surface);
}
.sidebar-nav { display: flex; flex-direction: column; gap: 2px; }
.sidebar-link { display: flex; align-items: center; gap: 12px; min-height: 40px; padding: 0 13px; border-radius: 8px; color: var(--home-text); font-size: 12px; font-weight: 500; transition: color .2s, background-color .2s; }
.sidebar-link:hover { color: var(--home-primary); background: var(--home-hover); }
.sidebar-link.active { color: var(--home-surface); background: var(--home-primary); box-shadow: 0 7px 17px rgba(86, 65, 239, .22); }
.sidebar-link i { width: 20px; color: var(--home-primary); text-align: center; font-size: 15px; }
.sidebar-link.active i { color: var(--home-surface); }
.sidebar-secondary { margin-top: 11px; padding-top: 11px; border-top: 1px solid var(--home-line); }
.new-label,
.game-badge { margin-left: auto; padding: 3px 6px; border-radius: 4px; color: var(--home-surface); background: var(--home-primary); font-size: 8px; font-weight: 800; }
.home-content { min-width: 0; flex: 1; padding: 12px 14px 18px; overflow: hidden; }
.home-hero { position: relative; display: flex; align-items: center; min-height: 320px; overflow: hidden; border-radius: 13px; background: #090d31; box-shadow: 0 13px 30px rgba(25, 22, 91, .16); }
.hero-background { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 72% center; transform: scale(1.04); filter: saturate(1.35) contrast(1.08); }
.home-hero::before { position: absolute; z-index: 1; inset: 0; content: ''; background: linear-gradient(90deg, rgba(3, 7, 33, .99) 0%, rgba(7, 11, 49, .96) 38%, rgba(31, 17, 103, .43) 69%, rgba(52, 23, 132, .10) 100%); }
.home-hero::after { position: absolute; z-index: 1; inset: 0; content: ''; background: linear-gradient(150deg, transparent 54%, rgba(124, 56, 237, .22)); }
.hero-copy { position: relative; z-index: 2; width: min(620px, 58%); padding: 36px 48px; color: var(--home-surface); }
.hero-eyebrow { display: inline-flex; padding: 6px 11px; border: 1px solid rgba(255, 255, 255, .14); border-radius: 7px; background: rgba(86, 61, 242, .65); font-size: 10px; font-weight: 700; }
.hero-copy h1 { margin: 16px 0 12px; color: var(--home-surface); font-size: clamp(30px, 3vw, 42px); font-weight: 800; line-height: 1.12; letter-spacing: -.035em; }
.hero-copy h1 span { color: #9c69ff; }
.hero-copy p { margin: 0; color: #e2e2ed; font-size: 13px; line-height: 1.7; }
.hero-button { display: inline-flex; align-items: center; gap: 12px; margin-top: 21px; padding: 12px 19px; border-radius: 8px; color: var(--home-surface); background: linear-gradient(135deg, var(--home-primary), var(--home-accent)); font-size: 12px; font-weight: 700; box-shadow: 0 9px 20px rgba(86, 61, 242, .34); }
.hero-game-label { position: absolute; right: 16px; bottom: 14px; z-index: 2; display: flex; max-width: 210px; flex-direction: column; padding: 9px 12px; border: 1px solid rgba(255, 255, 255, .14); border-radius: 8px; color: var(--home-surface); background: rgba(7, 9, 39, .62); backdrop-filter: blur(10px); }
.hero-game-label span { color: #bcbad2; font-size: 9px; text-transform: uppercase; letter-spacing: .08em; }
.hero-game-label strong { margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; }

.home-section { margin-top: 17px; }
.section-heading { display: flex; align-items: center; justify-content: space-between; margin-bottom: 9px; }
.section-heading h2 { margin: 0; color: var(--home-text); font-size: 18px; font-weight: 800; letter-spacing: -.02em; }
.section-heading a { padding: 8px 12px; border: 1px solid var(--home-line); border-radius: 8px; color: var(--home-text); background: var(--home-surface); font-size: 10px; font-weight: 600; box-shadow: 0 4px 12px rgba(31, 35, 74, .05); }
.category-cards,
.game-cards,
.popular-cards { display: grid; gap: 14px; }
.category-cards { grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); }
.category-card { display: flex; min-width: 0; min-height: 118px; align-items: center; flex-direction: column; justify-content: center; padding: 12px 8px; border: 1px solid var(--home-line); border-radius: var(--home-radius); color: var(--home-text); background: var(--home-surface); box-shadow: 0 7px 16px rgba(31, 35, 74, .08); transition: transform .2s, box-shadow .2s; }
.category-card i { margin-bottom: 10px; color: var(--home-primary); font-size: 30px; }
.category-card:nth-child(1) i { color: #ef4e3d; }
.category-card:nth-child(2) i { color: #20a653; }
.category-card:nth-child(3) i { color: #b92ee4; }
.category-card:nth-child(4) i { color: #4464f3; }
.category-card:nth-child(5) i { color: #ef790f; }
.category-card:nth-child(6) i { color: #35a94b; }
.category-card:nth-child(7) i { color: #188aea; }
.category-card:nth-child(8) i { color: #8d35dc; }
.category-card strong { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; }
.category-card span { margin-top: 4px; color: var(--home-muted); font-size: 9px; }
.game-cards { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.popular-cards { grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); }
.game-card,
.popular-card { min-width: 0; overflow: hidden; border: 1px solid var(--home-line); border-radius: var(--home-radius); color: var(--home-text); background: var(--home-surface); box-shadow: 0 7px 16px rgba(31, 35, 74, .08); transition: transform .2s, box-shadow .2s; }
.category-card:hover,
.game-card:hover,
.popular-card:hover { transform: translateY(-3px); box-shadow: 0 12px 24px rgba(31, 35, 74, .13); }
.game-art { position: relative; aspect-ratio: 1.35 / 1; overflow: hidden; background: var(--home-art); }
.game-art img,
.popular-card img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.game-card:hover img,
.popular-card:hover img { transform: scale(1.04); }
.game-art .game-badge { position: absolute; top: 7px; left: 7px; margin: 0; }
.game-meta { display: flex; flex-direction: column; gap: 3px; padding: 9px 10px 10px; }
.game-meta strong,
.popular-card strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; }
.game-meta span { color: var(--home-primary); font-size: 9px; }
.popular-card { position: relative; aspect-ratio: 1.7 / 1; }
.popular-card::after { position: absolute; inset: 38% 0 0; content: ''; background: linear-gradient(transparent, rgba(7, 9, 28, .88)); }
.popular-card strong { position: absolute; z-index: 2; right: 8px; bottom: 7px; left: 8px; color: var(--home-surface); text-align: center; }

.nexaplay-footer {
    width: 100%;
    margin: 0 !important;
    overflow: hidden;
    border-top: 1px solid var(--home-line);
    border-radius: 0;
    color: var(--home-text);
    background: var(--home-surface);
}
.footer-main {
    display: grid;
    grid-template-columns: minmax(260px, 1.6fr) repeat(3, minmax(130px, 1fr)) minmax(210px, 1.2fr);
    gap: 42px;
    padding: 50px 34px 42px;
}
.footer-brand-column { display: flex; max-width: 330px; flex-direction: column; gap: 18px; }
.footer-brand { display: inline-flex; width: fit-content; align-items: center; gap: 10px; color: var(--home-text); }
.footer-brand i { color: var(--home-primary); font-size: 28px; }
.footer-brand strong { color: var(--home-text); font-size: 22px; font-weight: 800; letter-spacing: -.03em; }
.footer-brand-column p,
.footer-support p { margin: 0; color: var(--home-muted); font-size: 13px; line-height: 1.7; }
.footer-browser-note { display: inline-flex; align-items: center; gap: 9px; color: var(--home-text); font-size: 12px; font-weight: 600; }
.footer-browser-note i { color: var(--home-primary); }
.footer-column { display: flex; align-items: flex-start; flex-direction: column; gap: 11px; }
.footer-column h2 { margin: 0 0 7px; color: var(--home-text); font-size: 13px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.footer-column a { color: var(--home-muted); font-size: 12px; transition: color .2s, transform .2s; }
.footer-column a:hover { color: var(--home-text); transform: translateX(2px); }
.footer-support { max-width: 250px; }
.footer-email { display: inline-flex; align-items: center; gap: 8px; color: var(--home-primary) !important; font-weight: 700; word-break: break-word; }
.footer-bottom { border-top: 1px solid var(--home-line); }
.footer-bottom .container-zon { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 16px 34px; }
.footer-bottom p { margin: 0; color: var(--home-muted); font-size: 11px; }

.content-intro { color: var(--home-text) !important; font-size: 17px !important; line-height: 1.75 !important; }
.content-card strong { color: var(--home-text); }
.content-callout,
.contact-panel { margin-top: 30px; padding: 22px; border: 1px solid var(--home-line); border-radius: var(--home-radius); background: var(--home-background); }
.content-callout h2 { margin-top: 0; }
.content-callout p { margin-bottom: 0; }
.contact-panel { display: flex; align-items: center; gap: 16px; }
.contact-icon { display: grid; width: 48px; height: 48px; flex: 0 0 48px; place-items: center; border-radius: 10px; color: var(--home-surface); background: var(--home-primary); font-size: 18px; }
.contact-panel > div:last-child { display: flex; flex-direction: column; gap: 4px; }
.contact-panel span { color: var(--home-muted); font-size: 12px; }
.contact-panel a { font-size: 16px; }

@media (max-width: 1360px) {
    .home-header { grid-template-columns: 190px auto minmax(240px, 1fr) auto; gap: 14px; padding: 0 18px; }
    .home-sidebar { flex-basis: 220px; }
    .game-cards { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 980px) {
    .game-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .footer-main { grid-template-columns: 1.5fr repeat(2, 1fr); gap: 34px; }
    .footer-brand-column { grid-column: 1 / -1; max-width: 520px; }
    .footer-support { max-width: none; }
    .home-header { grid-template-columns: 150px minmax(180px, 1fr) auto; min-height: 64px; }
    .home-primary-nav { display: none; }
    .home-mobile-menu { display: grid !important; }
    .home-shell { min-height: calc(100vh - 64px); }
    .home-sidebar { top: 74px; flex-basis: 205px; }
    .home-content { padding: 12px; }
    .hero-copy { width: 67%; padding: 32px; }
}
@media (max-width: 760px) {
    body.zontal-home { background: var(--home-background) !important; }
    .home-header { top: 0; grid-template-columns: 125px minmax(0, 1fr) auto; gap: 8px; margin: 0; padding: 0 12px; border-radius: 0; }
    .home-shell { margin: 0; border-radius: 0; }
    .home-brand img { max-width: 118px; height: 32px; }
    .home-search { height: 38px; }
    .home-theme-button { display: grid; }
    .home-signin { width: 38px; padding: 0; justify-content: center; font-size: 0; }
    .home-signin i { font-size: 13px; }
    .home-sidebar { display: none; }
    .home-hero { min-height: 330px; }
    .hero-copy { width: 78%; padding: 26px; }
    .hero-copy h1 { font-size: 30px; }
    .hero-game-label { display: none; }
    .category-cards { display: flex; overflow-x: auto; padding-bottom: 8px; scrollbar-width: none; }
    .category-cards::-webkit-scrollbar { display: none; }
    .category-card { min-width: 128px; }
    .game-cards,
    .popular-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
    .zontal-home footer { margin: 0 !important; border-radius: 0; }
    .footer-main { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 30px 24px; padding: 38px 24px 34px; }
    .footer-brand-column { grid-column: 1 / -1; }
    .footer-bottom .container-zon { align-items: flex-start; flex-direction: column; padding: 16px 24px; }
    .content-page { padding: 34px 14px; }
    .content-card { padding: 30px 24px; border-radius: 13px; }
    .content-card h1 { font-size: 32px; }
    .content-intro { font-size: 16px !important; }
}
.section-heading > div { display: flex; flex-direction: column; gap: 2px; }
.section-kicker { color: var(--home-primary); font-size: 9px; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; }
.empty-state { padding: 28px; border: 1px dashed var(--home-line); border-radius: var(--home-radius); color: var(--home-muted); background: var(--home-surface); text-align: center; }
.content-page { min-height: calc(100vh - 160px); padding: 56px 20px; background: var(--home-background); }
.content-card { max-width: 860px; margin: 0 auto; padding: 42px; border: 1px solid var(--home-line); border-radius: 16px; color: var(--home-text); background: var(--home-surface); box-shadow: 0 18px 48px rgba(31,35,74,.09); }
.content-card h1 { margin: 0 0 12px; font-size: clamp(30px,4vw,46px); line-height: 1.15; letter-spacing: -.04em; }
.content-card h2 { margin: 28px 0 8px; font-size: 20px; }
.content-card p, .content-card li { color: var(--home-muted); font-size: 15px; line-height: 1.75; }
.content-card a { color: var(--home-primary); font-weight: 700; }
.content-card ul { display: flex; flex-direction: column; gap: 8px; padding-left: 22px; }
.category-hero { margin: 30px 12px 10px; padding: 36px; border: 1px solid var(--home-line); border-radius: 16px; background: var(--home-surface); text-align: center; }
.category-hero h1 { margin: 0; color: var(--home-text); font-size: 38px; }
.category-hero p { max-width: 680px; margin: 10px auto 0; color: var(--home-muted); line-height: 1.7; }
.category-game-count { display: inline-flex; margin-top: 14px; padding: 7px 11px; border: 1px solid var(--home-line); border-radius: 8px; color: var(--home-primary); background: var(--home-background); font-size: 11px; font-weight: 700; }
.game-breadcrumb { display: flex; gap: 8px; margin: 20px 4px; color: #747990; font-size: 13px; }
.game-breadcrumb a { color: #5641ef; }
.related-games { margin: 30px 4px 50px; }

@media (max-width: 520px) {
    .footer-main { grid-template-columns: 1fr; }
    .footer-brand-column { grid-column: auto; }
    .contact-panel { align-items: flex-start; }
    .contact-panel a { font-size: 14px; }
    .home-header { grid-template-columns: 1fr auto; }
    .home-search { display: none; }
    .home-content { padding: 9px; }
    .home-hero { min-height: 360px; align-items: flex-end; }
    .hero-background { object-position: center; }
    .home-hero::before { background: linear-gradient(0deg, rgba(4, 8, 35, .98) 0%, rgba(7, 11, 43, .78) 58%, rgba(21, 13, 75, .28) 100%); }
    .hero-copy { width: 100%; padding: 24px 20px 28px; }
    .hero-copy h1 { font-size: 27px; }
    .hero-copy p br { display: none; }
    .section-heading h2 { font-size: 17px; }
}

/* Preserve the original NexaPlay desktop rhythm even when the database contains
   fewer categories or games. Fixed tracks stop sparse rows from stretching. */
.zontal-home .home-shell {
    margin-inline: 0;
    border-radius: 0;
}

.zontal-home .home-sidebar {
    flex-basis: 244px;
    padding: 14px 11px 12px;
    border-radius: 0;
}

.zontal-home .home-content {
    padding: 12px 14px 18px;
}

.zontal-home .home-hero {
    min-height: 328px;
}

.zontal-home .category-cards,
.zontal-home .home-content > .home-section .game-cards {
    grid-template-columns: repeat(8, minmax(0, 1fr));
    align-items: stretch;
}

.zontal-home .category-cards,
.zontal-home .home-content > .home-section .game-cards {
    gap: 14px;
}

.zontal-home .category-card {
    min-height: 118px;
}

.zontal-home .home-content > .home-section .game-card {
    display: flex;
    height: 100%;
    flex-direction: column;
}

.zontal-home .home-content > .home-section .game-art {
    aspect-ratio: 1.35 / 1;
}

.zontal-home .home-content > .home-section .game-meta {
    flex: 1;
}

@media (max-width: 1279px) {
    .zontal-home .category-cards,
    .zontal-home .home-content > .home-section .game-cards {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media (max-width: 980px) {
    .zontal-home .home-sidebar { flex-basis: 205px; }
    .zontal-home .category-cards,
    .zontal-home .home-content > .home-section .game-cards {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .zontal-home .category-cards {
        display: flex;
    }
    .zontal-home .home-content > .home-section .game-cards {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 520px) {
    .zontal-home .home-content > .home-section .game-cards {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* Complete public dark theme. The theme class lives on <html>, so these rules
   cover both the modern shell and legacy public pages without touching admin. */
html.dark,
html.dark body {
    color: var(--home-text);
    background-color: var(--home-background) !important;
}

.dark .home-shell,
.dark .content-page,
.dark .body,
.dark main {
    color: var(--home-text);
}

.dark .header-main,
.dark .mobile-header,
.dark .offcanvas-menu,
.dark .profile-dropdown,
.dark .login-form,
.dark .comment-single {
    color: var(--home-text);
    border-color: var(--home-line) !important;
    background-color: var(--home-surface) !important;
}

.dark .header-main {
    box-shadow: 0 1px 0 var(--home-line);
}

.dark .header-main a,
.dark .mobile-header a,
.dark .offcanvas-menu a,
.dark .offcanvas-menu button,
.dark .close-offcanvas,
.dark .login-form,
.dark .login-form label,
.dark .login-form a,
.dark .body h1,
.dark .body h2,
.dark .body h3,
.dark .body h4,
.dark .body p,
.dark .body span {
    color: var(--home-text) !important;
}

.dark .header-main form,
.dark .header-main input,
.dark .mobile-header form,
.dark .mobile-header input,
.dark .login-form input,
.dark .body input,
.dark .body textarea,
.dark .body select {
    color: var(--home-text) !important;
    border-color: var(--home-line) !important;
    background-color: var(--home-hover) !important;
}

.dark .header-main input::placeholder,
.dark .mobile-header input::placeholder,
.dark .login-form input::placeholder,
.dark .body input::placeholder,
.dark .body textarea::placeholder {
    color: var(--home-muted) !important;
}

.dark .mode-changer,
.dark .home-mobile-menu {
    color: var(--home-text) !important;
    border-color: var(--home-line) !important;
    background-color: var(--home-surface) !important;
}

.dark .menu-list li a:hover,
.dark .profile-dropdown a:hover {
    color: var(--home-text) !important;
    background-color: var(--home-hover) !important;
}

.dark .nexaplay-logo,
.dark .content-card h1,
.dark .content-card h2,
.dark .content-card h3,
.dark .content-card strong,
.dark .content-card li::marker,
.dark .category-hero h1,
.dark .section-heading h2 {
    color: var(--home-text);
}

.dark .content-card,
.dark .content-callout,
.dark .contact-panel,
.dark .category-hero,
.dark .empty-state,
.dark .category-card,
.dark .game-card,
.dark .popular-card,
.dark .nexaplay-footer {
    color: var(--home-text);
    border-color: var(--home-line);
    background-color: var(--home-surface);
}

.dark .content-card p,
.dark .content-card li,
.dark .content-intro,
.dark .category-hero p,
.dark .footer-brand-column p,
.dark .footer-support p,
.dark .footer-column a,
.dark .footer-bottom p,
.dark .empty-state {
    color: var(--home-muted) !important;
}

.dark .category-game-count,
.dark .content-callout,
.dark .contact-panel {
    border-color: var(--home-line);
    background-color: var(--home-hover);
}

.dark .game-breadcrumb {
    color: var(--home-muted);
}

.dark .game-breadcrumb a,
.dark .content-card a,
.dark .footer-email {
    color: var(--home-primary) !important;
}

.dark .offcanvas-menu {
    box-shadow: 18px 0 50px rgba(0, 0, 0, .42);
}

.dark .blur-overlay {
    background-color: rgba(4, 6, 15, .72);
}

.dark .nexaplay-footer,
.dark .footer-bottom {
    border-color: var(--home-line);
}

/* Game detail, profile, login, and registration surfaces use legacy utility
   classes. Important declarations keep the class-based saved theme authoritative
   even when the bundled Tailwind runtime was generated with media dark mode. */
html.dark body.zontal-home .gameplay-footer,
html.dark body.zontal-home .game-editorial,
html.dark body.zontal-home .game-original-description,
html.dark body.zontal-home .game-guide-section,
html.dark body.zontal-home .comments,
html.dark body.zontal-home .comment-single,
html.dark body.zontal-home .related-games,
html.dark body.zontal-home .card-container,
html.dark body.zontal-home .input-group {
    color: var(--home-text) !important;
}

html.dark body.zontal-home .game-original-description,
html.dark body.zontal-home .game-guide-section,
html.dark body.zontal-home .comment-single {
    border-color: var(--home-line) !important;
    background-color: var(--home-surface) !important;
}

html.dark body.zontal-home .gameplay-footer h1,
html.dark body.zontal-home .gameplay-footer h2,
html.dark body.zontal-home .game-editorial h2,
html.dark body.zontal-home .game-editorial p,
html.dark body.zontal-home .game-editorial li,
html.dark body.zontal-home .comments h4,
html.dark body.zontal-home .comments p,
html.dark body.zontal-home .related-games > h2,
html.dark body.zontal-home .card-container h1,
html.dark body.zontal-home .card-container label,
html.dark body.zontal-home .card-container p,
html.dark body.zontal-home .card-container span {
    color: var(--home-text) !important;
}

html.dark body.zontal-home .gameplay-footer > div > .left > a,
html.dark body.zontal-home .gameplay-footer .light-color,
html.dark body.zontal-home .comments .uppercase,
html.dark body.zontal-home .game-editorial .game-original-description p,
html.dark body.zontal-home .game-editorial .game-guide-section p,
html.dark body.zontal-home .game-editorial .game-guide-section li {
    color: var(--home-muted) !important;
}

html.dark body.zontal-home .gameplay-footer a[class*="bg-gray"],
html.dark body.zontal-home .gameplay-footer a[class*="bg-blue-100"] {
    color: var(--home-text) !important;
    border-color: var(--home-line) !important;
    background-color: var(--home-hover) !important;
}

html.dark body.zontal-home .comment-form textarea,
html.dark body.zontal-home .card-container input,
html.dark body.zontal-home .card-container textarea,
html.dark body.zontal-home .card-container select,
html.dark body .login-form input {
    color: var(--home-text) !important;
    border-color: var(--home-line) !important;
    background-color: var(--home-hover) !important;
}

html.dark body .login-form {
    padding: 24px;
    border: 1px solid var(--home-line);
    border-radius: var(--home-radius);
    background-color: var(--home-surface) !important;
    box-shadow: 0 18px 48px rgba(0, 0, 0, .28);
}

html.dark body .login-form label,
html.dark body .login-form a {
    color: var(--home-muted) !important;
}

html.dark body .login-form input:focus,
html.dark body.zontal-home .comment-form textarea:focus,
html.dark body.zontal-home .card-container input:focus {
    border-color: var(--home-primary) !important;
}

@media (max-width: 760px) {
    .mobile-categories-group details > summary {
        display: flex;
        align-items: center;
        justify-content: space-between;
        width: 100%;
        padding: 10px 14px;
        color: var(--home-text);
        cursor: pointer;
        list-style: none;
    }

    .mobile-categories-group details > summary::-webkit-details-marker {
        display: none;
    }

    .mobile-categories-group details > summary::after {
        content: "+";
        font-weight: 700;
    }

    .mobile-categories-group details[open] > summary::after {
        content: "−";
    }

    .mobile-categories-group details > ul {
        margin: 0;
        padding: 0 0 4px 10px;
    }
}
