/* Lasivo public site. Same tokens as the app (docs/DESIGN_SYSTEM.md §2): grouped surfaces, teal action, system font,
   and the app's one bold place — the large rounded time on Today — reused once, in the home page's Today figure.
   No web fonts, no scripts, no images beyond the app icon. The public CSP allows only this stylesheet (no inline styles). */
:root {
  --bg: #f2f2f7; --surface: #fff; --surface-2: #f7f7fa;
  --text: #111418; --text-2: #4b5157; --text-3: #5f656b;
  --line: #d8d8de; --action: #006a73; --action-text: #fff; --action-soft: #e0f1f2;
  --ok: #1d7a3c; --ok-soft: #e4f4e8; --late: #9a5200; --late-soft: #fdf0dd; --focus: #0a84ff;
  --brand-deep: #0b2a33;
  --font: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --font-rounded: ui-rounded, 'SF Pro Rounded', -apple-system, BlinkMacSystemFont, var(--font);
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #000; --surface: #1c1c1e; --surface-2: #2c2c2e;
    --text: #f2f2f7; --text-2: #c7c7cc; --text-3: #a1a1a8;
    --line: #38383a; --action: #7bdde8; --action-text: #001619; --action-soft: #0f3a40;
    --ok: #6fd88e; --ok-soft: #12321d; --late: #ffbf66; --late-soft: #3a2a10;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 1.0625rem/1.55 var(--font); }
a { color: var(--action); text-underline-offset: 0.15em; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
.skip { position: absolute; left: 8px; top: -60px; background: var(--surface); color: var(--text); padding: 10px 14px; border-radius: 8px; z-index: 2; }
.skip:focus { top: 8px; }

/* ---- Header and footer (every page) ---- */
.site-head { max-width: 1040px; margin: 0 auto; padding: 14px 16px; display: flex; align-items: center; gap: 8px 16px; flex-wrap: wrap; }
.brand { display: inline-flex; align-items: center; gap: 10px; font: 700 1.3rem/1 var(--font-rounded); letter-spacing: -0.01em; color: var(--text); text-decoration: none; margin-right: auto; min-height: 44px; }
.brand img { width: 34px; height: 34px; border-radius: 8px; }
.site-nav ul { list-style: none; display: flex; flex-wrap: wrap; gap: 0 18px; margin: 0; padding: 0; }
.site-nav a { display: inline-flex; align-items: center; min-height: 44px; color: var(--text-2); text-decoration: none; font-size: 0.95rem; }
.site-nav a:hover { color: var(--text); text-decoration: underline; }
.site-nav a[aria-current='page'] { color: var(--text); font-weight: 600; }
.signin { order: 2; }
.site-nav { order: 3; flex-basis: 100%; }
@media (min-width: 720px) { .site-nav { order: 1; flex-basis: auto; } }

.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 18px; border-radius: 12px; font-weight: 650; text-decoration: none; }
.btn-primary { background: var(--action); color: var(--action-text); }
.btn-primary:hover { filter: brightness(1.08); }
.btn-tinted { background: var(--action-soft); color: var(--action); }

.site-foot { max-width: 1040px; margin: 48px auto 0; padding: 20px 16px 40px; border-top: 1px solid var(--line); color: var(--text-3); font-size: 0.88rem; }
.site-foot ul { list-style: none; display: flex; flex-wrap: wrap; gap: 0 18px; margin: 0 0 8px; padding: 0; }
.site-foot a { color: var(--text-2); display: inline-flex; min-height: 44px; align-items: center; }
.site-foot p { margin: 0; max-width: 62ch; }

/* ---- Home: hero ---- */
.hero { max-width: 1040px; margin: 0 auto; padding: 24px 16px 8px; display: grid; gap: 32px; align-items: center; }
@media (min-width: 900px) { .hero { grid-template-columns: 1.05fr 1fr; gap: 56px; padding-top: 48px; } }
.hero h1 { font: 750 clamp(2.1rem, 6.4vw, 3.3rem)/1.06 var(--font-rounded); letter-spacing: -0.025em; margin: 0 0 18px; max-width: 15ch; }
.hero .lead { font-size: 1.15rem; color: var(--text-2); margin: 0 0 24px; max-width: 46ch; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; }
.hero-actions p { margin: 0; color: var(--text-3); font-size: 0.92rem; max-width: 34ch; }

/* The Today figure: a still of the app's Today screen, built from text so it scales with the reader's text size. */
.today { margin: 0; }
.today-frame { background: var(--brand-deep); border-radius: 28px; padding: 14px; }
.today-screen { background: var(--bg); border-radius: 18px; padding: 18px 14px 14px; }
.today-date { margin: 0 4px 14px; font-weight: 700; font-size: 1.5rem; letter-spacing: -0.02em; }
.slot + .slot { margin-top: 20px; }
.slot-head { display: flex; align-items: baseline; gap: 10px; margin: 0 4px 8px; }
.slot-time { font: 700 1.6rem/1.1 var(--font-rounded); font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }
.slot-word { font: 700 1.2rem/1.1 var(--font-rounded); color: var(--text-2); }
.dose { background: var(--surface); border-radius: 14px; padding: 12px 14px; display: flex; align-items: center; gap: 12px; }
.dose + .dose { margin-top: 8px; }
.dose-main { flex: 1; min-width: 0; }
.dose-name { font-weight: 650; display: block; }
.dose-sub { color: var(--text-2); font-size: 0.86rem; display: block; }
.state { flex: none; font-size: 0.86rem; font-weight: 600; padding: 6px 10px; border-radius: 999px; }
.state-taken { background: var(--ok-soft); color: var(--ok); }
.state-due { background: var(--action); color: var(--action-text); }
.state-low { background: var(--late-soft); color: var(--late); }
.today figcaption { color: var(--text-3); font-size: 0.86rem; margin: 10px 4px 0; }

/* ---- Home: what it keeps (grouped list, as in the app) ---- */
.section { max-width: 1040px; margin: 0 auto; padding: 40px 16px 0; }
.section h2 { font: 700 1.6rem/1.2 var(--font-rounded); letter-spacing: -0.015em; margin: 0 0 6px; }
.section > p { color: var(--text-2); margin: 0 0 18px; max-width: 62ch; }
.group { list-style: none; margin: 0; padding: 0; background: var(--surface); border-radius: 12px; overflow: hidden; }
.group li { padding: 14px 16px; border-top: 1px solid var(--line); }
.group li:first-child { border-top: 0; }
.group h3 { font-size: 1.02rem; margin: 0 0 2px; }
.group p { margin: 0; color: var(--text-2); font-size: 0.95rem; max-width: 70ch; }
@media (min-width: 900px) {
  .group.two { display: grid; grid-template-columns: 1fr 1fr; }
  .group.two li { border-top: 1px solid var(--line); }
  .group.two li:nth-child(-n + 2) { border-top: 0; }
  .group.two li:nth-child(odd) { border-right: 1px solid var(--line); }
}
.plain { max-width: 62ch; }
.plain p { margin: 0 0 12px; }
.access { background: var(--surface); border-radius: 12px; padding: 18px 16px; max-width: 720px; }
.access p { margin: 0 0 14px; }

/* ---- Inner pages (privacy, support, important information) ---- */
.page { max-width: 760px; margin: 0 auto; padding: 16px 16px 0; }
.page h1 { font: 750 2rem/1.15 var(--font-rounded); letter-spacing: -0.02em; margin: 12px 0 14px; }
.page h2 { font-size: 1.25rem; margin: 1.8em 0 0.4em; }
.page h3 { font-size: 1.05rem; margin: 1.4em 0 0.3em; }
.page p, .page li { max-width: 68ch; }
.note { background: var(--late-soft); border-radius: 12px; padding: 12px 14px; }
.tbd { background: var(--late-soft); color: var(--text); padding: 0 4px; border-radius: 4px; font-weight: 600; }
.table-wrap { overflow-x: auto; background: var(--surface); border-radius: 12px; }
table { border-collapse: collapse; width: 100%; font-size: 0.95rem; }
th, td { text-align: left; border-bottom: 1px solid var(--line); padding: 10px 12px; vertical-align: top; }
tr:last-child td { border-bottom: 0; }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
@media (prefers-contrast: more) and (prefers-color-scheme: light) { :root { --text-2: #2f3439; --text-3: #3f444a; --line: #9a9aa0; } }
