/* Kelda: Marginalia on the web. Paper, ink, mood accents, Literata for the book voice. */

@font-face {
  font-family: "Literata";
  src: url("/fonts/literata-latin.woff2") format("woff2");
  font-weight: 400 600;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: light dark;
  --paper: #fbf8f3;
  --raised: #ffffff;
  --ink: #1f1b16;
  --muted: #746b5f;
  --rule: rgba(31, 27, 22, 0.12);
  --accent: #8a4b2a;
  --bezel: #1f1b16;
  --serif: "Literata", Georgia, "Iowan Old Style", "Times New Roman", serif;
  --sans: system-ui, -apple-system, "Segoe UI", Inter, Roboto, "Helvetica Neue", Arial, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #1b1b1d;
    --raised: #26262a;
    --ink: #e4ded4;
    --muted: #9a948b;
    --rule: rgba(228, 222, 212, 0.14);
    --accent: #e0a47a;
    --bezel: #000000;
  }
}

*, *::before, *::after { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 1.0625rem/1.55 var(--sans);
  -webkit-text-size-adjust: 100%;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:focus-visible, summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

h1, h2, h3 { font-family: var(--serif); font-weight: 600; margin: 0 0 0.75rem; text-wrap: balance; }
h1 { font-size: clamp(2.5rem, 9vw, 4.25rem); line-height: 1.08; letter-spacing: -0.01em; }
h2 { font-size: clamp(1.75rem, 5vw, 2.5rem); line-height: 1.15; }
h3 { font-size: 1.25rem; line-height: 1.25; }
p { margin: 0 0 1rem; }

.wrap { max-width: 66rem; margin: 0 auto; padding: 0 1.5rem; }
.label {
  font: 700 0.75rem/1.2 var(--sans);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 0.75rem;
}
.label.accent { color: var(--accent); }
.lede { font-size: 1.25rem; line-height: 1.45; color: var(--muted); }
.small { font-size: 0.875rem; color: var(--muted); }
.serif { font-family: var(--serif); }

/* Header + footer */
.top { padding-top: 1.5rem; padding-bottom: 0.5rem; }
.mark { font: 600 1.625rem/1 var(--serif); text-decoration: none; }

/* Sections: depth is a hairline, never a shadow */
.band { padding-top: 3.5rem; padding-bottom: 3.5rem; border-top: 1px solid var(--rule); }

/* Hero */
.hero { display: grid; gap: 2.5rem; padding-top: 2rem; padding-bottom: 3.5rem; }
.hero .lede { max-width: 32rem; }
.hero p:not(.label):not(.lede) { max-width: 32rem; }

/* Store badges: placeholders until launch */
.badges { display: flex; flex-wrap: wrap; gap: 0.75rem; margin: 1.5rem 0 1rem; }
.badge {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  min-height: 3.25rem;
  padding: 0.5rem 1.15rem;
  border-radius: 14px;
  background: var(--ink);
  color: var(--paper);
  font-weight: 600;
  line-height: 1.15;
  text-decoration: none;
}
.badge small { font-size: 0.75rem; font-weight: 500; opacity: 0.8; }

/* Phone frames */
.phone {
  margin: 0;
  width: min(17rem, 78vw);
  border: 0.6rem solid var(--bezel);
  border-radius: 2.5rem;
  overflow: hidden;
  background: var(--paper);
  outline: 1px solid var(--rule);
}
.hero .phone { justify-self: center; }

.shots {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: min(16rem, 78vw);
  gap: 1.5rem;
  margin: 2rem -1.5rem 0;
  padding: 0 1.5rem 0.5rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
}
.shots figure { margin: 0; scroll-snap-align: center; }
.shots .phone { width: 100%; }
.shots figcaption { margin-top: 1rem; font-size: 0.9375rem; color: var(--muted); }
.shots figcaption strong { display: block; color: var(--ink); font: 600 1.125rem/1.3 var(--serif); margin-bottom: 0.25rem; }

/* Ideas / Stories */
.cols { display: grid; gap: 1.5rem 3rem; margin-top: 1.5rem; }
.cols p { color: var(--muted); }
.big { font: 600 1.375rem/1.3 var(--serif); margin-top: 1rem; }

/* Moods */
.mood-art { display: flex; gap: 0.75rem; margin-bottom: 1.25rem; }
.mood-art img { width: 3.25rem; height: 3.25rem; }
.chips { list-style: none; display: flex; flex-wrap: wrap; gap: 0.5rem; padding: 0; margin: 0 0 1.75rem; }
.chips li {
  padding: 0.45rem 0.85rem;
  border: 1px solid var(--rule);
  border-radius: 14px;
  background: var(--raised);
  color: var(--a);
  font-weight: 600;
  font-size: 0.9375rem;
}
@media (prefers-color-scheme: dark) { .chips li { color: var(--d); } }

/* Rows (feature lists): label left, words right, hairline between */
.rows { list-style: none; padding: 0; margin: 1.5rem 0 0; border-top: 1px solid var(--rule); }
.rows li { padding: 0.9rem 0; border-bottom: 1px solid var(--rule); color: var(--muted); }
.rows strong { display: block; color: var(--ink); font-weight: 600; }

.price { font: 600 1.5rem/1.3 var(--serif); margin-bottom: 0.75rem; }
.price .num { font-size: 2.25rem; font-variant-numeric: lining-nums tabular-nums; }

/* FAQ */
.faq details { border-bottom: 1px solid var(--rule); }
.faq details:first-of-type { border-top: 1px solid var(--rule); margin-top: 1.5rem; }
.faq summary {
  cursor: pointer;
  list-style: none;
  padding: 1.1rem 2rem 1.1rem 0;
  position: relative;
  font: 600 1.1875rem/1.35 var(--serif);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 0.25rem; top: 1rem; font: 400 1.5rem/1 var(--sans); color: var(--muted); }
.faq details[open] summary::after { content: "\2212"; }
.faq details p { color: var(--muted); max-width: 40rem; }

.close { text-align: left; }

.foot { padding-top: 2.5rem; padding-bottom: 3rem; border-top: 1px solid var(--rule); color: var(--muted); font-size: 0.9375rem; }
.foot .mark { color: var(--ink); display: inline-block; margin-bottom: 0.75rem; }
.foot nav { display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; margin: 1rem 0; }

/* Legal pages */
.prose { max-width: 42rem; padding-bottom: 3rem; }
.prose h1 { font-size: clamp(2.25rem, 7vw, 3rem); margin-top: 1.5rem; }
.prose h2 { font-size: 1.5rem; margin-top: 2.5rem; }
.prose h3 { font-size: 1.125rem; margin-top: 1.5rem; }
.prose ul { padding-left: 1.25rem; margin: 0 0 1rem; }
.prose li { margin-bottom: 0.4rem; }

@media (min-width: 52rem) {
  .hero { grid-template-columns: 1.15fr 0.85fr; align-items: center; padding-top: 3.5rem; padding-bottom: 5rem; }
  .hero .phone { width: 18rem; }
  .shots { grid-auto-flow: row; grid-template-columns: repeat(3, 1fr); overflow: visible; margin: 2.5rem 0 0; padding: 0; }
  .shots .phone { width: min(100%, 16.5rem); }
  .cols { grid-template-columns: 1fr 1fr; }
  .band { padding-top: 5rem; padding-bottom: 5rem; }
}
