/* MeetDayKit — shared potluck sheet (v3)
   Host lists what the party needs; guests claim quantities. Loaded by the home page and by
   /potluck/list/. The shared site.css and the other tool pages are untouched. */
/* A class rule that sets display (e.g. .potluck-add{display:flex}) outranks the UA [hidden] rule,
   so the hidden attribute needs to win explicitly: JS toggles visibility on several of these. */
[hidden]{display:none !important}
.potluck-page .home-potluck{max-width:1040px;margin:0 auto;padding:16px 22px 44px}
.potluck-page .potluck-hero{max-width:760px}
.potluck-page h1{font-size:clamp(30px,5.6vw,54px);line-height:1.05;letter-spacing:-.045em;max-width:720px;margin:2px 0 10px}
.potluck-page .home-potluck__lede{color:var(--muted);font-size:clamp(16px,2.2vw,20px);line-height:1.45;max-width:640px;margin:0 0 10px}
.potluck-page .potluck-intro{color:var(--muted);font-size:14px;line-height:1.55;max-width:720px;margin:0 0 16px}

/* --- nav: trimmed home variant (brand + sheet anchor) --- */
.potluck-page .site-nav.home-nav{max-width:1040px;flex-direction:row;align-items:center;justify-content:space-between;gap:10px;margin:0 auto 10px;padding:10px 22px 10px;border-bottom:1px solid var(--line);font-size:14px}
.potluck-page .home-nav .site-nav__links{flex-wrap:nowrap;gap:4px}
.potluck-page .home-nav .site-nav__link{padding:6px 9px}

/* --- shared card + fields --- */
.potluck-tool{background:var(--card);border:1px solid var(--line);border-radius:18px;padding:16px 16px 14px;box-shadow:0 12px 34px #17333212}
.potluck-field{display:block;min-width:0}
.potluck-label{display:block;font-size:11px;font-weight:750;letter-spacing:.11em;text-transform:uppercase;color:var(--muted);margin:0 0 3px}
.potluck-field input,.potluck-field select{display:block;width:100%;min-width:0;box-sizing:border-box;border:1px solid var(--line);border-radius:9px;background:var(--card);color:var(--ink);font-family:inherit;font-size:16px;font-weight:550;padding:10px 11px}
.potluck-field input:focus,.potluck-field select:focus{border-color:var(--accent);background:var(--soft);outline:none}
.potluck-field input.is-missing{border-color:#c0563f;background:#fbf1ee}
.potluck-input{display:block;width:100%;min-width:0;box-sizing:border-box;border:1px solid var(--line);border-radius:9px;background:var(--soft);color:var(--ink);font-family:inherit;font-size:13.5px;font-weight:550;padding:9px 10px}
.potluck-input:focus{border-color:var(--accent);outline:none}
.potluck-button{appearance:none;border:1px solid var(--line);border-radius:9px;background:var(--card);color:var(--ink);font-weight:700;font-size:14px;line-height:1.2;font-family:inherit;padding:11px 15px;cursor:pointer;white-space:nowrap}
.potluck-button:hover{border-color:var(--accent);color:var(--accent)}
.potluck-button:disabled{opacity:.5;cursor:not-allowed}
.potluck-button--primary{background:var(--accent);border-color:var(--accent);color:#fff}
.potluck-button--primary:hover{background:#11584f;border-color:#11584f;color:#fff}
.potluck-button--small{padding:8px 11px;font-size:12.5px}
.potluck-button--danger[data-armed="true"]{border-color:#c0563f;background:#f7e9e9;color:#8d2f2f}
.potluck-save{margin:0;color:var(--muted);font-size:12px;font-weight:600;min-height:1.2em}

/* --- date field: the whole block is one 48px touch target (D45) --- */
.potluck-date-block{display:block;min-height:48px;cursor:pointer;border-radius:9px}
.potluck-date-block input[type="date"]{min-height:48px;width:100%;cursor:pointer}

/* --- home: create form --- */
.potluck-create-card{margin:0 0 18px}
.potluck-create{display:flex;flex-wrap:wrap;align-items:flex-end;gap:12px 14px}
.potluck-create .potluck-field--title{flex:1 1 260px}
.potluck-create .potluck-field--date{flex:0 1 190px}
.potluck-create__status{flex:1 1 100%}
.potluck-button--cta{flex:1 1 100%;padding:16px 22px;font-size:17px;border-radius:12px;min-height:56px}

/* --- home: static example table --- */
.potluck-example__title{font-size:clamp(18px,2.6vw,22px);letter-spacing:-.03em;margin:0 0 4px}
.potluck-example__caption{margin:0 0 12px;color:var(--muted);font-size:13px;font-weight:650}
.potluck-table-wrap{overflow-x:auto;width:100%}
#example-needs{width:100%;border-collapse:collapse;table-layout:fixed;min-width:560px}
#example-needs th{text-align:left;font-size:11px;font-weight:750;letter-spacing:.11em;text-transform:uppercase;color:var(--muted);padding:0 8px 6px}
#example-needs td{padding:10px 8px;border-top:1px solid var(--line);font-size:15px;font-weight:550;overflow-wrap:anywhere}
#example-needs td.need-item{font-weight:750}
#example-needs td.need-claimed,#example-needs td.need-claimants{color:var(--muted);font-size:13px;font-weight:650}
.potluck-col--item{width:26%}
.potluck-col--qty{width:16%}
.potluck-col--claimed{width:22%}
.potluck-col--remaining{width:16%}
.potluck-col--claimants{width:20%}

/* --- home: My events (this browser) --- */
.potluck-events{margin-top:18px}
.potluck-events__title{font-size:clamp(18px,2.6vw,22px);letter-spacing:-.03em;margin:0 0 4px}
.potluck-events__entry{margin:0 0 10px;font-size:13px;font-weight:650}
.potluck-events__entry a{color:var(--accent)}
.potluck-events__list{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:8px}
.potluck-events__row{display:flex;flex-wrap:wrap;align-items:center;gap:8px 10px;padding:10px 12px;border:1px solid var(--line);border-radius:12px;background:var(--soft)}
.potluck-events__text{display:flex;flex:1 1 160px;flex-direction:column;gap:2px;min-width:0}
.potluck-events__text strong{font-size:15px;font-weight:750;overflow-wrap:anywhere}
.potluck-events__date{color:var(--muted);font-size:12.5px;font-weight:650}
.potluck-events__empty{margin:0;color:var(--muted);font-size:13px;font-weight:650}
.potluck-events__note{margin:10px 0 0;color:var(--muted);font-size:13px;line-height:1.5;max-width:640px}

/* --- how it works --- */
.potluck-steps{max-width:760px;margin:26px 0 0;padding-top:18px;border-top:1px solid var(--line)}
.potluck-steps h2{font-size:clamp(20px,3vw,26px);letter-spacing:-.03em;margin:0 0 10px}
.potluck-steps ol{margin:0;padding-left:20px;color:var(--muted);font-size:14px;line-height:1.6}
.potluck-steps li{margin:0 0 6px}
.potluck-steps strong{color:var(--ink)}

.potluck-footer{max-width:1040px;margin:26px auto 0;padding:14px 22px 30px}
.potluck-sr{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}


/* ================= shared list page (v3.4) ================= */
/* One address, four stages (setup -> ready -> manage, plus guest). The page is compact because the
   host's main action is the only thing under the list, everything low-frequency is behind More, and
   the activity head holds a title and a date and nothing else. Nothing here shrinks the readable type
   or the touch targets: the height comes from removed chrome, not from smaller text. */
.sr{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}
.potluck-list-page .list-nav{display:flex;align-items:center;justify-content:flex-start;max-width:960px;min-height:44px;margin:0 auto 4px;padding:6px 12px;border-bottom:1px solid var(--line);font-size:14px;position:static}
.potluck-brand{font-size:14px;font-weight:800;letter-spacing:-.03em;color:var(--ink);text-decoration:none}
.potluck-list{max-width:960px;margin:0 auto;padding:0 12px 28px}

/* --- activity area: a compact title + date, no exit, no actions ---------- */
.activity-head{margin:0;padding:8px 0 4px}
#list-title{font-size:clamp(24px,3.4vw,30px);line-height:1.2;letter-spacing:-.035em;margin:0;overflow-wrap:anywhere;cursor:text;border-radius:8px}
#list-title .title-text{border-bottom:2px dashed transparent;padding-bottom:1px}
#list-title:hover .title-text{border-bottom-color:var(--line)}
#list-title[aria-disabled="true"]{cursor:default}
#list-title[aria-disabled="true"]:hover .title-text{border-bottom-color:transparent}
.edit-hint{display:inline-block;margin-left:8px;font-size:11px;font-weight:750;letter-spacing:.06em;text-transform:uppercase;color:var(--accent);background:var(--soft);border:1px solid var(--line);border-radius:99px;padding:2px 8px;vertical-align:middle}
.is-editing #list-title{display:none}
.edit-title-input{display:block;width:100%;min-height:44px;box-sizing:border-box;border:1px solid var(--accent);border-radius:10px;background:var(--card);color:var(--ink);font-family:inherit;font-size:20px;font-weight:800;letter-spacing:-.03em;padding:8px 12px;margin:2px 0}
.edit-title-input:focus{outline:2px solid var(--accent);outline-offset:1px}

.button{appearance:none;display:inline-flex;align-items:center;justify-content:center;min-height:44px;border:1px solid var(--line);border-radius:10px;background:var(--card);color:var(--ink);font-family:inherit;font-size:14px;font-weight:700;line-height:1.2;padding:10px 14px;cursor:pointer;white-space:nowrap;text-decoration:none}
.button:hover{border-color:var(--accent);color:var(--accent)}
.button--primary{background:var(--accent);border-color:var(--accent);color:#fff}
.button--primary:hover{background:#11584f;border-color:#11584f;color:#fff}
.button--quiet{background:var(--card)}
.button:disabled{opacity:.5;cursor:not-allowed}

.activity-meta{display:flex;align-items:center;gap:4px 12px;flex-wrap:wrap;margin:4px 0 0}
.date-block{display:flex;align-items:center;min-height:48px;padding:0 10px;border:1px solid var(--line);border-radius:10px;background:var(--card);cursor:pointer}
.date-block input[type="date"]{border:0;background:transparent;color:var(--ink);font-family:inherit;font-size:16px;font-weight:650;min-height:44px;padding:0 2px;cursor:pointer}
.date-block input[type="date"]:focus{outline:2px solid var(--accent);outline-offset:2px;border-radius:6px}
.date-block input[type="date"]:disabled{cursor:default;opacity:1}
.progress{margin:0;font-size:14px;font-weight:750;color:var(--accent)}
.list-closed{margin:4px 0 0;font-size:13px;font-weight:750;color:#8d2f2f}
.expiry{margin:0;color:var(--muted);font-size:12.5px;font-weight:650;line-height:1.4}
.save-status{margin:0;color:var(--muted);font-size:13px;font-weight:600;min-height:1.1em}
/* An empty status line must not hold the page open — that was most of the old head height. */
.save-status:empty{display:none;min-height:0}
.potluck-error{margin:10px 0;padding:12px 14px;border:1px solid #d9a8a8;border-radius:12px;background:#f9ecec;color:#8d2f2f;font-size:14px;font-weight:650}

/* --- more menu: an anchored overlay, out of the flow (D87) --------------- */
.more-menu{position:fixed;z-index:40;left:8px;top:8px;display:flex;flex-direction:column;gap:2px;padding:8px;border:1px solid var(--line);border-radius:14px;background:var(--card);box-shadow:0 18px 40px #1733322e;width:min(320px,calc(100vw - 24px));max-width:calc(100vw - 24px);max-height:70vh;overflow:auto}
.menu-item{appearance:none;display:flex;align-items:center;min-height:44px;border:0;border-radius:9px;background:transparent;color:var(--ink);font-family:inherit;font-size:14px;font-weight:650;text-align:left;padding:10px 12px;cursor:pointer}
.menu-item:hover{background:var(--soft);color:var(--accent)}
.menu-item--danger{color:#8d2f2f}
.menu-item--danger:hover{background:#f7e9e9;color:#8d2f2f}
.menu-item--danger[data-armed="true"]{background:#f7e9e9;border:1px solid #c0563f;font-weight:800}
.menu-label{display:block;margin:6px 4px 2px;font-size:11px;font-weight:750;letter-spacing:.08em;text-transform:uppercase;color:var(--muted)}
#event-info{padding:2px 12px 8px;margin:0 0 4px;border-bottom:1px solid var(--line)}
.more-menu .text-input{flex:1 1 auto;width:100%;font-size:12px}
.more-menu .save-status{min-height:0;margin:2px 4px}
.text-input{flex:1 1 220px;min-width:0;min-height:40px;box-sizing:border-box;border:1px solid var(--line);border-radius:9px;background:var(--soft);color:var(--ink);font-family:inherit;font-size:13px;font-weight:600;padding:8px 10px}
.text-input:focus{border-color:var(--accent);outline:none}
.invite-fallback{display:flex;flex-wrap:wrap;gap:8px;align-items:center;margin:0}

/* --- host actions: the only block under the list (D84/D86) -------------- */
.host-actions{display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin:6px 0 0;padding:8px 0 2px;border-top:1px solid var(--line)}
.host-actions .button{flex:0 1 auto}
.host-actions .save-status,.host-actions .list-waiting,.host-actions .invite-fallback{flex:1 1 100%}
#finish-list{flex:1 1 100%;width:100%;min-height:48px}
#invite-guests.is-primary-action{flex:1 1 100%;width:100%}
.list-waiting{margin:0;color:var(--muted);font-size:14px;font-weight:650}

/* --- needs list ---------------------------------------------------------- */
.needs{margin:2px 0 0}
.table-wrap{overflow-x:auto;width:100%}
.needs-table{width:100%;border-collapse:collapse;table-layout:fixed}
.needs-table th{text-align:left;font-size:11px;font-weight:750;letter-spacing:.1em;text-transform:uppercase;color:var(--muted);padding:0 8px 6px}
.needs-table td{padding:10px 8px;border-top:1px solid var(--line);vertical-align:top;font-size:14px}
/* Four objects per row: item + category chip / amount / claimed by / row actions. Only the item name
   breaks anywhere — a wrapping Claim or a wrapping action column was the v3.1 bug (D68). */
.col-item{width:32%}
.col-amount{width:26%}
.col-claimants{width:26%}
.col-actions{width:16%}
.need-name{font-weight:750;overflow-wrap:anywhere}
.need-category-chip{display:inline-block;margin-left:8px;font-size:11px;font-weight:750;letter-spacing:.06em;text-transform:uppercase;color:var(--accent);background:var(--soft);border:1px solid var(--line);border-radius:99px;padding:2px 8px;vertical-align:middle}
.need-amount span{display:block;line-height:1.35}
.amount-needed{font-weight:750}
.amount-claimed,.amount-remaining{color:var(--muted);font-size:13px;font-weight:650}
.need-claimants{font-size:13px;color:var(--muted);min-width:0}
.claimants-summary{display:inline;font-weight:700;color:var(--ink);overflow-wrap:anywhere}
/* Claim and the row menu stay on one line: stacking them would double every row's height. */
.row-actions{display:flex;gap:6px;align-items:center;justify-content:flex-end;flex-wrap:nowrap}
.need-actions{white-space:nowrap}
/* A desk keeps a compact 32px control (a wrapping Claim was the old bug); the phone gets 44px. */
.need-actions button{appearance:none;min-height:32px;min-width:32px;border:1px solid var(--line);border-radius:9px;background:var(--card);color:var(--ink);font-family:inherit;font-size:14px;font-weight:700;padding:6px 10px;cursor:pointer;white-space:nowrap}
.need-actions button:hover{border-color:var(--accent);color:var(--accent)}
.need-actions button:disabled{opacity:.45;cursor:not-allowed}
.row-complete{font-size:12.5px;font-weight:750;letter-spacing:.02em;color:var(--accent);white-space:nowrap}
tr.need-row.is-complete td.need-amount .amount-needed{color:var(--muted);font-weight:650}
.claimants-toggle{appearance:none;margin-left:6px;min-height:32px;border:1px solid var(--line);border-radius:99px;background:var(--card);color:var(--muted);font-family:inherit;font-size:12.5px;font-weight:700;padding:5px 10px;cursor:pointer;white-space:nowrap}
.claimants-toggle:hover{border-color:var(--accent);color:var(--accent)}
.claimants-list{display:flex;flex-direction:column;gap:2px;margin-top:6px}
.claimant-line{display:flex;align-items:center;gap:8px;min-height:30px;padding-top:2px;border-top:1px dashed var(--line)}
.claimant-name{flex:1 1 auto;min-width:0;font-weight:700;color:var(--ink);overflow-wrap:anywhere}
.claimant-qty{flex:0 0 auto;font-weight:750;color:var(--muted);white-space:nowrap}
/* D66: one trash icon per claim, 32px on a desk and 44px on a phone, first click arms it. */
.claim-remove{appearance:none;display:inline-flex;flex:0 0 auto;align-items:center;justify-content:center;width:32px;height:32px;min-width:32px;min-height:32px;border:1px solid var(--line);border-radius:8px;background:var(--card);color:var(--muted);padding:0;cursor:pointer}
.claim-remove:hover{border-color:#c0563f;color:#8d2f2f}
.claim-remove svg{display:block;width:15px;height:15px;pointer-events:none}
.claim-remove.is-armed,.claim-remove[data-armed="true"]{border-color:#c0563f;background:#f7e9e9;color:#8d2f2f}
.claim-qty-input{width:66px;min-height:32px;box-sizing:border-box;border:1px solid var(--line);border-radius:8px;background:var(--card);color:var(--ink);font-family:inherit;font-size:16px;font-weight:600;padding:4px 6px}
/* An empty list says what to do next instead of showing a lone header row. */
tr.empty-row td{padding:8px 0 10px;border-top:1px solid var(--line);color:var(--muted);font-size:14px;font-weight:600}

/* --- claim form (only after Claim) --- */
tr.claim-row td{padding:0 0 12px;border-top:0}
.claim-form{display:flex;flex-wrap:wrap;gap:8px 10px;align-items:flex-end;padding:12px;border-radius:12px;background:var(--soft)}
.claim-field{display:flex;flex:1 1 140px;flex-direction:column;gap:3px;min-width:0}
.claim-field--qty{flex:0 1 96px}
.field-label{font-size:11px;font-weight:750;letter-spacing:.08em;text-transform:uppercase;color:var(--muted)}
.claim-field input,.add-field input,.edit-field input{display:block;width:100%;min-height:44px;box-sizing:border-box;border:1px solid var(--line);border-radius:9px;background:var(--card);color:var(--ink);font-family:inherit;font-size:16px;font-weight:550;padding:9px 10px}
.claim-field input:focus,.add-field input:focus,.edit-field input:focus{border-color:var(--accent);background:var(--card);outline:none}
.claim-field input.is-missing{border-color:#c0563f;background:#fbf1ee}
#claim-status{flex:1 1 100%}

/* --- add form: the last row of the table -------------------------------- */
tr.add-row td{padding:8px 0 0;border-top:1px solid var(--line)}
.add-need{display:flex;flex-wrap:wrap;gap:8px 10px;align-items:flex-end}
.add-field{display:flex;flex-direction:column;gap:3px;min-width:0}
.add-field--item{flex:2 1 190px}
.add-need__row{display:flex;flex:1 1 240px;gap:8px;align-items:flex-end}
.add-field--qty{flex:0 0 96px}
.add-field--unit{flex:0 0 110px}
#add-need-submit{flex:1 1 auto;min-height:44px}
.add-need__toggles{display:flex;flex:0 1 auto;gap:6px;align-items:center}
.add-category-field{flex:1 1 100%}
#add-need-status{flex:1 1 100%}
.pills{display:flex;flex-wrap:wrap;gap:6px}
.pill{appearance:none;min-height:40px;border:1px solid var(--line);border-radius:99px;background:var(--card);color:var(--muted);font-family:inherit;font-size:13px;font-weight:700;padding:8px 12px;cursor:pointer}
.pill:hover{border-color:var(--accent);color:var(--accent)}
.pill[aria-pressed="true"]{background:var(--accent);border-color:var(--accent);color:#fff}
/* D70: "Unit"/"Category" read as optional fields, not as chosen categories — so they are dashed chips. */
.pill--unit{min-height:44px;border-style:dashed;color:var(--ink);font-weight:750}
.pill--unit[aria-expanded="true"]{border-style:solid;background:var(--soft);color:var(--accent)}
.pill--toggle{min-height:44px;border-style:dashed;color:var(--ink);font-weight:750}
.pill--toggle[aria-expanded="true"]{border-style:solid;background:var(--soft);color:var(--accent)}

/* --- row menu (fixed, so it never widens the page) ---------------------- */
#row-menu{position:fixed;z-index:40;left:8px;top:8px;width:min(320px,calc(100vw - 16px));max-height:calc(100vh - 16px);overflow:auto;display:flex;flex-direction:column;gap:2px;padding:8px;border:1px solid var(--line);border-radius:14px;background:var(--card);box-shadow:0 18px 40px #1733322e}
.row-edit-form{display:flex;flex-wrap:wrap;gap:8px 10px;align-items:flex-end;margin-top:4px;padding-top:8px;border-top:1px solid var(--line)}
.edit-field{display:flex;flex:1 1 120px;flex-direction:column;gap:3px;min-width:0}
.edit-field--qty{flex:0 1 90px}
.edit-field--unit{flex:0 1 100px}
.row-edit-form .pills{flex:1 1 100%}
#row-status{flex:1 1 100%}

/* --- footer: the single, quiet way out (D86) ---------------------------- */
#back-my-events{color:var(--muted);font-size:13px;font-weight:600;text-decoration:none;padding:4px 0}
#back-my-events:hover{color:var(--accent);text-decoration:underline}

@media (max-width:560px){
  .potluck-page .home-potluck{padding:8px 14px 36px}
  .potluck-page .site-nav.home-nav{padding:8px 14px 8px;margin-bottom:6px}
  .potluck-page .potluck-intro{font-size:13.5px}
  /* Phones: the static example must show every column without a sideways scroll — an example that
     hides "Still needed" behind a swipe teaches nothing. Cells wrap instead; type stays as is. */
  #example-needs{min-width:0}
  #example-needs th{padding:0 4px 6px;letter-spacing:.05em}
  #example-needs td{padding:9px 4px}
  .potluck-tool{padding:12px 10px 10px;border-radius:14px}
  .potluck-create{gap:8px 10px}
  .potluck-create .potluck-field--title,.potluck-create .potluck-field--date{flex:1 1 100%}
  .potluck-button{padding:10px 13px;font-size:13.5px}
  .potluck-button--cta{padding:15px 18px;font-size:16px;min-height:56px}
  .potluck-page .potluck-footer{padding:12px 14px 26px}
  .potluck-events__row{padding:10px}
}

@media (prefers-color-scheme:dark){
  .potluck-tool{box-shadow:none}
  .potluck-button--primary{background:#267d70;border-color:#267d70;color:#f2fbf8}
  .potluck-button--primary:hover{background:#2f8d7e;border-color:#2f8d7e}
  .potluck-field input:focus,.potluck-field select:focus,.potluck-input:focus,.potluck-needs__table input:focus{background:#223531}
  .potluck-input{background:#223531;border-color:#405950}
  .potluck-error{background:#3a2323;border-color:#5d3a3a;color:#f0b3b3}
  .potluck-field input.is-missing{background:#3a2323;border-color:#7a463a}
  .potluck-events__row{background:#223531}
  .potluck-button--danger[data-armed="true"]{background:#3a2323;border-color:#5d3a3a;color:#f0b3b3}
}

/* --- v3.4 phones: the compact head, and the needs table becomes cards ----- */
@media (max-width:720px){
  .potluck-list{padding:0 12px 24px}
  .potluck-list-page .list-nav{padding:6px 12px;margin:0 auto 2px}
  .activity-head{padding:6px 0 2px}
  #list-title{font-size:20px;line-height:1.25;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
  .edit-hint{display:none}
  .activity-meta{gap:2px 10px;margin:2px 0 0}
  .date-block{min-height:44px;padding:0 8px}
  .date-block input[type="date"]{min-height:42px}
  /* D88: the add form is one line of item, one line of amount + submit, one line of optional chips.
     Labels fold away on the phone (every field keeps its aria-label); nothing gets smaller. */
  .add-need{display:grid;grid-template-columns:minmax(0,1fr);gap:4px}
  .add-need .field-label{display:none}
  .add-need__row{display:flex;gap:8px}
  .add-field--item{flex:1 1 100%}
  #add-need-submit{min-height:44px}
  /* D88: when the software keyboard is up and the focused line is scrolled into view, keep it clear
     of the top of the visible viewport (96px) and of the keyboard edge (16px). */
  #need-item,#add-need-submit{scroll-margin-block:96px 16px}
  .add-need__toggles{display:flex;gap:6px}
  .add-need__toggles .pill{flex:1 1 50%}
  .add-need .save-status{min-height:0}
  .host-actions{gap:8px}
  #finish-list{min-height:48px}
  .need-actions button{min-height:44px;min-width:44px;padding:10px 12px}
  /* D93-4: the fold indicator is a real touch target on a phone, not a 32px glyph. */
  .claimants-toggle{min-height:44px;min-width:44px;padding:10px 12px}
  #needs-table td.need-amount span{line-height:1.25}
  #back-my-events{padding:8px 0}
}
@media (max-width:640px){
  .potluck-list{padding:0 12px 28px}
  #needs-table colgroup,#needs-table thead{display:none}
  #needs-table,#needs-table tbody{display:block}
  #needs-table tr.need-row{display:grid;grid-template-columns:minmax(0,1fr) auto;grid-template-areas:"item item" "amount amount" "claimants actions";gap:0 10px;padding:6px 0;border-top:1px solid var(--line)}
  /* D71: an opened claimant list takes the whole card width; the row actions drop to their own line
     so the names never squeeze into a desktop-sized column on a phone. */
  #needs-table tr.need-row.is-open{grid-template-areas:"item item" "amount amount" "claimants claimants" "actions actions"}
  #needs-table tr.need-row.is-open td.need-actions{justify-self:end}
  #needs-table tr.need-row td{display:block;padding:0;border:0}
  #needs-table td.need-item{grid-area:item}
  #needs-table td.need-amount{grid-area:amount}
  #needs-table td.need-claimants{grid-area:claimants}
  #needs-table td.need-actions{grid-area:actions;align-self:start}
  #needs-table tr.claim-row,#needs-table tr.add-row,#needs-table tr.empty-row{display:block;padding:4px 0;border-top:1px solid var(--line)}
  #needs-table tr.claim-row td,#needs-table tr.add-row td,#needs-table tr.empty-row td{display:block;padding:0;border:0}
  /* D71: the stacked card keeps a label next to each number instead of a column header it lost. */
  #needs-table td.need-amount::before,#needs-table td.need-claimants::before{content:attr(data-label);display:block;margin-bottom:1px;font-size:10.5px;font-weight:750;letter-spacing:.1em;text-transform:uppercase;color:var(--muted)}
  .claimant-line{min-height:36px}
  .claim-field--qty{flex:0 1 80px}
  #row-menu{width:calc(100vw - 16px)}
}
/* D66: on a phone the remove icon is a 44px touch target, not a 32px glyph. It is pinned inside the
   line's right edge so the row does not grow taller than the text it belongs to. */
@media (max-width:720px){
  .claimant-line{position:relative;min-height:40px;padding-right:52px}
  .claimant-line .claim-remove{position:absolute;right:0;top:50%;transform:translateY(-50%);width:44px;height:44px;min-width:44px;min-height:44px}
  .claimant-line .claim-remove svg{width:18px;height:18px}
}

@media (prefers-color-scheme:dark){
  .claim-form{background:#223531}
  .date-block,.more-menu,#row-menu{background:var(--card);border-color:var(--line)}
  .menu-item--danger[data-armed="true"]{background:#3a2323;border-color:#5d3a3a;color:#f0b3b3}
  .claimants-toggle:hover{background:#223531}
  .claim-remove{background:#223531;border-color:#405950;color:var(--ink)}
  .claim-remove.is-armed,.claim-remove[data-armed="true"]{background:#3a2323;border-color:#5d3a3a;color:#f0b3b3}
  .need-actions button,.text-input{background:#223531;border-color:#405950;color:var(--ink)}
  .edit-title-input,.claim-field input,.add-field input,.edit-field input{background:#223531;border-color:#405950;color:var(--ink)}
  .menu-item:hover,.claimants-toggle:hover{background:#223531}
}

/* Holiday season cross-link strip (removable after the holidays) */
.season-strip{margin:14px 0 0;padding:10px 14px;border:1px solid var(--line,#e2e0da);border-radius:10px;background:#fffdf7;font-size:14px;line-height:1.55;color:var(--muted,#5b5b57)}
.season-strip strong{color:var(--ink,#1d1d1b);margin-right:6px}
.season-strip a{color:var(--accent,#1f6f54);text-decoration:underline;text-underline-offset:2px}
.season-strip a:hover{text-decoration-thickness:2px}
@media(max-width:520px){.season-strip{font-size:13.5px}}
