:root {
  --paper: #fffdf7;
  --paper-warm: #f7f1e5;
  --ink: #20251f;
  --muted: #626960;
  --line: #d9d2c3;
  --green: #173f35;
  --green-2: #235f4d;
  --red: #b9212a;
  --red-dark: #7f1620;
  --gold: #c99a2e;
  --gold-soft: #f5e6b4;
  --white: #fff;
  --shadow: 0 18px 45px rgba(45, 32, 17, .11);
  --radius: 18px;
  --content: 1320px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.68;
  text-rendering: optimizeLegibility;
}

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

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

a { color: #145f91; text-underline-offset: 3px; }
a:hover { color: #0d3d5f; }

button, input { font: inherit; }
button { cursor: pointer; }

.skip-link {
  position: fixed;
  top: 8px;
  left: 8px;
  z-index: 9999;
  transform: translateY(-140%);
  padding: 10px 15px;
  border-radius: 8px;
  background: var(--white);
  color: var(--ink);
  box-shadow: var(--shadow);
}
.skip-link:focus { transform: translateY(0); }

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 253, 247, .95);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}

.topbar {
  background: var(--green);
  color: #fff;
  font-size: .82rem;
}

.topbar-inner,
.header-inner,
.page-shell,
.footer-inner,
.wide-container {
  width: min(calc(100% - 32px), var(--content));
  margin-inline: auto;
}

.topbar-inner {
  min-height: 34px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.age-note { font-weight: 750; letter-spacing: .03em; }

.top-links { display: flex; gap: 18px; }
.top-links a { color: #fff; text-decoration: none; opacity: .9; }

.header-inner {
  min-height: 74px;
  display: grid;
  grid-template-columns: auto minmax(240px, 1fr) auto;
  gap: 26px;
  align-items: center;
}

.brand { display: inline-flex; align-items: center; text-decoration: none; }
.brand img { width: 190px; height: auto; display: block; }

.primary-nav { justify-self: center; }
.primary-nav ul { margin: 0; padding: 0; display: flex; align-items: center; gap: 24px; list-style: none; }
.primary-nav a {
  color: var(--ink);
  font-size: .94rem;
  font-weight: 750;
  text-decoration: none;
}
.primary-nav a[aria-current="page"], .primary-nav a:hover { color: var(--red); }

.header-actions { display: flex; align-items: center; gap: 10px; }
.icon-button,
.menu-toggle {
  min-width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--white);
  color: var(--green);
  display: inline-grid;
  place-items: center;
  font-weight: 900;
}
.icon-button {
  position: relative;
  width: 52px;
  min-width: 52px;
  height: 52px;
  padding: 0;
  font-size: 0;
  box-shadow: 0 7px 18px rgba(23,63,53,.09);
  transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease, background .16s ease;
}
.icon-button::before {
  content: "";
  width: 17px;
  height: 17px;
  border: 2.2px solid currentColor;
  border-radius: 50%;
  transform: translate(-1px, -1px);
}
.icon-button::after {
  content: "";
  position: absolute;
  width: 9px;
  height: 2.2px;
  border-radius: 999px;
  background: currentColor;
  transform: translate(8px, 8px) rotate(45deg);
  transform-origin: center;
}
.icon-button:hover {
  transform: translateY(-2px);
  border-color: #bda969;
  background: #fffdf5;
  box-shadow: 0 10px 24px rgba(23,63,53,.14);
}
.menu-toggle { display: none; }

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 46px;
  padding: 11px 18px;
  border: 1px solid transparent;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 800;
  line-height: 1.2;
  transition: transform .16s ease, box-shadow .16s ease, background .16s ease;
}
.button:hover { transform: translateY(-2px); }
.button-primary { background: var(--red); color: #fff; box-shadow: 0 10px 22px rgba(185, 33, 42, .24); }
.button-primary:hover { color: #fff; background: var(--red-dark); }
.button-secondary { background: var(--gold-soft); color: #312713; border-color: #e1c86f; }
.button-secondary:hover { color: #161108; background: #f1d985; }
.button-ghost { color: var(--green); background: #fff; border-color: var(--line); }

.independence-ribbon {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  background: linear-gradient(90deg, #941620 0%, #b9212a 50%, #941620 100%);
  color: #fff;
  border-bottom: 1px solid rgba(0, 0, 0, .1);
}

.ribbon-inner {
  width: min(calc(100% - 32px), var(--content));
  min-height: 48px;
  margin-inline: auto;
  padding-block: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  text-align: center;
  font-weight: 850;
  line-height: 1.25;
  letter-spacing: .03em;
  text-shadow: 0 1px 2px rgba(0,0,0,.28);
}

.flag-wrap {
  width: 36px;
  height: 24px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}
.flag {
  display: block;
  width: 34px;
  height: 22px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.6);
  border-radius: 2px;
  background: linear-gradient(to bottom, #df1f2d 0 50%, #fff 50% 100%);
  box-shadow: 0 3px 7px rgba(0,0,0,.18);
}
.flag::before,
.flag::after { content: none; }

.hero {
  position: relative;
  min-height: 620px;
  display: grid;
  align-items: center;
  overflow: hidden;
  background: #efe6d4;
}

.hero-media,
.hero-media::after { position: absolute; inset: 0; }
.hero-media {
  background-color: #efe6d4;
  background-image: url('../img/hero-live-roulette.webp');
  background-repeat: no-repeat;
  background-position: right center;
  background-size: auto 100%;
}
.hero-media::after {
  content: "";
  background:
    linear-gradient(90deg, rgba(255,253,247,1) 0%, rgba(255,253,247,.98) 33%, rgba(255,253,247,.88) 45%, rgba(255,253,247,.44) 58%, rgba(255,253,247,.08) 72%, rgba(255,253,247,0) 100%),
    linear-gradient(0deg, rgba(23,63,53,.13), transparent 55%);
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(calc(100% - 32px), var(--content));
  margin-inline: auto;
  padding-block: 78px;
}

.hero-copy { max-width: 670px; }
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 13px;
  color: var(--red-dark);
  font-size: .82rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .12em;
}
.eyebrow::before { content: ""; width: 28px; height: 3px; background: var(--gold); }

h1, h2, h3, h4 {
  color: #19211c;
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.18;
  text-wrap: balance;
}
h1 { margin: 0 0 18px; font-size: clamp(2.45rem, 5vw, 5rem); letter-spacing: -.04em; }
h2 { margin: 2.4rem 0 .9rem; font-size: clamp(1.65rem, 2.7vw, 2.45rem); letter-spacing: -.025em; }
h3 { margin: 1.8rem 0 .65rem; font-size: 1.32rem; }

.hero-lead { max-width: 610px; margin: 0; color: #394139; font-size: clamp(1.02rem, 1.6vw, 1.2rem); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

.trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  margin-top: 28px;
  padding: 0;
  list-style: none;
  font-size: .9rem;
  font-weight: 750;
  color: #425047;
}
.trust-row li::before { content: "✓"; color: var(--green-2); margin-right: 7px; font-weight: 950; }

.page-shell {
  display: grid;
  grid-template-columns: 230px minmax(0, 760px) 230px;
  justify-content: center;
  gap: 42px;
  padding-block: 46px 90px;
}

.main-content { min-width: 0; }
.article-sidebar,
.toc-sidebar { align-self: start; position: sticky; top: 142px; }

.sidebar-title {
  margin: 0 0 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: .75rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .1em;
}
.sidebar-nav { margin: 0; padding: 0; list-style: none; }
.sidebar-nav li { border-bottom: 1px solid #ece6da; }
.sidebar-nav a {
  display: block;
  padding: 9px 4px;
  color: #364039;
  font-size: .87rem;
  line-height: 1.35;
  text-decoration: none;
}
.sidebar-nav a:hover,
.sidebar-nav a[aria-current="page"],
.sidebar-nav a.is-active { color: var(--red); font-weight: 800; }

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin: 0 0 22px;
  padding: 0;
  color: var(--muted);
  font-size: .83rem;
  list-style: none;
}
.breadcrumb li:not(:last-child)::after { content: "›"; margin-left: 7px; color: #9a9e98; }
.breadcrumb a { color: inherit; }

.article-header { border-bottom: 1px solid var(--line); padding-bottom: 26px; margin-bottom: 27px; }
.article-header h1 { font-size: clamp(2.25rem, 4vw, 3.8rem); }
.article-deck { margin: 0 0 14px; color: #4a514b; font-size: 1.16rem; }
.article-meta { display: flex; flex-wrap: wrap; gap: 8px 18px; color: var(--muted); font-size: .82rem; }

.direct-answer {
  margin: 22px 0 30px;
  padding: 22px 24px;
  border: 1px solid #d9c36d;
  border-left: 5px solid var(--gold);
  border-radius: 12px;
  background: #fff9e6;
  font-size: 1.05rem;
}
.direct-answer strong { color: var(--green); }

.article-body p { margin: 0 0 1.08rem; }
.article-body ul, .article-body ol { padding-left: 1.35rem; }
.article-body li { margin: .45rem 0; }
.article-body section { scroll-margin-top: 150px; }
.article-body strong { color: #213d34; }

.note,
.warning,
.source-box {
  margin: 26px 0;
  padding: 18px 20px;
  border-radius: 12px;
}
.note { background: #edf6f1; border: 1px solid #c2dccf; }
.warning { background: #fff1f1; border: 1px solid #efc2c5; }
.source-box { background: #f5f3ee; border: 1px solid var(--line); font-size: .92rem; }
.source-box h2 { margin-top: 0; font-size: 1.25rem; }
.source-box ul { margin-bottom: 0; }

.data-table-wrap { overflow-x: auto; margin: 22px 0 30px; border: 1px solid var(--line); border-radius: 12px; }
.data-table { width: 100%; min-width: 610px; border-collapse: collapse; font-size: .9rem; }
.data-table th, .data-table td { padding: 12px 14px; border-bottom: 1px solid var(--line); text-align: left; }
.data-table th { background: var(--green); color: #fff; font-size: .82rem; letter-spacing: .02em; }
.data-table tr:last-child td { border-bottom: 0; }
.data-table tbody tr:nth-child(even) { background: #fbf7ee; }

.section { padding-block: 72px; }
.section-alt { background: var(--paper-warm); border-block: 1px solid #e5ded0; }
.section-header { max-width: 760px; margin-bottom: 30px; }
.section-header h2 { margin-top: 0; }
.section-header p { color: var(--muted); font-size: 1.05rem; }

.question-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
.question-card {
  display: block;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  color: var(--ink);
  text-decoration: none;
  box-shadow: 0 6px 20px rgba(45,32,17,.05);
}
.question-card:hover { color: var(--ink); border-color: #bba762; transform: translateY(-2px); }
.question-number { display: block; margin-bottom: 10px; color: var(--red); font-size: .75rem; font-weight: 900; letter-spacing: .1em; }
.question-card h3 { margin: 0 0 8px; font-size: 1.2rem; }
.question-card p { margin: 0; color: var(--muted); font-size: .92rem; }

.promo-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.promo-card {
  position: relative;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #160d20;
  box-shadow: var(--shadow);
  text-align: left;
}
.promo-card img { display: block; width: 100%; aspect-ratio: 1600 / 341; object-fit: cover; }
.promo-card span {
  position: absolute;
  right: 10px;
  bottom: 10px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(255,255,255,.92);
  color: var(--ink);
  font-size: .76rem;
  font-weight: 850;
}
.promo-card:hover { transform: translateY(-2px); }

.large-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  margin: 34px 0;
}
.visual-action {
  position: relative;
  min-height: 190px;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  padding: 24px;
  border-radius: var(--radius);
  background-color: #263b33;
  background-image: url('../img/hero-live-roulette.webp');
  background-repeat: no-repeat;
  background-position: right center;
  background-size: auto 100%;
  color: #fff;
  text-decoration: none;
  box-shadow: var(--shadow);
}
.visual-action::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(16,24,20,.96) 0 43%, rgba(16,24,20,.72) 58%, rgba(16,24,20,.12) 78%, rgba(16,24,20,0) 100%); }
.visual-action > span { position: relative; z-index: 1; max-width: 58%; }
.visual-action small { display: block; opacity: .88; font-weight: 650; }
.visual-action strong { display: block; font-size: 1.55rem; font-family: Georgia, serif; }
.visual-action:hover { color: #fff; transform: translateY(-3px); }

.faq-list { border-top: 1px solid var(--line); }
.faq-list details { border-bottom: 1px solid var(--line); }
.faq-list summary { padding: 18px 3px; font-weight: 850; cursor: pointer; list-style: none; }
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: "+"; float: right; color: var(--red); }
.faq-list details[open] summary::after { content: "–"; }
.faq-list details div { padding: 0 4px 19px; color: #495149; }

.site-search {
  position: fixed;
  inset: 0;
  z-index: 500;
  display: none;
  align-items: flex-start;
  justify-content: center;
  padding: min(15vh, 120px) 16px 20px;
  background: rgba(17, 25, 21, .72);
  backdrop-filter: blur(8px);
}
.site-search.is-open { display: flex; }
.search-panel { width: min(100%, 720px); max-height: 75vh; overflow: auto; padding: 24px; border-radius: 18px; background: #fff; box-shadow: 0 28px 80px rgba(0,0,0,.28); }
.search-row { display: grid; grid-template-columns: 1fr auto; gap: 10px; }
.search-row input { width: 100%; min-height: 50px; padding: 12px 16px; border: 2px solid #c9c3b6; border-radius: 10px; }
.search-row input:focus { outline: 3px solid rgba(201,154,46,.25); border-color: var(--gold); }
.search-close { border: 0; border-radius: 10px; padding: 0 16px; background: #ece8df; font-weight: 900; }
.search-results { margin: 18px 0 0; padding: 0; list-style: none; }
.search-results a { display: block; padding: 13px 4px; border-bottom: 1px solid var(--line); text-decoration: none; }
.search-results strong { display: block; color: var(--ink); }
.search-results span { display: block; color: var(--muted); font-size: .86rem; }

.modal {
  position: fixed;
  inset: 0;
  z-index: 600;
  display: none;
  place-items: center;
  padding: 16px;
  background: rgba(19, 13, 20, .78);
  backdrop-filter: blur(7px);
}
.modal.is-open { display: grid; }
.modal-dialog { width: min(100%, 880px); max-height: 88vh; overflow: auto; border-radius: 18px; background: #fff; box-shadow: 0 30px 90px rgba(0,0,0,.35); }
.modal-image { width: 100%; display: block; background: #190b20; }
.modal-copy { padding: 24px; }
.modal-copy h2 { margin-top: 0; }
.modal-close { float: right; border: 0; border-radius: 999px; width: 42px; height: 42px; background: #eee9df; font-size: 1.3rem; font-weight: 900; }

.site-footer { background: #122e27; color: #eaf1ed; border-top: 5px solid var(--gold); }
.footer-inner { display: grid; grid-template-columns: 1.25fr repeat(3, 1fr); gap: 34px; padding-block: 50px 32px; }
.footer-brand img { width: 190px; filter: drop-shadow(0 4px 10px rgba(0,0,0,.2)); }
.footer-brand p { color: #b9cbc2; font-size: .9rem; }
.footer-heading { margin: 0 0 13px; color: #fff; font-family: inherit; font-size: .9rem; text-transform: uppercase; letter-spacing: .08em; }
.footer-links { margin: 0; padding: 0; list-style: none; }
.footer-links li { margin: 8px 0; }
.footer-links a { color: #d4e0da; font-size: .9rem; text-decoration: none; }
.footer-links a:hover { color: #fff; text-decoration: underline; }
.footer-bottom { padding: 18px 0 26px; border-top: 1px solid rgba(255,255,255,.12); color: #a9bdb3; font-size: .8rem; }

.back-top {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 90;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 999px;
  background: var(--green);
  color: #fff;
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s;
}
.back-top.is-visible { opacity: 1; pointer-events: auto; }

.mobile-quick { display: none; }

.simple-page { width: min(calc(100% - 32px), 850px); margin: 0 auto; padding: 48px 0 90px; }
.simple-page .article-header h1 { font-size: clamp(2.2rem, 5vw, 4rem); }

@media (max-width: 1120px) {
  .page-shell { grid-template-columns: 205px minmax(0, 760px); }
  .toc-sidebar { display: none; }
  .primary-nav ul { gap: 16px; }
}

@media (max-width: 850px) {
  .top-links { display: none; }
  .header-inner { min-height: 66px; grid-template-columns: 1fr auto; }
  .brand img { width: 165px; }
  .menu-toggle { display: inline-grid; }
  .primary-nav {
    position: absolute;
    top: 100%;
    left: 16px;
    right: 16px;
    display: none;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #fff;
    box-shadow: var(--shadow);
  }
  .primary-nav.is-open { display: block; }
  .primary-nav ul { display: grid; gap: 0; }
  .primary-nav a { display: block; padding: 11px; }
  .header-actions .button { display: none; }
  .icon-button { width: 48px; min-width: 48px; height: 48px; }
  .hero { min-height: 600px; align-items: end; }
  .hero-media { background-position: 62% center; background-size: cover; }
  .hero-media::after { background: linear-gradient(0deg, rgba(255,253,247,.99) 0 35%, rgba(255,253,247,.55) 62%, rgba(255,253,247,.04) 100%); }
  .hero-content { padding-block: 250px 42px; }
  .page-shell { display: block; padding-top: 28px; }
  .article-sidebar { position: static; margin-bottom: 28px; }
  .article-sidebar .sidebar-nav { display: flex; overflow-x: auto; gap: 8px; padding-bottom: 8px; scrollbar-width: thin; }
  .article-sidebar .sidebar-nav li { flex: 0 0 210px; border: 1px solid var(--line); border-radius: 10px; }
  .article-sidebar .sidebar-nav a { padding: 10px; }
  .question-grid, .promo-grid, .large-actions { grid-template-columns: 1fr; }
  .visual-action { min-height: 180px; padding: 20px; }
  .visual-action > span { max-width: 62%; }
  .footer-inner { grid-template-columns: 1fr 1fr; }
  .mobile-quick {
    position: fixed;
    left: 10px;
    right: 10px;
    bottom: 10px;
    z-index: 95;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    padding: 8px;
    border: 1px solid rgba(255,255,255,.2);
    border-radius: 14px;
    background: rgba(18,46,39,.96);
    box-shadow: 0 12px 35px rgba(0,0,0,.3);
    backdrop-filter: blur(9px);
  }
  .mobile-quick a { min-height: 44px; padding: 9px 12px; border-radius: 9px; text-align: center; font-weight: 850; text-decoration: none; }
  .mobile-quick a:first-child { background: var(--gold-soft); color: #2c2414; }
  .mobile-quick a:last-child { background: var(--red); color: #fff; }
  .back-top { bottom: 82px; }
  body { padding-bottom: 76px; }
}

@media (max-width: 560px) {
  .topbar-inner { justify-content: center; text-align: center; }
  .ribbon-inner { font-size: .78rem; }
  .flag-wrap { display: none; }
  .hero-content { padding-top: 225px; }
  .hero h1 { font-size: 2.55rem; }
  .hero-actions .button { flex: 1 1 100%; }
  .section { padding-block: 52px; }
  .question-card { padding: 18px; }
  .promo-grid { gap: 12px; }
  .footer-inner { grid-template-columns: 1fr; }
  .article-header h1 { font-size: 2.35rem; }
  .article-deck { font-size: 1.03rem; }
  .direct-answer { padding: 18px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

@media print {
  .site-header, .independence-ribbon, .article-sidebar, .toc-sidebar, .mobile-quick, .back-top, .site-footer, .large-actions { display: none !important; }
  body { background: #fff; color: #000; }
  .page-shell { display: block; width: 100%; padding: 0; }
  a { color: #000; text-decoration: none; }
  a[href^="http"]::after { content: " (" attr(href) ")"; font-size: .75em; }
}
