  :root {
    --radius: 18px;
    --font: 'Plus Jakarta Sans', system-ui, sans-serif;
    --font-mono: 'JetBrains Mono', ui-monospace, monospace;
    /* Light, warm */
    --bg: #f6f2ec;
    --card: #fffdfa;
    --text: #3d3744;
    --muted: #8e8696;
    --line: #ebe4dc;
    --shadow: 0 1px 2px rgba(80,60,50,0.05), 0 4px 14px rgba(80,60,50,0.06);
    --nav-bg: rgba(255,253,250,0.92);
  }
  :root[data-palette="Warm"] {
    --primary: #4e7d46; --primary-soft: #e6efe1; --primary-deep: #3c6135;
    --sleep: #7e76bd; --sleep-soft: #edebf8; --sleep-deep: #5a52a4;
    --feed:  #c87d92; --feed-soft:  #f9e9ee; --feed-deep:  #a4536e;
    --belly: #d08c5c; --belly-soft: #f9ecdf; --belly-deep: #a4602f;
    --act:   #7ca57c; --act-soft:   #e9f1e4; --act-deep:   #54794f;
    --poop:  #ab8c6c; --poop-soft:  #f2ebdf; --poop-deep:  #7d6044;
    --solid: #94a35f; --solid-soft: #eef0da; --solid-deep: #68763a;
    --note:  #8d97a3; --note-soft:  #edf0f2; --note-deep:  #5c6671;
  }
  :root[data-palette="Kühl"] {
    --primary: #477a62; --primary-soft: #e2efe9; --primary-deep: #355f4b;
    --sleep: #6f80c6; --sleep-soft: #e9edf9; --sleep-deep: #4b5cab;
    --feed:  #b97fb4; --feed-soft:  #f6e9f5; --feed-deep:  #92568d;
    --belly: #c98f74; --belly-soft: #f8ece5; --belly-deep: #a05f41;
    --act:   #6ba696; --act-soft:   #e5f1ec; --act-deep:   #437a6a;
    --poop:  #9b8d7b; --poop-soft:  #eeebe3; --poop-deep:  #6d6150;
    --solid: #84a36b; --solid-soft: #e9f0e0; --solid-deep: #587743;
    --note:  #8694a6; --note-soft:  #ebeff3; --note-deep:  #566476;
  }
  :root[data-theme="night"] {
    --bg: #1f1c25;
    --card: #2a2632;
    --text: #ebe7ef;
    --muted: #9b93a6;
    --line: #393443;
    --shadow: 0 1px 2px rgba(0,0,0,0.3), 0 4px 14px rgba(0,0,0,0.25);
    --nav-bg: rgba(42,38,50,0.94);
  }
  :root[data-theme="night"][data-palette="Warm"], :root[data-theme="night"][data-palette="Kühl"] {
    --primary: #76a06c; --primary-soft: #2d3a29; --primary-deep: #abcd9f;
    --sleep-soft: #353050; --feed-soft: #44303a; --belly-soft: #463526;
    --act-soft: #2e3c2d; --poop-soft: #3d3528; --note-soft: #323741; --solid-soft: #393d25;
    --sleep-deep: #aaa3e0; --feed-deep: #e0a0b6; --belly-deep: #e2ab7e;
    --act-deep: #a3c9a0; --poop-deep: #c9ad8c; --note-deep: #aab4c0; --solid-deep: #c6d195;
  }

  * { box-sizing: border-box; }
  html, body { margin: 0; padding: 0; height: 100%; }
  body {
    background: var(--bg);
    font-family: var(--font);
  }
  #root { height: 100dvh; }

  /* ---------- App-Grundgerüst ---------- */
  .app {
    height: 100dvh;
    position: relative;
    overflow: hidden;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font);
    display: flex;
    flex-direction: column;
  }
  .app-scroll {
    flex: 1;
    overflow-y: auto;
    padding: calc(14px + env(safe-area-inset-top, 0px)) 18px 110px;
    scrollbar-width: none;
  }
  .app-scroll::-webkit-scrollbar { display: none; }
  .screen { display: flex; flex-direction: column; gap: 14px; }

  .page-head {
    display: flex; align-items: center; justify-content: space-between;
    padding: 6px 2px 2px;
  }
  .page-head h1 { font-size: 26px; font-weight: 800; margin: 0; letter-spacing: -0.4px; }
  .page-sub { font-size: 13px; color: var(--muted); margin-top: 3px; font-weight: 500; }
  .avatar {
    width: 42px; height: 42px; border-radius: 50%;
    background: var(--feed-soft); color: var(--feed-deep);
    display: flex; align-items: center; justify-content: center;
    font-weight: 800; font-size: 18px;
  }

  .card {
    background: var(--card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
  }

  /* ---------- Summary ---------- */
  .summary-grid {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px;
  }
  .sum-cell {
    background: var(--card); border-radius: calc(var(--radius) - 4px);
    box-shadow: var(--shadow);
    padding: 12px 12px 10px;
    display: flex; flex-direction: column; gap: 2px;
  }
  .sum-value { font-size: 17px; font-weight: 800; letter-spacing: -0.3px; font-variant-numeric: tabular-nums; }
  .sum-label { font-size: 11px; font-weight: 600; color: var(--muted); }
  .sum-big { background: var(--sleep-soft); box-shadow: none; }
  .sum-big .sum-value { color: var(--sleep-deep); }
  .sum-big .sum-label { color: var(--sleep-deep); opacity: 0.75; }

  /* ---------- Prediction ---------- */
  .pred-card { padding: 14px 16px 12px; display: flex; flex-direction: column; gap: 8px; }
  .pred-top { display: flex; align-items: center; gap: 12px; }
  .pred-icon {
    width: 38px; height: 38px; border-radius: 12px; flex-shrink: 0;
    background: var(--sleep-soft); color: var(--sleep-deep);
    display: flex; align-items: center; justify-content: center;
  }
  .pred-main { flex: 1; min-width: 0; }
  .pred-label { font-size: 12px; font-weight: 600; color: var(--muted); }
  .pred-window { font-size: 20px; font-weight: 800; letter-spacing: -0.3px; font-variant-numeric: tabular-nums; }
  .pred-reason { font-size: 12.5px; color: var(--muted); line-height: 1.45; }
  .conf-pill {
    font-size: 11px; font-weight: 700; padding: 4px 10px; border-radius: 99px; flex-shrink: 0;
  }
  .conf-low { background: var(--note-soft); color: var(--note-deep); }
  .conf-medium { background: var(--belly-soft); color: var(--belly-deep); }
  .conf-high { background: var(--act-soft); color: var(--act-deep); }

  /* ---------- Quick Actions ---------- */
  .qa-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
  .qa-btn {
    position: relative;
    border: none; cursor: pointer;
    border-radius: var(--radius);
    padding: 11px 4px 10px;
    min-height: 70px;
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
    font-family: var(--font); font-size: 11.5px; font-weight: 700; color: var(--text);
    transition: transform 0.12s ease, box-shadow 0.12s ease;
  }
  .qa-btn:active { transform: scale(0.95); }
  .qa-active { box-shadow: inset 0 0 0 2px currentColor; }
  .qa-live-dot {
    position: absolute; top: 9px; right: 9px;
    width: 8px; height: 8px; border-radius: 50%;
    background: currentColor;
    animation: pulse 1.6s ease-in-out infinite;
  }
  @keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.3; } }
  .qa-label { line-height: 1; }
  .qa-manual {
    background: transparent;
    border: 1.5px dashed var(--line);
    color: var(--muted);
  }
  .qa-manual .qa-icon { color: var(--muted); }
  .qa-manual:hover { border-color: var(--muted); color: var(--text); }

  .backfill-btn {
    width: 100%; margin-top: 9px;
    display: flex; align-items: center; justify-content: center; gap: 7px;
    background: transparent; border: 1.5px dashed var(--line);
    border-radius: var(--radius); padding: 12px;
    font-family: var(--font); font-size: 13px; font-weight: 600; color: var(--muted);
    cursor: pointer; transition: border-color 0.15s ease, color 0.15s ease;
  }
  .backfill-btn:hover { border-color: var(--muted); color: var(--text); }

  /* ---------- Running Card ---------- */
  .running-card {
    display: flex; align-items: center; gap: 12px;
    padding: 13px 14px;
    border-left: 4px solid;
  }
  .running-pulse {
    width: 42px; height: 42px; border-radius: 13px; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
    color: #fff;
    animation: pulse 2s ease-in-out infinite;
  }
  .running-main { flex: 1; min-width: 0; }
  .running-label { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.6px; color: var(--muted); }
  .running-title { font-size: 14.5px; font-weight: 700; margin-top: 2px; }
  .running-dur { font-variant-numeric: tabular-nums; }
  .running-actions { display: flex; align-items: center; gap: 6px; }
  .stop-btn {
    display: flex; align-items: center; gap: 5px;
    border: none; cursor: pointer; color: #fff;
    font-family: var(--font); font-size: 13px; font-weight: 700;
    padding: 9px 13px; border-radius: 12px;
  }
  .stop-btn:active { transform: scale(0.95); }
  .ghost-btn {
    width: 34px; height: 34px; border-radius: 11px;
    border: none; background: var(--bg); color: var(--muted); cursor: pointer;
    display: flex; align-items: center; justify-content: center;
  }
  .ghost-btn:hover { color: var(--text); }

  /* ---------- Kategorie-Farben ---------- */
  .cat-sleep { background: var(--sleep); color: #fff; }
  .cat-feed { background: var(--feed); color: #fff; }
  .cat-belly { background: var(--belly); color: #fff; }
  .cat-act { background: var(--act); color: #fff; }
  .cat-poop { background: var(--poop); color: #fff; }
  .cat-note { background: var(--note); color: #fff; }
  .cat-solid { background: var(--solid); color: #fff; }
  .cat-soft-sleep { background: var(--sleep-soft); }
  .cat-soft-feed { background: var(--feed-soft); }
  .cat-soft-belly { background: var(--belly-soft); }
  .cat-soft-act { background: var(--act-soft); }
  .cat-soft-poop { background: var(--poop-soft); }
  .cat-soft-note { background: var(--note-soft); }
  .cat-soft-solid { background: var(--solid-soft); }
  .cat-text-sleep { color: var(--sleep-deep); }
  .cat-text-feed { color: var(--feed-deep); }
  .cat-text-belly { color: var(--belly-deep); }
  .cat-text-act { color: var(--act-deep); }
  .cat-text-poop { color: var(--poop-deep); }
  .cat-text-note { color: var(--note-deep); }
  .cat-text-solid { color: var(--solid-deep); }
  .cat-border-sleep { border-color: var(--sleep); }
  .cat-border-feed { border-color: var(--feed); }
  .cat-border-belly { border-color: var(--belly); }
  .cat-border-act { border-color: var(--act); }

  /* ---------- Sections & Timeline ---------- */
  .section { margin-top: 6px; }
  .section-head {
    display: flex; align-items: baseline; justify-content: space-between;
    padding: 0 2px; margin-bottom: 8px;
  }
  .section-head h2 { font-size: 16px; font-weight: 800; margin: 0; letter-spacing: -0.2px; }
  .section-count { font-size: 12px; color: var(--muted); font-weight: 600; }
  .entry-list { display: flex; flex-direction: column; gap: 7px; }
  .entry-row {
    display: flex; align-items: flex-start; gap: 11px;
    width: 100%; text-align: left;
    background: var(--card); border: none; cursor: pointer;
    border-radius: calc(var(--radius) - 4px);
    box-shadow: var(--shadow);
    padding: 11px 13px;
    font-family: var(--font); color: var(--text);
    transition: transform 0.1s ease;
  }
  .entry-row:active { transform: scale(0.985); }
  .entry-dot {
    width: 30px; height: 30px; border-radius: 10px; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
    margin-top: 1px;
  }
  .entry-main { flex: 1; min-width: 0; }
  .entry-title-line { display: flex; align-items: baseline; gap: 8px; }
  .entry-title { font-size: 14px; font-weight: 700; }
  .entry-dur { font-size: 12.5px; font-weight: 700; font-variant-numeric: tabular-nums; }
  .entry-detail { font-size: 12.5px; color: var(--muted); margin-top: 2px; line-height: 1.4; }
  .entry-tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
  .mini-tag {
    font-size: 10.5px; font-weight: 600; color: var(--muted);
    background: var(--bg); border-radius: 6px; padding: 2px 7px;
  }
  .entry-time {
    font-size: 12.5px; font-weight: 600; color: var(--muted);
    font-variant-numeric: tabular-nums; flex-shrink: 0; margin-top: 2px;
    display: flex; flex-direction: column; align-items: flex-end; line-height: 1.35;
    white-space: nowrap;
  }
  .empty-hint {
    text-align: center; color: var(--muted); font-size: 13px; line-height: 1.6;
    padding: 26px 16px; background: var(--card); border-radius: var(--radius);
    box-shadow: var(--shadow);
  }

  /* ---------- Bottom Nav ---------- */
  .bottom-nav {
    position: absolute; bottom: 0; left: 0; right: 0; z-index: 30;
    display: flex; justify-content: space-around; align-items: flex-start;
    padding: 9px 8px calc(12px + env(safe-area-inset-bottom, 0px));
    background: var(--nav-bg);
    backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
    border-top: 1px solid var(--line);
  }
  .nav-brand { display: none; }
  .nav-theme { display: none; }
  .nav-collapse { display: none; }
  .header-actions { display: flex; align-items: center; gap: 10px; }
  .theme-btn {
    width: 38px; height: 38px; border-radius: 50%; flex-shrink: 0;
    border: 1.5px solid var(--line); background: var(--card); color: var(--muted);
    cursor: pointer; display: flex; align-items: center; justify-content: center;
    transition: all 0.15s ease;
  }
  .theme-btn:hover { color: var(--text); border-color: var(--muted); }
  .theme-btn:active { transform: scale(0.92); }
  .nav-btn {
    display: flex; flex-direction: column; align-items: center; gap: 3px;
    background: none; border: none; cursor: pointer;
    font-family: var(--font); font-size: 9.5px; font-weight: 700;
    color: var(--muted); padding: 4px 2px; border-radius: 12px;
    flex: 1; min-width: 0;
  }
  .nav-btn span { white-space: nowrap; }
  .nav-btn.on { color: var(--primary-deep); }

  /* ---------- Sheets ---------- */
  .sheet-backdrop {
    position: absolute; inset: 0; z-index: 40;
    background: rgba(30,24,38,0.42);
    display: flex; align-items: flex-end;
    animation: fadeIn 0.18s ease;
  }
  @keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
  .sheet {
    width: 100%; max-height: 72%;
    background: var(--card);
    border-radius: calc(var(--radius) + 6px) calc(var(--radius) + 6px) 0 0;
    display: flex; flex-direction: column;
    animation: slideUp 0.22s cubic-bezier(0.3, 0.9, 0.4, 1);
  }
  .sheet-tall { height: 88%; max-height: 88%; }
  @keyframes slideUp { from { transform: translateY(40px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
  .sheet-grab { width: 38px; height: 4.5px; border-radius: 99px; background: var(--line); margin: 9px auto 0; }
  .sheet-head {
    display: flex; align-items: center; justify-content: space-between;
    padding: 8px 18px 4px;
  }
  .sheet-title { font-size: 17px; font-weight: 800; letter-spacing: -0.2px; }
  .sheet-body { padding: 10px 18px 30px; overflow-y: auto; scrollbar-width: none; }
  .sheet-body::-webkit-scrollbar { display: none; }
  .icon-btn {
    width: 32px; height: 32px; border-radius: 50%;
    border: none; background: var(--bg); color: var(--muted); cursor: pointer;
    display: flex; align-items: center; justify-content: center;
  }
  .icon-btn:disabled { opacity: 0.35; cursor: default; }

  /* ---------- Formulare ---------- */
  .form-stack { display: flex; flex-direction: column; gap: 14px; }
  .form-row { display: flex; gap: 10px; }
  .form-row > * { flex: 1; }
  .form-label { font-size: 12px; font-weight: 700; color: var(--muted); margin-bottom: 7px; }
  .chip-row { display: flex; flex-wrap: wrap; gap: 6px; }
  .chip {
    border: 1.5px solid var(--line); background: var(--card);
    border-radius: 99px; padding: 7px 13px;
    font-family: var(--font); font-size: 12.5px; font-weight: 600; color: var(--text);
    cursor: pointer; transition: all 0.12s ease;
  }
  .chip.on { background: var(--primary-soft); border-color: var(--primary); color: var(--primary-deep); }
  .time-field, .form-field { display: flex; flex-direction: column; gap: 6px; }
  .time-field span, .form-field span { font-size: 12px; font-weight: 700; color: var(--muted); }
  .time-field input, .form-field input, .form-field textarea, .note-area {
    font-family: var(--font); font-size: 15px; font-weight: 600; color: var(--text);
    background: var(--bg); border: 1.5px solid var(--line);
    border-radius: 12px; padding: 11px 12px; width: 100%;
    outline: none;
  }
  .time-field input:focus, .form-field input:focus, .form-field textarea:focus, .note-area:focus {
    border-color: var(--primary);
  }
  .form-field textarea, .note-area { resize: none; font-weight: 500; }
  .primary-btn {
    display: flex; align-items: center; justify-content: center; gap: 7px;
    width: 100%; border: none; cursor: pointer;
    background: var(--primary); color: #fff;
    font-family: var(--font); font-size: 15px; font-weight: 700;
    padding: 14px; border-radius: 14px;
  }
  .primary-btn:disabled { opacity: 0.4; cursor: default; }
  .primary-btn:active:not(:disabled) { transform: scale(0.98); }
  .secondary-btn {
    display: flex; align-items: center; justify-content: center; gap: 7px;
    flex: 1; border: 1.5px solid var(--line); background: var(--card); cursor: pointer;
    font-family: var(--font); font-size: 13.5px; font-weight: 700; color: var(--text);
    padding: 11px; border-radius: 13px;
  }
  .secondary-btn.danger { color: #c25656; border-color: #e8c9c9; }
  :root[data-theme="night"] .secondary-btn.danger { border-color: #5d3a3a; color: #e08989; }
  .confirm-text { font-size: 14px; line-height: 1.55; color: var(--text); margin: 0; }
  .option-btn {
    display: flex; align-items: center; gap: 10px;
    width: 100%; border: none; cursor: pointer; text-align: left;
    background: var(--bg); color: var(--text);
    font-family: var(--font); font-size: 14.5px; font-weight: 700;
    padding: 15px 16px; border-radius: 14px;
  }
  .option-btn:active { transform: scale(0.98); }
  .option-sub { margin-left: auto; font-size: 12px; font-weight: 600; color: var(--muted); }
  .subtype-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
  .subtype-btn {
    border: none; cursor: pointer;
    border-radius: 13px; padding: 14px 6px;
    font-family: var(--font); font-size: 12.5px; font-weight: 700; color: var(--act-deep);
    transition: transform 0.1s ease;
  }
  .subtype-btn:active { transform: scale(0.94); }

  /* ---------- Timeline-Seite ---------- */
  .date-nav {
    display: flex; align-items: center; justify-content: space-between;
    background: var(--card); border-radius: var(--radius);
    box-shadow: var(--shadow); padding: 8px 10px;
  }
  .date-nav-label { font-size: 15px; font-weight: 800; }
  .day-meta {
    display: flex; gap: 7px; justify-content: center;
    font-size: 12.5px; color: var(--muted); font-weight: 600;
  }

  /* ---------- Stats ---------- */
  .seg {
    display: flex; background: var(--card); border-radius: 99px;
    padding: 4px; box-shadow: var(--shadow); gap: 2px;
  }
  .seg-opt {
    flex: 1; border: none; background: none; cursor: pointer;
    font-family: var(--font); font-size: 12.5px; font-weight: 700; color: var(--muted);
    padding: 8px 4px; border-radius: 99px; transition: all 0.15s ease;
  }
  .seg-opt.on { background: var(--primary-soft); color: var(--primary-deep); }
  .stat-group {
    background: var(--card); border-radius: var(--radius);
    box-shadow: var(--shadow); padding: 14px 16px 6px;
  }
  .stat-group-title {
    display: flex; align-items: center; gap: 7px;
    font-size: 13px; font-weight: 800; margin-bottom: 6px;
  }
  .stat-row {
    display: flex; align-items: center; justify-content: space-between;
    padding: 9px 0; border-bottom: 1px solid var(--line);
  }
  .stat-row:last-child { border-bottom: none; }
  .stat-row-label { font-size: 13.5px; font-weight: 600; color: var(--muted); }
  .stat-row-right { display: flex; align-items: baseline; gap: 7px; }
  .stat-row-value { font-size: 14.5px; font-weight: 800; font-variant-numeric: tabular-nums; }
  .stat-row-sub { font-size: 10.5px; font-weight: 600; color: var(--muted); }

  /* ---------- Insights ---------- */
  .insight-list { display: flex; flex-direction: column; gap: 9px; }
  .insight-card { display: flex; gap: 12px; padding: 14px 15px; align-items: flex-start; }
  .insight-title { font-size: 13.5px; font-weight: 800; }
  .insight-text { font-size: 13px; color: var(--muted); line-height: 1.5; margin-top: 3px; }
  .disclaimer {
    font-size: 11.5px; color: var(--muted); line-height: 1.55;
    text-align: center; padding: 4px 18px; margin: 4px 0 0;
  }

  /* ---------- Settings ---------- */
  .settings-row {
    display: flex; align-items: center; justify-content: space-between;
    width: 100%; border: none; background: none; cursor: pointer; text-align: left;
    font-family: var(--font); font-size: 14px; font-weight: 600; color: var(--text);
    padding: 13px 0; border-bottom: 1px solid var(--line);
  }
  .settings-row:last-child { border-bottom: none; }
  .settings-row.danger { color: #c25656; }
  :root[data-theme="night"] .settings-row.danger { color: #e08989; }
  .field-hint { font-size: 11.5px; color: var(--muted); margin: 2px 0 10px; }
  .form-field { margin-bottom: 12px; }

  /* ---------- Zeitstrahl ---------- */
  .view-seg { width: 188px; }
  .view-seg .seg-opt { padding: 7px 4px; font-size: 12px; }
  .bars-wrap { padding: 12px 12px 8px; }
  .bars-canvas { position: relative; }
  .bar-hour { position: absolute; left: 0; right: 0; border-top: 1px solid var(--line); }
  .bar-hour > span {
    position: absolute; top: -7px; left: 0;
    font-size: 10px; font-weight: 700; color: var(--muted);
    background: var(--card); padding-right: 5px;
    font-variant-numeric: tabular-nums;
  }
  .bar-hour > span span { position: static; }
  .bar-seg {
    position: absolute; border: none; cursor: pointer; text-align: left;
    border-radius: 8px; border-left: 3px solid; box-sizing: border-box;
    padding: 3px 8px; overflow: hidden;
    font-family: var(--font);
    display: flex; flex-direction: column; justify-content: center; gap: 1px;
    transition: transform 0.1s ease; z-index: 2; min-width: 0;
  }
  .bar-seg:active { transform: scale(0.98); }
  .bar-seg.clip-top { border-top-left-radius: 0; border-top-right-radius: 0; }
  .bar-seg.clip-bottom { border-bottom-left-radius: 0; border-bottom-right-radius: 0; }
  .bs-title { font-size: 11px; font-weight: 800; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .bs-meta { font-size: 10px; font-weight: 600; opacity: 0.75; line-height: 1.2; white-space: nowrap; font-variant-numeric: tabular-nums; }
  .cat-bar-sleep { background: var(--sleep-soft); border-color: var(--sleep); color: var(--sleep-deep); }
  .cat-bar-feed { background: var(--feed-soft); border-color: var(--feed); color: var(--feed-deep); }
  .cat-bar-belly { background: var(--belly-soft); border-color: var(--belly); color: var(--belly-deep); }
  .cat-bar-act { background: var(--act-soft); border-color: var(--act); color: var(--act-deep); }
  .cat-bar-poop { background: var(--poop-soft); border-color: var(--poop); color: var(--poop-deep); }
  .cat-bar-note { background: var(--note-soft); border-color: var(--note); color: var(--note-deep); }
  .cat-bar-solid { background: var(--solid-soft); border-color: var(--solid); color: var(--solid-deep); }
  .bar-instant {
    position: absolute; transform: translateY(-50%); z-index: 3;
    display: flex; align-items: center; gap: 5px;
    border: none; cursor: pointer;
    background: var(--card); box-shadow: var(--shadow);
    border-radius: 99px; padding: 3px 10px 3px 4px;
    font-family: var(--font); font-size: 10.5px; font-weight: 700; color: var(--text);
    white-space: nowrap;
  }
  .bi-dot {
    width: 18px; height: 18px; border-radius: 50%; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
  }
  .bar-now { position: absolute; left: 0; right: 0; height: 0; border-top: 2px solid #d6605c; z-index: 4; }
  .bar-now::before {
    content: ''; position: absolute; left: -1px; top: -4.5px;
    width: 7px; height: 7px; border-radius: 50%; background: #d6605c;
  }
  .bars-legend {
    display: flex; gap: 14px; justify-content: center; flex-wrap: wrap;
    padding: 10px 4px 4px; border-top: 1px solid var(--line); margin-top: 10px;
  }
  .legend-item { display: flex; align-items: center; gap: 5px; font-size: 11px; font-weight: 600; color: var(--muted); }
  .legend-dot { width: 9px; height: 9px; border-radius: 3px; }

  /* ---------- Mehrere Kinder ---------- */
  .avatar-btn { border: none; cursor: pointer; font-family: var(--font); transition: transform 0.1s ease; }
  .avatar-btn:active { transform: scale(0.92); }
  .avatar-sm { width: 30px; height: 30px; font-size: 14px; flex-shrink: 0; }
  .baby-line { display: flex; align-items: center; gap: 10px; }
  .baby-age { font-size: 11.5px; color: var(--muted); font-weight: 600; }
  .option-on { box-shadow: inset 0 0 0 2px var(--primary); }
  .baby-switch { display: flex; align-items: center; gap: 7px; }
  .baby-chip { width: 38px; height: 38px; font-size: 16px; opacity: 0.45; transition: opacity 0.15s ease, box-shadow 0.15s ease, transform 0.1s ease; }
  .baby-chip.on { opacity: 1; box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px currentColor; }
  .baby-c0 { background: var(--feed-soft); color: var(--feed-deep); }
  .baby-c1 { background: var(--sleep-soft); color: var(--sleep-deep); }
  .baby-c2 { background: var(--act-soft); color: var(--act-deep); }
  .baby-c3 { background: var(--belly-soft); color: var(--belly-deep); }
  .baby-add {
    width: 34px; height: 34px;
    background: transparent; border: 1.5px dashed var(--line); color: var(--muted);
  }
  .baby-add:hover { border-color: var(--muted); color: var(--text); }

  /* ---------- Meilensteine ---------- */
  .ms-legend {
    display: flex; flex-wrap: wrap; gap: 7px 14px;
    padding: 11px 14px;
    background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  }
  .ms-list { display: flex; flex-direction: column; gap: 8px; }
  .ms-month { overflow: hidden; }
  .ms-current { box-shadow: var(--shadow), inset 0 0 0 2px var(--primary); }
  .ms-head {
    display: flex; align-items: center; gap: 11px;
    width: 100%; border: none; background: none; cursor: pointer; text-align: left;
    font-family: var(--font); color: var(--text);
    padding: 12px 14px;
  }
  .ms-num {
    width: 32px; height: 32px; border-radius: 50%; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
    background: var(--bg); color: var(--muted);
    font-size: 14px; font-weight: 800; font-variant-numeric: tabular-nums;
  }
  .ms-num-past { background: var(--act-soft); color: var(--act-deep); }
  .ms-num-now { background: var(--primary); color: #fff; }
  .ms-head-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
  .ms-title { font-size: 14.5px; font-weight: 800; }
  .ms-range { font-size: 11.5px; color: var(--muted); font-weight: 600; }
  .ms-progress { font-size: 11.5px; font-weight: 700; color: var(--muted); font-variant-numeric: tabular-nums; }
  .ms-chevron { color: var(--muted); display: flex; transition: transform 0.18s ease; }
  .ms-chevron.open { transform: rotate(90deg); }
  .ms-items { padding: 2px 14px 12px; display: flex; flex-direction: column; gap: 4px; }
  .ms-item {
    display: flex; align-items: flex-start; gap: 10px;
    border: none; background: var(--bg); cursor: pointer; text-align: left;
    font-family: var(--font); color: var(--text);
    padding: 10px 12px; border-radius: 11px;
    transition: transform 0.1s ease;
  }
  .ms-item:active { transform: scale(0.985); }
  .ms-check {
    width: 20px; height: 20px; border-radius: 50%; flex-shrink: 0;
    border: 2px solid var(--line); background: var(--card);
    display: flex; align-items: center; justify-content: center;
    color: #fff; margin-top: 1px;
    transition: all 0.15s ease;
  }
  .ms-check.on { border-color: transparent; }
  .ms-check.on.cat-sleep { background: var(--sleep); }
  .ms-check.on.cat-feed { background: var(--feed); }
  .ms-check.on.cat-belly { background: var(--belly); }
  .ms-check.on.cat-act { background: var(--act); }
  .ms-check.on.cat-poop { background: var(--poop); }
  .ms-check.on.cat-note { background: var(--note); }
  .ms-item-text { flex: 1; font-size: 12.5px; font-weight: 600; line-height: 1.45; }
  .ms-item.done .ms-item-text { color: var(--muted); }
  .ms-cat-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; margin-top: 6px; }

  /* ---------- Rezepte ---------- */
  .vegan-note { padding: 13px 15px; }
  .vegan-note-title {
    display: flex; align-items: center; gap: 7px;
    font-size: 13px; font-weight: 800; color: var(--solid-deep); margin-bottom: 7px;
    white-space: nowrap;
  }
  .vegan-list { margin: 0; padding-left: 17px; display: flex; flex-direction: column; gap: 4px; }
  .vegan-list li { font-size: 12px; color: var(--muted); line-height: 1.45; font-weight: 500; }
  .recipe-card {
    border: none; cursor: pointer; text-align: left; width: 100%;
    font-family: var(--font); color: var(--text);
    padding: 13px 15px;
    display: flex; flex-direction: column; gap: 8px;
    transition: transform 0.1s ease;
  }
  .recipe-card:active { transform: scale(0.985); }
  .recipe-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
  .recipe-title { font-size: 14.5px; font-weight: 800; line-height: 1.35; min-width: 0; }
  .stage-pill {
    font-size: 10.5px; font-weight: 800; padding: 4px 10px; border-radius: 99px;
    background: var(--solid-soft); color: var(--solid-deep); white-space: nowrap; flex-shrink: 0;
  }
  .recipe-meta { display: flex; flex-wrap: wrap; gap: 5px; align-items: center; }
  .ing-row {
    display: flex; align-items: center; gap: 9px;
    padding: 7px 0; border-bottom: 1px solid var(--line);
  }
  .ing-row:last-child { border-bottom: none; }
  .ing-text { flex: 1; font-size: 13px; font-weight: 600; }
  .step-list { margin: 0; padding-left: 19px; display: flex; flex-direction: column; gap: 8px; }
  .step-list li { font-size: 13px; line-height: 1.5; font-weight: 500; }
  .recipe-hint {
    font-size: 12px; color: var(--solid-deep); background: var(--solid-soft);
    border-radius: 12px; padding: 11px 13px; line-height: 1.5; margin: 0; font-weight: 600;
  }
  .allergy-pill {
    font-size: 10.5px; font-weight: 800; padding: 3px 9px; border-radius: 99px;
    background: #f7e1e1; color: #a04545; white-space: nowrap;
  }
  .allergy-banner {
    font-size: 12.5px; font-weight: 700; line-height: 1.5;
    background: #f7e1e1; color: #a04545;
    border-radius: 12px; padding: 11px 13px;
  }
  .allergen-info { font-size: 12px; font-weight: 600; color: var(--muted); }
  :root[data-theme="night"] .allergy-pill, :root[data-theme="night"] .allergy-banner {
    background: #4a3030; color: #e9a3a3;
  }

  /* ---------- Foto-Import ---------- */
  .photo-drop {
    display: flex; flex-direction: column; align-items: center; gap: 6px;
    border: 1.5px dashed var(--line); border-radius: var(--radius);
    padding: 28px 16px; cursor: pointer;
    font-size: 13.5px; font-weight: 700; color: var(--text);
    text-align: center;
  }
  .photo-drop:hover { border-color: var(--muted); }
  .photo-drop-sub { font-size: 11.5px; font-weight: 600; color: var(--muted); }
  .photo-preview { position: relative; }
  .photo-preview img {
    width: 100%; max-height: 240px; object-fit: cover;
    border-radius: calc(var(--radius) - 4px); display: block;
  }
  .photo-replace {
    position: absolute; bottom: 8px; right: 8px;
    background: rgba(20,15,25,0.65); color: #fff;
    font-size: 11px; font-weight: 700; padding: 5px 11px; border-radius: 99px;
    cursor: pointer; backdrop-filter: blur(6px);
  }
  .scan-status {
    display: flex; align-items: center; justify-content: center; gap: 9px;
    font-size: 13px; font-weight: 700; color: var(--muted);
    padding: 14px;
  }
  .scan-spinner {
    width: 16px; height: 16px; border-radius: 50%;
    border: 2.5px solid var(--line); border-top-color: var(--primary);
    animation: spin 0.8s linear infinite;
  }
  @keyframes spin { to { transform: rotate(360deg); } }
  .recipe-photo {
    width: 100%; max-height: 200px; object-fit: cover;
    border-radius: calc(var(--radius) - 4px); display: block;
  }

  /* ---------- Einkaufsliste ---------- */
  .shop-add-row { display: flex; gap: 8px; }
  .shop-add-row input {
    flex: 1; font-family: var(--font); font-size: 14.5px; font-weight: 600; color: var(--text);
    background: var(--card); border: 1.5px solid var(--line);
    border-radius: 13px; padding: 12px 14px; outline: none; min-width: 0;
  }
  .shop-add-row input:focus { border-color: var(--primary); }
  .shop-add-btn {
    width: 48px; border-radius: 13px; border: none; cursor: pointer; flex-shrink: 0;
    background: var(--primary); color: #fff;
    display: flex; align-items: center; justify-content: center;
  }
  .shop-add-btn:active { transform: scale(0.95); }
  .shop-row {
    display: flex; align-items: center; gap: 10px;
    background: var(--card); border-radius: calc(var(--radius) - 4px);
    box-shadow: var(--shadow); padding: 10px 12px;
  }
  .shop-text { flex: 1; font-size: 13.5px; font-weight: 600; cursor: pointer; }
  .shop-row.done .shop-text { color: var(--muted); text-decoration: line-through; }
  .clear-done-btn {
    border: none; background: none; cursor: pointer;
    font-family: var(--font); font-size: 12px; font-weight: 700; color: var(--muted);
    text-decoration: underline; text-underline-offset: 3px; padding: 0;
  }

  /* ---------- Mehr-Hub ---------- */
  .hub-row {
    display: flex; align-items: center; gap: 12px; width: 100%;
    border: none; cursor: pointer; text-align: left;
    background: var(--card); box-shadow: var(--shadow);
    border-radius: var(--radius); padding: 14px 16px;
    font-family: var(--font); font-size: 14.5px; font-weight: 700; color: var(--text);
    transition: transform 0.1s ease;
  }
  .hub-row:active { transform: scale(0.985); }
  .hub-icon {
    width: 38px; height: 38px; border-radius: 12px; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
  }
  .hub-main { flex: 1; display: flex; flex-direction: column; gap: 1px; }
  .hub-sub { font-size: 11.5px; font-weight: 600; color: var(--muted); }
  .hub-chev { color: var(--muted); display: flex; }
  .back-bar {
    display: flex; align-items: center; gap: 4px;
    border: none; background: none; cursor: pointer;
    font-family: var(--font); font-size: 13px; font-weight: 700; color: var(--muted);
    padding: 0 0 10px;
  }
  .back-bar:hover { color: var(--text); }

  /* ---------- Ratgeber ---------- */
  .advice-card { overflow: hidden; }
  .advice-attention { box-shadow: var(--shadow), inset 0 0 0 1.5px var(--belly); }
  .advice-head {
    display: flex; gap: 12px; align-items: flex-start; width: 100%;
    border: none; background: none; cursor: pointer; text-align: left;
    font-family: var(--font); color: var(--text);
    padding: 14px 15px;
  }
  .advice-main { flex: 1; min-width: 0; }
  .advice-body { padding: 0 15px 14px; }
  .advice-tips { margin: 0; padding-left: 19px; display: flex; flex-direction: column; gap: 7px; }
  .advice-tips li { font-size: 12.5px; line-height: 1.5; font-weight: 500; }
  .redflag-box {
    margin-top: 12px; background: #f7e1e1; color: #a04545;
    border-radius: 12px; padding: 11px 13px;
  }
  :root[data-theme="night"] .redflag-box { background: #4a3030; color: #e9a3a3; }
  .redflag-title { font-size: 12px; font-weight: 800; margin-bottom: 6px; }
  .redflag-box ul { margin: 0; padding-left: 17px; display: flex; flex-direction: column; gap: 3px; }
  .redflag-box li { font-size: 12px; line-height: 1.45; font-weight: 600; }
  .advice-teaser {
    display: flex; gap: 11px; align-items: flex-start;
    padding: 13px 13px 13px 15px;
    border-left: 4px solid var(--belly);
  }
  .teaser-main { flex: 1; min-width: 0; }
  .teaser-title { font-size: 13px; font-weight: 800; }
  .teaser-text {
    font-size: 12px; color: var(--muted); line-height: 1.45; margin-top: 2px;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  }
  .teaser-link {
    border: none; background: none; cursor: pointer; padding: 0; margin-top: 7px;
    font-family: var(--font); font-size: 12.5px; font-weight: 800; color: var(--belly-deep);
    text-decoration: underline; text-underline-offset: 3px;
  }
  .teaser-x { width: 26px; height: 26px; flex-shrink: 0; }

  /* ---------- Mono-Kicker & Suche ---------- */
  .kicker {
    font-family: var(--font-mono); font-size: 10.5px; font-weight: 700;
    letter-spacing: 1px; text-transform: uppercase; color: var(--muted);
  }
  .search-bar {
    display: flex; align-items: center; gap: 9px;
    background: var(--card); border: 1.5px solid var(--line);
    border-radius: 99px; padding: 10px 16px;
    color: var(--muted);
  }
  .search-bar input {
    flex: 1; border: none; outline: none; background: none; min-width: 0;
    font-family: var(--font); font-size: 14px; font-weight: 600; color: var(--text);
  }
  .search-bar:focus-within { border-color: var(--primary); }
  .pill-row { display: flex; gap: 7px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
  .pill-row::-webkit-scrollbar { display: none; }
  .age-pill {
    border: 1.5px solid var(--line); background: var(--card); cursor: pointer;
    border-radius: 99px; padding: 9px 16px; white-space: nowrap; flex-shrink: 0;
    font-family: var(--font); font-size: 13px; font-weight: 700; color: var(--text);
    transition: all 0.12s ease;
  }
  .age-pill.on { background: var(--primary); border-color: var(--primary); color: #fff; }
  .filter-row { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }

  /* ---------- Rezepte v2 ---------- */
  .recipe-card { gap: 7px; border: 1.5px solid var(--line); box-shadow: none; }
  .recipe-card:hover { border-color: var(--primary); }
  .recipe-emoji {
    width: 44px; height: 44px; border-radius: 13px;
    background: var(--bg); display: flex; align-items: center; justify-content: center;
    font-size: 24px; flex-shrink: 0;
  }
  .recipe-emoji-lg { width: 56px; height: 56px; font-size: 30px; border-radius: 16px; }
  .stage-pill {
    font-family: var(--font-mono); letter-spacing: 0.5px;
  }
  .recipe-desc {
    font-size: 12.5px; color: var(--muted); line-height: 1.5; font-weight: 500;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  }
  .recipe-bottom { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
  .recipe-time {
    display: flex; align-items: center; gap: 5px;
    font-size: 12px; font-weight: 600; color: var(--muted);
  }
  .recipe-detail-head { display: flex; align-items: center; gap: 13px; }
  .recipe-detail-title { font-size: 18px; font-weight: 800; margin-top: 5px; }
  .recipe-desc-box {
    background: var(--bg); border-radius: 12px; padding: 12px 14px;
    font-size: 13px; line-height: 1.55; color: var(--text); font-weight: 500;
  }
  .ing-row-check { background: none; cursor: pointer; width: 100%; text-align: left; font-family: var(--font); color: var(--text); }

  /* ---------- Analyse-Karten ---------- */
  .stat-big { padding: 15px 17px 13px; display: flex; flex-direction: column; gap: 7px; }
  .stat-big-kicker { display: flex; align-items: center; gap: 6px; }
  .stat-big-line { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
  .stat-big-value { font-size: 26px; font-weight: 800; letter-spacing: -0.5px; font-variant-numeric: tabular-nums; }
  .stat-big-status { font-family: var(--font-mono); font-size: 11px; font-weight: 700; letter-spacing: 0.8px; }
  .stat-big-text { font-size: 12.5px; color: var(--muted); line-height: 1.5; }

  /* ---------- Allergie-Journal ---------- */
  .journal-form { padding: 16px; }
  .journal-form-head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
  .journal-plus {
    width: 38px; height: 38px; border-radius: 50%; flex-shrink: 0;
    background: #f7e1e1; color: #c64a4a;
    display: flex; align-items: center; justify-content: center;
  }
  :root[data-theme="night"] .journal-plus { background: #4a3030; color: #e9a3a3; }
  .journal-title { font-size: 16px; font-weight: 800; margin-top: 2px; }
  .journal-row { position: relative; padding: 13px 15px; display: flex; flex-direction: column; gap: 4px; }
  .journal-row-top { display: flex; align-items: center; justify-content: space-between; }
  .journal-date { font-family: var(--font-mono); font-size: 11px; font-weight: 700; color: var(--muted); letter-spacing: 0.5px; }
  .journal-food { font-size: 14px; font-weight: 800; }
  .journal-symptoms { font-size: 12.5px; font-weight: 600; color: var(--text); }
  .journal-note { font-size: 12px; color: var(--muted); font-style: italic; line-height: 1.45; }
  .journal-x { position: absolute; right: 10px; bottom: 10px; width: 26px; height: 26px; }
  .sev-dots { display: flex; gap: 4px; }
  .sev-dot { width: 11px; height: 11px; border-radius: 50%; }

  /* ---------- Wachstum ---------- */
  .guide-card { padding: 16px; background: var(--sleep-soft); box-shadow: none; }
  .guide-head { display: flex; align-items: center; gap: 11px; margin-bottom: 12px; }
  .guide-icon {
    width: 38px; height: 38px; border-radius: 12px; flex-shrink: 0;
    background: var(--sleep); color: #fff;
    display: flex; align-items: center; justify-content: center;
  }
  .guide-name { font-size: 14.5px; font-weight: 800; }
  .guide-title { font-size: 14px; font-weight: 800; color: var(--sleep-deep); margin-bottom: 5px; }
  .guide-text { font-size: 12.5px; line-height: 1.6; color: var(--text); margin: 0; font-weight: 500; }
  .growth-form { padding: 16px; }
  .growth-form .form-row { margin-bottom: 12px; }
  .growth-chart-card { padding: 15px 16px; }
  .growth-chart-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
  .growth-svg { width: 100%; height: auto; display: block; }
  .growth-grid-label { font-family: var(--font-mono); font-size: 10px; font-weight: 700; fill: var(--muted); }
  .growth-pt-label { font-family: var(--font-mono); font-size: 11.5px; font-weight: 700; fill: var(--text); }
  .measure-row { display: flex; align-items: center; gap: 10px; padding: 11px 13px; }
  .measure-vals { flex: 1; font-size: 13.5px; font-weight: 700; font-variant-numeric: tabular-nums; }

  /* ---------- 24h-Spuren ---------- */
  .lanes-card { padding: 12px 0 8px; overflow: hidden; }
  .lanes-scroll { overflow-x: auto; scrollbar-width: thin; }
  .lanes-inner { padding: 0 12px; }
  .lane-row { display: flex; align-items: center; gap: 0; margin-bottom: 7px; }
  .lane-label {
    position: sticky; left: 0; z-index: 3;
    width: 96px; flex-shrink: 0;
    display: flex; align-items: center; gap: 5px;
    font-family: var(--font-mono); font-size: 10px; font-weight: 700;
    letter-spacing: 0.5px; text-transform: uppercase;
    background: var(--card); padding: 8px 6px 8px 2px;
  }
  .lane-track {
    position: relative; height: 38px; border-radius: 11px;
    flex-shrink: 0;
  }
  .lane-tick { position: absolute; top: 0; bottom: 0; width: 1px; background: rgba(0,0,0,0.05); }
  :root[data-theme="night"] .lane-tick { background: rgba(255,255,255,0.06); }
  .lane-now { position: absolute; top: -2px; bottom: -2px; width: 2px; background: #d6605c; z-index: 2; border-radius: 2px; }
  .lane-pill {
    position: absolute; top: 5px; height: 28px;
    border: none; cursor: pointer; border-radius: 9px;
    display: flex; align-items: center; justify-content: center;
    font-family: var(--font-mono); font-size: 10.5px; font-weight: 700;
    padding: 0 5px; white-space: nowrap; overflow: hidden;
    box-shadow: 0 1px 3px rgba(40,30,25,0.18);
  }
  .lane-pill:active { transform: scale(0.96); }
  .lane-axis { position: relative; height: 18px; flex-shrink: 0; }
  .lane-axis > span {
    position: absolute; transform: translateX(-50%);
    font-family: var(--font-mono); font-size: 10px; font-weight: 700; color: var(--muted);
    white-space: nowrap;
  }
  .lane-axis > span span { position: static; transform: none; }
  .lane-axis > span:first-child { transform: none; }

  .stat-big-grid { display: flex; flex-direction: column; gap: 14px; }

  /* ---------- Desktop-Layout ---------- */
  @media (min-width: 701px) {
    .app { flex-direction: row; }
    .bottom-nav {
      position: static; order: -1;
      width: 230px; flex-shrink: 0;
      flex-direction: column; align-items: stretch; justify-content: flex-start; gap: 3px;
      padding: 22px 14px;
      border-top: none; border-right: 1px solid var(--line);
      backdrop-filter: none; -webkit-backdrop-filter: none;
      overflow-y: auto;
    }
    .nav-brand {
      display: flex; align-items: center; gap: 11px;
      font-size: 15px; font-weight: 800; color: var(--text);
      padding: 4px 11px 18px;
    }
    .nav-brand-logo {
      width: 34px; height: 34px; border-radius: 11px; flex-shrink: 0;
      object-fit: contain; display: block;
    }
    .nav-btn {
      flex-direction: row; justify-content: flex-start; gap: 12px;
      font-size: 13.5px; padding: 11px 13px; width: 100%; border-radius: 11px;
    }
    .nav-btn.on { background: var(--primary-soft); }
    .nav-theme {
      display: flex; align-items: center; gap: 12px;
      margin-top: auto;
      border: 1.5px dashed var(--line); background: none; cursor: pointer;
      font-family: var(--font); font-size: 12.5px; font-weight: 700; color: var(--muted);
      padding: 11px 13px; width: 100%; border-radius: 11px;
      transition: all 0.15s ease;
    }
    .nav-theme:hover { color: var(--text); border-color: var(--muted); }
    .nav-collapse {
      display: flex; align-items: center; justify-content: center;
      position: absolute; z-index: 40;
      left: calc(230px - 17px); top: 50%; transform: translateY(-50%);
      width: 34px; height: 34px; border-radius: 50%;
      background: var(--card); color: var(--muted);
      border: 1.5px solid var(--line);
      box-shadow: 0 2px 8px rgba(40,30,25,0.12);
      cursor: pointer;
      transition: left 0.2s ease, color 0.15s ease, border-color 0.15s ease;
    }
    .nav-collapse:hover { color: var(--primary-deep); border-color: var(--primary); }
    .nav-collapse:active { transform: translateY(-50%) scale(0.92); }
    .bottom-nav.nav-collapsed + .nav-collapse { left: calc(74px - 17px); }
    .bottom-nav { transition: width 0.2s ease; }
    .bottom-nav.nav-collapsed { width: 74px; padding: 22px 10px; }
    .nav-collapsed .nav-btn span, .nav-collapsed .nav-theme span { display: none; }
    .nav-collapsed .nav-brand > span:last-child { display: none; }
    .nav-collapsed .nav-btn, .nav-collapsed .nav-theme {
      justify-content: center; padding: 11px 0; gap: 0;
    }
    .nav-collapsed .nav-brand { justify-content: center; padding: 4px 0 18px; }
    .app-scroll { padding: 32px 40px 80px; }
    .app-scroll > * { max-width: 820px; margin-left: auto; margin-right: auto; }
    .page-head h1 { font-size: 30px; }
    .summary-grid { grid-template-columns: repeat(6, 1fr); }
    .qa-grid { grid-template-columns: repeat(8, 1fr); }
    .recipe-list { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; align-items: stretch; }
    .stat-big-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
    .sheet-backdrop { align-items: center; padding: 28px; }
    .sheet {
      max-width: 640px; max-height: 86%;
      border-radius: calc(var(--radius) + 6px);
    }
    .sheet-tall { height: auto; max-height: 90%; }
    .toast {
      left: 50%; right: auto; transform: translateX(-50%);
      min-width: 380px; max-width: 560px; bottom: 28px;
    }
    .bars-canvas { max-width: none; }
    .growth-svg { max-width: 560px; margin: 0 auto; }
  }

  /* ---------- Toast ---------- */
  .toast {
    position: absolute; bottom: 92px; left: 18px; right: 18px; z-index: 35;
    display: flex; align-items: center; gap: 9px;
    background: var(--text); color: var(--bg);
    border-radius: 14px; padding: 12px 15px;
    font-size: 13px; font-weight: 600;
    box-shadow: 0 8px 24px rgba(20,15,25,0.25);
    animation: slideUp 0.2s ease;
  }
  .toast-action {
    margin-left: auto; border: none; background: none; cursor: pointer;
    font-family: var(--font); font-size: 13px; font-weight: 800;
    color: inherit; text-decoration: underline; text-underline-offset: 3px;
    flex-shrink: 0;
  }

  .login-screen {
    min-height: 100dvh; display: flex; align-items: center; justify-content: center;
    padding: 24px; background: var(--bg);
  }
  .login-card {
    width: 100%; max-width: 360px;
    display: flex; flex-direction: column; align-items: center; gap: 6px;
    background: var(--card); border: 1px solid var(--line);
    border-radius: var(--radius); padding: 32px 26px;
    box-shadow: 0 10px 40px rgba(40,30,25,0.10);
  }
  .login-logo { width: 72px; height: 72px; object-fit: contain; }
  .login-title { font-size: 22px; font-weight: 800; color: var(--text); margin: 4px 0 0; }
  .login-card .form-stack { width: 100%; margin-top: 14px; }
