/* Colors from the app (src/SpryCad.App/UI/Palette.axaml): accent blue, navy headings, slate text; green is the
   SpryCAD name and logo only. */
:root {
  --bg: #ffffff;
  --panel: #f5f7fa;          /* Spry.Panel */
  --strip: #e8edf3;          /* Spry.Strip */
  --fg: #2b3645;             /* Spry.Text */
  --heading: #1d3557;        /* Spry.Heading */
  --muted: #5a6b85;          /* Spry.TextMuted */
  --line: #d5dce6;           /* Spry.Border */
  --line-strong: #c5cfdc;    /* Spry.BorderStrong */
  --accent: #2f7bd6;         /* Spry.Accent */
  --accent-hover: #2568b8;
  --accent-soft: #e8f1fc;    /* Spry.HoverBg */
  --accent-text: #1d4e8f;    /* Spry.AccentText */
  --brand: #0f9a83;          /* Spry.Brand */
  --warn: #a8661a;           /* Spry.Warning */
  --band: #0e1a2b;           /* the dark title bands */
  --band-fg: #e9eef5;
  --band-muted: #9fb0c6;
  --grid: rgba(142, 192, 255, .07);
  --code-bg: #101924;
  --code-fg: #d6e2f0;
  --code-line: #223146;
  --mono: ui-monospace, "Cascadia Mono", "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  --r: 2px;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0c131d;
    --panel: #111a26;
    --strip: #172231;
    --fg: #d3dce8;
    --heading: #eef3f9;
    --muted: #8d9db3;
    --line: #213045;
    --line-strong: #2b3d56;
    --accent: #4a92e6;
    --accent-hover: #67a6ee;
    --accent-soft: #14253b;
    --accent-text: #8ec0ff;   /* Spry.AccentLight */
    --brand: #21b598;
    --warn: #d99a45;
    --band: #08101a;
    --grid: rgba(142, 192, 255, .06);
    --code-bg: #070d15;
    --code-line: #1b2a3d;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 15.5px/1.6 "Segoe UI", system-ui, -apple-system, Roboto, Ubuntu, sans-serif;
}
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); text-decoration: underline; text-underline-offset: 3px; }
h1, h2, h3 { color: var(--heading); line-height: 1.2; margin: 0 0 .5em; font-weight: 650; }
h1 { font-size: 2.6rem; letter-spacing: -.025em; }
h2 { font-size: 1.3rem; letter-spacing: -.01em; margin-top: 2.5rem; padding-bottom: .5rem; border-bottom: 1px solid var(--line); }
h3 { font-size: 1rem; margin-top: 1.75rem; }
p { margin: 0 0 1em; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.eyebrow {
  display: inline-block; font: 600 .72rem/1 var(--mono); letter-spacing: .14em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 1rem;
}

.wrap { max-width: 1080px; margin: 0 auto; padding: 0 16px; }

/* header: the app's crisp light chrome */
header.site { background: var(--bg); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 10; }
header.site .wrap { display: flex; align-items: center; gap: 1rem; height: 56px; }
.brand { display: flex; align-items: center; gap: .55rem; font-weight: 700; font-size: 1.1rem; letter-spacing: -.01em; color: var(--brand); }
.brand:hover { color: var(--brand); text-decoration: none; }
.brand img { width: 26px; height: 26px; }
header.site nav { margin-left: auto; display: flex; height: 100%; }
header.site nav a {
  display: flex; align-items: center; padding: 0 1rem; height: 100%;
  font-size: .8rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted);
  border-bottom: 2px solid transparent; margin-bottom: -1px;
}
header.site nav a:hover { color: var(--heading); text-decoration: none; }
header.site nav a[aria-current="page"] { color: var(--heading); border-bottom-color: var(--accent); }

footer.site { border-top: 1px solid var(--line); margin-top: 5rem; padding: 1.5rem 0; color: var(--muted); font-size: .85rem; }
footer.site .wrap { display: flex; gap: 1.25rem; flex-wrap: wrap; }
footer.site .brand-sm { font-weight: 700; color: var(--brand); }

/* buttons: square, solid */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  padding: .7rem 1.3rem; border-radius: var(--r); border: 1px solid var(--line-strong);
  background: transparent; color: var(--heading); font: inherit; font-size: .9rem; font-weight: 600; letter-spacing: .01em;
  cursor: pointer; transition: background .12s, border-color .12s, color .12s;
}
.btn:hover { text-decoration: none; border-color: var(--accent); color: var(--accent); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: #fff; }
.btn .arrow { font-family: var(--mono); }
.band .btn:not(.primary) { color: var(--band-fg); border-color: rgba(233, 238, 245, .3); }
.band .btn:not(.primary):hover { border-color: var(--band-fg); color: #fff; }

/* dark title band with a blueprint grid */
.band {
  background-color: var(--band);
  background-image:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px),
    linear-gradient(rgba(142, 192, 255, .03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(142, 192, 255, .03) 1px, transparent 1px);
  background-size: 96px 96px, 96px 96px, 24px 24px, 24px 24px;
  background-position: -1px -1px;
  color: var(--band-fg);
  border-bottom: 1px solid #1d2c42;
}
.band h1 { color: #fff; }
.band .lead { color: var(--band-muted); }
.band .eyebrow { color: #8ec0ff; }

/* home */
.hero { padding-top: 5rem; }
.hero h1 { font-size: 3.2rem; max-width: 760px; }
.hero .lead { font-size: 1.15rem; max-width: 600px; margin-bottom: 2rem; }
.hero .actions { display: flex; gap: .75rem; flex-wrap: wrap; }
.specs {
  display: flex; flex-wrap: wrap; gap: 0; margin: 3rem 0 0; padding: 0; list-style: none;
  border-top: 1px solid rgba(233, 238, 245, .12);
}
.specs li { padding: 1rem 2rem 1rem 0; margin-right: 2rem; border-right: 1px solid rgba(233, 238, 245, .12); }
.specs li:last-child { border-right: 0; }
.specs b { display: block; font: 600 1.15rem/1.2 var(--mono); color: #fff; }
.specs span { font-size: .78rem; letter-spacing: .06em; text-transform: uppercase; color: var(--band-muted); }

/* the screenshot, framed like a window, overlapping the band */
.shot-wrap { position: relative; }
.shot-wrap::before { content: ""; position: absolute; inset: 0 0 50% 0; background: var(--band); border-bottom: 1px solid #1d2c42; }
.shot { position: relative; margin: 0; border: 1px solid var(--line-strong); background: var(--bg); box-shadow: 0 18px 50px rgba(8, 16, 26, .28); }
.shot img { width: 100%; height: auto; display: block; }

.section-head { margin: 5rem 0 1.5rem; }
.section-head h2 { border: 0; margin: 0; padding: 0; font-size: 1.8rem; }
.features { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.features div { background: var(--bg); padding: 1.5rem 1.4rem 1.6rem; box-shadow: inset 0 2px 0 transparent; transition: box-shadow .15s, background .15s; }
.features div:hover { box-shadow: inset 0 2px 0 var(--accent); background: var(--panel); }
@media (max-width: 900px) { .features { grid-template-columns: repeat(2, 1fr); } }
.features .num { display: block; font: 600 .75rem var(--mono); color: var(--accent); letter-spacing: .1em; margin-bottom: .9rem; }
.features h3 { margin: 0 0 .4rem; font-size: 1.05rem; }
.features p { margin: 0; color: var(--muted); font-size: .92rem; }

.cta { margin-top: 4rem; display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 2rem; justify-content: space-between; padding: 2rem; border: 1px solid var(--line); border-left: 3px solid var(--accent); background: var(--panel); }
.cta h2 { border: 0; margin: 0 0 .25rem; padding: 0; font-size: 1.3rem; }
.cta p { margin: 0; color: var(--muted); }

/* download */
.page-title { padding-top: 3rem; padding-bottom: 2.5rem; }
.page-title h1 { margin-bottom: .35rem; }
.page-title .lead { margin: 0; }

.picker { margin-top: -1.5rem; position: relative; border: 1px solid var(--line-strong); background: var(--bg); box-shadow: 0 8px 24px rgba(8, 16, 26, .08); }
.picker .head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding: .55rem 1.1rem; background: var(--strip); border-bottom: 1px solid var(--line); }
.picker .head strong { font-size: .75rem; letter-spacing: .1em; text-transform: uppercase; color: var(--heading); }
.picker .meta { font: .78rem var(--mono); color: var(--muted); }
.picker .body { display: flex; flex-wrap: wrap; gap: 1.1rem 2rem; align-items: end; padding: 1.1rem; }
.picker label { display: block; font: 600 .68rem var(--mono); color: var(--muted); text-transform: uppercase; letter-spacing: .12em; margin-bottom: .4rem; }
.seg { display: inline-flex; border: 1px solid var(--line-strong); border-radius: var(--r); overflow: hidden; background: var(--bg); }
.seg button {
  font: inherit; font-size: .9rem; font-weight: 600; padding: .5rem 1.05rem; border: 0; background: transparent; color: var(--muted); cursor: pointer;
}
.seg button:hover { color: var(--heading); background: var(--accent-soft); }
.seg button + button { border-left: 1px solid var(--line-strong); }
.seg button[aria-pressed="true"] { background: var(--accent); color: #fff; }
select {
  font: 600 .9rem var(--mono); padding: .5rem 2rem .5rem .7rem; border-radius: var(--r); border: 1px solid var(--line-strong);
  background: var(--bg); color: var(--heading); min-width: 240px; max-width: 100%;
}
select:focus, .seg button:focus-visible, .btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.notice { border: 1px solid var(--line); border-left: 3px solid var(--accent); background: var(--panel); padding: .75rem 1rem; margin: 1.25rem 0 0; font-size: .92rem; }
.notice.warn { border-left-color: var(--warn); }

.files { margin: 1.5rem 0 0; border: 1px solid var(--line); }
.file { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1rem; padding: 1rem 1.15rem; }
.file + .file { border-top: 1px solid var(--line); }
.file .what { flex: 1 1 260px; min-width: 0; }
.file .what strong { display: block; color: var(--heading); }
.file .what .name { font: .8rem var(--mono); color: var(--muted); overflow-wrap: anywhere; }
.file .sha { flex-basis: 100%; font: .72rem/1.4 var(--mono); color: var(--muted); overflow-wrap: anywhere; }

ol.steps { padding: 0; list-style: none; counter-reset: s; }
ol.steps li { counter-increment: s; position: relative; padding-left: 2.6rem; margin-bottom: .9rem; }
ol.steps li::before {
  content: counter(s, decimal-leading-zero); position: absolute; left: 0; top: .1rem;
  font: 600 .72rem/1 var(--mono); color: var(--accent); border: 1px solid var(--accent); padding: .3rem .35rem;
}

/* a command block: a strip with the shell and Copy, then the commands (scrolling sideways on their own) */
.code { margin: .6rem 0 1.1rem; background: var(--code-bg); border: 1px solid var(--code-line); border-left: 3px solid var(--accent); border-radius: var(--r); }
.code .bar { display: flex; align-items: center; justify-content: space-between; padding: .3rem .45rem .3rem 1rem; border-bottom: 1px solid var(--code-line); }
.code .bar span { font: 600 .66rem var(--mono); letter-spacing: .12em; text-transform: uppercase; color: #6f819b; }
pre { margin: 0; padding: .85rem 1rem; overflow-x: auto; color: var(--code-fg); font: .82rem/1.65 var(--mono); }
code { font-family: var(--mono); font-size: .86em; background: var(--strip); color: var(--heading); padding: .1em .35em; border-radius: var(--r); }
pre code { background: none; color: inherit; padding: 0; font-size: inherit; }
.code .copy {
  font: 600 .66rem var(--mono); letter-spacing: .08em; text-transform: uppercase;
  padding: .3rem .6rem; border-radius: var(--r); border: 1px solid var(--code-line); background: transparent; color: #8a9bb3; cursor: pointer;
}
.code .copy:hover { color: #fff; border-color: var(--accent); }

[hidden] { display: none !important; }

@media (max-width: 640px) {
  h1, .hero h1 { font-size: 2.1rem; }
  .hero { padding-top: 3rem; }
  .features { grid-template-columns: 1fr; }
  .specs li { padding-right: 1.25rem; margin-right: 1.25rem; }
  select { min-width: 0; width: 100%; }
  .picker .body > div { flex: 1 1 100%; }
  header.site nav a { padding: 0 .6rem; }
  .cta { padding: 1.4rem; }
}
