/* mockbay docs — shared styles for the presentation and user manual. */
:root {
  --bezel: #0e1622;
  --ground: #eef1f6;
  --surface: #ffffff;
  --surface-2: #f6f8fc;
  --ink: #101826;
  --ink-soft: #29344c;
  --muted: #63708a;
  --line: #d9dfea;
  --brand: #3a36e0;
  --brand-ink: #2a27b8;
  --brand-soft: #ecebfd;
  --get: #1f8a5b; --get-bg: #e2f2eb;
  --post: #2563c9; --post-bg: #e5edfb;
  --put: #9c6413; --put-bg: #f5ebda;
  --del: #c1394a; --del-bg: #f8e6e8;
  --dot: rgba(16,24,38,.055);
  --shadow: 0 1px 2px rgba(16,24,38,.05), 0 18px 44px -26px rgba(16,24,38,.4);
  --radius: 16px;
  --maxw: 1080px;
  --sans: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", "Cascadia Code", Menlo, Consolas, monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bezel: #070b12;
    --ground: #0a0f18;
    --surface: #121b2a;
    --surface-2: #0e1622;
    --ink: #eef2f8;
    --ink-soft: #c6cfde;
    --muted: #8492ac;
    --line: #233348;
    --brand: #7d78f2;
    --brand-ink: #a49ff6;
    --brand-soft: rgba(125,120,242,.16);
    --get: #46b98d; --get-bg: rgba(70,185,141,.15);
    --post: #6aa4f2; --post-bg: rgba(106,164,242,.15);
    --put: #d1a24c; --put-bg: rgba(209,162,76,.16);
    --del: #e56d7e; --del-bg: rgba(229,109,126,.16);
    --dot: rgba(255,255,255,.05);
    --shadow: 0 1px 2px rgba(0,0,0,.4), 0 22px 50px -28px rgba(0,0,0,.7);
  }
}
:root[data-theme="dark"] {
  --bezel: #070b12; --ground: #0a0f18; --surface: #121b2a; --surface-2: #0e1622;
  --ink: #eef2f8; --ink-soft: #c6cfde; --muted: #8492ac; --line: #233348;
  --brand: #7d78f2; --brand-ink: #a49ff6; --brand-soft: rgba(125,120,242,.16);
  --get: #46b98d; --get-bg: rgba(70,185,141,.15);
  --post: #6aa4f2; --post-bg: rgba(106,164,242,.15);
  --put: #d1a24c; --put-bg: rgba(209,162,76,.16);
  --del: #e56d7e; --del-bg: rgba(229,109,126,.16);
  --dot: rgba(255,255,255,.05);
  --shadow: 0 1px 2px rgba(0,0,0,.4), 0 22px 50px -28px rgba(0,0,0,.7);
}

* { box-sizing: border-box; }
body {
  margin: 0; font-family: var(--sans); color: var(--ink);
  background-color: var(--ground);
  background-image: radial-gradient(var(--dot) 1.1px, transparent 1.1px);
  background-size: 24px 24px;
  line-height: 1.6; -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { line-height: 1.08; letter-spacing: -0.02em; text-wrap: balance; margin: 0; }
p { margin: 0; }
a { color: var(--brand); text-decoration: none; }
code, .mono { font-family: var(--mono); }
:focus-visible { outline: 2.5px solid var(--brand); outline-offset: 3px; border-radius: 4px; }
img { max-width: 100%; height: auto; }

.eyebrow {
  font-family: var(--mono); font-size: 11px; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted);
}

.topbar { position: sticky; top: 0; z-index: 20; background: var(--bezel); border-bottom: 1px solid rgba(255,255,255,.06); }
.topbar__in { max-width: var(--maxw); margin: 0 auto; padding: 13px 24px; display: flex; align-items: center; gap: 18px; }
.wordmark { font-weight: 800; font-size: 18px; letter-spacing: -0.03em; color: #fff; }
.wordmark::before { content: "\25C6 "; color: var(--brand); }
.wordmark span { font-family: var(--mono); font-size: 10px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; color: #8ea0c9; margin-left: 8px; }
.topnav { margin-left: auto; display: flex; gap: 6px; flex-wrap: wrap; }
.topnav a { color: #c3cde3; font-size: 13.5px; font-weight: 500; padding: 6px 11px; border-radius: 7px; }
.topnav a:hover { color: #fff; background: rgba(255,255,255,.09); }
.topnav a[aria-current="page"] { color: #fff; background: rgba(255,255,255,.14); }

.hero { background: var(--bezel); color: #fff; padding: 64px 24px 88px; position: relative; overflow: hidden; }
.hero::after { content: ""; position: absolute; inset: 0; background-image: radial-gradient(rgba(255,255,255,.045) 1px, transparent 1px); background-size: 26px 26px; pointer-events: none; }
.hero__in { max-width: var(--maxw); margin: 0 auto; position: relative; z-index: 1; }
.hero h1 { font-size: clamp(2.4rem, 6.5vw, 4.4rem); font-weight: 800; margin: 14px 0 0; }
.hero h1 b { -webkit-text-fill-color: transparent; background: linear-gradient(92deg, #6f6bf5, #b7b3fb); -webkit-background-clip: text; background-clip: text; }
.hero__lead { color: #b9c4dc; font-size: clamp(1.05rem, 2.4vw, 1.28rem); max-width: 56ch; margin-top: 18px; }
.hero__eyebrow { color: #8ea0c9; }
.hero__chips { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 26px; }
.hchip { font-family: var(--mono); font-size: 12px; color: #dfe6f4; border: 1px solid rgba(255,255,255,.16); background: rgba(255,255,255,.05); border-radius: 999px; padding: 6px 12px; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
section.band { padding: 72px 0; }
.lead-in { max-width: 62ch; margin-bottom: 40px; }
.lead-in h2 { font-size: clamp(1.7rem, 4vw, 2.4rem); font-weight: 800; margin-top: 12px; }
.lead-in p { color: var(--ink-soft); font-size: 1.08rem; margin-top: 14px; }

.values { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.value { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); }
.value h3 { font-size: 1.15rem; font-weight: 700; margin-bottom: 8px; }
.value p { color: var(--muted); font-size: 0.98rem; }
.value .k { font-family: var(--mono); font-size: 22px; color: var(--brand); font-weight: 600; }

/* problem: before/after swimlanes */
.compare { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.compare__card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); }
.compare__tag { font-family: var(--mono); font-size: 11px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; padding: 5px 11px; border-radius: 999px; display: inline-block; }
.compare__tag--bad { color: var(--del); background: var(--del-bg); }
.compare__tag--good { color: var(--get); background: var(--get-bg); }
.lanes { display: flex; flex-direction: column; gap: 12px; margin-top: 20px; }
.lane { display: grid; grid-template-columns: 32px 1fr; align-items: center; gap: 12px; }
.lane__who { font-family: var(--mono); font-size: 12px; font-weight: 700; color: var(--muted); }
.track { display: flex; gap: 4px; height: 32px; }
.seg { display: flex; align-items: center; justify-content: center; border-radius: 7px; font-size: 10.5px; font-weight: 600; color: #fff; white-space: nowrap; overflow: hidden; padding: 0 8px; letter-spacing: 0.01em; min-width: 0; }
.seg--api { background: var(--post); }
.seg--build { background: var(--brand); }
.seg--mock { background: var(--get); }
.seg--idle { background: var(--surface-2); color: var(--muted); border: 1px solid var(--line); }
.seg--wait { background-image: repeating-linear-gradient(45deg, transparent, transparent 6px, color-mix(in srgb, var(--del) 20%, transparent) 6px, color-mix(in srgb, var(--del) 20%, transparent) 12px); background-color: var(--del-bg); color: var(--del); border: 1px dashed color-mix(in srgb, var(--del) 45%, transparent); }
.compare__note { margin-top: 16px; font-size: 0.95rem; color: var(--ink-soft); }

.feature { display: grid; grid-template-columns: 1fr 1fr; gap: 44px; align-items: center; }
.feature + .feature { margin-top: 72px; }
.feature--flip .feature__text { order: 2; }
.feature__text h3 { font-size: clamp(1.5rem, 3.2vw, 2rem); font-weight: 800; margin: 12px 0 14px; }
.feature__text p { color: var(--ink-soft); font-size: 1.05rem; }
.feature__text p + p { margin-top: 12px; }
.feature ul { margin: 16px 0 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 9px; }
.feature li { position: relative; padding-left: 22px; color: var(--ink-soft); }
.feature li::before { content: "\25B8"; position: absolute; left: 0; color: var(--brand); }

.frame { border-radius: 14px; overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow); background: var(--surface); }
.frame__bar { display: flex; align-items: center; gap: 7px; padding: 10px 14px; background: var(--surface-2); border-bottom: 1px solid var(--line); }
.frame__dot { width: 10px; height: 10px; border-radius: 50%; background: var(--line); }
.frame__url { font-family: var(--mono); font-size: 11.5px; color: var(--muted); margin-left: 10px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.frame img { display: block; width: 100%; }

.manual { background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.step { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: start; padding: 56px 0; border-top: 1px dashed var(--line); }
.step:first-of-type { border-top: 0; }
.step--flip .step__text { order: 2; }
.step__num { font-family: var(--mono); font-size: 13px; font-weight: 600; color: var(--brand); letter-spacing: 0.1em; }
.step__text h3 { font-size: 1.5rem; font-weight: 800; margin: 8px 0 14px; }
.step__text p { color: var(--ink-soft); }
.step__text ol { margin: 16px 0 0; padding-left: 20px; color: var(--ink-soft); display: flex; flex-direction: column; gap: 8px; }
.step__text ol code, .step__text p code { font-family: var(--mono); font-size: 0.88em; background: var(--surface-2); border: 1px solid var(--line); padding: 1px 6px; border-radius: 5px; color: var(--ink); }

.callout { margin-top: 18px; border-left: 3px solid var(--brand); background: var(--brand-soft); border-radius: 0 10px 10px 0; padding: 12px 16px; font-size: 0.95rem; color: var(--ink-soft); }
.callout b { color: var(--ink); }

/* Part divider between the user and admin tracks */
.parthead { padding: 60px 0 4px; max-width: 64ch; }
.parthead h2 { font-size: clamp(1.6rem, 4vw, 2.2rem); font-weight: 800; margin-top: 10px; }
.parthead p { color: var(--ink-soft); margin-top: 12px; }
.parthead + .step { border-top: 0; padding-top: 32px; }

/* Spec card — stands in for a screenshot on steps that don't have one */
.spec { align-self: start; border-radius: 14px; border: 1px solid var(--line); background: var(--surface-2); box-shadow: var(--shadow); padding: 24px 26px; }
.spec h4 { font-family: var(--mono); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); margin-bottom: 16px; }
.spec dl { display: grid; grid-template-columns: auto 1fr; gap: 12px 18px; margin: 0; }
.spec dt { font-family: var(--mono); font-size: 13px; color: var(--brand); font-weight: 600; }
.spec dd { margin: 0; color: var(--ink-soft); font-size: 0.95rem; }

.methods { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.m { font-family: var(--mono); font-weight: 700; font-size: 12px; padding: 4px 9px; border-radius: 6px; border: 1px solid transparent; }
.m.get { color: var(--get); background: var(--get-bg); border-color: color-mix(in srgb, var(--get) 24%, transparent); }
.m.post { color: var(--post); background: var(--post-bg); border-color: color-mix(in srgb, var(--post) 24%, transparent); }
.m.put { color: var(--put); background: var(--put-bg); border-color: color-mix(in srgb, var(--put) 26%, transparent); }
.m.del { color: var(--del); background: var(--del-bg); border-color: color-mix(in srgb, var(--del) 24%, transparent); }

.tablewrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow); }
table { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
th, td { text-align: left; padding: 14px 18px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); background: var(--surface-2); }
tr:last-child td { border-bottom: 0; }
td:first-child { font-family: var(--mono); color: var(--brand-ink); white-space: nowrap; }
td code { font-family: var(--mono); font-size: 0.86em; color: var(--ink-soft); }

footer { background: var(--bezel); color: #b9c4dc; padding: 40px 24px; }
footer .wrap { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; align-items: center; padding: 0 24px; }
footer .mono { font-size: 12px; color: #8ea0c9; }

.reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }

@media (max-width: 820px) {
  .values { grid-template-columns: 1fr; }
  .compare { grid-template-columns: 1fr; }
  .feature, .step { grid-template-columns: 1fr; gap: 22px; }
  .feature--flip .feature__text, .step--flip .step__text { order: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}
