/* Caseknot — site-wide theme (loaded after /assets/site.css on every page).
   The app's look is the string-and-button legal folder: rust pressed board, waxed cream string,
   brass buttons, ink and desk grey, marker yellow for highlights. Big headings and the case's own
   words are set in the system serif, interface text in the system sans, evidence numbers in mono.
   Spacing follows a 4/8 px scale. Light and dark. */
:root {
  --ck-board-1: #C4623A; --ck-board-2: #A8461F; --ck-board-3: #6E2711;
  --ck-string: #F6EBD0; --ck-string-edge: #C9B27A; --ck-brass: #D9B45F;
  --ck-ink: #15212E; --ck-desk: #EEF0F3; --ck-marker: #FFD84D;

  --bg: #F8F9FB; --bg-soft: #EEF0F3; --bg-card: #FFFFFF;
  --text: #15212E; --text-2: #3F4C5A; --text-3: #667382;
  --line: rgba(21, 33, 46, .10); --line-2: rgba(21, 33, 46, .18);
  --nav-bg: rgba(248, 249, 251, .8);
  /* the build writes --accent inline on <html>; the theme owns it per colour scheme */
  --accent: #A8461F !important; --accent-2: #C4623A !important; --accent-ink: #FFF6E3;
  --ck-tint: rgba(168, 70, 31, .07); --ck-tint-line: rgba(168, 70, 31, .32);
  --shadow-sm: 0 1px 2px rgba(21, 33, 46, .05), 0 8px 24px -12px rgba(21, 33, 46, .14);
  --shadow-lg: 0 2px 6px rgba(21, 33, 46, .06), 0 40px 80px -32px rgba(21, 33, 46, .34);
  --radius: 20px; --radius-sm: 12px;
  --font-serif: "New York", ui-serif, Georgia, "Times New Roman", serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0E141B; --bg-soft: #121A23; --bg-card: #18222E;
    --text: #F4EEE1; --text-2: #BCC5CF; --text-3: #8A96A4;
    --line: rgba(246, 235, 208, .10); --line-2: rgba(246, 235, 208, .20);
    --nav-bg: rgba(14, 20, 27, .8);
    --accent: #E9936C !important; --accent-2: #C4623A !important;
    --ck-tint: rgba(233, 147, 108, .09); --ck-tint-line: rgba(233, 147, 108, .36);
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, .4), 0 8px 24px -12px rgba(0, 0, 0, .6);
    --shadow-lg: 0 2px 6px rgba(0, 0, 0, .4), 0 40px 80px -32px rgba(0, 0, 0, .8);
  }
}

body { background: var(--bg); }
::selection { background: var(--ck-marker); color: #15212E; }
mark { background: var(--ck-marker); color: #15212E; padding: 0 .18em; border-radius: 3px; }

/* type: serif for the big words, sans for the interface, mono for evidence numbers */
.display, .h1, .h2, .prose h2, .ck-serif { font-family: var(--font-serif); font-weight: 700; letter-spacing: -0.016em; }
.display { font-size: clamp(44px, 6.6vw, 84px); line-height: 1.04; letter-spacing: -0.022em; }
.h1 { line-height: 1.08; }
.h2 { font-size: clamp(30px, 3.6vw, 44px); line-height: 1.12; }
.lead { font-size: clamp(18px, 1.6vw, 21px); line-height: 1.5; letter-spacing: 0; }
.ck-mono, .prose code { font-family: var(--font-mono); }
.ck-case { font-family: var(--font-serif); font-weight: 700; }
.ck-case i { font-weight: 500; }

/* a Bates-style stamp, used as the small label above headings */
.ck-stamp {
  display: inline-block; margin: 0 0 16px; padding: 4px 8px; border-radius: 6px;
  font-family: var(--font-mono); font-size: 12px; font-weight: 600; line-height: 16px; letter-spacing: .08em; text-transform: uppercase;
  color: var(--accent); background: var(--ck-tint); border: 1px solid var(--ck-tint-line);
}

/* nav, buttons */
.brand span { font-family: var(--font-serif); font-weight: 700; font-size: 19px; letter-spacing: -0.01em; }
.brand img, .footer .brand img { border-radius: 0; box-shadow: none; }
.nav-cta, .btn-primary {
  background: linear-gradient(180deg, var(--ck-board-1), var(--ck-board-2)); color: #FFF6E3 !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .22), 0 8px 20px -10px rgba(110, 39, 17, .8);
}
.btn[aria-disabled="true"] { cursor: default; }
.btn[aria-disabled="true"]:hover { transform: none; filter: none; }

/* the pressed board */
.ck-board {
  color: var(--ck-string);
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 .09 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"),
    linear-gradient(180deg, var(--ck-board-1) 0%, var(--ck-board-2) 56%, #8C3718 100%);
}

/* a Mac window: the screenshots already carry their own toolbar, so the frame is only the
   rounded outline and the shadow (the radius follows the window's own corners: 1.8% of the width) */
.ck-window {
  display: block; position: relative; overflow: hidden; aspect-ratio: 2880 / 1800;
  border-radius: 1.8% / 2.88%; background: #EBEDEF;
  box-shadow: 0 0 0 1px rgba(21, 33, 46, .16), var(--shadow-lg);
}
.ck-window img, .ck-window picture { display: block; width: 100%; height: 100%; }
@media (prefers-color-scheme: dark) { .ck-window { box-shadow: 0 0 0 1px rgba(246, 235, 208, .16), var(--shadow-lg); } }

/* pages: legal, support */
.hero::before { display: none; }
.hero-icon { border-radius: 0; box-shadow: none; filter: drop-shadow(0 16px 24px rgba(110, 39, 17, .32)); }
.page-head { padding: 64px 0 32px; background: var(--bg-soft); }
.page-head .lead { font-family: var(--font-mono); font-size: 13px; letter-spacing: .06em; text-transform: uppercase; color: var(--text-3); margin-top: 16px; }
.doc { padding-top: 48px; padding-bottom: 96px; }
.prose h2 { font-size: 26px; margin: 48px 0 12px; }
.prose a { text-decoration: underline; text-decoration-color: var(--ck-tint-line); text-underline-offset: 3px; }
.prose a:hover { text-decoration-color: currentColor; }
.callout { background: var(--ck-tint); border-color: var(--ck-tint-line); }
.card, .contact-form, .faq details { border-color: var(--line); }
.faq summary { color: var(--text); font-size: 18px; align-items: baseline; }
.faq details { padding: 20px 0; }
.faq details > div { max-width: 68ch; }
.contact-form { box-shadow: var(--shadow-sm); }
.contact-form .h3 { font-family: var(--font-serif); font-weight: 700; }
.footer { background: var(--bg-soft); }
@media (prefers-color-scheme: dark) { .footer { background: #0A1016; } }
.ck-form-note { margin: 16px 8px 0; font-size: 14px; line-height: 22px; color: var(--text-3); text-align: center; }
.page-head .wrap { max-width: 820px; }   /* the title sits on the same column as the text below */
