/* ============================================================
   MOBAN 8-10-34 — App Shell Mobile-First
   Crimson #A31621 · Cream #F8F3E6 · Dark gray body
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Be+Vietnam+Pro:wght@400;500;600;700;800&display=swap');

/* ---------- Global guards ---------- */
html, body { overflow-x: hidden; }
*, *::before, *::after { box-sizing: border-box; }

:root {
    --crimson: #A31621;
    --crimson-dark: #7d1019;
    --crimson-light: #c73a45;
    --cream: #F8F3E6;
    --cream-soft: #FFFDF6;
    --ink: #2b2726;
    --ink-soft: #5c554f;
    --line: rgba(163, 22, 33, 0.14);
    --gold: #d9a441;
    --radius: 10px;
    --radius-lg: 16px;
    --shadow-sm: 0 1px 3px rgba(43, 39, 38, 0.08);
    --shadow-md: 0 6px 18px rgba(163, 22, 33, 0.10);
    --shadow-lg: 0 12px 32px rgba(43, 39, 38, 0.14);
    --tabbar-h: 64px;
    --font: 'Be Vietnam Pro', 'Roboto', system-ui, -apple-system, sans-serif;
}

body {
    margin: 0;
    background: var(--cream);
    color: var(--ink);
    font-family: var(--font);
    font-size: 15px;
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    padding-bottom: 76px;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--crimson); text-decoration: none; transition: color .2s ease; }
a:hover { color: var(--crimson-light); }
h1, h2, h3, h4 { margin: 0 0 .5em; line-height: 1.25; font-weight: 800; color: var(--ink); }
p { margin: 0 0 1em; }
button { font-family: inherit; cursor: pointer; }

.container { max-width: 1080px; margin: 0 auto; padding: 0 16px; }
.container-narrow { max-width: 760px; }

/* ---------- Top bar ---------- */
.app-topbar {
    position: sticky; top: 0; z-index: 60;
    background: linear-gradient(135deg, var(--crimson) 0%, var(--crimson-dark) 100%);
    box-shadow: var(--shadow-md);
}
.topbar-inner {
    max-width: 1080px; margin: 0 auto; padding: 10px 16px;
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.topbar-logo img { height: 40px; width: auto; }
.topbar-actions { display: flex; gap: 8px; }
.btn-topbar {
    display: inline-block; padding: 8px 14px; border-radius: 999px;
    font-size: 13px; font-weight: 700; white-space: nowrap; transition: all .2s ease;
}
.btn-login { color: #fff; border: 1.5px solid rgba(255,255,255,.5); background: transparent; }
.btn-login:hover { background: rgba(255,255,255,.14); color: #fff; }
.btn-register { background: var(--cream); color: var(--crimson); border: 1.5px solid var(--cream); }
.btn-register:hover { background: #fff; transform: translateY(-1px); }

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    padding: 13px 24px; border-radius: var(--radius); font-weight: 700;
    font-size: 15px; border: none; transition: all .22s ease;
}
.btn-primary { background: var(--crimson); color: #fff; box-shadow: 0 4px 14px rgba(163,22,33,.32); }
.btn-primary:hover { background: var(--crimson-dark); color: #fff; transform: translateY(-2px); box-shadow: 0 8px 20px rgba(163,22,33,.4); }
.btn-ghost { background: transparent; color: var(--crimson); border: 1.5px solid var(--crimson); }
.btn-ghost:hover { background: rgba(163,22,33,.07); }
.btn-download { font-size: 16px; }

/* ---------- Section heads ---------- */
.section-head {
    display: flex; align-items: center; justify-content: space-between;
    gap: 12px; margin-bottom: 16px;
}
.section-title {
    display: flex; align-items: center; gap: 10px;
    font-size: 20px; margin: 0;
}
.title-dot {
    width: 8px; height: 22px; border-radius: 4px;
    background: linear-gradient(180deg, var(--crimson-light), var(--crimson));
    flex-shrink: 0;
}
.link-more { font-size: 13px; font-weight: 600; color: var(--crimson); white-space: nowrap; }
.notice-count {
    background: var(--crimson); color: #fff; font-size: 12px; font-weight: 700;
    padding: 3px 10px; border-radius: 999px;
}

/* ---------- App hero ---------- */
.app-hero { padding: 20px 0 8px; }
.app-hero-grid {
    display: grid; gap: 16px;
    grid-template-columns: 1fr;
    grid-template-areas: "card" "banner";
}
.app-hero-card {
    grid-area: card; background: var(--cream-soft);
    border: 1px solid var(--line); border-radius: var(--radius-lg);
    padding: 22px; box-shadow: var(--shadow-lg);
    position: relative; overflow: hidden;
}
.app-hero-card::before {
    content: ""; position: absolute; top: -60px; right: -60px;
    width: 180px; height: 180px; border-radius: 50%;
    background: radial-gradient(circle, rgba(163,22,33,.12), transparent 70%);
}
.app-hero-tag {
    display: inline-block; background: var(--crimson); color: #fff;
    font-size: 11px; font-weight: 800; letter-spacing: .05em;
    padding: 4px 12px; border-radius: 999px; text-transform: uppercase; margin-bottom: 14px;
}
.app-hero-row { display: flex; gap: 16px; align-items: flex-start; }
.app-hero-icon {
    width: 68px; height: 68px; border-radius: var(--radius-lg);
    background: var(--cream); border: 1px solid var(--line);
    display: flex; align-items: center; justify-content: center;
    overflow: hidden; flex-shrink: 0; box-shadow: var(--shadow-sm);
}
.app-hero-icon img { width: 100%; height: 100%; object-fit: contain; padding: 8px; }
.app-hero-name { font-size: 22px; margin: 0 0 4px; }
.app-hero-meta { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--ink-soft); margin-bottom: 8px; }
.app-rating { color: var(--gold); font-weight: 800; }
.app-hero-desc { font-size: 14px; color: var(--ink-soft); margin: 0; }
.app-hero-actions { display: flex; gap: 10px; flex-wrap: wrap; margin: 18px 0; }
.app-hero-stats {
    display: flex; border-top: 1px dashed var(--line); padding-top: 16px; gap: 8px;
}
.stat { flex: 1; text-align: center; }
.stat b { display: block; font-size: 18px; color: var(--crimson); font-weight: 800; }
.stat span { font-size: 12px; color: var(--ink-soft); }
.app-hero-banner { grid-area: banner; }

/* ---------- Banner slider ---------- */
.banner-slider {
    position: relative; border-radius: var(--radius-lg); overflow: hidden;
    box-shadow: var(--shadow-md); aspect-ratio: 16 / 8; background: var(--cream-soft);
}
.banner-slide { position: absolute; inset: 0; opacity: 0; transition: opacity .6s ease; }
.banner-slide.is-active { opacity: 1; }
.banner-slide img { width: 100%; height: 100%; object-fit: cover; }
.banner-dots {
    position: absolute; bottom: 10px; left: 50%; transform: translateX(-50%);
    display: flex; gap: 6px; z-index: 2;
}
.banner-dots button {
    width: 8px; height: 8px; border-radius: 50%; border: none;
    background: rgba(255,255,255,.5); padding: 0; transition: all .2s;
}
.banner-dots button.is-active { background: #fff; width: 20px; border-radius: 4px; }

/* ---------- Notice feed ---------- */
.notice-section { padding: 20px 0; }
.notice-feed { display: grid; gap: 12px; }
.notice-item {
    display: flex; gap: 14px; align-items: flex-start;
    background: var(--cream-soft); border: 1px solid var(--line);
    border-radius: var(--radius); padding: 16px; color: inherit;
    transition: all .22s ease; position: relative;
}
.notice-item:hover { border-color: var(--crimson-light); box-shadow: var(--shadow-md); transform: translateY(-2px); }
.notice-ico {
    position: relative; width: 44px; height: 44px; border-radius: var(--radius);
    background: var(--cream); display: flex; align-items: center; justify-content: center;
    font-size: 20px; flex-shrink: 0;
}
.notice-body { flex: 1; min-width: 0; }
.notice-title { font-size: 15px; margin: 0 0 4px; }
.notice-excerpt { font-size: 13px; color: var(--ink-soft); margin: 0; }
.notice-time { font-size: 12px; color: var(--ink-soft); white-space: nowrap; flex-shrink: 0; }

/* ---------- Badges ---------- */
.badge-dot, .tab-badge {
    position: absolute; top: -6px; right: -6px;
    min-width: 18px; height: 18px; padding: 0 4px;
    border-radius: 999px; background: var(--crimson); color: #fff;
    font-size: 10px; font-weight: 800; font-style: normal;
    display: flex; align-items: center; justify-content: center;
    border: 2px solid var(--cream); box-sizing: content-box;
    animation: badgePulse 2.4s ease-in-out infinite;
}
@keyframes badgePulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.12); }
}

/* ---------- Games ---------- */
.games-section { padding: 20px 0; }
.game-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.game-card { display: block; color: inherit; }
.game-thumb {
    position: relative; border-radius: var(--radius); overflow: hidden;
    border: 1px solid var(--line); box-shadow: var(--shadow-sm); aspect-ratio: 1 / 1;
}
.game-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.game-card:hover .game-thumb img { transform: scale(1.06); }
.game-flag {
    position: absolute; top: 8px; left: 8px; background: var(--crimson); color: #fff;
    font-size: 10px; font-weight: 800; padding: 3px 8px; border-radius: 999px; letter-spacing: .03em;
}
.game-meta { display: flex; align-items: center; justify-content: space-between; padding: 8px 2px 0; gap: 6px; }
.game-meta h3 { font-size: 13px; margin: 0; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.game-star { color: var(--gold); font-size: 12px; font-weight: 700; white-space: nowrap; }

/* ---------- Promo strip ---------- */
.promo-strip { padding: 12px 0 20px; }
.promo-scroll {
    display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory;
    padding-bottom: 6px; -webkit-overflow-scrolling: touch;
}
.promo-scroll::-webkit-scrollbar { display: none; }
.promo-card {
    flex: 0 0 68%; scroll-snap-align: start; border-radius: var(--radius-lg);
    overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow-sm);
}
.promo-card img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }

/* ---------- News list ---------- */
.news-section, .related-section { padding: 8px 0 20px; }
.news-list { display: grid; gap: 12px; }
.news-item {
    background: var(--cream-soft); border: 1px solid var(--line);
    border-radius: var(--radius); overflow: hidden; transition: all .22s ease;
}
.news-item:hover { border-color: var(--crimson-light); box-shadow: var(--shadow-md); }
.news-link { display: flex; gap: 14px; padding: 12px; color: inherit; align-items: center; }
.news-thumb {
    width: 110px; height: 82px; border-radius: 8px; overflow: hidden;
    flex-shrink: 0; background: var(--cream);
}
.news-thumb img { width: 100%; height: 100%; object-fit: cover; }
.news-body { min-width: 0; }
.news-title { font-size: 15px; margin: 0 0 4px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.news-excerpt { font-size: 13px; color: var(--ink-soft); margin: 0 0 4px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.news-date { font-size: 12px; color: var(--ink-soft); }
.empty-note { color: var(--ink-soft); padding: 30px 0; text-align: center; }

/* ---------- Accordion / FAQ ---------- */
.faq-section { padding: 8px 0 24px; }
.accordion { display: grid; gap: 10px; }
.accordion-item {
    background: var(--cream-soft); border: 1px solid var(--line);
    border-radius: var(--radius); overflow: hidden; transition: border-color .2s;
}
.accordion-item.is-open { border-color: var(--crimson); }
.accordion-head {
    width: 100%; background: none; border: none; text-align: left;
    padding: 16px; font-size: 15px; font-weight: 700; color: var(--ink);
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.accordion-plus {
    position: relative; width: 22px; height: 22px; flex-shrink: 0;
    transition: transform .3s ease;
}
.accordion-plus::before, .accordion-plus::after {
    content: ""; position: absolute; top: 50%; left: 50%; background: var(--crimson);
    border-radius: 2px; transform: translate(-50%, -50%);
}
.accordion-plus::before { width: 14px; height: 2px; }
.accordion-plus::after { width: 2px; height: 14px; transition: transform .3s ease; }
.accordion-item.is-open .accordion-plus { transform: rotate(180deg); }
.accordion-item.is-open .accordion-plus::after { transform: translate(-50%,-50%) scaleY(0); }
.accordion-body { max-height: 0; overflow: hidden; transition: max-height .35s ease; }
.accordion-body p { padding: 0 16px 16px; margin: 0; color: var(--ink-soft); font-size: 14px; }

/* ---------- CTA ---------- */
.cta-section { padding: 8px 0 32px; }
.cta-card {
    background: linear-gradient(135deg, var(--crimson) 0%, var(--crimson-dark) 100%);
    color: #fff; text-align: center; border-radius: var(--radius-lg);
    padding: 34px 20px; box-shadow: var(--shadow-lg);
}
.cta-title { color: #fff; font-size: 22px; }
.cta-desc { color: rgba(255,255,255,.85); margin-bottom: 20px; }
.cta-card .btn-primary { background: var(--cream); color: var(--crimson); box-shadow: 0 6px 18px rgba(0,0,0,.25); }
.cta-card .btn-primary:hover { background: #fff; }

/* ---------- Pages / single ---------- */
.page-wrap { padding: 20px 0 32px; }
.page-hero { margin-bottom: 20px; }
.page-title { font-size: 24px; margin: 0 0 6px; }
.page-sub { color: var(--ink-soft); margin: 0; font-size: 14px; }
.single-card {
    background: var(--cream-soft); border: 1px solid var(--line);
    border-radius: var(--radius-lg); padding: 22px; box-shadow: var(--shadow-md);
}
.single-title { font-size: 24px; }
.single-meta { display: flex; gap: 16px; font-size: 13px; color: var(--ink-soft); margin-bottom: 16px; flex-wrap: wrap; }
.single-thumb { border-radius: var(--radius); overflow: hidden; margin-bottom: 18px; }
.single-content { font-size: 15px; }
.single-content img { border-radius: var(--radius); }
.single-tags { margin: 18px 0; font-size: 13px; color: var(--ink-soft); }
.single-tags a { background: var(--cream); border: 1px solid var(--line); padding: 4px 10px; border-radius: 999px; font-size: 12px; }
.single-cta {
    background: var(--cream); border: 1px dashed var(--crimson-light);
    border-radius: var(--radius); padding: 18px; text-align: center; margin-top: 12px;
}
.single-cta p { margin-bottom: 12px; }
.post-nav { display: flex; justify-content: space-between; gap: 12px; margin: 20px 0; font-size: 14px; }
.post-nav-item { flex: 1; }
.post-nav-item:last-child { text-align: right; }
.pagination-bar { margin-top: 24px; text-align: center; }
.pagination-bar .nav-links { display: flex; gap: 6px; justify-content: center; flex-wrap: wrap; }
.pagination-bar .page-numbers {
    min-width: 38px; height: 38px; display: inline-flex; align-items: center; justify-content: center;
    border-radius: 8px; border: 1px solid var(--line); background: var(--cream-soft);
    font-weight: 600; padding: 0 8px;
}
.pagination-bar .page-numbers.current { background: var(--crimson); color: #fff; border-color: var(--crimson); }

/* ---------- Footer ---------- */
.app-footer { background: #1f1a19; color: #cfc8c2; padding: 34px 0 20px; }
.footer-widgets { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-bottom: 22px; }
.app-footer .widget-title { color: #fff; font-size: 15px; }
.app-footer a { color: #cfc8c2; }
.app-footer a:hover { color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.08); padding-top: 20px; text-align: center; }
.disclaimer-text { font-size: 12.5px; line-height: 1.7; color: #a89f98; max-width: 640px; margin: 14px auto; }
.footer-copy { font-size: 12px; color: #7d756f; margin: 0; }

/* ---------- Bottom tab bar ---------- */
.tabbar {
    position: fixed; bottom: 0; left: 0; right: 0; z-index: 80;
    height: var(--tabbar-h); background: #fff;
    border-top: 1px solid var(--line);
    box-shadow: 0 -4px 20px rgba(43,39,38,.12);
    display: flex; align-items: stretch;
    padding-bottom: env(safe-area-inset-bottom);
}
.tab-item {
    flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 2px; color: var(--ink-soft); font-size: 11px; font-weight: 600;
    position: relative; padding: 6px 2px; text-align: center;
}
.tab-item:hover { color: var(--crimson); }
.tab-item.is-active { color: var(--crimson); }
.tab-item.is-active::after {
    content: ""; position: absolute; top: 0; left: 50%; transform: translateX(-50%);
    width: 34px; height: 3px; border-radius: 0 0 3px 3px; background: var(--crimson);
}
.tab-ico { position: relative; font-size: 20px; line-height: 1; display: inline-block; }
.tab-label { max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---------- Reveal ---------- */
.entry-content a { text-decoration: underline; }
