/* ContaClara: workspace typography, neutral surfaces and compact actions. */
@media screen {
  :root { --cream:#f3f4f2; --ink:#202b27; --muted:#626e67; --line:#dce1dc; --green:#205b46; --surface:#fff; }
  html[data-theme="dark"] { --cream:#151a18; --ink:#edf1ed; --muted:#a5b1aa; --line:#35413a; --green:#82c6a4; --surface:#202823; }
  body { font-size:14px; color:var(--ink); background:var(--cream); }
  .sidebar { background:var(--surface); padding-top:24px; }
  .brand { margin-bottom:26px; letter-spacing:-.7px; }
  .brand-symbol { transform:none; border-radius:8px; }
  .brand small,.side-note { display:none; }
  .business-switch { border-radius:6px; margin-bottom:24px; background:var(--surface); }
  .business-switch b { font-size:13px; }
  .business-switch small,.owner small { font-size:11px; color:var(--muted); }
  .nav-label { font-size:10px; letter-spacing:.8px; }
  .nav-item { font-size:14px; border-radius:5px; min-height:46px; padding:11px 13px; }
  .nav-item.active { background:#e8f0eb; color:#205b46; box-shadow:inset 3px 0 #205b46; }
  .nav-dot { display:none; }
  .owner { padding:18px 5px; }
  .owner b { font-size:12px; }
  .topbar { background:var(--surface); height:60px; }
  .breadcrumbs { font-size:12px; }
  .breadcrumbs b { color:var(--ink); }
  .theme-switch select,.save-status,.private-badge { font-size:11px; }
  main { max-width:1440px; padding-top:28px; }
  .page-heading { margin-bottom:22px; }
  .eyebrow { font-size:11px; letter-spacing:.4px; color:var(--muted); }
  h1 { font-size:30px; font-weight:650; letter-spacing:-.8px; margin:8px 0; }
  h2 { font-size:18px; font-weight:650; letter-spacing:-.3px; }
  .page-heading p { font-size:14px; color:var(--muted); }
  .movement-shortcuts { gap:0; padding:6px; background:var(--surface); border:1px solid var(--line); border-radius:6px; margin-bottom:18px; }
  .movement-shortcuts button { background:transparent; color:var(--ink); border-radius:4px; font-size:13px; min-height:44px; padding:10px 8px; }
  .movement-shortcuts button+button { border-left:1px solid var(--line); }
  .movement-shortcuts button .icon { color:#205b46; width:18px; height:18px; }
  .movement-shortcuts button:hover { background:#e8f0eb; filter:none; }
  .demo-banner { background:transparent; border:0; border-left:3px solid #b8954e; border-radius:0; padding:8px 12px; font-size:12px; color:var(--muted); }
  .demo-label { background:#eee8dc; color:#725b2f; font-size:10px; letter-spacing:.4px; }
  .demo-banner button { font-size:12px; color:var(--ink); }
  .view-toolbar { margin:24px 0 16px; }
  .tabs { flex-wrap:wrap; gap:4px; }
  .tabs button { font-size:13px; color:var(--muted); min-height:40px; border-radius:4px; }
  .tabs button.selected { background:var(--surface); color:var(--ink); border-color:var(--line); box-shadow:none; }
  .period-control { min-height:40px; border-radius:5px; background:var(--surface); border-color:var(--line); }
  .period-control select { font-size:12px; color:var(--ink); }
  .stats-grid { gap:0; background:var(--surface); border:1px solid var(--line); border-radius:6px; overflow:hidden; }
  .stat-card { border:0; border-radius:0; border-bottom:1px solid var(--line); border-right:1px solid var(--line); padding:22px; min-height:146px; text-align:left; background:transparent; }
  .stat-top { font-size:13px; color:var(--muted); align-items:flex-start; }
  .stat-top .icon { color:var(--muted); }
  .stat-value { font-size:30px; font-weight:650; letter-spacing:-1px; margin:14px 0 10px; }
  .stat-caption { font-size:12px; color:var(--muted); line-height:1.5; }
  .stat-card.featured { background:#eaf2ed; color:#205b46; border-color:var(--line); }
  .featured:after { display:none; }
  .featured .stat-top,.featured .stat-caption { color:#526b5d; }
  .featured .stat-value { color:#205b46; }
  .soft-pill { background:#d4e7da; color:#205b46; font-size:11px; border-radius:3px; }
  .stat-card.clickable:hover { background:#f0f5f1; filter:none; }
  .panel { border-radius:6px; background:var(--surface); border-color:var(--line); box-shadow:none; }
  .panel-heading { padding-top:22px; }
  .panel-heading p { font-size:12px; color:var(--muted); margin-top:6px; }
  .small-label { font-size:10px; letter-spacing:.6px; color:var(--muted); }
  .charts-grid { gap:18px; }
  .chart-legend { gap:20px; }
  .legend-toggle { font-size:12px; color:var(--muted); min-height:32px; }
  .chart-controls { margin:8px 22px 16px; padding:12px 0; border-top:1px solid var(--line); border-bottom:1px solid var(--line); }
  .chart-controls label,.chart-controls input,.chart-controls select { font-size:12px; }
  .chart-foot { font-size:11px; color:var(--muted); }
  .button,.button.small { font-size:13px; border-radius:5px; min-height:40px; box-shadow:none; }
  .button.primary { background:#205b46; border-color:#205b46; color:#fff; }
  .button.secondary { background:var(--surface); border-color:var(--line); color:var(--ink); }
  .text-button { font-size:13px; color:var(--green); min-height:36px; }
  table { font-size:13px; }
  th { font-size:11px; letter-spacing:.2px; color:var(--muted); background:var(--cream); }
  td { padding-top:15px; padding-bottom:15px; }
  .movement-cell small,.entry-code { font-size:11px; }
  .report-line { font-size:14px; min-height:44px; }
  .report-line.detail { font-size:13px; color:var(--muted); }
  .report-line.total { border-radius:4px; }
  .insight-panel { background:var(--surface); border:1px solid var(--line); border-radius:6px; padding:24px; }
  .insight-icon { display:none; }
  .insight-panel h2 { font-size:22px; line-height:1.3; margin:12px 0; }
  .insight-panel p { font-size:13px; color:var(--muted); }
  .page-footer { font-size:11px; color:var(--muted); margin-top:28px; }
  .modal { border-radius:8px; background:var(--surface); box-shadow:0 16px 64px #0003; }
  .modal h2 { font-size:23px; }
  .modal-subtitle,.modal>p { font-size:13px; color:var(--muted); }
  .modal label,.form-grid label,.movement-section label { font-size:13px; color:var(--muted); }
  .featured .stat-caption span:not(.soft-pill) { color:inherit; }
  input,select,textarea { border-radius:5px; }
  .movement-choice { border-radius:5px; padding:18px; }
  .movement-choice b { font-size:14px; }
  .movement-choice small { font-size:13px; }
  .movement-choice-icon { background:#e8f0eb; color:#205b46; border-radius:5px; }
  html[data-theme="dark"] .sidebar,html[data-theme="dark"] .topbar,html[data-theme="dark"] .panel,html[data-theme="dark"] .stat-card,html[data-theme="dark"] .insight-panel { background:var(--surface); }
  html[data-theme="dark"] .stat-card.featured,html[data-theme="dark"] .nav-item.active { background:#263f32; color:#bce4cc; }
  html[data-theme="dark"] .featured .stat-value { color:#bce4cc; }
  html[data-theme="dark"] .featured .stat-top,html[data-theme="dark"] .featured .stat-caption { color:#b5c6ba; }
  html[data-theme="dark"] .movement-shortcuts button .icon { color:#82c6a4; }
  html[data-theme="dark"] .movement-shortcuts button:hover,html[data-theme="dark"] .stat-card.clickable:hover { background:#2a3830; }
  html[data-theme="dark"] .demo-banner { background:transparent; }
}
@media screen and (max-width:1000px) and (min-width:701px) {
  .movement-shortcuts { grid-template-columns:repeat(3,minmax(0,1fr)); }
  .movement-shortcuts button:nth-child(4) { border-left:0; }
}
@media screen and (max-width:700px) {
  .sidebar { background:var(--surface); padding:10px 16px; }
  .sidebar .brand { margin:0; }
  .sidebar .brand-symbol { width:30px; height:32px; }
  .sidebar .business-switch { max-width:170px; background:var(--surface); }
  .sidebar nav { background:var(--surface); border-top:1px solid var(--line); padding:6px 5px max(6px,env(safe-area-inset-bottom)); }
  .sidebar nav .nav-item { font-size:11px; min-height:54px; padding:7px 3px; }
  .sidebar nav .nav-item.active { box-shadow:inset 0 3px #205b46; }
  main { padding:24px 16px 20px; }
  .topbar { min-height:48px; height:auto; padding:8px 16px; }
  .breadcrumbs { font-size:11px; }
  .page-heading { margin-bottom:18px; }
  h1 { font-size:27px; }
  .page-heading p { font-size:13px; max-width:36ch; }
  .eyebrow { font-size:10px; }
  .movement-shortcuts { grid-template-columns:repeat(3,minmax(0,1fr)); padding:4px; gap:0; }
  .movement-shortcuts button { flex-direction:row; gap:6px; min-height:44px; font-size:12px; padding:8px 4px; }
  .movement-shortcuts button:nth-child(3) { font-size:11px; }
  .movement-shortcuts button:nth-child(4) { border-left:0; }
  .movement-shortcuts button .icon { width:15px; height:15px; }
  .demo-banner { flex-wrap:wrap; gap:7px; }
  .demo-banner p { flex:1; min-width:180px; font-size:11px; }
  .demo-banner button { margin-left:0; min-height:32px; }
  .stats-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .stat-card { padding:17px 13px; min-height:143px; }
  .stat-top { font-size:12px; }
  .stat-top .icon { width:14px; height:14px; }
  .stat-value { font-size:clamp(22px,4.8vw,29px); }
  .stat-caption { font-size:11px; }
  .chart-controls { margin:10px 16px 14px; gap:9px; }
  .chart-controls input { max-width:135px; }
  .panel-heading p { font-size:12px; }
  .reports-toolbar .tabs button { font-size:14px; }
  .insight-panel h2 { font-size:21px; }
}
@media screen and (max-width:400px) {
  .topbar .private-badge { display:none; }
  .topbar-right { gap:6px; }
  .breadcrumbs { gap:5px; }
}
@media screen and (max-width:360px) {
  .sidebar .brand { font-size:18px; gap:6px; }
  .sidebar .business-switch { max-width:110px; }
  .sidebar .business-switch b { font-size:10px; }
  .sidebar .business-avatar { width:22px; height:22px; flex-basis:22px; }
  .stat-value { font-size:20px; letter-spacing:-.6px; }
  .movement-shortcuts button { font-size:11px; gap:4px; }
  .view-toolbar { flex-wrap:wrap; }
}
