/* intake.css — the shared donor intake panel.
   Everything is scoped under #llfIntake so it cannot leak into the rest of the
   page, and so /give's own .tier/.t/.f/.check rules stay untouched in phase 2. */

#llfIntake{
  --i-text:#F5F1E6; --i-muted:#9D978A;
  --i-gold:#E6B450; --i-gold-deep:#A87B26; --i-gold-bright:#F7CE6E;
  --i-red:#FF4034;
  --i-line:rgba(230,180,80,.16); --i-line-soft:rgba(245,241,232,.08);
  display:none; font-family:'Hanken Grotesk',system-ui,sans-serif; color:var(--i-text);
  margin-top:16px; padding-top:16px; border-top:1px solid var(--i-line-soft);
}
#llfIntake.open{display:block; animation:lliIn .35s cubic-bezier(.2,.7,.3,1)}
@keyframes lliIn{from{opacity:0;transform:translateY(-8px)}to{opacity:1;transform:none}}
@media (prefers-reduced-motion:reduce){#llfIntake.open{animation:none}}
#llfIntake *{box-sizing:border-box}

/* amount */
#llfIntake .lli-tiers{display:grid;grid-template-columns:1fr 1fr;gap:9px}
#llfIntake .lli-tier{
  position:relative;display:block;border:1px solid var(--i-line-soft);border-radius:12px;
  padding:12px 12px;cursor:pointer;background:rgba(0,0,0,.22);
  transition:border-color .15s,background .15s;
}
#llfIntake .lli-tier:hover{border-color:var(--i-gold-deep)}
#llfIntake .lli-tier input[type=radio]{position:absolute;opacity:0;width:0;height:0}
#llfIntake .lli-amt{font-family:'Anton',Impact,sans-serif;font-size:25px;line-height:1;color:var(--i-text)}
#llfIntake .lli-cap{display:block;font-size:11.5px;color:var(--i-muted);margin-top:4px;line-height:1.3}
#llfIntake .lli-tier:has(input:checked){
  border-color:var(--i-gold);
  background:linear-gradient(180deg,rgba(230,180,80,.12),rgba(230,180,80,.03));
}
#llfIntake .lli-tier:has(input:checked) .lli-amt{color:var(--i-gold-bright)}
#llfIntake .lli-tier:has(input:focus-visible){outline:2px solid var(--i-gold-bright);outline-offset:2px}
#llfIntake .lli-other{margin-top:9px}
#llfIntake .lli-oin{display:none;align-items:center;gap:8px;margin-top:9px}
#llfIntake .lli-other.on .lli-oin{display:flex}
#llfIntake .lli-oin b{color:var(--i-gold-bright);font-family:'Anton',Impact,sans-serif;font-size:20px}

/* fields */
#llfIntake .lli-f{
  display:block;font-family:'Archivo',system-ui,sans-serif;font-weight:500;font-size:10.5px;
  letter-spacing:.1em;text-transform:uppercase;color:var(--i-muted);margin:13px 0 5px;
}
#llfIntake .lli-opt{text-transform:none;letter-spacing:0;opacity:.75}
#llfIntake .lli-t{
  width:100%;background:rgba(0,0,0,.3);border:1px solid var(--i-line-soft);color:var(--i-text);
  border-radius:10px;padding:11px 12px;font-family:'Hanken Grotesk',system-ui,sans-serif;font-size:16px;
}
#llfIntake .lli-t:focus{outline:2px solid var(--i-gold);outline-offset:1px;border-color:var(--i-gold)}
#llfIntake .lli-t.bad{border-color:var(--i-red)}

/* checkboxes */
#llfIntake .lli-check{
  display:flex;gap:10px;align-items:flex-start;margin:13px 0;
  border:1px solid var(--i-line-soft);border-radius:12px;padding:12px;transition:opacity .15s;
}
#llfIntake .lli-check input{width:19px;height:19px;flex:0 0 19px;margin-top:1px;accent-color:var(--i-gold)}
#llfIntake .lli-check span{font-size:13px;line-height:1.4}
#llfIntake .lli-check span b{display:block;font-family:'Archivo',system-ui,sans-serif;font-weight:700;font-size:13.5px;margin-bottom:2px}
#llfIntake .lli-check span i{display:block;font-style:normal;color:var(--i-muted);font-size:11.5px;margin-top:3px}
#llfIntake #lliGiftBox{border-color:var(--i-line);background:rgba(230,180,80,.04)}
#llfIntake #lliGiftBox.off{opacity:.4;pointer-events:none}

/* status + submit */
#llfIntake .lli-status{margin:11px 0 0;font-size:13.5px;min-height:0}
#llfIntake .lli-status.is-err{
  padding:11px 13px;border-radius:10px;background:rgba(255,64,52,.12);
  border:1px solid var(--i-red);color:#ffd9d6;
}
#llfIntake .lli-status.is-ok{
  padding:11px 13px;border-radius:10px;background:rgba(230,180,80,.12);
  border:1px solid var(--i-gold);color:var(--i-text);
}
#llfIntake .lli-go{
  display:block;width:100%;margin-top:14px;padding:14px 18px;border-radius:12px;cursor:pointer;
  background:var(--i-gold);color:#1a1405;border:1px solid var(--i-gold);
  font-family:'Archivo',system-ui,sans-serif;font-weight:700;font-size:16px;
  transition:background .15s,opacity .2s;
}
#llfIntake .lli-go:hover:not(:disabled){background:var(--i-gold-bright)}
#llfIntake .lli-go:focus-visible{outline:2px solid var(--i-gold-bright);outline-offset:3px}
#llfIntake .lli-go:disabled{opacity:.5;cursor:not-allowed}

/* the chosen rail, once the panel is open */
.herocard .donopt.chosen{
  border-color:var(--gold);
  background:linear-gradient(180deg,rgba(230,180,80,.14),rgba(230,180,80,.03));
}
.herocard .donopt.chosen .arr{transform:rotate(90deg);display:inline-block}

/* ---------------------------------------------------------------------------
   The pop-out. Each rail opens its own titled dialog rather than one accordion
   sliding open under all four (Dawn, 2026-09-01).

   Why a <dialog> and not a positioned overlay: .herocard carries an inline
   transform — tail.html's .anim loader sets transform:translateY(0) and leaves
   it there — which makes a containing block, so position:fixed inside the card
   is pinned to the card. section.hero then clips it with overflow:hidden.
   showModal() renders in the TOP LAYER, which is outside both, and above the
   sticky header (z:50) and the cookie banner (z:80) without a z-index at all.
   Verified in the live page before this was written.

   :not([open]) is load-bearing. A browser with no <dialog> support gives the
   element no UA display:none, so without this the whole form would sit open in
   the card forever. With it, such a browser falls back to the inline panel.

   inset:0 + margin:auto is also load-bearing: styles.css opens with
   *{margin:0} which kills the UA stylesheet's margin:auto on a modal dialog,
   and the pop-out would pin to the top-left corner of the window.
--------------------------------------------------------------------------- */
#llfIntakeModal{
  --i-gold:#E6B450; --i-line:rgba(230,180,80,.16);
  inset:0; margin:auto;                       /* NOT inherited — see above */
  width:min(430px,92vw); max-height:min(88dvh,880px);
  padding:0; overflow:auto; overscroll-behavior:contain;
  background:#16150F; color:#F5F1E6;
  border:1px solid rgba(230,180,80,.30); border-radius:18px;
  box-shadow:0 30px 90px rgba(0,0,0,.72);
}
#llfIntakeModal:not([open]){display:none}
#llfIntakeModal::backdrop{background:rgba(8,7,4,.72)}
html:has(#llfIntakeModal[open]){overflow:hidden}

#llfIntakeModal .lli-head{
  position:sticky; top:0; z-index:2; display:flex; align-items:center; gap:11px;
  padding:15px 18px 13px; background:linear-gradient(180deg,#221F15,#16150F);
  border-bottom:1px solid var(--i-line);
}
#llfIntakeModal .lli-mark{
  width:31px; height:31px; flex:0 0 31px; border-radius:9px; font-size:16px;
  background:rgba(230,180,80,.13); display:grid; place-items:center;
}
#llfIntakeModal .lli-nm{
  display:block; font-family:'Archivo',system-ui,sans-serif; font-weight:700;
  font-size:15px; line-height:1.2; color:#F5F1E6;
}
#llfIntakeModal .lli-hd{
  display:block; font-family:'Hanken Grotesk',system-ui,sans-serif;
  font-size:11.5px; color:#9D978A; margin-top:1px;
}
#llfIntakeModal .lli-x{
  margin-left:auto; flex:0 0 auto; background:none; border:0; cursor:pointer;
  color:#9D978A; font-size:26px; line-height:1; padding:0 2px;
  font-family:'Hanken Grotesk',system-ui,sans-serif;
}
#llfIntakeModal .lli-x:hover{color:#F5F1E6}
#llfIntakeModal .lli-x:focus-visible{outline:2px solid #F7CE6E; outline-offset:2px; border-radius:6px}

/* the panel is always shown inside the dialog — the dialog is what opens now */
#llfIntakeModal #llfIntake{
  display:block; margin-top:0; padding:2px 18px 20px; border-top:0; animation:none;
}

/* D — a phone gets the whole screen. The form is 861px tall; a centred card
   there would waste the margins it cannot afford. */
@media (max-width:560px){
  #llfIntakeModal{
    width:100vw; max-width:100vw; height:100dvh; max-height:100dvh;
    margin:0; border:0; border-radius:0;
  }
}

/* The pop-out scrolls internally; the platform scrollbar is a light slab on a
   dark card, so tone it to the panel. */
#llfIntakeModal{scrollbar-width:thin;scrollbar-color:rgba(230,180,80,.38) transparent}
#llfIntakeModal::-webkit-scrollbar{width:10px}
#llfIntakeModal::-webkit-scrollbar-track{background:transparent}
#llfIntakeModal::-webkit-scrollbar-thumb{background:rgba(230,180,80,.32);border-radius:6px;
  border:3px solid transparent;background-clip:content-box}
#llfIntakeModal::-webkit-scrollbar-thumb:hover{background:rgba(230,180,80,.55);border:3px solid transparent;background-clip:content-box}

/* ---------------------------------------------------------------------------
   Rail labels. A <button> does not inherit `color`, and nothing in styles.css
   sets one for .donopt — so the four titles were falling back to the UA default
   of black, rendering rgb(0,0,0) on rgb(10,10,10): a contrast ratio of 1.06:1.
   Measured on production 2026-09-01, all four rails. The subtitles were
   rgb(111,106,96) at 3.68:1, under the 4.5:1 AA floor for small text.

   Pre-existing, not introduced here, but this file already owns .donopt.chosen
   and a donor cannot pick a rail they cannot read.
--------------------------------------------------------------------------- */
.herocard .donopt{color:#F5F1E6}
.herocard .donopt b{color:#F5F1E6}
.herocard .donopt small{color:#B4AE9F}
.herocard .donopt:hover b,
.herocard .donopt.chosen b{color:#F7CE6E}
