/* BTC Cycle Lab landing — "The Observatory": obsidian, instrument-grade,
   Bitcoin-orange with teal/amber cycle anchors. */

:root {
  --ink: #0b0e15;
  --ink-2: #10141f;
  --panel: rgba(20, 25, 38, 0.66);
  --line: rgba(255, 255, 255, 0.09);
  --text: #e6e9f2;
  --dim: #98a0b3;
  --orange: #f7931a;
  --orange-hot: #ffb14d;
  --teal: #14b8a6;
  --amber: #f59e0b;
  --red: #ef5350;
  --green: #26a69a;
  --disp: "Unbounded", sans-serif;
  --body: "Sora", sans-serif;
  --mono: "IBM Plex Mono", monospace;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--ink);
  color: var(--text);
  font-family: var(--body);
  font-weight: 300;
  line-height: 1.65;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
b, strong { font-weight: 600; }
a { color: inherit; }
img { max-width: 100%; display: block; }

.teal { color: var(--teal); }
.amber { color: var(--amber); }

/* film grain + scroll progress */
.grain {
  position: fixed; inset: -50%; z-index: 90; pointer-events: none; opacity: .05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)' opacity='0.6'/%3E%3C/svg%3E");
  animation: grain 7s steps(9) infinite;
}
@keyframes grain {
  0%,100% { transform: translate(0,0); } 20% { transform: translate(-4%,3%); }
  40% { transform: translate(3%,-4%); } 60% { transform: translate(-2%,-3%); } 80% { transform: translate(4%,2%); }
}
.scroll-progress {
  position: fixed; top: 0; left: 0; height: 2px; width: 0; z-index: 100;
  background: linear-gradient(90deg, var(--teal), var(--orange), var(--amber));
  box-shadow: 0 0 12px rgba(247, 147, 26, .7);
}

/* ============================== HERO ============================== */

.hero { position: relative; min-height: 100svh; display: flex; flex-direction: column; overflow: hidden; }

#hero-candles { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .5; }

.hero-aurora {
  position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(55% 42% at 78% 18%, rgba(247, 147, 26, .17), transparent 65%),
    radial-gradient(45% 38% at 15% 75%, rgba(20, 184, 166, .13), transparent 65%),
    radial-gradient(60% 50% at 50% 110%, rgba(245, 158, 11, .10), transparent 70%);
  animation: aurora 14s ease-in-out infinite alternate;
}
@keyframes aurora {
  from { transform: translate3d(0,0,0) scale(1); opacity: .9; }
  to   { transform: translate3d(-2%,2%,0) scale(1.08); opacity: 1; }
}
.hero-grid {
  position: absolute; inset: 0; pointer-events: none; opacity: .5;
  background-image:
    linear-gradient(rgba(255,255,255,.033) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.033) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(75% 60% at 50% 45%, #000 30%, transparent 100%);
}
.hero-fade {
  position: absolute; left: 0; right: 0; bottom: 0; height: 140px; pointer-events: none;
  background: linear-gradient(transparent, var(--ink));
}

.nav {
  position: relative; z-index: 5;
  display: flex; justify-content: space-between; align-items: center;
  padding: 22px clamp(20px, 5vw, 64px);
}
.nav-brand { display: flex; align-items: center; gap: 10px; }
.brand-coin {
  display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%;
  font-weight: 700; color: #1a1205;
  background: radial-gradient(circle at 32% 28%, #ffd27a, var(--orange) 62%, #c46f08);
  box-shadow: 0 0 22px rgba(247,147,26,.55), inset 0 -2px 5px rgba(0,0,0,.3);
  animation: coin-glow 3.2s ease-in-out infinite;
}
@keyframes coin-glow {
  0%,100% { box-shadow: 0 0 14px rgba(247,147,26,.4), inset 0 -2px 5px rgba(0,0,0,.3); }
  50% { box-shadow: 0 0 30px rgba(247,147,26,.75), inset 0 -2px 5px rgba(0,0,0,.3); }
}
.brand-word { font-family: var(--disp); font-weight: 300; font-size: 15px; letter-spacing: .14em; }
.brand-word b { font-weight: 700; color: var(--orange); }
.brand-word.small { font-size: 12px; }

.nav-links { display: flex; align-items: center; gap: clamp(14px, 2.6vw, 34px); font-size: 14px; }
.nav-links a { text-decoration: none; color: var(--dim); transition: color .2s; }
.nav-links a:hover { color: var(--text); }
.nav-cta {
  color: var(--text) !important;
  border: 1px solid rgba(247,147,26,.55); border-radius: 999px;
  padding: 8px 18px; transition: background .2s, box-shadow .2s;
}
.nav-cta:hover { background: rgba(247,147,26,.14); box-shadow: 0 0 18px rgba(247,147,26,.35); }

.hero-inner {
  position: relative; z-index: 5;
  max-width: 1060px; margin: auto;
  padding: clamp(30px, 6vh, 70px) 24px;
  text-align: center;
}

.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--mono); font-size: 12.5px; letter-spacing: .12em; color: var(--dim);
  border: 1px solid var(--line); border-radius: 999px; padding: 8px 16px;
  background: rgba(11,14,21,.55); backdrop-filter: blur(6px);
}
.pulse-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); animation: pulse 1.8s infinite; }
@keyframes pulse { 0%,100% { opacity: 1; box-shadow: 0 0 0 0 rgba(38,166,154,.6);} 50% { opacity: .6; box-shadow: 0 0 0 7px rgba(38,166,154,0);} }
.hero-price { color: var(--text); font-weight: 600; min-width: 90px; transition: color .3s; }
.hero-price.up { color: var(--green); }
.hero-price.down { color: var(--red); }

.hero-title {
  font-family: var(--disp);
  font-weight: 900;
  font-size: clamp(38px, 7.2vw, 92px);
  line-height: 1.04;
  letter-spacing: -.01em;
  margin: 34px 0 26px;
}
.hero-title span { display: block; }
.hero-title-accent {
  background: linear-gradient(100deg, var(--orange-hot), var(--orange) 45%, var(--amber));
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 0 26px rgba(247,147,26,.3));
}

.hero-sub { max-width: 680px; margin: 0 auto 38px; font-size: clamp(15px, 1.6vw, 18px); color: var(--dim); }
.hero-sub b { font-weight: 600; }

.hero-actions { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

.btn-primary {
  position: relative; overflow: hidden;
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--disp); font-weight: 500; font-size: 15px;
  color: #17110a; text-decoration: none;
  background: linear-gradient(120deg, #ffc267, var(--orange) 55%, #e07f06);
  padding: 16px 30px; border-radius: 14px;
  box-shadow: 0 8px 34px rgba(247,147,26,.4), inset 0 1px 0 rgba(255,255,255,.4);
  transition: transform .18s ease, box-shadow .18s ease;
}
.btn-primary:hover { transform: translateY(-2px) scale(1.02); box-shadow: 0 14px 44px rgba(247,147,26,.55), inset 0 1px 0 rgba(255,255,255,.4); }
.btn-primary:active { transform: translateY(0) scale(.99); }
.btn-shine {
  position: absolute; top: 0; bottom: 0; width: 55%; left: -80%;
  background: linear-gradient(105deg, transparent, rgba(255,255,255,.55), transparent);
  transform: skewX(-18deg);
  animation: shine 3.6s ease-in-out infinite;
}
@keyframes shine { 0%, 55% { left: -80%; } 78%, 100% { left: 130%; } }
.btn-big { font-size: 17px; padding: 19px 38px; }

.btn-ghost {
  display: inline-flex; align-items: center;
  font-size: 15px; color: var(--dim); text-decoration: none;
  padding: 16px 24px; border: 1px solid var(--line); border-radius: 14px;
  transition: color .2s, border-color .2s, background .2s;
}
.btn-ghost:hover { color: var(--text); border-color: rgba(255,255,255,.25); background: rgba(255,255,255,.04); }

.hero-fine { margin-top: 22px; font-size: 13px; color: rgba(152,160,179,.75); }

/* load-in animation */
.reveal-load { opacity: 0; transform: translateY(26px); animation: rise .9s cubic-bezier(.2,.7,.2,1) forwards; animation-delay: var(--d, 0s); }
@keyframes rise { to { opacity: 1; transform: none; } }

/* ============================== MARQUEE ============================== */

.marquee {
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  background: rgba(16,20,31,.8); overflow: hidden; padding: 15px 0;
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee-track {
  display: inline-flex; align-items: center; gap: 34px; white-space: nowrap;
  font-family: var(--mono); font-size: 13.5px; letter-spacing: .1em; color: var(--dim);
  animation: marquee 36s linear infinite; will-change: transform;
}
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee-track span { color: var(--text); }
.marquee-track i { color: var(--orange); font-style: normal; font-size: 9px; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ============================== SECTIONS ============================== */

.section { position: relative; padding: clamp(70px, 11vh, 130px) clamp(20px, 5vw, 64px); max-width: 1280px; margin: 0 auto; }
.section-alt::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(50% 40% at 85% 8%, rgba(247,147,26,.06), transparent 70%),
    radial-gradient(45% 45% at 8% 90%, rgba(20,184,166,.06), transparent 70%);
}

.section-head { max-width: 720px; margin-bottom: clamp(40px, 6vh, 70px); }
.kicker {
  font-family: var(--mono); font-size: 12.5px; letter-spacing: .28em; color: var(--orange);
}
.section-head h2, .finale h2 {
  font-family: var(--disp); font-weight: 700;
  font-size: clamp(26px, 3.6vw, 44px); line-height: 1.18; margin: 14px 0 18px;
}
.section-head p { color: var(--dim); font-size: 16.5px; }

/* scroll reveal */
.reveal { opacity: 0; transform: translateY(34px); transition: opacity .9s cubic-bezier(.2,.7,.2,1), transform .9s cubic-bezier(.2,.7,.2,1); transition-delay: var(--d, 0s); }
.reveal.in { opacity: 1; transform: none; }

/* ---------- anatomy ---------- */

.anatomy {
  background: var(--panel); border: 1px solid var(--line); border-radius: 20px;
  padding: clamp(16px, 3vw, 40px); backdrop-filter: blur(8px);
  box-shadow: 0 30px 80px rgba(0,0,0,.45);
}
.anatomy svg { width: 100%; height: auto; }
.anatomy figcaption { text-align: center; font-size: 13px; color: var(--dim); margin-top: 14px; font-family: var(--mono); }

#anatomy-curve { stroke-dasharray: 1400; stroke-dashoffset: 1400; filter: drop-shadow(0 0 8px rgba(247,147,26,.35)); }
.anatomy.in #anatomy-curve { animation: drawline 2.2s cubic-bezier(.4,0,.2,1) forwards .2s; }
@keyframes drawline { to { stroke-dashoffset: 0; } }

.an-line { stroke-width: 2; stroke-dasharray: 5 6; opacity: 0; }
.an-halving { stroke: var(--orange); stroke-width: 3; }
.an-bottom { stroke: var(--teal); }
.an-top { stroke: var(--amber); }
.anatomy.in .an-line { animation: fadein .6s forwards; }
.anatomy.in .an-bottom { animation-delay: .9s; }
.anatomy.in .an-halving { animation-delay: 1.4s; }
.anatomy.in .an-top { animation-delay: 1.9s; }

.an-marker { opacity: 0; }
.an-marker circle { stroke-width: 3; fill: var(--ink); }
.an-m-bottom circle { stroke: var(--teal); }
.an-m-halving circle { stroke: var(--orange); fill: var(--orange); filter: drop-shadow(0 0 10px rgba(247,147,26,.8)); }
.an-m-top circle { stroke: var(--amber); }
.anatomy.in .an-m-bottom { animation: fadein .6s forwards .9s; }
.anatomy.in .an-m-halving { animation: fadein .6s forwards 1.4s; }
.anatomy.in .an-m-top { animation: fadein .6s forwards 1.9s; }
.an-label { font-family: var(--disp); font-size: 15px; font-weight: 700; }
.an-days { font-family: var(--mono); font-size: 14px; }
.teal-t { fill: var(--teal); } .orange-t { fill: var(--orange); } .amber-t { fill: var(--amber); }

.an-total { opacity: 0; }
.anatomy.in .an-total { animation: fadein .8s forwards 2.4s; }
.an-total-line { stroke: rgba(230,233,242,.4); stroke-width: 1.5; marker-start: none; }
.an-total-text { fill: var(--dim); font-family: var(--mono); font-size: 12.5px; }
@keyframes fadein { to { opacity: 1; } }

/* ---------- stats ---------- */

.stat-row {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 16px; margin-top: 46px;
}
.stat {
  background: var(--panel); border: 1px solid var(--line); border-radius: 16px;
  padding: 24px 20px; text-align: center; position: relative; overflow: hidden;
}
.stat::after {
  content: ""; position: absolute; inset: auto 0 0 0; height: 2px;
  background: linear-gradient(90deg, transparent, var(--orange), transparent); opacity: .6;
}
.stat em {
  display: block; font-style: normal; font-family: var(--disp); font-weight: 700;
  font-size: clamp(30px, 3.4vw, 44px); color: var(--orange-hot);
  text-shadow: 0 0 24px rgba(247,147,26,.3);
  font-variant-numeric: tabular-nums;
}
.stat span { display: block; margin-top: 8px; font-size: 13px; color: var(--dim); line-height: 1.5; }

/* ---------- features ---------- */

.feature {
  display: grid; grid-template-columns: minmax(280px, 5fr) 7fr;
  gap: clamp(24px, 4vw, 60px); align-items: center;
  margin-bottom: clamp(60px, 9vh, 110px);
}
.feature-flip { grid-template-columns: 7fr minmax(280px, 5fr); }
.feature-flip .feature-copy { order: 2; }
.feature-flip .shot { order: 1; }

.feature-copy h3 {
  font-family: var(--disp); font-weight: 700; font-size: clamp(20px, 2.3vw, 27px);
  line-height: 1.25; margin-bottom: 16px; display: flex; align-items: baseline; gap: 14px;
}
.f-num {
  font-size: 13px; font-weight: 500; color: var(--orange);
  border: 1px solid rgba(247,147,26,.5); border-radius: 8px; padding: 3px 9px;
  flex: 0 0 auto;
}
.feature-copy p { color: var(--dim); font-size: 15.5px; margin-bottom: 18px; }
.feature-copy p b { color: var(--text); }

.chips { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; }
.chips li {
  font-family: var(--mono); font-size: 12px; color: var(--text);
  border: 1px solid var(--line); border-radius: 999px; padding: 5px 12px;
  background: rgba(255,255,255,.03);
}

.shot { perspective: 1100px; }
.shot img, .mini-shots img {
  border-radius: 14px; border: 1px solid rgba(255,255,255,.13);
  box-shadow: 0 24px 70px rgba(0,0,0,.55), 0 0 0 1px rgba(0,0,0,.4);
  transition: transform .25s ease, box-shadow .25s ease;
  will-change: transform;
}
.tilt img, img.tilt { transform-style: preserve-3d; }
.mini-shots { display: flex; gap: 12px; }
.mini-shots img { width: calc(50% - 6px); }

/* ---------- steps ---------- */

.steps {
  list-style: none; display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 18px;
  counter-reset: step;
}
.steps li {
  position: relative; background: var(--panel); border: 1px solid var(--line);
  border-radius: 18px; padding: 28px 24px 24px; overflow: hidden;
  transition: transform .25s ease, border-color .25s ease;
}
.steps li:hover { transform: translateY(-6px); border-color: rgba(247,147,26,.45); }
.steps li:hover .step-n { color: rgba(247,147,26,.4); }
.step-n {
  position: absolute; top: -6px; right: 10px;
  font-family: var(--disp); font-weight: 900; font-size: 64px;
  color: rgba(255,255,255,.06); transition: color .25s;
}
.steps h4 { font-family: var(--disp); font-weight: 500; font-size: 16.5px; margin-bottom: 12px; }
.steps p { font-size: 14px; color: var(--dim); }
.steps code {
  font-family: var(--mono); font-size: 12.5px; color: var(--orange-hot);
  background: rgba(247,147,26,.09); border-radius: 6px; padding: 1.5px 7px;
}

/* ---------- toolkit ---------- */

.inline-link { color: var(--orange-hot); text-decoration: none; border-bottom: 1px dotted rgba(247,147,26,.6); }
.inline-link:hover { border-bottom-style: solid; }

.tool-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(330px, 1fr)); gap: 16px; }
.tool {
  background: var(--panel); border: 1px solid var(--line); border-radius: 16px;
  padding: 22px 22px 16px; transition: border-color .25s, transform .25s;
}
.tool:hover { border-color: rgba(247,147,26,.35); transform: translateY(-3px); }
.tool h4 {
  font-family: var(--disp); font-weight: 500; font-size: 15.5px; line-height: 1.4;
  display: flex; justify-content: space-between; align-items: baseline; gap: 10px; flex-wrap: wrap;
  margin-bottom: 10px;
}
.tool-tag {
  font-family: var(--mono); font-size: 10.5px; font-weight: 400; letter-spacing: .04em;
  color: var(--dim); border: 1px solid var(--line); border-radius: 999px; padding: 2.5px 9px;
  white-space: nowrap;
}
.tool-plain { font-size: 14px; color: var(--dim); }
.tool-plain b { color: var(--text); }
.tool details { margin-top: 12px; border-top: 1px solid rgba(255,255,255,.06); }
.tool summary {
  cursor: pointer; list-style: none; padding: 10px 0 6px;
  font-family: var(--mono); font-size: 11.5px; letter-spacing: .1em; color: var(--orange);
  text-transform: uppercase;
}
.tool summary::-webkit-details-marker { display: none; }
.tool summary::before { content: "▸ "; transition: none; }
.tool details[open] summary::before { content: "▾ "; }
.tool details p { font-size: 13.5px; color: var(--dim); padding: 4px 0 8px; }
.tool details p b { color: var(--text); }
.tool details code {
  font-family: var(--mono); font-size: 12px; color: var(--orange-hot);
  background: rgba(247,147,26,.08); border-radius: 6px; padding: 1.5px 7px;
}
.tool-use { color: var(--text) !important; }
.tool-use::before { content: "→ "; color: var(--teal); }

/* ---------- honesty ---------- */

.honesty { padding: 20px clamp(20px, 5vw, 64px) clamp(60px, 9vh, 100px); max-width: 1060px; margin: 0 auto; }
.honesty-card {
  position: relative; border-radius: 22px; padding: clamp(30px, 5vw, 54px);
  background: linear-gradient(140deg, rgba(20,184,166,.09), rgba(16,20,31,.9) 45%, rgba(247,147,26,.08));
  border: 1px solid var(--line);
}
.honesty-mark {
  position: absolute; top: -22px; left: clamp(24px, 5vw, 52px);
  font-family: var(--mono); font-weight: 600; font-size: 15px; color: var(--ink);
  background: linear-gradient(120deg, var(--teal), #3dd6c3); border-radius: 10px; padding: 8px 16px;
  box-shadow: 0 8px 26px rgba(20,184,166,.4);
}
.honesty blockquote { font-size: clamp(15.5px, 1.8vw, 19px); color: var(--dim); line-height: 1.75; }
.honesty blockquote b { color: var(--text); }

/* ---------- finale + footer ---------- */

.finale { position: relative; text-align: center; padding: clamp(60px, 10vh, 120px) 24px; overflow: hidden; }
.finale::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: radial-gradient(55% 65% at 50% 100%, rgba(247,147,26,.16), transparent 72%);
}
.finale-sub { color: var(--dim); margin: 16px 0 34px; font-size: 16px; }

.footer { border-top: 1px solid var(--line); background: rgba(10,12,18,.85); }
.footer-inner { max-width: 1060px; margin: 0 auto; padding: 42px 24px 54px; text-align: center; }
.footer p { font-size: 12.5px; color: rgba(152,160,179,.75); margin-top: 12px; max-width: 720px; margin-left: auto; margin-right: auto; }
.footer-disclaimer { color: rgba(152,160,179,.95); }

/* ---------- responsive ---------- */

@media (max-width: 880px) {
  .nav-links a:not(.nav-cta) { display: none; }
  .feature, .feature-flip { grid-template-columns: 1fr; }
  .feature-flip .feature-copy { order: 1; }
  .feature-flip .shot { order: 2; }
  .an-days { font-size: 17px; }
  .an-label { font-size: 18px; }
  .an-total-text { font-size: 15px; }
}

/* ---------- reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .grain, .hero-aurora, .brand-coin, .btn-shine, .pulse-dot { animation: none !important; }
  .marquee-track { animation-duration: 160s; }
  .reveal, .reveal-load { opacity: 1 !important; transform: none !important; animation: none !important; transition: none !important; }
  .anatomy.in #anatomy-curve { animation: none; stroke-dashoffset: 0; }
  .anatomy.in .an-line, .anatomy.in .an-marker, .anatomy.in .an-total { animation: none; opacity: 1; }
}
