/* ==========================================================================
   Sound Health — bitcoinbarbell.com
   One House, Two Doors: bone-light default, jungle-dark accents.
   Same tokens as the sister site (bitcoinsgym.com); inverted page default.
   No frameworks, no webfonts, no render-blocking bloat.
   ========================================================================== */

:root {
  --orange: #f7931a;
  --orange-deep: #d97a06;
  --orange-ink: #964e00;  /* AA text on bone/sand/sand-deep/white (>=4.5:1) */
  --orange-soft: rgba(247, 147, 26, 0.14);

  --jungle-950: #0a140e;
  --jungle-900: #0e1b13;
  --jungle-800: #142519;
  --jungle-700: #1d3323;
  --leaf: #4c9a63;
  --leaf-bright: #6fbe86;
  --leaf-ink: #2f7042;    /* AA text on bone/sand (>=4.5:1) */

  --sand: #f2ead9;
  --sand-deep: #e7dcc4;
  --bone: #fbf7ee;
  --ink: #16211a;
  --ink-soft: #45523f;
  --mist: rgba(251, 247, 238, 0.72);

  --font-sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --container: 72rem;
  --radius: 0.9rem;
  --shadow: 0 20px 50px -18px rgba(4, 10, 6, 0.35);
}

/* ---------- Reset & base ---------- */

*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bone);
}

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

h1, h2, h3 { line-height: 1.15; margin: 0 0 1rem; letter-spacing: -0.02em; font-weight: 800; }
p { margin: 0 0 1rem; }
ul, ol, dl { margin: 0; padding: 0; }

a { color: var(--orange-ink); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }

::selection { background: rgba(247, 147, 26, 0.35); color: #fff; }

:focus-visible {
  outline: 2px solid var(--orange);
  outline-offset: 3px;
  border-radius: 2px;
}

[id] { scroll-margin-top: 5rem; }

.container {
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 4vw, 2.5rem);
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  z-index: 100;
  background: var(--orange);
  color: var(--jungle-950);
  padding: 0.6rem 1rem;
  border-radius: 0 0 var(--radius) 0;
  font-weight: 700;
}
.skip-link:focus { left: 0; }

/* ---------- Header / nav ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--bone);
  border-bottom: 1px solid var(--sand-deep);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4.25rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  color: var(--ink);
  text-decoration: none;
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: 0.01em;
}
.brand:hover { color: var(--ink); }

.brand-tick {
  color: var(--orange);
  font-weight: 800;
  font-size: 1.35rem;
  line-height: 1;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: clamp(0.7rem, 1.8vw, 1.5rem);
  list-style: none;
}

.nav-menu a {
  color: var(--ink-soft);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  white-space: nowrap;
}
.nav-menu a:hover { color: var(--orange-ink); }

.nav-cta {
  display: inline-block;
  padding: 0.5rem 1.1rem;
  border-radius: 999px;
  background: var(--orange);
  color: var(--jungle-950) !important;
  font-weight: 700;
}
.nav-cta:hover { background: var(--orange-deep); }

.nav-toggle {
  display: none;
  position: relative;
  width: 2.75rem;
  height: 2.75rem;
  border: 0;
  border-radius: 0.5rem;
  background: transparent;
  cursor: pointer;
}

.nav-toggle-bar,
.nav-toggle-bar::before,
.nav-toggle-bar::after {
  content: "";
  position: absolute;
  left: 50%;
  width: 1.5rem;
  height: 2px;
  background: var(--ink);
  transform: translateX(-50%);
  transition: transform 0.25s ease, opacity 0.25s ease;
}
.nav-toggle-bar { top: calc(50% - 1px); }
.nav-toggle-bar::before { top: -7px; }
.nav-toggle-bar::after { top: 7px; }

.nav-toggle[aria-expanded="true"] .nav-toggle-bar { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar::before { transform: translateX(-50%) translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar::after { transform: translateX(-50%) translateY(-7px) rotate(-45deg); }

/* 7 items + brand only fit on one line from ~1020px; hamburger below that */
@media (max-width: 1023px) {
  .nav-toggle { display: block; }

  .nav-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--bone);
    border-bottom: 1px solid var(--sand-deep);
    padding: 0.5rem 1.25rem 1.25rem;
    display: none;
    box-shadow: var(--shadow);
  }
  .nav-menu.open { display: flex; }
  .nav-menu li { border-top: 1px solid var(--sand-deep); }
  .nav-menu li:first-child { border-top: 0; }
  .nav-menu a { display: block; padding: 0.9rem 0.25rem; font-size: 1.05rem; }
  .nav-menu .nav-cta { margin-top: 0.75rem; text-align: center; border-radius: 0.6rem; }
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  min-height: calc(100svh - 4.25rem);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  isolation: isolate;
}

.hero-media,
.hero-media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
}

.hero-scrim {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(to top,
      rgba(10, 20, 14, 0.94) 0%,
      rgba(10, 20, 14, 0.55) 34%,
      rgba(10, 20, 14, 0.28) 64%,
      rgba(10, 20, 14, 0.5) 100%);
}

.hero-inner {
  width: 100%;
  padding-top: 6rem;
  padding-bottom: clamp(3rem, 8vh, 6rem);
}

.eyebrow {
  display: inline-block;
  padding: 0.45rem 1rem;
  border: 1px solid rgba(247, 147, 26, 0.45);
  border-radius: 999px;
  background: rgba(10, 20, 14, 0.55);
  color: var(--orange);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
}

.hero-title {
  font-size: clamp(2.9rem, 8vw, 6.5rem);
  color: var(--bone);
  text-wrap: balance;
  margin-bottom: 1.25rem;
}

.hero-title em {
  font-style: normal;
  color: var(--orange);
}

.hero-sub {
  max-width: 44rem;
  font-size: clamp(1.1rem, 2.2vw, 1.35rem);
  color: var(--mist);
  margin-bottom: 2.25rem;
  text-wrap: pretty;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 0.9rem; }

/* ---------- Buttons ---------- */

.btn {
  display: inline-block;
  padding: 0.95rem 1.9rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 1.02rem;
  text-decoration: none;
  transition: transform 0.15s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}
.btn:hover { transform: translateY(-2px); }

.btn-primary {
  background: var(--orange);
  color: var(--jungle-950);
  box-shadow: 0 12px 32px -10px rgba(247, 147, 26, 0.55);
}
.btn-primary:hover { background: var(--orange-deep); color: var(--jungle-950); }

.btn-ghost {
  background: rgba(251, 247, 238, 0.08);
  color: var(--bone);
  border: 1px solid rgba(251, 247, 238, 0.35);
  backdrop-filter: blur(6px);
}
.btn-ghost:hover { background: rgba(251, 247, 238, 0.16); color: var(--bone); }

/* ---------- Ticker ---------- */

.ticker {
  overflow: hidden;
  border-top: 1px solid rgba(247, 147, 26, 0.35);
  background: rgba(10, 20, 14, 0.85);
  padding: 0.7rem 0;
}

.ticker-track {
  display: flex;
  gap: 2.25rem;
  width: max-content;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(251, 247, 238, 0.75);
  white-space: nowrap;
}

.ticker-track.ready { animation: ticker 30s linear infinite; }
.ticker:hover .ticker-track.ready { animation-play-state: paused; }

.ticker .tick { color: var(--orange); letter-spacing: 0; }

@keyframes ticker {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* ---------- Sections ---------- */

.section { padding-block: clamp(4rem, 10vw, 7.5rem); }

.section h2 {
  font-size: clamp(2rem, 4.5vw, 3.2rem);
  text-wrap: balance;
}

.section-dark {
  background: radial-gradient(70rem 40rem at 50% -10%, var(--jungle-900), var(--jungle-950));
  color: var(--mist);
}
.section-dark h2, .section-dark h3 { color: var(--bone); }

.section-sand { background: var(--sand); color: var(--ink-soft); }
.section-sand h2, .section-sand h3 { color: var(--ink); }
.section-sand .lead { color: var(--ink-soft); }

.section-jungle {
  background:
    radial-gradient(60rem 30rem at 85% -10%, rgba(76, 154, 99, 0.18), transparent 60%),
    radial-gradient(50rem 28rem at 0% 110%, rgba(247, 147, 26, 0.1), transparent 60%),
    var(--jungle-950);
  color: var(--mist);
}
.section-jungle h2, .section-jungle h3 { color: var(--bone); }
.section-jungle a:not(.btn) { color: var(--orange); }
.section-jungle-800 {
  background:
    radial-gradient(60rem 30rem at 85% -10%, rgba(76, 154, 99, 0.14), transparent 60%),
    var(--jungle-800);
}

.kicker {
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--orange);
  margin-bottom: 0.9rem;
}
.section-sand .kicker, .section-rail .kicker, #how-it-works .kicker, .section-film .kicker { color: var(--orange-ink); }

.badge {
  display: inline-block;
  padding: 0.4rem 0.95rem;
  border: 1px solid rgba(217, 122, 6, 0.5);
  border-radius: 999px;
  background: var(--orange-soft);
  color: var(--orange-ink);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 1.1rem;
}

.badge-dark {
  border-color: rgba(247, 147, 26, 0.45);
  background: rgba(10, 20, 14, 0.45);
  color: var(--orange);
}

.lead {
  font-size: clamp(1.1rem, 2vw, 1.25rem);
  text-wrap: pretty;
}
.section-dark .lead, .section-jungle .lead { color: rgba(251, 247, 238, 0.85); }

.section-head { max-width: 46rem; margin-bottom: clamp(2.5rem, 6vw, 4rem); }

.section-actions { margin-top: 2rem; }

.text-cta { margin-top: 1.75rem; }
.text-cta a {
  font-weight: 700;
  font-size: 1.05rem;
  text-decoration: none;
}
.text-cta a:hover { text-decoration: underline; }
.section-jungle .text-cta a, .section-jungle-800 .text-cta a { color: var(--orange); }

.grid-2 {
  display: grid;
  gap: clamp(2.5rem, 6vw, 5rem);
  align-items: center;
}

@media (min-width: 900px) {
  .grid-2 { grid-template-columns: 1fr 1fr; }
}

/* ---------- Offer rail ---------- */

.section-rail { padding-block: clamp(3rem, 7vw, 5rem); }

.rail-title {
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 1.5rem;
}

.rail-list {
  list-style: none;
  display: grid;
  gap: 1.1rem;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
}

.rail-card {
  position: relative;
  display: block;
  height: 100%;
  padding: 1.5rem 1.6rem 1.4rem;
  border-radius: var(--radius);
  background: #fff;
  border: 1px solid var(--sand-deep);
  text-decoration: none;
  color: var(--ink-soft);
  transition: transform 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.rail-card:hover {
  transform: translateY(-2px);
  border-color: var(--orange);
  box-shadow: 0 14px 34px -20px rgba(22, 33, 26, 0.35);
  color: var(--ink-soft);
}

.rail-card .kicker { margin-bottom: 0.5rem; }
.rail-card h3 { font-size: 1.25rem; color: var(--ink); margin-bottom: 0.4rem; }
.rail-card p:last-of-type { margin: 0; font-size: 0.95rem; }

.rail-arrow {
  position: absolute;
  top: 1.35rem;
  right: 1.4rem;
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--orange-ink);
  transition: transform 0.16s ease;
}
.rail-card:hover .rail-arrow { transform: translateX(3px); }

/* ---------- Cards (dark sections) ---------- */

.card-list { list-style: none; display: grid; gap: 1.1rem; margin-top: 1.5rem; }

.card-grid { margin-top: 0; }
@media (min-width: 720px) {
  .card-grid { grid-template-columns: 1fr 1fr; }
}

.card {
  padding: 1.5rem 1.6rem;
  border-radius: var(--radius);
  background: rgba(251, 247, 238, 0.04);
  border: 1px solid rgba(251, 247, 238, 0.1);
  transition: border-color 0.25s ease, background-color 0.25s ease, transform 0.25s ease;
}

.card:hover {
  border-color: rgba(247, 147, 26, 0.45);
  background: rgba(247, 147, 26, 0.06);
  transform: translateY(-2px);
}

.card h3 { font-size: 1.2rem; margin-bottom: 0.4rem; }
.card p { margin: 0; font-size: 0.97rem; color: rgba(251, 247, 238, 0.72); }

.pull-quote {
  margin: 2rem 0 0;
  padding: 1.25rem 1.5rem;
  border-left: 4px solid var(--orange);
  background: rgba(247, 147, 26, 0.07);
  border-radius: 0 var(--radius) var(--radius) 0;
}
.pull-quote p {
  margin: 0 0 0.35rem;
  font-size: 1.15rem;
  font-weight: 700;
  font-style: italic;
  color: var(--bone);
}
.pull-quote footer { font-size: 0.9rem; color: rgba(251, 247, 238, 0.6); }

/* ---------- Media figures ---------- */

figure { margin: 0; }

.media-stack {
  position: relative;
  padding-bottom: 4.5rem;
}

.media-stack img {
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.media-stack .media-stack-offset {
  position: absolute;
  right: -0.5rem;
  bottom: 0;
  width: 52%;
  border: 5px solid var(--bone);
}

.media-single img {
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  width: 100%;
}

.media-single figcaption {
  margin-top: 0.8rem;
  font-size: 0.9rem;
  color: var(--ink-soft);
  font-style: italic;
}

.media-narrow {
  max-width: 46rem;
  margin: clamp(2.5rem, 6vw, 4rem) auto 0;
}

/* ---------- Loc facts ---------- */

.loc-facts {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
  margin-top: 1.75rem;
}

.loc-fact {
  border: 1px solid rgba(22, 33, 26, 0.12);
  border-radius: var(--radius);
  padding: 1.1rem 1.2rem;
  background: var(--bone);
}

.loc-fact dt {
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--leaf-ink);
  margin-bottom: 0.3rem;
}

.loc-fact dd { margin: 0; font-size: 1.02rem; font-weight: 600; color: var(--ink); }

/* ---------- Film facade ---------- */

.film-figure { max-width: 67rem; margin-inline: auto; }
.film-figure + .film-figure { margin-top: clamp(2.5rem, 6vw, 4rem); }

.film-facade {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  background: var(--jungle-950);
}

.film-facade iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.film-play {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
}

.film-play img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.film-play-btn {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: grid;
  place-items: center;
  width: 5rem;
  height: 5rem;
  border-radius: 50%;
  background: var(--orange);
  color: var(--jungle-950);
  box-shadow: 0 12px 40px -8px rgba(247, 147, 26, 0.7);
  transition: transform 0.16s ease, background-color 0.2s ease;
}
.film-play:hover .film-play-btn {
  transform: translate(-50%, -50%) scale(1.07);
  background: var(--orange-deep);
}

.film-figure figcaption {
  margin-top: 0.8rem;
  text-align: center;
  font-size: 0.9rem;
  color: var(--ink-soft);
  font-style: italic;
}

/* ---------- Ledger (compare) ---------- */

.ledger-wrap {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid rgba(22, 33, 26, 0.14);
  box-shadow: var(--shadow);
  overflow-x: auto;
}

.ledger {
  width: 100%;
  border-collapse: collapse;
  min-width: 34rem;
}

.ledger th, .ledger td {
  padding: 1.05rem 1.3rem;
  text-align: left;
  vertical-align: top;
  width: 50%;
  font-size: 0.98rem;
}

.ledger th {
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.ledger td { border-top: 1px solid rgba(22, 33, 26, 0.1); }

.ledger .ledger-con { background: var(--sand-deep); color: var(--ink-soft); }
.ledger th.ledger-con { color: var(--orange-ink); }
.ledger .ledger-sh { background: var(--bone); color: var(--ink); }
.ledger th.ledger-sh { color: var(--leaf-ink); }

.mark {
  display: inline-block;
  width: 1.5rem;
  font-weight: 800;
}
.mark-x { color: var(--orange-ink); }
.mark-check { color: var(--leaf-ink); }

/* Mobile: stack each ✕/✓ pair instead of forcing a horizontal scroll */
@media (max-width: 699px) {
  .ledger { min-width: 0; }
  .ledger thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
  }
  .ledger tr, .ledger td { display: block; width: 100%; }
  .ledger td { border-top: 0; }
  .ledger tbody tr { border-top: 2px solid rgba(22, 33, 26, 0.14); }
  .ledger tbody tr:first-child { border-top: 0; }
}

/* ---------- Timeline (how it works) ---------- */

.timeline {
  list-style: none;
  display: grid;
  gap: 2rem;
  position: relative;
  padding-left: 0;
}

.step {
  display: flex;
  gap: 1.4rem;
  align-items: flex-start;
  position: relative;
}

.step::before {
  content: "";
  position: absolute;
  left: 1.6rem;
  top: 3.2rem;
  bottom: -2rem;
  width: 2px;
  background: var(--sand-deep);
}
.step:last-child::before { display: none; }

.step-num {
  flex: none;
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--orange);
  letter-spacing: -0.02em;
  width: 3.2rem;
  line-height: 1.4;
}

.step h3 { font-size: 1.2rem; margin-bottom: 0.35rem; color: var(--ink); }
.step p { margin: 0; color: var(--ink-soft); font-size: 0.98rem; }

/* ---------- Contact ---------- */

.section-contact { text-align: center; }

.contact-inner { max-width: 44rem; }
.contact-inner h2 { font-size: clamp(2.1rem, 5vw, 3.4rem); }
.contact-inner .lead { margin-bottom: 2rem; }

.contact-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.9rem;
}

.contact-email { margin-top: 1.75rem; font-size: 1.1rem; font-weight: 600; }

.cta-fineprint {
  margin-top: 1rem;
  margin-bottom: 0;
  font-size: 0.9rem;
  color: var(--ink-soft);
}

/* ---------- Footer ---------- */

.site-footer {
  background: var(--jungle-950);
  color: var(--mist);
  border-top: 1px solid rgba(251, 247, 238, 0.08);
  padding-top: 3.25rem;
  font-size: 0.95rem;
}

.site-footer a { color: var(--orange); }
.site-footer a:hover { color: var(--orange-deep); }

.footer-grid {
  display: grid;
  gap: 2rem;
  padding-bottom: 2.5rem;
}

@media (min-width: 700px) {
  .footer-grid { grid-template-columns: 1.2fr 1.4fr 1fr; }
}

.footer-brand {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--bone);
  margin-bottom: 0.25rem;
}

.footer-tag { color: rgba(251, 247, 238, 0.7); }

.footer-heading {
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(251, 247, 238, 0.5);
  margin-bottom: 0.6rem;
}

.footer-text { color: rgba(251, 247, 238, 0.7); }

.footer-legal {
  border-top: 1px solid rgba(251, 247, 238, 0.08);
  padding-block: 1.4rem;
  color: rgba(251, 247, 238, 0.6);
  font-size: 0.85rem;
}
.footer-legal p { margin: 0; }

/* ---------- Reveal on scroll ---------- */
/* Hidden state only applies when JS is running (html.js added by main.js),
   so no-JS visitors always see full content. */

html.js .reveal {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}

html.js .reveal.in {
  opacity: 1;
  transform: none;
}

/* No-JS and reduced motion: everything visible, nothing moves */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  html.js .reveal { opacity: 1; transform: none; transition: none; }
  .ticker-track.ready { animation: none; }
  .btn:hover, .card:hover, .rail-card:hover { transform: none; }
  .film-play:hover .film-play-btn { transform: translate(-50%, -50%); }
}
