:root {
  color-scheme: light;
  --canvas:#f3ede2; --surface:#fffaf1; --ink:#24313b; --muted:#887c6b;
  --line:#e3d8c7; --accent:#b55740; --soft:#f0ded0; --gold:#ad803a;
  --green:#356447; --green-soft:#e0eddf; --green-line:#afc9ac;
  --top:env(safe-area-inset-top,0px); --bottom:env(safe-area-inset-bottom,0px);
  font-family:-apple-system,BlinkMacSystemFont,"PingFang SC",sans-serif;
  font-size:15px; -webkit-text-size-adjust:100%;
}
* {box-sizing:border-box}
body {margin:0;background:var(--canvas);color:var(--ink);-webkit-tap-highlight-color:transparent}
button,input,textarea,select {font:inherit;color:inherit}
button {border:0;background:none;cursor:pointer;touch-action:manipulation}
button:focus-visible,input:focus-visible,textarea:focus-visible {outline:2px solid var(--accent);outline-offset:3px}
button:active {transform:scale(.98)}
button:disabled {opacity:.38;cursor:default}
svg {width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round;flex-shrink:0}
.app-shell {min-height:100dvh;max-width:480px;margin:auto;position:relative}
header {padding:calc(var(--top) + 20px) 24px 0}
.brand-line {display:flex;align-items:center;justify-content:space-between;margin-bottom:24px}
.brand {font-family:"Iowan Old Style",Georgia,serif;font-size:25px;font-weight:600;letter-spacing:-1px}
.brand b {color:var(--accent);font-weight:600}
.preview-tag {font-size:10px;font-weight:500;letter-spacing:1.6px;color:var(--muted);margin-left:12px;padding-left:12px;border-left:1px solid var(--line)}
.brand-group {display:flex;align-items:center}
.icon-button {display:grid;place-items:center;width:44px;height:44px;border-radius:50%;color:var(--muted);flex-shrink:0}
.icon-button.surface {background:var(--surface);border:1px solid var(--line)}
.date-line {color:var(--accent);font-size:12px;font-weight:600;letter-spacing:1px;display:flex;align-items:center;gap:7px;margin-bottom:12px}
.date-line svg {width:14px;height:14px}
.heading-row {display:flex;align-items:center;justify-content:space-between;gap:8px}
h1 {font-family:"Songti SC","STSong","Iowan Old Style",serif;font-size:32px;font-weight:600;margin:0;letter-spacing:.4px;line-height:1.25}
.subtitle {font-size:12px;line-height:1.7;color:var(--muted);margin:12px 0 0}
.add-button {width:44px;height:44px;border-radius:14px;background:var(--accent);color:#fff;display:grid;place-items:center;box-shadow:0 5px 12px #b5574015}
main {padding:24px 24px calc(170px + var(--bottom))}
.section-heading {display:flex;justify-content:space-between;align-items:center;margin:26px 0 13px}
.section-heading:first-child {margin-top:0}
h2 {font-size:15px;font-weight:600;margin:0}
.quiet-label {font-size:11px;color:var(--muted)}
.progress-summary {display:flex;align-items:center;justify-content:space-between;margin-bottom:20px}
.progress-copy {font-size:12px;color:var(--muted)}
.progress-copy strong {font-size:21px;font-weight:600;color:var(--ink);margin-right:5px;font-variant-numeric:tabular-nums}
.card {position:relative;padding:19px 18px 15px;margin-bottom:14px;background:var(--surface);border:1px solid var(--line);border-radius:21px;box-shadow:0 4px 16px #473d2805}
.card.done {background:var(--green-soft);border-color:var(--green-line)}
.card.done h3 {color:var(--green)}
.card-top {display:flex;align-items:center;justify-content:space-between;gap:8px;min-height:23px}
.metadata {display:flex;align-items:center;gap:7px;font-size:10px;color:var(--muted);flex-wrap:wrap}
.metadata svg {width:13px;height:13px}
.tag {background:var(--soft);color:var(--accent);padding:3px 6px;border-radius:5px;font-size:9px;letter-spacing:.5px}
.done .tag {background:#cde0cc;color:var(--green)}
.star {position:absolute;right:8px;top:6px;width:44px;height:44px;color:#b0a38f;display:grid;place-items:center}
.star svg {width:20px;height:20px}
.star.selected {color:var(--gold)}
.star.selected svg {fill:var(--gold);stroke:var(--gold)}
.card-top .metadata {padding-right:27px}
.card h3 {font-size:20px;font-weight:600;margin:13px 0 9px;line-height:1.35;letter-spacing:.3px}
.detail-line {font-size:12px;color:var(--muted);display:flex;align-items:center;gap:8px;min-height:20px}
.detail-line svg {width:14px;height:14px}
.track {height:4px;background:var(--line);border-radius:10px;overflow:hidden;flex:1;max-width:168px}
.track span {display:block;height:100%;background:var(--accent);border-radius:10px;transition:width .2s}
.done .track span {background:var(--green)}
.card-actions {display:flex;align-items:center;gap:10px;margin-top:16px;padding-top:13px;border-top:1px solid var(--line)}
.done .card-actions {border-color:#c2d6be}
.primary {background:var(--accent);color:white;border-radius:11px;min-height:44px;display:flex;align-items:center;justify-content:center;gap:7px;font-size:13px;font-weight:600;padding:10px 17px}
.primary svg {width:17px;height:17px}
.card-actions .primary,.card-actions .status {flex:1}
.status {background:var(--green);color:white;border-radius:11px;min-height:44px;display:flex;align-items:center;justify-content:center;gap:7px;font-size:13px;font-weight:500}
.status svg {width:17px;height:17px}
.text-button {font-size:12px;min-height:44px;color:var(--muted);padding:8px 2px;display:flex;align-items:center;gap:4px}
.text-button svg {width:14px;height:14px}
.undo {color:var(--green);padding:8px 7px}
.card-back {padding-top:0}
.card-back h3 {font-size:18px;margin-top:0}
.back-header {display:flex;align-items:center;justify-content:space-between}
.back-detail {display:flex;align-items:center;justify-content:space-between;padding:11px 0;border-bottom:1px solid var(--line);font-size:12px}
.back-detail span:first-child {color:var(--muted)}
.secondary {display:flex;align-items:center;justify-content:center;gap:6px;padding:11px 14px;min-height:44px;border:1px solid var(--line);border-radius:11px;color:var(--muted);font-size:12px;background:var(--surface)}
.card-back .secondary {width:100%;margin-top:15px}
.journal-card {padding:18px;border-radius:18px;border:1px solid var(--line);background:linear-gradient(135deg,#fffaf1,#f9f0e3);margin-top:5px;cursor:pointer}
.journal-top {display:flex;justify-content:space-between;align-items:center;margin-bottom:12px}
.journal-top svg {color:var(--accent);width:18px;height:18px}
.journal-card p {font-family:"Songti SC",serif;color:var(--muted);font-size:15px;line-height:1.7;margin:0;white-space:pre-wrap}
.journal-rule {border-top:1px solid var(--line);margin-top:15px;width:100%}
.journal-rule.short {width:68%;margin-top:16px}
.mini-date {display:flex;align-items:center;justify-content:space-between;padding:15px 0;border-top:1px solid var(--line);margin-top:25px}
.mini-date h3 {font-size:12px;font-weight:500;margin:0 0 4px}
.mini-date span {font-size:10px;color:var(--muted)}
.days-count {font-family:Georgia,serif;font-size:26px;color:var(--accent)}
.days-count small {font-family:-apple-system,sans-serif;font-size:10px;color:var(--muted);margin-left:3px}
nav {position:fixed;z-index:10;bottom:0;left:50%;transform:translateX(-50%);width:min(100%,480px);padding:9px 12px calc(var(--bottom) + 10px);display:flex;justify-content:space-around;background:#f9f3e9f5;border-top:1px solid var(--line);backdrop-filter:blur(20px);-webkit-backdrop-filter:blur(20px)}
.tab {display:flex;align-items:center;flex-direction:column;gap:5px;width:25%;min-height:46px;color:#998c79;font-size:10px}
.tab svg {height:22px;width:22px}
.tab.active {color:var(--accent);font-weight:600}
.tab.active svg {stroke-width:2}
#switcher {position:fixed;left:50%;bottom:calc(var(--bottom) + 77px);transform:translateX(-50%);z-index:15;display:flex;align-items:center;gap:8px;background:#27343af2;color:#fff;border-radius:50px;padding:2px 6px;box-shadow:0 6px 20px #20282a26;border:1px solid #ffffff1a;backdrop-filter:blur(16px)}
#switcher button {width:40px;height:40px;color:#fff;display:grid;place-items:center}
#switcher svg {height:16px;width:16px}
.variant-label {font-size:11px;letter-spacing:.4px;min-width:114px;text-align:center;white-space:nowrap}
.variant-label small {opacity:.5;font-size:9px;margin-right:7px}
.filters {display:flex;gap:7px;margin:0 0 23px;overflow:auto;padding-bottom:2px;scrollbar-width:none}
.filter {white-space:nowrap;font-size:12px;min-height:38px;padding:8px 15px;border-radius:50px;color:var(--muted);border:1px solid var(--line)}
.filter.active {background:var(--ink);color:var(--surface);border-color:var(--ink)}
.warehouse-group {margin-bottom:26px}
.warehouse-group .section-heading {margin-top:0}
.type-heading {display:flex;align-items:center;gap:8px}
.type-heading svg {width:16px;height:16px;color:var(--accent)}
.group-count {font-size:11px;color:var(--muted);font-weight:400;margin-left:6px}
.warehouse-row {display:flex;align-items:center;gap:14px;padding:16px;background:var(--surface);border:1px solid var(--line);border-radius:15px;margin-bottom:9px}
.warehouse-row .row-copy {flex:1;min-width:0}
.row-copy h3 {font-size:15px;font-weight:500;line-height:1.4;margin:0 0 7px}
.row-copy .metadata {font-size:10px}
.round-add {width:44px;height:44px;display:grid;place-items:center;color:var(--accent);background:var(--soft);border-radius:50%;flex-shrink:0}
.round-add svg {width:18px;height:18px}
.round-add.added {background:var(--green-soft);color:var(--green)}
.search-box {display:flex;align-items:center;background:#e9e1d5;border-radius:13px;padding:11px 13px;margin-bottom:17px;gap:8px;color:var(--muted)}
.search-box svg {width:17px;height:17px}
.search-box input {border:0;background:none;outline:none;width:100%;font-size:13px;min-height:24px}
.date-card {padding:24px 20px;margin-bottom:15px;position:relative;border-radius:20px;border:1px solid var(--line);background:var(--surface);overflow:hidden}
.date-card.featured {background:var(--ink);color:var(--surface);border-color:var(--ink)}
.date-card .eyebrow {font-size:10px;letter-spacing:1.2px;color:var(--muted)}
.date-card.featured .eyebrow {color:#b9b1a5}
.date-card h3 {font-family:"Songti SC",serif;font-size:23px;margin:13px 0 10px;font-weight:500}
.date-card p {font-size:11px;color:var(--muted);margin:0}
.date-card.featured p {color:#b9b1a5}
.date-card .count {font-family:Georgia,serif;font-size:56px;line-height:1;margin:22px 0 4px;color:var(--accent)}
.date-card.featured .count {color:#e7ba90}
.date-card .count small {font-family:-apple-system,sans-serif;font-size:12px;margin-left:7px;font-weight:400}
.date-decoration {position:absolute;right:-18px;top:45px;width:150px;height:150px;border-radius:50%;border:1px solid #ffffff16}
.date-decoration:after {content:"";position:absolute;inset:20px;border-radius:50%;border:1px solid #ffffff16}
.date-row {display:flex;gap:18px;align-items:center;margin-bottom:14px;background:var(--surface);border:1px solid var(--line);border-radius:17px;padding:18px}
.date-tile {color:var(--accent);text-align:center;padding-right:17px;border-right:1px solid var(--line)}
.date-tile span {font-size:10px;display:block}
.date-tile strong {font:32px Georgia,serif;display:block;margin-top:3px}
.date-row h3 {font-size:15px;font-weight:500;margin:0 0 8px}
.date-row p {font-size:11px;color:var(--muted);margin:0}
.review-overview {display:flex;gap:12px;margin-bottom:23px}
.stat {background:var(--surface);border:1px solid var(--line);border-radius:17px;padding:20px 17px;flex:1}
.stat .number {font:37px Georgia,serif;margin-bottom:9px}
.stat span {font-size:11px;color:var(--muted)}
.chart {padding:20px 17px;background:var(--surface);border:1px solid var(--line);border-radius:20px}
.chart-header {display:flex;justify-content:space-between;align-items:center;margin-bottom:25px}
.bars {display:flex;align-items:flex-end;justify-content:space-between;gap:8px;height:128px}
.bar-col {display:flex;align-items:center;justify-content:flex-end;flex-direction:column;height:100%;width:12%}
.bar-num {font-size:10px;color:var(--muted);margin-bottom:6px}
.bar {width:100%;max-width:25px;background:var(--soft);border-radius:6px 6px 3px 3px;min-height:3px}
.bar.today {background:var(--accent)}
.bar-label {font-size:10px;color:var(--muted);margin-top:10px}
.category-line {display:flex;align-items:center;justify-content:space-between;font-size:12px;margin:18px 0}
.category-line span {display:flex;align-items:center;gap:8px}
.swatch {height:7px;width:7px;border-radius:50%;background:var(--accent)}
.swatch.life {background:#92a080}.swatch.study {background:#bfa573}
.timeline {border-left:1px solid var(--line);margin:21px 0 0 5px;padding-left:18px}
.timeline-item {position:relative;padding-bottom:20px}
.timeline-item:before {content:"";position:absolute;left:-22px;top:5px;width:7px;height:7px;border-radius:50%;background:var(--accent);box-shadow:0 0 0 4px var(--canvas)}
.timeline-item strong {font-size:12px;font-weight:500}
.timeline-item p {font-size:11px;color:var(--muted);margin:6px 0 0}
/* B differs in hierarchy: one large focus surface, then a quiet queue. */
.focus-hero {min-height:355px;background:var(--ink);color:var(--surface);border-radius:25px;padding:26px 23px;position:relative;overflow:hidden}
.focus-hero:after {content:"";position:absolute;width:260px;height:260px;border:1px solid #ffffff0c;border-radius:50%;right:-150px;top:45px;pointer-events:none}
.focus-hero .metadata {color:#b4afa4;padding-right:22px}
.focus-hero .tag {background:#ffffff12;color:#e7ba90}
.focus-hero .star {color:#a79b86;top:16px;right:14px}
.focus-hero .star.selected {color:#e7ba90}
.focus-hero h3 {font-family:"Songti SC",serif;font-size:34px;font-weight:500;line-height:1.45;margin:30px 0 20px;max-width:260px}
.focus-hero .detail-line {color:#b4afa4;display:block;font-size:12px;line-height:1.8}
.focus-hero .focus-progress {margin-top:17px;font-size:39px;font-family:Georgia,serif;color:#e7ba90}
.focus-hero .focus-progress small {font-family:-apple-system,sans-serif;color:#b4afa4;font-size:12px}
.focus-hero .primary {margin-top:26px;width:100%;background:#e7ba90;color:#2a3337;min-height:49px;border-radius:13px;position:relative;z-index:1}
.focus-hero .focus-sub {font-size:10px;color:#a79e8f;letter-spacing:1px;margin-top:17px}
.focus-next {display:flex;align-items:center;justify-content:space-between;margin:17px 0 0;width:100%;min-height:44px;color:#b4afa4;font-size:12px}
.focus-next .text-button {font-size:12px}
.focus-pager {display:flex;justify-content:center;gap:2px;margin-top:5px}
.focus-pager button {width:36px;height:36px;display:grid;place-items:center}
.focus-pager button:after {content:"";width:5px;height:5px;border-radius:50%;background:var(--line)}
.focus-pager button.active:after {background:var(--accent);width:15px;border-radius:5px}
.queue-title {flex:1;text-align:left;font-size:14px;min-height:44px;padding:0}
.queue-row {display:flex;align-items:center;gap:12px;padding:15px 0;border-bottom:1px solid var(--line);width:100%;text-align:left}
.queue-dot {width:44px;height:44px;border:1px solid var(--line);border-radius:50%;display:grid;place-items:center;color:var(--green);flex-shrink:0}
.queue-dot svg {width:13px;height:13px}
.queue-dot.done {background:var(--green-soft);border-color:var(--green-line)}
.queue-row .row-copy h3 {font-size:14px;margin-bottom:5px}
.queue-row .row-copy p {font-size:10px;color:var(--muted);margin:0}
/* C uses a dense paper list and leading action circles instead of cards. */
.ledger {border-top:1px solid var(--line);margin-top:2px}
.ledger-row {display:flex;align-items:center;gap:13px;padding:21px 0;border-bottom:1px solid var(--line);position:relative}
.ledger-action {width:44px;height:44px;display:grid;place-items:center;flex-shrink:0;color:var(--accent)}
.ledger-circle {width:29px;height:29px;display:grid;place-items:center;border:1.5px solid #c7b9a3;border-radius:50%}
.ledger-circle svg {width:15px;height:15px}
.ledger-row.done .ledger-circle {background:var(--green);border-color:var(--green);color:white}
.ledger-row .row-copy {flex:1;min-width:0}
.ledger-row .row-copy h3 {font-size:17px;margin:0 0 8px;font-weight:500}
.ledger-row.done .row-copy h3 {color:var(--green)}
.ledger-side {display:grid;place-items:center;width:44px;height:44px;flex-shrink:0;color:#b0a38f}
.ledger-side.selected {color:var(--gold)}
.ledger-side.selected svg {fill:var(--gold)}
.ledger-side .icon-button {height:34px;width:34px}
.ledger-side svg {width:16px;height:16px}
.ledger-status {font-size:10px;color:var(--accent);margin-top:3px;white-space:nowrap}
.ledger-row.done .ledger-status {color:var(--green)}
.ledger-row .undo {min-height:32px;font-size:10px;padding:4px}
.ledger-status button {min-height:32px;font-size:10px;color:var(--green);margin-left:7px;text-decoration:underline;text-underline-offset:3px}
.ledger-info {font-size:10px;color:var(--muted);display:flex;align-items:center;gap:6px;line-height:1.5}
.ledger-info .tag {font-size:9px;padding:2px 5px}
.list-note {margin-top:20px;font-size:11px;color:var(--muted);line-height:1.8}
.empty {padding:45px 15px;text-align:center;color:var(--muted);font-size:13px;line-height:1.8}
.empty svg {width:36px;height:36px;margin-bottom:13px;color:var(--green)}
.sheet-overlay {position:fixed;inset:0;background:#24313b55;backdrop-filter:blur(3px);z-index:30;display:flex;align-items:flex-end;justify-content:center}
.sheet {width:min(100%,480px);max-height:90dvh;overflow:auto;background:var(--canvas);border-radius:27px 27px 0 0;padding:11px 24px calc(22px + var(--bottom));box-shadow:0 -10px 40px #24313b14;overscroll-behavior:contain}
.sheet-handle {display:block;width:72px;height:28px;min-height:28px;border:0;padding:0;background:transparent;margin:0 auto 4px;touch-action:none;cursor:grab;flex-shrink:0}
.sheet-handle::before {content:"";display:block;width:36px;height:4px;border-radius:5px;background:#c7bcaa;margin:auto}
.sheet-handle.is-dragging {cursor:grabbing}
.sheet-heading {display:flex;align-items:center;justify-content:space-between;margin-bottom:6px;gap:8px}
.sheet h2 {font-size:22px;font-family:"Songti SC",serif;line-height:1.3}
.sheet-desc {font-size:12px;color:var(--muted);line-height:1.7;margin:0 0 22px}
.sheet .primary.full {width:100%;margin-top:23px;min-height:48px}
.sheet .warehouse-row {padding:15px 12px}
.sheet .row-copy h3 {font-size:14px}
.sheet-footer {font-size:10px;color:var(--muted);text-align:center;margin-top:13px;line-height:1.6}
.field-label {font-size:12px;color:var(--muted);display:block;margin:20px 0 9px}
.field {display:block;width:100%;margin:20px 0}
.field > span {font-size:12px;color:var(--muted);display:block;margin-bottom:9px}
.field input,.field textarea,.field select {border:1px solid var(--line);border-radius:12px;background:var(--surface);width:100%;padding:14px;min-height:48px;outline:0;font-size:16px}
.field textarea {min-height:225px;line-height:1.8;resize:none}
.type-pills {display:flex;gap:6px}
.type-pills button {flex:1;min-height:43px;border:1px solid var(--line);border-radius:10px;font-size:12px;color:var(--muted);padding:8px 3px}
.type-pills button.selected {background:var(--soft);color:var(--accent);border-color:#d5b9a2}
.settings-item {width:100%;display:flex;justify-content:space-between;align-items:center;min-height:58px;border-bottom:1px solid var(--line);font-size:13px;text-align:left}
.settings-item span {color:var(--muted);font-size:11px}
.settings-intro {padding:22px 0 16px;font-size:12px;color:var(--muted);line-height:1.8}
.settings-intro strong {display:block;color:var(--ink);font-family:Georgia,serif;font-size:25px;margin-bottom:8px}
.voice-sample {padding:24px 18px;border:1px solid var(--line);background:var(--surface);border-radius:18px;text-align:center;margin:20px 0}
.voice-sample svg {width:32px;height:32px;color:var(--accent);margin-bottom:10px}
.voice-sample p {font-size:16px;line-height:1.7;margin:0}
#toast {position:fixed;left:50%;bottom:calc(var(--bottom) + 140px);transform:translate(-50%,12px);padding:11px 18px;background:#24313bf2;color:white;font-size:12px;border-radius:50px;z-index:50;opacity:0;pointer-events:none;transition:opacity .16s,transform .16s;max-width:85%;white-space:nowrap}
#toast.visible {opacity:1;transform:translate(-50%,0)}
/* A revision: compact two-column cards, with two real faces kept in the DOM. */
body[data-variant="A"][data-page="today"] header {padding:calc(var(--top) + 8px) 18px 0}
body[data-variant="A"][data-page="today"] .brand-line {margin-bottom:8px}
body[data-variant="A"][data-page="today"] .brand {font-size:22px}
body[data-variant="A"][data-page="today"] .date-line {font-size:11px;margin-bottom:5px}
body[data-variant="A"][data-page="today"] h1 {font-size:28px}
body[data-variant="A"][data-page="today"] .subtitle {font-size:11px;margin-top:6px}
body[data-variant="A"][data-page="today"] main {padding:16px 18px calc(145px + var(--bottom))}
body[data-variant="A"][data-page="today"] .progress-summary {margin-bottom:12px}
body[data-variant="A"][data-page="today"] .progress-copy {font-size:11px}
body[data-variant="A"][data-page="today"] .progress-copy strong {font-size:18px}
.card-grid {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.card-grid .card {height:190px;padding:0;margin:0;border:0;background:none;box-shadow:none;border-radius:17px;perspective:1000px;min-width:0}
.card-grid .card-rotator {position:relative;width:100%;height:100%;transform-style:preserve-3d;transition:transform .38s cubic-bezier(.2,.7,.2,1)}
.card-grid .card.flipped .card-rotator {transform:rotateY(180deg)}
.card-grid .card-side {position:absolute;inset:0;padding:12px;border:1px solid var(--line);border-radius:17px;background:var(--surface);backface-visibility:hidden;-webkit-backface-visibility:hidden;display:flex;flex-direction:column;box-shadow:0 3px 12px #473d2805;overflow:hidden}
.card-grid .card.done .card-side {background:var(--green-soft);border-color:var(--green-line)}
.card-grid .card-back {transform:rotateY(180deg)}
.card-grid .card-front .card-top {min-height:21px}
.card-grid .metadata {gap:5px;font-size:9px}
.card-grid .metadata svg {width:12px;height:12px}
.card-grid .tag {font-size:9px;padding:2px 5px}
.card-grid .star {top:0;right:0;width:44px;height:44px}
.card-grid .star svg {width:17px;height:17px}
.card-grid .card-front h3 {font-size:17px;margin:8px 0 6px;line-height:1.35;min-height:45px;max-height:46px;overflow-wrap:anywhere;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;flex-shrink:0}
.card-grid .detail-line {font-size:11px;gap:6px;min-height:18px;line-height:1.5}
.card-grid .track {max-width:68px;min-width:15px}
.card-grid .detail-line span {flex-shrink:0}
.card-grid .card-actions {margin-top:auto;padding-top:8px;gap:4px}
.card-grid .primary {font-size:12px;min-height:44px;padding:8px 5px;gap:4px;border-radius:9px}
.card-grid .primary svg,.card-grid .status svg {width:14px;height:14px}
.card-grid .status {font-size:11px;min-height:44px;gap:4px;border-radius:9px}
.card-grid .undo {font-size:10px;padding:8px 2px;gap:2px;min-width:36px}
.card-grid .undo svg {width:11px;height:11px}
.card-grid .back-header {min-height:36px;gap:4px}
.card-grid .card-back h3 {font-size:14px;margin:0;line-height:1.3;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.card-grid .back-header .icon-button {width:36px;height:36px;margin-right:-7px;flex-shrink:0}
.card-grid .back-header .icon-button {width:44px;height:44px}
.card-grid .back-header svg {width:15px;height:15px}
.card-grid .back-detail {font-size:11px;padding:4px 0;min-height:24px;gap:5px}
.card-grid .card-back .secondary {margin-top:auto;min-height:44px;padding:8px;font-size:11px;border-radius:9px}
body[data-variant="A"][data-page="today"] .section-heading {margin:20px 0 10px}
body[data-variant="A"][data-page="today"] .journal-card {padding:15px;border-radius:16px}
body[data-variant="A"][data-page="today"] .journal-top {margin-bottom:8px}
body[data-variant="A"][data-page="today"] .journal-rule.short {display:none}
body[data-presentation="true"] #switcher {display:none}
body[data-presentation="true"][data-variant="A"][data-page="today"] main {padding-bottom:calc(100px + var(--bottom))}
/* Explicit simulated safe areas used only by the Mac review frame. */
body[data-preview-insets="true"] {--top:62px;--bottom:34px}
@media(max-width:350px) {.card-grid {grid-template-columns:1fr}.card-grid .card {height:185px}}
@media(min-width:600px) {body {background:#e2d8c9}.app-shell {box-shadow:0 0 70px #57462b18;background:var(--canvas)}}
@media(prefers-reduced-motion:reduce) {* {transition:none!important;scroll-behavior:auto!important}}
/* The back contains only its name and four direct actions. */
.card-grid .card .card-front>.metadata{padding-right:28px}
.card-grid .card .card-back{display:flex;flex-direction:column;gap:12px;padding:14px}
.card-grid .card .card-back>h3{margin:0;font-size:14px;line-height:1.4;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.card-grid .card .card-back .back-buttons{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin-top:auto}
.card-grid .card .card-back .back-buttons .secondary{margin:0;min-height:40px;padding:6px;font-size:11px;line-height:1.4;border-radius:8px}
.setup-editor-footer{display:flex;gap:8px;align-items:center}
.setup-editor-footer>button{flex:1;min-width:0;min-height:48px;padding:8px 12px;font-size:13px;white-space:nowrap}
.setup-editor-footer .cancel-setup-created{border-color:var(--accent);color:var(--accent);margin:0}
.setup-staging-note{padding:12px 14px;border-left:3px solid var(--accent);background:var(--soft)}

@media(max-width:700px){.card-grid .card .card-back .back-buttons .secondary{padding:6px 2px;font-size:10px;white-space:nowrap}}
