/* 9.6.2 — Flat. Replaces every "liquid glass" layer (translucent fills, backdrop blur, sheens, rims, inner glows,
   drop shadows) with solid iOS dark-mode surfaces. Loaded last, after every other sheet, so it wins without
   touching the older layers: black background, #1C1C1E cards and rows, #2C2C2E raised controls (and the rows
   inside a sheet), hairline separators, white / #8E8E93 text, Apple blue only on buttons and accents.
   Inputs: no blue ring or outline on focus; the field's fill steps up one shade instead. */
:root, html {
  --bg: #000000; --cell: #1C1C1E; --cell2: #2C2C2E; --cell-press: #2C2C2E; --sheet: #1C1C1E; --sheet-cell: #2C2C2E;
  --label: #FFFFFF; --label2: #8E8E93; --label3: #636366; --label4: #48484A;
  --sep: rgba(84,84,88,.65); --fill: #2C2C2E; --fill2: #3A3A3C; --thumb: #636366; --track: #39393D;
  --accent: #0A84FF; --accent-soft: #0B2A4A; --bar: #1C1C1E; --glyph-bg: #3A3A3C; --menu: #2C2C2E;
  --field: #2C2C2E; --field-on: #3A3A3C;
  /* the old glass recipe, emptied: every layer that used it now paints one solid colour */
  --glass-fill: #1C1C1E; --glass-fill-strong: #1C1C1E; --glass-solid: #1C1C1E;
  --glass-sheen: none; --glass-lens: none; --glass-rim: none;
  --glass-inner: 0 0 0 0 transparent; --glass-shadow: 0 0 0 0 transparent;
  --glass-blur: none; --glass-blur-strong: none; --glass-pill: #2C2C2E; --glass-press: #3A3A3C;
  --panel-fill: #1C1C1E; --panel-press: #2C2C2E; --panel-rim: none; --panel-shadow: 0 0 0 0 transparent;
  --tint-fill: var(--accent); --danger-fill: #3A1715; --danger-text: #FF6961;
  --crisp-fill: #1C1C1E; --crisp-edge: 0 0 0 0 transparent; --crisp-shadow: 0 0 0 0 transparent; --toast: #2C2C2E;
  --k-tile: #1C1C1E; --k-tile2: #1C1C1E; --k-edge: transparent;
}
html.light {
  --bg: #F2F2F7; --cell: #FFFFFF; --cell2: #F2F2F7; --cell-press: #E5E5EA; --sheet: #F2F2F7; --sheet-cell: #FFFFFF;
  --label: #000000; --label2: #8A8A8E; --label3: #C4C4C7; --label4: #D8D8DC;
  --sep: #C6C6C8; --fill: #E5E5EA; --fill2: #D1D1D6; --thumb: #FFFFFF; --track: #E9E9EA;
  --accent: #007AFF; --accent-soft: #DCEBFF; --bar: #FFFFFF; --glyph-bg: #8E8E93; --menu: #FFFFFF;
  --field: #E5E5EA; --field-on: #D1D1D6;
  --glass-fill: #FFFFFF; --glass-fill-strong: #F2F2F7; --glass-solid: #FFFFFF; --glass-pill: #E5E5EA; --glass-press: #D1D1D6;
  --panel-fill: #FFFFFF; --panel-press: #E5E5EA; --danger-fill: #FDE2E0; --danger-text: #E0352B;
  --crisp-fill: #FFFFFF; --toast: #FFFFFF; --k-tile: #FFFFFF; --k-tile2: #FFFFFF;
}
/* inside a sheet (itself #1C1C1E) controls and grouped rows sit one shade up */
.sheet { --glass-fill: #2C2C2E; --crisp-fill: #2C2C2E; --panel-fill: #2C2C2E; --k-tile: #2C2C2E; --fill: #3A3A3C; --fill2: #48484A; --field: #2C2C2E; --field-on: #3A3A3C; }
html.light .sheet { --glass-fill: #FFFFFF; --crisp-fill: #FFFFFF; --panel-fill: #FFFFFF; --k-tile: #FFFFFF; --fill: #E5E5EA; --fill2: #D1D1D6; --field: #FFFFFF; --field-on: #E5E5EA; }

/* no blur anywhere, and no glow, rim, sheen or drop shadow on any surface */
*, *::before, *::after { -webkit-backdrop-filter: none !important; backdrop-filter: none !important; }
html body *, html body *::before, html body *::after { box-shadow: none !important; }
/* the specular rims and sheen overlays were drawn on ::before / ::after with a mask; with no paint they vanish,
   these are the ones painted with their own gradient */
.pass::after, .k-card::after, .nav::before, .view::after { display: none !important; }
/* what stays: autofill keeps its painted fill (the browser's yellow otherwise), the code boxes keep their state ring */
html body input:-webkit-autofill, html body input:-webkit-autofill:hover, html body input:-webkit-autofill:focus, html body input:-webkit-autofill:active {
  -webkit-box-shadow: 0 0 0 1000px var(--field) inset !important; box-shadow: 0 0 0 1000px var(--field) inset !important; -webkit-text-fill-color: var(--label) !important; }
html body .kl-otp-boxes i.on, html body .wl-otp-boxes i.on { box-shadow: inset 0 0 0 2px var(--accent) !important; }
html body .kl-otp.bad .kl-otp-boxes i, html body .wl-otp.bad .wl-otp-boxes i { box-shadow: inset 0 0 0 2px var(--red) !important; }

/* solid surfaces */
html body .sheet { background: var(--sheet) !important; }
html body .sheet .group, html:not(.light) body .sheet .group { background: var(--sheet-cell); }
html body .group, html body .card, html body .fl, html body .fl-alert, html body .fl-btn { background: var(--panel-fill); }
html body .card:active { background: var(--panel-press); }
html body .tabbar { background: var(--bar); border: .5px solid var(--sep); }
html.light body .tabbar { border-color: #D1D1D6; }
html body .tab[aria-selected="true"] { background: var(--glass-pill); }
html body .menu, html body .hud { background: var(--menu); border: .5px solid var(--sep); }
html body .seg { background: var(--fill); }
html body .seg .thumb, html:not(.light) body .seg .thumb { background: var(--thumb); }
html body .switch, html:not(.light) body .switch { background: var(--track); }
html body .switch::after { background: #FFFFFF; }
html body .ranges button[aria-pressed="true"], html.light body .ranges button[aria-pressed="true"] { background: var(--fill2); }
html body .cta, html body .cta.give, html body .sheet .sbar .nav-btn.b, html body .composer .send { background: var(--accent); color: #fff; }
html body .cta[disabled], html body .sheet .sbar .nav-btn.b[disabled] { background: var(--fill); color: var(--label3); }
html body .composer .send[disabled] { background: var(--fill2); color: var(--label3); opacity: 1; }
html body .avatar, html body .nav .avatar, html body .k-head .avatar, html body .k-prof .avatar { background: #48484A !important; color: #fff !important; }
html body .k-hero { background: var(--k-tile); }
html body .k-empty .k-eic { background: var(--accent); }
html body .kl-na-ic { background: var(--red); }
html body .k-card, html body .k-art { background: var(--ca, #2C2C2E) !important; }
html body .k-card .kc-chip { background: #CDB677; }
html body .pass.graphite { background: #2C2C2E; } html body .pass.midnight { background: #1A2236; }
html body .pass.titanium { background: #C9C9CE; } html body .pass.champagne { background: #DDD2BF; }
html body .ibox, html.light body .ibox { background: var(--field); }
html body .sb-err { background: #3A1715; }
html.light body .sb-err { background: #FDE2E0; }
html body .meter.lg i.exp { background: #0B3A6E; }
html.light body .meter.lg i.exp { background: #B8D7FF; }
html body .k-delta.up { background: #3A1A1A; } html body .k-delta.down { background: #10301A; }
html.light body .k-delta.up { background: #FDE2E0; } html.light body .k-delta.down { background: #DDF5E3; }

/* KollelAi: solid bubbles, chips and cards; the bottom bar is the sheet's own colour, no fade */
html body .msg.ai { background: var(--fill); }
html body .acard { background: var(--fill); }
html body .ac-bar { background: var(--fill2); }
html body .fup, html body .achip, html.light body .fup, html.light body .achip { background: var(--fill); }
html body .ask-foot, html.light body .ask-foot { background: var(--sheet); }

/* ---- inputs: no blue ring, no outline box; focus = one shade lighter fill, caret in the accent ---- */
input, textarea, select, [contenteditable] { caret-color: var(--accent); }
html body input:focus, html body input:focus-visible, html body textarea:focus, html body textarea:focus-visible,
html body select:focus, html body select:focus-visible, html body [contenteditable]:focus, html body [contenteditable]:focus-visible { outline: none !important; }
html body .composer .field { background: var(--field); border: 0; transition: background-color .15s linear; }
html body .composer .field:focus-within { background: var(--field-on); }
html body .search { background: var(--field); transition: background-color .15s linear; }
html body .search:focus-within { background: var(--field-on); }
html body .ibox { transition: background-color .15s linear; }
html body .ibox:focus-within { background: var(--field-on); }
html body .kl-lock-field { transition: background-color .15s linear; }
html body .kl-lock-field:focus-within { background: var(--field-on); }
html body .wl-stage .wl-group:focus-within { background: #2C2C2E; }
html body .wl.su .su-amt { background: var(--fill2); }
html body .wl.su .su-amt:focus { background: #48484A; }
html.light body .wl.su .su-amt:focus { background: #C7C7CC; }

/* ---- 9.6.2 keyboard: while the iPhone keyboard is up the open sheet fits the visible area (sheets.js sets its
   top and height from visualViewport); no home-indicator padding under the composer, the empty state shrinks ---- */
html body .sheet.kbfit { transition: transform .5s var(--ease), border-radius .4s var(--ease); }
html body .sheet.kbfit .composer { padding-bottom: 8px; }
html body .sheet.kbfit .sbody { padding-bottom: 8px; }
html body .sheet.kbfit .ask-empty { min-height: 0; padding-bottom: 8px; }

/* welcome, sign-in and first-run screens (their own variables) */
.wl.dark, .wl:not(.light) { --fill2: #2C2C2E; --glass: #1C1C1E; --glass-edge: transparent; --label2: #8E8E93; --label3: #636366; --sep: rgba(84,84,88,.65); }
.wl.light { --fill2: #E5E5EA; --glass: #FFFFFF; --glass-edge: transparent; }
@media (prefers-color-scheme: light) { .wl:not(.dark) { --fill2: #E5E5EA; --glass: #FFFFFF; --glass-edge: transparent; --label2: #8A8A8E; --label3: #C4C4C7; --sep: #C6C6C8; } }

/* the last blurs: the colour glow behind the home tiles, and the blur on the welcome screen's exit */
html body .k-tile .k-glow { display: none !important; }
html body .wl.wl-leave { filter: none; }

/* 9.6.4 money-type questions + Money In rows (flat iOS dark) */
.kl-qcard { text-align: left; }
.kl-qcard .k-lbl { color: var(--accent); }
.kl-qsub { display: block; margin-top: 4px; font-size: 15px; color: #FFFFFF; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kl-qhead { padding: 6px 20px 2px; }
.kl-qamt { font-size: 34px; font-weight: 700; line-height: 41px; font-variant-numeric: tabular-nums; }
.kl-qwho { font-size: 17px; font-weight: 600; margin-top: 2px; }
.kl-qmeta { font-size: 15px; color: #8E8E93; margin-top: 2px; }
.kl-qopt .t2 { font-size: 13px; line-height: 18px; }
.kl-qopt .check { color: #0A84FF; opacity: 0; }
.kl-qopt[aria-checked="true"] .check { opacity: 1; }
.kl-inrow .kl-dot { width: 8px; height: 8px; border-radius: 4px; background: var(--c); margin-right: 12px; flex: none; }

/* 9.6.5: questions answer one tap (no double-tap zoom wait, no grey flash); the answered card closes up without a jump */
.kl-qcard, .kl-qopt, #qSave, #qLater, #qAlways { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
.kl-qgone { display: block; overflow: hidden; pointer-events: none; transition: height .3s cubic-bezier(.32, .72, 0, 1), margin .3s cubic-bezier(.32, .72, 0, 1); }
.kl-qgone.out { height: 0 !important; margin-top: 0 !important; margin-bottom: 0 !important; }
.kl-qalways[hidden] { display: none; }

/* 9.6.6: Members › Requests — full emails (tap to copy), the waitlist email, and one applicant's sheet */
.mrow.kreq { cursor: pointer; align-items: flex-start; padding-top: 12px; padding-bottom: 12px; touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
.mrow.kreq:active { background: var(--cell-press); }
.mrow.kreq[hidden] { display: none; }
.mrow.kreq .mmain .t1 { font-size: 17px; line-height: 22px; font-weight: 600; }
.kreq-mail { display: block; max-width: 100%; padding: 0; margin: 1px 0 0; border: 0; background: none; font: inherit; font-size: 15px; line-height: 20px; color: var(--accent); text-align: left; white-space: normal; overflow-wrap: anywhere; cursor: pointer; }
.kreq-meta { display: block; margin-top: 2px; font-size: 13px; line-height: 18px; color: var(--label2); font-variant-numeric: tabular-nums; }
.kreq-sent { color: var(--label2); }
.kreq-not { color: var(--label); }
.kreq-chev { flex: none; align-self: center; color: var(--label3); display: inline-flex; }
.kreq-chev .chev { width: 8px; height: 14px; }
.kreq-search { margin: 0 16px 8px; }
.kreq-search input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; color: var(--label); font: inherit; font-size: 17px; }
.kreq-head { display: flex; flex-direction: column; align-items: center; padding: 6px 16px 18px; }
.kreq-av { width: 64px; height: 64px; border-radius: 32px; display: inline-flex; align-items: center; justify-content: center; background: #2C2C2E; color: #FFFFFF; font-size: 24px; font-weight: 600; }
.kreq-hn { margin-top: 10px; font-size: 22px; line-height: 28px; font-weight: 700; color: var(--label); text-align: center; }
.kreq-hs { margin-top: 2px; font-size: 15px; line-height: 20px; color: var(--label2); }
.kreq-g .row.kreq-f { align-items: flex-start; gap: 12px; min-height: 44px; padding: 11px 16px; }
.kreq-k { flex: none; width: 118px; font-size: 15px; line-height: 20px; color: var(--label2); }
.kreq-v { flex: 1; min-width: 0; font-size: 15px; line-height: 20px; color: var(--label); text-align: right; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.kreq-stack { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; text-align: left; }
.kreq-mailv { font-size: 17px; line-height: 22px; color: var(--label); overflow-wrap: anywhere; }
.kreq-email .kreq-copy { align-self: center; }
.kreq-copy { flex: none; font-size: 15px; line-height: 20px; color: var(--accent); font-weight: 600; }
.kreq-email { cursor: pointer; touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
.kreq-dim { color: var(--label2); }
.kreq-acts { display: flex; flex-direction: column; gap: 10px; margin: 20px 16px 24px; }
.kreq-g { margin-top: 8px; }
.kreq-btn { min-height: 50px; border: 0; border-radius: 12px; background: #2C2C2E; color: var(--accent); font: inherit; font-size: 17px; font-weight: 600; cursor: pointer; touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
.kreq-btn.primary { background: var(--accent); color: #FFFFFF; }
.kreq-btn.danger { background: #2C2C2E; color: #FF453A; }
.kreq-btn:disabled { color: var(--label2); cursor: default; }
.kreq-btn:active:not(:disabled) { filter: brightness(1.15); }
html.light .kreq-btn, html.light .kreq-btn.danger, html.light .kreq-av { background: #FFFFFF; }
html.light .kreq-av { color: #000000; }
