/* The public site's stylesheet (notes/DECISIONS.md, S.141): served by Phoenix at /site.css, as docs/index.html carried it inline. */
/* Layout: a reading column (40rem) for words; the features widen to 64rem.
   Newsreader for the wordmark, the headings and the letter; Inter for text and controls;
   IBM Plex Mono for the small labels and the address.
   Dark-first, warm-grey neutrals on the app's own hue; amber for the display italic
   and small marks. Buttons neutral. */
:root {
  --bg: oklch(0.165 0.005 80);
  --bg-raised: oklch(0.2 0.005 80);
  --fg: oklch(0.95 0.006 80);
  --muted: oklch(0.7 0.012 80);
  --faint: oklch(0.52 0.012 80);
  --border: oklch(0.3 0.007 80);
  --border-strong: oklch(0.38 0.008 80);
  --accent: oklch(0.8 0.14 75);
  --accent-soft: oklch(0.8 0.14 75 / 0.14);
  --ok: oklch(0.74 0.17 150);
  --glow: oklch(0.8 0.14 75 / 0.07);
  --font-display: "Newsreader", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --reading: 40rem;
  --wide: 64rem;
  /* The demo's frame, and the header and footer bars aligned with it (S.141). */
  --frame-max: 100rem;
  color-scheme: dark;
}
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --bg: oklch(0.985 0.002 80);
    --bg-raised: oklch(1 0 0);
    --fg: oklch(0.2 0.006 80);
    --muted: oklch(0.46 0.012 80);
    --faint: oklch(0.6 0.01 80);
    --border: oklch(0.88 0.005 80);
    --border-strong: oklch(0.8 0.006 80);
    --accent: oklch(0.58 0.14 65);
    --accent-soft: oklch(0.58 0.14 65 / 0.12);
    --ok: oklch(0.6 0.17 150);
    --glow: oklch(0.58 0.14 65 / 0.08);
    color-scheme: light;
  }
}
:root[data-theme="light"] {
  --bg: oklch(0.985 0.002 80);
  --bg-raised: oklch(1 0 0);
  --fg: oklch(0.2 0.006 80);
  --muted: oklch(0.46 0.012 80);
  --faint: oklch(0.6 0.01 80);
  --border: oklch(0.88 0.005 80);
  --border-strong: oklch(0.8 0.006 80);
  --accent: oklch(0.58 0.14 65);
  --accent-soft: oklch(0.58 0.14 65 / 0.12);
  --ok: oklch(0.6 0.17 150);
  --glow: oklch(0.58 0.14 65 / 0.08);
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { height: 100%; scroll-behavior: smooth; }
body {
  margin: 0; min-height: 100%;
  background: var(--bg); color: var(--fg);
  font-family: var(--font-body); font-size: 1.0625rem; line-height: 1.6;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
a { color: inherit; }
:focus-visible { outline: 2px solid var(--muted); outline-offset: 3px; border-radius: 4px; }
::selection { background: var(--accent-soft); }
.skip { position: absolute; left: -999px; top: 0; background: var(--bg-raised); color: var(--fg); padding: .5rem .75rem; border-radius: 6px; }
.skip:focus { left: 16px; top: 12px; z-index: 20; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.col { max-width: var(--reading); margin-inline: auto; }
.wide { max-width: var(--wide); margin-inline: auto; }

header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 10;
  background: color-mix(in oklab, var(--bg) 82%, transparent);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  margin-inline: calc(-1 * max(16px, env(safe-area-inset-left, 0px))) calc(-1 * max(16px, env(safe-area-inset-right, 0px)));
  padding-inline: max(16px, env(safe-area-inset-left, 0px)) max(16px, env(safe-area-inset-right, 0px));
}
.bar { display: flex; align-items: center; gap: 1.25rem; min-height: 3.5rem; max-width: var(--frame-max); margin-inline: auto; }
.wordmark { display: inline-flex; align-items: center; flex-shrink: 0; text-decoration: none; font-family: var(--font-display); font-weight: 500; letter-spacing: -0.01em; font-size: 1.3rem; line-height: 1; }
.bar nav { margin-left: auto; display: flex; gap: 1.25rem; font-size: .9rem; }
.bar nav a { color: var(--muted); text-decoration: none; transition: color .15s ease; }
.bar nav a:hover { color: var(--fg); }
@media (max-width: 520px) { .bar nav a.optional { display: none; } }

.hero { position: relative; padding-block: clamp(2.5rem, 7vw, 5.5rem) clamp(2.5rem, 6vw, 4rem); scroll-margin-top: calc(3.5rem + env(safe-area-inset-top, 0px)); }
.hero::before {
  content: ""; position: absolute; inset: -4rem 0 0 0;
  background: radial-gradient(44rem 20rem at 30% 0, var(--glow), transparent 70%);
  pointer-events: none;
}
.hero > * { position: relative; }
.hero .wide { text-align: center; }
h1 {
  font-family: var(--font-display); font-weight: 400;
  font-size: clamp(2.5rem, 7vw, 4.4rem); line-height: 1.03; letter-spacing: -0.02em;
  margin: 0 auto; text-wrap: balance; max-width: 26ch;
}
h1 em { display: block; font-style: italic; color: var(--accent); }
.pillars {
  list-style: none; margin: 2.75rem auto 0; padding: 0; max-width: var(--wide);
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2rem;
}
.pillars li { border-top: 1px solid var(--border-strong); padding-top: 1rem; min-width: 0; text-wrap: pretty; }
.pillars b { display: block; font-weight: 600; font-size: 1.02rem; letter-spacing: -0.01em; }
.pillars span { display: block; margin-top: .35rem; color: var(--muted); font-size: .95rem; line-height: 1.5; }
@media (max-width: 760px) {
  .pillars { grid-template-columns: 1fr; gap: 1.25rem; margin-top: 2.25rem; max-width: 28rem; }
}
.cta { margin-top: 1.75rem; display: flex; flex-wrap: wrap; gap: .625rem; align-items: center; justify-content: center; }
.btn {
  font: inherit; font-size: .92rem; font-weight: 500; cursor: pointer; text-decoration: none;
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .6rem .95rem; border-radius: 8px;
  border: 1px solid var(--border-strong); background: var(--bg-raised); color: var(--fg);
  transition: border-color .15s ease, transform .15s ease, color .15s ease;
}
.btn:hover { border-color: var(--muted); transform: translateY(-1px); }
.btn.primary { background: var(--fg); color: var(--bg); border-color: transparent; }
.btn.primary:hover { border-color: transparent; opacity: .92; }
.btn[data-done="true"] { color: var(--ok); border-color: var(--ok); }

main { display: grid; gap: clamp(3.5rem, 8vw, 6rem); padding-block: 1rem clamp(4rem, 8vw, 6rem); text-align: center; }
main > section { scroll-margin-top: 4.5rem; }
.kicker { font-family: var(--font-mono); font-size: .74rem; font-weight: 500; letter-spacing: .1em; text-transform: uppercase; color: var(--accent); margin: 0 0 1rem; }
h2 {
  font-family: var(--font-display); font-weight: 500;
  font-size: clamp(1.7rem, 3.6vw, 2.35rem); line-height: 1.12; letter-spacing: -0.015em;
  margin: 0 0 1rem; text-wrap: balance;
}
section p { margin: 0; text-wrap: pretty; }
.lead { font-size: 1.15rem; }
.quiet { color: var(--muted); }

.features { position: relative; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--border); margin-top: 1.5rem; }
.feature { padding: 1.4rem 1.25rem; min-width: 0; border-bottom: 1px solid var(--border); }
.feature:nth-child(3n+2), .feature:nth-child(3n+3) { border-left: 1px solid var(--border); }
.feature h3 { display: flex; align-items: center; justify-content: center; gap: .5rem; margin: 0 0 .4rem; font-size: 1.05rem; font-weight: 600; letter-spacing: -0.01em; text-wrap: balance; }
.feature-icon { width: 1.1rem; height: 1.1rem; flex: none; color: var(--accent); }
.feature p { color: var(--muted); font-size: .95rem; }
.feature-traces { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.feature-pulse {
  fill: none; stroke: var(--accent); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round;
  opacity: 0; animation: feature-travel var(--travel-duration, 12s) linear infinite;
  animation-delay: var(--travel-delay); animation-play-state: paused;
}
.features[data-in-view="true"] .feature-pulse { animation-play-state: running; }
@keyframes feature-travel {
  0% { stroke-dashoffset: var(--travel-start); opacity: 0; }
  8% { opacity: .75; }
  62% { opacity: .75; }
  72%, 100% { stroke-dashoffset: var(--travel-end); opacity: 0; }
}
@media (min-width: 600px) and (max-width: 991px) {
  .features { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .feature:nth-child(n) { border-left: 0; }
  .feature:nth-child(even) { border-left: 1px solid var(--border); }
}
@media (max-width: 599px) {
  .features { grid-template-columns: 1fr; }
  .feature:nth-child(n) { border-left: 0; padding: 1.1rem 0; }
}

.letter { margin-top: 1.75rem; scroll-margin-top: 4.5rem; }
.letter p { font-family: var(--font-display); font-size: clamp(1.15rem, 2.2vw, 1.35rem); line-height: 1.5; margin: 0; }
.letter strong { color: var(--accent); font-weight: 700; text-decoration: underline; text-decoration-thickness: .065em; text-underline-offset: .15em; white-space: nowrap; }
.ask {
  border: 1px solid var(--border); border-radius: 14px;
  padding: clamp(1.25rem, 3vw, 1.75rem);
  background: linear-gradient(180deg, color-mix(in oklab, var(--accent-soft) 35%, transparent), transparent 70%), var(--bg-raised);
  display: grid; gap: .6rem;
  scroll-margin-top: 4.5rem;
}
.ask .kicker { margin-bottom: 0; }
.contact { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: .35rem .25rem; margin-top: .5rem; }
.ask { justify-items: center; }
.ask p { max-width: 40rem; }
.book { margin-top: .5rem; }
.line { display: inline-flex; align-items: center; gap: .5rem; text-decoration: none; color: var(--fg); padding: .25rem 0; border-bottom: 1px solid transparent; transition: border-color .15s ease; }
.line:hover { border-color: var(--accent); }
.line #address { font-family: var(--font-mono); font-size: .95rem; user-select: all; -webkit-user-select: all; }
.line .ico { width: 1.05rem; height: 1.05rem; flex: none; color: var(--muted); }
.iconbtn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 2.75rem; height: 2.75rem; border-radius: 6px; border: 0; background: transparent; color: var(--muted); cursor: pointer;
  transition: color .15s ease, background .15s ease;
}
.iconbtn:hover { color: var(--fg); background: var(--accent-soft); }
.iconbtn .ico { width: 1rem; height: 1rem; }
.iconbtn .ico-check { display: none; }
.iconbtn[data-done="true"] { color: var(--ok); }
.iconbtn[data-done="true"] .ico-copy { display: none; }
.iconbtn[data-done="true"] .ico-check { display: block; }

footer { border-top: 1px solid var(--border); padding-block: 1.15rem max(1.15rem, env(safe-area-inset-bottom, 0px)); font-size: .8125rem; color: var(--muted); }
.foot { display: flex; align-items: center; flex-wrap: wrap; justify-content: space-between; gap: .8rem 1.5rem; max-width: var(--frame-max); margin-inline: auto; }
.foot a { color: inherit; text-decoration: none; }
.foot a:hover { color: var(--fg); text-decoration: underline; }
.foot .wordmark { color: var(--fg); font-size: 1.1rem; }
.foot .wordmark:hover { text-decoration: none; }
.founder { display: flex; align-items: center; flex-wrap: wrap; gap: .2rem .65rem; }
.founder a { display: inline-flex; align-items: center; gap: .45rem; color: var(--fg); }
.linkedin-mark { width: .8rem; height: .8rem; flex: none; }
.footer-contact { display: flex; align-items: center; flex-wrap: wrap; gap: .35rem .5rem; }
@media (max-width: 540px) {
  .foot { align-items: flex-start; flex-direction: column; gap: .7rem; }
  .founder { display: grid; }
  .footer-contact { align-items: flex-start; flex-direction: column; gap: .15rem; }
  .footer-contact .separator { display: none; }
}

.hero > *, main > section { animation: rise .7s ease both; }
main > section:nth-child(1) { animation-delay: .1s }
main > section:nth-child(2) { animation-delay: .18s }
@keyframes rise { from { opacity: .4; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
  .hero > *, main > section, .feature-pulse { animation: none; }
  html { scroll-behavior: auto; }
  .btn:hover { transform: none; }
}

/* The contact blocks
/* The demo on the landing (notes/DECISIONS.md, S.141): the product in a
   frame under the title, as wide as the window allows (the rows and their
   buttons need the room they have in the app), read-only. */
.demo {
  --frame-w: min(var(--frame-max), 100vw - 2 * max(16px, env(safe-area-inset-left, 0px)));
  width: var(--frame-w);
  margin: 2.5rem calc((100% - var(--frame-w)) / 2) 0;
  scroll-margin-top: 4.5rem;
  text-align: left;
}
.frame {
  border: 1px solid var(--border-strong); border-radius: 14px; overflow: hidden;
  background: var(--bg-raised);
  box-shadow: 0 40px 90px -40px color-mix(in oklab, var(--accent) 35%, transparent);
}
.frame-bar { display: flex; align-items: center; gap: .9rem; padding: .55rem .9rem; border-bottom: 1px solid var(--border); font-size: .82rem; color: var(--muted); }
.dots { display: inline-flex; gap: .35rem; }
.dots i { width: .6rem; height: .6rem; border-radius: 50%; background: var(--border-strong); }
.frame-title { font-family: var(--font-mono); font-size: .74rem; letter-spacing: .04em; text-transform: uppercase; }
.frame-open { margin-left: auto; color: var(--fg); text-decoration: none; border-bottom: 1px solid transparent; transition: border-color .15s ease; }
.frame-open:hover { border-color: var(--accent); }
.frame iframe { display: block; width: 100%; height: clamp(36rem, 78vh, 54rem); border: 0; background: #fff; }
.frame-note { margin-top: .9rem; font-size: .9rem; text-align: center; }
@media (max-width: 760px) {
  .frame iframe { height: 30rem; }
  .frame-title { display: none; }
}
