:root {
  --bg: #f7f8f5;
  --surface: #fff;
  --ink: #25312d;
  --muted: #77817a;
  --line: #e7eae2;
  --accent: #d3f1a7;
  --sidebar: #24332d;
  --radius: 20px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--bg);
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
}
* { box-sizing: border-box; }
body { margin: 0; }
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
a { color: inherit; }
button:disabled { opacity: .55; cursor: wait; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid #6e9476; outline-offset: 4px; }
svg { width: 20px; height: 20px; flex-shrink: 0; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.skip-link { position: fixed; top: -100px; left: 20px; z-index: 10; padding: 12px; background: var(--accent); }
.skip-link:focus { top: 12px; }
.app-shell { display: grid; grid-template-columns: 236px minmax(0, 1fr); min-height: 100vh; }
.sidebar { background: var(--sidebar); color: #e7eee7; padding: 34px 20px 24px; display: flex; flex-direction: column; min-height: 100vh; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; font-size: 15px; font-weight: 650; letter-spacing: -.3px; padding: 0 6px; }
.brand-mark { background: var(--accent); color: var(--sidebar); width: 40px; height: 40px; border-radius: 13px; display: grid; place-items: center; font-size: 30px; font-weight: 750; padding-bottom: 6px; }
.brand small { display: block; color: #a6b4a9; font-size: 10px; font-weight: 400; margin-top: 5px; letter-spacing: .1px; }
.nav-caption { font-size: 9px; letter-spacing: 1.8px; color: #98ab9d; margin: 52px 15px 14px; }
.navigation { display: grid; gap: 8px; }
.navigation a { display: flex; align-items: center; gap: 13px; padding: 14px 15px; border-radius: 11px; font-size: 13px; text-decoration: none; color: #b6c4b9; transition: background .15s; }
.navigation a:hover { background: #304239; }
.navigation a[aria-current="page"] { color: var(--sidebar); background: var(--accent); font-weight: 600; }
.nav-count { margin-left: auto; font-size: 10px; padding: 3px 6px; border-radius: 5px; background: #ffffff16; }
.sidebar-note { margin: auto 10px 26px; padding-top: 70px; }
.small-star { font-size: 38px; font-weight: 200; color: var(--accent); }
.sidebar-note p { font-size: 18px; font-weight: 400; line-height: 1.6; letter-spacing: -.4px; color: #dce5db; }
.sidebar-footer { border-top: 1px solid #ffffff15; padding: 20px 8px 0; font-size: 10px; color: #a6b5a8; }
.main { min-width: 0; padding: 0 42px 24px; max-width: 1590px; width: 100%; margin: 0 auto; }
.topbar { display: flex; justify-content: space-between; align-items: center; min-height: 90px; border-bottom: 1px solid var(--line); gap: 16px; }
.breadcrumb { color: #6d796f; font-size: 12px; }
.topbar-actions { display: flex; align-items: center; gap: 22px; }
.topbar time { font-size: 11px; color: #6d796f; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid transparent; border-radius: 9px; padding: 10px 13px; font-size: 11px; font-weight: 550; }
.button svg { width: 14px; height: 14px; }
.button-secondary { background: white; border-color: var(--line); color: var(--ink); }
.button-primary { background: var(--sidebar); color: white; }
.button:hover { filter: brightness(.96); }
.mode-notice { display: flex; align-items: center; gap: 9px; padding: 10px 13px; margin-top: 18px; border: 1px solid #e7dfc5; background: #fbf7e9; border-radius: 9px; color: #7a683c; font-size: 11px; line-height: 1.5; }
.notice-dot, .orange-dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: #b69a55; flex-shrink: 0; }
.page-heading { display: flex; justify-content: space-between; align-items: center; padding: 35px 0 29px; gap: 15px; }
.eyebrow { margin: 0 0 11px; font-size: 9px; letter-spacing: 1.7px; font-weight: 600; color: #859080; }
h1 { margin: 0; font-size: clamp(28px, 3vw, 42px); font-weight: 550; letter-spacing: -1.7px; line-height: 1.2; }
.page-description { font-size: 12px; line-height: 1.7; color: var(--muted); margin: 13px 0 0; }
.heading-decoration { font-size: 55px; line-height: 1; font-weight: 200; color: #809470; padding-right: 10px; }
.stats-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-bottom: 25px; }
.stat-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 21px 22px; display: grid; gap: 13px; }
.stat-label { display: flex; align-items: center; justify-content: space-between; font-size: 11px; font-weight: 550; }
.stat-card strong { font-size: 38px; line-height: 1; font-weight: 500; letter-spacing: -1.5px; }
.stat-card strong small { font-size: 12px; letter-spacing: 0; margin-left: 7px; font-weight: 400; }
.stat-description { font-size: 10px; color: var(--muted); }
.stat-accent { background: #e7f0de; border-color: #dbe7d0; }
.orange-dot { background: #d6a272; }
.workspace-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(280px, 1fr); align-items: start; gap: 23px; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; min-width: 0; }
.panel-heading { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 24px 23px 19px; }
.panel-heading .eyebrow { font-size: 8px; letter-spacing: 1.35px; margin-bottom: 8px; }
h2 { font-size: 18px; font-weight: 550; letter-spacing: -.6px; margin: 0; }
.panel-icon { color: #78956a; width: 26px; height: 26px; }
.count-badge { display: grid; place-items: center; background: #f0f3eb; border-radius: 8px; min-width: 27px; height: 27px; font-size: 11px; }
.task-filters { display: flex; gap: 6px; padding: 0 23px 18px; flex-wrap: wrap; }
.task-filters button { padding: 7px 11px; border: 1px solid transparent; background: transparent; color: var(--muted); font-size: 10px; border-radius: 7px; }
.task-filters button[aria-pressed="true"] { color: var(--ink); background: #f0f3eb; border-color: #e4e9dd; }
.task-list, .source-list, .plan-list { list-style: none; margin: 0; padding: 0; }
.task-list > li { border-top: 1px solid #edf0e8; }
.task-summary { padding: 18px 23px; display: flex; align-items: start; gap: 13px; cursor: pointer; list-style: none; }
.task-summary::-webkit-details-marker { display: none; }
.task-marker { width: 9px; height: 9px; border-radius: 3px; background: #adbb9c; flex-shrink: 0; margin-top: 7px; }
.priority-high .task-marker { background: #d39770; }
.priority-low .task-marker { background: #c0c5bc; }
.task-copy { min-width: 0; flex: 1; }
.task-course { display: block; color: #8b9488; font-size: 9px; line-height: 1.4; margin-bottom: 6px; }
.task-title { display: block; font-size: 12px; font-weight: 550; line-height: 1.6; }
.task-meta { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 8px; align-items: center; font-size: 9px; color: #899080; }
.due-label { border-radius: 4px; padding: 3px 5px; background: #f1f3ed; }
.due-today { background: #fbefe4; color: #9f704e; }
.task-chevron { font-size: 15px; color: #a3ada0; padding-top: 14px; transition: transform .15s; }
details[open] .task-chevron { transform: rotate(90deg); }
.task-evidence { padding: 0 23px 19px 45px; font-size: 11px; line-height: 1.7; color: #6f7e70; }
.task-evidence h3 { margin: 12px 0 5px; font-size: 10px; color: var(--ink); font-weight: 600; }
.task-evidence blockquote { border-left: 2px solid #d6dfcb; padding-left: 10px; margin: 5px 0; }
.task-evidence ul { padding-left: 17px; margin: 5px 0; }
.task-evidence a { text-underline-offset: 3px; }
.panel-footer { border-top: 1px solid var(--line); padding: 14px 23px; color: #8a9487; font-size: 9px; line-height: 1.7; background: #fdfefb; }
.plan-budget { margin: 0 23px 20px; padding: 14px; border-radius: 10px; background: #f6f8f2; }
.plan-budget > div { display: flex; justify-content: space-between; gap: 8px; font-size: 9px; color: #7e8977; }
.plan-budget strong { color: #4c6244; font-size: 9px; font-weight: 500; }
meter { display: block; width: 100%; height: 7px; border: 0; margin-top: 10px; border-radius: 6px; background: #e4e9dc; }
meter::-webkit-meter-bar { background: #e4e9dc; border: none; border-radius: 6px; }
meter::-webkit-meter-optimum-value { background: #a8c68b; border-radius: 6px; }
meter::-moz-meter-bar { background: #a8c68b; border-radius: 6px; }
.plan-list { padding: 0 23px; }
.plan-item { display: flex; gap: 13px; position: relative; padding-bottom: 25px; }
.plan-item:not(:last-child)::before { content: ""; position: absolute; left: 13px; top: 29px; height: calc(100% - 32px); width: 1px; background: #e0e7d9; }
.step-number { display: grid; place-items: center; width: 27px; height: 27px; background: #f0f4ea; border: 1px solid #e0e7d9; border-radius: 50%; font-size: 9px; color: #7e9270; flex-shrink: 0; }
.plan-time { color: #8a9582; font-size: 9px; display: block; margin: 1px 0 8px; }
.plan-item h3 { margin: 0; font-size: 12px; font-weight: 550; line-height: 1.6; }
.plan-reason { color: #8a9582; font-size: 10px; line-height: 1.7; margin: 8px 0 0; }
.plan-note { margin: 0 23px 22px; padding: 13px; background: #f4f7ed; color: #7a896d; border-radius: 10px; font-size: 9px; line-height: 1.8; }
.sources-panel { grid-column: 1 / -1; }
.source-total { color: #8b9586; font-size: 10px; }
.source-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; padding: 0 23px 23px; }
.source-card { border: 1px solid var(--line); border-radius: 11px; padding: 16px; }
.source-top { display: flex; align-items: center; gap: 9px; margin-bottom: 10px; }
.source-avatar { width: 29px; height: 29px; border-radius: 8px; background: #f1f4ed; display: grid; place-items: center; color: #798b6d; font-size: 11px; font-weight: 600; flex-shrink: 0; }
.source-name { font-size: 11px; font-weight: 550; margin: 0; }
.source-description { color: #949c8d; font-size: 9px; line-height: 1.8; min-height: 32px; margin: 0 0 13px; }
.source-status { display: flex; align-items: center; gap: 6px; font-size: 9px; color: #90998a; }
.status-dot { width: 5px; height: 5px; border-radius: 50%; background: #b6beaf; }
.source-status[data-status="connected"] .status-dot { background: #629a68; }
.source-status[data-status="error"] .status-dot { background: #c77d66; }
.source-status[data-status="stale"] .status-dot,
.source-status[data-status="partial"] .status-dot { background: #b69a55; }
.source-updated { display: block; color: #929c89; font-size: 8px; margin-top: 8px; }
.page-footer { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding-top: 23px; font-size: 9px; color: #929b8c; }
.load-state { padding: 70px 20px; text-align: center; background: white; border: 1px solid var(--line); border-radius: var(--radius); }
.load-state h2 { margin-top: 20px; }
.load-state p { font-size: 12px; color: var(--muted); line-height: 1.8; }
.spinner { display: inline-block; width: 26px; height: 26px; border: 2px solid #e3eadb; border-top-color: #8aab71; border-radius: 50%; animation: spin .8s linear infinite; }
.load-state.is-error .spinner { display: none; }
.empty-state { text-align: center; padding: 30px 23px 35px; }
.empty-state > span { color: #a4bb8b; font-size: 30px; }
.empty-state h3 { font-size: 13px; font-weight: 550; }
.empty-state p { font-size: 11px; line-height: 1.8; color: var(--muted); max-width: 300px; margin: auto; }
.workspace-grid.single-view { grid-template-columns: 1fr; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (min-width: 1500px) { .main { padding-inline: 60px; } }
@media (max-width: 1100px) {
  .app-shell { grid-template-columns: 204px minmax(0, 1fr); }
  .main { padding-inline: 26px; }
  .workspace-grid { grid-template-columns: 1fr; }
  .source-list { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .sidebar { padding-inline: 14px; }
}
@media (max-width: 760px) {
  .app-shell { display: block; }
  .sidebar { min-height: auto; padding: 17px 20px 13px; }
  .brand-mark { width: 33px; height: 33px; font-size: 26px; border-radius: 10px; }
  .brand { padding: 0; font-size: 13px; }
  .brand small { font-size: 9px; }
  .nav-caption, .sidebar-note, .sidebar-footer { display: none; }
  .navigation { display: flex; gap: 8px; margin-top: 18px; }
  .navigation a { padding: 10px 12px; font-size: 11px; gap: 7px; }
  .navigation svg { width: 15px; height: 15px; }
  .nav-count { display: none; }
  .main { padding: 0 20px 24px; }
  .topbar { min-height: 68px; }
  .topbar time { display: none; }
  .page-heading { padding-top: 27px; }
  h1 { font-size: 29px; letter-spacing: -1px; }
  .heading-decoration { font-size: 36px; }
  .stats-grid { gap: 9px; margin-bottom: 18px; }
  .stat-card { padding: 16px 12px; border-radius: 13px; gap: 12px; }
  .stat-label { font-size: 9px; line-height: 1.6; min-height: 29px; }
  .stat-card strong { font-size: 29px; }
  .stat-card strong small { font-size: 9px; margin-left: 3px; }
  .stat-description { font-size: 8px; line-height: 1.7; }
  .orange-dot { display: none; }
  .source-list { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .panel-heading { padding-inline: 19px; }
  .task-summary { padding-inline: 19px; }
  .mode-notice { font-size: 10px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
