/*
Theme Name: Moban 8-2-15
Description: Chủ đề WordPress tùy chỉnh cho cổng thông tin game Bầu Cua Tôm Cá (Hoo Hey How) – landing page xanh dương trắng kiểu màn hình chia đôi, tối ưu SEO.
Version: 1.0
Author: Moban82
Text Domain: moban82
*/

/* Google Fonts (Montserrat + Be Vietnam Pro) are enqueued in functions.php — no @import here. */

/* ============================================================
   1. Design tokens
   ============================================================ */
:root {
  --brand-primary: #2563eb;
  --brand-primary-deep: #1e40af;
  --brand-ink: #0f1f44;
  --brand-accent: #f59e0b;
  --bg: #ffffff;
  --bg-blue: #eef4ff;
  --surface: #ffffff;
  --text: #33415c;
  --text-muted: #6b7a99;
  --line: #dbe4f5;
  --radius: 4px;
  --radius-sm: 3px;
  --shadow: 0 16px 34px rgba(37, 99, 235, 0.12);
  --font-display: 'Montserrat', 'Be Vietnam Pro', sans-serif;
  --font-body: 'Be Vietnam Pro', 'Segoe UI', sans-serif;
  --wrap: 1180px;
}

/* ============================================================
   2. Reset & base
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  color: var(--text);
  background-color: var(--bg);
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--brand-primary); text-decoration: none; transition: color 0.25s ease; }
a:hover { color: var(--brand-primary-deep); }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 800;
  line-height: 1.24;
  color: var(--brand-ink);
  margin: 0 0 0.6em;
  text-transform: none;
}

h1 { font-size: clamp(1.8rem, 4.4vw, 2.8rem); letter-spacing: -0.02em; }
h2 { font-size: clamp(1.35rem, 3.2vw, 1.95rem); }
h3 { font-size: clamp(1.05rem, 2.3vw, 1.25rem); }

p { margin: 0 0 1.2em; }

.wrap { width: min(var(--wrap), 92%); margin-inline: auto; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* ============================================================
   3. Header: compact bar + TOC strip
   ============================================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: var(--brand-ink);
}

.site-header__inner {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.6rem 0;
}

.site-brand { display: flex; align-items: center; gap: 0.6rem; margin-right: auto; }

.site-brand__logo { width: 42px; height: 42px; border-radius: var(--radius); border: 2px solid var(--brand-accent); }

.site-brand__name {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1rem;
  color: #fff;
  line-height: 1.1;
}

.site-brand__tag {
  display: block;
  font-size: 0.6rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #9db4e8;
}

.site-nav { display: none; }

.site-nav__list {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-nav__link {
  display: block;
  padding: 0.55rem 0.85rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.9rem;
  color: #dbe6ff;
  border-left: 3px solid transparent;
  transition: color 0.25s ease, border-color 0.25s ease;
}

.site-nav__link:hover,
.site-nav__link:focus { color: #fff; border-left-color: var(--brand-accent); }

.nav-toggle {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px; height: 44px;
  padding: 12px;
  background: transparent;
  border: 1px solid rgba(219, 230, 255, 0.4);
  border-radius: var(--radius-sm);
  cursor: pointer;
}

.nav-toggle__bar {
  display: block;
  width: 100%; height: 2px;
  border-radius: 2px;
  background: #fff;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.site-nav.is-open {
  display: block;
  position: absolute;
  top: 100%;
  left: 0; right: 0;
  background: var(--brand-ink);
  border-bottom: 3px solid var(--brand-accent);
  padding: 0.5rem 4% 1rem;
  box-shadow: var(--shadow);
}

.toc-strip {
  background: var(--brand-primary);
  border-top: 1px solid rgba(255, 255, 255, 0.18);
}

.toc-strip__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem 1.4rem;
  padding: 0.5rem 0;
}

.toc-strip__label {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.72rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.75);
}

.toc-strip__link {
  font-size: 0.86rem;
  font-weight: 600;
  color: #fff;
  padding: 0.2rem 0;
  border-bottom: 2px solid transparent;
  transition: border-color 0.2s ease;
}

.toc-strip__link:hover { color: #fff; border-bottom-color: var(--brand-accent); }

@media (min-width: 1000px) {
  .site-nav { display: block; }
  .nav-toggle { display: none; }
  .site-nav__list { flex-direction: row; gap: 0.2rem; }
  .site-nav__link { border-left: 0; border-bottom: 3px solid transparent; }
  .site-nav__link:hover, .site-nav__link:focus { border-bottom-color: var(--brand-accent); }
}

/* ============================================================
   4. Split screen
   ============================================================ */
.split {
  display: grid;
  grid-template-columns: 1fr;
}

@media (min-width: 980px) {
  .split { grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); }
}

.split-panel {
  background:
    radial-gradient(ellipse 70% 42% at 100% 0%, rgba(245, 158, 11, 0.22), transparent 62%),
    linear-gradient(168deg, var(--brand-primary), var(--brand-primary-deep) 70%, var(--brand-ink));
  color: #fff;
}

@media (min-width: 980px) {
  .split-panel {
    position: sticky;
    top: 96px;
    align-self: start;
    height: calc(100vh - 96px);
    overflow-y: auto;
  }
}

.split-panel__inner { padding: 3rem clamp(1.4rem, 4vw, 3.4rem) 3.2rem; }

.split-panel__logo {
  width: 84px; height: 84px;
  border-radius: var(--radius);
  border: 3px solid rgba(255, 255, 255, 0.85);
  margin-bottom: 1.4rem;
}

.split-panel__title { color: #fff; margin-bottom: 0.7rem; }

.split-panel__lead { color: #cdd9f6; font-size: 1rem; max-width: 48ch; }

.split-panel__stats {
  margin: 2rem 0 0;
  display: grid;
  gap: 0.9rem;
}

.split-panel__stats div {
  border-left: 3px solid var(--brand-accent);
  padding-left: 0.9rem;
}

.split-panel__stats dt {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #ffd58a;
}

.split-panel__stats dd { margin: 0.1rem 0 0; color: #e6edff; font-size: 0.92rem; }

.split-content { background: var(--bg); }

.split-section {
  padding: 3rem clamp(1.4rem, 4vw, 3.2rem);
  border-bottom: 1px solid var(--line);
}

.split-kicker {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.72rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--brand-primary);
  margin-bottom: 0.7rem;
}

.split-title { position: relative; }

.split-lead { color: var(--text-muted); max-width: 60ch; }

/* Feature lines */
.feat-rows { display: grid; gap: 1.2rem; margin-top: 1.6rem; }

.feat-line {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 1.1rem;
  align-items: center;
  background: var(--bg-blue);
  border: 1px solid var(--line);
  border-left: 4px solid var(--brand-primary);
  border-radius: var(--radius);
  padding: 1rem 1.2rem;
}

.feat-line img { width: 96px; height: 96px; object-fit: cover; border-radius: var(--radius-sm); }

.feat-line__title { font-size: 1.02rem; margin-bottom: 0.25rem; }
.feat-line__text { margin: 0; font-size: 0.92rem; color: var(--text-muted); }

/* Rule steps */
.rule-steps {
  margin: 1.6rem 0 0;
  padding: 0;
  list-style: none;
  counter-reset: rule;
  display: grid;
  gap: 1rem;
}

.rule-step {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.2rem 1.3rem;
  box-shadow: var(--shadow);
}

.rule-step__tag {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #fff;
  background: var(--brand-primary);
  padding: 0.25rem 0.7rem;
  border-radius: var(--radius-sm);
  margin-bottom: 0.55rem;
}

.rule-step__title { font-size: 1.04rem; margin-bottom: 0.3rem; }
.rule-step__text { margin: 0; font-size: 0.92rem; color: var(--text-muted); }

/* Symbol tiles */
.symbol-tiles {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(3, 1fr);
  margin: 1.8rem 0 0;
  padding: 0;
  list-style: none;
}

@media (min-width: 700px) { .symbol-tiles { grid-template-columns: repeat(6, 1fr); } }

.symbol-tile {
  text-align: center;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.9rem 0.5rem;
  background: var(--bg-blue);
}

.symbol-tile img { width: 64px; height: 64px; margin: 0 auto 0.5rem; border-radius: var(--radius-sm); object-fit: cover; }

.symbol-tile__name {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.9rem;
  color: var(--brand-primary-deep);
}

/* Notes */
.note-lines { margin: 1.4rem 0 0; padding: 0; list-style: none; display: grid; gap: 0.6rem; }

.note-lines__item {
  padding: 0.8rem 1rem 0.8rem 2.6rem;
  position: relative;
  background: #fff8ec;
  border: 1px solid #f5e2bd;
  border-radius: var(--radius);
  font-size: 0.92rem;
}

.note-lines__item::before {
  content: '→';
  position: absolute;
  left: 1rem;
  color: var(--brand-accent);
  font-weight: 700;
}

.split-cta {
  margin-top: 2.2rem;
  padding: 2rem 1.6rem;
  text-align: center;
  background: var(--bg-blue);
  border: 2px solid var(--brand-primary);
  border-radius: var(--radius);
}

/* ============================================================
   5. CTA button
   ============================================================ */
.cta-btn {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.98rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--brand-ink);
  background: var(--brand-accent);
  border-radius: var(--radius-sm);
  padding: 0.9rem 2.3rem;
  box-shadow: 0 10px 24px rgba(245, 158, 11, 0.35);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.cta-btn:hover,
.cta-btn:focus {
  color: var(--brand-ink);
  transform: translateY(-2px);
  box-shadow: 0 16px 34px rgba(245, 158, 11, 0.48);
}

.cta-btn--block { display: block; width: max-content; margin-inline: auto; }

/* ============================================================
   6. Breadcrumbs
   ============================================================ */
.breadcrumbs { padding: 1rem 0 0; font-size: 0.85rem; }

.breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--text-muted);
}

.breadcrumbs li + li::before { content: '›'; margin-right: 0.4rem; color: var(--brand-primary); }
.breadcrumbs a { color: var(--text-muted); }
.breadcrumbs a:hover { color: var(--brand-primary); }
.breadcrumbs [aria-current="page"] { color: var(--brand-primary); }

/* ============================================================
   7. Archive: numbered landing cards
   ============================================================ */
.page-head {
  background: linear-gradient(160deg, var(--brand-ink), var(--brand-primary-deep));
  color: #fff;
  padding: 2.6rem 0 2.2rem;
}

.page-head h1 { color: #fff; }
.page-head p { color: #cdd9f6; }

.page-head .cat-label {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--brand-ink);
  background: var(--brand-accent);
  padding: 0.3rem 0.9rem;
  border-radius: var(--radius-sm);
  margin-bottom: 0.8rem;
}

.post-board {
  display: grid;
  gap: 1.4rem;
  grid-template-columns: 1fr;
  padding: 2rem 0 3rem;
}

@media (min-width: 680px) { .post-board { grid-template-columns: repeat(2, 1fr); } }

.board-card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 5px solid var(--brand-primary);
  border-radius: var(--radius);
  padding: 1.5rem 1.4rem 1.6rem;
  box-shadow: var(--shadow);
  transition: transform 0.25s ease;
}

.board-card:hover { transform: translateY(-5px); }

.board-card__media { display: block; margin-bottom: 1rem; }
.board-card__media img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--radius-sm); }

.board-card__title { font-size: 1.08rem; margin-bottom: 0.4rem; }
.board-card__title a { color: var(--brand-ink); }
.board-card__title a:hover { color: var(--brand-primary); }

.board-card__excerpt { font-size: 0.9rem; color: var(--text-muted); margin-bottom: 0.8rem; }

.board-card__meta { margin: 0; font-size: 0.78rem; color: var(--brand-primary); font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }

.empty-state { text-align: center; padding: 4rem 1rem; color: var(--text-muted); }

/* Pagination */
.pagination, .nav-links {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  padding: 0.5rem 0 3rem;
}

.page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px; height: 42px;
  padding: 0 0.7rem;
  border: 2px solid var(--line);
  border-radius: var(--radius-sm);
  color: var(--brand-ink);
  font-weight: 700;
  background: var(--surface);
}

.page-numbers.current { background: var(--brand-primary); border-color: var(--brand-primary); color: #fff; }
.page-numbers:hover { border-color: var(--brand-primary); color: var(--brand-primary); }
.page-numbers.current:hover { color: #fff; }

/* ============================================================
   8. Single post
   ============================================================ */
.single-head { padding: 2.4rem 0 1.2rem; border-bottom: 4px solid var(--brand-primary); margin-bottom: 1.6rem; }

.single-head .cat-chip {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--brand-ink);
  background: var(--brand-accent);
  padding: 0.28rem 0.85rem;
  border-radius: var(--radius-sm);
  margin-bottom: 0.8rem;
}

.single-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.4rem;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 1.4rem;
}

.entry-content { max-width: 780px; }

.entry-content img { border-radius: var(--radius-sm); }
.entry-content h2, .entry-content h3 { margin-top: 1.8em; }

.entry-content blockquote {
  margin: 1.6em 0;
  padding: 1rem 1.4rem;
  border-left: 5px solid var(--brand-primary);
  background: var(--bg-blue);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-style: italic;
}

.bottom-cta {
  margin: 2.6rem auto 3rem;
  max-width: 780px;
  padding: 2rem 1.8rem;
  background: linear-gradient(140deg, var(--brand-ink), var(--brand-primary-deep));
  border-radius: var(--radius);
  color: #fff;
  text-align: center;
}

.bottom-cta h2 { color: #fff; }
.bottom-cta p { color: #cdd9f6; }

.related-block { padding: 0 0 3rem; }

.related-strip {
  display: grid;
  gap: 1.2rem;
  grid-template-columns: 1fr;
  margin-top: 1.5rem;
}

@media (min-width: 860px) { .related-strip { grid-template-columns: repeat(3, 1fr); } }

.related-chip {
  background: var(--bg-blue);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.1rem 1.2rem;
}

.related-chip__title { font-family: var(--font-display); font-weight: 800; font-size: 0.98rem; margin: 0 0 0.4rem; }
.related-chip__title a { color: var(--brand-ink); }
.related-chip__title a:hover { color: var(--brand-primary); }

.related-chip__date { font-size: 0.76rem; color: var(--text-muted); }

/* ============================================================
   9. Footer
   ============================================================ */
.site-footer {
  background: var(--brand-ink);
  color: #b9c6e4;
  padding: 2.8rem 0 1.6rem;
  text-align: center;
  border-top: 4px solid var(--brand-accent);
}

.site-footer__nav ul {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.4rem 1.6rem;
  margin: 0 0 1.6rem;
  padding: 0;
  list-style: none;
}

.site-footer__nav a { color: #b9c6e4; font-size: 0.92rem; font-weight: 600; }
.site-footer__nav a:hover { color: var(--brand-accent); }

.site-footer__badge { margin: 1.4rem 0; }

.site-footer__disclaimer {
  max-width: 720px;
  margin: 1.2rem auto 0;
  font-size: 0.82rem;
  line-height: 1.8;
  color: #8fa0c6;
}

.site-footer__disclaimer p { margin: 0.3em 0; }

.site-footer__copy { margin-top: 1.4rem; font-size: 0.78rem; color: rgba(143, 160, 198, 0.7); }

/* ============================================================
   10. Motion & a11y
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
}

:focus-visible { outline: 2px solid var(--brand-accent); outline-offset: 3px; }
