/* ==========================================================================
   MANDOCMD — sections
   ========================================================================== */

/* ---------- hero ---------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding-top: clamp(96px, 14vh, 150px);
  padding-bottom: clamp(60px, 10vh, 110px);
  overflow: hidden;
  isolation: isolate;
}

#ecg,
.hero__dust {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

#ecg { z-index: 0; opacity: 0.85; }
.hero__dust { z-index: 0; opacity: 0.7; }

.hero__glow {
  position: absolute;
  z-index: -1;
  width: 120vw;
  height: 120vw;
  left: 50%;
  top: 42%;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, rgba(242, 107, 29, 0.16) 0%, rgba(242, 107, 29, 0.05) 32%, transparent 62%);
  pointer-events: none;
}

.hero__grid {
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(rgba(243, 233, 216, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(243, 233, 216, 0.045) 1px, transparent 1px);
  background-size: 88px 88px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 45%, #000 10%, transparent 78%);
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 45%, #000 10%, transparent 78%);
  pointer-events: none;
}

.hero__inner { position: relative; z-index: 2; width: 100%; }

.hero__meta .kicker { margin-bottom: 0; }

.hero__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 26px;
  margin-bottom: clamp(18px, 3vw, 30px);
}

.hero__bpm {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 14px 7px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: ui-monospace, monospace;
  font-size: 0.68rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  background: rgba(19, 19, 19, 0.5);
}

.hero__bpm b {
  font-family: var(--display);
  font-size: 1.05rem;
  letter-spacing: 0.06em;
  color: var(--orange);
  font-weight: 400;
  font-variant-numeric: tabular-nums;
  min-width: 2.4ch;
  text-align: right;
}

.pulse-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--orange);
  box-shadow: 0 0 0 0 rgba(242, 107, 29, 0.7);
  animation: beat 1.1s var(--ease-in-out) infinite;
}

@keyframes beat {
  0%, 100% { box-shadow: 0 0 0 0 rgba(242, 107, 29, 0.65); transform: scale(1); }
  18% { box-shadow: 0 0 0 9px rgba(242, 107, 29, 0); transform: scale(1.28); }
  36% { box-shadow: 0 0 0 0 rgba(242, 107, 29, 0); transform: scale(1); }
  54% { box-shadow: 0 0 0 7px rgba(242, 107, 29, 0); transform: scale(1.16); }
}

.hero__title {
  display: grid;
  gap: 0;
  margin-block: 0 clamp(20px, 3vw, 34px);
  line-height: 0.82;
}

.hero__title .t1 {
  font-size: clamp(2.6rem, 15vw, 10.6rem);
  letter-spacing: -0.015em;
}

.hero__title .t2 {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.16em;
  font-size: clamp(1.55rem, 6.2vw, 5.6rem);
  color: rgba(243, 233, 216, 0.46);
  letter-spacing: 0.02em;
}

.hero__title .t2 .accent {
  color: var(--orange);
  -webkit-text-stroke: 0;
}

.hero__title .t2 .ghost {
  color: transparent;
  -webkit-text-stroke: 1.5px rgba(243, 233, 216, 0.35);
}

.hero__sub {
  max-width: 46ch;
  font-size: clamp(0.98rem, 1.4vw, 1.18rem);
  color: var(--muted);
  margin-bottom: clamp(26px, 4vw, 40px);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 18px;
}

.hero__side {
  position: absolute;
  right: var(--pad);
  top: 50%;
  transform: translateY(-50%);
  display: grid;
  gap: 18px;
  justify-items: center;
  z-index: 2;
}

.hero__badge {
  width: clamp(88px, 9vw, 132px);
  border-radius: 50%;
  animation: badge-spin 26s linear infinite;
  filter: drop-shadow(0 18px 40px rgba(0, 0, 0, 0.6));
}

@keyframes badge-spin { to { transform: rotate(360deg); } }

.hero__side .mono { writing-mode: vertical-rl; letter-spacing: 0.4em; }

@media (max-width: 1080px) { .hero__side { display: none; } }

.hero__scroll {
  position: absolute;
  left: 50%;
  bottom: clamp(26px, 5vh, 58px);
  transform: translateX(-50%);
  display: grid;
  justify-items: center;
  gap: 10px;
  font-family: ui-monospace, monospace;
  font-size: 0.62rem;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: rgba(243, 233, 216, 0.45);
  z-index: 3;
}

.hero__scroll i {
  display: block;
  width: 1px;
  height: 32px;
  background: linear-gradient(to bottom, var(--orange), transparent);
  animation: scroll-line 1.8s var(--ease-in-out) infinite;
  transform-origin: top;
}

@keyframes scroll-line {
  0% { transform: scaleY(0); opacity: 0; }
  40% { transform: scaleY(1); opacity: 1; }
  100% { transform: scaleY(1); opacity: 0; transform: translateY(16px); }
}

/* ---------- intro / ride ---------- */
.ride {
  border-top: 1px solid var(--line);
  background:
    radial-gradient(80% 120% at 12% 0%, rgba(242, 107, 29, 0.08), transparent 60%),
    var(--ink);
}

.ride__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(28px, 5vw, 72px);
  align-items: start;
}

@media (max-width: 720px) { .ride__grid { grid-template-columns: 1fr; } }

.ride__title { margin-bottom: 22px; }

.ride__body p + p { margin-top: 1em; }
.ride__body { max-width: 58ch; }

.ride__facts {
  display: grid;
  gap: 0;
  border-top: 1px solid var(--line);
}

.fact {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 18px;
  padding-block: 18px;
  border-bottom: 1px solid var(--line);
  transition: padding 0.4s var(--ease), background 0.4s;
}

.fact:hover { padding-left: 10px; background: rgba(242, 107, 29, 0.05); }

.fact dt {
  font-family: ui-monospace, monospace;
  font-size: 0.68rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}

.fact dd {
  margin: 0;
  font-family: var(--display);
  font-size: clamp(1.1rem, 1.7vw, 1.5rem);
  letter-spacing: 0.03em;
  text-align: right;
  color: var(--cream);
}

/* ---------- code cards ---------- */
.code { background: var(--ink-2); border-top: 1px solid var(--line); }

.cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(14px, 1.8vw, 22px);
  perspective: 1200px;
}

.cards-hint {
  display: none;
  margin-top: 14px;
  font-family: ui-monospace, monospace;
  font-size: 0.62rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: rgba(243, 233, 216, 0.4);
}

@media (max-width: 640px) {
  .cards {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 4px;
    margin-inline: calc(var(--pad) * -1);
    padding-inline: var(--pad);
  }
  .cards::-webkit-scrollbar { display: none; }
  .card { flex: 0 0 78%; scroll-snap-align: center; }
  .cards-hint { display: block; }
}


.card {
  --mx: 50%;
  --my: 50%;
  position: relative;
  padding: clamp(24px, 2.6vw, 36px);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background:
    radial-gradient(320px 220px at var(--mx) var(--my), rgba(242, 107, 29, 0.16), transparent 70%),
    linear-gradient(160deg, rgba(243, 233, 216, 0.045), rgba(243, 233, 216, 0));
  overflow: hidden;
  transform-style: preserve-3d;
  transition: border-color 0.4s, box-shadow 0.5s;
  will-change: transform;
}

.card:hover { border-color: rgba(242, 107, 29, 0.6); box-shadow: 0 30px 70px -30px rgba(0, 0, 0, 0.9); }

.card__num {
  font-family: ui-monospace, monospace;
  font-size: 0.7rem;
  letter-spacing: 0.3em;
  color: var(--orange);
  margin-bottom: clamp(38px, 5vw, 72px);
  display: block;
}

.card__icon {
  width: 44px;
  height: 44px;
  margin-bottom: 18px;
  color: var(--orange);
  transform: translateZ(40px);
}

.card h3 { margin-bottom: 12px; transform: translateZ(30px); }

.card p { color: var(--muted); font-size: 0.94rem; transform: translateZ(18px); }

.card__line {
  position: absolute;
  left: 0;
  bottom: 0;
  height: 2px;
  width: 100%;
  background: var(--orange);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.7s var(--ease);
}

.card:hover .card__line { transform: scaleX(1); }

/* ---------- stats ---------- */
.stats {
  border-block: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(242, 107, 29, 0.06), transparent);
}

.stats__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

@media (max-width: 820px) { .stats__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.stat {
  padding: clamp(26px, 3vw, 44px) clamp(14px, 2vw, 28px);
  border-right: 1px solid var(--line);
  text-align: center;
}

.stat:last-child { border-right: 0; }
@media (max-width: 820px) {
  .stat:nth-child(2n) { border-right: 0; }
  .stat:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
}

.stat__num {
  font-family: var(--display);
  font-size: clamp(2.6rem, 6vw, 4.6rem);
  line-height: 1;
  color: var(--cream);
  font-variant-numeric: tabular-nums;
}

.stat__num small { font-size: 0.42em; color: var(--orange); margin-left: 0.1em; }

.stat__label {
  margin-top: 10px;
  font-family: ui-monospace, monospace;
  font-size: 0.64rem;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ---------- pit stop ---------- */
.pitstop { overflow: hidden; }

.pitstop__panel {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  gap: clamp(24px, 4vw, 56px);
  align-items: center;
  padding: clamp(24px, 3.4vw, 52px);
  border: 1px solid var(--line);
  border-radius: clamp(18px, 2.4vw, 28px);
  background:
    radial-gradient(120% 100% at 100% 0%, rgba(242, 107, 29, 0.14), transparent 62%),
    var(--ink-2);
  overflow: hidden;
}

@media (max-width: 720px) { .pitstop__panel { grid-template-columns: 1fr; } }

.pitstop__copy h2 { margin-block: 14px 18px; }
.pitstop__copy p { color: var(--muted); max-width: 42ch; }

.hold {
  position: relative;
  margin-top: clamp(22px, 3vw, 32px);
  display: grid;
  justify-items: start;
  gap: 14px;
}

.hold__btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 16px;
  padding: 16px 28px;
  border-radius: 999px;
  border: 1px solid var(--orange);
  background: rgba(242, 107, 29, 0.1);
  font-family: var(--display);
  font-size: 1.02rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--cream);
  overflow: hidden;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
  transition: transform 0.25s var(--ease), background 0.3s;
}

.hold__btn:active { transform: scale(0.97); }
.hold__btn .ring { position: absolute; inset: 0; border-radius: inherit; pointer-events: none; }

.hold__btn .ring::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  border: 1px solid var(--orange);
  opacity: 0.55;
  animation: ring-pulse 2.4s ease-out infinite;
}

@keyframes ring-pulse {
  0% { transform: scale(1); opacity: 0.55; }
  70%, 100% { transform: scale(1.22); opacity: 0; }
}

.hold__btn .fill {
  position: absolute;
  inset: 0;
  background: var(--orange);
  transform: scaleX(0);
  transform-origin: left;
  z-index: 0;
}

.hold__btn > * { position: relative; z-index: 1; }
.hold.is-holding .hold__btn { color: #120a04; }

.hold__readout {
  min-height: 3.2em;
  font-family: ui-monospace, monospace;
  font-size: 0.78rem;
  line-height: 1.7;
  letter-spacing: 0.06em;
  color: var(--muted);
  border-left: 2px solid var(--orange);
  padding-left: 14px;
  max-width: 40ch;
}

.hold__readout strong { color: var(--cream); font-weight: 700; }

.pitstop__monitor {
  position: relative;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #080808;
  overflow: hidden;
  aspect-ratio: 16 / 10;
}

.pitstop__monitor canvas { width: 100%; height: 100%; display: block; }

.pitstop__hud {
  position: absolute;
  inset: auto 0 0 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  font-family: ui-monospace, monospace;
  font-size: 0.64rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
  background: linear-gradient(to top, rgba(0, 0, 0, 0.85), transparent);
}

.pitstop__hud b { color: var(--orange); font-weight: 700; font-variant-numeric: tabular-nums; }

.pitstop__note {
  margin-top: 18px;
  font-size: 0.76rem;
  color: rgba(243, 233, 216, 0.42);
  max-width: 52ch;
}

/* ---------- clips ---------- */
.clips { background: var(--ink); border-top: 1px solid var(--line); }

.clips__list { border-top: 1px solid var(--line); }

.clip {
  position: relative;
  display: grid;
  grid-template-columns: 60px minmax(0, 1fr) auto;
  align-items: center;
  gap: clamp(14px, 3vw, 40px);
  padding: clamp(16px, 2.1vw, 27px) clamp(10px, 1.4vw, 20px);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
  isolation: isolate;
}

.clip::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg, rgba(242, 107, 29, 0.14), rgba(242, 107, 29, 0));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.7s var(--ease);
}

.clip:hover::before,
.clip:focus-visible::before { transform: scaleX(1); }

.clip__idx {
  white-space: nowrap;
  font-family: ui-monospace, monospace;
  font-size: 0.68rem;
  letter-spacing: 0.22em;
  color: rgba(243, 233, 216, 0.35);
}

.clip__name {
  font-family: var(--display);
  font-size: clamp(1.6rem, 4.6vw, 3.4rem);
  letter-spacing: 0.02em;
  text-transform: uppercase;
  line-height: 1;
  transition: transform 0.6s var(--ease), color 0.4s;
  display: flex;
  align-items: center;
  gap: 0.4em;
  flex-wrap: wrap;
}

.clip:hover .clip__name { transform: translateX(14px); color: var(--orange); }

.clip__handle {
  font-family: var(--body);
  font-size: 0.74rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(243, 233, 216, 0.4);
  -webkit-text-stroke: 0;
}

.clip__go {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  color: var(--cream);
  transition: transform 0.5s var(--ease), background 0.4s, color 0.4s, border-color 0.4s;
}

.clip:hover .clip__go {
  transform: rotate(-45deg) scale(1.08);
  background: var(--orange);
  border-color: var(--orange);
  color: #120a04;
}

.clip__thumb {
  position: absolute;
  right: 12%;
  top: 50%;
  width: clamp(110px, 12vw, 176px);
  aspect-ratio: 16 / 10;
  border-radius: 10px;
  overflow: hidden;
  transform: translate(20px, -50%) rotate(-7deg) scale(0.86);
  opacity: 0.14;
  z-index: -1;
  transition: opacity 0.5s, transform 0.7s var(--ease);
  border: 1px solid var(--line-strong);
}

.clip__thumb img { width: 100%; height: 100%; object-fit: cover; }

.clip:hover .clip__thumb { opacity: 0.7; transform: translate(0, -50%) rotate(-4deg) scale(1.04); }

@media (max-width: 720px) {
  .clip { grid-template-columns: 44px minmax(0, 1fr) auto; }
  .clip__thumb { display: none; }
}

/* ---------- manifesto ---------- */
.manifesto {
  position: relative;
  overflow: hidden;
  border-block: 1px solid var(--line);
  background:
    radial-gradient(70% 100% at 80% 100%, rgba(242, 107, 29, 0.12), transparent 60%),
    var(--ink-2);
  text-align: center;
}

.manifesto__big {
  font-family: var(--display);
  font-size: clamp(2.2rem, 7.8vw, 6.8rem);
  line-height: 1.0;
  text-transform: uppercase;
  max-width: 20ch;
  margin-inline: auto;
}

.manifesto__big .outline {
  color: transparent;
  -webkit-text-stroke: 1.5px rgba(243, 233, 216, 0.55);
}

.manifesto__big .o { color: var(--orange); }

.manifesto__sig {
  margin-top: clamp(26px, 4vw, 44px);
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: ui-monospace, monospace;
  font-size: 0.68rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--muted);
}

.manifesto__sig img { width: 34px; height: 34px; border-radius: 50%; }

/* ---------- faq ---------- */
.faq { background: var(--ink); }
.faq .sec-head { margin-bottom: clamp(16px, 2.2vw, 28px); }

.faq__list { display: grid; gap: 0; border-top: 1px solid var(--line); max-width: 900px; }

.faq details {
  border-bottom: 1px solid var(--line);
  transition: background 0.4s;
}

.faq details[open] { background: rgba(242, 107, 29, 0.05); }

.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: clamp(12px, 1.4vw, 17px) 6px;
  cursor: pointer;
  list-style: none;
  font-family: var(--display);
  font-size: clamp(1.05rem, 2.2vw, 1.6rem);
  letter-spacing: 0.03em;
  text-transform: uppercase;
  transition: color 0.3s, padding 0.4s var(--ease);
}

.faq summary::-webkit-details-marker { display: none; }
.faq summary:hover { color: var(--orange); padding-left: 14px; }

.faq summary .plus {
  position: relative;
  flex: none;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  transition: transform 0.5s var(--ease), background 0.4s, border-color 0.4s;
}

.faq summary .plus::before,
.faq summary .plus::after {
  content: "";
  position: absolute;
  inset: 50% auto auto 50%;
  background: currentColor;
  transform: translate(-50%, -50%);
}

.faq summary .plus::before { width: 11px; height: 1.5px; }
.faq summary .plus::after { width: 1.5px; height: 11px; }

.faq details[open] summary .plus { transform: rotate(135deg); background: var(--orange); border-color: var(--orange); color: #120a04; }

.faq__body {
  padding: 0 6px clamp(14px, 1.9vw, 24px);
  color: var(--muted);
  max-width: 68ch;
  font-size: 0.96rem;
}

.faq details[open] .faq__body { animation: faq-in 0.5s var(--ease); }

@keyframes faq-in {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: none; }
}

/* ---------- footer ---------- */
.footer {
  position: relative;
  padding-top: clamp(56px, 8vw, 100px);
  background: #080808;
  border-top: 1px solid var(--line);
  overflow: hidden;
}

.footer__top {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 0.6fr);
  gap: clamp(28px, 5vw, 70px);
  padding-bottom: clamp(36px, 5vw, 64px);
}

@media (max-width: 800px) { .footer__top { grid-template-columns: 1fr; } }

.footer__title {
  font-family: var(--display);
  font-size: clamp(2rem, 6.4vw, 5rem);
  line-height: 0.9;
  text-transform: uppercase;
  margin-bottom: 18px;
}

.footer__links { display: grid; gap: 12px; align-content: start; }

.footer__links a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-block: 10px;
  border-bottom: 1px solid var(--line);
  font-size: 0.82rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  transition: color 0.3s, padding 0.4s var(--ease);
}

.footer__links a:hover { color: var(--orange); padding-left: 8px; }

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding-block: 22px;
  border-top: 1px solid var(--line);
  font-family: ui-monospace, monospace;
  font-size: 0.64rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(243, 233, 216, 0.38);
}

.footer__bottom .hint { color: rgba(242, 107, 29, 0.55); }

.footer__marquee { border-top: 1px solid var(--line); }

@media (max-width: 720px) {
  .footer__bottom { padding-bottom: 84px; row-gap: 8px; }
  .footer__bottom span { flex: 1 1 100%; }
}
