/* Sixiang — 四象限效率工具 · Apple-style minimal
 * Palette: black/white/gray skeleton + restrained Apple blue (#0071e3).
 * Type scale: 28 / 20 / 16 / 14 / 13 / 12. Spacing rhythm: 8 / 16 / 24 / 32.
 * Widths: 390 (phone) / 834 (tablet) / 1440 (desktop). No horizontal scroll.
 */
:root {
  --bg: #f5f5f7;
  --surface: #ffffff;
  --surface-2: #fafafa;
  --ink: #1d1d1f;
  --ink-2: #424245;
  --muted: #6e6e73;
  --faint: #a1a1a6;
  --border: #e5e5ea;
  --border-strong: #d2d2d7;
  --accent: #0071e3;
  --accent-soft: #e8f2fd;
  --accent-hover: #0077ed;
  --danger: #d70015;
  --danger-soft: #fdecef;
  --warn: #b7791f;
  --warn-soft: #fdf3e0;
  --ok: #1d7a3d;
  --ok-soft: #e6f4ea;
  --q1: #d70015;
  --q1-soft: #fdecef;
  --q2: #0071e3;
  --q2-soft: #e8f2fd;
  --q3: #b7791f;
  --q3-soft: #fdf3e0;
  --q4: #6e6e73;
  --q4-soft: #f5f5f7;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(0, 0, 0, .04), 0 8px 24px rgba(0, 0, 0, .05);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, .14);
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font); font-size: 15px; line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
button { font-family: var(--font); cursor: pointer; }
input, select, textarea { font-family: var(--font); font-size: 15px; color: var(--ink); }
img { max-width: 100%; }

/* ---------- Header ---------- */
.topbar {
  position: sticky; top: 0; z-index: 40;
  background: rgba(255, 255, 255, .86);
  backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--border);
}
.topbar-inner {
  max-width: 1200px; margin: 0 auto; padding: 0 24px;
  min-height: 56px; display: flex; align-items: center; gap: 16px;
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); flex-shrink: 0; }
.brand:hover { text-decoration: none; }
.brand-mark { width: 28px; height: 28px; border-radius: 8px; display: grid; grid-template-columns: 1fr 1fr; gap: 2px; padding: 3px; background: #fff; border: 1px solid var(--border-strong); flex-shrink: 0; }
.brand-mark i { border-radius: 2px; display: block; }
.brand-mark i:nth-child(1) { background: var(--q1); }
.brand-mark i:nth-child(2) { background: #c7d6e8; }
.brand-mark i:nth-child(3) { background: #f0d9a8; }
.brand-mark i:nth-child(4) { background: #e5e5ea; }
.brand-name { font-size: 17px; font-weight: 700; letter-spacing: -.01em; white-space: nowrap; }
.brand-sub { font-size: 12px; color: var(--muted); white-space: nowrap; }
.mainnav { display: flex; gap: 4px; margin-left: 8px; }
.mainnav a {
  color: var(--ink-2); font-size: 14px; padding: 7px 11px; border-radius: 999px; white-space: nowrap;
}
.mainnav a:hover { text-decoration: none; background: #f0f0f2; }
.mainnav a.active { background: var(--ink); color: #fff; }
.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 10px; min-width: 0; }
.lang-switch { display: flex; flex-shrink: 0; border: 1px solid var(--border-strong); border-radius: 999px; overflow: hidden; background: #fff; }
.lang-switch button { border: 0; background: transparent; padding: 6px 11px; font-size: 13px; color: var(--muted); }
.lang-switch button.on { background: var(--ink); color: #fff; }
.sync-pill {
  display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--border-strong);
  background: #fff; border-radius: 999px; padding: 6px 12px; font-size: 13px; color: var(--ink-2);
  white-space: nowrap;
}
.sync-pill .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); flex-shrink: 0; }
.sync-pill[data-state="syncing"] .dot { background: var(--accent); animation: pulse 1s infinite; }
.sync-pill[data-state="pending"] .dot { background: var(--warn); }
.sync-pill[data-state="offline"] .dot { background: var(--faint); }
.sync-pill[data-state="conflict"] { border-color: var(--danger); color: var(--danger); }
.sync-pill[data-state="conflict"] .dot { background: var(--danger); }
@keyframes pulse { 50% { opacity: .35; } }
.avatar-btn {
  border: 1px solid var(--border-strong); background: #fff; border-radius: 999px;
  padding: 6px 12px; font-size: 13px; color: var(--ink-2); white-space: nowrap;
  max-width: 180px; overflow: hidden; text-overflow: ellipsis; flex-shrink: 1; min-width: 0;
}
.avatar-btn:hover { border-color: var(--ink); }

/* ---------- Layout ---------- */
.wrap { max-width: 1200px; margin: 0 auto; padding: 32px 24px 96px; }
.view { display: none; }
.view.active { display: block; }
.hero { margin: 8px 0 24px; }
.hero h1 { font-size: 28px; line-height: 1.25; font-weight: 700; letter-spacing: -.02em; margin: 0 0 8px; }
.hero p { margin: 0; color: var(--muted); font-size: 16px; max-width: 720px; }
.hero .hero-note { margin-top: 10px; font-size: 13px; color: var(--faint); }
.section-title { font-size: 20px; font-weight: 700; letter-spacing: -.01em; margin: 32px 0 12px; }
.section-sub { color: var(--muted); font-size: 14px; margin: -6px 0 16px; }
.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.card-pad { padding: 20px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.tiny { font-size: 12px; color: var(--faint); }

/* ---------- Today board ---------- */
.today-board { display: grid; grid-template-columns: 1.5fr 1fr 1fr; gap: 16px; margin-bottom: 8px; }
.today-card { padding: 20px; }
.today-card h2 { font-size: 15px; margin: 0 0 4px; font-weight: 700; }
.today-card .big-num { font-size: 34px; font-weight: 700; letter-spacing: -.02em; line-height: 1.1; }
.today-card .big-num span { font-size: 15px; color: var(--muted); font-weight: 500; }
.today-list { list-style: none; margin: 10px 0 0; padding: 0; }
.today-list li {
  display: flex; align-items: flex-start; gap: 10px; padding: 9px 0;
  border-top: 1px solid var(--border); font-size: 14px;
}
.today-list li:first-child { border-top: 0; }
.today-list .num {
  width: 22px; height: 22px; border-radius: 50%; background: var(--ink); color: #fff;
  font-size: 12px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.check {
  width: 22px; height: 22px; border-radius: 50%; border: 1.5px solid var(--border-strong);
  background: #fff; flex-shrink: 0; padding: 0; display: inline-flex; align-items: center; justify-content: center;
  color: transparent; font-size: 13px; line-height: 1;
}
.check.done { background: var(--accent); border-color: var(--accent); color: #fff; }
.today-list li.done .task-title { text-decoration: line-through; color: var(--muted); }
.task-title { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.task-meta { color: var(--muted); font-size: 12px; white-space: nowrap; }
.overdue-flag { color: var(--danger); font-size: 12px; font-weight: 600; white-space: nowrap; }
.empty-note { color: var(--muted); font-size: 14px; padding: 12px 0 4px; }
.link-btn { background: none; border: 0; color: var(--accent); font-size: 14px; padding: 0; }
.link-btn:hover { text-decoration: underline; }

/* ---------- Composer ---------- */
.composer { display: flex; gap: 10px; align-items: flex-start; padding: 16px; margin: 16px 0 24px; flex-wrap: wrap; }
.composer input[type="text"] {
  flex: 1 1 260px; border: 1px solid var(--border-strong); border-radius: var(--radius-sm);
  padding: 11px 12px; background: #fff; min-width: 0;
}
.composer input[type="text"]:focus { outline: 2px solid var(--accent); outline-offset: 0; border-color: var(--accent); }
.composer select, .field select, .field input, .field textarea {
  border: 1px solid var(--border-strong); border-radius: var(--radius-sm); padding: 10px 11px; background: #fff;
}
.composer select:focus, .field select:focus, .field input:focus, .field textarea:focus { outline: 2px solid var(--accent); border-color: var(--accent); }
.btn {
  border: 0; border-radius: 999px; padding: 11px 20px; font-size: 15px; font-weight: 600;
  background: var(--accent); color: #fff; white-space: nowrap;
}
.btn:hover { background: var(--accent-hover); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn-ghost {
  background: #fff; color: var(--accent); border: 1px solid var(--border-strong); font-weight: 600;
}
.btn-ghost:hover { background: var(--accent-soft); }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: #000; }
.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover { background: #b30012; }
.btn-sm { padding: 7px 14px; font-size: 13px; }
.btn-block { width: 100%; }
.toggle-row { display: flex; gap: 8px; flex-wrap: wrap; }
.chip {
  border: 1px solid var(--border-strong); background: #fff; border-radius: 999px;
  padding: 6px 13px; font-size: 13px; color: var(--ink-2);
}
.chip.on { background: var(--ink); color: #fff; border-color: var(--ink); }

/* ---------- Quadrant grid (first screen) ---------- */
.quadrant-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.quadrant {
  border-radius: var(--radius); padding: 18px 18px 14px; min-height: 260px;
  background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow);
  display: flex; flex-direction: column;
  transition: border-color .15s, box-shadow .15s;
}
.quadrant.drag-over { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft), var(--shadow); }
.quadrant-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 4px; }
.quadrant-head .q-tag {
  font-size: 12px; font-weight: 700; padding: 3px 8px; border-radius: 6px; flex-shrink: 0;
}
.q1 .q-tag { background: var(--q1-soft); color: var(--q1); }
.q2 .q-tag { background: var(--q2-soft); color: var(--q2); }
.q3 .q-tag { background: var(--q3-soft); color: var(--q3); }
.q4 .q-tag { background: var(--q4-soft); color: var(--q4); }
.quadrant-head h2 { font-size: 17px; margin: 0; font-weight: 700; letter-spacing: -.01em; }
.quadrant-head .count {
  margin-left: auto; font-size: 13px; color: var(--muted); background: var(--q4-soft);
  border-radius: 999px; padding: 2px 9px; white-space: nowrap;
}
.quadrant-head .q-hint { font-size: 12px; color: var(--faint); }
.quadrant .q-desc { font-size: 13px; color: var(--muted); margin: 0 0 12px; }
.task-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.task-list:empty::after {
  content: attr(data-empty); color: var(--faint); font-size: 13px;
  display: block; padding: 14px 4px; text-align: center;
}
.task-card {
  background: var(--surface-2); border: 1px solid var(--border); border-radius: 12px;
  padding: 12px 12px 10px; cursor: grab;
}
.task-card:active { cursor: grabbing; }
.task-card.dragging { opacity: .45; border-style: dashed; border-color: var(--accent); }
.task-card.done-card { opacity: .62; }
.task-card-top { display: flex; align-items: flex-start; gap: 9px; }
.task-card .task-title { font-size: 15px; font-weight: 600; line-height: 1.4; }
.task-card.done-card .task-title { text-decoration: line-through; color: var(--muted); }
.task-card .task-notes { font-size: 13px; color: var(--muted); margin: 6px 0 0 31px; overflow-wrap: anywhere; }
.task-card .task-foot { display: flex; align-items: center; gap: 8px; margin: 8px 0 0 31px; flex-wrap: wrap; }
.pill { font-size: 12px; border-radius: 999px; padding: 2px 8px; background: #fff; border: 1px solid var(--border); color: var(--muted); white-space: nowrap; }
.pill.overdue { background: var(--danger-soft); border-color: transparent; color: var(--danger); font-weight: 600; }
.pill.conflict { background: var(--danger-soft); border-color: transparent; color: var(--danger); font-weight: 600; }
.pill.pending { background: var(--warn-soft); border-color: transparent; color: var(--warn); font-weight: 600; }
.pill.repeat { background: var(--accent-soft); border-color: transparent; color: var(--accent); }
.icon-btn {
  border: 0; background: transparent; color: var(--muted); font-size: 16px; line-height: 1;
  padding: 4px 6px; border-radius: 8px; flex-shrink: 0;
}
.icon-btn:hover { background: #ececf0; color: var(--ink); }
.task-menu { position: relative; }
.menu-pop {
  position: absolute; right: 0; top: 30px; z-index: 30; min-width: 190px;
  background: #fff; border: 1px solid var(--border); border-radius: 12px; box-shadow: var(--shadow-lg);
  padding: 6px;
}
.menu-pop button {
  display: block; width: 100%; text-align: left; border: 0; background: transparent;
  padding: 9px 10px; font-size: 14px; border-radius: 8px; color: var(--ink);
}
.menu-pop button:hover { background: #f5f5f7; }
.menu-pop button.danger { color: var(--danger); }
.menu-pop .menu-sep { height: 1px; background: var(--border); margin: 5px 4px; }
.menu-pop .menu-label { font-size: 12px; color: var(--faint); padding: 7px 10px 3px; }
.quadrant-foot { margin-top: auto; padding-top: 12px; }
.quadrant-foot .link-btn { font-size: 13px; }

/* ---------- Forms / panels ---------- */
.panel { padding: 24px; }
.panel h2 { font-size: 20px; margin: 0 0 6px; }
.panel h3 { font-size: 16px; margin: 24px 0 10px; }
.panel h3:first-child { margin-top: 0; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field.full { grid-column: 1 / -1; }
.field label { font-size: 13px; font-weight: 600; color: var(--ink-2); }
.field input, .field select, .field textarea { width: 100%; }
.field textarea { min-height: 84px; resize: vertical; }
.field .hint { font-size: 12px; color: var(--faint); font-weight: 400; }
.form-actions { display: flex; gap: 10px; margin-top: 20px; flex-wrap: wrap; }
.divider { height: 1px; background: var(--border); margin: 24px 0; }
.kv { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0; border-bottom: 1px solid var(--border); font-size: 14px; }
.kv:last-child { border-bottom: 0; }
.kv b { font-weight: 600; }
.badge { font-size: 12px; font-weight: 700; border-radius: 999px; padding: 3px 10px; white-space: nowrap; }
.badge.free { background: var(--q4-soft); color: var(--ink-2); }
.badge.buyout { background: var(--accent-soft); color: var(--accent); }
.badge.sponsor { background: var(--ink); color: #fff; }
.price-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 16px; }
.price-card { padding: 24px; position: relative; }
.price-card.featured { border-color: var(--ink); box-shadow: var(--shadow-lg); }
.price-card .price { font-size: 34px; font-weight: 700; letter-spacing: -.02em; margin: 8px 0 4px; }
.price-card .price span { font-size: 14px; color: var(--muted); font-weight: 500; }
.price-card ul { margin: 14px 0 18px; padding: 0; list-style: none; font-size: 14px; color: var(--ink-2); }
.price-card li { padding: 5px 0 5px 22px; position: relative; }
.price-card li::before { content: "✓"; position: absolute; left: 0; color: var(--accent); font-weight: 700; }
.price-card .flag {
  position: absolute; top: 16px; right: 16px; font-size: 12px; font-weight: 700;
  background: var(--ink); color: #fff; border-radius: 999px; padding: 3px 10px;
}
.notice {
  border-radius: 12px; padding: 14px 16px; font-size: 14px; margin: 16px 0;
  background: var(--accent-soft); color: #0b4a8f; border: 1px solid #cfe3fa;
}
.notice.warn { background: var(--warn-soft); color: #7a5200; border-color: #f0dfb8; }
.notice.danger { background: var(--danger-soft); color: #8f0010; border-color: #f6c9cf; }
.notice.ok { background: var(--ok-soft); color: #14532a; border-color: #c4e3cd; }
.notice p { margin: 0 0 6px; }
.notice p:last-child { margin-bottom: 0; }

/* ---------- Trash ---------- */
.trash-item {
  display: flex; align-items: flex-start; gap: 14px; padding: 16px 0;
  border-bottom: 1px solid var(--border);
}
.trash-item:last-child { border-bottom: 0; }
.trash-item .trash-body { flex: 1; min-width: 0; }
.trash-item .trash-title { font-weight: 600; font-size: 15px; overflow-wrap: anywhere; }
.countdown { font-size: 13px; color: var(--warn); font-weight: 600; margin-top: 4px; }
.countdown.soon { color: var(--danger); }
.countdown-bar { height: 6px; border-radius: 999px; background: var(--border); margin-top: 8px; overflow: hidden; max-width: 320px; }
.countdown-bar i { display: block; height: 100%; background: var(--accent); border-radius: 999px; }
.trash-actions { display: flex; gap: 8px; flex-shrink: 0; }

/* ---------- Reminders ---------- */
.remind-item { display: flex; gap: 12px; align-items: flex-start; padding: 14px 0; border-bottom: 1px solid var(--border); }
.remind-item:last-child { border-bottom: 0; }
.remind-item .bell { width: 34px; height: 34px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: flex; align-items: center; justify-content: center; font-size: 16px; flex-shrink: 0; }
.remind-item.unread { background: linear-gradient(90deg, var(--accent-soft), transparent 60%); margin: 0 -12px; padding-left: 12px; padding-right: 12px; border-radius: 8px; }
.remind-item .remind-body { flex: 1; min-width: 0; }

/* ---------- Modal / sheet ---------- */
.modal-backdrop {
  position: fixed; inset: 0; background: rgba(0, 0, 0, .32); z-index: 80;
  display: none; align-items: flex-end; justify-content: center;
}
.modal-backdrop.open { display: flex; }
.modal {
  background: #fff; border-radius: 20px 20px 0 0; width: 100%; max-width: 720px;
  max-height: 88vh; overflow-y: auto; padding: 24px; box-shadow: var(--shadow-lg);
}
.modal h2 { font-size: 20px; margin: 0 0 6px; }
.modal .modal-sub { color: var(--muted); font-size: 14px; margin: 0 0 16px; }
.conflict-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.conflict-col { border: 1px solid var(--border); border-radius: 12px; padding: 14px; }
.conflict-col h3 { font-size: 14px; margin: 0 0 8px; }
.conflict-col.mine { border-color: var(--accent); }
.conflict-col dl { margin: 0; font-size: 13px; }
.conflict-col dt { color: var(--faint); font-size: 12px; margin-top: 8px; }
.conflict-col dd { margin: 2px 0 0; overflow-wrap: anywhere; }
.toast {
  position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%) translateY(20px);
  background: var(--ink); color: #fff; padding: 11px 18px; border-radius: 999px;
  font-size: 14px; z-index: 100; opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s;
  max-width: calc(100vw - 32px); text-align: center;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.sheet-handle { display: none; }

/* ---------- AI ---------- */
.ai-result { border: 1px solid var(--border); border-radius: 12px; padding: 14px 16px; margin-top: 12px; }
.ai-result h4 { margin: 0 0 8px; font-size: 15px; }
.ai-result ul { margin: 0; padding-left: 18px; font-size: 14px; color: var(--ink-2); }
.ai-result li { margin: 4px 0; }
.quota-line { font-size: 13px; color: var(--muted); margin-top: 10px; }
.loading { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font-size: 14px; }
.spinner { width: 16px; height: 16px; border: 2px solid var(--border-strong); border-top-color: var(--accent); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.skeleton { background: linear-gradient(90deg, #ececf0 25%, #f5f5f7 50%, #ececf0 75%); background-size: 200% 100%; animation: shimmer 1.2s infinite; border-radius: 8px; color: transparent !important; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* ---------- Login intro: quadrant explainer + pricing summary (C3) ---------- */
.quad-intro { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.quad-intro-card { padding: 16px; }
.quad-intro-card .q-tag {
  font-size: 12px; font-weight: 700; padding: 3px 8px; border-radius: 6px;
}
.quad-intro-card h3 { font-size: 15px; margin: 10px 0 4px; font-weight: 700; letter-spacing: -.01em; }
.quad-intro-card p { font-size: 13px; color: var(--muted); margin: 0; }
.price-summary { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.price-mini { padding: 16px 18px; }
.price-mini .pm-top { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.price-mini .pm-name { font-size: 15px; font-weight: 700; }
.price-mini .pm-price { font-size: 24px; font-weight: 700; letter-spacing: -.02em; white-space: nowrap; }
.price-mini .pm-price span { font-size: 13px; color: var(--muted); font-weight: 500; }
.price-mini p { font-size: 13px; color: var(--muted); margin: 8px 0 0; }
.login-more { margin: 14px 0 0; font-size: 14px; }

/* ---------- Footer ---------- */
.footer { max-width: 1200px; margin: 0 auto; padding: 0 24px 48px; color: var(--faint); font-size: 13px; line-height: 1.8; }
.footer .foot-links { display: flex; gap: 20px; flex-wrap: wrap; margin-bottom: 8px; }
.footer a { color: var(--muted); }

/* ---------- Tablet 834 ---------- */
@media (max-width: 900px) {
  .topbar-inner { padding: 0 16px; gap: 10px; }
  .brand-sub { display: none; }
  .mainnav { overflow-x: auto; scrollbar-width: none; }
  .mainnav::-webkit-scrollbar { display: none; }
  .wrap { padding: 24px 16px 80px; }
  .today-board { grid-template-columns: 1fr 1fr; }
  .today-card.wide { grid-column: 1 / -1; }
  .price-grid { grid-template-columns: 1fr; }
  .quad-intro { grid-template-columns: 1fr 1fr; }
  .price-summary { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
}

/* ---------- Phone 390 ---------- */
@media (max-width: 640px) {
  body { font-size: 15px; }
  .topbar-inner { flex-wrap: wrap; padding: 8px 12px; min-height: 0; row-gap: 8px; }
  .mainnav { order: 3; flex-basis: 100%; margin-left: 0; padding-bottom: 2px; }
  .sync-pill .sync-text-long { display: none; }
  .avatar-btn { max-width: 120px; }
  .wrap { padding: 20px 12px 72px; }
  .hero { margin: 4px 0 16px; }
  .hero h1 { font-size: 20px; }
  .hero p { font-size: 14px; }
  .hero .hero-note { display: none; }
  .today-board { grid-template-columns: 1fr 1fr; gap: 10px; }
  .today-card.wide { grid-column: 1 / -1; }
  .today-card { padding: 14px; }
  .today-card .big-num { font-size: 28px; }
  /* C2: mobile home order — grid before composer so the 2x2 grid is in the first screen */
  #view-home.active { display: flex; flex-direction: column; }
  #view-home.active > * { order: 7; }
  #view-home.active > .hero { order: 1; }
  #view-home.active > #offlineBanner, #view-home.active > #authBanner { order: 2; }
  #view-home.active > .today-board { order: 3; }
  #view-home.active > .quadrant-grid { order: 4; }
  #view-home.active > .composer { order: 5; }
  #view-home.active > p.tiny { order: 6; }
  .quadrant-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .quadrant { padding: 12px 10px 10px; min-height: 220px; border-radius: 14px; }
  .quadrant-head { flex-wrap: wrap; gap: 6px; }
  .quadrant-head h2 { font-size: 14px; }
  .quadrant-head .q-hint { display: none; }
  .quadrant .q-desc { display: none; }
  .quadrant-head .count { margin-left: 0; }
  .task-card { padding: 10px; }
  .task-card .task-notes { margin-left: 0; }
  .task-card .task-foot { margin-left: 0; }
  .composer { padding: 12px; gap: 8px; }
  .composer select, .composer input[type="date"] { flex: 1 1 30%; min-width: 0; }
  .composer .btn { flex: 1 1 100%; }
  .quad-intro-card { padding: 12px; }
  .price-mini { padding: 14px; }
  .conflict-cols { grid-template-columns: 1fr; }
  .modal { padding: 20px 16px; border-radius: 20px 20px 0 0; }
  .sheet-handle { display: block; width: 36px; height: 4px; border-radius: 999px; background: var(--border-strong); margin: 0 auto 14px; }
  .trash-item { flex-wrap: wrap; }
  .trash-actions { width: 100%; }
  .trash-actions .btn { flex: 1; }
  .panel { padding: 18px 14px; }
  .price-card { padding: 20px 16px; }
}
