/* ============================================================
   Golden Play — Global styles
   ============================================================ */
body {
  font-family: var(--font-main);
  font-weight: var(--fw-regular);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  color: var(--color-text);
  background: var(--color-bg-primary);
  min-height: 100dvh;
  overflow-x: hidden;
}

/* ---- Container ---- */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--container-pad);
}

.main {
  display: block;
  padding-block: var(--space-section);
  padding-bottom: var(--main-bottom);
}

.section { margin-block: var(--space-section); }
.section:first-child { margin-top: 0; }

/* Readable text column for long-form content */
.prose { max-width: var(--content-max); }

/* ---- Skip link ---- */
.skip-link {
  position: absolute;
  left: 8px;
  top: -60px;
  z-index: calc(var(--z-header) + 10);
  background: var(--color-gold);
  color: var(--color-on-gold);
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  font-weight: var(--fw-semibold);
  transition: top var(--transition);
}
.skip-link:focus { top: 8px; }

/* ---- Typography ---- */
h1, h2, h3 {
  font-family: var(--font-main);
  color: var(--color-gold);
  line-height: var(--lh-h2);
}

h1 {
  font-size: var(--fs-h1);
  font-weight: var(--fw-semibold);
  line-height: var(--lh-banner);
  letter-spacing: .2px;
}

h2 {
  font-size: var(--fs-h2);
  font-weight: var(--fw-semibold);
  text-transform: uppercase;
  line-height: 1.2;
  scroll-margin-top: calc(var(--header-h) + 20px);
}

h3 {
  font-size: var(--fs-h3);
  font-weight: var(--fw-semibold);
  color: var(--color-white);
}

p { color: var(--color-text); }
p + p { margin-top: var(--space-paragraph); }

strong { color: var(--color-white); font-weight: var(--fw-semibold); }
.text-gold { color: var(--color-gold); }

a.inline-link {
  color: var(--color-gold);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color var(--transition);
}
a.inline-link:hover { color: var(--color-gold-strong); }

/* ---- Content sections (H2 + text + optional image) ---- */
.content-block { margin-block: var(--space-section); }
.content-block > h2 { margin-bottom: var(--space-h2-text); }
.content-block h3 {
  margin-top: 26px;
  margin-bottom: var(--space-h3-text);
}
.content-block p + h3 { margin-top: 26px; }
.content-block .lead { margin-bottom: var(--space-paragraph); }
.content-block p { max-width: var(--content-max); }

/* Bullet / numbered lists inside content */
.content-list {
  margin-top: var(--space-h3-text);
  margin-bottom: var(--space-paragraph);
  display: grid;
  gap: 10px;
  max-width: var(--content-max);
}
.content-list--nested { margin-bottom: 4px; }
.content-list li {
  position: relative;
  padding-left: 26px;
  color: var(--color-text);
}
.content-list li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: .55em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-gold);
}
ol.content-list { counter-reset: step; }
ol.content-list li::before {
  content: counter(step);
  counter-increment: step;
  top: 0;
  left: 0;
  width: 22px;
  height: 22px;
  background: var(--gold-gradient);
  color: var(--color-white);
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: var(--fw-semibold);
}
ol.content-list li { padding-left: 34px; }

.content-list--nested {
  margin-top: 10px;
  margin-bottom: 4px;
}

/* ---- Content image after H2 (must display fully, never cropped) ---- */
.content-figure {
  margin: var(--space-h2-text) 0 var(--space-paragraph);
  max-width: var(--content-max);
}
.content-figure img {
  width: 100%;
  height: auto;
  object-fit: contain;      /* never crop */
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-soft);
}

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 26px;
  border-radius: var(--radius-pill);
  font-family: var(--font-main);
  font-weight: var(--fw-semibold);
  font-size: var(--fs-body);
  line-height: 1;
  text-align: center;
  transition: background-color var(--transition), transform var(--transition), color var(--transition);
}
.btn:hover { transform: translateY(-2px); }
.btn--gold { background: var(--color-gold); color: var(--color-on-gold); }
.btn--gold:hover { background: var(--color-gold-strong); }
.btn--green { background: var(--color-green); color: var(--color-white); }
.btn--green:hover { background: var(--color-green-hover); }
.btn--neutral { background: var(--color-neutral-btn); color: var(--color-white); }
.btn--neutral:hover { background: #3d3e44; }
.btn--outline {
  background: transparent;
  color: var(--color-gold);
  border: 1px solid var(--color-gold);
}
.btn--outline:hover { background: rgba(209,170,65,.12); }
.btn--lg { padding: 15px 34px; font-size: 1.05rem; }
.btn--block { width: 100%; }

.cta-row {
  margin-top: var(--space-paragraph);
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}
.cta-row--center { justify-content: center; }

/* ---- Breadcrumb ---- */
.breadcrumb {
  margin-bottom: 22px;
  font-size: var(--fs-small);
  color: var(--color-text-muted);
}
.breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.breadcrumb li { display: flex; align-items: center; gap: 8px; }
.breadcrumb li:not(:last-child)::after {
  content: "›";
  color: var(--color-gold);
}
.breadcrumb a { color: var(--color-text-muted); transition: color var(--transition); }
.breadcrumb a:hover { color: var(--color-gold); }
.breadcrumb [aria-current="page"] { color: var(--color-white); }

/* ---- Tables ---- */
.table-wrap {
  overflow-x: auto;
  border-radius: var(--radius-md);
  margin-block: var(--space-paragraph);
  max-width: min(var(--content-max), 100%);
  min-width: 0;
}
.data-table {
  background: var(--color-surface);
  border-radius: var(--radius-md);
  overflow: hidden;
  font-size: var(--fs-small);
  min-width: 420px;
}
.data-table caption {
  caption-side: top;
  text-align: left;
  padding: 16px 18px 0;
  color: var(--color-gold);
  font-weight: var(--fw-semibold);
}
.data-table th,
.data-table td {
  padding: 13px 18px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--color-border);
}
.data-table thead th {
  background: var(--color-bg-dark);
  color: var(--color-gold);
  font-weight: var(--fw-semibold);
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: .4px;
}
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table tbody th {
  color: var(--color-white);
  font-weight: var(--fw-medium);
  width: 42%;
}
.data-table tbody tr:nth-child(even) { background: rgba(255,255,255,.02); }

/* ---- Section intro spacing ---- */
.section-head { margin-bottom: var(--space-h2-text); }

/* ---- Cards grid helper ---- */
.grid { display: grid; gap: var(--space-card-gap); }

/* ---- To-top button ---- */
.to-top {
  position: fixed;
  right: 22px;
  bottom: 22px;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--color-gold);
  color: var(--color-on-gold);
  box-shadow: var(--shadow-card);
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity var(--transition), transform var(--transition), visibility var(--transition), background-color var(--transition);
  z-index: var(--z-totop);
}
.to-top.is-visible { opacity: 1; visibility: visible; transform: translateY(0); }
.to-top:hover { background: var(--color-gold-strong); }
.to-top svg { width: 22px; height: 22px; }

/* ---- Fade-in on scroll ---- */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity var(--transition-slow), transform var(--transition-slow);
  will-change: opacity, transform;
}
.fade-in.is-visible { opacity: 1; transform: translateY(0); }

/* ---- Info / note callout ---- */
.note {
  background: var(--color-surface);
  border-left: 3px solid var(--color-gold);
  border-radius: var(--radius-sm);
  padding: 16px 18px;
  margin-top: var(--space-paragraph);
  max-width: var(--content-max);
  color: var(--color-text-muted);
  font-size: var(--fs-small);
}

/* ---- Responsive typography adjustments ---- */
@media (min-width: 768px) {
  .content-figure { float: none; }
}

/* ---- Reduced motion: neutralise transitions/animations via tokens ---- */
@media (prefers-reduced-motion: reduce) {
  :root { --transition: 1ms; --transition-slow: 1ms; }
  .fade-in { opacity: 1; transform: none; }
  html { scroll-behavior: auto; }
}
html { scroll-behavior: smooth; }
