:root {
  color-scheme: light;
  --bg: #f4f5f7;
  --surface: rgba(255, 255, 255, .72);
  --surface-strong: #fff;
  --text: #111317;
  --muted: #6d727b;
  --soft: #eceef1;
  --line: rgba(17, 19, 23, .09);
  --accent: #7b90ab;
  --accent-deep: #647a98;
  --accent-soft: #e8edf3;
  --shadow: 0 18px 50px rgba(23, 29, 38, .07), 0 2px 10px rgba(23, 29, 38, .03);
  --radius: 24px;
  --sidebar: 244px;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", Inter, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { background: var(--bg); }
body { margin: 0; min-width: 320px; color: var(--text); background: radial-gradient(circle at 72% 0, rgba(123,144,171,.11), transparent 24rem), var(--bg); font-size: 17px; }
button, input, textarea, select { font: inherit; }
button { color: inherit; }
.en-hint { display: none; }
body.bilingual .en-hint { display: block; }
.phrase-hint { margin-top: 4px; color: #959aa2; font-size: 9px; font-weight: 450; letter-spacing: .01em; }
.svg-defs { position: absolute; width: 0; height: 0; overflow: hidden; }
svg { fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }

.app-shell { min-height: 100vh; }
.sidebar { position: fixed; z-index: 40; inset: 0 auto 0 0; width: var(--sidebar); padding: 22px 16px 18px; display: flex; flex-direction: column; background: linear-gradient(180deg,rgba(235,238,242,.97),rgba(228,232,237,.95)); border-right: 1px solid rgba(17,19,23,.12); backdrop-filter: blur(28px) saturate(120%); -webkit-backdrop-filter: blur(28px) saturate(120%); }
.brand { height: 56px; display: flex; align-items: center; gap: 12px; padding: 0 10px 16px; }
.brand-mark { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 12px; color: white; background: #17191d; font-weight: 700; box-shadow: 0 7px 16px rgba(0,0,0,.12); }
.brand strong, .brand span { display: block; line-height: 1.05; }
.brand strong { font-size: 14px; letter-spacing: .01em; }
.brand span { color: var(--muted); font-size: 13px; margin-top: 4px; }
.nav { flex: 1; overflow-y: auto; scrollbar-width: none; padding-top: 8px; }
.nav::-webkit-scrollbar { display: none; }
.nav-group { margin: 12px 0 16px; }
.nav-group-title { border: 0; background: transparent; width: 100%; padding: 0 12px 8px; display: flex; justify-content: space-between; color: #8c9199; font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; cursor: pointer; }
.nav-group-title .en-hint { margin-top: 3px; font-size: 8px; letter-spacing: .08em; }
.nav-group.collapsed .nav-group-items { display: none; }
.nav-group.collapsed .nav-group-title span:last-child { transform: rotate(90deg); }
.nav-item { width: 100%; min-height: 44px; border: 0; border-radius: 12px; background: transparent; display: flex; align-items: center; gap: 11px; padding: 7px 12px; margin: 2px 0; color: #555b63; font-size: 14px; cursor: pointer; transition: .18s ease; text-align: left; }
.nav-item svg { width: 18px; height: 18px; }
.nav-item > span { line-height: 1.15; }
.nav-item .en-hint { margin-top: 3px; color: #8f959e; font-size: 10px; font-weight: 500; letter-spacing: .01em; }
body.bilingual .nav-item { min-height: 52px; }
.nav-item:hover { color: var(--text); background: rgba(255,255,255,.58); }
.nav-item.active { color: #28374a; background: rgba(210,218,227,.9); font-weight: 650; }
.settings-item { flex: 0 0 auto; }
.sidebar-profile { display: grid; grid-template-columns: 34px 1fr 16px; align-items: center; gap: 10px; border-top: 1px solid var(--line); padding: 16px 8px 0; margin-top: 8px; }
.avatar, .mini-avatar { border: 0; display: grid; place-items: center; color: white; background: #191b20; border-radius: 50%; font-weight: 650; }
.avatar { width: 34px; height: 34px; font-size: 12px; }
.sidebar-profile strong, .sidebar-profile span { display: block; }
.sidebar-profile strong { font-size: 12px; }
.sidebar-profile span { margin-top: 3px; color: var(--muted); font-size: 10px; }
.sidebar-profile > svg { width: 14px; height: 14px; color: #9a9ea5; }

.main { min-height: 100vh; margin-left: var(--sidebar); }
.topbar { position: sticky; z-index: 30; top: 0; height: 76px; padding: 0 clamp(22px, 4vw, 54px); display: flex; align-items: center; border-bottom: 1px solid transparent; backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); }
.topbar.scrolled { background: rgba(244,245,247,.78); border-color: var(--line); }
.search-pill { width: 260px; height: 40px; border: 1px solid var(--line); border-radius: 13px; background: rgba(255,255,255,.62); color: #777d86; display: flex; justify-content: space-between; align-items: center; padding: 0 13px; cursor: pointer; font-size: 13px; }
.search-pill kbd { border: 1px solid var(--line); border-radius: 6px; background: #fff; padding: 2px 6px; color: #9b9fa6; font-size: 10px; box-shadow: 0 1px 2px rgba(0,0,0,.04); }
.topbar-actions { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.language-toggle { height: 32px; display: flex; align-items: center; gap: 6px; padding: 3px 8px 3px 3px; border: 1px solid var(--line); border-radius: 999px; color: #8a8f97; background: rgba(255,255,255,.62); font-size: 9px; cursor: pointer; }
.language-toggle span { padding: 5px 7px; border-radius: 999px; color: white; background: #272a2f; }
.language-toggle strong { font-weight: 650; }
.language-toggle[aria-pressed="true"] { color: #536982; background: var(--accent-soft); }
.preview-pill { padding: 7px 10px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); background: rgba(255,255,255,.62); font-size: 11px; }
.cloud-sync-pill { padding:6px 9px; border:1px solid var(--line); border-radius:999px; color:#747b84; background:rgba(255,255,255,.48); font-size:10px; white-space:nowrap; }
.cloud-sync-pill[data-mode="pending"] { color:#66778b; }
.cloud-sync-pill[data-mode="ok"]::before { content:'•'; color:#748f7e; margin-right:5px; }
.cloud-sync-pill[data-mode="offline"] { color:#8a7771; }
.icon-button { position: relative; width: 38px; height: 38px; border: 1px solid var(--line); border-radius: 12px; background: rgba(255,255,255,.65); display: grid; place-items: center; cursor: pointer; }
.icon-button svg { width: 18px; height: 18px; }
.mini-avatar { width: 38px; height: 38px; cursor: pointer; }
.notification-dot { position: absolute; top: 7px; right: 7px; width: 5px; height: 5px; border-radius: 50%; background: var(--accent-deep); }
.menu-button { display: none; margin-right: 10px; }
.notification-panel { position: absolute; top: 66px; right: clamp(22px, 4vw, 54px); width: 292px; padding: 17px; border: 1px solid var(--line); border-radius: 18px; background: rgba(255,255,255,.92); box-shadow: var(--shadow); opacity: 0; visibility: hidden; transform: translateY(-6px); transition: .18s ease; }
.notification-panel.open { opacity: 1; visibility: visible; transform: translateY(0); }
.notification-panel strong { font-size: 13px; }
.notification-panel p { color: var(--muted); font-size: 12px; line-height: 1.55; margin: 8px 0 0; }

.page { width: min(1420px, 100%); margin: 0 auto; padding: 28px clamp(22px, 4vw, 54px) 120px; }
.page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin: 8px 0 28px; }
.eyebrow, .section-kicker { margin: 0; color: var(--accent-deep); font-size: 12px; font-weight: 750; letter-spacing: .11em; text-transform: uppercase; }
.page-heading h1 { margin: 10px 0 7px; font-size: clamp(36px, 3.5vw, 50px); letter-spacing: -.045em; line-height: 1.05; }
.page-heading > div > p:last-child { margin: 0; color: var(--muted); font-size: 16px; }
.primary-button, .secondary-button { border-radius: 12px; height: 43px; padding: 0 17px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; cursor: pointer; transition: .18s ease; font-size: 13px; }
.primary-button { border: 1px solid #17191d; color: white; background: #17191d; box-shadow: 0 8px 22px rgba(17,19,23,.12); }
.primary-button:hover { transform: translateY(-1px); background: #292c32; }
.primary-button svg { width: 16px; height: 16px; }
.secondary-button { border: 1px solid var(--line); background: white; color: #34383f; }
.secondary-button:hover { border-color: rgba(17,19,23,.18); transform: translateY(-1px); }
.text-button { border: 0; background: transparent; color: var(--accent-deep); font-size: 13px; font-weight: 600; cursor: pointer; }

.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 12px; }
.metric-card, .card { border: 1px solid rgba(255,255,255,.85); background: var(--surface); backdrop-filter: blur(24px) saturate(115%); -webkit-backdrop-filter: blur(24px) saturate(115%); box-shadow: var(--shadow); }
.metric-card { min-height: 134px; border-radius: 20px; padding: 20px; }
.metric-label { color: var(--muted); font-size: 13px; }
.metric-label .en-hint, h2 .en-hint { margin-top: 3px; color: #9a9fa7; font-size: 8px; font-weight: 500; letter-spacing: .01em; }
.metric-value { display: flex; align-items: baseline; gap: 7px; margin: 14px 0 13px; }
.metric-value strong { font-size: 29px; letter-spacing: -.04em; }
.metric-value span, .tiny-caption { color: var(--muted); font-size: 12px; }
.progress { height: 5px; border-radius: 999px; background: var(--soft); overflow: hidden; }
.progress span { display: block; width: 0; height: 100%; border-radius: inherit; background: var(--accent); transition: width .35s ease; }
.dashboard-grid { display: grid; grid-template-columns: repeat(12, minmax(0,1fr)); gap: 12px; }
.card { border-radius: var(--radius); padding: 25px; overflow: hidden; }
.priorities-card { grid-column: span 7; }
.schedule-card { grid-column: span 5; }
.habits-card, .movement-card { grid-column: span 6; }
.movement-card { align-self: start; }
.mood-card { grid-column: span 5; }
.flash-card { grid-column: span 7; }
.review-card { grid-column: span 12; }
.card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.card-head h2 { margin: 6px 0 0; font-size: 21px; letter-spacing: -.025em; }
.card-meta { color: var(--muted); font-size: 12px; }

.task-row { display: grid; grid-template-columns: 27px 1fr auto; align-items: center; gap: 13px; min-height: 72px; border-bottom: 1px solid var(--line); cursor: pointer; }
.task-row input, .habit-row input { position: absolute; opacity: 0; pointer-events: none; }
.checkmark { width: 25px; height: 25px; border: 1.5px solid #b9bec5; border-radius: 8px; display: grid; place-items: center; transition: .16s ease; }
.checkmark svg { width: 13px; height: 13px; opacity: 0; }
.task-row input:checked + .checkmark { background: var(--accent); border-color: var(--accent); color: white; }
.task-row input:checked + .checkmark svg { opacity: 1; }
.task-row input:checked ~ .task-copy { opacity: .48; text-decoration: line-through; }
.task-copy strong, .task-copy small { display: block; }
.task-copy strong { font-size: 15px; font-weight: 630; }
.task-copy small { margin-top: 6px; color: var(--muted); font-size: 12px; }
.task-copy small .en-hint, .habit-row small .en-hint { margin-top: 3px; color: #9a9fa7; font-size: 8px; }
.priority-tag { padding: 6px 9px; border-radius: 999px; color: #61666d; background: #f0f1f3; font-size: 11px; }
.priority-tag.high { color: #52657f; background: #e5eaf0; }
.add-line { border: 0; background: transparent; padding: 16px 0 0; display: flex; align-items: center; gap: 7px; color: var(--accent-deep); font-size: 13px; cursor: pointer; }
.add-line svg { width: 14px; height: 14px; }
.home-task-empty { min-height: 216px; display: grid; place-content: center; text-align: center; color: var(--muted); }
.home-task-empty strong, .home-task-empty span { display: block; }
.home-task-empty strong { color: #3d4249; font-size: 14px; }
.home-task-empty span { margin-top: 7px; font-size: 11px; }
.empty-schedule { min-height: 199px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; border: 1px dashed rgba(17,19,23,.13); border-radius: 17px; padding: 24px; }
.calendar-glyph { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 12px; background: var(--accent-soft); color: var(--accent-deep); margin-bottom: 12px; }
.calendar-glyph svg { width: 19px; height: 19px; }
.empty-schedule strong { font-size: 15px; }
.empty-schedule p { max-width: 320px; margin: 8px 0 16px; color: var(--muted); font-size: 12px; line-height: 1.6; }
.empty-schedule .secondary-button { height: 34px; font-size: 10px; }

.habit-row { min-height: 76px; display: grid; grid-template-columns: minmax(0, 1fr) 34px; align-items: center; gap: 16px; border-bottom: 1px solid var(--line); cursor: pointer; }
.habit-row:last-child { border-bottom: 0; }
.habit-row > span:last-child { grid-column: 1; grid-row: 1; }
.habit-dot { position: relative; grid-column: 2; grid-row: 1; justify-self: end; width: 28px; height: 28px; border: 1.5px solid #aeb4bc; border-radius: 50%; background: rgba(255,255,255,.72); box-shadow: 0 0 0 6px #f0f2f4; transition: .16s ease; }
.habit-dot::after { content: ""; position: absolute; left: 8px; top: 7px; width: 9px; height: 5px; border-left: 2px solid white; border-bottom: 2px solid white; opacity: 0; transform: rotate(-45deg); transition: .16s ease; }
.habit-row input:checked + .habit-dot { border-color: var(--accent-deep); background: var(--accent); box-shadow: 0 0 0 6px var(--accent-soft); }
.habit-row input:checked + .habit-dot::after { opacity: 1; }
.habit-row strong, .habit-row small { display: block; }
.habit-row strong { font-size: 15px; }
.habit-row small { margin-top: 6px; color: var(--muted); font-size: 12px; }
.habit-row input:checked ~ span:last-child { opacity: .48; }
.movement-content { display: grid; grid-template-columns: 90px 1fr; align-items: center; gap: 18px; min-height: 125px; }
.ring { --pct: 66%; width: 84px; height: 84px; display: grid; place-content: center; text-align: center; border-radius: 50%; background: radial-gradient(circle at center, white 60%, transparent 62%), conic-gradient(var(--accent) var(--pct), var(--soft) 0); }
.ring span { font-size: 25px; font-weight: 700; letter-spacing: -.04em; }
.ring small { color: var(--muted); font-size: 9px; }
.movement-copy strong { font-size: 15px; }
.movement-copy p { margin: 7px 0 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
.segmented-actions { display: grid; grid-template-columns: repeat(4,1fr); gap: 6px; }
.segmented-actions button { height: 38px; border: 1px solid var(--line); border-radius: 10px; background: rgba(255,255,255,.6); color: #545a62; font-size: 12px; cursor: pointer; }
.segmented-actions button .en-hint { margin-left: 4px; font-size: 8px; }
body.bilingual .segmented-actions button .en-hint { display: inline; }
.segmented-actions button:hover { color: #34435a; background: var(--accent-soft); }
.movement-history-head { margin-top: 19px; padding-top: 16px; border-top: 1px solid var(--line); display: flex; align-items: end; justify-content: space-between; gap: 12px; }
.movement-history-head strong, .movement-history-head small { display: block; }
.movement-history-head strong { font-size: 13px; }
.movement-history-head small { margin-top: 3px; color: #a0a5ac; font-size: 8px; letter-spacing: .08em; }
.movement-history-head > span { color: var(--muted); font-size: 9px; }
.movement-history { margin-top: 9px; display: grid; gap: 5px; }
.movement-history article { min-height: 52px; display: grid; grid-template-columns: 34px minmax(0,1fr) 28px; align-items: center; gap: 10px; padding: 6px 7px; border: 1px solid var(--line); border-radius: 12px; background: rgba(255,255,255,.43); }
.movement-log-icon { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 10px; background: var(--accent-soft); color: var(--accent-deep); font-size: 11px; font-weight: 700; }
.movement-history article strong, .movement-history article small { display: block; }
.movement-history article strong { font-size: 11px; }
.movement-history article small { margin-top: 4px; color: var(--muted); font-size: 9px; }
.movement-history article button { width: 28px; height: 28px; border: 0; border-radius: 9px; background: transparent; color: #a0a5ac; cursor: pointer; }
.movement-history article button:hover { background: var(--soft); color: #444950; }
.movement-history-empty { min-height: 86px; display: grid; place-content: center; text-align: center; border: 1px dashed rgba(17,19,23,.12); border-radius: 13px; padding: 15px; }
.movement-history-empty strong, .movement-history-empty span { display: block; }
.movement-history-empty strong { color: #4a4f56; font-size: 11px; }
.movement-history-empty span { max-width: 350px; margin-top: 5px; color: var(--muted); font-size: 9px; line-height: 1.55; }
.movement-duration-label { margin-top: 13px; }

.mood-scale { display: grid; grid-template-columns: repeat(5,1fr); gap: 8px; min-height: 104px; align-items: center; }
.mood-scale button { border: 0; background: transparent; display: flex; flex-direction: column; align-items: center; gap: 10px; color: var(--muted); font-size: 11px; cursor: pointer; }
.mood-scale button span { width: 30px; height: 30px; border: 1px solid #c7cbd0; border-radius: 50%; background: rgba(255,255,255,.5); transition: .18s ease; position: relative; }
.mood-scale button span::before, .mood-scale button span::after { content: ""; position: absolute; top: 9px; width: 3px; height: 3px; background: #777c84; border-radius: 50%; }
.mood-scale button span::before { left: 8px; } .mood-scale button span::after { right: 8px; }
.mood-scale button.active span, .mood-scale button:hover span { background: var(--accent-soft); border-color: var(--accent); transform: translateY(-2px); }
.mood-note { margin-top: 4px; padding-top: 16px; border-top: 1px solid var(--line); }
.mood-note label { display: block; margin-bottom: 10px; }
.mood-note label strong, .mood-note label small { display: block; }
.mood-note label strong { font-size: 14px; font-weight: 640; }
.mood-note label small { margin-top: 5px; color: var(--muted); font-size: 11px; line-height: 1.55; }
.mood-note label .en-hint { margin-top: 2px; color: #9a9fa7; font-size: 8px; }
.mood-note textarea { resize: vertical; width: 100%; min-height: 96px; border: 1px solid var(--line); border-radius: 15px; background: rgba(255,255,255,.58); padding: 13px 14px; outline: none; color: var(--text); font: inherit; font-size: 13px; line-height: 1.65; }
.mood-note textarea:focus { border-color: rgba(100,122,152,.45); box-shadow: 0 0 0 3px var(--accent-soft); }
.mood-note textarea::placeholder { color: #a5a9af; }
.mood-note-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 9px; }
.mood-note-footer > span { color: var(--muted); font-size: 10px; }
.mood-note-footer .secondary-button { flex: 0 0 auto; height: 34px; padding: 0 12px; font-size: 10px; }
.capture-tabs { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 4px; width: 100%; min-width: 0; padding: 3px; border-radius: 10px; background: var(--soft); }
.capture-tabs button { min-width: 0; border: 0; border-radius: 8px; background: transparent; padding: 7px 9px; color: var(--muted); font-size: 10px; line-height: 1.2; white-space: nowrap; word-break: keep-all; writing-mode: horizontal-tb; cursor: pointer; }
.capture-tabs button.active { background: white; color: #363a40; box-shadow: 0 1px 4px rgba(0,0,0,.06); }
.flash-form textarea { resize: none; width: 100%; border: 1px solid var(--line); border-radius: 15px; background: rgba(255,255,255,.58); padding: 14px; outline: none; color: var(--text); font-size: 14px; }
.flash-form textarea:focus { border-color: rgba(100,122,152,.45); box-shadow: 0 0 0 3px var(--accent-soft); }
.flash-form > div { display: flex; align-items: center; justify-content: space-between; margin-top: 8px; }
.flash-form > div span { color: var(--muted); font-size: 11px; }
.flash-form .secondary-button { height: 32px; font-size: 10px; }
.recent-capture { margin-top: 9px; padding: 11px 13px; border-radius: 11px; background: rgba(236,238,241,.65); color: var(--muted); font-size: 11px; }
.tree-preview { display: grid; grid-template-columns: 170px 1fr; align-items: center; gap: 30px; min-height: 150px; }
.tree-art { position: relative; width: 180px; height: 145px; margin: 0 auto; }
.tree-svg { display:block; width:100%; height:100%; overflow:visible; }
.tree-svg-ground,.tree-svg-trunk,.tree-svg-branch { fill:none; stroke-linecap:round; }
.tree-svg-ground { stroke:#c4c9c8; stroke-width:4; }
.tree-svg-trunk { stroke:#737d7b; stroke-width:8; }
.tree-svg-branch { stroke:#858f8d; stroke-width:4; stroke-dasharray:70; stroke-dashoffset:70; animation:treeSvgBranchGrow .38s ease-out var(--grow-delay,0s) forwards; }
.tree-svg-leaf { stroke:none; opacity:0; animation:treeSvgLeafFade .28s ease-out var(--leaf-delay,0s) forwards; }
.tree-svg-leaf.leaf-work { fill:#79977f; }
.tree-svg-leaf.leaf-growth { fill:#c3a24c; }
.tree-svg-leaf.leaf-movement { fill:#648db4; }
.tree-svg-leaf.leaf-other { fill:#9aa0a5; }
@keyframes treeSvgBranchGrow { to { stroke-dashoffset:0; } }
@keyframes treeSvgLeafFade { from { opacity:.15; } to { opacity:1; } }
.trunk, .branch, .ground { position: absolute; display: block; background: #858b8f; border-radius: 999px; }
.trunk { z-index:1; width: 7px; height: 82px; left: 72px; bottom: 17px; background:linear-gradient(90deg,#9aa09f,#727a7b); }
.branch { z-index:1; height:3px; opacity:0; background:linear-gradient(90deg,#7d8584,#a4aaa8); transform:rotate(var(--branch-r)) scaleX(0); animation:branchGrow .42s cubic-bezier(.2,.85,.3,1) var(--branch-delay,0s) forwards; }
.b1 { --branch-r:-34deg; --branch-delay:.03s; width:38px; left:75px; top:76px; transform-origin:left center; }
.b2 { --branch-r:34deg; --branch-delay:.06s; width:38px; right:75px; top:76px; transform-origin:right center; }
.b3 { --branch-r:-30deg; --branch-delay:.09s; width:31px; left:75px; top:58px; transform-origin:left center; }
.b4 { --branch-r:30deg; --branch-delay:.12s; width:31px; right:75px; top:58px; transform-origin:right center; }
.b5 { --branch-r:-27deg; --branch-delay:.15s; width:24px; left:75px; top:43px; transform-origin:left center; }
.b6 { --branch-r:27deg; --branch-delay:.18s; width:24px; right:75px; top:43px; transform-origin:right center; }
.ground { width: 118px; height: 3px; left: 17px; bottom: 15px; background: #c3c6ca; }
.branch::after { content:none; }
.tree-art.tree-bare .ground { width:62px; left:45px; opacity:.5; }
.tree-leaves { position:absolute; inset:0; z-index:2; display:block; pointer-events:none; }
.tree-leaf { position:absolute; left:var(--leaf-x); top:var(--leaf-y); width:15px; height:9px; display:block; border-radius:90% 15% 90% 15%; background:linear-gradient(135deg,#8ea790,#6f8d79); box-shadow:0 2px 5px rgba(65,88,70,.15); transform:translate(-50%,-50%) rotate(var(--leaf-r)) scale(0); transform-origin:bottom left; animation:leafGrow .35s cubic-bezier(.2,.9,.35,1.25) var(--leaf-delay) forwards; }
@keyframes leafGrow { to { transform:translate(-50%,-50%) rotate(var(--leaf-r)) scale(1); } }
@keyframes branchGrow { to { opacity:1; transform:rotate(var(--branch-r)) scaleX(1); } }
.tree-copy strong { font-size: 16px; }
.tree-copy p { margin: 8px 0 17px; color: var(--muted); font-size: 12px; }

.bird-button { position: fixed; z-index: 50; right: 25px; top: 88px; width: 132px; height: 132px; overflow:visible; border: 0; background: transparent; padding: 0; cursor: grab; filter: drop-shadow(0 16px 18px rgba(24,28,34,.15)); transform-origin: center; touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; }
.bird-stage, .bird-sprite { position:absolute; inset:0; display:block; }
.bird-stage { overflow:hidden; transform-origin:50% 78%; transition:transform .18s ease; }
.bird-sprite { background-image:url('./assets/chui-chui-motion-v3.png'); background-repeat:no-repeat; background-size:400% 400%; background-position:0 0; will-change:background-position; }
.bird-button:hover .bird-stage { transform:translateY(-3px); }
.bird-button.dragging { cursor: grabbing; animation: none; transform: none; }
.bird-button.dragging .bird-stage { transform:none; }
.bird-button.idle-look .bird-sprite { animation:birdLookFrames 1.45s steps(1,end); }
.bird-button.idle-look .bird-stage { animation:birdLook 1.45s ease-in-out; }
.bird-button.idle-hop .bird-sprite { animation:birdHopFrames 1.45s steps(1,end); }
.bird-button.idle-hop .bird-stage { animation:birdHop 1.45s ease-in-out; }
.bird-button.idle-shake .bird-sprite { animation:birdRuffle .96s steps(1,end); }
.bird-button.idle-nap .bird-sprite { animation:birdSleepFrames 4.2s steps(1,end); }
.bird-button.idle-nap .bird-stage { animation:birdNap 4.2s ease-in-out; }
.bird-button.idle-stretch .bird-sprite { animation:birdStretchFrames 1.65s steps(1,end); }
.bird-button.idle-stretch .bird-stage { animation:birdStretch 1.65s ease-in-out; }
.bird-button.idle-fly { animation:birdFlightPath 3.8s cubic-bezier(.38,.05,.24,1); pointer-events:none; }
.bird-button.idle-fly .bird-sprite { animation:birdWingCycle .28s steps(1,end) infinite; }
.bird-button.react .bird-stage { animation: birdReact .65s cubic-bezier(.2,.9,.3,1.25); }
.bird-status { position: absolute; z-index: 2; top: 8px; right: 13px; width: 9px; height: 9px; border-radius: 50%; background: #fff; border: 2px solid #7d8289; box-shadow: 0 0 0 3px rgba(255,255,255,.7); }
@keyframes birdLookFrames { 0%,20%,82%,100% { background-position:0 0; } 24%,78% { background-position:0 100%; } }
@keyframes birdLook { 0%,100% { transform: rotate(0); } 32%,68% { transform: rotate(-5deg) translateX(-1px); } }
@keyframes birdHopFrames { 0%,18%,100% { background-position:0 0; } 22%,43% { background-position:66.667% 100%; } 47%,78% { background-position:100% 100%; } 82% { background-position:0 100%; } }
@keyframes birdHop { 0%,22%,100% { transform:translateY(0) scale(1); } 40% { transform:translateY(-16px) scale(.98,1.03); } 64% { transform:translateY(1px) scale(1.03,.97); } }
@keyframes birdRuffle { 0%,100% { background-position:0 0; } 12%,84% { background-position:33.333% 0; } 25%,72% { background-position:66.667% 0; } 38%,58% { background-position:100% 0; } }
@keyframes birdSleepFrames { 0%,9%,94%,100% { background-position:0 0; } 12%,23% { background-position:0 33.333%; } 27%,39% { background-position:33.333% 33.333%; } 43%,78% { background-position:66.667% 33.333%; } 82%,91% { background-position:100% 33.333%; } }
@keyframes birdNap { 0%,15%,85%,100% { transform:translateY(0); filter:saturate(1); } 22%,78% { transform:translateY(5px) scale(.98); filter:saturate(.84); } }
@keyframes birdStretchFrames { 0%,18%,88%,100% { background-position:0 0; } 22%,84% { background-position:33.333% 100%; } }
@keyframes birdStretch { 0%,100% { transform:scale(1); } 38%,72% { transform:translateY(-2px) scale(1.04); } }
@keyframes birdWingCycle { 0%,24% { background-position:0 66.667%; } 25%,49% { background-position:33.333% 66.667%; } 50%,74% { background-position:66.667% 66.667%; } 75%,100% { background-position:100% 66.667%; } }
@keyframes birdFlightPath { 0%,100% { transform:translate(0,0) rotate(0) scale(1); } 34% { transform:translate(var(--bird-fly-x1,-160px),var(--bird-fly-y1,-150px)) rotate(var(--bird-fly-r1,-8deg)) scale(.94); } 62% { transform:translate(var(--bird-fly-x2,-300px),var(--bird-fly-y2,-220px)) rotate(var(--bird-fly-r2,5deg)) scale(.88); } 84% { transform:translate(var(--bird-fly-x3,-120px),var(--bird-fly-y3,-80px)) rotate(2deg) scale(.96); } }
@keyframes birdReact { 0%,100% { transform: scale(1); } 38% { transform: translateY(-8px) scale(1.1) rotate(4deg); } 68% { transform: scale(.97); } }
.bird-nudge { position: fixed; z-index: 49; right: 112px; top: 166px; max-width: 250px; padding: 11px 14px; border: 1px solid var(--line); border-radius: 14px 14px 4px 14px; background: rgba(255,255,255,.88); color: #575c64; box-shadow: var(--shadow); font-size: 12px; opacity: 0; transform: translateY(8px); pointer-events: none; transition: .22s ease; }
.bird-nudge.show { opacity: 1; transform: translateY(0); }
.bird-action-menu { position: fixed; z-index: 65; width: 238px; padding: 14px; border: 1px solid rgba(255,255,255,.9); border-radius: 20px; background: rgba(249,250,251,.94); box-shadow: 0 22px 60px rgba(20,25,32,.2); backdrop-filter: blur(26px); -webkit-backdrop-filter: blur(26px); opacity: 0; visibility: hidden; transform: scale(.94) translateY(6px); transform-origin: bottom right; transition: .17s ease; }
.bird-action-menu.open { opacity: 1; visibility: visible; transform: scale(1) translateY(0); }
.bird-action-menu > strong { display: block; padding: 2px 3px 10px; font-size: 12px; }
.bird-action-menu > div { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.bird-action-menu button { min-height: 38px; border: 1px solid var(--line); border-radius: 11px; background: rgba(255,255,255,.68); color: #555b63; font-size: 10px; cursor: pointer; }
.bird-action-menu button:hover { background: var(--soft); color: #25292f; }
.assistant-panel { position: fixed; z-index: 60; right: 25px; bottom: 32px; width: min(370px, calc(100vw - 28px)); height: min(560px, calc(100vh - 60px)); display: flex; flex-direction: column; border: 1px solid rgba(255,255,255,.86); border-radius: 26px; background: rgba(249,250,251,.92); box-shadow: 0 28px 80px rgba(20,25,32,.2); backdrop-filter: blur(30px); -webkit-backdrop-filter: blur(30px); opacity: 0; visibility: hidden; transform: translateY(18px) scale(.97); transform-origin: bottom right; transition: .22s ease; }
.assistant-panel.open { opacity: 1; visibility: visible; transform: translateY(0) scale(1); }
.assistant-head { height: 68px; display: flex; align-items: center; justify-content: space-between; padding: 0 18px; border-bottom: 1px solid var(--line); }
.assistant-head strong, .assistant-head span { display: block; }
.assistant-head strong { font-size: 13px; }
.assistant-head span { margin-top: 4px; color: var(--muted); font-size: 9px; }
.assistant-head button { border: 0; background: transparent; color: var(--muted); font-size: 23px; cursor: pointer; }
.assistant-body { flex: 1; padding: 18px; }
.assistant-message { max-width: 86%; padding: 13px 14px; border-radius: 16px 16px 16px 5px; background: white; color: #4f555e; font-size: 11px; line-height: 1.55; box-shadow: 0 5px 18px rgba(0,0,0,.04); }
.assistant-suggestions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.assistant-suggestions button { border: 1px solid var(--line); border-radius: 999px; background: rgba(255,255,255,.55); padding: 7px 10px; color: #68707a; font-size: 9px; cursor: pointer; }
.assistant-input { display: grid; grid-template-columns: 1fr auto; gap: 8px; padding: 13px; border-top: 1px solid var(--line); }
.assistant-input input { height: 40px; min-width: 0; border: 1px solid var(--line); border-radius: 12px; padding: 0 12px; background: white; outline: none; }
.assistant-input button { border: 0; border-radius: 12px; padding: 0 14px; background: #17191d; color: white; cursor: pointer; }

.page-module { min-height: calc(100vh - 76px); display: grid; place-items: center; }
.page-module[hidden] { display: none; }
.module-placeholder { width: min(680px,100%); padding: clamp(32px,7vw,70px); text-align: center; }
.module-icon { width: 58px; height: 58px; display: grid; place-items: center; margin: 18px auto; border-radius: 18px; color: var(--accent-deep); background: var(--accent-soft); }
.module-icon svg { width: 25px; height: 25px; }
.module-placeholder h1 { margin: 0; font-size: 34px; letter-spacing: -.04em; }
.module-placeholder > p { max-width: 500px; margin: 12px auto 19px; color: var(--muted); font-size: 13px; line-height: 1.65; }
.module-english { margin: -13px auto 20px; color: #9a9fa7; font-size: 11px; }
.feature-chips { display: flex; flex-wrap: wrap; justify-content: center; gap: 7px; margin-bottom: 24px; }
.feature-chips span { border: 1px solid var(--line); border-radius: 999px; background: rgba(255,255,255,.54); padding: 7px 10px; color: #656b73; font-size: 10px; }

.page-work[hidden] { display: none; }
.work-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin: 8px 0 28px; }
.work-heading h1 { margin: 10px 0 9px; font-size: clamp(34px, 3.7vw, 52px); line-height: 1.05; letter-spacing: -.05em; }
.work-heading > div > p:last-child { margin: 0; color: var(--muted); font-size: 15px; }
.en-inline { color: #9a9fa7; font-size: .72em; letter-spacing: .08em; }
.work-metrics { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 12px; margin-bottom: 12px; }
.work-metrics article { min-height: 124px; padding: 20px; border: 1px solid rgba(255,255,255,.85); border-radius: 20px; background: var(--surface); box-shadow: var(--shadow); }
.work-metrics span, .work-metrics small { display: block; color: var(--muted); }
.work-metrics span { font-size: 12px; }
.work-metrics strong { display: block; margin: 13px 0 5px; font-size: 30px; letter-spacing: -.045em; }
.work-metrics small { font-size: 9px; }
.work-layout { display: grid; grid-template-columns: minmax(0, 8fr) minmax(280px, 4fr); gap: 12px; align-items: start; }
.work-board { min-height: 480px; }
.work-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.work-tabs { display: flex; gap: 4px; padding: 4px; border-radius: 13px; background: var(--soft); }
.work-tabs button { min-height: 34px; border: 0; border-radius: 10px; padding: 0 13px; color: var(--muted); background: transparent; font-size: 11px; cursor: pointer; }
.work-tabs button.active { color: #24282e; background: white; box-shadow: 0 2px 8px rgba(20,25,32,.06); font-weight: 650; }
.priority-filter { display: flex; align-items: center; gap: 7px; color: var(--muted); font-size: 10px; }
.priority-filter select { height: 34px; border: 1px solid var(--line); border-radius: 10px; background: rgba(255,255,255,.7); padding: 0 28px 0 10px; color: #51565e; outline: none; font-size: 11px; }
.work-task-row { display: grid; grid-template-columns: 30px minmax(0,1fr) auto 34px; align-items: center; gap: 13px; min-height: 86px; border-bottom: 1px solid var(--line); }
.work-task-row:last-child { border-bottom: 0; }
.work-task-check { width: 28px; height: 28px; border: 1.5px solid #aeb4bc; border-radius: 9px; display: grid; place-items: center; background: rgba(255,255,255,.7); color: white; cursor: pointer; transition: .16s ease; }
.work-task-check svg { width: 14px; height: 14px; opacity: 0; }
.work-task-row.done .work-task-check { border-color: var(--accent-deep); background: var(--accent); }
.work-task-row.done .work-task-check svg { opacity: 1; }
.work-task-copy { min-width: 0; }
.work-task-copy strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 15px; font-weight: 640; }
.work-task-copy small { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-top: 7px; color: var(--muted); font-size: 11px; }
.work-task-row.done .work-task-copy { opacity: .46; text-decoration: line-through; }
.task-due.overdue { color: #4b5665; font-weight: 650; }
.work-task-delete { width: 32px; height: 32px; border: 0; border-radius: 9px; display: grid; place-items: center; color: #9a9fa7; background: transparent; cursor: pointer; }
.work-task-delete:hover { color: #34383f; background: var(--soft); }
.work-task-delete svg { width: 15px; height: 15px; }
.work-empty { min-height: 330px; display: grid; place-content: center; justify-items: center; text-align: center; color: var(--muted); }
.work-empty span { width: 46px; height: 46px; display: grid; place-items: center; margin-bottom: 13px; border: 1px solid var(--line); border-radius: 50%; background: rgba(255,255,255,.6); color: var(--accent-deep); font-size: 18px; }
.work-empty strong { color: #3a3f46; font-size: 15px; }
.work-empty p { margin: 7px 0 0; font-size: 11px; }
.work-insight { position: sticky; top: 92px; text-align: center; }
.work-ring { --pct: 0%; width: 142px; height: 142px; display: grid; place-content: center; margin: 24px auto 21px; border-radius: 50%; background: radial-gradient(circle at center, white 61%, transparent 62%), conic-gradient(var(--accent) var(--pct), var(--soft) 0); }
.work-ring strong, .work-ring span { display: block; }
.work-ring strong { font-size: 27px; letter-spacing: -.04em; }
.work-ring span { margin-top: 4px; color: var(--muted); font-size: 9px; }
.work-insight h2 { margin: 0; font-size: 18px; letter-spacing: -.02em; }
.work-insight p { margin: 9px auto 20px; max-width: 290px; color: var(--muted); font-size: 12px; line-height: 1.65; }
.work-insight .secondary-button { width: 100%; }
.page-schedule[hidden] { display: none; }
.schedule-heading { display: flex; align-items: flex-end; gap: 22px; margin: 8px 0 28px; }
.schedule-heading > div { flex: 1; }
.schedule-heading h1 { margin: 10px 0 9px; font-size: clamp(34px,3.7vw,52px); line-height: 1.05; letter-spacing: -.05em; }
.schedule-heading > div > p:last-child { margin: 0; color: var(--muted); font-size: 15px; }
.schedule-layout { display: grid; grid-template-columns: minmax(250px,3fr) minmax(0,9fr); gap: 12px; align-items: start; }
.schedule-editor { position: sticky; top: 92px; }
.schedule-form { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 12px; }
.schedule-form label { display: grid; gap: 8px; color: #5d646d; font-size: 13px; font-weight: 580; }
.schedule-form input, .schedule-form select { width: 100%; height: 48px; border: 1px solid var(--line); border-radius: 12px; background: rgba(255,255,255,.82); padding: 0 14px; color: var(--text); outline: none; font-size: 15px; font-weight: 450; }
.schedule-form input:focus, .schedule-form select:focus { border-color: rgba(100,122,152,.46); box-shadow: 0 0 0 3px var(--accent-soft); }
.schedule-title-field, .schedule-place-field, .schedule-save { grid-column: 1 / -1; }
.schedule-save { width: 100%; margin-top: 4px; }
.schedule-board-card { min-width: 0; }
.schedule-week { display:grid; grid-template-columns:repeat(7,minmax(0,1fr)); gap:7px; overflow-x:hidden; padding:2px 0 8px; scrollbar-width:thin; }
.schedule-day { min-height: 360px; border: 1px solid var(--line); border-radius: 16px; background: rgba(249,250,251,.5); overflow: hidden; }
.schedule-day.today { border-color: rgba(100,122,152,.32); background: rgba(232,237,243,.58); }
.schedule-day header { min-height:55px; padding:10px 8px; border-bottom:1px solid var(--line); }
.schedule-day header strong, .schedule-day header span { display: block; }
.schedule-day header strong { font-size: 12px; }
.schedule-day header span { margin-top: 4px; color: var(--muted); font-size: 9px; }
.schedule-day > div { padding: 8px; }
.schedule-item { position:relative; min-height:112px; margin-bottom:7px; padding:11px 8px 42px; border-radius:12px; background:white; box-shadow:0 5px 16px rgba(23,29,38,.05); overflow:hidden; }
.schedule-item time, .schedule-item strong, .schedule-item small { display: block; }
.schedule-item time { color: var(--accent-deep); font-size: 10px; line-height:1.35; font-weight: 720; letter-spacing:.01em; white-space:nowrap; }
.schedule-item strong { margin-top: 8px; font-size: 13px; line-height: 1.35; }
.schedule-item small { margin-top: 6px; color: var(--muted); font-size: 10px; line-height:1.35; }
.schedule-item button { position: absolute; top:auto; bottom:9px; right:8px; width: 28px; height: 28px; border: 0; border-radius: 8px; display: grid; place-items: center; background: var(--soft); color: #8e959d; cursor: pointer; }
.schedule-item button:hover { color: #3e434a; background: var(--soft); }
.schedule-item button svg { width: 13px; height: 13px; }
.schedule-day-empty { margin: 18px 0; color: #a0a5ac; text-align: center; font-size: 9px; }
.schedule-empty { min-height: 360px; display: grid; place-content: center; justify-items: center; text-align: center; }
.schedule-empty strong { font-size: 15px; }
.schedule-empty p { max-width: 300px; margin: 8px 0 0; color: var(--muted); font-size: 11px; line-height: 1.6; }
.home-schedule-list { width: 100%; }
.home-schedule-row { width: 100%; min-height: 53px; display: grid; grid-template-columns: 50px 1fr; align-items: center; gap: 10px; border: 0; border-bottom: 1px solid var(--line); background: transparent; text-align: left; cursor: pointer; }
.home-schedule-row:last-child { border-bottom: 0; }
.home-schedule-row time { color: var(--accent-deep); font-size: 11px; font-weight: 680; }
.home-schedule-row strong, .home-schedule-row small { display: block; }
.home-schedule-row strong { font-size: 12px; }
.home-schedule-row small { margin-top: 4px; color: var(--muted); font-size: 9px; }
.home-schedule-list + .secondary-button { margin-top: 14px; }
.page-focus[hidden] { display: none; }
.focus-heading { margin: 8px 0 28px; }
.focus-heading h1 { margin: 10px 0 9px; font-size: clamp(34px,3.7vw,52px); line-height: 1.05; letter-spacing: -.05em; }
.focus-heading > div > p:last-child { margin: 0; color: var(--muted); font-size: 15px; }
.focus-layout { display: grid; grid-template-columns: minmax(0,8fr) minmax(290px,4fr); gap: 12px; align-items: start; }
.focus-timer-card { min-height: 570px; display: flex; flex-direction: column; align-items: center; }
.focus-options { width: 100%; display: flex; align-items: end; justify-content: space-between; gap: 18px; }
.focus-duration { display: flex; gap: 5px; padding: 4px; border-radius: 13px; background: var(--soft); }
.focus-duration button { min-height: 35px; border: 0; border-radius: 10px; padding: 0 13px; background: transparent; color: var(--muted); font-size: 10px; cursor: pointer; }
.focus-duration button.active { background: white; color: #24282e; box-shadow: 0 2px 8px rgba(20,25,32,.06); font-weight: 680; }
.focus-task-label { min-width: min(280px,45%); display: grid; gap: 6px; color: var(--muted); font-size: 10px; }
.focus-task-label select { width: 100%; height: 43px; border: 1px solid var(--line); border-radius: 12px; background: rgba(255,255,255,.76); padding: 0 12px; outline: none; color: var(--text); font-size: 11px; }
.focus-clock { width: clamp(240px,34vw,370px); aspect-ratio: 1; display: grid; place-content: center; justify-items: center; margin: 30px 0 22px; border: 1px solid rgba(255,255,255,.9); border-radius: 50%; background: radial-gradient(circle at 45% 35%, rgba(255,255,255,.96), rgba(232,237,243,.62)); box-shadow: inset 0 0 0 14px rgba(255,255,255,.32), 0 24px 65px rgba(30,38,49,.08); transition: .3s ease; }
.focus-clock.running { box-shadow: inset 0 0 0 14px rgba(255,255,255,.32), 0 28px 78px rgba(100,122,152,.16); transform: scale(1.012); }
.focus-clock-label { color: var(--accent-deep); font-size: 11px; font-weight: 720; letter-spacing: .09em; }
.focus-clock strong { margin: 15px 0 11px; font-size: clamp(54px,7vw,84px); line-height: .92; letter-spacing: -.065em; font-variant-numeric: tabular-nums; }
.focus-clock > span:last-child { max-width: 230px; color: var(--muted); text-align: center; font-size: 11px; line-height: 1.5; }
.phone-away-check { width: min(520px,100%); min-height: 72px; display: grid; grid-template-columns: 27px 1fr; align-items: center; gap: 13px; padding: 13px 15px; border: 1px solid var(--line); border-radius: 16px; background: rgba(255,255,255,.48); cursor: pointer; }
.phone-away-check input { position: absolute; opacity: 0; }
.phone-away-check strong, .phone-away-check small { display: block; }
.phone-away-check strong { font-size: 13px; }
.phone-away-check small { margin-top: 5px; color: var(--muted); font-size: 10px; line-height: 1.45; }
.phone-away-check input:checked + .checkmark { background: var(--accent); border-color: var(--accent); color: white; }
.phone-away-check input:checked + .checkmark svg { opacity: 1; }
.focus-controls { display: flex; align-items: center; justify-content: center; gap: 9px; margin-top: 18px; }
.focus-controls .text-button { padding: 10px; }
.focus-side { display: grid; gap: 12px; }
.interruption-buttons { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; }
.interruption-buttons button { min-height: 42px; border: 1px solid var(--line); border-radius: 11px; background: rgba(255,255,255,.62); color: #555b63; font-size: 11px; cursor: pointer; }
.interruption-buttons button:hover { background: var(--accent-soft); color: #3f526b; }
.interruption-card > p { margin: 13px 0 0; color: var(--muted); font-size: 10px; line-height: 1.55; }
.focus-history { max-height: 310px; overflow-y: auto; }
.focus-history article { min-height: 66px; display: grid; grid-template-columns: 46px 1fr; align-items: center; gap: 10px; border-bottom: 1px solid var(--line); }
.focus-history article:last-child { border-bottom: 0; }
.focus-history article > span { color: var(--accent-deep); font-size: 10px; font-weight: 680; }
.focus-history strong, .focus-history small { display: block; }
.focus-history strong { font-size: 12px; }
.focus-history small { margin-top: 5px; color: var(--muted); font-size: 9px; }
.focus-history-empty { min-height: 150px; display: grid; place-items: center; color: var(--muted); text-align: center; font-size: 11px; }
.page-academics[hidden] { display: none; }
.academics-heading { margin: 8px 0 25px; display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; }
.academics-heading h1 { margin: 10px 0 10px; font-size: clamp(34px,3.7vw,52px); line-height: 1.05; letter-spacing: -.05em; }
.academics-heading > div > p:last-child { max-width: 680px; margin: 0; color: var(--muted); font-size: 14px; line-height: 1.65; }
.academics-heading .primary-button svg { width: 15px; height: 15px; }
.academics-metrics { display: grid; grid-template-columns: repeat(3,1fr); gap: 10px; margin-bottom: 12px; }
.academics-metrics article { min-height: 118px; padding: 19px 20px; display: flex; flex-direction: column; justify-content: space-between; border: 1px solid rgba(255,255,255,.82); border-radius: 21px; background: rgba(255,255,255,.56); box-shadow: 0 12px 34px rgba(30,38,49,.045); }
.academics-metrics span { color: var(--muted); font-size: 11px; }
.academics-metrics strong { margin-top: 8px; font-size: 30px; line-height: 1; letter-spacing: -.045em; }
.academics-metrics small { color: #a0a5ac; font-size: 9px; letter-spacing: .04em; }
.academics-layout { display: grid; grid-template-columns: minmax(0,7.6fr) minmax(310px,4.4fr); gap: 12px; align-items: start; }
.courses-card { min-height: 630px; }
.course-list { display: grid; gap: 10px; }
.course-row { padding: 17px; border: 1px solid var(--line); border-radius: 17px; background: rgba(255,255,255,.47); }
.course-row-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; }
.course-row-head span, .course-row-head strong { display: block; }
.course-row-head span { margin-bottom: 5px; color: #9ba1a9; font-size: 8px; font-weight: 720; letter-spacing: .11em; }
.course-row-head strong { font-size: 15px; letter-spacing: -.02em; }
.course-row-head button { width: 30px; height: 30px; border: 0; border-radius: 9px; display: grid; place-items: center; background: transparent; color: #a0a5ac; cursor: pointer; }
.course-row-head button:hover { background: var(--soft); color: #474c53; }
.course-row-head svg { width: 14px; height: 14px; }
.course-progress-line { margin: 15px 0 7px; display: flex; align-items: center; justify-content: space-between; color: var(--muted); font-size: 10px; }
.course-progress-line strong { color: var(--accent-deep); font-size: 11px; font-variant-numeric: tabular-nums; }
.course-progress { height: 5px; overflow: hidden; border-radius: 99px; background: #e8ebef; }
.course-progress span { display: block; height: 100%; border-radius: inherit; background: var(--accent); transition: width .18s ease; }
.course-range { width: 100%; height: 24px; margin: 5px 0 9px; accent-color: var(--accent); cursor: pointer; }
.course-next-label { display: grid; grid-template-columns: auto minmax(0,1fr); align-items: center; gap: 12px; color: var(--muted); font-size: 10px; }
.course-next-label input { min-width: 0; height: 41px; border: 1px solid var(--line); border-radius: 11px; background: rgba(255,255,255,.72); padding: 0 12px; color: var(--text); outline: none; font-size: 11px; }
.course-next-label input:focus, .grade-calculator input:focus, .grade-calculator select:focus, .rank-card input:focus { border-color: rgba(98,119,147,.52); box-shadow: 0 0 0 3px var(--accent-soft); }
.course-to-task { width: 100%; margin-top: 10px; min-height: 38px; }
.course-empty { min-height: 420px; display: grid; place-content: center; justify-items: center; text-align: center; }
.course-empty strong { font-size: 15px; }
.course-empty span { max-width: 300px; margin-top: 8px; color: var(--muted); font-size: 11px; line-height: 1.6; }
.academics-side { display: grid; gap: 12px; }
.grade-calculator > label, .grade-fields label, .rank-fields label { position: relative; display: grid; gap: 7px; color: var(--muted); font-size: 10px; }
.grade-calculator select, .grade-fields input, .rank-fields input { width: 100%; height: 43px; border: 1px solid var(--line); border-radius: 12px; background: rgba(255,255,255,.72); padding: 0 12px; color: var(--text); outline: none; font-size: 12px; }
.grade-fields { margin-top: 11px; display: grid; grid-template-columns: repeat(3,1fr); gap: 7px; }
.grade-fields label span, .rank-fields label span { position: absolute; right: 11px; bottom: 13px; color: #9ca2aa; }
.grade-fields label:has(span) input, .rank-fields label:has(span) input { padding-right: 28px; }
.grade-result { min-height: 125px; margin-top: 14px; padding: 18px; display: grid; align-content: center; justify-items: center; border-radius: 17px; background: linear-gradient(145deg, rgba(236,240,245,.88), rgba(255,255,255,.72)); text-align: center; }
.grade-result span { color: var(--muted); font-size: 10px; }
.grade-result strong { margin: 7px 0 5px; font-size: 38px; letter-spacing: -.05em; }
.grade-result strong.impossible { color: #7c6262; }
.grade-result small { color: #8d949d; font-size: 9px; }
.rank-fields { display: grid; grid-template-columns: repeat(3,1fr); gap: 7px; }
.rank-summary { min-height: 68px; margin-top: 13px; padding: 13px 14px; border-radius: 13px; background: var(--soft); color: var(--muted); font-size: 10px; line-height: 1.6; }
.rank-summary strong { color: var(--text); font-size: 12px; }
.course-dialog-next { margin-top: 13px; }
.toast { position: fixed; z-index: 90; left: calc(var(--sidebar) + (100vw - var(--sidebar))/2); bottom: 28px; transform: translate(-50%, 16px); padding: 11px 15px; border: 1px solid rgba(255,255,255,.7); border-radius: 12px; background: rgba(27,30,35,.92); color: white; box-shadow: var(--shadow); font-size: 10px; opacity: 0; pointer-events: none; transition: .22s ease; }
.toast.show { opacity: 1; transform: translate(-50%,0); }
.quick-dialog { width: min(470px,calc(100% - 28px)); border: 1px solid rgba(255,255,255,.85); border-radius: 24px; background: rgba(249,250,251,.94); box-shadow: 0 32px 90px rgba(20,25,32,.24); backdrop-filter: blur(28px); -webkit-backdrop-filter: blur(28px); padding: 0; }
.quick-dialog::backdrop { background: rgba(31,35,41,.24); backdrop-filter: blur(5px); }
.quick-dialog form { padding: 24px; }
.dialog-head { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 20px; }
.dialog-head h2 { margin: 5px 0 0; font-size: 21px; }
.dialog-head button { border: 0; background: transparent; color: var(--muted); font-size: 24px; cursor: pointer; }
.quick-dialog label { display: grid; gap: 7px; color: var(--muted); font-size: 10px; }
.quick-dialog input, .quick-dialog select { width: 100%; height: 42px; border: 1px solid var(--line); border-radius: 12px; background: white; padding: 0 12px; color: var(--text); outline: none; }
.dialog-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 13px; }
.quick-dialog menu { margin: 22px 0 0; padding: 0; display: flex; justify-content: flex-end; gap: 8px; }
.scrim { display: none; }

@media (max-width: 1100px) {
  .metric-grid { grid-template-columns: repeat(2,1fr); }
  .priorities-card, .schedule-card, .habits-card, .movement-card, .mood-card, .flash-card { grid-column: span 6; }
  .work-layout { grid-template-columns: 1fr; }
  .work-insight { position: static; }
  .schedule-layout { grid-template-columns: 1fr; }
  .schedule-editor { position: static; }
  .focus-layout { grid-template-columns: 1fr; }
  .academics-layout { grid-template-columns: 1fr; }
}
@media (max-width: 820px) {
  :root { --sidebar: 0px; }
  .sidebar { width: 264px; transform: translateX(-102%); transition: transform .24s ease; box-shadow: 18px 0 50px rgba(20,25,32,.12); }
  .sidebar.open { transform: translateX(0); }
  .scrim { position: fixed; z-index: 35; inset: 0; display: block; background: rgba(23,27,33,.2); opacity: 0; visibility: hidden; transition: .2s ease; }
  .scrim.open { opacity: 1; visibility: visible; }
  .main { margin-left: 0; }
  .menu-button { display: grid; }
  .topbar { height: 66px; padding-inline: 16px; }
  .search-pill { width: min(210px,45vw); }
  .preview-pill { display: none; }
  .language-toggle { margin-left: auto; }
  .page { padding: 22px 16px 130px; }
  .bird-button { right: 10px; top: 72px; width: 104px; height: 104px; }
  .bird-nudge { right: 80px; top: 142px; }
  .toast { left: 50%; }
}
@media (max-width: 620px) {
  .topbar-actions { gap: 6px; }
  .cloud-sync-pill { display:none; }
  .page-heading { align-items: flex-start; }
  .page-heading h1 { font-size: 34px; }
  .page-heading .primary-button { width: 40px; padding: 0; font-size: 0; }
  .metric-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
  .metric-card { min-height: 112px; padding: 15px; }
  .metric-value strong { font-size: 25px; }
  .priorities-card, .schedule-card, .habits-card, .movement-card, .mood-card, .flash-card, .review-card { grid-column: span 12; }
  .card { padding: 18px; border-radius: 21px; }
  .search-pill { width: 42px; padding: 0; justify-content: center; }
  .search-pill span { display: none; }
  .search-pill kbd { border: 0; background: transparent; padding: 0; }
  .language-toggle { gap: 3px; padding-right: 6px; }
  .language-toggle span { padding: 5px; }
  .tree-preview { grid-template-columns: 110px 1fr; gap: 16px; }
  .tree-art { transform: scale(.72); transform-origin: center; margin-left: -22px; }
  .mood-scale { gap: 3px; }
  .mood-scale button small { font-size: 8px; }
  .mood-note-footer { align-items: flex-end; }
  .task-row { grid-template-columns: 24px 1fr; padding: 7px 0; }
  .priority-tag { display: none; }
  .assistant-panel { right: 14px; bottom: 14px; }
  .work-heading { align-items: flex-start; }
  .work-heading h1 { font-size: 34px; }
  .work-heading .primary-button { width: 42px; padding: 0; font-size: 0; }
  .work-metrics { grid-template-columns: repeat(3,1fr); gap: 7px; }
  .work-metrics article { min-height: 104px; padding: 14px 12px; }
  .work-metrics strong { font-size: 25px; }
  .work-toolbar { align-items: stretch; flex-direction: column; }
  .work-tabs { display: grid; grid-template-columns: repeat(3,1fr); }
  .work-tabs button { padding: 0 7px; }
  .priority-filter { justify-content: flex-end; }
  .work-task-row { grid-template-columns: 30px minmax(0,1fr) 30px; gap: 10px; min-height: 82px; }
  .work-task-row .priority-tag { display: inline-flex; grid-column: 2; grid-row: 2; width: max-content; margin-top: -10px; }
  .work-task-delete { grid-column: 3; grid-row: 1 / span 2; }
  .schedule-heading { align-items: flex-start; }
  .schedule-heading h1 { font-size: 34px; }
  .schedule-heading .secondary-button { flex: 0 0 auto; padding-inline: 12px; }
  .schedule-form { grid-template-columns: 1fr 1fr; }
  .schedule-week { grid-template-columns: repeat(7,150px); }
  .focus-heading h1 { font-size: 34px; }
  .focus-timer-card { min-height: 0; }
  .focus-options { align-items: stretch; flex-direction: column; }
  .focus-task-label { width: 100%; min-width: 0; }
  .focus-clock { width: min(310px,82vw); margin-block: 24px 18px; }
  .focus-controls { width: 100%; flex-wrap: wrap; }
  .segmented-actions { grid-template-columns: repeat(2,1fr); }
  .academics-heading { align-items: flex-start; }
  .academics-heading h1 { font-size: 34px; }
  .academics-heading .primary-button { flex: 0 0 42px; width: 42px; padding: 0; font-size: 0; }
  .academics-metrics { gap: 7px; }
  .academics-metrics article { min-height: 106px; padding: 14px 12px; }
  .academics-metrics strong { font-size: 24px; }
  .academics-metrics small { font-size: 8px; }
  .courses-card { min-height: 0; }
  .course-row { padding: 15px; }
  .course-next-label { grid-template-columns: 1fr; gap: 6px; }
  .grade-fields, .rank-fields { grid-template-columns: 1fr; }
  .grade-fields label span, .rank-fields label span { bottom: 14px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* Release 19: always-visible, collision-safe responsive layout. */
.nav-group-title { cursor:default; }
.nav-group-title > span:last-child { display:none; }
.nav-group.collapsed .nav-group-items { display:block; }
.movement-goal-progress { display:flex; }
.movement-goal-progress > span { flex:0 0 auto; border-radius:0; }
.movement-goal-progress > span:first-child { border-radius:999px 0 0 999px; }
.movement-goal-progress > span:last-child { background:#3f648d; border-radius:0 999px 999px 0; }
.work-side { display:grid; gap:12px; align-content:start; }
.work-heading-actions { display:flex; align-items:center; justify-content:flex-end; gap:12px; }
.work-heading-actions .work-ring { width:92px; height:92px; margin:0; }
.work-heading-actions .work-ring strong { font-size:21px; }
.work-heading-actions .work-ring span { font-size:8px; }
.work-insight { position:static; }
.work-overview h2 { margin:6px 0 18px; font-size:18px; }
.work-overview dl { margin:0; display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:6px; }
.work-overview dl div { min-width:0; padding:12px 8px; border-radius:12px; background:var(--soft); text-align:center; }
.work-overview dt { color:var(--muted); font-size:10px; white-space:nowrap; }
.work-overview dd { margin:5px 0 0; font-size:22px; font-weight:700; }
.work-overview p { color:var(--muted); font-size:12px; line-height:1.6; }
.work-overview .secondary-button { width:100%; }
.schedule-layout { grid-template-columns:minmax(270px,3fr) minmax(0,9fr); align-items:stretch; }
.schedule-editor { position:static; }
.schedule-week-picker { margin:0 0 14px; display:grid; grid-template-columns:42px minmax(160px,1fr) 42px auto; gap:8px; align-items:end; }
.schedule-week-picker button { height:42px; border:1px solid var(--line); border-radius:11px; background:white; cursor:pointer; }
.schedule-week-picker label { display:grid; gap:5px; color:var(--muted); font-size:10px; }
.schedule-week-picker input { min-width:0; width:100%; height:42px; border:1px solid var(--line); border-radius:11px; background:white; padding:0 10px; }
.schedule-week { grid-template-columns:repeat(7,minmax(0,1fr)); overflow:visible; }
.schedule-day { min-width:0; min-height:300px; }
.schedule-day header strong { overflow-wrap:anywhere; }
.schedule-item { min-width:0; padding-inline:9px; }
.schedule-item strong,.schedule-item small { overflow-wrap:anywhere; }
.bird-button { position:absolute; right:25px; top:82px; }
.bird-button.free-position { position:fixed; }
.page > section:first-child { padding-right:145px; min-height:125px; }
.tree-leaf.leaf-growth { background:linear-gradient(135deg,#dcc982,#a98c45); box-shadow:0 2px 5px rgba(139,108,42,.18); }
.tree-leaf.leaf-movement { background:linear-gradient(135deg,#91b5d7,#4f759c); box-shadow:0 2px 5px rgba(54,90,128,.18); }
.tree-leaf.leaf-other { background:linear-gradient(135deg,#bcc1c7,#7d858e); box-shadow:0 2px 5px rgba(84,91,99,.18); }
@keyframes birdLook { 0%,100% { transform:rotate(0); } 32%,68% { transform:rotate(-3deg) translateX(-1px); } }
@keyframes birdHop { 0%,22%,100% { transform:translateY(0) scale(1); } 40% { transform:translateY(-10px) scale(.99,1.02); } 64% { transform:translateY(1px) scale(1.02,.98); } }
.bird-button.idle-nap .bird-sprite { animation-duration:7.6s; }
.bird-button.idle-nap .bird-stage { animation-duration:7.6s; }
@keyframes birdSleepFrames { 0%,7%,96%,100% { background-position:0 0; } 10%,17% { background-position:0 33.333%; } 20%,28% { background-position:33.333% 33.333%; } 31%,86% { background-position:66.667% 33.333%; } 89%,94% { background-position:100% 33.333%; } }
@keyframes birdNap { 0%,12%,90%,100% { transform:translateY(0); filter:saturate(1); } 20%,84% { transform:translateY(3px) scale(.99); filter:saturate(.88); } }
@keyframes birdStretch { 0%,100% { transform:scale(1); } 38%,72% { transform:translateY(-1px) scale(1.025); } }
@keyframes birdReact { 0%,100% { transform:scale(1); } 38% { transform:translateY(-5px) scale(1.06) rotate(2deg); } 68% { transform:scale(.985); } }

@media(max-width:1400px) {
  .schedule-layout { grid-template-columns:1fr; }
  .schedule-week { grid-template-columns:repeat(7,minmax(0,1fr)); }
  .schedule-day { min-height:240px; }
  .schedule-item strong { font-size:11px; }
  .schedule-item small { font-size:9px; }
}
@media(max-width:1024px) {
  .schedule-week { grid-template-columns:repeat(7,minmax(0,1fr)); gap:5px; }
  .schedule-day header { padding-inline:6px; }
  .schedule-day header strong { font-size:10px; }
  .schedule-item { padding-inline:6px; }
  .work-layout { align-items:stretch; }
  .work-side { height:100%; }
  .work-overview { flex:1; }
}
@media(max-width:760px) {
  .page > section:first-child { padding-right:0; padding-top:112px; min-height:0; }
  .bird-button { right:8px; top:72px; width:104px; height:104px; }
  .schedule-heading { flex-wrap:wrap; }
  .schedule-heading .secondary-button { width:100%; }
  .schedule-week-picker { grid-template-columns:38px minmax(0,1fr) 38px; }
  .schedule-week-picker #scheduleThisWeek { grid-column:1/-1; }
  .schedule-week { grid-template-columns:minmax(0,1fr); }
  .schedule-day { min-height:0; }
  .schedule-form { grid-template-columns:minmax(0,1fr); }
  .schedule-form > * { grid-column:1!important; }
  .work-overview dl { grid-template-columns:1fr; }
  .work-overview dl div { display:flex; justify-content:space-between; align-items:center; }
  .work-overview dd { margin:0; }
}
