/* Landing page (Views/Home/Index.cshtml + Views/Home/Landing/*).
   Standalone: the admin theme CSS is not loaded on this page. */

/* ---------- Tokens ---------- */
:root {
    color-scheme: dark;

    --bg: #0f172a;
    --bg-deep: #0b1120;
    --surface: #131c31;
    --surface-2: #18223a;
    --term: #0a0f1e;

    --line: rgba(148, 163, 184, .14);
    --line-strong: rgba(148, 163, 184, .26);

    --text: #e2e8f0;
    --heading: #f8fafc;
    --muted: #94a3b8;

    --accent: #14b8a6;
    --accent-2: #2dd4bf;
    --accent-soft: rgba(20, 184, 166, .1);
    --accent-line: rgba(45, 212, 191, .4);
    --warn: #f87171;

    --sans: "Inter", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
    --mono: ui-monospace, "Cascadia Code", "JetBrains Mono", "SF Mono", Consolas, Menlo, monospace;

    --radius: 14px;
    --gutter: 24px;
    --flow-gap: 28px;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }

html {
    scroll-behavior: smooth;
    scroll-padding-top: 84px;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--sans);
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

h1, h2, h3, p, ul, ol, fieldset, legend { margin: 0; padding: 0; }
ul, ol { list-style: none; }
fieldset { border: 0; min-width: 0; }
img { max-width: 100%; display: block; }
a { color: inherit; }

h1, h2, h3 { color: var(--heading); letter-spacing: -.025em; line-height: 1.12; font-weight: 700; }
h2 { font-size: clamp(1.8rem, 3.4vw, 2.6rem); max-width: 22ch; }
h3 { font-size: 1.15rem; letter-spacing: -.01em; line-height: 1.3; }

:focus-visible { outline: 2px solid var(--accent-2); outline-offset: 3px; border-radius: 6px; }

.container { width: 100%; max-width: 1160px; margin: 0 auto; padding: 0 var(--gutter); }

.visually-hidden, .hp {
    position: absolute; width: 1px; height: 1px; overflow: hidden;
    clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}

.skip-link {
    position: absolute; left: 16px; top: -60px; z-index: 100;
    background: var(--accent); color: #042f2a; font-weight: 600;
    padding: 10px 14px; border-radius: 8px; text-decoration: none;
}
.skip-link:focus { top: 12px; }

.accent { color: var(--accent-2); }

/* ---------- Micro elements ---------- */
.eyebrow, .tag, .badge, .microcopy, .lane-name, .flow-note, .form-note, .essay-tags, .terminal-title, .terminal-live {
    font-family: var(--mono);
}

.eyebrow { color: var(--accent-2); font-size: .82rem; letter-spacing: .04em; margin-bottom: 14px; }

.tag {
    display: inline-block; align-self: flex-start;
    font-size: .72rem; letter-spacing: .08em; text-transform: uppercase;
    color: var(--accent-2); background: var(--accent-soft);
    border: 1px solid rgba(45, 212, 191, .28); border-radius: 6px;
    padding: 3px 9px; white-space: nowrap;
}

.pill {
    display: inline-flex; align-items: center; gap: 7px;
    font-family: var(--mono); font-size: .72rem; letter-spacing: .06em; text-transform: uppercase;
    color: var(--accent-2); background: var(--accent-soft);
    border: 1px solid var(--accent-line); border-radius: 999px;
    padding: 3px 10px; white-space: nowrap;
}
.pill::before {
    content: ""; width: 6px; height: 6px; border-radius: 50%;
    background: var(--accent-2); box-shadow: 0 0 8px var(--accent-2);
}

.microcopy { color: var(--muted); font-size: .82rem; }

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
    font: 600 .95rem/1.2 var(--sans); text-decoration: none; cursor: pointer;
    padding: .72rem 1.1rem; border-radius: 10px; border: 1px solid transparent;
    transition: transform .15s ease, background-color .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-sm { padding: .55rem .9rem; font-size: .875rem; }
.btn-lg { padding: .95rem 1.4rem; font-size: 1rem; }
.btn-block { width: 100%; }

.btn-primary {
    background: var(--accent); color: #042f2a;
    box-shadow: 0 0 0 1px rgba(45, 212, 191, .4), 0 12px 32px -12px rgba(20, 184, 166, .8);
}
.btn-primary:hover { background: var(--accent-2); box-shadow: 0 0 0 1px rgba(45, 212, 191, .6), 0 14px 38px -10px rgba(20, 184, 166, .95); }

.btn-ghost { color: var(--text); border-color: var(--line-strong); background: rgba(148, 163, 184, .06); }
.btn-ghost:hover { border-color: rgba(148, 163, 184, .5); background: rgba(148, 163, 184, .1); }

.btn-outline { color: var(--accent-2); border-color: var(--accent-line); background: var(--accent-soft); }
.btn-outline:hover { border-color: var(--accent-2); background: rgba(20, 184, 166, .16); }

/* ---------- Brand ---------- */
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--heading); font-weight: 700; font-size: 1.05rem; }
.brand b { color: var(--accent-2); }
.brand-mark {
    font-family: var(--mono); font-size: .85em; font-weight: 700;
    color: #042f2a; background: var(--accent); border-radius: 5px; padding: 2px 7px;
    box-shadow: 0 0 18px -4px rgba(20, 184, 166, .9);
}

/* ---------- Navigation ---------- */
.nav {
    position: sticky; top: 0; z-index: 50;
    background: rgba(15, 23, 42, .82);
    -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--line);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; min-height: 68px; gap: 20px; }
.nav-menu { display: flex; align-items: center; gap: 28px; }
.nav-menu a:not(.btn) { color: var(--muted); text-decoration: none; font-size: .93rem; font-weight: 500; transition: color .15s ease; }
.nav-menu a:not(.btn):hover { color: var(--heading); }

.nav-toggle {
    display: none; width: 42px; height: 42px; padding: 11px 10px;
    background: transparent; border: 1px solid var(--line-strong); border-radius: 10px; cursor: pointer;
    flex-direction: column; justify-content: space-between;
}
.nav-toggle span { display: block; height: 2px; border-radius: 2px; background: var(--text); transition: transform .2s ease, opacity .2s ease; }
.nav.open .nav-toggle span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.nav.open .nav-toggle span:nth-child(2) { opacity: 0; }
.nav.open .nav-toggle span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero { position: relative; padding: 84px 0 96px; isolation: isolate; }
.hero::before {
    content: ""; position: absolute; inset: 0; z-index: -2;
    background:
        radial-gradient(780px 460px at 78% 0%, rgba(20, 184, 166, .2), transparent 65%),
        radial-gradient(620px 420px at 0% 100%, rgba(34, 211, 238, .08), transparent 60%);
}
.hero::after {
    content: ""; position: absolute; inset: 0; z-index: -1;
    background-image:
        linear-gradient(rgba(148, 163, 184, .07) 1px, transparent 1px),
        linear-gradient(90deg, rgba(148, 163, 184, .07) 1px, transparent 1px);
    background-size: 44px 44px;
    -webkit-mask-image: radial-gradient(ellipse at 70% 20%, #000 5%, transparent 70%);
    mask-image: radial-gradient(ellipse at 70% 20%, #000 5%, transparent 70%);
}

.hero-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: 52px; align-items: center; }

.badge {
    display: inline-flex; align-items: center; gap: 10px;
    font-size: .74rem; letter-spacing: .12em; color: var(--accent-2);
    background: var(--accent-soft); border: 1px solid var(--accent-line);
    border-radius: 999px; padding: 6px 14px; margin-bottom: 26px;
}
.badge-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent-2); box-shadow: 0 0 10px var(--accent-2); animation: pulse 2.4s ease-in-out infinite; }

.hero h1 { font-size: clamp(2.2rem, 4.4vw, 3.5rem); line-height: 1.07; letter-spacing: -.035em; }
.lead { margin-top: 24px; color: var(--muted); font-size: 1.12rem; max-width: 56ch; }

.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }
.hero .microcopy { margin-top: 14px; }

.facts { display: grid; grid-template-columns: repeat(4, auto); justify-content: start; gap: 0 34px; margin-top: 44px; padding-top: 26px; border-top: 1px solid var(--line); }
.facts li { display: flex; flex-direction: column; }
.facts b { font-family: var(--mono); font-size: 1.7rem; line-height: 1.1; color: var(--heading); }
.facts span { color: var(--muted); font-size: .8rem; }

/* ---------- Terminal ---------- */
.terminal, .intake, .flow {
    background: var(--term);
    border: 1px solid var(--line-strong);
    border-radius: var(--radius);
    overflow: hidden;
}
.terminal { box-shadow: 0 0 0 1px rgba(45, 212, 191, .08), 0 40px 90px -40px rgba(20, 184, 166, .55), 0 30px 60px -30px rgba(0, 0, 0, .8); }

.terminal-bar {
    display: flex; align-items: center; gap: 14px;
    padding: 12px 16px; background: rgba(148, 163, 184, .06); border-bottom: 1px solid var(--line);
}
.dots { display: inline-flex; gap: 7px; }
.dots i { width: 11px; height: 11px; border-radius: 50%; background: rgba(148, 163, 184, .3); }
.terminal-title { color: var(--muted); font-size: .78rem; flex: 1; }
.terminal-live { display: inline-flex; align-items: center; gap: 7px; color: var(--accent-2); font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; }
.terminal-live i { width: 7px; height: 7px; border-radius: 50%; background: var(--accent-2); box-shadow: 0 0 10px var(--accent-2); animation: pulse 1.8s ease-in-out infinite; }

.terminal-body { padding: 22px 20px 24px; font-family: var(--mono); font-size: .86rem; line-height: 1.7; color: var(--text); }
.t-line { opacity: 0; animation: line-in .4s ease forwards; }
.t-line:nth-child(1) { animation-delay: .2s; }
.t-line:nth-child(2) { animation-delay: .7s; }
.t-line:nth-child(3) { animation-delay: 1s; }
.t-line:nth-child(4) { animation-delay: 1.5s; }
.t-line:nth-child(5) { animation-delay: 2s; }
.t-line:nth-child(6) { animation-delay: 2.5s; }
.t-line:nth-child(7) { animation-delay: 3.1s; }
.t-line:nth-child(8) { animation-delay: 3.4s; }

.t-prompt { color: var(--accent-2); margin-right: 6px; }
.t-dim { color: var(--muted); }
.t-ok { color: var(--accent-2); margin-top: 14px; }

.job {
    display: grid; grid-template-columns: minmax(62px, max-content) minmax(0, 1fr) auto; align-items: center; gap: 12px;
    margin-top: 10px; padding: 10px 12px;
    background: rgba(148, 163, 184, .05); border: 1px solid var(--line); border-radius: 10px;
}
.t-dim + .job { margin-top: 16px; }
.job-name { color: var(--heading); font-weight: 600; }
.job-steps { color: var(--muted); font-size: .74rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.job-steps i { font-style: normal; color: var(--accent-2); margin-right: 4px; }
.job .pill { letter-spacing: .03em; padding: 3px 9px; }

.caret { display: inline-block; width: 8px; height: 1.05em; vertical-align: text-bottom; background: var(--accent-2); animation: blink 1.1s steps(1) infinite; }

/* ---------- Sections ---------- */
.section { padding: 104px 0; border-top: 1px solid var(--line); }
.section-alt { background: var(--bg-deep); }
.section-lead { margin-top: 18px; color: var(--muted); font-size: 1.08rem; max-width: none; }

/* ---------- Comparison ---------- */
.compare { width: 100%; margin-top: 52px; border-collapse: separate; border-spacing: 0; table-layout: fixed; }
.compare th, .compare td { text-align: left; vertical-align: top; padding: 20px 24px; border-bottom: 1px solid var(--line); }
.compare thead th { font-family: var(--mono); font-size: .78rem; letter-spacing: .08em; text-transform: uppercase; font-weight: 600; color: var(--muted); padding-top: 22px; padding-bottom: 22px; }
.compare thead th:first-child, .compare tbody th { width: 21%; }
.compare tbody th { color: var(--heading); font-weight: 600; font-size: .98rem; padding-left: 0; }

.compare .col-them { color: var(--muted); }
.compare td.col-them::before { content: "\2715"; color: var(--warn); font-size: .8rem; margin-right: 10px; }

.compare .col-us {
    color: var(--text); background: rgba(20, 184, 166, .07);
    border-left: 1px solid var(--accent-line); border-right: 1px solid var(--accent-line);
}
.compare thead .col-us { color: var(--accent-2); border-top: 1px solid var(--accent-line); border-radius: var(--radius) var(--radius) 0 0; }
.compare thead .col-us .brand-mark { margin-right: 8px; }
.compare tbody tr:last-child .col-us { border-bottom: 1px solid var(--accent-line); border-radius: 0 0 var(--radius) var(--radius); }
.compare tbody tr:last-child th, .compare tbody tr:last-child .col-them { border-bottom: 0; }
.compare td.col-us::before { content: "\2713"; color: var(--accent-2); font-weight: 700; margin-right: 10px; }

/* ---------- Cards / stack ---------- */
.card {
    display: flex; flex-direction: column; gap: 12px;
    background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
    padding: 26px 24px; transition: border-color .2s ease, transform .2s ease, background-color .2s ease;
}
.card p { color: var(--muted); font-size: .95rem; }
.card:hover { border-color: var(--accent-line); background: var(--surface-2); }

.stack { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; margin-top: 52px; }

/* ---------- Commit-to-store flow ---------- */
.flow { margin-top: 28px; }
.flow-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 20px; background: rgba(148, 163, 184, .06); border-bottom: 1px solid var(--line); }
.flow-note { color: var(--muted); font-size: .78rem; }

.flow-body { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; padding: 30px 26px; }

.node {
    position: relative; display: flex; flex-direction: column; justify-content: center;
    min-height: 58px; padding: 10px 16px;
    background: var(--surface); border: 1px solid var(--line-strong); border-radius: 10px;
    color: var(--heading); font-size: .9rem; font-weight: 600; line-height: 1.3;
}
.node small { font-family: var(--mono); font-size: .7rem; font-weight: 400; color: var(--muted); margin-top: 2px; }
.node-kicker { color: var(--accent-2); margin-right: 6px; }
.node-accent { flex-direction: row; align-items: center; font-family: var(--mono); border-color: var(--accent-line); background: var(--accent-soft); white-space: nowrap; }
.node-done { border-color: var(--accent-line); background: var(--accent-soft); color: var(--accent-2); }

/* connector: line plus arrowhead into every node that follows another */
.flow-source .node + .node::before, .lane-steps .node + .node::before {
    content: ""; position: absolute; top: 50%; left: calc(-1 * var(--flow-gap) - 1px);
    width: var(--flow-gap); height: 1px; background: var(--accent-line);
}
.flow-source .node + .node::after, .lane-steps .node + .node::after {
    content: ""; position: absolute; top: calc(50% - 4px); left: -8px;
    border-left: 7px solid var(--accent-2); border-top: 4px solid transparent; border-bottom: 4px solid transparent;
}

.flow-source { position: relative; display: flex; align-items: center; gap: var(--flow-gap); padding-right: var(--flow-gap); }
.flow-source::after { content: ""; position: absolute; right: 0; top: 50%; width: var(--flow-gap); height: 1px; background: var(--accent-line); }

/* three equal lanes without gaps, so the vertical bus runs from the first lane centre to the last */
.flow-lanes { position: relative; display: grid; grid-auto-rows: 1fr; padding-left: var(--flow-gap); }
.flow-lanes::before { content: ""; position: absolute; left: 0; top: 16.666%; bottom: 16.666%; width: 1px; background: var(--accent-line); }

.lane { position: relative; display: grid; grid-template-columns: 78px minmax(0, 1fr); align-items: center; gap: var(--flow-gap); padding: 8px 0; }
.lane::before { content: ""; position: absolute; left: calc(-1 * var(--flow-gap)); top: 50%; width: var(--flow-gap); height: 1px; background: var(--accent-line); }
.lane-name { position: relative; text-align: center; font-size: .74rem; letter-spacing: .08em; text-transform: uppercase; color: var(--accent-2); background: var(--term); border: 1px solid var(--accent-line); border-radius: 6px; padding: 4px 0; }
.lane-name::after { content: ""; position: absolute; left: 100%; top: 50%; width: var(--flow-gap); height: 1px; background: var(--accent-line); }
.lane-steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--flow-gap); }

/* ---------- Tiers ---------- */
.tiers { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; margin-top: 52px; }
.tier {
    display: flex; flex-direction: column; gap: 16px;
    background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 34px 32px;
}
.tier h3 { font-size: 1.55rem; letter-spacing: -.02em; line-height: 1.2; }
.tier-for { color: var(--muted); }
.tier-featured {
    border-color: var(--accent-line);
    background: linear-gradient(180deg, rgba(20, 184, 166, .12), rgba(20, 184, 166, 0) 45%), var(--surface);
    box-shadow: 0 40px 90px -50px rgba(20, 184, 166, .6);
}

.checks { display: grid; gap: 11px; margin-top: 6px; padding-top: 20px; border-top: 1px solid var(--line); }
.checks li { position: relative; padding-left: 28px; font-size: .97rem; }
.checks li::before { content: "\2713"; position: absolute; left: 0; top: 0; color: var(--accent-2); font-weight: 700; }

.tier-foot { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px; margin-top: auto; padding-top: 24px; }
.tier-terms { color: var(--muted); font-size: .92rem; }
.tier-terms b { color: var(--heading); }

/* ---------- Day 14 handover / scope ---------- */
.scope-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 22px; margin-top: 52px; align-items: start; }
.manifest { background: var(--term); border: 1px solid var(--line-strong); border-radius: var(--radius); overflow: hidden; }
.manifest-list { padding: 6px 24px 10px; }
.manifest-list li { position: relative; padding: 15px 0 15px 30px; border-bottom: 1px solid var(--line); }
.manifest-list li:last-child { border-bottom: 0; }
.manifest-list li::before { content: "\2713"; position: absolute; left: 0; top: 15px; color: var(--accent-2); font-weight: 700; }
.manifest-list b { display: block; color: var(--heading); }
.manifest-list span { color: var(--muted); font-size: .92rem; }

.scope-side { display: grid; gap: 22px; }
.tag-warn { color: var(--warn); background: rgba(248, 113, 113, .08); border-color: rgba(248, 113, 113, .3); }
.crosses { display: grid; gap: 12px; }
.crosses li { position: relative; padding-left: 26px; color: var(--muted); font-size: .95rem; }
.crosses li::before { content: "\2715"; position: absolute; left: 0; top: 1px; font-size: .8rem; color: var(--muted); }
.crosses-warn li::before { color: var(--warn); }

.guarantee {
    display: flex; align-items: center; gap: 22px; flex-wrap: wrap;
    margin-top: 22px; padding: 24px 28px;
    border: 1px solid var(--accent-line); border-radius: var(--radius);
    background: linear-gradient(90deg, rgba(20, 184, 166, .14), rgba(20, 184, 166, .03));
}
.guarantee h3 { font-size: 1.3rem; }
.guarantee p { color: var(--text); margin-top: 4px; }

/* ---------- FAQ ---------- */
.faq { display: grid; gap: 12px; max-width: none; margin-top: 44px; }
#faq h2 { max-width: none; }
.faq-item { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; transition: border-color .2s ease; }
.faq-item[open], .faq-item:hover { border-color: var(--accent-line); }
.faq-item summary {
    display: flex; align-items: center; justify-content: space-between; gap: 16px;
    padding: 18px 22px; cursor: pointer; list-style: none;
    color: var(--heading); font-weight: 600;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; font-family: var(--mono); font-size: 1.25rem; line-height: 1; color: var(--accent-2); }
.faq-item[open] summary::after { content: "\2212"; }
.faq-item p { padding: 0 22px 20px; color: var(--muted); font-size: .95rem; max-width: none; }

/* ---------- Proof ---------- */
/* Section headings run the full width of the container before they wrap, on every page. */
.section h2 { max-width: none; }
.essays { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; margin-top: 52px; }
.essay { text-decoration: none; }
.essay:hover { transform: translateY(-3px); }
.essay p { display: -webkit-box; -webkit-line-clamp: 4; line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.essay-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; padding-top: 8px; font-size: .72rem; color: var(--muted); }
.essay-tags span { border: 1px solid var(--line-strong); border-radius: 5px; padding: 1px 7px; }
.essay-more { color: var(--accent-2); font-weight: 600; font-size: .92rem; }

.author {
    display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
    margin-top: 22px; padding: 20px 24px;
    background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
}
.author img { width: 64px; height: 64px; border-radius: 50%; border: 2px solid var(--accent); object-fit: cover; }
.author-text { display: flex; flex-direction: column; flex: 1 1 260px; }
.author-text b { color: var(--heading); font-size: 1.05rem; }
.author-text span { color: var(--muted); font-size: .92rem; }
.author-links { display: flex; flex-wrap: wrap; gap: 10px; }

/* ---------- Contact / intake ---------- */
.section-cta { position: relative; isolation: isolate; }
.section-cta::before {
    content: ""; position: absolute; inset: 0; z-index: -1;
    background: radial-gradient(760px 420px at 85% 100%, rgba(20, 184, 166, .16), transparent 65%);
}
.contact-grid { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: 56px; align-items: start; }

.steps { display: grid; gap: 22px; margin: 36px 0 30px; }
.steps li { display: grid; grid-template-columns: auto 1fr; gap: 16px; align-items: start; }
.steps b { color: var(--heading); }
.steps p { color: var(--muted); font-size: .95rem; }
.contact-copy .btn { margin-top: 20px; }

.intake { box-shadow: 0 40px 90px -50px rgba(20, 184, 166, .5); }
.intake-form { display: grid; gap: 20px; padding: 28px; }
.field-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.field { display: grid; gap: 8px; align-content: start; }

.field label, .field legend { font-family: var(--mono); font-size: .76rem; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.field legend { margin-bottom: 8px; }

.field input[type="text"], .field input[type="email"], .field select, .field textarea {
    width: 100%; font: inherit; font-size: 1rem; color: var(--heading);
    background: var(--bg); border: 1px solid var(--line-strong); border-radius: 10px;
    padding: .75rem .9rem; transition: border-color .15s ease, box-shadow .15s ease;
}
.field textarea { resize: vertical; min-height: 128px; }
.field ::placeholder { color: #64748b; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--accent-2); box-shadow: 0 0 0 3px rgba(20, 184, 166, .22); }

.choices { display: flex; flex-wrap: wrap; gap: 10px; }
.choice { position: relative; cursor: pointer; }
.choice input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.choice span {
    display: block; font-family: var(--sans); font-size: .92rem; letter-spacing: 0; text-transform: none; color: var(--text);
    border: 1px solid var(--line-strong); border-radius: 999px; padding: .5rem 1rem; background: var(--bg);
    transition: border-color .15s ease, background-color .15s ease, color .15s ease;
}
.choice input:checked + span { border-color: var(--accent-2); background: var(--accent-soft); color: var(--accent-2); }
.choice input:focus-visible + span { outline: 2px solid var(--accent-2); outline-offset: 3px; }

.field-error, .form-error { color: var(--warn); font-size: .86rem; }
.field-error:empty, .form-error:empty { display: none; }
.form-error ul { list-style: none; }
.form-note { color: var(--muted); font-size: .76rem; text-align: center; }

.intake-sent { display: grid; gap: 14px; justify-items: start; padding: 40px 28px; }
.intake-sent h3 { font-size: 1.35rem; }
.intake-sent p { color: var(--muted); }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--line); background: var(--bg-deep); padding: 34px 0; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 18px 28px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 22px; }
.footer-links a { color: var(--muted); text-decoration: none; font-size: .9rem; }
.footer-links a:hover { color: var(--heading); }
.footer-note { color: var(--muted); font-size: .82rem; flex-basis: 100%; }

/* ---------- Scroll reveal (only when landing.js runs) ---------- */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ---------- Motion ---------- */
@keyframes line-in { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
@keyframes blink { 50% { opacity: 0; } }
@keyframes pulse { 50% { opacity: .35; } }

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation: none !important; transition: none !important; }
    .t-line, .reveal { opacity: 1; transform: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1020px) {
    .hero { padding: 56px 0 72px; }
    .hero-grid, .contact-grid { grid-template-columns: minmax(0, 1fr); gap: 44px; }
    .scope-grid { grid-template-columns: minmax(0, 1fr); }
    .stack, .essays { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .section { padding: 80px 0; }

    /* flow: source on top, lanes below */
    .flow-body { grid-template-columns: minmax(0, 1fr); gap: var(--flow-gap); }
    .flow-source { padding-right: 0; justify-content: center; }
    .flow-source::after, .flow-lanes::before, .lane::before { display: none; }
    .flow-lanes { padding-left: 0; }
}

@media (max-width: 900px) {
    .js .nav-toggle { display: flex; }
    .js .nav-menu {
        display: none; position: absolute; left: 0; right: 0; top: 100%;
        flex-direction: column; align-items: stretch; gap: 4px;
        padding: 14px var(--gutter) 22px;
        background: var(--bg-deep); border-bottom: 1px solid var(--line);
    }
    .js .nav.open .nav-menu { display: flex; }
    .js .nav-menu a:not(.btn) { padding: 12px 4px; font-size: 1rem; border-bottom: 1px solid var(--line); }
    .js .nav-menu .btn { margin-top: 14px; }
    html:not(.js) .nav-inner { flex-wrap: wrap; padding-top: 12px; padding-bottom: 12px; }
    html:not(.js) .nav-menu { flex-wrap: wrap; gap: 14px 20px; }

    .tiers { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 760px) {
    :root { --gutter: 18px; }
    .section { padding: 64px 0; }

    /* comparison table turns into one card per criterion */
    .compare, .compare tbody, .compare tr, .compare th, .compare td { display: block; width: auto; }
    .compare thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
    .compare { margin-top: 36px; }
    .compare tbody tr { margin-top: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
    .compare tbody th { width: auto; padding: 16px 18px 12px; border-bottom: 1px solid var(--line) !important; font-size: 1.02rem; }
    .compare td { display: grid; grid-template-columns: auto minmax(0, 1fr); padding: 14px 18px; border: 0 !important; border-radius: 0 !important; }
    .compare td::before { grid-row: 2; grid-column: 1; }
    .compare td::after {
        content: attr(data-label); grid-row: 1; grid-column: 1 / -1;
        font-family: var(--mono); font-size: .68rem; letter-spacing: .08em; text-transform: uppercase;
        color: var(--muted); margin-bottom: 6px;
    }
    .compare td.col-us::after { color: var(--accent-2); }
    .compare td.col-us { border-top: 1px solid var(--accent-line) !important; }

    .stack, .essays, .field-row { grid-template-columns: minmax(0, 1fr); }
    .facts { grid-template-columns: repeat(2, auto); gap: 22px 34px; }

    .lane { grid-template-columns: minmax(0, 1fr); gap: 10px; padding: 12px 0; }
    .lane-name { justify-self: start; padding: 4px 12px; }
    .lane-name::after { display: none; }
    .lane-steps { --flow-gap: 18px; }
    .lane-steps .node { min-height: 64px; padding: 8px 10px; font-size: .82rem; }

    .tier { padding: 28px 22px; }
    .intake-form { padding: 22px 18px; }
    .author-links { flex-basis: 100%; }
}

@media (max-width: 480px) {
    .hero-cta .btn, .tier-foot .btn { width: 100%; text-align: center; }
    .badge { font-size: .62rem; letter-spacing: .06em; padding: 6px 12px; }
    .job { grid-template-columns: 62px minmax(0, 1fr); }
    .job-steps { display: none; }
    .job .pill { justify-self: end; }
    .terminal-body { padding: 18px 14px 20px; font-size: .8rem; }
    .flow-source { --flow-gap: 18px; }
    .footer-inner { flex-direction: column; align-items: flex-start; }
}

/* Two-column card grid for the service pages (four cards, two per row). */
.stack-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 900px) { .stack-2 { grid-template-columns: minmax(0, 1fr); } }
.stack-2 .tag { white-space: normal; }

/* Static explainer diagrams on the landing and service pages, readable on a phone. */
.section .diagram { margin: 44px auto 0; max-width: 720px; }
.section .diagram img { display: block; width: 100%; height: auto; }
.section .diagram figcaption { margin-top: 12px; text-align: center; color: var(--muted); font-family: var(--mono); font-size: .8rem; }

/* ======================================================================
   Site-wide additions: the layout is shared by every public page now.
   ====================================================================== */

/* ---------- Generic utilities ---------- */
.text-center { text-align: center; }
.page-narrow { max-width: 880px; }
.hero-compact { padding: 64px 0 52px; }
.hero-compact h1 { font-size: clamp(2rem, 4vw, 3rem); line-height: 1.1; letter-spacing: -.03em; }
.hero-compact .lead { max-width: 64ch; }
.hero-compact .microcopy { margin-top: 18px; }
.hero-compact .microcopy a { color: var(--accent-2); }
.section-tight { padding-top: 56px; }
.section-note { margin-top: 28px; color: var(--muted); }
.checks-wide { max-width: 860px; margin-top: 36px; padding-top: 0; border-top: 0; gap: 16px; }
.checks-wide li { font-size: 1.02rem; color: var(--muted); }
.checks-wide b { color: var(--heading); }

/* ---------- Navigation: five items plus the button ---------- */
.nav-menu a[aria-current="page"] { color: var(--heading); }
@media (max-width: 1100px) {
    .nav-menu { gap: 20px; }
    .nav-menu a:not(.btn) { font-size: .9rem; }
}

/* ---------- Footer with columns ---------- */
.footer { padding: 52px 0 28px; }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) repeat(3, minmax(0, 1fr)); gap: 32px 40px; }
.footer-about p { margin-top: 16px; color: var(--muted); font-size: .92rem; max-width: 40ch; }
.footer-col h4 { font-family: var(--mono); font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--accent-2); margin: 6px 0 14px; }
.footer-col a { display: block; color: var(--muted); text-decoration: none; font-size: .92rem; padding: 5px 0; }
.footer-col a:hover { color: var(--heading); }
.footer-bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px 24px; margin-top: 36px; padding-top: 18px; border-top: 1px solid var(--line); color: var(--muted); font-size: .82rem; }
.footer-bottom a { color: var(--muted); text-decoration: none; }
.footer-bottom a:hover { color: var(--heading); }
@media (max-width: 900px) { .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .footer-about { grid-column: 1 / -1; } }
@media (max-width: 480px) { .footer-grid { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Blog index ---------- */
.subscribe { gap: 14px; }
.subscribe p { color: var(--text); }
.subscribe-form { display: flex; gap: 10px; flex-wrap: wrap; }
.subscribe-form input {
    flex: 1 1 240px; font: inherit; color: var(--heading);
    background: var(--bg); border: 1px solid var(--line-strong); border-radius: 10px; padding: .7rem .9rem;
}
.subscribe-form input:focus { outline: none; border-color: var(--accent-2); box-shadow: 0 0 0 3px rgba(20, 184, 166, .22); }
.form-ok { color: var(--accent-2); font-size: .92rem; }
.post-list { display: grid; gap: 18px; margin-top: 32px; }
.post-card { gap: 10px; }
.post-card-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 14px; }
.post-series { font-family: var(--mono); font-size: .76rem; color: var(--muted); }
.post-card h2 { font-size: 1.35rem; max-width: none; }
.post-card h2 a { color: var(--heading); text-decoration: none; }
.post-card h2 a:hover { color: var(--accent-2); }
.post-card-foot { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px 20px; margin-top: 6px; }

/* ---------- Profile (About) ---------- */
.profile { display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: 40px; align-items: center; }
.profile img { width: 160px; height: 160px; border-radius: 50%; border: 3px solid var(--accent); object-fit: cover; box-shadow: 0 0 40px -10px rgba(20, 184, 166, .7); }
.profile-links { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 18px; color: var(--muted); font-size: .92rem; }
.profile-links a { color: var(--accent-2); text-decoration: none; }
.profile-links a:hover { text-decoration: underline; }
.cred-list { display: grid; margin-top: 36px; max-width: 860px; }
.cred-list li { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; padding: 14px 0; border-bottom: 1px solid var(--line); color: var(--heading); }
.cred-list a { color: var(--accent-2); text-decoration: none; font-size: .92rem; white-space: nowrap; }
.cred-list a:hover { text-decoration: underline; }
@media (max-width: 760px) {
    .profile { grid-template-columns: minmax(0, 1fr); gap: 24px; }
    .profile img { width: 120px; height: 120px; }
}

/* ---------- Long-form pages (.prose): reading defaults the base reset removed. The essays have blog.css. ---------- */
.prose { font-size: 1.04rem; line-height: 1.72; }
.prose p { margin: 0 0 1.15em; }
.prose ul, .prose ol { margin: 0 0 1.15em; padding-left: 1.5em; }
.prose ul { list-style: disc; }
.prose ol { list-style: decimal; }
.prose li { margin: .35em 0; }
.prose h2 { font-size: clamp(1.5rem, 2.6vw, 2rem); max-width: none; margin-bottom: .8em; }
.prose h2 { margin-top: 2em; color: var(--accent-2); }
.prose h2:first-child { margin-top: 0; }
.prose h3 { font-size: 1.25rem; margin: 1.8em 0 .6em; }
.prose a { color: var(--accent-2); }
.prose a:hover { text-decoration: underline; }
.prose strong { color: var(--heading); }
.prose code {
    font-family: var(--mono); font-size: .9em; color: #f1f5f9;
    background: rgba(148, 163, 184, .14); border-radius: 4px; padding: .1em .35em;
}
@media (max-width: 760px) {
    .prose { font-size: 1rem; }
}

/* ---------- Small text that was under 12px on phones ---------- */
.tag, .pill { font-size: .75rem; }
.terminal-live, .essay-tags { font-size: .75rem; }
@media (max-width: 480px) { .badge { font-size: .7rem; letter-spacing: .05em; } }

/* Remaining monospace labels that computed below 12px on phones. */
.badge, .job-steps, .node small, .lane-name { font-size: .76rem; }

/* ---------- Contact page: the form is the page ---------- */
.hero-slim { padding: 40px 0 28px; }
.hero-slim .microcopy { margin-top: 10px; }
.contact-page .section-cta { padding-top: 36px; }
.contact-page .steps { margin-top: 28px; }
@media (max-width: 1020px) {
    .contact-page .contact-grid { gap: 32px; }
    .contact-page .intake { order: -1; }
}
@media (max-width: 760px) {
    .hero-slim { padding: 28px 0 18px; }
    .contact-page .section-cta { padding-top: 24px; }
}


/* ---------- Analytics consent (banner at the bottom, "Cookie settings" in the footer) ---------- */
.consent { position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 60; display: flex; justify-content: center; }
.consent[hidden] { display: none; }
.consent-box {
    width: 100%; max-width: 560px; padding: 18px 20px;
    background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--radius);
    box-shadow: 0 18px 50px -20px rgba(0, 0, 0, .8);
}
.consent-box p { margin: 0; color: var(--text); font-size: .92rem; line-height: 1.55; }
.consent-box a { color: var(--accent-2); }
.consent-current { margin-top: 6px !important; color: var(--muted) !important; font-size: .82rem !important; }
.consent-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 12px; }
.footer-col .footer-link {
    display: block; width: 100%; text-align: left; padding: 5px 0; margin: 0;
    background: none; border: 0; cursor: pointer; font: inherit; font-size: .92rem; color: var(--muted);
}
.footer-col .footer-link:hover { color: var(--heading); }
.subscribe-note { color: var(--muted); font-size: .8rem; margin: 0; }
.subscribe-note a { color: var(--accent-2); }
