/* Precept Systems design tokens and component classes.
   Load fonts/ beside this file. Light theme ("Pearl") is the default; add data-theme="dark" on <html> for "Night". */

@font-face { font-family: "Instrument Serif"; src: url("fonts/InstrumentSerif-Regular.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Geist"; src: url("fonts/Geist-Variable.woff2") format("woff2"); font-weight: 100 900; font-style: normal; font-display: swap; }
@font-face { font-family: "Geist Mono"; src: url("fonts/GeistMono-Variable.woff2") format("woff2"); font-weight: 100 900; font-style: normal; font-display: swap; }

:root, [data-theme="light"] {
  --ebody: #0d1035;
  --zodiac: #253a52;
  --sienna: #ee5518;
  --peach: #ff9760;
  --haze: #a97ff0;
  --silver-400: #8a8071;
  --silver-300: #a7a095;
  --silver-200: #c5c0b8;
  --silver-100: #e2dfdc;
  --pearl-400: #e6d6bb;
  --pearl-300: #ece0cc;
  --pearl-200: #f3ebdd;
  --pearl-100: #f9f5ee;
  --chalk: #faf6ed;
  --surface: var(--chalk);
  --surface-card: var(--pearl-400);
  --ink: var(--zodiac);
  --ink-strong: var(--ebody);
  --ink-muted: var(--silver-400);
  --line: var(--silver-200);
  --accent: var(--sienna);
  --on-accent: var(--ebody);
  --accent-text: var(--sienna);
  --focus-ring: var(--zodiac);
}

[data-theme="dark"] {
  --surface: var(--ebody);
  --surface-card: var(--zodiac);
  --ink: var(--chalk);
  --ink-strong: var(--pearl-100);
  --ink-muted: var(--silver-200);
  --line: rgba(230, 214, 187, 0.24);
  --accent-text: var(--peach);
  --focus-ring: var(--peach);
}

:root {
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-6: 24px;
  --space-8: 32px;
  --space-12: 48px;
  --space-16: 64px;
  --space-24: 96px;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-full: 9999px;
  --gradient-page: linear-gradient(90deg, #e6d6bb 0%, #faf6ed 100%);
  --gradient-night: linear-gradient(90deg, #253a52 0%, #0d1035 100%);
  --gradient-dawn: linear-gradient(180deg, #faf6ed 0%, #e6d6bb 28%, #a97ff0 60%, #ff9760 100%);
  --gradient-ember: radial-gradient(120% 90% at 50% 100%, #ff9760 0%, #ee5518 35%, #253a52 72%, #0d1035 100%);
  --gradient-horizon: linear-gradient(90deg, #ff9760 0%, #ee5518 22%, #253a52 62%, #0d1035 100%);
  --gradient-bloom: radial-gradient(90% 130% at 0% 50%, #ff9760 0%, #a97ff0 48%, #faf6ed 85%);
  --font-serif: "Instrument Serif", "Times New Roman", Georgia, serif;
  --font-sans: Geist, ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "Geist Mono", ui-monospace, "SF Mono", Menlo, monospace;
}

/* Type styles */
.display { font-family: var(--font-serif); font-size: 120px; line-height: 0.95; font-weight: 400; letter-spacing: -0.01em; }
.headline-xl { font-family: var(--font-serif); font-size: 80px; line-height: 1; font-weight: 400; letter-spacing: -0.01em; }
.headline-l { font-family: var(--font-serif); font-size: 56px; line-height: 1.05; font-weight: 400; letter-spacing: -0.005em; }
.headline-m { font-family: var(--font-serif); font-size: 40px; line-height: 1.1; font-weight: 400; }
.quote { font-family: var(--font-serif); font-size: 32px; line-height: 1.25; font-weight: 400; font-style: italic; }
.heading { font-family: var(--font-sans); font-size: 32px; line-height: 1.2; font-weight: 500; letter-spacing: -0.01em; }
.lead { font-family: var(--font-sans); font-size: 24px; line-height: 1.4; font-weight: 400; letter-spacing: -0.005em; }
.body { font-family: var(--font-sans); font-size: 17px; line-height: 1.55; font-weight: 400; }
.small { font-family: var(--font-sans); font-size: 14px; line-height: 1.45; font-weight: 400; }
.ui { font-family: var(--font-sans); font-size: 15px; line-height: 1.2; font-weight: 500; }
.label { font-family: var(--font-mono); font-size: 13px; line-height: 1.3; font-weight: 400; letter-spacing: 0.06em; text-transform: uppercase; }
.detail { font-family: var(--font-mono); font-size: 12px; line-height: 1.4; font-weight: 400; letter-spacing: 0.04em; text-transform: uppercase; }


/* Precept Systems — component classes. Values come from tokens.css (tokens.json). */

.ps-root { background: var(--surface); color: var(--ink); font-family: var(--font-sans); font-size: 17px; line-height: 1.55; -webkit-font-smoothing: antialiased; }

/* Button */
.ps-btn { display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2); min-height: 44px; padding: 0 22px; border: 1px solid transparent; border-radius: var(--radius-md); font-family: var(--font-sans); font-size: 15px; font-weight: 500; line-height: 1.2; letter-spacing: -0.005em; text-decoration: none; cursor: pointer; transition: background-color .16s ease-out, color .16s ease-out, border-color .16s ease-out; }
.ps-btn:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
.ps-btn[disabled], .ps-btn[aria-disabled="true"] { opacity: .4; pointer-events: none; }
.ps-btn--primary { background: var(--ink); color: var(--surface); }
.ps-btn--primary:hover { background: var(--ink-strong); }
.ps-btn--accent { background: var(--accent); color: var(--on-accent); }
.ps-btn--accent:hover { background: var(--peach); }
.ps-btn--quiet { background: transparent; color: var(--ink); border-color: var(--ink); }
.ps-btn--quiet:hover { background: var(--surface-card); }
.ps-btn--sm { min-height: 36px; padding: 0 var(--space-4); font-size: 14px; }

/* Label (Geist Mono eyebrow) */
.ps-label { display: inline-block; font-family: var(--font-mono); font-size: 13px; line-height: 1.3; font-weight: 400; letter-spacing: .06em; text-transform: uppercase; color: var(--ink); }
.ps-label--muted { color: var(--ink-muted); }
.ps-label--accent { color: var(--accent-text); }

/* Card */
.ps-card { background: var(--surface-card); color: var(--ink); border-radius: var(--radius-lg); padding: var(--space-8); }
.ps-card--outline { background: transparent; border: 1px solid var(--line); }
.ps-card__label { margin: 0 0 var(--space-3); }
.ps-card__title { margin: 0 0 var(--space-3); font-family: var(--font-serif); font-weight: 400; font-size: 40px; line-height: 1.05; letter-spacing: -0.005em; color: var(--ink); }
.ps-card__body { margin: 0; font-size: 17px; line-height: 1.55; }

/* Quote */
.ps-quote { margin: 0; padding: 0; border: 0; }
.ps-quote__text { margin: 0; font-family: var(--font-serif); font-style: italic; font-weight: 400; font-size: 32px; line-height: 1.25; color: var(--ink); }
.ps-quote__cite { display: block; margin-top: var(--space-4); font-family: var(--font-mono); font-style: normal; font-size: 12px; line-height: 1.4; letter-spacing: .04em; text-transform: uppercase; color: var(--ink); }

/* Page frame: header and footer chrome */
.ps-frame { display: flex; flex-direction: column; min-height: 100%; }
.ps-frame__header, .ps-frame__footer { display: flex; align-items: center; justify-content: space-between; gap: var(--space-6); }
.ps-frame__header { padding-bottom: var(--space-6); border-bottom: 1px solid var(--line); }
.ps-frame__footer { padding-top: var(--space-6); border-top: 1px solid var(--line); }
.ps-frame__logo { display: block; height: 22px; width: auto; }
.ps-frame__icon { display: block; width: 32px; height: 32px; }
.ps-frame__crumbs { display: flex; align-items: center; gap: var(--space-6); font-family: var(--font-mono); font-size: 12px; line-height: 1.4; letter-spacing: .04em; text-transform: uppercase; color: var(--ink); }
.ps-frame__crumbs > * + *::before { content: "\203A"; margin-right: var(--space-6); font-family: var(--font-sans); color: var(--ink); }
.ps-frame__meta { font-family: var(--font-mono); font-size: 12px; line-height: 1.4; letter-spacing: .04em; text-transform: uppercase; color: var(--ink); }
.ps-frame__body { flex: 1; padding: var(--space-12) 0; }
.ps-frame--night { background: var(--gradient-night); }

/* Theme-specific artwork (logo files carry fixed ink) */
[data-theme="dark"] .ps-only-light { display: none !important; }
:root:not([data-theme="dark"]) .ps-only-dark { display: none !important; }
