/* F-SI1: bringing in a bank's CSV (design/sheet-import/SPEC.md §4), in
 * Settings → Your data and its Bring in page, and the Ask bar's paste offer.
 * The palette's tokens only (pages.css points #settings at Lamplit or
 * Plaster); the phone's type scale only (app.css's --t-*, F-TY1).
 * "a guess" is peach, the Estimate colour (SPEC §6). Nothing here is red
 * but a backend failure (.status.bad, app.css). Every line wraps. */

.settings .sidoors { margin-top: 12px; }
.settings button.snapdoor { width: 100%; text-align: left; font: inherit; color: inherit; }
.settings .siprivacy { margin-top: 12px; }
.settings .sipaste { width: 100%; min-height: 120px; margin-top: 12px; font-family: ui-monospace, Menlo, monospace; font-size: var(--t-small); line-height: var(--lh-small); resize: vertical; }

/* What's in it: the file's name and its size. */
.settings .sihead { margin: 12px 0 4px; }
.settings .sifile { font-family: var(--body-face); font-size: var(--t-small); line-height: var(--lh-small); overflow-wrap: anywhere; }

/* A field's row: Hearth's word, then the file's column as a chip. */
.settings .simap { display: grid; gap: 4px; }
.settings .sichip {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; width: 100%; min-height: 44px; margin: 0;
  padding: 8px 12px; border: 1px solid rgb(var(--fg) / .3); border-radius: 12px; background: none;
  color: var(--cream); font-family: var(--body-face); font-size: var(--t-small); line-height: var(--lh-small); text-align: left; cursor: pointer;
}
.settings .sichip[aria-expanded="true"] { border-color: var(--peach); }
.settings .sichip .cn, .settings .sicols .cn { font-weight: 600; overflow-wrap: anywhere; }
.settings .sichip .cs, .settings .sicols .cs {
  display: block; flex-basis: 100%; min-width: 0; color: var(--softc); font-family: var(--body-face); font-size: var(--t-small); line-height: var(--lh-small); overflow-wrap: anywhere;
}
.settings .sichip .guess { color: var(--peach); font-family: var(--body-face); font-size: var(--t-small); line-height: var(--lh-small); }
.settings .sicols { grid-template-columns: 1fr; }
.settings .sicols button { display: grid; gap: 2px; font-family: var(--body-face); font-size: var(--t-small); line-height: var(--lh-small); }
.settings .sicols button[aria-pressed="true"] .cs { color: inherit; opacity: .8; }

/* Bills that recur: a switch per payee. */
.settings .sibills, .settings .sibillsedit .kv { margin-top: 8px; }

/* What lights up: the backend's list, dashed where it can't yet. */
.ecard .silights { display: grid; gap: 4px; margin-top: 4px; }
.ecard .sillist { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.ecard .sillist li { display: grid; gap: 4px; padding: 8px 12px; border-radius: 8px; border: 1px solid var(--edge); overflow-wrap: anywhere; }
.ecard .sillist li.on { background: rgb(var(--fg) / .05); }
.ecard .sillist li.on .ll::before { content: '●'; color: var(--peach); margin-right: 6px; font-size: .8em; }
.ecard .sillist li.off { border-style: dashed; color: var(--softc); }
.ecard .sillist .lw { font-family: var(--body-face); font-size: var(--t-small); line-height: var(--lh-small); color: var(--softc); }

/* Today's Confirm card in Settings: Settings' 4/8/12/16 scale (the
 * conversation's card is F-EM4's tighter 10 px; test_settings_type.py). */
.settings .ecard { padding: 12px; gap: 8px; }
.settings .ecard .k { padding-right: 0; }
.settings .ecard .btn { padding: 8px 16px; }

/* Your data: a file as a batch. */
.settings .sibatch { margin-top: 12px; padding: 12px; border-radius: 12px; border: 1px solid rgb(var(--fg) / .15); }
.settings .sibatch.undone { opacity: .7; }
.settings .sibatch .ecard { margin-top: 8px; }
.settings .sisource { color: var(--softc); }
.settings [data-sheet="kept"], .settings [data-sheet="confirm"] { margin-top: 12px; }

/* The Ask bar's offer, above the bar, when cells are pasted into it. */
.convo .sipaste-offer { flex: none; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: 0 12px 8px; }
.convo .sipaste-offer[hidden] { display: none; }
.convo .sipaste-offer .pw { flex-basis: 100%; font-family: var(--body-face); font-size: var(--t-small); line-height: var(--lh-small); color: var(--softc); }

/* F-SI2: the Mapping card (SPEC §4 step 4), in Settings' Bring in page and
 * in Ember's conversation. Hearth's field on the left, the file's column as
 * a chip on the right; "a guess" in peach. Her question is a bubble with
 * chips, one at a time. Every word wraps; nothing is cut off. */
.ecard .msaid, .settings .msay {
  margin: 0; font-family: var(--prose); font-size: var(--t-body); line-height: var(--lh-body); color: var(--ink2, var(--cream)); overflow-wrap: anywhere;
}
.settings .msay { margin-top: 12px; padding: 8px 12px; border-radius: 12px; border: 1px solid var(--edge); background: var(--wall); }
.settings [data-sheet="mapping"] { margin-top: 8px; animation: none; } /* redrawn on every answer: no rise each time */
.ecard .mrows { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.ecard .mrow {
  display: grid; grid-template-columns: 6.5em 1em minmax(0, 1fr); gap: 4px 8px; align-items: center; min-width: 0;
  font-family: var(--body-face); font-size: var(--t-small); line-height: var(--lh-small);
}
.ecard .mrow .f { color: var(--softc); overflow-wrap: anywhere; min-width: 0; }
.ecard .mword .f { color: var(--ink2, var(--cream)); font-weight: 600; }
.ecard .mrow .a { color: var(--softc); text-align: center; }
.ecard .mcols { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; min-width: 0; }
.ecard .mchip {
  display: inline-flex; flex-wrap: wrap; align-items: baseline; gap: 0 4px; max-width: 100%; min-width: 0; min-height: 32px; margin: 0;
  padding: 4px 12px; border: 1px solid rgb(var(--fg) / .3); border-radius: 16px; background: none; color: var(--ink2, var(--cream));
  font-family: var(--body-face); font-size: var(--t-small); line-height: var(--lh-small); text-align: left; cursor: pointer;
}
.ecard .mchip .cn { font-weight: 600; overflow-wrap: anywhere; min-width: 0; }
.ecard .mchip .cs { flex-basis: 100%; min-width: 0; color: var(--softc); font-weight: 400; overflow-wrap: anywhere; }
.ecard .mchip[aria-expanded="true"], .ecard .mchip[aria-pressed="true"] { border-color: var(--peach); }
.ecard .mcols .g { color: var(--peach); font-family: var(--body-face); font-weight: 600; font-size: var(--t-small); line-height: var(--lh-small); white-space: nowrap; }
.ecard .mchoose { display: flex; flex-wrap: wrap; gap: 4px; padding: 4px 0 4px 8px; border-left: 2px solid var(--edge); }
.ecard .mswap { border-style: dashed; color: var(--softc); }
.ecard .mopts { padding-top: 4px; border-top: 1px solid var(--edge); }
.ecard .mwords { display: grid; gap: 4px; padding-top: 4px; border-top: 1px solid var(--edge); }
.ecard .mwords > .k { padding-right: 0; }
.ecard .mnote, .ecard .mdone { margin: 0; font-family: var(--body-face); font-size: var(--t-small); line-height: var(--lh-small); color: var(--softc); }
.ecard .munmapped { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.ecard .munmapped li {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; padding: 4px 8px; border-radius: 8px; border: 1px dashed rgb(var(--fg) / .3);
  font-family: var(--body-face); font-size: var(--t-small); line-height: var(--lh-small); overflow-wrap: anywhere;
}
.ecard .munmapped .w { font-weight: 600; min-width: 0; }
.ecard .munmapped .why { color: var(--softc); min-width: 0; }
/* Her question: a bubble, Ember's, with its chips under it. */
.ecard .mq { display: grid; gap: 8px; padding: 8px 12px; border-radius: 12px; background: rgb(var(--fg) / .06); border: 1px solid var(--edge); }
.ecard .mq .bubq { margin: 0; font-family: var(--prose); font-size: var(--t-body); line-height: var(--lh-body); overflow-wrap: anywhere; }
.ecard .mqchips { display: flex; flex-wrap: wrap; gap: 8px; }
.ecard .mqchips .chip {
  position: relative; display: inline-flex; align-items: center; min-height: 32px; max-width: 100%; padding: 4px 12px; border-radius: 999px;
  border: 1px solid rgb(var(--fg) / .3); background: none; color: var(--ink2, var(--cream)); cursor: pointer;
  font-family: var(--body-face); font-weight: 600; font-size: var(--t-small); line-height: var(--lh-small); white-space: normal; text-align: left; height: auto;
}
