/* Lullaball tokens. The base set below is the original (handoff) palette; the Aubergine
   block at the end of this file overrides it and is the brand palette. */
:root {
  --surface: #f6f1ea;
  --surface-raised: #ffffff;
  --ink: #3b3633;
  --ink-muted: #5a534f;
  --line: #e3dcd3;
  --line-strong: #8c8279;
  --butter: #e7d7ac;
  --honey: #cdae7e;
  --walnut: #5a4535;
  --blush: #dcbcb2;
  --rosewood: #b79591;
  --plum: #4e3a44;
  --on-night: #f6f1ea;
  --blush-soft: #efe0da;   /* blush laid thin on surface, for cards */
  --lamplight: #f6f1ea;
  --accent: var(--plum);   /* the deep accent of the page's brand colour (Blush) */
  --action: #4e3a44;
  --on-action: #f6f1ea;
  --action-hover: #644c58;
  --focus: #3b3633;
  --error: #8a3b2e;
  --shadow-lift: 0 10px 18px -12px rgba(40, 32, 24, 0.45);
  /* The mark, in the brand colours: plum outline and shadow, butter for the lit side. */
  --mark-ink: var(--plum);
  --mark-fill: var(--butter);

  --space-1: 4px; --space-2: 8px; --space-3: 16px;
  --space-4: 24px; --space-5: 40px; --space-6: 64px; --space-7: 112px;
  --radius-full: 9999px;
  --gutter: clamp(16px, 5vw, 64px);

  --display: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  /* Paper grain, laid over the whole page at a whisper. */
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .3 0 0 0 0 .22 0 0 0 0 .2 0 0 0 .55 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  color-scheme: light;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; animation: none !important; } }

body {
  margin: 0;
  background: var(--surface);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
body::after {
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 10;
  background-image: var(--grain); opacity: 0.09; mix-blend-mode: multiply;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }

/* Type */
.display, .headline, .subhead, .lede, .price-figure, .wordmark, .signature, .letter-body, .cover-name {
  font-family: var(--display);
  font-weight: 380;
  font-variation-settings: "SOFT" 100;
  margin: 0;
}
.display em, .headline em { font-style: italic; color: var(--plum); }
.display { font-size: clamp(46px, 7vw, 76px); line-height: 1.0; letter-spacing: -0.01em; }
.headline { font-size: clamp(30px, 4vw, 42px); line-height: 1.1; }
.subhead { font-size: 22px; line-height: 1.25; }
.lede { font-size: clamp(21px, 2.2vw, 25px); line-height: 1.3; }
.body { margin: 0; max-width: 65ch; }
.small { font-size: 13px; line-height: 1.5; }
.muted { color: var(--ink-muted); }
.label {
  font-size: 11px; line-height: 1.4; font-weight: 500;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--accent); margin: 0;
}

/* The mark and name, in Plum with a Butter lit side */
/* Horizontal lockup (brand/logo): the ball is the height of the l; the gap is 0.42 of the ball. */
.lockup { display: inline-flex; align-items: flex-end; gap: 13px; color: var(--mark-ink); line-height: 0; }
.mark { width: 30px; height: 30px; flex: none; }
.wordmark { height: 30.5px; width: auto; aspect-ratio: 7297 / 1488.4; flex: none; }
.home { text-decoration: none; }

/* Notice bar */
.notice {
  margin: 0; padding: 10px var(--gutter);
  background: var(--plum); color: var(--on-night);
  text-align: center; letter-spacing: 0.04em;
}

/* Hero, on the Blush field with the lamplight glow */
.blush-field {
  background:
    radial-gradient(80% 110% at 6% 0%, var(--lamplight) 0%, transparent 55%),
    var(--blush);
  color: #3b3633;
  --accent: var(--plum);
}
.blush-field .muted { color: #4e3a44; }
.masthead {
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--space-3);
  padding: var(--space-4) var(--gutter);
}
.quiet-link { text-decoration: none; border-bottom: 1px solid currentColor; padding-bottom: 2px; }

.hero {
  display: grid; grid-template-columns: 1fr; gap: var(--space-5); align-items: center;
  padding: var(--space-4) var(--gutter) var(--space-6);
  max-width: 1320px; margin: 0 auto;
}
@media (min-width: 900px) { .hero { grid-template-columns: 1.2fr 1fr; gap: var(--space-6); padding-bottom: var(--space-7); } }
.hero-image { margin: 0; display: grid; gap: var(--space-2); }
/* The shadow edge: one corner curves like the mark. */
.hero-image img { border-radius: 24px 24px 180px 24px; box-shadow: var(--shadow-lift); }
.hero-copy { display: grid; gap: var(--space-4); justify-items: start; }

main { padding: 0 var(--gutter); }
section { scroll-margin-top: var(--space-4); }
.section-head { display: grid; gap: var(--space-3); margin-bottom: var(--space-5); }

/* The letter */
.letter { max-width: 640px; margin: 0 auto; padding: var(--space-7) 0 var(--space-5); display: grid; gap: var(--space-4); }
.letter-body { font-size: clamp(20px, 2vw, 23px); line-height: 1.5; display: grid; gap: var(--space-3); }
.letter-body p { margin: 0; }
.signature { font-style: italic; font-size: 30px; line-height: 1.2; color: var(--accent); margin-top: var(--space-2); }

.divider { color: var(--rosewood); display: flex; justify-content: center; padding: var(--space-5) 0; }
.divider svg { width: 240px; height: 30px; }

/* Cover chooser */
.choose { padding: var(--space-5) 0 var(--space-6); max-width: 1120px; margin: 0 auto; }
fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.covers legend { margin-bottom: var(--space-3); }
.cover-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-4) var(--space-3); }
/* Eight covers: two across, then four across (never 3+3+2). */
@media (min-width: 960px) { .cover-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--space-5) var(--space-4); } }

.cover { position: relative; display: grid; gap: 6px; align-content: start; cursor: pointer; }
.cover input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.swatch {
  position: relative; display: block; margin-bottom: var(--space-2);
  border-radius: 18px; outline: 2px solid transparent; outline-offset: 4px;
  transition: outline-color 300ms ease-out, transform 300ms ease-out;
}
.swatch > img:first-child { border-radius: 18px; aspect-ratio: 1; object-fit: cover; width: 100%; }
.inset {
  position: absolute; right: 8%; bottom: -6%; width: 36%;
  border-radius: 50%; border: 3px solid var(--surface);
  box-shadow: var(--shadow-lift);
}
.cover-name { font-size: 20px; line-height: 1.25; }
.cover-tier { font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent); font-weight: 500; }
.cover-line { font-size: 14px; line-height: 1.45; color: var(--ink-muted); }
.cover:hover .swatch { outline-color: var(--rosewood); }
.cover:has(input:checked) .swatch { outline-color: var(--accent); transform: translateY(-2px); }
.cover:has(input:checked) .cover-name::after { content: " ✓"; color: var(--accent); }
.cover:has(input:focus-visible) .swatch { outline: 2px solid var(--focus); }

.price {
  margin-top: var(--space-5); padding: var(--space-4) var(--space-5); border-radius: 20px;
  background: radial-gradient(120% 140% at 15% 0%, var(--butter) 0%, transparent 60%), var(--surface-raised);
  color: #3b3633;
}
.price[data-family="blush"] { background: radial-gradient(120% 140% at 15% 0%, var(--blush) 0%, transparent 60%), var(--surface-raised); }
.price .muted { color: #5a534f; }
.price p { margin: 0; }
.price-figure { font-size: 24px; line-height: 1.25; margin-bottom: var(--space-1); }

/* Fields */
.fields { display: grid; gap: var(--space-4); max-width: 520px; margin-top: var(--space-5); }
.field { display: grid; gap: var(--space-2); }
input[type="email"], select, textarea {
  font: inherit; color: var(--ink); background: var(--surface-raised);
  border: 1px solid var(--line-strong); border-radius: 12px;
  min-height: 48px; padding: 0 var(--space-3); width: 100%;
}
textarea { padding: var(--space-3); resize: vertical; min-height: 96px; line-height: 1.5; }
input:focus-visible, select:focus-visible, textarea:focus-visible, .button:focus-visible, a:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.check { display: flex; gap: var(--space-3); align-items: flex-start; cursor: pointer; min-height: 48px; padding-top: var(--space-2); }
.check input { width: 22px; height: 22px; margin: 2px 0 0; accent-color: var(--plum); flex: none; }
fieldset.field legend { margin-bottom: var(--space-2); }
.for-choice { display: flex; gap: var(--space-2); }
.for-choice label { flex: 1; cursor: pointer; }
.for-choice input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.for-choice span {
  display: flex; align-items: center; justify-content: center; min-height: 48px;
  border: 1px solid var(--line-strong); border-radius: var(--radius-full); background: var(--surface-raised);
}
.for-choice input:checked + span { background: var(--action); color: var(--on-action); border-color: var(--action); }
.for-choice input:focus-visible + span { outline: 2px solid var(--focus); outline-offset: 2px; }
.field-error { color: var(--error); font-size: 13px; margin: 0; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.button {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 50px; padding: 0 var(--space-5);
  border: 0; border-radius: var(--radius-full);
  background: var(--action); color: var(--on-action);
  font: 500 15px/1 var(--sans); letter-spacing: 0.02em;
  text-decoration: none; cursor: pointer;
  transition: background-color 400ms ease-out; justify-self: start;
}
.blush-field .button { background: var(--plum); color: var(--on-night); }
.button:hover, .blush-field .button:hover { background: var(--action-hover); }
.blush-field .button:hover { background: #644c58; }
.button[disabled] { opacity: 0.6; cursor: progress; }

/* Thank you, as a postcard */
.thanks { padding: var(--space-5) 0; }
.thanks:focus { outline: none; }
.postcard {
  display: grid; grid-template-columns: 1fr; gap: var(--space-5);
  max-width: 760px; padding: var(--space-5);
  background: radial-gradient(120% 140% at 0% 0%, var(--lamplight) 0%, transparent 55%), var(--blush);
  color: #3b3633; --accent: var(--plum);
  border-radius: 8px; box-shadow: var(--shadow-lift); transform: rotate(-0.6deg);
}
@media (min-width: 640px) { .postcard { grid-template-columns: 1.4fr 1fr; } }
.postcard-message { display: grid; gap: var(--space-3); align-content: start; }
.postcard-side { display: grid; gap: var(--space-5); justify-items: end; align-content: start; }
.stamp {
  display: grid; place-items: center; width: 76px; height: 92px;
  background: var(--surface); border: 2px dashed var(--rosewood); border-radius: 4px;
}
.stamp .mark { width: 40px; height: 40px; }
.postcard-lines { display: grid; gap: 28px; width: 100%; }
.postcard-lines span { display: block; border-bottom: 1px solid var(--rosewood); }

/* The quiet hours */
.hours { max-width: 1120px; margin: 0 auto; padding: var(--space-6) 0; border-top: 1px solid var(--line); }
.hours-grid { display: grid; gap: var(--space-5); }
@media (min-width: 820px) { .hours-grid { grid-template-columns: repeat(3, 1fr); } }
.hour { display: grid; gap: var(--space-3); align-content: start; }
.motif { width: 28px; height: 28px; color: var(--rosewood); --mark-ink: var(--rosewood); --mark-fill: none; --mark-shadow: var(--rosewood); }

/* The details */
.details { max-width: 1120px; margin: 0 auto; padding: var(--space-6) 0 var(--space-7); display: grid; gap: var(--space-5); justify-items: start; border-top: 1px solid var(--line); }
.details-list { margin: 0; display: grid; gap: var(--space-4); width: 100%; }
@media (min-width: 820px) { .details-list { grid-template-columns: repeat(2, 1fr); gap: var(--space-5) var(--space-6); } }
.details-list div { display: grid; gap: var(--space-2); padding-top: var(--space-3); border-top: 1px solid var(--rosewood); }
.details-list dd { margin: 0; max-width: 46ch; }

.footer {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--space-3);
  padding: var(--space-5) var(--gutter);
  background: var(--plum); color: var(--on-night);
  --mark-ink: var(--on-night); --mark-fill: var(--butter); --mark-shadow: transparent;
}
.footer .lockup { gap: 10px; }
.footer .wordmark { height: 24.4px; }
.footer .mark { width: 24px; height: 24px; }
.footer a { color: var(--on-night); }
.footer p { margin: 0; }

/* Privacy page */
.prose { max-width: 65ch; margin: 0 auto; padding: var(--space-5) 0 var(--space-6); }
.prose h1 { margin-bottom: var(--space-4); }
.prose h2 { font-family: var(--display); font-weight: 380; font-variation-settings: "SOFT" 100; font-size: 24px; line-height: 1.25; margin: var(--space-5) 0 var(--space-2); }

/* Aubergine (operator, 2026-11-04): the brand's only palette. It overrides the
   base tokens above; brand colour sheet 01 in the life_lab repo. */

:root {
  --p-dark: #2b1b28; --p-second: #5b3550; --p-lamp: #e7c77a; --p-soft: #d49a92; --p-light: #f5ede4;
  --p-raised: #fcf8f3; --p-line: #e6d8d2; --p-muted: #5e4a58; --p-hover: #42283b; --p-lamp-hover: #eed596;
}

:root {
  --surface: var(--p-light);
  --surface-raised: var(--p-raised);
  --ink: var(--p-dark);
  --ink-muted: var(--p-muted);
  --line: var(--p-line);
  --line-strong: #9a6c66;  /* control borders: 3.9:1 on light */
  --rosewood: var(--p-soft);
  --plum: var(--p-dark);
  --accent: var(--p-second);
  --action: var(--p-dark);
  --on-action: var(--p-light);
  --action-hover: var(--p-hover);
  --focus: var(--p-dark);
  --on-night: var(--p-light);
  --mark-ink: var(--p-dark);
  --mark-fill: var(--p-lamp);
  --mark-shadow: var(--p-dark);
  color-scheme: light;
}
.display em, .headline em { color: var(--p-second); }

/* The night: notice bar, hero field and footer go dark, lit by the lamp. */
.notice { background: var(--p-second); color: var(--p-light); }
.blush-field {
  background:
    radial-gradient(70% 120% at 4% 0%, color-mix(in srgb, var(--p-lamp) 38%, transparent) 0%, transparent 60%),
    var(--p-dark);
  color: var(--p-light);
  --accent: var(--p-lamp);
  --mark-ink: var(--p-light); --mark-shadow: transparent;
}
.blush-field .muted { color: color-mix(in srgb, var(--p-light) 80%, transparent); }
.blush-field .display em { color: var(--p-lamp); }
.blush-field .button { background: var(--p-lamp); color: var(--p-dark); }
.blush-field .button:hover { background: var(--p-lamp-hover); }
.blush-field .hero-image img { box-shadow: 0 24px 50px -20px rgba(0, 0, 0, 0.7); }

.postcard {
  background: radial-gradient(120% 140% at 0% 0%, color-mix(in srgb, var(--p-lamp) 35%, transparent) 0%, transparent 55%), var(--p-dark);
  color: var(--p-light); --accent: var(--p-lamp);
}
.postcard .muted { color: color-mix(in srgb, var(--p-light) 80%, transparent); }
.stamp { background: var(--p-light); --mark-ink: var(--p-dark); --mark-shadow: var(--p-dark); }
.footer { background: var(--p-dark); --mark-fill: var(--p-lamp); }
.motif { --mark-fill: none; }


/* For the quiet hours: a second night band, full bleed. */
.hours {
  background: var(--p-dark);
  box-shadow: 0 0 0 100vmax var(--p-dark); clip-path: inset(0 -100vmax);
  color: var(--p-light); border-top: 0;
  --accent: var(--p-lamp); --ink-muted: color-mix(in srgb, var(--p-light) 80%, transparent);
}
.hours .motif { color: var(--p-lamp); --mark-ink: var(--p-lamp); --mark-shadow: var(--p-lamp); }
.hours + .details { border-top: 0; }
