/* BCGamePK.org - base styles
   Palette inspired by BC.Game's dark UI: near-black background, neon-green accent. */

:root {
  --bg: #14171a;
  --bg-elevated: #1b1f22;
  --bg-card: #1f2427;
  --border: #2a3034;
  --border-soft: #242a2e;
  --text: #eef1f2;
  --text-muted: #9aa2a6;
  --text-faint: #6d7579;
  --accent: #1fdf64;
  --accent-strong: #17c458;
  --accent-soft: rgba(31, 223, 100, 0.12);
  --accent-text-on: #0b1210;
  --radius-lg: 18px;
  --radius-md: 12px;
  --radius-sm: 8px;
  --max-width: 1120px;
  --shadow-card: 0 1px 0 rgba(255, 255, 255, 0.02) inset, 0 8px 24px rgba(0, 0, 0, 0.28);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

/* Inline homepage anchor: a phrase inside existing body copy that links back to "/".
   Kept visually distinct from the surrounding text with an underline + soft background,
   so it reads as a highlighted, intentional in-text link rather than plain wording. */
.inline-home-link {
  color: var(--accent);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 2px;
  background: var(--accent-soft);
  padding: 0 3px;
  border-radius: 3px;
}
.inline-home-link:hover { color: var(--accent-strong); }

h1, h2, h3 { line-height: 1.25; margin: 0 0 0.6em; font-weight: 700; color: var(--text); }
h1 { font-size: clamp(1.6rem, 4vw, 2.35rem); }
h2 { font-size: clamp(1.25rem, 2.6vw, 1.6rem); margin-top: 2.2em; }
p { margin: 0 0 1em; color: var(--text); }

ul, ol { padding-left: 1.3em; margin: 0 0 1.2em; }
li { margin-bottom: 0.5em; }

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--accent);
  color: var(--accent-text-on);
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  z-index: 200;
}
.skip-link:focus { left: 8px; top: 8px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(20, 23, 26, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border-soft);
}
.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 700;
  font-size: 1.05rem;
  white-space: nowrap;
}
.brand:hover { text-decoration: none; }
.brand-mark { border-radius: 6px; }
.brand-dot { color: var(--accent); font-weight: 600; }

.main-nav ul {
  display: flex;
  gap: 22px;
  list-style: none;
  padding: 0;
  margin: 0;
}
.main-nav a {
  color: var(--text-muted);
  font-size: 0.92rem;
  font-weight: 500;
}
.main-nav a:hover { color: var(--text); text-decoration: none; }

.nav-toggle-input { display: none; }
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 4px;
  cursor: pointer;
  padding: 8px;
}
.nav-toggle span {
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

@media (max-width: 860px) {
  .nav-toggle { display: flex; }
  .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-elevated);
    border-bottom: 1px solid var(--border-soft);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.25s ease;
  }
  .main-nav ul {
    flex-direction: column;
    gap: 0;
    padding: 6px 20px 14px;
  }
  .main-nav li { border-top: 1px solid var(--border-soft); }
  .main-nav li:first-child { border-top: none; }
  .main-nav a { display: block; padding: 12px 4px; }
  .nav-toggle-input:checked ~ .main-nav { max-height: 480px; }
  .nav-toggle-input:checked ~ .nav-toggle span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
  .nav-toggle-input:checked ~ .nav-toggle span:nth-child(2) { opacity: 0; }
  .nav-toggle-input:checked ~ .nav-toggle span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
}

/* ---------- Hero ---------- */
.hero {
  padding: 36px 20px 24px;
  border-bottom: 1px solid var(--border-soft);
}
.hero-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 36px;
  align-items: center;
}
.eyebrow {
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.78rem;
  font-weight: 700;
  margin: 0 0 10px;
}
.hero h1 { margin-bottom: 14px; }
.hero-lede { color: var(--text-muted); font-size: 1.03rem; max-width: 560px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin: 20px 0 10px; }
.hero-disclaimer { color: var(--text-faint); font-size: 0.82rem; margin: 6px 0 0; }
.hero-media img {
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-soft);
  width: 100%;
  height: auto;
}

@media (max-width: 780px) {
  .hero-inner { grid-template-columns: 1fr; gap: 22px; }
  .hero-media { order: -1; }
}

/* ---------- Buttons ---------- */
.cta-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 13px 22px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.95rem;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease;
  white-space: nowrap;
}
.cta-btn:hover { text-decoration: none; transform: translateY(-1px); }
.cta-btn-primary {
  background: var(--accent);
  color: var(--accent-text-on);
  border: 1px solid var(--accent);
}
.cta-btn-primary:hover { background: var(--accent-strong); }
.cta-btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}
.cta-btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

/* ---------- Sections shared ---------- */
.topic-grid-section, .home-section, .faq-section, .related-section {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 44px 20px;
}
.section-sub { color: var(--text-muted); margin-top: -6px; margin-bottom: 24px; }

.topic-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}
@media (max-width: 900px) { .topic-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .topic-grid { grid-template-columns: 1fr; } }

.topic-card {
  background: var(--bg-card);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-md);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  color: var(--text);
  box-shadow: var(--shadow-card);
  transition: border-color 0.15s ease, transform 0.15s ease;
}
.topic-card:hover { text-decoration: none; border-color: var(--accent); transform: translateY(-2px); }
.topic-card-icon {
  width: 38px; height: 38px;
  display: flex; align-items: center; justify-content: center;
  border-radius: var(--radius-sm);
  background: var(--accent-soft);
  color: var(--accent);
  margin-bottom: 4px;
}
.topic-card-icon .icon { width: 20px; height: 20px; }
.topic-card-label { font-weight: 700; font-size: 1rem; }
.topic-card-blurb { color: var(--text-muted); font-size: 0.87rem; }

/* ---------- Quick answer / TOC ---------- */
.quick-answer-box {
  background: var(--accent-soft);
  border: 1px solid rgba(31, 223, 100, 0.28);
  border-radius: var(--radius-md);
  padding: 16px 18px;
  margin: 22px 0;
}
.quick-answer-label {
  display: inline-block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 6px;
}
.quick-answer-box p { margin: 0; color: var(--text); }

.toc {
  background: var(--bg-card);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  margin: 20px 0 30px;
}
.toc-label {
  display: block;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-faint);
  margin-bottom: 8px;
  font-weight: 700;
}
.toc ol { margin: 0; padding-left: 1.1em; columns: 2; }
.toc li { margin-bottom: 4px; }
.toc a { color: var(--text-muted); font-size: 0.92rem; }
.toc a:hover { color: var(--accent); }
@media (max-width: 560px) { .toc ol { columns: 1; } }

/* ---------- Article / content page ---------- */
.content-page {
  max-width: 760px;
  margin: 0 auto;
  padding: 26px 20px 10px;
}
.breadcrumb {
  font-size: 0.82rem;
  color: var(--text-faint);
  display: flex;
  gap: 6px;
  align-items: center;
  margin-bottom: 18px;
  flex-wrap: wrap;
}
.breadcrumb a { color: var(--text-muted); }
.breadcrumb a:hover { color: var(--accent); text-decoration: underline; }
.breadcrumb [aria-current] { color: var(--text); font-weight: 600; }
.breadcrumb-sep { display: inline-flex; align-items: center; color: var(--text-faint); }
.breadcrumb-sep-icon { width: 13px; height: 13px; }
.page-header { margin-bottom: 4px; }
.page-intro { color: var(--text-muted); font-size: 1.02rem; }

.content-blocks h2 { scroll-margin-top: 90px; }
.content-blocks p { color: var(--text); }

.content-table-wrap {
  overflow-x: auto;
  margin: 20px 0 26px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}
.content-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
  min-width: 480px;
}
.content-table th,
.content-table td {
  padding: 10px 14px;
  text-align: left;
  border-bottom: 1px solid var(--border-soft);
}
.content-table th {
  background: var(--bg-card);
  color: var(--text);
  font-weight: 700;
  white-space: nowrap;
}
.content-table td { color: var(--text-muted); }
.content-table tbody tr:last-child td { border-bottom: none; }
.content-table tbody tr:hover td { background: rgba(31, 223, 100, 0.04); }

.disclaimer-note {
  border-left: 3px solid var(--accent);
  background: var(--bg-card);
  padding: 12px 16px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin: 22px 0;
  color: var(--text-muted);
  font-size: 0.9rem;
}
.disclaimer-note p { margin: 0; }

.page-cta-row { margin: 32px 0; }

/* ---------- FAQ ---------- */
.faq-list { display: flex; flex-direction: column; gap: 10px; }
.faq-item {
  background: var(--bg-card);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-md);
  padding: 4px 18px;
}
.faq-item summary {
  cursor: pointer;
  list-style: none;
  padding: 14px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-weight: 600;
  color: var(--text);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-chevron { width: 18px; height: 18px; color: var(--text-faint); flex-shrink: 0; transition: transform 0.2s ease; }
.faq-item[open] .faq-chevron { transform: rotate(180deg); color: var(--accent); }
.faq-item p { color: var(--text-muted); padding-bottom: 14px; margin: 0; }

/* ---------- Related guides ---------- */
.related-strip { display: flex; flex-wrap: wrap; gap: 10px; }
.related-chip {
  background: var(--bg-card);
  border: 1px solid var(--border-soft);
  border-radius: 999px;
  padding: 9px 16px;
  color: var(--text);
  font-size: 0.88rem;
  font-weight: 600;
}
.related-chip:hover { border-color: var(--accent); color: var(--accent); text-decoration: none; }

/* ---------- Editorial note / responsible use ---------- */
.editorial-note {
  max-width: var(--max-width);
  margin: 10px auto 0;
  padding: 26px 20px 8px;
  border-top: 1px solid var(--border-soft);
}
.editorial-note h2 { margin-top: 0; }
.editorial-note p { color: var(--text-muted); }

.responsible-use {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 4px 20px 30px;
}
.responsible-use p {
  color: var(--text-faint);
  font-size: 0.85rem;
  border-top: 1px solid var(--border-soft);
  padding-top: 18px;
  margin: 0;
}

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--border-soft);
  background: var(--bg-elevated);
  margin-top: 20px;
}
.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 40px 20px 30px;
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 30px 26px;
  align-items: start;
}
.footer-brand-row { margin-bottom: 10px; }
.footer-note { color: var(--text-muted); font-size: 0.9rem; max-width: 380px; }
.footer-note-secondary { margin-top: 10px; }
.footer-col-title {
  display: block;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-faint);
  font-weight: 700;
  margin-bottom: 10px;
}
.footer-col ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.footer-col a { color: var(--text-muted); font-size: 0.9rem; }
.footer-col a:hover { color: var(--accent); }
.footer-legal {
  grid-column: 1 / -1;
  border-top: 1px solid var(--border-soft);
  padding-top: 20px;
  margin-top: 6px;
  color: var(--text-faint);
  font-size: 0.8rem;
}
.footer-legal p { margin: 0 0 8px; }
.footer-updated { color: var(--text-muted); }
.footer-copyright { margin-top: 12px; }

@media (max-width: 900px) {
  .footer-inner { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 560px) {
  .footer-inner { grid-template-columns: 1fr 1fr; gap: 24px 16px; }
  .footer-note { max-width: none; }
}

/* ---------- 404 ---------- */
.not-found {
  max-width: 640px;
  margin: 0 auto;
  padding: 80px 20px;
  text-align: center;
}
.not-found p { color: var(--text-muted); margin-bottom: 24px; }

/* ---------- Utility ---------- */
.icon { width: 22px; height: 22px; }
