/* ==========================================================================
   stakenba.ca — "Night basketball market board"
   Premium dark basketball editorial hub. Independent affiliate site.
   ========================================================================== */

/* ---------- Design tokens ---------- */
:root {
  --bg: #0a0e1a;
  --bg-2: #0c1220;
  --panel: #101830;
  --panel-2: #0e1526;
  --line: #223052;
  --line-soft: #1a2540;
  --ink: #eef2fb;
  --ink-soft: #c7d2e6;
  --muted: #93a0ba;
  /* Primary accent: electric blue -> cyan */
  --blue: #2F7BFF;
  --blue-2: #38BDF8;
  --accent: #38BDF8;
  --accent-strong: #2F7BFF;
  --accent-soft: rgba(56,189,248,.14);
  --accent-glow: rgba(56,189,248,.28);
  /* Secondary basketball accent — used sparingly */
  --orange: #FF8A3D;
  --orange-2: #ffb27a;
  --basketball: #FF8A3D;
  --basketball-soft: rgba(255,138,61,.14);
  --good: #37d9a0;
  --warn: #ffd166;
  --radius: 10px;
  --radius-sm: 8px;
  --radius-lg: 16px;
  --shadow: 0 18px 40px rgba(0,0,0,.45);
  --shadow-sm: 0 8px 22px rgba(0,0,0,.35);
  --maxw: 1160px;
  --gap: clamp(16px, 3vw, 28px);
  --font: system-ui, -apple-system, BlinkMacSystemFont, "Noto Sans JP",
          "Hiragino Sans", "Yu Gothic", "Segoe UI", sans-serif;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background:
    radial-gradient(1100px 520px at 82% -8%, rgba(61,125,255,.16), transparent 60%),
    radial-gradient(900px 480px at 6% 4%, rgba(47,123,255,.12), transparent 55%),
    var(--bg);
  line-height: 1.65;
  font-size: 16px;
  overflow-x: hidden;
}
img, svg { max-width: 100%; height: auto; display: block; }
a { color: var(--blue-2); text-decoration: none; }
a:hover { color: var(--ink); }
h1, h2, h3, h4 { line-height: 1.2; margin: 0 0 .5em; font-weight: 800; letter-spacing: -.01em; }
h1 { font-size: clamp(1.9rem, 4.6vw, 3.05rem); }
h2 { font-size: clamp(1.5rem, 3.2vw, 2.15rem); }
h3 { font-size: clamp(1.12rem, 2vw, 1.35rem); }
p { margin: 0 0 1rem; color: var(--ink-soft); }
:lang(ja) { line-height: 1.85; }

/* court-line background motif */
body::before {
  content: "";
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background-image:
    linear-gradient(transparent 0, transparent calc(100% - 1px), rgba(255,255,255,.03) 100%),
    radial-gradient(circle at 50% 120%, rgba(255,138,61,.05), transparent 45%);
  background-size: 100% 46px, 100% 100%;
}

/* ---------- Layout ---------- */
.container { width: min(100% - 32px, var(--maxw)); margin-inline: auto; }
.section { padding: clamp(48px, 8vw, 88px) 0; }
.section--tight { padding: clamp(32px, 5vw, 56px) 0; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: .78rem; letter-spacing: .16em; text-transform: uppercase;
  color: var(--blue-2); font-weight: 700; margin-bottom: .7rem;
}
.eyebrow::before { content: ""; width: 22px; height: 2px; background: var(--blue); border-radius: 2px; }
.lead { font-size: clamp(1.02rem, 1.6vw, 1.16rem); color: var(--ink-soft); max-width: 60ch; }
.center { text-align: center; }
.center .lead { margin-inline: auto; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  font-weight: 700; font-size: .98rem; line-height: 1.1;
  padding: .82em 1.5em; border-radius: 999px; cursor: pointer;
  border: 1px solid transparent; transition: transform .15s ease, box-shadow .2s ease, background .2s ease;
  text-align: center; white-space: normal;
}
.btn:active { transform: translateY(1px); }
.btn--primary {
  color: #ffffff;
  background: linear-gradient(135deg, var(--accent-strong), var(--accent));
  box-shadow: 0 10px 28px rgba(47,123,255,.34);
}
.btn--primary:hover { color: #ffffff; box-shadow: 0 14px 34px rgba(56,189,248,.46), 0 0 0 1px rgba(255,138,61,.35); transform: translateY(-2px); }
.btn--ghost {
  color: var(--ink); background: rgba(61,125,255,.08);
  border-color: var(--line); backdrop-filter: blur(6px);
}
.btn--ghost:hover { color: var(--ink); border-color: var(--blue); background: rgba(61,125,255,.16); }
.btn--blue {
  color: #fff; background: linear-gradient(120deg, var(--blue-2), var(--blue));
  box-shadow: 0 10px 26px rgba(61,125,255,.28);
}
.btn--blue:hover { color: #fff; transform: translateY(-2px); box-shadow: 0 14px 32px rgba(61,125,255,.42); }
.btn--sm { padding: .6em 1.1em; font-size: .88rem; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 1.4rem; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 60;
  background: rgba(9,13,24,.82);
  backdrop-filter: saturate(140%) blur(14px);
  border-bottom: 1px solid var(--line-soft);
}
.header-inner {
  display: flex; align-items: center; gap: 16px;
  height: 66px;
}
.brand { display: flex; align-items: center; gap: 10px; margin-right: auto; }
.brand img { height: 26px; width: auto; }
.brand .brand-tag {
  font-size: .62rem; letter-spacing: .14em; text-transform: uppercase;
  color: var(--muted); border-left: 1px solid var(--line); padding-left: 8px;
}
.nav { display: flex; align-items: center; gap: 6px; }
.nav a {
  color: var(--ink-soft); font-weight: 600; font-size: .95rem;
  padding: 8px 12px; border-radius: 8px;
}
.nav a:hover, .nav a[aria-current="page"] { color: var(--ink); background: rgba(61,125,255,.1); }
/* CTA lives inside nav only for the mobile dropdown; hidden on desktop.
   The language link stays in the nav group (Promo Code / Sports / 日本語). */
.nav .btn--primary { display: none; }
.header-cta { display: flex; align-items: center; gap: 12px; }
.header-cta .lang-link { display: none; }
.lang-link {
  font-size: .82rem; color: var(--muted); font-weight: 600;
  border: 1px solid var(--line); border-radius: 999px; padding: 5px 11px;
}
.lang-link:hover { color: var(--ink); border-color: var(--blue); }
.nav-toggle {
  display: none; width: 42px; height: 42px; border-radius: 10px;
  border: 1px solid var(--line); background: rgba(61,125,255,.06);
  cursor: pointer; padding: 0; align-items: center; justify-content: center;
}
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
  content: ""; display: block; width: 18px; height: 2px; background: var(--ink);
  border-radius: 2px; position: relative; transition: transform .25s ease, opacity .2s ease;
}
.nav-toggle span::before { position: absolute; top: -6px; }
.nav-toggle span::after { position: absolute; top: 6px; }
.nav-toggle[aria-expanded="true"] span { background: transparent; }
.nav-toggle[aria-expanded="true"] span::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span::after { transform: translateY(-6px) rotate(-45deg); }

/* Desktop: balanced 3-column header — logo left | nav centered | CTA right */
@media (min-width: 861px) {
  .header-inner {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 32px;
    align-items: center;
  }
  .brand { margin-right: 0; justify-self: start; }
  .nav { justify-self: center; gap: 26px; }
  .header-cta { justify-self: end; }
}

@media (max-width: 860px) {
  .nav-toggle { display: inline-flex; }
  .header-cta .btn--primary, .header-cta .lang-link { display: none; }
  .nav {
    position: fixed; inset: 66px 0 auto 0;
    flex-direction: column; align-items: stretch; gap: 4px;
    background: rgba(9,13,24,.98); border-bottom: 1px solid var(--line);
    padding: 14px 16px 22px; backdrop-filter: blur(16px);
    max-height: 0; overflow: hidden; opacity: 0;
    transition: max-height .32s ease, opacity .25s ease, padding .25s ease;
    padding-top: 0; padding-bottom: 0;
  }
  .nav.open { max-height: 80vh; opacity: 1; padding: 14px 16px 22px; }
  .nav a { padding: 13px 12px; font-size: 1rem; border-bottom: 1px solid var(--line-soft); }
  .nav .btn--primary, .nav .lang-link { display: inline-flex; margin-top: 10px; }
  .nav .lang-link { align-self: flex-start; }
}

/* ---------- Hero ---------- */
.hero { padding: clamp(38px, 6vw, 72px) 0 clamp(30px, 5vw, 56px); }
.hero-grid {
  display: grid; gap: clamp(28px, 5vw, 52px);
  grid-template-columns: 1fr; align-items: center;
}
.hero-copy h1 { margin-bottom: .35em; }
.hero-copy .lead { margin-bottom: .2rem; }
.hero-micro {
  display: flex; flex-wrap: wrap; gap: 10px 18px; margin-top: 1.4rem;
  font-size: .82rem; color: var(--muted);
}
.hero-micro span { display: inline-flex; align-items: center; gap: 7px; }
.hero-micro span::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--blue); }
.hero-micro span.warn::before { background: var(--orange); }
.hero-art { position: relative; }
.hero-art img { width: 100%; filter: drop-shadow(0 24px 50px rgba(0,0,0,.5)); }
@media (min-width: 900px) {
  .hero-grid { grid-template-columns: 1.05fr .95fr; }
  .hero--flip .hero-art { order: -1; }
}

/* ---------- Panels / cards ---------- */
.panel {
  background: linear-gradient(180deg, rgba(20,29,52,.72), rgba(12,18,34,.72));
  border: 1px solid var(--line); border-radius: var(--radius);
  backdrop-filter: blur(8px); box-shadow: var(--shadow-sm);
}
.grid { display: grid; gap: var(--gap); }
.grid-2 { grid-template-columns: 1fr; }
.grid-3 { grid-template-columns: 1fr; }
.grid-4 { grid-template-columns: 1fr; }
@media (min-width: 620px) { .grid-2 { grid-template-columns: 1fr 1fr; } .grid-4 { grid-template-columns: 1fr 1fr; } }
@media (min-width: 820px) {
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
  .grid-4 { grid-template-columns: repeat(4, 1fr); }
}

/* market / info cards — thin outline, low radius */
.card {
  border: 1px solid var(--line); border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(18,26,48,.6), rgba(11,17,32,.6));
  padding: 22px; position: relative; overflow: hidden;
  transition: border-color .2s ease, transform .2s ease;
}
.card::before {
  content: ""; position: absolute; inset: 0 0 auto 0; height: 2px;
  background: linear-gradient(90deg, transparent, var(--blue), transparent);
  opacity: .5;
}
.card:hover { border-color: #33507f; transform: translateY(-3px); }
.card--orange::before { background: linear-gradient(90deg, transparent, var(--orange), transparent); }
.card h3 { margin-bottom: .35em; }
.card p:last-child { margin-bottom: 0; }
.card .tag {
  display: inline-block; font-size: .72rem; letter-spacing: .08em; text-transform: uppercase;
  color: var(--blue-2); font-weight: 700; margin-bottom: .6em;
}
.card--orange .tag { color: var(--orange-2); }
.card-ico {
  width: 40px; height: 40px; border-radius: 10px; margin-bottom: 14px;
  display: grid; place-items: center; font-size: 1.2rem;
  background: rgba(61,125,255,.12); border: 1px solid var(--line);
}
.card--orange .card-ico { background: rgba(255,138,61,.12); }

/* ---------- Quick answer box ---------- */
.quick {
  border: 1px solid var(--line); border-left: 3px solid var(--blue);
  border-radius: var(--radius); padding: clamp(20px, 3vw, 30px);
  background: linear-gradient(120deg, rgba(61,125,255,.08), rgba(12,18,34,.5));
}
.quick .q-label {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: .76rem; letter-spacing: .14em; text-transform: uppercase;
  color: var(--blue-2); font-weight: 700; margin-bottom: .55em;
}
.quick h2, .quick h3 { margin-bottom: .4em; }
.quick p:last-child { margin-bottom: 0; }

/* ---------- Split / editorial rows ---------- */
.split {
  display: grid; gap: clamp(24px, 4vw, 48px); align-items: center;
  grid-template-columns: 1fr;
}
@media (min-width: 880px) {
  .split { grid-template-columns: 1fr 1fr; }
  .split--r > .split-media { order: 2; }
}
.split-media img { border-radius: var(--radius-lg); border: 1px solid var(--line); box-shadow: var(--shadow); }

/* ---------- Offer / rakeback block ---------- */
.offer {
  position: relative; overflow: hidden;
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  background:
    radial-gradient(600px 240px at 90% -10%, rgba(56,189,248,.16), transparent 60%),
    linear-gradient(160deg, rgba(20,29,52,.9), rgba(11,17,32,.92));
  padding: clamp(24px, 4vw, 44px);
}
.offer-grid { display: grid; gap: clamp(20px, 3vw, 36px); grid-template-columns: 1fr; align-items: center; }
@media (min-width: 840px) { .offer-grid { grid-template-columns: 1.2fr .8fr; } }
.offer .pill-row { display: flex; flex-wrap: wrap; gap: 10px; margin: 1rem 0 1.2rem; }
.stat-chip {
  border: 1px solid var(--line); border-radius: 999px; padding: 7px 14px;
  font-size: .85rem; color: var(--ink-soft); background: rgba(255,255,255,.03);
}
.stat-chip b { color: var(--blue-2); }

/* ---------- Promo code copy box ---------- */
.codebox {
  border: 1px dashed var(--blue); border-radius: var(--radius);
  background: linear-gradient(120deg, rgba(61,125,255,.1), rgba(12,18,34,.6));
  padding: clamp(18px, 3vw, 26px); text-align: center;
}
.codebox .code-label { font-size: .82rem; color: var(--muted); letter-spacing: .12em; text-transform: uppercase; }
.code-tap {
  display: inline-flex; align-items: center; gap: 14px; margin: 12px auto 6px;
  border: 1px solid var(--line); border-radius: 12px; cursor: pointer;
  background: #0b1428; padding: 14px 20px; transition: border-color .2s ease, background .2s ease;
  font: inherit; color: var(--ink);
}
.code-tap:hover { border-color: var(--blue); background: #0d1730; }
.code-tap .code-value {
  font-size: clamp(1.5rem, 5vw, 2.1rem); font-weight: 800; letter-spacing: .06em; color: var(--ink);
}
.code-tap .code-copyico {
  font-size: .8rem; color: var(--blue-2); border: 1px solid var(--line);
  border-radius: 8px; padding: 6px 10px; white-space: nowrap;
}
.code-tap.copied { border-color: var(--good); }
.code-tap.copied .code-copyico { color: var(--good); border-color: var(--good); }
.codebox .code-hint { font-size: .84rem; color: var(--muted); margin: .4rem 0 0; }

/* ---------- Large promo image banner (below step-by-step) ---------- */
.promo-image-section { padding: clamp(6px, 2vw, 18px) 0 clamp(34px, 5vw, 60px); }
.promo-large-visual {
  margin: 0 auto; max-width: 1080px; width: 100%;
}
.promo-large-visual img {
  width: 100%; height: auto; display: block;
  border-radius: 24px;
  border: 1px solid var(--line);
  box-shadow: 0 26px 64px rgba(0,0,0,.55), 0 0 44px rgba(61,125,255,.14);
}
@media (max-width: 640px) {
  .promo-large-visual img { border-radius: 16px; }
}

/* ---------- Steps ---------- */
.steps { counter-reset: step; display: grid; gap: 14px; }
.step {
  display: grid; grid-template-columns: 44px 1fr; gap: 16px; align-items: start;
  border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px;
  background: rgba(12,18,34,.5);
}
.step::before {
  counter-increment: step; content: counter(step);
  width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center;
  font-weight: 800; color: #ffffff; background: linear-gradient(135deg, var(--accent-strong), var(--accent));
}
.step h4 { margin: 2px 0 .3em; font-size: 1.05rem; }
.step p { margin: 0; font-size: .96rem; }

/* ---------- Tables (responsive) ---------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); -webkit-overflow-scrolling: touch; }
table.board { width: 100%; border-collapse: collapse; min-width: 560px; font-size: .94rem; }
table.board caption { text-align: left; padding: 14px 16px; color: var(--muted); font-size: .82rem; letter-spacing: .1em; text-transform: uppercase; }
table.board th, table.board td { padding: 13px 16px; text-align: left; border-bottom: 1px solid var(--line-soft); }
table.board thead th { background: rgba(61,125,255,.08); color: var(--ink); font-weight: 700; white-space: nowrap; }
table.board tbody tr:hover { background: rgba(255,255,255,.02); }
table.board td:first-child { font-weight: 700; color: var(--ink); }
table.board .pos { color: var(--good); } table.board .neg { color: var(--orange-2); }
@media (max-width: 560px) { table.board { min-width: 520px; } }

/* ---------- FAQ ---------- */
.faq { display: grid; gap: 12px; }
.faq-item { border: 1px solid var(--line); border-radius: var(--radius); background: rgba(12,18,34,.5); overflow: hidden; }
.faq-q {
  width: 100%; text-align: left; cursor: pointer; border: 0; background: transparent;
  color: var(--ink); font: inherit; font-weight: 700; font-size: 1.03rem;
  padding: 18px 52px 18px 20px; position: relative;
}
.faq-q::after {
  content: "+"; position: absolute; right: 20px; top: 50%; transform: translateY(-50%);
  font-size: 1.4rem; font-weight: 400; color: var(--blue-2); transition: transform .25s ease;
}
.faq-item.open .faq-q::after { content: "\2212"; }
.faq-a { max-height: 0; overflow: hidden; transition: max-height .3s ease; }
.faq-a-inner { padding: 0 20px 18px; color: var(--ink-soft); }
.faq-a-inner p:last-child { margin-bottom: 0; }

/* ---------- Notes / trust / responsible gambling ---------- */
.note {
  border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 22px;
  background: rgba(12,18,34,.5);
}
.note--warn { border-left: 3px solid var(--orange); }
.note--info { border-left: 3px solid var(--blue); }
.note h3 { font-size: 1.1rem; }
.note ul { margin: .4rem 0 0; padding-left: 1.1rem; color: var(--ink-soft); }
.note li { margin-bottom: .4rem; }
.rg {
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  background: linear-gradient(120deg, rgba(56,189,248,.07), rgba(12,18,34,.5));
  padding: clamp(22px, 3vw, 34px);
}
.rg .rg-badge {
  display: inline-flex; align-items: center; gap: 8px; font-weight: 700; font-size: .8rem;
  letter-spacing: .1em; text-transform: uppercase; color: var(--orange-2); margin-bottom: .6em;
}

/* ---------- Breadcrumbs ---------- */
.crumbs { padding: 16px 0 0; font-size: .86rem; color: var(--muted); }
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; }
.crumbs li { display: flex; gap: 8px; align-items: center; }
.crumbs li + li::before { content: "›"; color: var(--line); }
.crumbs a { color: var(--blue-2); }
.crumbs [aria-current="page"] { color: var(--ink-soft); }

/* ---------- Disclaimer ribbon ---------- */
.disclaimer-bar {
  background: rgba(56,189,248,.06); border-bottom: 1px solid var(--line-soft);
  font-size: .82rem; color: var(--ink-soft); text-align: center; padding: 8px 16px;
}
.disclaimer-bar b { color: var(--ink); }

/* ---------- CTA band ---------- */
.cta-band {
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  background:
    radial-gradient(500px 220px at 15% 0%, rgba(61,125,255,.2), transparent 60%),
    radial-gradient(500px 220px at 90% 120%, rgba(255,138,61,.10), transparent 60%),
    linear-gradient(160deg, rgba(20,29,52,.9), rgba(11,17,32,.92));
  padding: clamp(28px, 4vw, 48px); text-align: center;
}
.cta-band h2 { margin-bottom: .3em; }
.cta-band .btn-row { justify-content: center; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); margin-top: 20px; background: rgba(8,11,20,.7); }
.footer-grid {
  display: grid; gap: 28px; padding: clamp(38px, 5vw, 56px) 0 28px;
  grid-template-columns: 1fr;
}
@media (min-width: 720px) { .footer-grid { grid-template-columns: 1.6fr 1fr 1fr; } }
.footer-brand img { height: 26px; margin-bottom: 14px; }
.footer-brand p { font-size: .9rem; color: var(--muted); max-width: 42ch; }
.footer-col h4 { font-size: .82rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: .8em; }
.footer-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.footer-col a { color: var(--ink-soft); font-size: .94rem; }
.footer-col a:hover { color: var(--ink); }
.footer-bottom {
  border-top: 1px solid var(--line-soft); padding: 18px 0 30px;
  font-size: .82rem; color: var(--muted); display: grid; gap: 10px;
}
.footer-bottom .rg-line { color: var(--ink-soft); }
.age-badge {
  display: inline-grid; place-items: center; min-width: 34px; height: 24px; padding: 0 8px;
  border: 1px solid var(--orange); color: var(--orange-2); border-radius: 6px;
  font-size: .74rem; font-weight: 800; margin-right: 6px;
}

/* ---------- Utilities ---------- */
.mt-0 { margin-top: 0; } .mb-0 { margin-bottom: 0; }
.stack > * + * { margin-top: clamp(28px, 4vw, 44px); }
.muted { color: var(--muted); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }
:focus-visible { outline: 2px solid var(--blue-2); outline-offset: 2px; border-radius: 4px; }
@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; transition: none !important; } }
