/* Repomate landing: see inside.
   Near-black stage, one living canvas (the real file tree of a scanned
   repository), cyan-to-violet as the only accent. Motion is canvas-rendered
   and scroll-smoothed; everything after the score section is calm. */

:root {
  --sc-canvas: #06070b;
  --sc-surface: #0d0f16;
  --sc-ink: #e9ecf5;
  --sc-ink-soft: #a3a9ba;
  --sc-accent: #53e0ff;
  --sc-accent-ink: #06070b;
  --sc-font-display: "Geist", system-ui, sans-serif;
  --sc-font-text: "Geist", system-ui, sans-serif;
  --sc-font-mono: "Geist Mono", ui-monospace, monospace;

  --bg: #06070b; --panel: #0c0e15; --panel-2: #11141d;
  --line: #1b1f2b; --line-2: #262b3a;
  --ink: #e9ecf5; --ink-2: #a3a9ba; --ink-3: #6b7285;
  --cyan: #53e0ff; --violet: #9b7bff; --mint: #7cf0b0; --amber: #ffb86b;
  --good: #3ddc84; --warn: #f5c451; --serious: #ff8a4c; --critical: #ff5470;
  --grad: linear-gradient(100deg, #53e0ff 0%, #8fa2ff 50%, #9b7bff 100%);
}

html { scroll-padding-top: 72px; background: var(--bg); }
body { background: var(--bg); color: var(--ink); font-size: 16px; overflow-x: clip; }
body::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(60rem 40rem at 70% -10%, #1a2a4a55, transparent 60%),
    radial-gradient(50rem 40rem at -10% 110%, #2a1a4a44, transparent 60%),
    linear-gradient(#ffffff06 1px, transparent 1px) 0 0 / 56px 56px,
    linear-gradient(90deg, #ffffff06 1px, transparent 1px) 0 0 / 56px 56px;
}
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.mono, code, pre { font-family: var(--sc-font-mono); }
a { color: inherit; }
.shell { width: 100%; max-width: 74rem; margin-inline: auto; padding-inline: clamp(1.1rem, 4vw, 2rem); position: relative; }

h1, h2, h3 { margin: 0; color: var(--ink); text-wrap: balance; font-family: var(--sc-font-display); }
h1 { font-size: clamp(2.8rem, 1.6rem + 4.6vw, 5.4rem); font-weight: 650; letter-spacing: -0.045em; line-height: .98; max-width: 11ch; }
h2 { font-size: clamp(2rem, 1.3rem + 2.4vw, 3.3rem); font-weight: 600; letter-spacing: -0.04em; line-height: 1.02; }
h3 { font-size: 1.05rem; font-weight: 600; letter-spacing: -0.01em; }
.grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.dim { color: var(--ink-3); }
.kicker { font-size: .78rem; color: var(--cyan); margin: 0 0 1.1rem; letter-spacing: .01em; }
.lede { font-size: clamp(1.02rem, .96rem + .3vw, 1.18rem); color: var(--ink-2); line-height: 1.6; max-width: 34rem; margin: 1.3rem 0 0; }
.body { color: var(--ink-2); line-height: 1.65; max-width: 30rem; margin: 1.2rem 0 0; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; border: 0; border-radius: 10px; padding: .8rem 1.25rem; font: 600 .95rem/1 var(--sc-font-text); text-decoration: none; cursor: pointer; white-space: nowrap; color: var(--bg); }
.btn--sm { padding: .55rem .9rem; font-size: .86rem; }
.btn--glow { background: var(--grad); box-shadow: 0 0 0 1px #ffffff22 inset, 0 8px 30px -8px #53e0ff66; transition: box-shadow .25s, transform .15s; }
.btn--glow:hover { box-shadow: 0 0 0 1px #ffffff44 inset, 0 10px 40px -6px #53e0ffaa; }
.btn--glow:active { transform: translateY(1px); }
.btn--ghost { color: var(--ink); background: #ffffff0d; box-shadow: 0 0 0 1px var(--line-2) inset; }
.btn--ghost:hover { background: #ffffff16; }
.btn:disabled { opacity: .6; cursor: progress; }

/* nav */
.nav { position: fixed; inset: 0 0 auto 0; z-index: 60; background: #06070bb3; backdrop-filter: blur(14px) saturate(1.4); border-bottom: 1px solid #ffffff0f; }
.nav__row { display: flex; align-items: center; gap: 2rem; height: 62px; }
.brand { display: inline-flex; align-items: center; gap: .6rem; font-weight: 650; letter-spacing: -0.02em; text-decoration: none; }
.nav__links { display: flex; gap: 1.5rem; font-size: .9rem; }
.nav__links a { color: var(--ink-3); text-decoration: none; transition: color .2s; }
.nav__links a:hover { color: var(--ink); }
.nav__end { margin-left: auto; display: flex; gap: 1rem; align-items: center; }
.nav__sign { color: var(--ink-2); text-decoration: none; font-size: .9rem; }
.nav__sign:hover { color: var(--ink); }
@media (max-width: 760px) { .nav__links { display: none; } }

/* the canvas */
.field { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 0; pointer-events: none; will-change: opacity; }
.labels { position: fixed; inset: 0; z-index: 2; pointer-events: none; }
.flag {
  position: absolute; left: 0; top: 0; transform: translate(-50%, -50%); white-space: nowrap;
  font: 500 .72rem var(--sc-font-mono); color: var(--ink); background: #0c0e15e6; border: 1px solid var(--c, var(--critical));
  border-radius: 7px; padding: .3rem .55rem; opacity: 0; transition: opacity .35s; box-shadow: 0 0 24px -6px var(--c, var(--critical));
}
.flag b { color: var(--c, var(--critical)); font-weight: 600; margin-right: .35rem; }
@media (max-width: 899px) { .flag { max-width: calc(100vw - 32px); overflow: hidden; text-overflow: ellipsis; font-size: .66rem; } }
.flag.on { opacity: 1; }
main { position: relative; z-index: 1; }

/* hero */
.hero { min-height: 100vh; display: flex; flex-direction: column; justify-content: center; padding: 90px 0 3rem; position: relative; }
.hero__inner { pointer-events: none; }
.hero__inner > * { pointer-events: auto; }
@media (max-width: 899px) { .hero__cap { display: none; } }
.hero__cap { position: absolute; right: clamp(1rem, 4vw, 2.5rem); bottom: 1.4rem; font-size: .72rem; color: var(--ink-3); margin: 0; }
.prompt {
  margin-top: 2rem; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; max-width: 31rem;
  background: #0c0e15cc; backdrop-filter: blur(10px); border: 1px solid var(--line-2); border-radius: 14px; padding: .4rem .4rem .4rem 1rem;
  transition: border-color .25s, box-shadow .25s;
}
.prompt:focus-within { border-color: #53e0ff88; box-shadow: 0 0 0 4px #53e0ff1f, 0 0 40px -10px #53e0ff66; }
.prompt__sign { color: var(--ink-3); font-size: .95rem; }
.prompt input { border: 0; outline: 0; background: none; min-width: 0; color: var(--ink); font: 500 .95rem/1 var(--sc-font-mono); padding: .85rem .15rem; }
.prompt input::placeholder { color: #4d5467; }
.prompt__note { font-size: .82rem; color: var(--ink-3); margin: .75rem 0 0 .2rem; }
.prompt__note.is-error { color: var(--critical); }
.prompt__note a { color: var(--cyan); }
.try { margin: 1rem 0 0; font-size: .78rem; color: var(--ink-3); display: flex; flex-wrap: wrap; align-items: center; gap: .45rem; }
.try button { font: inherit; color: var(--ink-2); background: #ffffff08; border: 1px solid var(--line-2); border-radius: 999px; padding: .28rem .65rem; cursor: pointer; transition: border-color .2s, color .2s; }
.try button:hover { border-color: #53e0ff66; color: var(--ink); }

/* pinned stages */
.act .stage { display: flex; align-items: center; }
.stage__copy { padding-top: 56px; }
.stage__copy > * { max-width: 26rem; }
.steps { list-style: none; counter-reset: s; padding: 0; margin: 2rem 0 0; display: grid; gap: .7rem; font-size: .84rem; }
.steps li { counter-increment: s; display: flex; gap: .8rem; align-items: baseline; color: var(--ink-3); transition: color .4s; }
.steps li::before { content: "0" counter(s); color: var(--line-2); transition: color .4s; }
.steps li.on { color: var(--ink); }
.steps li.on::before { color: var(--cyan); }
.steps li.done { color: var(--ink-2); }
.steps li.done::before { color: var(--good); content: "ok"; }
.counters { display: grid; grid-template-columns: repeat(3, auto); justify-content: start; gap: .6rem 2.4rem; margin: 2.2rem 0 0; }
.counters dt { font-size: .7rem; color: var(--ink-3); }
.counters dd { margin: .2rem 0 0; font-size: 2rem; font-weight: 600; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.legend { list-style: none; padding: 0; margin: 1.6rem 0 0; display: grid; grid-template-columns: 1fr 1fr; gap: .35rem 1.4rem; font-size: .74rem; color: var(--ink-2); }
.legend li { display: flex; align-items: center; gap: .5rem; min-width: 0; }
.legend i { width: 9px; height: 9px; border-radius: 2px; flex: none; }
.legend span { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.legend b { font-weight: 500; color: var(--critical); font-variant-numeric: tabular-nums; }
.legend b.z { color: var(--ink-3); }
.gauge-num { position: fixed; left: 0; top: 0; transform: translate(-50%, -50%); display: grid; justify-items: center; pointer-events: none; opacity: 0; z-index: 2; }
.gauge-num b { font-size: clamp(2.6rem, 2rem + 2.4vw, 4.4rem); font-weight: 650; letter-spacing: -0.05em; line-height: 1; font-variant-numeric: tabular-nums; }
.gauge-num__of { font-size: .75rem; color: var(--ink-3); margin-top: .3rem; }
.grade { margin-top: .7rem; display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; font-weight: 700; color: #06070b; background: var(--good); transform: scale(.6); opacity: 0; transition: transform .45s cubic-bezier(.2,1.4,.4,1), opacity .3s; }
.grade.on { transform: none; opacity: 1; }
.grade[data-g="C"] { background: var(--warn); } .grade[data-g="D"] { background: var(--serious); } .grade[data-g="F"] { background: var(--critical); }

@media (max-width: 900px) {
  .stage__copy { align-self: flex-start; padding-top: 82px; }
  .stage__copy .body { display: none; }
  .counters dd { font-size: 1.5rem; }
  .steps { margin-top: 1.2rem; font-size: .76rem; gap: .45rem; }
  .legend { display: none; }
}

/* content sections */
.sec { padding: clamp(5rem, 13vh, 9rem) 0; position: relative; }
.glass { background: linear-gradient(180deg, #11141dcc, #0c0e15cc); border: 1px solid var(--line); border-radius: 18px; box-shadow: 0 1px 0 #ffffff0a inset, 0 30px 80px -40px #000; backdrop-filter: blur(8px); }
.split { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
@media (max-width: 900px) { .split { grid-template-columns: minmax(0, 1fr); } }

.editor { margin-top: 2.6rem; overflow: hidden; }
.editor__tabs { display: flex; border-bottom: 1px solid var(--line); overflow-x: auto; }
.editor__tabs button { font: 500 .76rem var(--sc-font-mono); color: var(--ink-3); background: none; border: 0; padding: .85rem 1.1rem; cursor: pointer; white-space: nowrap; border-right: 1px solid var(--line); transition: color .2s, background .2s; }
.editor__tabs button[aria-selected="true"] { color: var(--ink); background: #ffffff06; box-shadow: inset 0 -2px 0 var(--cyan); }
.editor__tabs .repo { color: #555c70; margin-right: .5rem; }
.editor__body { font: .8rem/1.75 var(--sc-font-mono); color: #d6dbe8; overflow-x: auto; padding: .8rem 0; }
.ln { display: grid; grid-template-columns: 3.4rem minmax(0, 1fr); white-space: pre; }
.ln__n { text-align: right; padding-right: 1.1rem; color: #3c4254; user-select: none; }
.ln--hit { background: linear-gradient(90deg, #f5c4511c, transparent 70%); box-shadow: inset 2px 0 0 var(--sev, var(--warn)); }
.ln--hit .ln__n { color: var(--sev, var(--warn)); }
.t-key { color: #8fb3ff; } .t-str { color: #e7c07b; } .t-dim { color: #555c70; }
.note { margin: .5rem 1.2rem .9rem 3.4rem; border: 1px solid var(--line-2); border-left: 2px solid var(--sev, var(--warn)); background: #0a0c12; border-radius: 10px; padding: .95rem 1.05rem; font-family: var(--sc-font-text); white-space: normal; max-width: 46rem; }
.note__head { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; }
.note__sev { font: 600 .7rem var(--sc-font-mono); color: var(--sev); text-transform: uppercase; letter-spacing: .06em; }
.note__title { font-weight: 600; font-size: .92rem; color: var(--ink); }
.note p { color: var(--ink-2); font-size: .86rem; line-height: 1.55; margin: .35rem 0 0; }
.note__foot { display: flex; flex-wrap: wrap; gap: 1.1rem; margin-top: .6rem; font-size: .78rem; }
.note__foot a { color: var(--cyan); text-decoration: none; }
.note__foot a:hover { text-decoration: underline; }
.note__foot span { font-family: var(--sc-font-mono); color: var(--ink-3); }
@media (max-width: 640px) { .note { margin-left: 1rem; } .ln { grid-template-columns: 2.4rem minmax(0, 1fr); } .ln__n { padding-right: .6rem; } }

.guards { list-style: none; padding: 0; margin: 1.8rem 0 0; display: grid; gap: .6rem; font-size: .84rem; color: var(--ink-2); }
.guards li { display: flex; gap: .7rem; align-items: center; }
.guards li::before {
  --tick: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3 8.5l3 3 7-7' stroke='black' stroke-width='2.4' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  content: ""; width: 14px; height: 14px; flex: none; background: var(--grad);
  -webkit-mask: var(--tick) center / contain no-repeat; mask: var(--tick) center / contain no-repeat;
}
.pr { overflow: hidden; }
.pr__head { display: flex; gap: .9rem; align-items: center; padding: 1.1rem 1.2rem; border-bottom: 1px solid var(--line); }
.pr__state { font-size: .72rem; color: var(--good); border: 1px solid #3ddc8455; background: #3ddc8414; padding: .25rem .6rem; border-radius: 999px; }
.pr__title { margin: 0; font-weight: 600; }
.pr__meta { margin: .2rem 0 0; font-size: .72rem; color: var(--ink-3); }
.diff { margin: 0; padding: .7rem 0; font-size: .74rem; line-height: 1.7; white-space: normal; overflow-x: auto; }
.diff span { display: block; padding: 0 1.2rem; white-space: pre; }
.diff .h { color: #8fb3ff; }
.diff .a { color: #7cf0b0; background: linear-gradient(90deg, #3ddc8412, transparent); }
.diff .more { color: #4d5467; font-style: italic; }
.pr__cap { margin: 0; padding: .75rem 1.2rem; border-top: 1px solid var(--line); font-size: .7rem; color: var(--ink-3); }

.bento { margin-top: 2.6rem; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.cell { padding: 1.4rem; min-width: 0; position: relative; overflow: hidden; transition: border-color .3s; }
.cell:hover { border-color: #53e0ff44; }
.cell--wide { grid-column: span 2; }
.cell p { color: var(--ink-2); font-size: .9rem; line-height: 1.55; margin: .5rem 0 0; }
.cell__code { font-size: .74rem !important; color: var(--cyan) !important; margin-top: 1.1rem !important; }
.cell__badge { margin-top: 1.1rem !important; min-height: 20px; }
@media (max-width: 900px) { .bento { grid-template-columns: minmax(0, 1fr); } .cell--wide { grid-column: auto; } }
.cmp { margin-top: 1.1rem; font-size: .74rem; display: grid; gap: .3rem; }
.cmp__goal { color: var(--ink-3) !important; font-size: .74rem !important; margin: 0 0 .4rem !important; }
.cmp__row { display: grid; grid-template-columns: minmax(0, 1fr) 6.5rem 5rem; gap: .5rem; align-items: center; padding: .35rem 0; border-top: 1px solid var(--line); color: var(--ink-2); }
.cmp__row--h { border-top: 0; color: var(--ink-3); }
.cmp__row em { font-style: normal; }
.cmp i { font-style: normal; width: fit-content; padding: .1rem .5rem; border-radius: 999px; }
.cmp i.y { color: var(--good); background: #3ddc8414; } .cmp i.n { color: var(--critical); background: #ff547014; }

.price { margin-top: 2.6rem; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
@media (max-width: 860px) { .price { grid-template-columns: minmax(0, 1fr); } }
.plan { padding: 1.6rem; display: flex; flex-direction: column; }
.plan--pro { border-color: #53e0ff55; box-shadow: 0 0 0 1px #53e0ff22 inset, 0 30px 80px -40px #53e0ff44; }
.plan__name { margin: 0; font: 500 .8rem var(--sc-font-mono); color: var(--ink-2); }
.plan__price { font-size: 2.6rem; font-weight: 650; letter-spacing: -0.05em; margin: .5rem 0 .2rem; }
.plan__price small { font-size: .85rem; font-weight: 500; color: var(--ink-3); letter-spacing: 0; }
.plan__blurb { color: var(--ink-3); font-size: .86rem; margin: 0 0 1.2rem; min-height: 2.8em; line-height: 1.5; }
.plan ul { list-style: none; padding: 0; margin: 0 0 1.5rem; display: grid; gap: .5rem; font-size: .88rem; color: var(--ink-2); }
.plan li { display: flex; gap: .6rem; align-items: baseline; }
.plan li::before { content: "+"; font-family: var(--sc-font-mono); color: var(--cyan); }
.plan li.no { color: #4d5467; } .plan li.no::before { content: "-"; color: #4d5467; }
.plan .btn { margin-top: auto; }

.close { padding: clamp(5rem, 14vh, 9rem) 0; text-align: center; }
.close__inner { display: grid; justify-items: center; }
.close .prompt { width: 100%; }
.foot { border-top: 1px solid var(--line); position: relative; z-index: 1; background: var(--bg); }
.foot__row { display: flex; flex-wrap: wrap; gap: .6rem 1.4rem; padding-block: 1.5rem; font-size: .76rem; color: var(--ink-3); }
.foot__row a { text-decoration: none; } .foot__row a:hover { color: var(--ink); }
.foot__note { margin-left: auto; }
@media (max-width: 760px) { .foot__note { margin-left: 0; width: 100%; } }
