/* Manifesto section styles — appended */

.manifesto{
  position: relative;
  z-index: 3;
  padding: 88px var(--pad-x) 104px;
  max-width: var(--maxw);
  margin: 0 auto;
  border-top: 1px solid var(--border-soft);
}

.man-head{
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 40px;
  margin-bottom: 80px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--border-soft);
}
.man-eyebrow{
  font-family: 'Geist', sans-serif;
  font-weight: 500;
  font-size: clamp(1.4rem, 2.4vw, 2rem);
  letter-spacing: -0.02em;
  margin: 0;
  max-width: 28ch;
  line-height: 1.15;
}
.man-eyebrow .serif{
  color: var(--accent);
  font-size: 1.05em;
  letter-spacing: -0.01em;
}

/* Grid: text left, sticky right */
.man-grid{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(40px, 7vw, 110px);
  align-items: stretch;
}

/* ── Left column: scrolling panels ─────────────────────────────────────── */
.man-left{
  display: flex;
  flex-direction: column;
  gap: 0;
}
.man-panel{
  min-height: 78vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 60px 0;
  border-bottom: 1px solid var(--border-soft);
  opacity: 0.32;
  transition: opacity .6s cubic-bezier(.2,.7,.2,1);
}
.man-panel:last-child{ border-bottom: 0; }
.man-panel.is-active{ opacity: 1; }

.man-panel-meta{
  display: flex;
  justify-content: space-between;
  margin-bottom: 28px;
  padding-bottom: 16px;
  border-bottom: 1px dashed var(--border);
}
.man-panel-title{
  font-family: 'Geist', sans-serif;
  font-weight: 500;
  font-size: clamp(2rem, 4vw, 3.2rem);
  letter-spacing: -0.035em;
  line-height: 1.02;
  margin: 0 0 32px;
  text-wrap: balance;
}
.man-panel.is-active .man-panel-title{
  color: var(--fg);
}
.man-panel-body{
  font-size: clamp(15px, 1.25vw, 17px);
  line-height: 1.6;
  color: var(--fg-2);
  max-width: 42ch;
  margin: 0 0 36px;
  letter-spacing: -0.005em;
}

.man-progress{
  position: relative;
  height: 1px;
  width: 80px;
  background: var(--border);
}
.man-progress-fill{
  position: absolute; inset: 0;
  background: var(--accent);
  transform: scaleX(0); transform-origin: left;
  transition: transform 1.2s cubic-bezier(.2,.7,.2,1);
}
.man-panel.is-active .man-progress-fill{ transform: scaleX(1); }

/* ── Right column: sticky visual ───────────────────────────────────────── */
.man-right{
  position: relative;
  align-self: stretch;
  height: 100%;
}
.man-sticky{
  position: sticky;
  top: 16px;
  z-index: 5;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 22px;
  background: linear-gradient(180deg, rgba(20,20,22,0.6), rgba(10,10,10,0.5));
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
  height: 88vh;
  display: flex;
  flex-direction: column;
}
.man-sticky-h{
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border-soft);
  margin-bottom: 16px;
}
.man-sticky-foot{
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid var(--border-soft);
  display: flex;
  justify-content: flex-start;
}

/* Visual stage — cross-fade between visuals */
.vis-stage{
  position: relative;
  flex: 1;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.vis-slot{
  position: absolute; inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transform: translateY(8px) scale(0.99);
  transition: opacity .5s ease, transform .7s cubic-bezier(.2,.7,.2,1);
  pointer-events: none;
}
.vis-slot.active{
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}
.vis{
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ── Visual: compare ──────────────────────────────────────────────────── */
.vis-compare{
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 14px;
  width: 100%;
  align-items: stretch;
}
.vis-frame{
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 14px;
  background: rgba(10,10,10,0.4);
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 320px;
}
.vis-frame-h{
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-size: 10px;
  flex-wrap: wrap;
}
.vis-tag{ font-size: 10px; color: var(--fg-2); letter-spacing: 0.04em; text-transform: uppercase; white-space: nowrap; }
.vis-tag-x{ font-size: 10px; color: var(--fg-3); white-space: nowrap; }
.vis-tag-x.accent{ color: var(--accent); }

.vis-bad-grid{
  flex: 1;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 4px;
}
.vis-bad-cell{
  background: rgba(255,255,255,0.04);
  border-radius: 2px;
  height: 100%;
  min-height: 22px;
}
.vis-bad-cell.used{
  background: rgba(255,255,255,0.18);
  outline: 1px solid rgba(255,255,255,0.3);
}
.vis-frame-foot{
  font-size: 10px;
}
.vis-frame-foot.accent{ color: var(--accent); }

.vis-good-rows{
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 12px;
  justify-content: center;
}
.vgood-row{
  display: grid;
  grid-template-columns: 8px 1fr;
  align-items: center;
  gap: 10px;
  position: relative;
}
.vgood-dot{
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 6px var(--accent);
}
.vgood-label{
  font-size: 12px;
  color: var(--fg);
}
.vgood-bar{
  position: absolute;
  bottom: -8px;
  left: 18px;
  height: 1px;
  background: linear-gradient(90deg, var(--accent), transparent);
}

.vis-divider{
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.vis-divider::before{
  content: "";
  position: absolute;
  top: 0; bottom: 0; left: 50%;
  width: 1px;
  background: var(--border-soft);
  transform: translateX(-50%);
}
.vis-vs{
  position: relative;
  background: var(--bg);
  padding: 2px 4px;
  font-size: 9px;
  color: var(--fg-3);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* ── Visual: code ─────────────────────────────────────────────────────── */
.vis-code{ width: 100%; }
.code-window{
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: rgba(8,8,10,0.7);
  overflow: hidden;
  font-size: 11.5px;
}
.code-h{
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 10px 14px;
  border-bottom: 1px solid var(--border-soft);
  background: rgba(255,255,255,0.02);
}
.dots{ display: inline-flex; gap: 5px; }
.dots i{ width: 9px; height: 9px; border-radius: 50%; background: rgba(255,255,255,0.12); }
.dots i:nth-child(1){ background: rgba(255,95,86,0.5); }
.dots i:nth-child(2){ background: rgba(255,189,46,0.5); }
.dots i:nth-child(3){ background: rgba(39,201,63,0.5); }
.code-tab{ font-size: 10.5px; color: var(--fg-2); }
.code-status{ display: inline-flex; align-items: center; gap: 6px; font-size: 10px; color: var(--fg-2); }
.green-dot{ width: 6px; height: 6px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 6px rgba(34,197,94,0.6); }

.code-body{ padding: 14px 0; }
.code-line{
  display: grid;
  grid-template-columns: 36px 1fr;
  padding: 0 16px;
  line-height: 1.7;
}
.code-ln{ color: var(--fg-3); opacity: 0.6; font-size: 10px; user-select: none; padding-top: 1px; }
.code-content{ color: var(--fg); white-space: pre; }
.tok-kw{ color: #c084fc; }      /* keywords */
.tok-fn{ color: #93c5fd; }      /* functions */
.tok-prop{ color: #fca5a5; }    /* props */
.tok-str{ color: #86efac; }     /* strings */
.tok-var{ color: #fcd34d; }     /* vars */
.tok-lib{ color: #f0abfc; }     /* libs */
.tok-lit{ color: #fcd34d; }     /* literals */
.tok-p{ color: var(--fg-2); }
.tok-k{ color: var(--fg); }

.code-foot{
  display: flex;
  gap: 8px;
  align-items: center;
  padding: 10px 14px;
  border-top: 1px solid var(--border-soft);
  font-size: 10px;
  color: var(--fg-2);
}

/* ── Visual: arch ─────────────────────────────────────────────────────── */
.vis-arch{
  position: relative;
  width: 100%;
  flex-direction: column;
  gap: 12px;
}
.arch-svg{ width: 100%; max-width: 380px; height: auto; }
.arch-cap{
  font-size: 10px;
  color: var(--fg-3);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* ── Visual: timeline ─────────────────────────────────────────────────── */
.vis-timeline{
  width: 100%;
  flex-direction: column;
  gap: 28px;
  padding: 8px;
  align-items: stretch;
}
.tl-head{
  display: flex;
  justify-content: space-between;
  font-size: 10.5px;
  color: var(--fg-2);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.tl-track{
  display: flex;
  align-items: stretch;
  gap: 4px;
  position: relative;
  padding: 12px 0;
}
.tl-axis{
  position: absolute;
  top: 22px; left: 0; right: 0;
  height: 1px;
  background: var(--border);
}
.tl-phase{
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding-top: 12px;
}
.tl-bar{
  height: 18px;
  border-radius: 3px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-soft);
  overflow: hidden;
  position: relative;
}
.tl-bar-fill{
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(168,85,247,0.4), var(--accent));
  transform: scaleX(0); transform-origin: left;
  animation: tl-fill 1.4s cubic-bezier(.2,.7,.2,1) forwards;
}
.tl-phase:nth-child(2) .tl-bar-fill{ animation-delay: 0.1s; }
.tl-phase:nth-child(3) .tl-bar-fill{ animation-delay: 0.25s; }
.tl-phase:nth-child(4) .tl-bar-fill{ animation-delay: 0.45s; }
.tl-phase:nth-child(5) .tl-bar-fill{ animation-delay: 0.65s; }
@keyframes tl-fill{
  from { transform: scaleX(0); }
  to   { transform: scaleX(1); }
}
.tl-meta{
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 10.5px;
}
.tl-num{ font-size: 9px; color: var(--accent); letter-spacing: 0.06em; }
.tl-label{ font-size: 11px; color: var(--fg); font-family: 'Geist', sans-serif; font-weight: 500; }
.tl-d{ font-size: 9.5px; }

.tl-actor{
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-top: 16px;
  border-top: 1px dashed var(--border-soft);
}
.tl-actor-line{
  position: relative;
  height: 14px;
  display: flex;
  align-items: center;
}
.tl-actor-dot{
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 10px var(--accent);
  position: absolute;
  left: 0;
  animation: actor-walk 8s cubic-bezier(.4,0,.2,1) infinite;
  z-index: 2;
}
.tl-actor-line-fill{
  position: absolute;
  left: 0; right: 0; top: 50%;
  height: 1px;
  background: linear-gradient(90deg, var(--accent), rgba(168,85,247,0.1));
}
@keyframes actor-walk{
  0%   { left: 0%; }
  50%  { left: calc(100% - 8px); }
  100% { left: 0%; }
}
.tl-actor-lbl{
  font-size: 10px;
  color: var(--fg-2);
}

/* ── Responsive ───────────────────────────────────────────────────────── */
@media (max-width: 920px){
  .manifesto{ padding: 80px 20px 100px; }
  .man-head{ flex-direction: column; align-items: flex-start; gap: 20px; margin-bottom: 40px; }
  .man-grid{ grid-template-columns: 1fr; gap: 32px; }
  .man-panel{ min-height: auto; padding: 32px 0; opacity: 1; }
  .man-right{ order: -1; }
  .man-sticky{ position: relative; top: 0; min-height: 360px; }
  .vis-compare{ grid-template-columns: 1fr; }
  .vis-divider{ display: none; }
  .vis-frame{ min-height: 200px; }
}
