/* Amira: link hub and newsletter.
   Layout: desktop = portrait pinned left, content column right. Phone = compact header row, links first.
   Colour: warm neutral paper and ink; one accent, amber (her eye colour), used for keywords and focus. */
:root {
  --bg: #f5f4f1;
  --surface: #ffffff;
  --ink: #1a1715;
  --muted: #69625c;
  --line: #e3dfd9;
  --accent: #9a5f12;
  --accent-wash: #f6ead6;
  --btn: #1a1715;
  --btn-ink: #ffffff;

  --f-display: "Bricolage Grotesque", "Helvetica Neue", Arial, sans-serif;
  --f-body: "Geist", "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --f-mono: "Geist Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;

  --s-1: 4px; --s-2: 8px; --s-3: 12px; --s-4: 16px; --s-5: 24px; --s-6: 32px; --s-7: 48px; --s-8: 72px;
  --r-sm: 10px; --r-md: 14px; --r-lg: 22px;
  --ease: cubic-bezier(.2, .7, .2, 1);
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #121110;
    --surface: #1b1917;
    --ink: #f1ede8;
    --muted: #a49c94;
    --line: #2d2925;
    --accent: #e3a54a;
    --accent-wash: #2a2117;
    --btn: #f1ede8;
    --btn-ink: #121110;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 16px/1.6 var(--f-body);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
.skip { position: absolute; left: -9999px; top: 8px; background: var(--btn); color: var(--btn-ink); padding: 8px 14px; border-radius: 8px; z-index: 10; }
.skip:focus { left: 16px; }

/* ---------- Frame ---------- */
.frame {
  max-width: 1180px; margin: 0 auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
  padding-block: var(--s-5) var(--s-7);
  display: grid; gap: var(--s-7);
}
@media (min-width: 960px) {
  .frame { grid-template-columns: minmax(0, 440px) minmax(0, 1fr); gap: 80px; padding-block: 56px 72px; padding-left: max(40px, env(safe-area-inset-left, 0px)); padding-right: max(40px, env(safe-area-inset-right, 0px)); }
  .frame.single { grid-template-columns: minmax(0, 720px); justify-content: center; padding-block: 72px 72px; }
}

/* Portrait: desktop only, pinned while the column scrolls */
.portrait { display: none; }
@media (min-width: 960px) {
  .portrait { display: block; position: sticky; top: 56px; align-self: start; }
  .portrait img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--r-lg); }
}

/* Phone identity row */
.who { display: flex; align-items: center; gap: var(--s-3); }
.who img { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; }
.who b { display: block; font-family: var(--f-display); font-size: 18px; font-weight: 600; letter-spacing: -.01em; line-height: 1.2; }
.who span { font-size: 13px; color: var(--muted); }

.col { display: grid; gap: var(--s-8); min-width: 0; align-content: start; }

/* ---------- Type ---------- */
h1, h2, h3 { font-family: var(--f-display); font-weight: 600; letter-spacing: -.025em; text-wrap: balance; margin: 0; }
h1 { font-size: clamp(36px, 6.4vw, 60px); line-height: 1.02; }
h2 { font-size: clamp(26px, 3.4vw, 34px); line-height: 1.1; }
h3 { font-size: 19px; line-height: 1.3; letter-spacing: -.01em; }
p { margin: 0; }
.lede { text-wrap: pretty; font-size: 18px; line-height: 1.55; color: var(--muted); max-width: 34em; }
.muted { color: var(--muted); }
.fine { font-size: 13px; line-height: 1.5; color: var(--muted); }
.mono { font-family: var(--f-mono); font-weight: 500; letter-spacing: .02em; }

/* ---------- Hero ---------- */
.hero { display: grid; gap: var(--s-5); }
.hero .who { margin-bottom: var(--s-2); }
.actions { display: flex; flex-wrap: wrap; gap: var(--s-3); margin-top: var(--s-2); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 50px; padding: 0 22px; border-radius: 999px;
  font: 600 15px/1 var(--f-body); text-decoration: none; cursor: pointer;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink);
  transition: transform .18s var(--ease), background-color .18s var(--ease), border-color .18s var(--ease);
}
.btn:hover { transform: translateY(-1px); border-color: var(--ink); }
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--btn); color: var(--btn-ink); border-color: var(--btn); }
.btn[disabled] { opacity: .45; cursor: not-allowed; transform: none; }
.btn .arr { transition: transform .18s var(--ease); }
.btn:hover .arr { transform: translateX(3px); }
@media (max-width: 520px) { .actions .btn { flex: 1 1 100%; } }

/* ---------- Section head ---------- */
.sec { display: grid; gap: var(--s-5); }
.sec-head { display: grid; gap: var(--s-2); }

/* How the DM works: a tiny comment-to-DM fragment */
.flow { font-size: 15px; line-height: 2; color: var(--muted); max-width: 40em; }
.flow .chip { display: inline-flex; margin: 0 4px; line-height: 1.4; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); }
.flow .chip .mono { color: var(--accent); }
.flow .caret { display: inline-block; width: 1px; height: 14px; background: var(--accent); margin-left: 1px; animation: blink 1.1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }

/* ---------- Reel list ---------- */
.reels { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.reels li { border-bottom: 1px solid var(--line); }
.reels a {
  display: grid; grid-template-columns: 92px minmax(0, 1fr) auto; align-items: baseline; gap: var(--s-4);
  padding: 20px 4px; text-decoration: none;
}
.reels .kw { color: var(--accent); font-size: 14px; }
.reels .t { font-weight: 500; font-size: 17px; line-height: 1.4; }
.reels .d { font-size: 13px; color: var(--muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.reels a .t { background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; transition: background-size .25s var(--ease); }
.reels a:hover .t { background-size: 100% 1px; }
@media (max-width: 520px) {
  .reels a { grid-template-columns: minmax(0, 1fr) auto; gap: 4px var(--s-3); }
  .reels .kw { grid-column: 1; }
  .reels .d { grid-column: 2; grid-row: 1; }
  .reels .t { grid-column: 1 / -1; }
}

/* ---------- Newsletter ---------- */
.letter { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: clamp(24px, 4vw, 40px); display: grid; gap: var(--s-4); }
.letter ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 6px; color: var(--muted); }
.letter li { padding-left: 20px; position: relative; }
.letter li::before { content: ""; position: absolute; left: 0; top: .72em; width: 8px; height: 2px; background: var(--accent); }
.signup { display: grid; gap: var(--s-2); margin-top: var(--s-2); }
.signup label { font-size: 14px; font-weight: 600; }
.signup .row { display: flex; flex-wrap: wrap; gap: var(--s-2); }
.signup input[type=email] {
  flex: 1 1 220px; min-width: 0; min-height: 50px; padding: 0 18px; font: 400 16px var(--f-body);
  border-radius: 999px; border: 1px solid var(--line); background: var(--bg); color: var(--ink);
}
.signup input[type=email]:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: transparent; }
.signup .btn { flex: 0 0 auto; }
@media (max-width: 520px) { .signup .btn { flex: 1 1 100%; } }
.hp { position: absolute; left: -9999px; }

/* ---------- Resource page ---------- */
.back { font-size: 14px; color: var(--muted); text-decoration: none; display: inline-flex; gap: 6px; }
.back:hover { color: var(--ink); }
.res { display: grid; gap: var(--s-5); }
.res .kwline { font-size: 14px; color: var(--muted); }
.res .kwline .mono { color: var(--accent); }
.crit { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.crit li { display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: var(--s-3); padding: 16px 0; border-bottom: 1px solid var(--line); font-size: 16px; }
.crit li::before { content: ""; width: 8px; height: 8px; margin-top: 9px; border-radius: 50%; background: var(--accent); }
.crit li { grid-template-columns: 20px minmax(0, 1fr); }
.crit-or { font-size: 13px; color: var(--muted); margin-top: calc(-1 * var(--s-2)); }

/* ---------- Footer ---------- */
footer { border-top: 1px solid var(--line); padding-top: var(--s-5); display: grid; gap: var(--s-3); }
footer nav { display: flex; flex-wrap: wrap; gap: var(--s-2) var(--s-5); font-size: 14px; }
footer nav a { text-decoration: none; color: var(--muted); padding: 6px 0; }
footer nav a:hover { color: var(--ink); }

/* ---------- Entrance: hero only, once ---------- */
@media (prefers-reduced-motion: no-preference) {
  .enter > * { animation: rise .7s var(--ease) both; }
  .enter > *:nth-child(2) { animation-delay: .06s; }
  .enter > *:nth-child(3) { animation-delay: .12s; }
  .enter > *:nth-child(4) { animation-delay: .18s; }
  .portrait img { animation: settle 1s var(--ease) both; }
  @keyframes rise { from { opacity: 0; transform: translateY(10px); } }
  @keyframes settle { from { opacity: 0; transform: scale(1.015); } }
}
@media (prefers-reduced-motion: reduce) {
  .flow .caret { animation: none; }
  * { transition: none !important; }
}
