/* ==========================================================================
   GamesPoker.com — Design System
   Palette:  Baize #16302A · Baize Dark #0E211C · Parchment #F3EEDD
             Ink #201C15 · Brass #C6A15B · Rail #8A2A2A · Card #FFFDF6
   Type:     Display  — 'Fraunces'      (headlines, editorial voice)
             Body     — 'Source Sans 3' (reading copy)
             Utility  — 'IBM Plex Mono' (odds, stats, data)
   Signature: the "rank ladder" — poker hands rendered as stacked index
              cards, and suit glyphs (♠ ♥ ♦ ♣) used as structural markers.
   ========================================================================== */

:root {
  --baize: #16302A;
  --baize-dark: #0E211C;
  --baize-light: #1F4A3E;
  --parchment: #F3EEDD;
  --parchment-deep: #EAE2C9;
  --ink: #201C15;
  --ink-soft: #4A4536;
  --brass: #C6A15B;
  --brass-deep: #A2802F;
  --rail: #8A2A2A;
  --card: #FFFDF6;
  --card-border: #DFD6B8;
  --line: rgba(32, 28, 21, 0.12);

  --font-display: 'Fraunces', Georgia, 'Times New Roman', serif;
  --font-body: 'Source Sans 3', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'IBM Plex Mono', 'SFMono-Regular', Consolas, monospace;

  --radius: 6px;
  --radius-lg: 10px;
  --shadow-card: 0 1px 2px rgba(14, 33, 28, 0.06), 0 8px 24px rgba(14, 33, 28, 0.08);
  --max-width: 1160px;
}

@media (prefers-reduced-motion: no-preference) {
  :root { --transition: 180ms ease; }
}
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--parchment);
  color: var(--ink);
  line-height: 1.65;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--baize-light); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--rail); }
:focus-visible { outline: 3px solid var(--brass); outline-offset: 2px; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--baize-dark);
  font-weight: 600;
  line-height: 1.15;
  margin: 0 0 0.5em;
  letter-spacing: -0.01em;
}
h1 { font-size: clamp(2.1rem, 4vw, 3.4rem); font-weight: 500; }
h2 { font-size: clamp(1.5rem, 2.6vw, 2.1rem); }
h3 { font-size: 1.3rem; }
p { margin: 0 0 1.1em; }
.lede { font-size: 1.18rem; color: var(--ink-soft); }

.container { max-width: var(--max-width); margin: 0 auto; padding: 0 24px; }
.container--narrow { max-width: 780px; }
section { padding: 64px 0; }
section + section { border-top: 1px solid var(--line); }

/* -------------------- eyebrow / suit markers -------------------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.76rem;
  color: var(--brass-deep);
  margin-bottom: 0.9em;
}
.eyebrow .suit { font-size: 1rem; }
.suit-spade::before { content: "♠"; }
.suit-heart::before { content: "♥"; color: var(--rail); }
.suit-diamond::before { content: "♦"; color: var(--rail); }
.suit-club::before { content: "♣"; }

/* -------------------- header / nav -------------------- */
.site-header {
  background: var(--baize);
  color: var(--parchment);
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 3px solid var(--brass);
}
.site-header .container { display: flex; align-items: center; justify-content: space-between; padding-top: 14px; padding-bottom: 14px; gap: 24px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--parchment); text-decoration: none; font-family: var(--font-display); font-size: 1.32rem; font-weight: 600; }
.brand:hover { color: var(--brass); }
.brand-mark { width: 30px; height: 30px; flex-shrink: 0; }
.primary-nav { display: flex; align-items: center; gap: 4px; }
.primary-nav a {
  color: var(--parchment);
  text-decoration: none;
  font-size: 0.92rem;
  padding: 8px 12px;
  border-radius: var(--radius);
  transition: background var(--transition), color var(--transition);
  white-space: nowrap;
}
.primary-nav a:hover, .primary-nav a:focus-visible { background: rgba(243,238,221,0.12); color: var(--brass); }
.nav-search-btn {
  border: 1px solid rgba(243,238,221,0.35);
  background: transparent;
  color: var(--parchment);
  border-radius: var(--radius);
  padding: 8px 12px;
  font-family: var(--font-body);
  font-size: 0.9rem;
  cursor: pointer;
  text-decoration: none;
}
.nav-search-btn:hover { border-color: var(--brass); color: var(--brass); }
.nav-toggle { display: none; }

@media (max-width: 880px) {
  .primary-nav { display: none; }
  .nav-toggle {
    display: inline-flex; align-items: center; justify-content: center;
    background: transparent; border: 1px solid rgba(243,238,221,0.35); color: var(--parchment);
    border-radius: var(--radius); width: 40px; height: 40px; cursor: pointer;
  }
  .header-actions { display: flex; gap: 8px; align-items: center; }
  .primary-nav.is-open {
    display: flex; flex-direction: column; align-items: stretch;
    position: absolute; left: 0; right: 0; top: 100%;
    background: var(--baize-dark); padding: 8px 24px 18px; border-bottom: 3px solid var(--brass);
  }
}

/* -------------------- breadcrumbs -------------------- */
.breadcrumbs { font-size: 0.84rem; color: var(--ink-soft); padding: 14px 0 0; }
.breadcrumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; }
.breadcrumbs li:not(:last-child)::after { content: "/"; margin-left: 6px; color: var(--card-border); }
.breadcrumbs a { color: var(--ink-soft); }
.breadcrumbs [aria-current] { color: var(--ink); font-weight: 600; }

/* -------------------- hero -------------------- */
.hero { background: radial-gradient(120% 140% at 15% 0%, var(--baize-light) 0%, var(--baize) 46%, var(--baize-dark) 100%); color: var(--parchment); padding: 76px 0 88px; border-top: none; }
.hero .container { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 48px; align-items: center; }
.hero h1 { color: var(--parchment); }
.hero .lede { color: rgba(243,238,221,0.86); max-width: 46ch; }
.hero-actions { display: flex; gap: 12px; margin-top: 28px; flex-wrap: wrap; }
@media (max-width: 880px) { .hero .container { grid-template-columns: 1fr; } .hero { padding: 52px 0 60px; } }

/* -------------------- buttons -------------------- */
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 12px 22px; border-radius: var(--radius); font-weight: 600; font-size: 0.96rem; text-decoration: none; border: 1px solid transparent; cursor: pointer; transition: transform var(--transition), background var(--transition), border-color var(--transition); }
.btn:hover { transform: translateY(-1px); }
.btn-brass { background: var(--brass); color: var(--baize-dark); }
.btn-brass:hover { background: #d4b26f; color: var(--baize-dark); }
.btn-outline { background: transparent; color: var(--parchment); border-color: rgba(243,238,221,0.5); }
.btn-outline:hover { border-color: var(--brass); color: var(--brass); }
.btn-ink { background: var(--baize); color: var(--parchment); }
.btn-ink:hover { background: var(--baize-dark); color: var(--brass); }
.btn-sm { padding: 8px 14px; font-size: 0.84rem; }

/* -------------------- signature: playing-card index component -------------------- */
.card-index {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  padding: 22px 24px;
  position: relative;
}
.card-index::before {
  content: attr(data-suit);
  position: absolute;
  top: 12px; left: 14px;
  font-family: var(--font-display);
  font-size: 1.1rem;
  color: var(--brass-deep);
  opacity: 0.55;
}

.rank-ladder { display: flex; flex-direction: column; gap: 10px; }
.rank-ladder li { list-style: none; }
.rank-row {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  align-items: center;
  gap: 14px;
  background: var(--card);
  border: 1px solid var(--card-border);
  border-left: 4px solid var(--brass);
  border-radius: var(--radius);
  padding: 12px 16px;
  box-shadow: var(--shadow-card);
}
.rank-row .rank-num { font-family: var(--font-mono); color: var(--brass-deep); font-size: 0.95rem; }
.rank-row .rank-name { font-family: var(--font-display); font-weight: 600; color: var(--baize-dark); }
.rank-row .rank-ex { font-family: var(--font-mono); font-size: 0.82rem; color: var(--ink-soft); }

/* -------------------- grids / cards -------------------- */
.grid { display: grid; gap: 22px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 880px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }

.tile {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  gap: 10px;
  height: 100%;
}
.tile h3 { margin-bottom: 4px; }
.tile a.tile-link { color: var(--baize-dark); text-decoration: none; }
.tile a.tile-link:hover { color: var(--rail); }
.tile .tag { font-family: var(--font-mono); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--brass-deep); }

/* -------------------- affiliate CTA panel -------------------- */
.cta-panel {
  background: linear-gradient(135deg, var(--baize-dark), var(--baize));
  color: var(--parchment);
  border-radius: var(--radius-lg);
  padding: 30px 32px;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 20px;
  border: 1px solid var(--brass-deep);
}
.cta-panel h3 { color: var(--parchment); margin-bottom: 6px; }
.cta-panel p { color: rgba(243,238,221,0.82); margin-bottom: 0; font-size: 0.95rem; }
.cta-panel .btn { flex-shrink: 0; }
@media (max-width: 700px) { .cta-panel { grid-template-columns: 1fr; text-align: left; } }

.cta-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  background: var(--parchment-deep);
  border: 1px dashed var(--brass-deep);
  border-radius: var(--radius);
  padding: 16px 18px;
  align-items: center;
  font-size: 0.92rem;
}
.cta-strip strong { color: var(--baize-dark); }

.disclosure-note {
  font-size: 0.8rem;
  color: var(--ink-soft);
  border-top: 1px solid var(--line);
  padding-top: 10px;
  margin-top: 10px;
}

/* -------------------- room comparison table -------------------- */
.room-table { width: 100%; border-collapse: collapse; background: var(--card); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-card); }
.room-table th, .room-table td { text-align: left; padding: 14px 16px; border-bottom: 1px solid var(--card-border); font-size: 0.94rem; }
.room-table thead th { background: var(--baize); color: var(--parchment); font-family: var(--font-mono); font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.06em; }
.room-table tbody tr:last-child td { border-bottom: none; }
.room-table td.num { font-family: var(--font-mono); }
.table-scroll { overflow-x: auto; }

/* -------------------- FAQ / accordion -------------------- */
details.faq-item { background: var(--card); border: 1px solid var(--card-border); border-radius: var(--radius); padding: 6px 18px; margin-bottom: 10px; }
details.faq-item summary { cursor: pointer; font-family: var(--font-display); font-weight: 600; padding: 12px 0; color: var(--baize-dark); list-style: none; display: flex; justify-content: space-between; gap: 12px; }
details.faq-item summary::-webkit-details-marker { display: none; }
details.faq-item summary::after { content: "+"; font-family: var(--font-mono); color: var(--brass-deep); font-size: 1.2rem; }
details.faq-item[open] summary::after { content: "–"; }
details.faq-item .faq-body { padding-bottom: 14px; color: var(--ink-soft); }

/* -------------------- glossary -------------------- */
.glossary-term { font-family: var(--font-mono); background: rgba(198,161,91,0.16); padding: 1px 6px; border-radius: 4px; }

/* -------------------- meta rows -------------------- */
.meta-row { display: flex; flex-wrap: wrap; gap: 16px; font-family: var(--font-mono); font-size: 0.78rem; color: var(--ink-soft); margin-bottom: 1.6em; }
.meta-row span { display: inline-flex; align-items: center; gap: 6px; }

/* -------------------- toc -------------------- */
.toc { background: var(--parchment-deep); border-radius: var(--radius); padding: 18px 22px; margin: 1.6em 0; }
.toc p.toc-title { font-family: var(--font-mono); text-transform: uppercase; font-size: 0.75rem; letter-spacing: 0.1em; color: var(--brass-deep); margin-bottom: 8px; }
.toc ol { margin: 0; padding-left: 20px; }
.toc a { color: var(--ink); }

/* -------------------- misc content -------------------- */
.callout { border-left: 4px solid var(--brass); background: var(--parchment-deep); border-radius: 0 var(--radius) var(--radius) 0; padding: 16px 20px; margin: 1.6em 0; }
.callout--warn { border-left-color: var(--rail); }
.callout p:last-child { margin-bottom: 0; }
blockquote { border-left: 3px solid var(--card-border); margin: 1.6em 0; padding-left: 18px; color: var(--ink-soft); font-style: italic; }
hr.divider { border: none; text-align: center; margin: 3em 0; }
hr.divider::before { content: "♠ ♥ ♦ ♣"; font-family: var(--font-display); color: var(--card-border); letter-spacing: 0.6em; }
table.data-table { width: 100%; border-collapse: collapse; margin: 1.4em 0; }
table.data-table th, table.data-table td { border: 1px solid var(--card-border); padding: 10px 12px; font-size: 0.92rem; text-align: left; }
table.data-table thead th { background: var(--parchment-deep); font-family: var(--font-mono); font-size: 0.78rem; text-transform: uppercase; }

/* -------------------- related / footer -------------------- */
.related-list { display: grid; gap: 10px; }
.related-list a { display: block; background: var(--card); border: 1px solid var(--card-border); border-radius: var(--radius); padding: 12px 16px; text-decoration: none; color: var(--baize-dark); font-weight: 600; }
.related-list a:hover { border-color: var(--brass); color: var(--rail); }

.site-footer { background: var(--baize-dark); color: rgba(243,238,221,0.82); padding: 56px 0 28px; margin-top: 40px; }
.site-footer a { color: rgba(243,238,221,0.82); }
.site-footer a:hover { color: var(--brass); }
.footer-grid { display: grid; grid-template-columns: 1.4fr repeat(4, 1fr); gap: 32px; margin-bottom: 40px; }
.footer-grid h4 { color: var(--brass); font-family: var(--font-mono); font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 14px; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; font-size: 0.9rem; }
.footer-brand p { font-size: 0.88rem; color: rgba(243,238,221,0.65); max-width: 32ch; }
.footer-bottom { border-top: 1px solid rgba(243,238,221,0.14); padding-top: 22px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: 0.8rem; color: rgba(243,238,221,0.55); }
.footer-legal { font-size: 0.78rem; color: rgba(243,238,221,0.55); max-width: 900px; margin-top: 18px; line-height: 1.6; }
@media (max-width: 880px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer-grid { grid-template-columns: 1fr; } }

/* -------------------- search page -------------------- */
.search-box { display: flex; gap: 10px; margin: 1.4em 0; }
.search-box input { flex: 1; padding: 12px 16px; border: 1px solid var(--card-border); border-radius: var(--radius); font-family: var(--font-body); font-size: 1rem; background: var(--card); }
#search-results .result { padding: 14px 0; border-bottom: 1px solid var(--line); }
#search-results .result h3 { margin-bottom: 4px; font-size: 1.05rem; }
#search-results .result p { margin-bottom: 0; color: var(--ink-soft); font-size: 0.92rem; }
#search-empty { color: var(--ink-soft); font-family: var(--font-mono); font-size: 0.9rem; }

/* -------------------- 404 -------------------- */
.error-page { text-align: center; padding: 100px 0; }
.error-page .code { font-family: var(--font-mono); color: var(--brass-deep); font-size: 1rem; letter-spacing: 0.2em; }

/* -------------------- skip link / a11y -------------------- */
.skip-link { position: absolute; left: -999px; top: 0; background: var(--brass); color: var(--baize-dark); padding: 10px 16px; z-index: 100; border-radius: 0 0 var(--radius) 0; }
.skip-link:focus { left: 0; }

/* -------------------- utility -------------------- */
.mt-0 { margin-top: 0; }
.center { text-align: center; }
.stack { display: flex; flex-direction: column; gap: 14px; }
