/* Haggai Voice Tooling — feedback tool styles.
   Built on tokens.css (brand palette, Montserrat/Roboto, 4px radii, gold accents).
   Extends the v1 review tool: per-block cards, schematic previews, sticky bars. */

* { box-sizing: border-box; }
body { margin: 0; background: var(--hi-paper); color: var(--fg-body);
  font-family: var(--font-body); line-height: var(--lh-base); font-size: var(--fs-base); }
.wrap { max-width: 940px; margin: 0 auto; padding: 0 24px; }
[hidden] { display: none !important; }

/* ---------- header ---------- */
.top { background: var(--hi-dark-blue); color: #fff; padding: 34px 0 30px; }
.top .wrap { display: flex; flex-direction: column; gap: 16px; }
.top img.logo { height: 30px; width: auto; align-self: flex-start; } /* flex column stretches children by default — keep the logo at its own aspect ratio */
.top .eyebrow { color: var(--hi-gold); margin: 0; }
.top h1 { color: #fff; font-size: var(--fs-2xl); font-weight: 800; letter-spacing: -.01em; line-height: 1.12; margin: 0; }
.top p { color: rgba(255,255,255,.82); max-width: 62ch; margin: 6px 0 0; }

/* ---------- how-it-works ---------- */
.how { background: var(--hi-light-blue); border-bottom: 1px solid var(--border); }
.how .wrap { padding: 20px 24px; }
.how h2 { font-size: var(--fs-sm); letter-spacing: var(--tracking-caps-lg); text-transform: uppercase; color: var(--hi-dark-blue); margin: 0 0 10px; }
.how ol { margin: 0; padding-left: 20px; display: grid; gap: 5px; }
.how li { font-size: 14.5px; }
.how b { color: var(--hi-dark-blue); }

/* ---------- identity gate (first screen) ---------- */
.gate { min-height: 46vh; display: flex; align-items: center; justify-content: center; padding: 48px 24px; }
.gate .card { background: #fff; border: 1px solid var(--border); border-top: 5px solid var(--hi-gold);
  border-radius: var(--r-lg); max-width: 480px; width: 100%; padding: 30px; box-shadow: var(--shadow-2); }
.gate h2 { font-size: var(--fs-xl); margin: 0 0 8px; }
.gate p { font-size: 14.5px; color: var(--fg-muted); margin: 0 0 18px; }
.gate label { font-family: var(--font-display); font-weight: 700; font-size: var(--fs-xs);
  letter-spacing: var(--tracking-caps-lg); text-transform: uppercase; color: var(--fg-muted); display: block; margin: 0 0 6px; }
.field-input { font-family: var(--font-body); font-size: 15px; padding: 11px 13px; border: 1px solid var(--border);
  border-radius: var(--r-md); width: 100%; background: var(--hi-paper); }
.field-input:focus { outline: 2px solid var(--hi-medium-blue); outline-offset: 1px; }
.gate .row { display: flex; gap: 10px; margin-top: 14px; flex-wrap: wrap; }
.gate .hint { font-size: 12.5px; color: var(--fg-subtle); margin: 12px 0 0; }

/* ---------- sticky reviewer bar ---------- */
.who { background: #fff; border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 30; box-shadow: var(--shadow-1); }
.who .wrap { display: flex; gap: 12px; align-items: center; padding: 11px 24px; flex-wrap: wrap; }
.who .id { font-family: var(--font-display); font-weight: 700; color: var(--hi-dark-blue); font-size: 14px; }
.who .id small { display: block; font-weight: 400; color: var(--fg-muted); font-size: 12px; letter-spacing: .02em; }
.who .status { margin-left: auto; font-size: 12.5px; color: var(--fg-muted); }
.who .status b { color: var(--status-success); }
.who .switch { background: none; border: 0; color: var(--hi-medium-blue); font-size: 12.5px; cursor: pointer; }

main { padding: 30px 0 150px; }
.blockhead { font-size: var(--fs-xl); font-weight: 800; color: var(--hi-dark-blue);
  border-bottom: 3px solid var(--hi-gold); padding-bottom: 8px; margin: 40px 0 20px; }
.blockhead:first-child { margin-top: 0; }

/* ---------- item card ---------- */
.item { background: #fff; border: 1px solid var(--border); border-radius: var(--r-lg); padding: 20px 22px; margin: 0 0 18px; }
.ihead { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; }
.ihead > div:first-child { min-width: 0; }
.item .code { font-family: var(--font-display); font-weight: 700; font-size: var(--fs-xs); letter-spacing: var(--tracking-caps-lg); text-transform: uppercase; color: #C99A2E; }
.item .name { font-family: var(--font-display); font-weight: 700; color: var(--hi-dark-blue); font-size: var(--fs-md); margin: 2px 0 0; }
.thumb { flex: none; width: 132px; height: 84px; border: 1px solid var(--border); border-radius: var(--r-md); overflow: hidden; background: var(--hi-paper); }
.thumb svg { display: block; width: 100%; height: 100%; }
.oq { margin-top: 8px; font-size: 13px; color: var(--fg-muted); background: var(--hi-paper); border-left: 3px solid var(--hi-gold); padding: 8px 12px; border-radius: 0 var(--r-md) var(--r-md) 0; }

/* ---------- editable fields ---------- */
.fields { margin: 14px 0 6px; display: grid; gap: 12px; }
.field { }
.field .lbl { font-family: var(--font-display); font-weight: 700; color: var(--hi-dark-blue); font-size: 12.5px; letter-spacing: .02em; display: block; margin: 0 0 5px; }
.field .lbl:empty { display: none; }
.field-edit { width: 100%; font-family: var(--font-body); font-size: 15px; line-height: 1.55; color: var(--fg-body);
  padding: 11px 13px; border: 1px solid var(--border); border-radius: var(--r-md); background: var(--hi-paper); resize: none; overflow: hidden; display: block; }
.field-edit.big { font-family: var(--font-display); font-weight: 700; color: var(--hi-dark-blue); font-size: 18px; line-height: 1.28; }
.field-edit.eyebrow, .field-edit.meta { font-size: 13px; color: var(--fg-muted); }
.field-edit:focus { outline: 2px solid var(--hi-medium-blue); outline-offset: 1px; background: #fff; }
.field-edit.dirty { border-color: var(--hi-gold); background: #fff; }
.field-edit.tuning { opacity: .6; background: linear-gradient(100deg, var(--hi-paper) 30%, var(--hi-light-blue) 50%, var(--hi-paper) 70%);
  background-size: 220% 100%; animation: shimmer 1.1s var(--ease-in-out) infinite; pointer-events: none; }
@keyframes shimmer { from { background-position: 180% 0; } to { background-position: -80% 0; } }
.field .orig { display: none; font-size: 13.5px; color: var(--fg-muted); background: #fff; border: 1px dashed var(--border);
  border-radius: var(--r-md); padding: 8px 12px; margin-top: 6px; }
.field .orig.show { display: block; }
.field .orig b { color: var(--fg-subtle); font-family: var(--font-display); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; display: block; margin-bottom: 3px; }

/* ---------- inline AI exchange panel (diff) ---------- */
.exchange { margin-top: 8px; border: 1px solid var(--hi-medium-blue-tint); border-radius: var(--r-md); background: var(--hi-light-blue-50); padding: 12px 14px; }
.exchange .diff { font-size: 15px; line-height: 1.55; color: var(--fg-body); }
.exchange .diff ins { text-decoration: underline; text-decoration-color: var(--hi-gold); text-decoration-thickness: 2px; text-underline-offset: 2px; background: rgba(255,201,92,.18); }
.exchange .diff del { text-decoration: line-through; color: var(--hi-taupe); opacity: .7; }
.exchange .ask { font-size: 12px; color: var(--fg-muted); margin: 0 0 6px; }
.exchange .ask b { color: var(--hi-dark-blue); }
.exchange .row { display: flex; gap: 8px; margin-top: 10px; align-items: center; flex-wrap: wrap; }
.exchange .prompt { flex: 1; min-width: 180px; }

/* ---------- verdict row ---------- */
.verdicts { display: flex; gap: 8px; flex-wrap: wrap; margin: 14px 0 4px; align-items: center; }
.verdicts .vlabel { font-family: var(--font-display); font-weight: 700; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--fg-muted); margin-right: 2px; }
button.v { font-family: var(--font-display); font-weight: 600; font-size: 12.5px; letter-spacing: .06em; text-transform: uppercase;
  padding: 8px 14px; border: 1px solid var(--border); border-radius: var(--r-md); background: #fff; color: var(--hi-dark-blue); cursor: pointer; transition: .15s; }
button.v:hover { border-color: var(--hi-dark-blue); }
button.v[aria-pressed="true"][data-v="love"] { background: var(--status-success); border-color: var(--status-success); color: #fff; }
button.v[aria-pressed="true"][data-v="needs"] { background: var(--hi-gold); border-color: var(--hi-gold); color: var(--hi-taupe); }
button.v[aria-pressed="true"][data-v="never"] { background: var(--status-error); border-color: var(--status-error); color: #fff; }
.compare-toggle { margin-left: auto; background: none; border: 0; color: var(--hi-medium-blue); font-size: 12.5px; cursor: pointer; }

/* per-block reason box (for a love / needs-work / never verdict) */
.whybox { margin-top: 10px; display: none; }
.whybox.show { display: block; }
.whyhead { display: flex; align-items: center; justify-content: space-between; margin-bottom: 4px; }
.whylabel { font-family: var(--font-display); font-weight: 700; color: var(--hi-dark-blue); font-size: 12.5px; }
.whyclose { background: none; border: 0; color: var(--fg-muted); font-size: 20px; line-height: 1; cursor: pointer; padding: 0 5px; border-radius: var(--r-sm); }
.whyclose:hover { color: var(--hi-dark-blue); background: var(--hi-stone-100); }
.whydone { display: none; background: transparent; border: 1px dashed var(--border); color: var(--fg-muted);
  font-family: var(--font-display); font-size: 12px; font-weight: 600; padding: 6px 11px; border-radius: var(--r-md); cursor: pointer; }
.whydone:hover { border-color: var(--hi-medium-blue-tint); color: var(--hi-dark-blue); }
.whybox.collapsed .whyhead, .whybox.collapsed .whyinput { display: none; }
.whybox.collapsed .whydone { display: inline-block; }

/* ---------- per-block feedback log ---------- */
.fblog { display: none; margin-top: 12px; border-top: 1px dashed var(--border); padding-top: 10px; }
.fblog.show { display: block; }
.fbhead { font-family: var(--font-display); font-weight: 700; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--fg-muted); margin-bottom: 7px; }
.fbentry { border: 1px solid var(--border); border-radius: var(--r-md); background: var(--hi-paper); margin-bottom: 6px; overflow: hidden; }
.fbrow { display: flex; align-items: center; }
.fbsum { flex: 1; display: flex; align-items: center; gap: 8px; min-width: 0; text-align: left; background: none; border: 0; cursor: pointer; padding: 8px 10px; font-family: var(--font-body); }
.fbtag { flex: none; font-family: var(--font-display); font-weight: 700; font-size: 11px; padding: 2px 8px; border-radius: var(--r-pill); border: 1px solid var(--border); }
.fbtag.love { color: var(--hi-dark-blue); border-color: var(--hi-gold); background: rgba(255,201,92,.18); }
.fbtag.needs { color: var(--hi-taupe); }
.fbtag.never { color: var(--status-error, #b23b3b); border-color: var(--status-error, #b23b3b); }
.fbtag.ai { color: var(--hi-medium-blue, #3B82BD); border-color: var(--hi-medium-blue-tint); }
.fbprev { font-size: 13px; color: var(--fg-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fbdel { flex: none; background: none; border: 0; color: var(--fg-muted); font-size: 18px; line-height: 1; cursor: pointer; padding: 6px 11px; border-left: 1px solid var(--border); }
.fbdel:hover { color: var(--status-error, #b23b3b); background: var(--hi-stone-100); }
.fbdetail { display: none; padding: 0 12px 11px; }
.fbentry.open .fbdetail { display: block; }
.fbentry.open .fbsum .fbprev { white-space: normal; }
.fbi { font-size: 13.5px; color: var(--fg-body); margin: 2px 0; }
.fbr { font-size: 13px; color: var(--fg-muted); margin: 4px 0 0; }
.fbdetail .diff { font-size: 14px; line-height: 1.5; margin-top: 4px; }
.fbdetail .diff ins { text-decoration: underline; text-decoration-color: var(--hi-gold); text-decoration-thickness: 2px; text-underline-offset: 2px; background: rgba(255,201,92,.18); }
.fbdetail .diff del { text-decoration: line-through; color: var(--hi-taupe); opacity: .7; }

/* ---------- calibration game ---------- */
.gamewrap { padding: 26px 0 140px; } /* bottom clearance so the card + Back/Next row scroll clear of the fixed submit bar */
.gameprog { margin: 0 0 18px; }
.gamebar { height: 7px; background: var(--hi-stone-100); border-radius: var(--r-pill); overflow: hidden; }
.gamebar span { display: block; height: 100%; width: 0; background: var(--hi-gold); border-radius: var(--r-pill); transition: width .3s ease; }
.gameprog p { margin: 7px 0 0; font-size: 13px; color: var(--fg-muted); }
.gamecard { background: #fff; border: 1px solid var(--border); border-top: 4px solid var(--hi-gold); border-radius: var(--r-lg); padding: 30px 30px 26px; box-shadow: var(--shadow-1); }
.gamekicker { font-family: var(--font-display); font-weight: 700; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--fg-muted); margin: 0 0 14px; }
.gametext { font-family: var(--font-display); font-weight: 600; color: var(--hi-dark-blue); font-size: 25px; line-height: 1.35; margin: 0 0 24px; border: 0; padding: 0; }
@media (max-width: 640px) { .gametext { font-size: 21px; } .gamecard { padding: 22px 20px; } }

.verdictscale { display: flex; gap: 8px; margin: 0 0 22px; }
.vs { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 5px; padding: 12px 6px; border: 1px solid var(--border); border-radius: var(--r-md); background: #fff; color: var(--hi-dark-blue); font-family: var(--font-display); font-weight: 700; font-size: 13.5px; cursor: pointer; transition: .15s; }
.vs:hover { border-color: var(--hi-medium-blue-tint); }
.vsnum { display: inline-flex; align-items: center; justify-content: center; width: 20px; height: 20px; border-radius: 50%; background: var(--hi-stone-100); color: var(--fg-muted); font-size: 11px; font-weight: 700; }
.vs[aria-pressed="true"] { color: #fff; border-color: transparent; }
.vs[aria-pressed="true"] .vsnum { background: rgba(255,255,255,.3); color: #fff; }
.vs-love[aria-pressed="true"] { background: var(--hi-gold); color: var(--hi-taupe); }
.vs-love[aria-pressed="true"] .vsnum { color: var(--hi-taupe); }
.vs-like[aria-pressed="true"] { background: var(--hi-medium-blue); }
.vs-neutral[aria-pressed="true"] { background: var(--hi-taupe); }
.vs-dislike[aria-pressed="true"] { background: var(--hi-medium-blue-tint); color: var(--hi-dark-blue); }
.vs-never[aria-pressed="true"] { background: var(--status-error); }
@media (max-width: 640px) { .verdictscale { flex-wrap: wrap; } .vs { flex: 1 1 30%; } }

.feelq { font-family: var(--font-display); font-weight: 700; font-size: 12.5px; color: var(--hi-dark-blue); margin: 0 0 8px; }
.feelrow { display: flex; flex-wrap: wrap; gap: 7px; }
.feel { padding: 6px 13px; border: 1px solid var(--border); border-radius: var(--r-pill); background: #fff; color: var(--fg-muted); font-size: 13px; cursor: pointer; transition: .15s; }
.feel:hover { border-color: var(--hi-medium-blue-tint); color: var(--hi-dark-blue); }
.feel[aria-pressed="true"] { background: var(--hi-light-blue); border-color: var(--hi-medium-blue-tint); color: var(--hi-dark-blue); font-weight: 600; }

.gamenav { display: flex; align-items: center; gap: 10px; margin-top: 18px; }
.gamenav .gback { background: transparent; border: 1px solid var(--border); color: var(--fg-muted); }
.gamenav .gskip { background: transparent; border: 1px dashed var(--border); color: var(--fg-muted); margin-left: auto; }
.gamenav #gnext { }
.gamenav button:disabled { opacity: .4; cursor: default; }

/* gate: calibration step label + skip link (soft gate on the review tools) */
.gate .card .step { display: block; font-family: var(--font-display); font-weight: 700; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: #C99A2E; margin-bottom: 6px; }
.linklike { background: none; border: 0; color: var(--fg-muted); text-decoration: underline; cursor: pointer; font-size: 13px; margin-top: 12px; padding: 4px 0; font-family: var(--font-body); }
.linklike:hover { color: var(--hi-dark-blue); }

/* live-preview button — sits on the navy header + navy submit bar (homepage only) */
.prevbtn { display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-display); font-weight: 700;
  font-size: 12.5px; letter-spacing: .01em; color: var(--hi-gold); background: transparent; border: 1px solid var(--hi-gold);
  padding: 8px 14px; border-radius: var(--r-md); text-decoration: none; cursor: pointer; transition: .15s; }
.prevbtn:hover { background: var(--hi-gold); color: var(--hi-taupe); text-decoration: none; }
.top .prevbtn { align-self: flex-start; margin-top: 2px; }
.submitbar .prevbtn { padding: 7px 13px; font-size: 12px; }

/* ---------- flashcard review cards (homepage + loved, via cards.js) ---------- */
.rcard { background: #fff; border: 1px solid var(--border); border-top: 4px solid var(--hi-gold); border-radius: var(--r-lg); padding: 24px 26px 22px; box-shadow: var(--shadow-1); }
.rchead { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
.rchead > div:first-child { min-width: 0; }
.rchead .code { font-family: var(--font-display); font-weight: 700; font-size: var(--fs-xs); letter-spacing: var(--tracking-caps-lg); text-transform: uppercase; color: #C99A2E; }
.rchead .name { font-family: var(--font-display); font-weight: 700; color: var(--hi-dark-blue); font-size: var(--fs-md); margin: 2px 0 0; }
.rcbody { margin: 0 0 20px; }
.rcf { margin: 0 0 9px; color: var(--fg-body); line-height: 1.5; }
.rcf:last-child { margin-bottom: 0; }
.rcf-big { font-family: var(--font-display); font-weight: 700; color: var(--hi-dark-blue); font-size: 22px; line-height: 1.25; }
.rcf-eyebrow { font-family: var(--font-display); font-weight: 700; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--hi-taupe); }
.rcf-meta { font-size: 13px; color: var(--fg-muted); }
.rcloved { font-family: var(--font-display); font-weight: 600; color: var(--hi-dark-blue); font-size: 22px; line-height: 1.35; margin: 0 0 8px; border: 0; padding: 0; }
.rcsrc { font-size: 12.5px; color: var(--fg-muted); margin: 0 0 4px; }
.rckicker { font-family: var(--font-display); font-weight: 700; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--fg-muted); margin: 0 0 10px; }
.worktoggle { margin-top: 18px; background: transparent; border: 1px dashed var(--border); color: var(--hi-dark-blue); font-family: var(--font-display); font-weight: 700; font-size: 13px; padding: 9px 15px; border-radius: var(--r-md); cursor: pointer; transition: .15s; }
.worktoggle:hover { border-color: var(--hi-medium-blue-tint); }
.cardeditor { margin-top: 14px; border-top: 1px dashed var(--border); padding-top: 14px; }
.cardeditor .editorhint { font-size: 12.5px; color: var(--fg-muted); margin: 0 0 12px; }
@media (max-width: 640px) { .rcard { padding: 20px; } .rcf-big, .rcloved { font-size: 19px; } .rchead .thumb { display: none; } }
.hubfoot { color: var(--fg-muted); font-size: 13px; text-align: center; margin: 0 auto 60px; }
.hubfoot a { color: var(--hi-medium-blue); }

/* ---------- selection toolbar (select-to-prompt) ---------- */
#seltool { position: absolute; z-index: 60; display: none; background: var(--hi-dark-blue); border-radius: var(--r-md);
  box-shadow: var(--shadow-3); padding: 10px; width: 300px; }
#seltool .presets { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
#seltool .presets button, #seltool .vrow button { font-family: var(--font-display); font-weight: 600; font-size: 11.5px;
  padding: 6px 9px; border: 0; border-radius: var(--r-sm); background: rgba(255,255,255,.14); color: #fff; cursor: pointer; }
#seltool .presets button:hover, #seltool .vrow button:hover { background: rgba(255,255,255,.26); }
#seltool .vrow { display: flex; gap: 6px; margin-bottom: 8px; }
#seltool .vrow button.love { background: var(--status-success); }
#seltool .vrow button.needs { background: var(--hi-gold); color: var(--hi-taupe); }
#seltool .vrow button.never { background: var(--status-error); }
#seltool textarea { width: 100%; min-height: 44px; border: 0; border-radius: var(--r-sm); padding: 8px; font-family: var(--font-body); font-size: 13.5px; resize: vertical; }
#seltool .go { margin-top: 7px; width: 100%; background: var(--hi-gold); color: var(--hi-taupe); font-weight: 700; padding: 8px; border: 0; border-radius: var(--r-sm); cursor: pointer;
  font-family: var(--font-display); letter-spacing: .06em; text-transform: uppercase; font-size: 12px; }
#seltool .sel { color: rgba(255,255,255,.7); font-size: 11px; margin: 0 0 6px; max-height: 34px; overflow: hidden; }

/* ---------- buttons ---------- */
.btn { font-family: var(--font-display); font-weight: 700; font-size: 13px; letter-spacing: .1em; text-transform: uppercase;
  padding: 11px 18px; border-radius: var(--r-md); border: 1px solid transparent; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; gap: 8px; }
.btn:disabled { opacity: .5; cursor: default; }
.btn-gold { background: var(--hi-gold); color: var(--hi-taupe); } .btn-gold:hover:not(:disabled) { filter: brightness(1.04); }
.btn-ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,.5); } .btn-ghost:hover { background: rgba(255,255,255,.1); }
.btn-navy { background: var(--hi-dark-blue); color: #fff; } .btn-navy:hover:not(:disabled) { background: var(--hi-dark-blue-90); }
.btn-sm { font-size: 11.5px; padding: 8px 12px; }

/* ---------- sticky submit bar ---------- */
.submitbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; background: var(--hi-dark-blue); color: #fff; box-shadow: 0 -4px 20px rgba(0,0,0,.18); }
.submitbar .wrap { display: flex; gap: 16px; align-items: center; padding: 13px 24px; flex-wrap: wrap; }
.submitbar .msg { font-size: 13.5px; color: rgba(255,255,255,.85); }
.submitbar .msg b { color: var(--hi-gold); }
.submitbar .spacer { flex: 1; }

/* ---------- toast ---------- */
#toast { position: fixed; bottom: 74px; left: 50%; transform: translateX(-50%) translateY(20px); z-index: 70;
  background: var(--hi-dark-blue); color: #fff; padding: 10px 18px; border-radius: var(--r-md); font-size: 13.5px; box-shadow: var(--shadow-3);
  opacity: 0; transition: .25s var(--ease-out); pointer-events: none; }
#toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
#toast b { color: var(--hi-gold); }

/* ---------- modal ---------- */
#modal { position: fixed; inset: 0; z-index: 80; background: rgba(15,28,48,.6); display: none; align-items: center; justify-content: center; padding: 24px; }
#modal.show { display: flex; }
#modal .card { background: #fff; border-radius: var(--r-lg); max-width: 540px; width: 100%; padding: 30px; border-top: 5px solid var(--hi-gold); }
#modal h3 { font-size: var(--fs-xl); margin: 0 0 6px; }
#modal p { font-size: 14.5px; margin: 0 0 14px; }
#modal ol { margin: 0 0 18px; padding-left: 20px; display: grid; gap: 8px; font-size: 14.5px; }

@media (max-width: 640px) {
  .top h1 { font-size: 24px; }
  .thumb { width: 96px; height: 62px; }
  .submitbar .msg { display: none; }
  .ihead { flex-direction: column-reverse; align-items: stretch; }
  .thumb { width: 100%; height: 74px; }
}

/* ---------- loved-copy page ---------- */
.lovedline { font-family: var(--font-display); font-weight: 700; color: var(--hi-dark-blue); font-size: 20px; line-height: 1.3;
  margin: 0; padding: 4px 0 4px 16px; border-left: 3px solid var(--hi-gold); }
.lovedsrc { font-size: 12.5px; color: var(--fg-muted); margin: 8px 0 12px 16px; }
.lovedsrc .code { color: #C99A2E; font-family: var(--font-display); font-weight: 700; letter-spacing: .1em; }
.taglist { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 10px; }
.tag { font-family: var(--font-display); font-weight: 600; font-size: 12px; letter-spacing: .04em; text-transform: capitalize;
  padding: 6px 12px; border: 1px solid var(--border); border-radius: var(--r-pill); background: #fff; color: var(--fg-muted); cursor: pointer; transition: .15s; }
.tag:hover { border-color: var(--hi-dark-blue); }
.tag[aria-pressed="true"] { background: var(--hi-light-blue); border-color: var(--hi-medium-blue-tint); color: var(--hi-dark-blue); }

/* ---------- cross-task nav (in the navy header) ---------- */
.tasknav { display: flex; flex-wrap: wrap; gap: 4px 14px; align-items: center; margin-top: 6px;
  font-family: var(--font-display); font-size: 12.5px; font-weight: 600; }
.tasknav a { color: rgba(255,255,255,.72); text-decoration: none; padding: 2px 0; border-bottom: 2px solid transparent; }
.tasknav a:hover { color: #fff; }
.tasknav .cur { color: var(--hi-gold); border-bottom: 2px solid var(--hi-gold); padding: 2px 0; }
.tasknav .all { color: rgba(255,255,255,.5); }
.tasknav .all::after { content: "·"; margin-left: 14px; color: rgba(255,255,255,.35); }

/* ---------- next-up row (completion modal) ---------- */
.nextlabel { font-size: 14px; margin: 16px 0 8px; }
.nextrow { display: flex; flex-wrap: wrap; gap: 8px; }
.nextrow .allx { background: transparent; border: 1px solid var(--border); color: var(--fg-muted); }

/* ---------- hub landing ---------- */
.hub { padding: 34px 0 80px; display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.hubcard { display: flex; flex-direction: column; gap: 5px; background: #fff; border: 1px solid var(--border);
  border-top: 4px solid var(--border); border-radius: var(--r-lg); padding: 20px 22px; text-decoration: none;
  transition: .15s var(--ease-out); box-shadow: var(--shadow-1); }
.hubcard:hover { border-top-color: var(--hi-gold); box-shadow: var(--shadow-2); transform: translateY(-2px); }
.hubcard.start { border-top-color: var(--hi-gold); }
.hubcard .step { font-family: var(--font-display); font-weight: 700; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--hi-taupe); }
.hubcard.start .step { color: #C99A2E; }
.hubcard h2 { font-size: var(--fs-lg); margin: 2px 0; color: var(--hi-dark-blue); }
.hubcard p { font-size: 14px; color: var(--fg-body); margin: 0; line-height: 1.5; flex: 1; }
.hubcard .go { font-family: var(--font-display); font-weight: 700; font-size: 13px; letter-spacing: .06em; color: var(--hi-medium-blue); margin-top: 8px; }
