/* DateNight – Abend-Thema */
:root {
  --bg: #0e0c13;
  --bg-2: #14111b;
  --surface: #1a1622;
  --surface-2: #211b2c;
  --surface-3: #2b2438;
  --line: rgba(255, 255, 255, .07);
  --line-strong: rgba(255, 255, 255, .15);
  --text: #f4efe6;
  --muted: #a89fb3;
  --faint: #6f677c;
  --gold: #e2b76a;
  --gold-2: #f0d39a;
  --rose: #e8a0a0;
  --wax: #a5303f;
  --wax-2: #d24a5c;
  --ok: #8fd3a5;
  --warn: #f0b36b;
  --bad: #f08080;
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 24px 60px -30px rgba(0, 0, 0, .8), 0 1px 0 rgba(255, 255, 255, .04) inset;
  --display: "Fraunces", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --side: 264px;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--text); font-family: var(--body); font-size: 15px; line-height: 1.5;
  min-height: 100dvh; -webkit-font-smoothing: antialiased;
  background-image: radial-gradient(1000px 500px at 70% -10%, rgba(226, 183, 106, .10), transparent 60%),
                    radial-gradient(700px 500px at 0% 100%, rgba(165, 48, 63, .10), transparent 60%);
  background-attachment: fixed;
}
a { color: var(--gold-2); text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
::selection { background: rgba(226, 183, 106, .35); }
[hidden] { display: none !important; }
svg.i { width: 1.15em; height: 1.15em; vertical-align: -.2em; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex: none; }

h1, h2, h3 { font-family: var(--display); font-weight: 500; letter-spacing: -.01em; margin: 0; line-height: 1.15; }
h1 { font-size: 2rem; }
h2 { font-size: 1.4rem; }
h3 { font-size: 1.1rem; }
.serif { font-family: var(--display); }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.small { font-size: .85rem; }
.tiny { font-size: .72rem; letter-spacing: .06em; text-transform: uppercase; }
.center { text-align: center; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.row.nowrap { flex-wrap: nowrap; }
.row.between { justify-content: space-between; }
.stack { display: grid; gap: 12px; }
.grow { flex: 1; min-width: 0; }
.mt { margin-top: 16px; }
.mb { margin-bottom: 16px; }
.ellipsis { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* Boot */
.boot { min-height: 80dvh; display: grid; place-items: center; align-content: center; gap: 18px; color: var(--muted); }
.boot-seal { width: 54px; height: 54px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, var(--wax-2), var(--wax) 60%, #6b1c28);
  box-shadow: 0 8px 24px -6px rgba(165, 48, 63, .8); animation: pulse 1.6s ease-in-out infinite; }
@keyframes pulse { 0%, 100% { transform: scale(1); opacity: .85 } 50% { transform: scale(1.08); opacity: 1 } }

/* ── Layout ── */
.app { min-height: 100dvh; }
.main { padding: 0 16px calc(90px + env(safe-area-inset-bottom, 0px)); padding-top: env(safe-area-inset-top, 0px); max-width: 1180px; margin: 0 auto; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 0 10px; }
.topbar .pagetitle { display: none; }
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--display); font-size: 1.35rem; font-weight: 600; letter-spacing: -.02em; color: var(--text); }
.brand .mark { width: 30px; height: 30px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, var(--wax-2), var(--wax) 60%, #6b1c28);
  box-shadow: 0 6px 16px -4px rgba(165, 48, 63, .8); position: relative; flex: none; }
.brand .mark::after { content: ""; position: absolute; inset: 8px; border-radius: 50%; border: 1.5px solid rgba(255, 255, 255, .35); }
.avatars { display: flex; }
.avatar { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-size: 15px; border: 2px solid var(--bg);
  background: var(--surface-3); box-shadow: 0 0 0 1.5px var(--c, var(--gold)); flex: none; }
.avatar.sm { width: 22px; height: 22px; font-size: 11px; border-width: 1px; }
.avatar.lg { width: 56px; height: 56px; font-size: 26px; }
.avatar.xl { width: 84px; height: 84px; font-size: 38px; }
.avatar img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; display: block; }
.avatar { overflow: hidden; }
.avatars .avatar + .avatar { margin-left: -8px; }

/* Navigation: Tabs (mobil) / Sidebar (Desktop) */
.side { position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; display: flex; justify-content: space-around;
  background: rgba(16, 13, 21, .88); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); border-top: 1px solid var(--line);
  padding: 6px 6px calc(6px + env(safe-area-inset-bottom, 0px)); }
.side .sbrand, .side .couple { display: none; }
.side a.nav { display: grid; justify-items: center; gap: 3px; color: var(--faint); font-size: .66rem; letter-spacing: .03em; padding: 6px 10px; border-radius: 12px; min-width: 58px; }
.side a.nav svg.i { width: 22px; height: 22px; }
.side a.nav.active { color: var(--gold-2); }

@media (min-width: 960px) {
  .main { margin-left: var(--side); padding: 0 40px 48px; max-width: none; }
  .content { max-width: 1120px; }
  .topbar { padding: 26px 0 18px; }
  .topbar .brand { display: none; }
  .topbar .pagetitle { display: block; font-family: var(--display); font-style: italic; font-weight: 400; font-size: 1.7rem; }
  .side { left: 0; right: auto; top: 0; bottom: 0; width: var(--side); flex-direction: column; justify-content: flex-start; gap: 4px; padding: 28px 18px;
    border-top: 0; border-right: 1px solid var(--line); background: linear-gradient(180deg, #14111b, #0f0c14); backdrop-filter: none; }
  .side .sbrand { display: flex; margin: 0 8px 26px; font-size: 1.5rem; }
  .side .sbrand .mark { width: 34px; height: 34px; }
  .side a.nav { grid-template-columns: 24px 1fr; justify-items: start; align-items: center; font-size: .95rem; letter-spacing: 0; padding: 11px 14px; width: 100%; border-radius: 12px; color: var(--muted); position: relative; }
  .side a.nav:hover { color: var(--text); background: rgba(255, 255, 255, .04); }
  .side a.nav.active { background: linear-gradient(90deg, rgba(226, 183, 106, .16), rgba(226, 183, 106, .04)); color: var(--gold-2); }
  .side a.nav.active::before { content: ""; position: absolute; left: 0; top: 10px; bottom: 10px; width: 3px; border-radius: 3px; background: var(--gold); }
  .side .couple { display: block; margin-top: auto; padding: 16px; border-radius: 16px; background: rgba(255, 255, 255, .03); border: 1px solid var(--line); }
  .side .couple .who { display: flex; align-items: center; gap: 10px; padding: 4px 0; }
  .side .couple .who b { font-weight: 500; }
  .side .couple .who span.small { display: block; color: var(--faint); }
}

/* Zweispaltig auf Desktop */
.cols { display: grid; gap: 18px; }
@media (min-width: 960px) { .cols { grid-template-columns: minmax(0, 1fr) 340px; align-items: start; } .cols > aside { position: sticky; top: 24px; } .cols.wide { grid-template-columns: minmax(0, 1fr) 400px; } .cols.even { grid-template-columns: 1fr 1fr; } }

/* Cards */
.card { background: linear-gradient(180deg, var(--surface-2), var(--surface)); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.card.flat { box-shadow: none; background: var(--surface); }
.card.tight { padding: 16px; }
.section { margin-top: 24px; }
.section:first-child { margin-top: 0; }
.section-title { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.section-title h2 { font-style: italic; font-weight: 400; }
.eyebrow { font-size: .7rem; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); font-weight: 600; }

/* Hero */
.hero { position: relative; overflow: hidden; padding: 28px 26px; border-radius: 24px; border: 1px solid rgba(226, 183, 106, .22);
  background: radial-gradient(700px 300px at 15% 0%, rgba(226, 183, 106, .16), transparent 60%), radial-gradient(400px 300px at 100% 100%, rgba(165, 48, 63, .18), transparent 60%), linear-gradient(160deg, #2a2034, #171220 70%); box-shadow: var(--shadow); }
.hero h1 { font-size: clamp(1.6rem, 4vw, 2.3rem); font-style: italic; font-weight: 400; max-width: 20ch; }
.hero .when { font-family: var(--display); font-size: 1.05rem; color: var(--gold-2); margin-top: 4px; }
.hero .ornament { position: absolute; right: -40px; top: -40px; width: 230px; height: 230px; opacity: .16; pointer-events: none; }
.countdown { display: flex; gap: 8px; margin-top: 18px; }
.countdown .u { background: rgba(0, 0, 0, .28); border: 1px solid var(--line); border-radius: 12px; padding: 8px 0; flex: 1; max-width: 80px; text-align: center; }
.countdown .u b { display: block; font-family: var(--display); font-size: 1.6rem; font-weight: 500; line-height: 1; color: var(--gold-2); font-variant-numeric: tabular-nums; }
.countdown .u span { font-size: .62rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }

/* Wachssiegel */
.seal { width: 74px; height: 74px; border-radius: 50%; position: relative; flex: none;
  background: radial-gradient(circle at 35% 30%, var(--wax-2), var(--wax) 55%, #5e1622 100%);
  box-shadow: 0 10px 26px -8px rgba(165, 48, 63, .9), inset 0 -3px 8px rgba(0, 0, 0, .35), inset 0 2px 4px rgba(255, 255, 255, .2); }
.seal::before { content: ""; position: absolute; inset: 9px; border-radius: 50%; border: 1.5px solid rgba(255, 255, 255, .35); }
.seal::after { content: "♥"; position: absolute; inset: 0; display: grid; place-items: center; color: rgba(255, 230, 230, .85); font-size: 26px; font-family: var(--display); }
.seal.sm { width: 44px; height: 44px; } .seal.sm::after { font-size: 16px; } .seal.sm::before { inset: 6px; }
.seal.broken { background: radial-gradient(circle at 35% 30%, #6d6470, #4a4352 60%, #2b2731); box-shadow: none; }
.seal.broken::after { content: "✓"; color: var(--ok); }
.seal.dim { opacity: .35; }

/* Timeline */
.timeline { display: grid; gap: 8px; }
.dcard { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 10px 12px 10px 10px; border-radius: 14px; border: 1px solid var(--line);
  background: var(--surface); transition: transform .15s, border-color .15s, background .15s; color: inherit; min-width: 0; }
.dcard:hover { transform: translateY(-1px); border-color: var(--line-strong); background: var(--surface-2); }
.dcard.past { opacity: .7; }
.dcard .day { text-align: center; line-height: 1; background: rgba(0, 0, 0, .25); border-radius: 10px; padding: 8px 0; border: 1px solid var(--line); }
.dcard .day b { display: block; font-family: var(--display); font-size: 1.35rem; font-weight: 500; }
.dcard .day span { font-size: .6rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.dcard .title { font-family: var(--display); font-size: 1.05rem; line-height: 1.25; }
.dcard .sub { color: var(--muted); font-size: .82rem; display: flex; gap: 6px; align-items: center; min-width: 0; margin-top: 2px; }
.dcard .sub > span:last-child { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dcard.sealed { border-color: rgba(165, 48, 63, .35); background: linear-gradient(90deg, rgba(165, 48, 63, .10), var(--surface) 60%); }
.dcard.sealed .day { border-color: rgba(210, 74, 92, .4); }
.dcard.open.mine { border-style: dashed; border-color: rgba(226, 183, 106, .4); }
.dcard.revealed { background: linear-gradient(90deg, rgba(143, 211, 165, .07), var(--surface) 60%); }
.state { font-size: .64rem; letter-spacing: .08em; text-transform: uppercase; padding: 4px 8px; border-radius: 999px; border: 1px solid var(--line-strong); color: var(--muted); white-space: nowrap; }
.state.sealed { color: #f5b7bf; border-color: rgba(210, 74, 92, .5); background: rgba(165, 48, 63, .15); }
.state.todo { color: var(--gold-2); border-color: rgba(226, 183, 106, .5); background: rgba(226, 183, 106, .1); }
.state.revealed { color: var(--ok); border-color: rgba(143, 211, 165, .4); background: rgba(143, 211, 165, .08); }
.month-sep { margin: 12px 0 2px; font-family: var(--display); font-style: italic; color: var(--muted); display: flex; align-items: center; gap: 12px; font-size: .95rem; }
.month-sep:first-child { margin-top: 0; }
.month-sep::after { content: ""; flex: 1; height: 1px; background: var(--line); }
@media (min-width: 1200px) { .timeline.grid2col { grid-template-columns: 1fr 1fr; } .timeline.grid2col .month-sep { grid-column: 1 / -1; } }

/* Buttons & Forms */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 18px; border-radius: 999px; border: 1px solid var(--line-strong);
  background: var(--surface-3); color: var(--text); cursor: pointer; font-weight: 500; transition: .15s; white-space: nowrap; }
.btn:hover { border-color: rgba(255, 255, 255, .3); transform: translateY(-1px); }
.btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.btn.primary { background: linear-gradient(135deg, var(--gold-2), var(--gold)); color: #2a1f0a; border-color: transparent; box-shadow: 0 10px 24px -10px rgba(226, 183, 106, .8); }
.btn.wax { background: linear-gradient(135deg, var(--wax-2), var(--wax)); color: #fff; border-color: transparent; box-shadow: 0 10px 24px -10px rgba(165, 48, 63, .9); }
.btn.ghost { background: transparent; }
.btn.danger { color: var(--bad); border-color: rgba(240, 128, 128, .35); background: transparent; }
.btn.sm { padding: 6px 12px; font-size: .84rem; }
.btn.block { width: 100%; }
.btn .spin { width: 14px; height: 14px; border: 2px solid rgba(0, 0, 0, .25); border-top-color: currentColor; border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg) } }
.iconbtn { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line-strong); background: transparent; color: var(--muted); cursor: pointer; display: grid; place-items: center; flex: none; }
.iconbtn:hover { color: var(--bad); border-color: rgba(240, 128, 128, .4); }

label.f { display: grid; gap: 6px; font-size: .8rem; color: var(--muted); min-width: 0; }
label.f > span { letter-spacing: .03em; }

/* Eingabefelder – identisch auf iOS Safari, Android Chrome und Desktop */
.input, textarea.input, select.input {
  -webkit-appearance: none; appearance: none; margin: 0; box-shadow: none;
  display: block; width: 100%; min-width: 0; min-height: 46px; padding: 10px 13px; line-height: 1.4;
  font-family: var(--body); font-size: 16px; /* ≥16px: kein Auto-Zoom auf iOS */
  border-radius: var(--radius-sm); border: 1px solid var(--line-strong); background: rgba(0, 0, 0, .25); color: var(--text);
  outline: none; transition: border-color .15s, box-shadow .15s; -webkit-tap-highlight-color: transparent; }
.input:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(226, 183, 106, .15); }
.input::placeholder { color: var(--faint); opacity: 1; }
.input:disabled { opacity: .6; -webkit-text-fill-color: var(--muted); }
textarea.input { min-height: 110px; resize: vertical; }
select.input { padding-right: 38px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23a89fb3' stroke-width='2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; background-size: 16px; }
select.input option { background: #1f1929; color: var(--text); }
/* Datum/Zeit: iOS rendert diese als Inline-Flex mit eigener Höhe */
input[type="date"].input, input[type="time"].input, input[type="datetime-local"].input { display: flex; align-items: center; text-align: left; }
input::-webkit-date-and-time-value { text-align: left; min-height: 1.4em; margin: 0; }
input::-webkit-datetime-edit { padding: 0; }
input::-webkit-calendar-picker-indicator { filter: invert(.75) sepia(.3); opacity: .8; cursor: pointer; }
/* Zahlen: keine Spinner */
input[type="number"].input { -moz-appearance: textfield; }
input[type="number"].input::-webkit-inner-spin-button, input[type="number"].input::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
/* Autofill (Chrome/Safari) nicht gelb/weiss */
input:-webkit-autofill, input:-webkit-autofill:hover, input:-webkit-autofill:focus {
  -webkit-text-fill-color: var(--text); -webkit-box-shadow: 0 0 0 1000px #1c1826 inset; caret-color: var(--text); transition: background-color 99999s ease-out 0s; }
/* Passwort-Felder: Safari-Schlüssel-Icon braucht Platz */
input[type="password"].input { letter-spacing: .08em; }
input[type="search"]::-webkit-search-decoration { -webkit-appearance: none; }
button, .btn, .chip, .iconbtn { -webkit-appearance: none; appearance: none; -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.grid3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; }
@media (max-width: 560px) { .grid2, .grid3 { grid-template-columns: 1fr; } }
input[type="checkbox"] { -webkit-appearance: none; appearance: none; width: 20px; height: 20px; margin: 0; border-radius: 6px; border: 1.5px solid var(--line-strong); background: rgba(0, 0, 0, .25); display: inline-grid; place-items: center; flex: none; cursor: pointer; }
input[type="checkbox"]::before { content: ""; width: 10px; height: 10px; border-radius: 2px; background: var(--gold); transform: scale(0); transition: transform .12s; }
input[type="checkbox"]:checked { border-color: var(--gold); }
input[type="checkbox"]:checked::before { transform: scale(1); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { padding: 7px 12px; border-radius: 999px; border: 1px solid var(--line-strong); background: transparent; cursor: pointer; font-size: .86rem; color: var(--muted); transition: .15s; }
.chip.on { background: rgba(226, 183, 106, .15); border-color: var(--gold); color: var(--gold-2); }
.chip.static { cursor: default; }
.chip.static.on { background: var(--surface-3); border-color: var(--line-strong); color: var(--text); }

.stars { display: inline-flex; gap: 2px; }
.stars button, .stars span { background: none; border: 0; cursor: pointer; font-size: 24px; color: var(--faint); padding: 0 1px; line-height: 1; }
.stars .on { color: var(--gold); }
.stars.ro span { font-size: 16px; cursor: default; }

/* Regeln */
.rule { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: .93rem; }
.rule:last-child { border-bottom: 0; padding-bottom: 0; }
.rule:first-child { padding-top: 0; }
.rule b.num { font-family: var(--display); font-size: 1.15rem; font-weight: 500; }
.meter { height: 5px; background: rgba(255, 255, 255, .08); border-radius: 999px; overflow: hidden; margin-top: 7px; }
.meter i { display: block; height: 100%; background: linear-gradient(90deg, var(--gold), var(--gold-2)); border-radius: 999px; transition: width .4s; }
.meter i.bad { background: linear-gradient(90deg, #c0392b, var(--bad)); }
.meter i.ok { background: linear-gradient(90deg, #4fa66f, var(--ok)); }
.rulecheck { display: flex; gap: 10px; align-items: flex-start; padding: 7px 0; font-size: .88rem; }
.rulecheck .dot { width: 9px; height: 9px; border-radius: 50%; margin-top: 7px; flex: none; }
.rulecheck.ok .dot { background: var(--ok); } .rulecheck.bad .dot { background: var(--bad); } .rulecheck.info .dot { background: var(--warn); }

/* Teaser / Regel-Zeilen */
.teaser { padding: 12px 14px; border-radius: var(--radius-sm); background: rgba(0, 0, 0, .22); border: 1px dashed var(--line-strong); display: grid; gap: 4px; }
.teaser.locked { opacity: .55; }
.teaser .t { font-family: var(--display); font-style: italic; font-size: 1.05rem; }
.rulerow { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1.5fr) 84px 36px; gap: 10px; align-items: end; padding: 12px; border-radius: var(--radius-sm); background: rgba(0, 0, 0, .2); border: 1px solid var(--line); }
@media (max-width: 640px) { .rulerow { grid-template-columns: minmax(0, 1fr) 90px 36px; grid-template-areas: "type type rm" "tag val val"; } .rulerow .r-type { grid-area: type; } .rulerow .r-tag { grid-area: tag; } .rulerow .r-val { grid-area: val; } .rulerow .r-rm { grid-area: rm; align-self: end; } }
.tagrow { display: grid; grid-template-columns: 60px minmax(0, 1fr) 36px; gap: 8px; align-items: center; }
.taggrid { display: grid; gap: 8px; }
@media (min-width: 720px) { .taggrid { grid-template-columns: 1fr 1fr; } }

/* Detail */
.plan h1 { font-style: italic; font-weight: 400; font-size: clamp(1.7rem, 4vw, 2.4rem); }
.kv { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 8px 18px; font-size: .95rem; margin: 0; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; }
.envelope-wrap { display: grid; place-items: center; gap: 14px; padding: 26px 10px 20px; text-align: center; }
.envelope-wrap p { color: var(--muted); max-width: 36ch; margin: 0; }
.envelope-wrap .countdown { justify-content: center; width: 100%; max-width: 360px; }
.backlink { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: .88rem; }
.backlink:hover { color: var(--text); }

/* Divers */
.banner { padding: 12px 16px; border-radius: var(--radius-sm); border: 1px solid rgba(226, 183, 106, .35); background: rgba(226, 183, 106, .08); display: flex; gap: 12px; align-items: center; flex-wrap: wrap; font-size: .92rem; }
.banner.rose { border-color: rgba(232, 160, 160, .35); background: rgba(232, 160, 160, .08); }
.stat { text-align: center; padding: 14px 8px; border-radius: var(--radius-sm); background: rgba(0, 0, 0, .2); border: 1px solid var(--line); }
.stat b { display: block; font-family: var(--display); font-size: 1.7rem; font-weight: 500; color: var(--gold-2); line-height: 1.1; }
.stat span { font-size: .66rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 640px) { .stats { grid-template-columns: repeat(4, 1fr); } .stats.three { grid-template-columns: repeat(3, 1fr); } }
.toast { position: fixed; left: 50%; bottom: calc(86px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); background: #2f2740; color: var(--text); padding: 12px 18px;
  border-radius: 999px; border: 1px solid var(--line-strong); box-shadow: var(--shadow); z-index: 50; max-width: 90vw; font-size: .9rem; animation: up .25s ease-out; }
.toast.err { border-color: rgba(240, 128, 128, .5); }
@media (min-width: 960px) { .toast { bottom: 30px; left: calc(50% + var(--side) / 2); } }
@keyframes up { from { opacity: 0; transform: translate(-50%, 10px) } to { opacity: 1; transform: translate(-50%, 0) } }
.fade { animation: fade .3s ease-out; }
@keyframes fade { from { opacity: 0; transform: translateY(6px) } to { opacity: 1; transform: none } }
.auth { max-width: 440px; margin: 8vh auto 40px; padding: 0 16px; }
.auth .brand { justify-content: center; font-size: 2rem; margin-bottom: 8px; }
.auth .brand .mark { width: 44px; height: 44px; }
.divider { height: 1px; background: var(--line); margin: 16px 0; }
.help { font-size: .84rem; color: var(--muted); line-height: 1.6; padding-left: 18px; margin: 0; }
.help li { margin-bottom: 8px; }
.help b { color: var(--text); font-weight: 600; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .85em; background: rgba(0, 0, 0, .3); padding: 2px 6px; border-radius: 6px; }
.pill-list { display: grid; gap: 8px; }
.idea { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: var(--radius-sm); background: rgba(0, 0, 0, .2); border: 1px solid var(--line); }
.lockrow { display: inline-flex; align-items: center; gap: 8px; font-size: .8rem; color: var(--muted); }
.swatches { display: flex; gap: 8px; flex-wrap: wrap; }
.swatch { width: 28px; height: 28px; border-radius: 50%; border: 2px solid transparent; cursor: pointer; }
.swatch.on { border-color: #fff; }
.confirm { position: fixed; inset: 0; z-index: 60; background: rgba(0, 0, 0, .6); display: grid; place-items: center; padding: 20px; backdrop-filter: blur(6px); }
.confirm .card { max-width: 440px; width: 100%; }
.todo-list { display: grid; gap: 6px; }
.todo-list a { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 10px; color: var(--text); font-size: .9rem; background: rgba(0, 0, 0, .18); border: 1px solid var(--line); }
.todo-list a:hover { border-color: rgba(226, 183, 106, .4); }
.todo-list .d { font-family: var(--display); color: var(--gold-2); min-width: 52px; }
.empty { padding: 34px 20px; text-align: center; color: var(--muted); border: 1px dashed var(--line-strong); border-radius: var(--radius); }
.empty .seal { margin: 0 auto 12px; }
.sticky-actions { display: grid; gap: 10px; }
.sticky-actions .btn { width: 100%; }

@media (max-width: 959px) { .cols.home > aside { order: -1; } .hide-m { display: none !important; } }
