/* ============ RESET / BASE ============ */
* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
    --bg: #ffffff;
    --surface: #ffffff;
    --surface-2: #f7f9f8;
    --border: #e6eae8;
    --border-strong: rgba(234, 179, 8, 0.5);
    --gold: #eab308;
    --gold-2: #f5c451;
    --gold-text: #b45309;      /* readable amber for bonus text on white */
    --green: #17b455;
    --green-2: #12a049;
    --text: #17231c;
    --muted: #5f6f66;
    --shadow: 0 10px 30px rgba(20, 45, 30, 0.07);
    --radius: 18px;
}

html { scroll-behavior: smooth; }

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: var(--text);
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    background:
        radial-gradient(1100px 500px at 85% -8%, rgba(23, 180, 85, 0.06), transparent 60%),
        radial-gradient(900px 500px at 0% 0%, rgba(234, 179, 8, 0.06), transparent 55%),
        var(--bg);
    min-height: 100vh;
    overflow-x: hidden;              /* safety net: never scroll sideways on mobile */
}

a { text-decoration: none; color: inherit; }
h1, h2, h3, .brand-title { font-family: 'Sora', 'Inter', sans-serif; }

/* ============ BRAND / LOGO ============ */
.brand { display: flex; align-items: center; gap: 12px; }
.brand-logo {
    width: 50px; height: 50px;
    border-radius: 13px;
    background: linear-gradient(150deg, #0c2a1e, #06150e);
    border: 1.5px solid var(--gold);
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    line-height: 1.02; flex-shrink: 0;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.18), inset 0 0 12px rgba(247, 201, 72, 0.18);
}
.brand-logo-top { color: var(--gold-2); font-size: 11px; font-weight: 800; letter-spacing: 1px; }
.brand-logo-bottom { color: #2fe07d; font-size: 11px; font-weight: 800; letter-spacing: 1.5px; }
.brand-title { font-size: 19px; font-weight: 800; color: #16231c; }

/* ============ HEADER ============ */
.site-header {
    position: sticky; top: 0; z-index: 60;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 1px 8px rgba(20, 45, 30, 0.04);
}
.header-inner {
    max-width: 1200px; margin: 0 auto;
    padding: 12px 22px;
    display: flex; align-items: center; justify-content: space-between; gap: 18px;
}
.site-nav { display: flex; align-items: center; gap: 4px; }
.nav-link {
    display: inline-flex; align-items: center; gap: 7px;
    padding: 9px 15px; border-radius: 10px;
    font-size: 14px; font-weight: 600; color: #40514a;
    transition: all 0.16s;
}
.nav-link i { font-size: 14px; }
.nav-link:hover { background: #f1f4f2; color: #16231c; }
.nav-link.active { color: var(--green-2); background: #eafaf0; }
.nav-tg { color: #1e93d6; }
.menu-toggle {
    display: none;
    background: #f1f4f2;
    border: 1px solid var(--border);
    color: #16231c; width: 44px; height: 40px;
    border-radius: 10px; font-size: 18px; cursor: pointer;
}

/* ============ HERO ============ */
.hero { padding: 52px 22px 34px; }
.hero-inner { max-width: 900px; margin: 0 auto; text-align: center; }
.hero-eyebrow {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 7px 16px; border-radius: 999px;
    background: #fdf6e3;
    border: 1px solid var(--border-strong);
    color: var(--gold-text); font-size: 12.5px; font-weight: 700;
    letter-spacing: 0.3px; margin-bottom: 20px;
}
.hero-title {
    font-size: 42px; font-weight: 800; line-height: 1.15;
    color: #14231b; letter-spacing: -0.5px; margin-bottom: 16px;
}
.hero-title .grad {
    background: linear-gradient(100deg, var(--gold-text) 0%, var(--gold) 45%, var(--green-2) 110%);
    -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.hero-sub { color: #4a5a52; font-size: 16px; max-width: 660px; margin: 0 auto 26px; }
.hero-sub strong { color: #16231c; }

.hero-search {
    display: flex; align-items: center; gap: 10px;
    max-width: 580px; margin: 0 auto 30px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 999px; padding: 6px 8px 6px 20px;
    box-shadow: var(--shadow);
    transition: border-color 0.18s, box-shadow 0.18s;
}
.hero-search:focus-within { border-color: var(--gold); box-shadow: 0 0 0 4px rgba(234, 179, 8, 0.14); }
.hero-search > i { color: var(--gold); font-size: 16px; }
.hero-search input {
    flex: 1; border: none; background: transparent; outline: none;
    color: #16231c; font-size: 15px; font-family: inherit; padding: 12px 0;
}
.hero-search input::placeholder { color: #93a49b; }
.search-clear {
    background: #eef1ef; border: none; color: #5f6f66;
    width: 40px; height: 40px; border-radius: 50%; cursor: pointer; font-size: 15px;
    flex-shrink: 0;
}
.search-clear:hover { background: #e2e6e3; color: #16231c; }

.hero-stats {
    display: grid; grid-template-columns: repeat(4, 1fr);
    gap: 12px; max-width: 720px; margin: 0 auto;
}
.stat {
    background: var(--surface); border: 1px solid var(--border);
    border-radius: 14px; padding: 16px 10px;
    display: flex; flex-direction: column; align-items: center; gap: 3px;
    box-shadow: var(--shadow);
}
.stat i { color: var(--gold); font-size: 18px; margin-bottom: 3px; }
.stat b { font-size: 21px; font-weight: 800; color: #16231c; }
.stat span { font-size: 11.5px; color: var(--muted); }

/* ============ CONTAINER / SECTION HEAD ============ */
.container { max-width: 1200px; margin: 0 auto; padding: 24px 22px 40px; }
.section-head { text-align: center; margin-bottom: 22px; }
.section-title { font-size: 28px; font-weight: 800; color: #14231b; }
.section-desc { color: var(--muted); font-size: 15px; margin-top: 6px; }

/* ============ FILTER CHIPS ============ */
.filter-bar {
    display: flex; gap: 10px; flex-wrap: wrap; justify-content: center;
    margin-bottom: 18px;
}
.chip {
    display: inline-flex; align-items: center; gap: 7px;
    padding: 9px 17px; border-radius: 999px;
    background: #fff; border: 1px solid var(--border);
    color: #40514a; font-size: 13.5px; font-weight: 700; cursor: pointer;
    font-family: inherit; transition: all 0.16s; white-space: nowrap;
}
.chip .count { font-size: 11px; opacity: 0.65; }
.chip:hover { border-color: var(--border-strong); color: #16231c; }
.chip.active {
    background: linear-gradient(100deg, var(--gold), var(--gold-2));
    color: #3d2c04; border-color: transparent;
    box-shadow: 0 8px 18px rgba(234, 179, 8, 0.28);
}
.chip.active .count { opacity: 0.8; }

.result-count { text-align: center; color: var(--muted); font-size: 13px; margin-bottom: 18px; }
.result-count b { color: var(--gold-text); }

/* ============ GAME GRID ============ */
.game-grid {
    display: grid;
    /* min(330px,100%) prevents the track from ever exceeding the screen on small phones */
    grid-template-columns: repeat(auto-fill, minmax(min(330px, 100%), 1fr));
    gap: 16px;
}

.game-card {
    position: relative;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px;
    display: flex; align-items: center; gap: 15px;
    box-shadow: var(--shadow);
    transition: transform 0.18s, border-color 0.18s, box-shadow 0.18s;
    animation: fadeUp 0.4s ease both;
    overflow: hidden;
}
.game-card:hover {
    transform: translateY(-4px);
    border-color: var(--border-strong);
    box-shadow: 0 18px 40px rgba(20, 45, 30, 0.13);
}
.game-card.featured {
    grid-column: 1 / -1;
    background:
        radial-gradient(600px 200px at 100% 0%, rgba(234, 179, 8, 0.1), transparent 60%),
        var(--surface);
    border-color: var(--border-strong);
}
.featured-tag {
    position: absolute; top: 14px; right: 16px;
    font-size: 11px; font-weight: 800; letter-spacing: 0.5px;
    color: #3d2c04; background: linear-gradient(100deg, var(--gold), var(--gold-2));
    padding: 4px 10px; border-radius: 999px;
}

.game-badge {
    position: absolute; top: 12px; left: 12px;
    min-width: 24px; height: 24px; padding: 0 6px;
    background: #fdf6e3;
    border: 1px solid var(--border-strong);
    color: var(--gold-text); font-size: 12px; font-weight: 800;
    border-radius: 8px; display: flex; align-items: center; justify-content: center;
}

.game-icon {
    width: 62px; height: 62px; border-radius: 15px; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-weight: 800; font-size: 17px; letter-spacing: 0.3px;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.28);
    box-shadow: 0 8px 16px rgba(20, 45, 30, 0.18), inset 0 0 0 1.5px rgba(255, 255, 255, 0.2);
}

.game-icon-img { object-fit: cover; padding: 0; background: #fff; }

.game-info { flex: 1; min-width: 0; }
.game-name { font-size: 18px; font-weight: 700; color: #16231c; margin-bottom: 8px; }
.game-cat {
    display: inline-block; font-size: 10.5px; font-weight: 700; letter-spacing: 0.4px;
    color: var(--green-2); background: #eafaf0;
    padding: 2px 8px; border-radius: 6px; margin-left: 8px; vertical-align: middle;
    text-transform: uppercase;
}
.game-meta { display: flex; flex-direction: column; gap: 4px; }
.game-meta .bonus {
    color: var(--gold-text); font-size: 13.5px; font-weight: 700;
    display: flex; align-items: center; gap: 8px;
}
.game-meta .withdraw {
    color: var(--muted); font-size: 13px; font-weight: 500;
    display: flex; align-items: center; gap: 8px;
}
.game-meta i { width: 15px; text-align: center; }
.game-meta .bonus i { color: var(--gold); }

.download-btn {
    background: linear-gradient(100deg, var(--green), var(--green-2));
    color: #fff; border: none; font-family: inherit;
    font-size: 14px; font-weight: 800; padding: 12px 22px;
    border-radius: 12px; cursor: pointer;
    display: inline-flex; align-items: center; gap: 8px; white-space: nowrap;
    transition: transform 0.12s, box-shadow 0.18s, filter 0.18s;
    flex-shrink: 0; box-shadow: 0 8px 18px rgba(23, 180, 85, 0.28);
}
.download-btn:hover { filter: brightness(1.06); box-shadow: 0 12px 26px rgba(23, 180, 85, 0.4); }
.download-btn:active { transform: scale(0.96); }

.no-results { text-align: center; color: var(--muted); font-size: 16px; padding: 40px 0; }
.no-results i { color: var(--gold); margin-right: 8px; }

/* ============ GAME DETAIL PAGE ============ */
.detail-container { padding-top: 30px; }

.back-link {
    display: inline-flex; align-items: center; gap: 8px;
    font-size: 14px; font-weight: 700; color: var(--muted);
    padding: 8px 4px; margin-bottom: 16px; transition: color 0.15s;
}
.back-link:hover { color: var(--gold-text); }
.back-link i { font-size: 13px; }

.detail-card {
    background:
        radial-gradient(700px 240px at 100% 0%, rgba(234, 179, 8, 0.10), transparent 60%),
        var(--surface);
    border: 1px solid var(--border-strong);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 30px;
    display: flex; gap: 26px; align-items: flex-start;
    animation: fadeUp 0.4s ease both;
}
.detail-card .game-icon {
    width: 96px; height: 96px; border-radius: 22px; font-size: 26px;
}
.detail-info { flex: 1; min-width: 0; }
.detail-name {
    font-size: 30px; font-weight: 800; color: #14231b; line-height: 1.2;
    display: flex; align-items: center; flex-wrap: wrap; gap: 4px;
}
.detail-name .game-cat { font-size: 12px; margin-left: 6px; }
.detail-tagline { color: var(--muted); font-size: 15px; margin: 8px 0 20px; }

.detail-stats {
    display: grid; grid-template-columns: repeat(4, 1fr);
    gap: 12px; margin-bottom: 22px;
}
.detail-stat {
    background: var(--surface-2); border: 1px solid var(--border);
    border-radius: 14px; padding: 14px 10px;
    display: flex; flex-direction: column; align-items: center; gap: 2px; text-align: center;
}
.detail-stat i { color: var(--gold); font-size: 17px; margin-bottom: 4px; }
.detail-stat b { font-size: 18px; font-weight: 800; color: #16231c; }
.detail-stat span { font-size: 11.5px; color: var(--muted); }

.detail-download {
    font-size: 16px; padding: 16px 30px; border-radius: 14px;
    width: 100%; justify-content: center; margin-bottom: 20px;
}

.detail-points { list-style: none; display: flex; flex-direction: column; gap: 9px; }
.detail-points li {
    display: flex; align-items: flex-start; gap: 10px;
    color: #45564d; font-size: 14px;
}
.detail-points i { color: var(--green); margin-top: 3px; }

.detail-notfound {
    text-align: center; padding: 50px 20px;
    background: var(--surface); border: 1px solid var(--border);
    border-radius: var(--radius); box-shadow: var(--shadow);
}
.detail-notfound i { font-size: 40px; color: var(--gold); margin-bottom: 14px; }
.detail-notfound h1 { font-size: 26px; color: #14231b; margin-bottom: 10px; }
.detail-notfound p { color: var(--muted); font-size: 15px; max-width: 460px; margin: 0 auto 22px; }
.detail-notfound .download-btn { background: linear-gradient(100deg, var(--gold), var(--gold-2)); color: #3d2c04; }

.suggest-section { margin-top: 44px; }
.suggest-section .section-head { margin-bottom: 18px; }

@media (max-width: 640px) {
    .detail-card { flex-direction: column; align-items: center; text-align: center; padding: 24px 20px; }
    .detail-card .game-icon { width: 84px; height: 84px; }
    .detail-name { justify-content: center; font-size: 25px; }
    .detail-stats { grid-template-columns: repeat(2, 1fr); }
    .detail-points { text-align: left; }
}

/* ============ SEO SECTION ============ */
.seo-section { padding: 30px 22px; }
.seo-inner {
    max-width: 1000px; margin: 0 auto;
    background: var(--surface-2); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 34px;
}
.seo-inner h2 { font-size: 24px; color: #14231b; margin-bottom: 14px; }
.seo-inner h3 { font-size: 18px; color: var(--gold-text); margin: 24px 0 12px; }
.seo-inner p { color: #45564d; font-size: 14.5px; margin-bottom: 14px; }
.seo-inner strong { color: #16231c; }
.keyword-cloud { display: flex; flex-wrap: wrap; gap: 9px; }
.keyword-cloud span {
    font-size: 12.5px; font-weight: 600; color: #40514a;
    background: #fff; border: 1px solid var(--border);
    padding: 6px 13px; border-radius: 999px;
}

/* ============ FAQ ============ */
.faq-section { padding: 20px 22px 40px; }
.faq-inner { max-width: 820px; margin: 0 auto; }
.faq-inner .section-title { margin-bottom: 22px; }
.faq { display: flex; flex-direction: column; gap: 12px; }
.faq-item {
    background: var(--surface); border: 1px solid var(--border);
    border-radius: 14px; overflow: hidden; box-shadow: var(--shadow);
}
.faq-q {
    width: 100%; background: transparent; border: none; cursor: pointer;
    font-family: inherit; color: #16231c; font-size: 15.5px; font-weight: 700;
    text-align: left; padding: 18px 20px;
    display: flex; align-items: center; justify-content: space-between; gap: 14px;
}
.faq-q i { color: var(--gold); transition: transform 0.25s; flex-shrink: 0; }
.faq-item.open .faq-q i { transform: rotate(45deg); }
.faq-a { max-height: 0; overflow: hidden; transition: max-height 0.3s ease; }
.faq-item.open .faq-a { max-height: 240px; }
.faq-a p { color: #526158; font-size: 14px; padding: 0 20px 18px; }

/* ============ FOOTER ============ */
.site-footer { background: var(--surface-2); border-top: 1px solid var(--border); margin-top: 20px; }
.footer-inner {
    max-width: 1200px; margin: 0 auto; padding: 44px 22px 26px;
    display: grid; grid-template-columns: 1.4fr 1fr 1.2fr 1fr; gap: 30px;
}
.footer-brand { margin-bottom: 14px; }
.footer-col h3 { color: #16231c; font-size: 15px; margin-bottom: 14px; }
.footer-col p { color: var(--muted); font-size: 13.5px; margin-bottom: 8px; line-height: 1.7; }
.footer-col a { display: block; color: #45564d; font-size: 13.5px; margin-bottom: 9px; transition: color 0.15s; }
.footer-col a:hover { color: var(--gold-text); }
.footer-col i { color: var(--gold); margin-right: 6px; }
.footer-bottom {
    border-top: 1px solid var(--border); text-align: center;
    padding: 18px; font-size: 12.5px; color: #8a988f;
}

/* ============ FLOATING BUTTONS ============ */
.floating {
    position: fixed; right: 20px; bottom: 20px;
    display: flex; flex-direction: column; align-items: flex-end; gap: 12px; z-index: 70;
}
.float-badge {
    background: linear-gradient(100deg, var(--gold), var(--gold-2)); color: #3d2c04;
    font-size: 13.5px; font-weight: 800; padding: 8px 14px; border-radius: 20px;
    box-shadow: 0 8px 18px rgba(234, 179, 8, 0.35);
    display: flex; align-items: center; gap: 6px;
}
.float-tg {
    width: 54px; height: 54px; border-radius: 50%;
    background: #2aabee; color: #fff; font-size: 26px;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 8px 20px rgba(42, 171, 238, 0.42); transition: transform 0.15s;
}
.float-tg:hover { transform: scale(1.08); }

/* ============ ANIMATION ============ */
@keyframes fadeUp { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: translateY(0); } }

/* ============ RESPONSIVE ============ */
@media (max-width: 980px) {
    .footer-inner { grid-template-columns: 1fr 1fr; gap: 26px; }
}
@media (max-width: 820px) {
    .menu-toggle { display: block; }
    .site-nav {
        position: absolute; top: 100%; left: 0; right: 0;
        flex-direction: column; align-items: stretch; gap: 4px;
        background: #fff; backdrop-filter: blur(14px);
        border-bottom: 1px solid var(--border);
        box-shadow: 0 12px 24px rgba(20, 45, 30, 0.08);
        padding: 10px 16px; max-height: 0; overflow: hidden;
        transition: max-height 0.3s ease, padding 0.3s ease;
    }
    .site-nav:not(.open) { padding-top: 0; padding-bottom: 0; }
    .site-nav.open { max-height: 400px; }
    .nav-link { padding: 12px 14px; }
    .hero-title { font-size: 32px; }
    .hero-stats { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
    .brand-title { font-size: 16px; }
    .hero { padding: 40px 18px 26px; }
    .hero-title { font-size: 27px; }
    .hero-sub { font-size: 14.5px; }
    .section-title { font-size: 23px; }
    .game-grid { grid-template-columns: 1fr; }
    .seo-inner { padding: 24px 20px; }
    .footer-inner { grid-template-columns: 1fr; }
}
/* Phones (portrait): stack the Download button full-width for a bigger tap target */
@media (max-width: 520px) {
    .game-card { flex-wrap: wrap; padding: 16px; gap: 13px; }
    .game-info { flex-basis: calc(100% - 75px); }
    .download-btn { width: 100%; justify-content: center; margin-top: 4px; padding: 13px 22px; }
    .game-name { font-size: 16.5px; padding-right: 66px; }  /* clear the corner badge */
}
@media (max-width: 440px) {
    .stat b { font-size: 18px; }
    .stat span { font-size: 10.5px; }
    .hero-eyebrow { font-size: 11px; padding: 6px 12px; }
}
