/* SFERA Finance ─ restrained, desktop-first independent accounting. */
:root{color-scheme:dark;--bg:#0a0b10;--rail:#101117;--panel:#12151c;--panel-hover:#171a23;--panel-raised:#1b1e27;--line:#252a35;--line-strong:#393f4d;--text:#f4f5f8;--muted:#b9bfca;--dim:#9099aa;--accent:#a898ff;--accent-soft:#2b2546;--mint:#72e6ba;--mint-soft:#14372c;--red:#ff98a4;--red-soft:#42262d;--amber:#ffdc89;--amber-soft:#3f3420;--shadow:0 20px 60px #0004;--radius:12px;--body:-apple-system,BlinkMacSystemFont,"Segoe UI",system-ui,sans-serif;--mono:ui-monospace,"SFMono-Regular",Consolas,monospace;--rail-width:248px}
*{box-sizing:border-box}html,body{margin:0;min-height:100%;background:var(--bg);color:var(--text);font:14px/1.5 var(--body);font-synthesis:none; -webkit-font-smoothing:antialiased}button,input,textarea,select{font:inherit;color:inherit}button{cursor:pointer}button:disabled{opacity:.55;cursor:not-allowed}a{color:inherit}button:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible,a:focus-visible,[tabindex]:focus-visible{outline:2px solid #b9aaff;outline-offset:3px}[hidden]{display:none!important}strong{font-weight:650}svg{display:inline-block;vertical-align:middle;flex-shrink:0}h1,h2,h3,p{margin:0}h1{font-weight:650;letter-spacing:-.035em;font-size:2rem;line-height:1.15}h2{font-size:1.02rem;font-weight:650;letter-spacing:-.015em}h3{font-size:.93rem;font-weight:650}.mono{font-family:var(--mono);font-variant-numeric:tabular-nums;letter-spacing:-.025em}.positive{color:var(--mint)}.negative{color:var(--red)}.warning{color:var(--amber)}.muted{color:var(--muted)}.dim{color:var(--dim)}.text-right{text-align:right}.nowrap{white-space:nowrap}.overline{display:block;font-size:.66rem;text-transform:uppercase;letter-spacing:.13em;line-height:1.3;color:var(--dim);font-weight:650}.skip{position:fixed;top:4px;left:-1000px;padding:8px 16px;background:var(--accent);color:#16112e;z-index:999}.skip:focus{left:4px}
.brand{display:flex;align-items:center;gap:12px;font-weight:700;letter-spacing:.22em;font-size:19px;white-space:nowrap;line-height:1.03}.brand small{display:block;font-size:9px;letter-spacing:.28em;margin-top:5px;color:#c7c0ff}.brand-mark{display:grid;place-items:center;width:36px;height:36px;border:1.5px solid #d4ccff;border-radius:50%;transform:rotate(-24deg);position:relative;box-shadow:0 0 12px #a898ff25;flex:none}.brand-mark::before{content:"";position:absolute;width:12px;height:36px;border:1px solid #d4ccff;border-radius:50%;transform:rotate(24deg)}.brand-mark::after{content:"";position:absolute;width:43px;height:11px;border:1px solid #d4ccff;border-radius:50%;transform:rotate(5deg)}.brand-mark i{width:6px;height:6px;border-radius:50%;background:#ddd5ff;position:absolute;top:1px;left:5px;box-shadow:0 0 6px #fff8}.splash{min-height:100vh;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:14px;letter-spacing:.14em;color:var(--muted)}.splash small{letter-spacing:0;color:var(--dim)}
/* Authentication */
.login-stage{display:grid;grid-template-columns:minmax(400px,1fr) minmax(400px,1fr);min-height:100vh}.login-art{position:relative;overflow:hidden;padding:52px 58px;background:radial-gradient(ellipse at 51% 41%,#282444 0,#191825 35%,#0f1018 68%);display:flex;flex-direction:column;justify-content:space-between;min-height:100vh;border-right:1px solid #2c2b3c}.login-brand{position:relative;z-index:2}.login-copy{position:relative;z-index:2}.login-copy h2{font-size:2.85rem;line-height:1.08;letter-spacing:-.035em;margin:12px 0 18px;font-weight:600}.login-copy p{max-width:390px;color:#c1c4d3;font-size:15px}.login-foot{display:flex;justify-content:space-between;color:var(--dim);font-size:12px;gap:18px}.login-visual{position:absolute;inset:6% 0 17%;display:grid;place-items:center;pointer-events:none}.orb{position:relative;width:240px;height:240px;border-radius:50%;background:radial-gradient(circle at 35% 25%,#565178,#25233b 35%,#141522 67%,#0b0d15 85%);box-shadow:inset 0 0 26px #a898ff28,0 15px 80px #0009;transform:rotate(-17deg);border:1px solid #a898ff50}.orb::before,.orb::after{content:"";position:absolute;inset:-20px;border-radius:50%;border:1px solid #a898ff40;transform:scaleX(.5) rotate(45deg)}.orb::after{transform:scaleX(.58) rotate(-38deg)}.orb-ring{position:absolute;left:-55px;right:-55px;top:83px;height:74px;border:2px solid #bbadffb0;border-radius:50%;transform:rotate(-12deg);box-shadow:0 0 15px #9f8fff42}.orb i{position:absolute;top:78px;right:-39px;width:9px;height:9px;border-radius:50%;background:#dad1ff;box-shadow:0 0 18px #c2b2ff}.login-panel{display:grid;place-items:center;padding:40px}.login-box{max-width:390px;width:100%}.login-box h1{font-size:1.7rem;margin-top:20px}.login-box>p{margin:12px 0 30px;color:var(--muted)}.login-lock{display:grid;place-items:center;width:44px;height:44px;border-radius:12px;background:var(--accent-soft);color:var(--accent);border:1px solid #4c426f}.login-box label{display:block;margin:0 0 9px;color:var(--muted);font-weight:550}.login-box input{width:100%;height:46px;background:#151720}.login-submit{width:100%;justify-content:space-between;margin-top:18px;min-height:44px}.login-note{margin:24px 0 0!important;font-size:12px;line-height:1.65;color:var(--dim)!important}.mobile-brand{display:none;margin:0 0 42px}
/* Navigation and structure */
.workspace{display:grid;grid-template-columns:var(--rail-width) minmax(0,1fr);min-height:100vh}.sidebar{height:100vh;position:sticky;top:0;display:flex;flex-direction:column;gap:22px;padding:25px 16px 15px;background:var(--rail);border-right:1px solid var(--line);overflow-y:auto;z-index:20}.sidebar-brand{margin:2px 12px 4px}.space-label{display:flex;align-items:center;gap:10px;padding:11px 9px;border:1px solid #2b2f3a;background:#161821;border-radius:10px}.space-avatar{width:31px;height:31px;display:grid;place-items:center;border-radius:7px;background:var(--accent-soft);color:#d1c5ff;font-size:10px;font-weight:700;letter-spacing:.06em;flex-shrink:0}.space-label strong,.space-label small,.owner strong,.owner small,.source-mini strong,.source-mini small{display:block;line-height:1.35}.space-label strong{font-size:11px;white-space:nowrap;letter-spacing:-.03em}.space-label small{font-size:10px;color:var(--dim);margin-top:4px}.main-nav{display:flex;flex-direction:column;gap:3px}.nav-caption{font-size:10px;letter-spacing:.1em;color:var(--dim);font-weight:600;padding:8px 12px 5px}.nav-caption:not(:first-child){margin-top:16px}.main-nav button{display:flex;align-items:center;gap:10px;min-height:42px;border:1px solid transparent;padding:9px 11px;border-radius:8px;background:none;color:#b8bfcb;text-align:left;font-size:13px;font-weight:500;transition:background 140ms,color 140ms}.main-nav button:hover{background:#1c1e28;color:var(--text)}.main-nav button[aria-current="page"]{color:#dcd3ff;background:#2c2644;border-color:#4b416c;font-weight:600}.nav-icon{display:flex;align-items:center;justify-content:center;width:20px;color:#a8aebb}.main-nav button[aria-current="page"] .nav-icon{color:#c3b4ff}.sidebar-footer{margin-top:auto;display:flex;flex-direction:column;gap:12px}.source-mini{padding:10px 9px 12px;border-bottom:1px solid var(--line);display:flex;align-items:flex-start;gap:9px}.source-mini .status-dot{margin-top:5px}.source-mini strong,.owner strong{font-size:12px}.source-mini small,.owner small{font-size:11px;color:var(--dim);margin-top:4px;overflow-wrap:anywhere}.owner{display:flex;align-items:center;gap:9px;padding:2px 3px}.owner-avatar{width:34px;height:34px;border-radius:50%;border:1px solid #554b6d;background:#2c263b;color:#ded3ff;display:grid;place-items:center;font-weight:600}.owner .icon-btn{margin-left:auto;color:var(--dim)}.status-dot{width:7px;height:7px;border-radius:50%;background:var(--dim);display:inline-block;flex:none}.status-dot.good{background:var(--mint);box-shadow:0 0 7px #72e6ba30}.status-dot.warn{background:var(--amber)}.status-dot.bad{background:var(--red)}.main{min-width:0;display:flex;flex-direction:column;min-height:100vh}.topbar{height:63px;display:flex;align-items:center;justify-content:space-between;gap:18px;padding:0 34px;border-bottom:1px solid var(--line);background:#0f1118;position:sticky;top:0;z-index:15}.topbar-left,.topbar-right,.topbar-state{display:flex;align-items:center;gap:14px}.crumb{font-size:12px;color:var(--dim)}.crumb>span{padding:0 5px;color:#6b7383}.crumb strong{color:var(--muted);font-weight:550}.topbar-state{font-size:11px;color:var(--muted);gap:7px}.time-zone{font-size:11px;color:var(--dim);white-space:nowrap;border-left:1px solid var(--line);padding-left:15px;letter-spacing:.02em}.mobile-menu{display:none!important}.page{max-width:1580px;width:100%;margin:0 auto;padding:34px 34px 30px;flex:1}.page-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:18px;margin-bottom:24px}.page-heading h1{margin:8px 0}.page-heading p{color:var(--muted);font-size:13px;max-width:700px}.page-actions{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:8px;align-items:center;padding-top:19px}.page-foot{display:flex;justify-content:center;gap:9px;flex-wrap:wrap;padding:19px;color:#83909e;font-size:11px;border-top:1px solid var(--line)}.page-foot span{color:#535963}.period-bar{display:flex;flex-wrap:wrap;align-items:center;gap:12px;justify-content:space-between;border:1px solid var(--line);background:var(--panel);border-radius:10px;padding:9px 11px;margin-bottom:24px}.period-presets{display:flex;flex-wrap:wrap;gap:3px}.period-presets button{background:transparent;border:1px solid transparent;border-radius:6px;padding:7px 10px;font-size:12px;color:var(--muted);transition:background 150ms,color 150ms}.period-presets button:hover{background:var(--panel-raised);color:var(--text)}.period-presets button[aria-pressed="true"]{background:var(--accent-soft);border-color:#51466e;color:#e0d8ff}.date-form{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.date-form input{font-size:12px;width:128px;min-height:34px;padding:7px 8px}.date-label{font-size:11px;color:var(--dim)}
/* Controls */
.btn{background:var(--panel-raised);border:1px solid var(--line-strong);border-radius:8px;min-height:37px;padding:8px 13px;display:inline-flex;align-items:center;justify-content:center;gap:8px;font-size:12px;font-weight:600;white-space:nowrap;transition:background 150ms,border-color 150ms,color 150ms;line-height:1.4}.btn:hover:not(:disabled){background:#252935;border-color:#505769}.btn.primary{background:var(--accent);border-color:var(--accent);color:#1a1332}.btn.primary:hover:not(:disabled){background:#c3b5ff;border-color:#c3b5ff}.btn.secondary{background:#1c1f2a;border-color:var(--line-strong);color:var(--text)}.btn.ghost{background:transparent;border-color:transparent;color:var(--muted)}.btn.ghost:hover:not(:disabled){background:#242735;color:var(--text)}.btn.danger{background:var(--red-soft);color:#ffc1c9;border-color:#6d3d48}.btn.compact{min-height:31px;padding:6px 10px}.icon-btn{display:grid;place-items:center;min-width:34px;height:34px;background:transparent;border:1px solid transparent;border-radius:8px;color:var(--muted)}.icon-btn:hover:not(:disabled){background:var(--panel-raised);color:var(--text)}input,select,textarea{width:100%;min-width:0;background:#0e1017;color:var(--text);border:1px solid #414654;border-radius:7px;padding:9px 11px;line-height:1.4;min-height:40px;transition:border-color 150ms}input:hover,select:hover,textarea:hover{border-color:#72798b}input:focus,select:focus,textarea:focus{border-color:#b2a1ff}input::placeholder,textarea::placeholder{color:#929aac}input[readonly]{color:#b0b8c6}select{cursor:pointer}textarea{resize:vertical;min-height:90px}input[type="date"]{color-scheme:dark}label{font-size:12px}.form-error{color:#ffc0c9;background:var(--red-soft);border:1px solid #764752;padding:10px 12px;border-radius:7px;font-size:12px;margin:7px 0 15px}.field{display:flex;flex-direction:column;gap:7px}.field>label,.field>.label{font-weight:550;color:var(--muted)}.field small{color:var(--dim);line-height:1.45}.field-row{display:grid;grid-template-columns:1fr 1fr;gap:12px}.field-row.three{grid-template-columns:1fr 1fr 1fr}.filter-group{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.filter-group select,.filter-group input{min-height:34px;font-size:12px;padding:7px 10px;width:auto}.filter-group input[type="search"]{width:220px;max-width:100%}.filter-group label{color:var(--dim);font-size:11px}.search-wrap{position:relative;display:block}.search-wrap svg{position:absolute;left:10px;top:9px;color:var(--dim);pointer-events:none}.search-wrap input{padding-left:32px}.form-help{font-size:12px;color:var(--dim);line-height:1.5}
/* Dashboard */
.content{display:flex;flex-direction:column;gap:19px;min-height:290px;min-width:0}.metrics-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px}.metric{min-width:0;border:1px solid var(--line);background:var(--panel);border-radius:var(--radius);padding:18px 17px 14px;position:relative;overflow:hidden}.metric.key{background:linear-gradient(108deg,#211c35 0,#161522 90%);border-color:#43395b}.metric-label{display:flex;align-items:center;justify-content:space-between;gap:7px;color:var(--muted);font-size:12px;font-weight:500}.metric-icon{width:30px;height:30px;display:grid;place-items:center;color:var(--dim);background:#1e222d;border:1px solid var(--line);border-radius:8px}.metric.key .metric-icon{color:#bfb0ff;background:#312849;border-color:#514371}.metric-value{display:flex;align-items:baseline;gap:4px;font-size:1.65rem;font-weight:620;line-height:1.24;letter-spacing:-.04em;margin-top:13px;font-variant-numeric:tabular-nums;white-space:normal;overflow-wrap:anywhere}.metric-value .unit{font-size:.61rem;font-weight:550;letter-spacing:0;color:var(--dim)}.metric-value .null{font-size:1.3rem;color:var(--dim)}.metric-note{display:flex;align-items:center;gap:5px;color:var(--dim);font-size:11px;line-height:1.4;min-height:16px;margin-top:8px}.dashboard-grid{display:grid;grid-template-columns:minmax(0,1.74fr) minmax(260px,1fr);gap:14px}.dashboard-grid.half{grid-template-columns:1fr 1fr}.panel{min-width:0;background:var(--panel);border:1px solid var(--line);border-radius:var(--radius);overflow:hidden}.panel-head{display:flex;justify-content:space-between;align-items:flex-start;gap:15px;padding:19px 20px 14px}.panel-head p{color:var(--dim);font-size:11px;margin-top:5px}.panel-body{padding:0 20px 19px}.panel-head .btn{margin-top:-2px}.chart-wrap{padding:4px 17px 13px}.chart{width:100%;height:auto;display:block;overflow:visible}.chart-legend{display:flex;gap:17px;align-items:center;flex-wrap:wrap;font-size:11px;color:var(--muted);padding:4px 20px 15px}.legend-key{display:flex;align-items:center;gap:6px}.legend-dot{width:8px;height:8px;border-radius:2px;background:var(--accent);display:inline-block}.legend-dot.mint{background:var(--mint)}.legend-dot.red{background:var(--red)}.chart-title{display:flex;gap:7px;align-items:baseline}.breakdown{display:flex;flex-direction:column;gap:17px;padding:7px 0 2px}.breakdown-row{display:flex;justify-content:space-between;align-items:baseline;gap:8px;font-size:12px}.breakdown-row strong{font-weight:550}.track{height:6px;border-radius:9px;background:#242834;margin-top:7px;overflow:hidden}.track>span{display:block;height:100%;border-radius:9px;background:var(--accent)}.breakdown-total{border-top:1px solid var(--line);display:flex;justify-content:space-between;gap:8px;padding:15px 0 2px;margin-top:13px;color:var(--muted);font-size:12px}.breakdown-total strong{font:600 13px var(--mono);color:var(--text)}.snapshot-panel .panel-body{display:grid;gap:0}.kv-line{display:flex;justify-content:space-between;align-items:center;gap:12px;border-bottom:1px solid #272b35;padding:11px 0;color:var(--muted);font-size:12px}.kv-line:last-child{border-bottom:0;padding-bottom:2px}.kv-line .mono{color:var(--text);white-space:nowrap;font-weight:550}.kv-line .mono.positive{color:var(--mint)}.kv-line .mono.negative{color:var(--red)}.kv-line .mono.warning{color:var(--amber)}.kv-line>span:first-child{display:flex;flex-direction:column}.kv-line small{font-size:10px;color:var(--dim);margin-top:3px}.notice{border:1px solid #3f3657;background:#211c31;padding:12px 15px;border-radius:9px;display:flex;align-items:center;gap:10px;color:#dfd4ff;font-size:12px}.notice .notice-text{flex:1;min-width:0}.notice strong{display:block;margin-bottom:2px}.notice small{color:#d0c8e0;font-size:11px}.notice.warn{background:#252015;border-color:#554723;color:var(--amber)}.notice.warn small{color:#e5d4a9}.notice.ok{background:#172923;border-color:#2f5445;color:var(--mint)}.notice-source-button{background:none;border:0;color:inherit;font-weight:600;white-space:nowrap;text-decoration:underline;text-underline-offset:3px;font-size:12px}
/* Registries */
.registry-head{display:flex;justify-content:space-between;gap:12px;align-items:center;padding:15px 20px;border-bottom:1px solid var(--line);flex-wrap:wrap}.registry-head h2{font-size:14px}.registry-head p{font-size:11px;color:var(--dim);margin-top:3px}.table-wrap{overflow-x:auto;max-width:100%}table{width:100%;border-collapse:collapse;text-align:left;font-size:12px;min-width:660px}th{text-transform:none;font-weight:550;color:#a9b0bd;background:#141720;padding:12px 16px;border-bottom:1px solid var(--line);white-space:nowrap;font-size:11px;letter-spacing:.015em}td{padding:13px 16px;border-bottom:1px solid #262a34;line-height:1.4;color:var(--muted);vertical-align:top}tbody tr:last-child td{border-bottom:0}tbody tr:hover{background:#181b23}td:first-child,th:first-child{padding-left:20px}td:last-child,th:last-child{padding-right:20px}.cell-main{color:var(--text);font-weight:550;display:block}.cell-sub{display:block;font-size:10px;color:var(--dim);margin-top:4px}.cell-num{color:var(--text);font:500 12px/1.45 var(--mono);white-space:nowrap}.cell-num.positive{color:var(--mint)}.cell-num.negative{color:var(--red)}.cell-num.warning{color:var(--amber)}.cell-action{white-space:nowrap;text-align:right}.row-link{padding:0;border:0;background:none;color:#d5cbff;font-weight:600;text-align:left}.row-link:hover{text-decoration:underline;text-underline-offset:3px}.badge{display:inline-flex;gap:5px;align-items:center;border-radius:5px;padding:3px 6px;font-size:10px;white-space:nowrap;color:#d0d3dd;background:#252a35;border:1px solid #343b49;line-height:1.2}.badge.positive{color:#92ebc5;background:#19382d;border-color:#2d5545}.badge.negative{color:#ffb2bc;background:#38232b;border-color:#65404a}.badge.warning{color:#f6d68b;background:#362e19;border-color:#5d5030}.badge.neutral{color:#ccc4ff;background:#2d2643;border-color:#4c4169}.voided td{opacity:.67}.pagination{display:flex;justify-content:space-between;align-items:center;padding:11px 20px;border-top:1px solid var(--line);gap:10px;font-size:11px;color:var(--dim)}.page-buttons{display:flex;align-items:center;gap:5px}.page-buttons button{min-width:29px;height:29px;display:grid;place-items:center}.page-buttons button.current{color:#ded6ff;background:#2f2748;border-color:#584c7a}.empty{display:flex;flex-direction:column;align-items:center;text-align:center;padding:42px 20px 48px;gap:8px;color:var(--muted);font-size:12px}.empty-icon{width:48px;height:48px;border:1px solid #3c4051;background:#1e222d;color:var(--accent);border-radius:12px;display:grid;place-items:center;margin-bottom:4px}.empty strong{font-size:14px;color:var(--text)}.empty p{max-width:390px;color:var(--dim);line-height:1.55}.empty .btn{margin-top:8px}.skeleton{height:102px;background:#1c1f29;border:1px solid #252b37;border-radius:12px;animation:pulse 1.25s ease-in-out infinite alternate}.skeleton.large{height:260px}.skeleton-line{height:12px;background:#2b3040;border-radius:4px;width:55%;margin:18px}.skeleton-line.short{width:30%}@keyframes pulse{from{opacity:.5}to{opacity:1}}
/* Editor and details */
.editor{max-width:min(640px,100vw - 24px);width:100%;max-height:calc(100vh - 48px);margin:auto;padding:0;color:var(--text);border:1px solid var(--line-strong);background:#151821;border-radius:14px;box-shadow:0 30px 100px #0009;overflow:auto}.editor::backdrop{background:#03040ab8;backdrop-filter:blur(2px)}.editor-head{display:flex;align-items:flex-start;justify-content:space-between;gap:15px;padding:22px 25px;border-bottom:1px solid var(--line)}.editor-head h2{font-size:1.3rem;margin-top:5px;line-height:1.3}.editor-head p{max-width:500px;color:var(--muted);font-size:12px;margin-top:7px}.editor-head .icon-btn{margin-top:-7px;margin-right:-6px}.editor-content{padding:22px 25px;display:flex;flex-direction:column;gap:16px}.editor-content form{display:flex;flex-direction:column;gap:14px}.editor-actions{display:flex;justify-content:flex-end;align-items:center;gap:8px;border-top:1px solid var(--line);padding:16px 25px;background:#12151e;position:sticky;bottom:0}.editor-actions .primary{min-width:130px}.editor-preview{display:flex;justify-content:space-between;align-items:center;gap:12px;background:#201a31;border:1px solid #473e61;padding:13px;border-radius:8px;font-size:12px;color:#d6cdf6}.editor-preview strong{font:600 14px var(--mono);white-space:nowrap}.detail-metrics{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}.detail-metric{border:1px solid var(--line);background:#12151e;border-radius:8px;padding:12px}.detail-metric small{font-size:10px;color:var(--dim);display:block}.detail-metric strong{font:600 14px var(--mono);display:block;margin-top:7px;overflow-wrap:anywhere}.detail-list{display:flex;flex-direction:column;gap:8px}.detail-item{border:1px solid var(--line);border-radius:8px;background:#13161e;padding:11px;display:flex;justify-content:space-between;align-items:flex-start;gap:10px;font-size:12px}.detail-item .mono{white-space:nowrap}.detail-item small{display:block;color:var(--dim);margin-top:3px}.toast-area{position:fixed;right:24px;bottom:24px;z-index:80;display:flex;flex-direction:column;gap:8px;max-width:min(370px,calc(100vw - 48px))}.toast{padding:12px 15px;border:1px solid #3a5d4e;background:#182f26;color:#c7f1dc;font-size:12px;border-radius:9px;box-shadow:var(--shadow);display:flex;align-items:center;gap:9px;animation:toast-in .18s ease}.toast.error{background:#3c242c;border-color:#70414d;color:#ffd0d6}.toast button{margin-left:auto;color:inherit;background:none;border:0;font-size:18px;line-height:1}@keyframes toast-in{from{opacity:0;transform:translateY(5px)}to{opacity:1;transform:none}}
@media(max-width:1350px){:root{--rail-width:224px}.page{padding:30px 24px}.topbar{padding:0 24px}.sidebar{padding-inline:12px}.metric{padding:15px 14px}.metric-value{font-size:1.47rem}.period-bar{align-items:flex-start}.dashboard-grid{grid-template-columns:minmax(0,1.5fr) minmax(250px,1fr)}}
@media(max-width:1120px){.metrics-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.dashboard-grid,.dashboard-grid.half{grid-template-columns:1fr}.period-bar{flex-direction:column}.date-form{width:100%;justify-content:flex-start}.metric-value{font-size:1.7rem}.login-art{padding:40px 35px}.login-copy h2{font-size:2.35rem}.orb{width:200px;height:200px}}
@media(max-width:850px){:root{--rail-width:0px}.workspace{display:block}.sidebar{position:fixed;top:0;bottom:0;width:248px;transform:translateX(-103%);transition:transform .18s ease;box-shadow:20px 0 50px #0009}.sidebar.open{transform:translateX(0)}.sidebar-brand{padding-right:0;margin-top:5px}.mobile-menu{display:grid!important}.topbar{height:53px;padding:0 15px}.topbar-left{gap:6px}.topbar-state{display:none}.time-zone{border:0;font-size:10px;padding:0}.page{padding:23px 16px}.page-heading h1{font-size:1.7rem}.page-actions{padding:0;justify-content:flex-start}.page-heading{flex-direction:column;gap:11px;margin-bottom:16px}.period-bar{margin-bottom:17px}.registry-head{padding:12px 14px}.panel-body{padding-inline:16px}.panel-head{padding:16px}.page-foot{padding:14px}.login-stage{grid-template-columns:1fr;min-height:100vh}.login-art{display:none}.login-panel{min-height:100vh;padding:30px}.mobile-brand{display:flex}.login-box{max-width:410px}.login-box h1{font-size:1.6rem}.filter-group{flex:1;min-width:0}.filter-group input[type="search"]{width:170px}.page-actions .btn{white-space:normal}}
@media(max-width:520px){.metrics-grid{gap:9px}.metric{padding:11px 10px}.metric-label{font-size:11px}.metric-icon{width:25px;height:25px;display:none}.metric-value{font-size:1.25rem;margin-top:10px}.metric-value .unit{font-size:.53rem}.metric-note{font-size:10px}.date-form input{width:calc((100% - 50px)/2)}.date-form #apply-dates{width:100%;margin-top:3px}.period-presets button{font-size:11px;padding:5px 7px}.page{padding:20px 12px}.page-heading p{font-size:12px}.field-row,.field-row.three{grid-template-columns:1fr 1fr}.editor{max-width:calc(100vw - 16px);max-height:calc(100vh - 24px);border-radius:10px}.editor-head,.editor-content{padding:17px}.editor-actions{padding:13px 17px}.editor-preview{align-items:flex-start;flex-direction:column}.detail-metrics{grid-template-columns:1fr 1fr}.crumb{font-size:11px}.crumb strong{max-width:145px;display:inline-block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;vertical-align:bottom}.topbar-left{min-width:0}.notice{align-items:flex-start;flex-wrap:wrap}.notice-source-button{margin-left:28px}.filter-group input[type="search"]{width:100%;min-width:130px}.filter-group select{max-width:100%}.pagination{padding-inline:12px}.toast-area{right:12px;bottom:12px;max-width:calc(100vw - 24px)}.login-panel{padding:25px}.chart-wrap{padding:3px 8px}.registry-head h2{font-size:13px}.date-label{font-size:10px}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important;scroll-behavior:auto!important}}

/* User help entry. */
.sidebar-help{display:flex;align-items:center;gap:10px;padding:8px 11px;min-height:38px;border-radius:8px;color:var(--muted);font-size:12px;font-weight:550;text-decoration:none}.sidebar-help:hover{color:var(--text);background:#1c1e28}.sidebar-help svg{color:var(--dim);flex:none}
