 
@layer force, vendor, tokens, base, components, utilities;
@import url('../vendor/bootstrap/bootstrap.min.css') layer(vendor);
@layer force {
@media (min-width: 992px) {
  .app-sidebar.offcanvas-lg { background-color: var(--shell) !important; }
}
.app-content > .text-muted,
.app-content > .bi-report > .text-muted,
.auth-foot .text-muted { color: var(--ground-ink-muted) !important; }
}   
@layer tokens {
:root {
  color-scheme: light;
--bg: #2c509b;
  --surface: #ffffff;
  --surface-muted: #f4f6fa;    
  --surface-sunken: #dfe5f0;   
  --surface-hover: rgba(44,80,155,.055);
--ground-shade: rgba(6,14,34,.22);
--glass: rgba(223,229,240,.82);
  --glass-strong: rgba(223,229,240,.94);
  --glass-blur: 18px;
--surface-raised: rgba(255,255,255,.92);
--glass-solid: #e1e6f1;
--ground-ink: #ffffff;
  --ground-ink-muted: rgba(255,255,255,.80);
  --ground-accent: #e3c894;
  --ground-success: #6ee7b7;
  --ground-warning: #fcd34d;
  --ground-danger: #fdbcbc;
  --ground-info: #67e8f9;
  --ground-wash: rgba(255,255,255,.14);
  --ground-line: rgba(255,255,255,.22);
--shell: #d2ab67;
  --shell-strong: #d2ab67;
  --shell-solid: #d2ab67;
  --shell-ink: #16222a;
  --shell-ink-muted: #1b2a33;
  --shell-ink-faint: #2e424c;
  --shell-line: rgba(36,54,63,.22);
  --shell-hover: rgba(36,54,63,.10);
--shell-well: rgba(36,54,63,.07);
  --shell-well-strong: rgba(36,54,63,.14);
--shell-danger: #7a1212;
  --shell-active-ink: #ffffff;
--border: rgba(44,80,155,.14);
  --border-strong: rgba(44,80,155,.22);
  --surface-border: var(--border);
--text: #101728;
  --muted: #515f7a;
--faint: #57647c;
--primary: #2c509b;
  --primary-dark: #24457f;
  --primary-2: #3a6ab0;
  --primary-contrast: #ffffff;
--primary-soft: color-mix(in srgb, var(--primary) 10%, transparent);
--primary-text: #24457f;
  --primary-line: color-mix(in srgb, var(--primary) 24%, transparent);
--grad-from: #2c509b;
  --grad-to: #24363f;
  --grad-from-hover: #24457f;
  --grad-to-hover: #1a2a33;
  --grad-primary: linear-gradient(135deg, #2c509b, #24363f);
  --grad-primary-hover: linear-gradient(135deg, #24457f, #1a2a33);
--grad-primary-text: var(--grad-primary);
--accent: #8f6c30;
  --accent-soft: color-mix(in srgb, var(--accent) 10%, transparent);
--success: #0e7a4a;
  --success-soft: rgba(16,185,129,.13);
  --warning: #9a5b08;
  --warning-soft: rgba(245,158,11,.15);
  --danger: #c02626;
  --danger-soft: rgba(220,38,38,.10);
  --info: #0369a1;
  --info-soft: rgba(14,165,233,.12);
--success-fill: #10b981;
  --success-fill-strong: #059669;
  --warning-fill: #f59e0b;
  --warning-fill-strong: #d97706;
--warning-fill-deep: #f97316;
--urgent: #ea580c;
  --urgent-soft: rgba(234, 88, 12, .04);
  --danger-fill: #ef4444;
  --danger-fill-strong: #dc2626;
--accent-fill: #d2ab67;
  --accent-fill-strong: #b8904a;
--live: #34d399;
--excel: #16a765;
  --excel-strong: #0f9d58;
--chart-revenue: #2c509b;
  --chart-expense: #b8904a;
--bi-cat-1: #118dff;
  --bi-cat-2: #e66c37;
  --bi-cat-3: #12239e;
  --bi-cat-4: #6b007b;
  --bi-cat-5: #e044a7;
  --bi-cat-6: #744ec2;
  --bi-cat-7: #d9b300;
  --bi-cat-8: #d64550;
--bi-good: #1aab40;
  --bi-warn: #d9b300;
  --bi-bad: #d64550;
--bi-canvas: #f1f1f1;         
  --bi-visual: #ffffff;         
  --bi-line: #e1dfdd;           
  --bi-line-soft: #edebe9;
  --bi-ink: #252423;            
  --bi-ink-2: #605e5c;          
  --bi-chrome: #f3f2f1;         
  --bi-chrome-hover: #edebe9;
  --bi-accent: #0078d4;         
  --bi-accent-dark: #106ebe;
--bi-font: 'Segoe UI', 'Segoe UI Variable Text', system-ui, -apple-system,
             'Inter Variable', Inter, sans-serif;
  --bi-radius: 4px;
  --bi-shadow: 0 1.6px 3.6px rgba(0,0,0,.09), 0 .3px .9px rgba(0,0,0,.06);
  --bi-shadow-hover: 0 3.2px 7.2px rgba(0,0,0,.11), 0 .6px 1.8px rgba(0,0,0,.08);
--bi-shadow-focus: 0 25.6px 57.6px rgba(0,0,0,.22), 0 4.8px 14.4px rgba(0,0,0,.18);
--shadow-sm: 0 1px 2px rgba(6,14,34,.16), 0 1px 3px rgba(6,14,34,.14);
  --shadow-md: 0 2px 6px rgba(6,14,34,.16), 0 10px 26px rgba(6,14,34,.20);
  --shadow-lg: 0 14px 34px rgba(6,14,34,.30), 0 3px 8px rgba(6,14,34,.18);
--shadow-up: 0 -2px 14px rgba(6,14,34,.22);
  --shadow-glow: 0 6px 20px color-mix(in srgb, var(--primary) 28%, transparent);
--shadow-glow-strong: 0 8px 24px color-mix(in srgb, var(--primary) 34%, transparent);
  --card-shadow: var(--shadow-md);
--glow-accent: 0 6px 20px color-mix(in srgb, var(--accent-fill-strong) 26%, transparent);
  --glow-success: 0 6px 20px color-mix(in srgb, var(--success-fill) 32%, transparent);
  --glow-warning: 0 6px 20px color-mix(in srgb, var(--warning-fill) 32%, transparent);
  --glow-danger: 0 6px 20px color-mix(in srgb, var(--danger-fill-strong) 32%, transparent);
--radius-xs: .25rem;    
  --radius-sm: .55rem;    
  --radius: .8rem;        
  --radius-lg: 1.1rem;    
  --radius-xl: 1.5rem;    
  --radius-pill: 999px;
  --radius-round: 50%;
--bs-border-radius-sm: var(--radius-xs);
  --bs-border-radius: var(--radius-sm);
  --bs-border-radius-lg: var(--radius);
  --bs-border-radius-xl: var(--radius-lg);
  --bs-border-radius-xxl: var(--radius-xl);
  --bs-border-radius-pill: var(--radius-pill);
--bs-body-font-size: var(--text-base);
--rail: 3px;            
  --hairline: 1px;        
  --ring-w: 2px;          
  --ring-w-lg: 3px;       
--ring: 0 0 0 var(--ring-w-lg) color-mix(in srgb, var(--primary) 32%, transparent);
--ring-cut: 0 0 0 var(--ring-w) var(--surface);
--edge-light: inset 0 1px 0 rgba(255,255,255,.65);
  --edge-light-soft: inset 0 1px 0 rgba(255,255,255,.4);
--dur-1: .12s;    
  --dur-2: .18s;    
  --dur-3: .32s;    
  --dur-4: .7s;     
  --ease-out: cubic-bezier(.22,.61,.36,1);
  --ease-in-out: cubic-bezier(.65,0,.35,1);
  --ease-spring: cubic-bezier(.34,1.4,.64,1);
--spin: .65s;         
  --beat-fast: 1.1s;    
  --beat: 1.4s;         
  --beat-slow: 2s;      
--drift-a: 19s;       
  --drift-b: 25s;       
  --drift-c: 31s;       
  --drift-slow: 52s;    
  --drift-tick: 37s;    
--space-0: .125rem;    
  --space-1: .25rem;     
  --space-1-5: .375rem;  
  --space-2: .5rem;      
  --space-3: .75rem;     
  --space-4: 1rem;       
  --space-5: 1.5rem;     
  --space-6: 2rem;       
  --space-6-5: 2.5rem;   
  --space-7: 3rem;       
--text-2xs: .66rem;    
  --text-xs: .74rem;     
  --text-sm: .84rem;     
  --text-md: .92rem;     
  --text-base: 1rem;
  --text-lg: 1.15rem;    
  --text-xl: 1.32rem;    
  --text-2xl: 1.6rem;    
  --text-3xl: 2rem;      
--display-sm: clamp(1.35rem, 1.22rem + .5vw, 1.72rem);    
  --display-md: clamp(1.9rem, 3.2vw, 2.7rem);               
  --display-lg: clamp(3.5rem, 12vw, 5.5rem);                
--sidebar-w: 268px;
  --topbar-h: 62px;
--login-scene: url('../img/kontabiliteti.svg');
--app-scene: url('../img/tavolina.svg');
--grain: url('../img/grain.svg');
--land-shot-1: url('../img/kryefaqja-libri.svg');
  --land-shot-2: url('../img/kryefaqja-analitika.jpg');
  --land-shot-3: url('../img/kryefaqja-dokumentet.jpg');
--tm-accent: #6264a7;
  --tm-accent-soft: rgba(98,100,167,.14);
  --tm-accent-faint: rgba(98,100,167,.06);
  --tm-accent-line: rgba(98,100,167,.30);
--grad-tm-from: #6264a7;
  --grad-tm-to: #6668bb;
  --grad-tm: linear-gradient(135deg, var(--grad-tm-from), var(--grad-tm-to));
  --tm-contrast: #ffffff;
}
@property --grad-angle {
  syntax: '<angle>';
  inherits: false;
  initial-value: 135deg;
}
@property --spot-x {
  syntax: '<length-percentage>';
  inherits: true;
  initial-value: 50%;
}
@property --spot-y {
  syntax: '<length-percentage>';
  inherits: true;
  initial-value: 0%;
}
@property --spot-o {
  syntax: '<number>';
  inherits: true;
  initial-value: 0;
}
@supports (transition-timing-function: linear(0, 1)) {
  :root {
    --ease-spring: linear(
      0, 0.218 5%, 0.68 12%, 0.898 17%, 1.02 22%, 1.075 27%,
      1.073 33%, 1.03 40%, 0.994 50%, 0.986 60%, 1.002 78%, 1
    );
  }
}
}   
@layer base {
body {
font-family: 'Inter Variable', Inter, system-ui, -apple-system, 'Segoe UI',
               Roboto, 'Helvetica Neue', Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
accent-color: var(--primary);
caret-color: var(--primary);
font-optical-sizing: auto;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
background:
    radial-gradient(900px 480px at 8% -10%,
                    color-mix(in srgb, var(--grad-to) 10%, transparent) 0%,
                    color-mix(in srgb, var(--grad-to) 6.2%, transparent) 20%,
                    color-mix(in srgb, var(--grad-to) 3.4%, transparent) 38%,
                    color-mix(in srgb, var(--grad-to) 1.5%, transparent) 55%,
                    color-mix(in srgb, var(--grad-to) 0.5%, transparent) 72%,
                    transparent 90%),
    radial-gradient(760px 420px at 96% -6%,
                    color-mix(in srgb, var(--grad-to) 9%, transparent) 0%,
                    color-mix(in srgb, var(--grad-to) 5.58%, transparent) 20%,
                    color-mix(in srgb, var(--grad-to) 3.06%, transparent) 38%,
                    color-mix(in srgb, var(--grad-to) 1.35%, transparent) 55%,
                    color-mix(in srgb, var(--grad-to) 0.45%, transparent) 72%,
                    transparent 90%),
    radial-gradient(680px 460px at 78% 108%,
                    color-mix(in srgb, var(--grad-to) 8%, transparent) 0%,
                    color-mix(in srgb, var(--grad-to) 4.96%, transparent) 20%,
                    color-mix(in srgb, var(--grad-to) 2.72%, transparent) 38%,
                    color-mix(in srgb, var(--grad-to) 1.2%, transparent) 55%,
                    color-mix(in srgb, var(--grad-to) 0.4%, transparent) 72%,
                    transparent 90%),
    linear-gradient(155deg,
                    color-mix(in srgb, var(--grad-to) 4%, transparent) 0%,
                    color-mix(in srgb, var(--grad-to) 3%, transparent) 46%,
                    transparent 74%),
    linear-gradient(180deg, transparent 38%, var(--ground-shade) 100%);
}
@supports ((-webkit-mask-image: url('')) or (mask-image: url(''))) {
  body::after {
    content: "";
    position: fixed;
inset: 0;
    z-index: -1;
    pointer-events: none;
background:
      radial-gradient(46% 46% at 74% 106%, var(--accent) 0%, transparent 58%),
      radial-gradient(62% 62% at 104% 66%, var(--primary-2) 0%, transparent 60%),
      radial-gradient(86% 86% at 88% 92%, var(--primary) 0%, transparent 66%);
    -webkit-mask: var(--app-scene) center / contain no-repeat;
    mask: var(--app-scene) center / contain no-repeat;
opacity: .22;
animation: sceneDrift var(--drift-slow) var(--ease-in-out) infinite alternate;
  }
}
@keyframes sceneDrift {
  from { transform: translate3d(-.6%, -.4%, 0) scale(1); }
  to   { transform: translate3d(.6%, .4%, 0) scale(1.035); }
}
body:has(.auth-hero)::after { display: none; }
@media (max-width: 900px) {
  body::after { display: none; }
}
@media (prefers-contrast: more) {
  body::after { display: none; }
}
@supports ((-webkit-mask-image: url('')) or (mask-image: url(''))) {
  .app-shell::after {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background: var(--text);
    -webkit-mask: var(--grain) 0 0 / 180px 180px repeat;
    mask: var(--grain) 0 0 / 180px 180px repeat;
    opacity: .014;
  }
body:has(.auth-hero) .app-shell::after { display: none; }
}
@media (forced-colors: active) {
  .app-shell::after { display: none; }
}
@media (prefers-contrast: more) {
  .app-shell::after { display: none; }
}
@supports (font-variation-settings: normal) {
  body { font-feature-settings: 'cv02','cv03','cv04','cv11'; }
}
h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
  font-family: 'Inter Variable', Inter, system-ui, sans-serif;
  letter-spacing: -.02em;
  font-weight: 700;
text-wrap: balance;
}
p, .page-sub, .empty-text, .stat-note, .form-text {
  text-wrap: pretty;
}
::selection { background: var(--primary-soft); color: inherit; }
* { scrollbar-width: thin; scrollbar-color: var(--border-strong) transparent; }
*::-webkit-scrollbar { width: 10px; height: 10px; }
*::-webkit-scrollbar-thumb {
  background: var(--border-strong);
  border-radius: var(--radius-pill);
  border: 3px solid transparent;
  background-clip: padding-box;
}
*::-webkit-scrollbar-track { background: transparent; }
.table td, .table th,
.money, .task-col-count, .badge, .chip,
input[type="number"],
.stat-value {
  font-variant-numeric: tabular-nums;
  font-feature-settings: 'tnum' 1;
}
a:not(.btn) { color: var(--primary-text); text-underline-offset: .18em; }
a:not(.btn):hover { color: var(--primary); }
hr { border-color: var(--border); opacity: 1; }
code, kbd, pre, samp {
  font-family: 'JetBrains Mono Variable', 'JetBrains Mono', ui-monospace,
               SFMono-Regular, Menlo, Consolas, monospace;
}
code { color: var(--primary-text); background: var(--primary-soft);
       padding: var(--space-0) var(--space-1-5); border-radius: var(--radius-xs); font-size: .875em; }
kbd, .kbd {
  display: inline-flex;
  align-items: center;
  gap: var(--space-0);
  background: var(--surface-muted);
  color: var(--muted);
  border: 1px solid var(--border-strong);
  border-bottom-width: 2px;
  border-radius: var(--radius-xs);
  padding: var(--space-0) var(--space-1-5);
  font-size: var(--text-xs);
  font-weight: 600;
  line-height: 1.5;
}
.text-gradient {
  background: var(--grad-primary-text);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: var(--primary-text);
}
.text-muted { color: var(--muted) !important; }
}   
@layer components {
.app-shell { display: flex; min-height: 100vh; }
.app-sidebar {
  width: var(--sidebar-w);
  flex-shrink: 0;
  background: var(--shell);
color: var(--shell-ink);
  border-right: 1px solid var(--shell-line);
}
@media (min-width: 992px) {
  .app-sidebar {
    position: sticky;
    top: 0;
    height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }
}
.app-sidebar.offcanvas, .app-sidebar.offcanvas-lg {
  --bs-offcanvas-width: var(--sidebar-w);
  --bs-offcanvas-bg: var(--shell-strong);
  --bs-offcanvas-color: var(--shell-ink);
}
.sidebar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  padding: var(--space-4);
  min-height: var(--topbar-h);
  border-bottom: 1px solid var(--shell-line);
  flex-shrink: 0;
}
.sidebar-body {
  flex: 1;
  overflow-y: auto;
  padding: var(--space-4) var(--space-3);
  overscroll-behavior: contain;
}
.sidebar-section-title {
  position: sticky;
  top: 0;
  z-index: 2;
  background: var(--shell-solid);
  font-size: var(--text-2xs);
  text-transform: uppercase;
  letter-spacing: .09em;
  color: var(--shell-ink-faint);
  font-weight: 700;
  padding: var(--space-3) var(--space-2) var(--space-1-5);
  user-select: none;
}
.sidebar-body > .sidebar-section-title:first-child,
.sidebar-body > .sidebar-fav .sidebar-section-title,
.sidebar-body > .sidebar-fav.d-none + .sidebar-section-title { padding-top: var(--space-0); }
button.sidebar-section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  background: var(--shell-solid);
  border: 0;
  text-align: left;
  cursor: pointer;
}
button.sidebar-section-title i {
  font-size: var(--text-xs);
  opacity: .55;
  transition: transform var(--dur-2) var(--ease-out);
}
button.sidebar-section-title.collapsed i { transform: rotate(-90deg); }
button.sidebar-section-title:hover { color: var(--shell-ink); }
.app-sidebar .fav-star {
  margin-left: auto;
  background: none;
  border: 0;
  padding: 0 var(--space-0);
  line-height: 1;
  color: var(--shell-ink-faint);
  opacity: 0;
  transition: opacity var(--dur-2) var(--ease-out), color var(--dur-2) var(--ease-out);
}
.app-sidebar .nav-link:hover .fav-star,
.app-sidebar .fav-star:focus-visible { opacity: 1; }
.app-sidebar .fav-star.on { opacity: 1; color: var(--shell-ink); }
.app-sidebar .fav-star:hover { color: var(--shell-ink); }
body.sidebar-mini .app-sidebar .fav-star { display: none; }
@media (hover: none) {
  .app-sidebar .fav-star { display: none; }
}
.app-topbar .icon-btn,
.app-sidebar .icon-btn,
.app-topbar .topbar-search {
  background: var(--shell-well);
  border-color: var(--shell-line);
  color: var(--shell-ink-muted);
}
.app-topbar .icon-btn:hover,
.app-sidebar .icon-btn:hover,
.app-topbar .topbar-search:hover {
  background: var(--shell-well-strong);
  border-color: var(--shell-line);
  color: var(--shell-ink);
}
.app-topbar :is(.btn-outline-primary, .btn-outline-secondary, .btn-outline-success,
                .btn-outline-dark, .btn-outline-light, .btn-link),
.app-sidebar :is(.btn-outline-primary, .btn-outline-secondary, .btn-outline-success,
                 .btn-outline-dark, .btn-outline-light, .btn-link) {
  --bs-btn-color: var(--shell-ink);
  --bs-btn-border-color: var(--shell-line);
  --bs-btn-hover-color: var(--shell);
  --bs-btn-hover-bg: var(--shell-ink);
  --bs-btn-hover-border-color: var(--shell-ink);
  --bs-btn-active-color: var(--shell);
  --bs-btn-active-bg: var(--shell-ink);
  --bs-btn-active-border-color: var(--shell-ink);
  --bs-btn-disabled-color: var(--shell-ink-faint);
  --bs-btn-disabled-border-color: var(--shell-line);
}
.app-topbar .btn-outline-danger,
.app-sidebar .btn-outline-danger {
  --bs-btn-color: var(--shell-danger);
  --bs-btn-border-color: var(--shell-danger);
  --bs-btn-hover-color: var(--shell);
  --bs-btn-hover-bg: var(--shell-danger);
  --bs-btn-hover-border-color: var(--shell-danger);
  --bs-btn-active-color: var(--shell);
  --bs-btn-active-bg: var(--shell-danger);
  --bs-btn-active-border-color: var(--shell-danger);
}
.app-topbar .topbar-search .kbd {
  background: var(--shell-well-strong);
  border-color: var(--shell-line);
  color: var(--shell-ink-muted);
}
.app-sidebar .nav-link {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--space-3);
  color: var(--shell-ink-muted);
  border-radius: var(--radius);
  padding: var(--space-2);
  margin-bottom: var(--space-0);
  font-size: var(--text-sm);
  font-weight: 500;
  transition: color var(--dur-1) var(--ease-out),
              background var(--dur-1) var(--ease-out),
              transform var(--dur-2) var(--ease-spring);
}
.app-sidebar .nav-link i {
  font-size: var(--text-base);
  width: 1.35rem;
  text-align: center;
  color: var(--shell-ink-faint);
  transition: color var(--dur-2) var(--ease-out), transform var(--dur-2) var(--ease-out);
  flex-shrink: 0;
}
@media (hover: hover) {
  .app-sidebar .nav-link:hover {
    color: var(--shell-ink);
    background: var(--shell-hover);
  }
  .app-sidebar .nav-link:hover i { color: var(--shell-ink); transform: translateX(1px); }
.app-sidebar .nav-link:not(.active):hover::before {
    content: "";
    position: absolute;
    left: -.3rem;
    top: 38%;
    bottom: 38%;
    width: 3px;
    border-radius: var(--radius-xs);
    background: var(--shell-ink-faint);
    transform-origin: center;
    animation: railIn var(--dur-2) var(--ease-spring) both;
  }
}
.app-sidebar .nav-link:active {
  color: var(--shell-ink);
  background: var(--shell-hover);
}
.app-sidebar .nav-link.active {
  color: var(--shell-active-ink);
  background: var(--grad-primary);
  font-weight: 600;
}
.app-sidebar .nav-link.active i { color: inherit; }
.app-sidebar .nav-link.active::before {
  content: "";
  position: absolute;
  left: -.3rem;
  top: 22%;
  bottom: 22%;
  width: 3px;
  border-radius: var(--radius-xs);
  background: var(--grad-primary);
transform-origin: center;
  animation: railIn var(--dur-3) var(--ease-spring) both;
}
@keyframes railIn {
  from { transform: scaleY(0); opacity: 0; }
  to   { transform: none; opacity: 1; }
}
.sidebar-badge {
  margin-left: auto;
  background: var(--grad-primary);
  color: #fff;
  font-size: var(--text-2xs);
  font-weight: 700;
  padding: var(--space-0) var(--space-1-5);
  border-radius: var(--radius-pill);
  min-width: 1.25rem;
  text-align: center;
}
.sidebar-foot {
  flex-shrink: 0;
  padding: var(--space-3);
  border-top: 1px solid var(--shell-line);
}
.sidebar-user {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2);
  border-radius: var(--radius);
  text-decoration: none;
  color: inherit;
  transition: background var(--dur-2) var(--ease-out);
}
.sidebar-user:hover { background: var(--shell-hover); color: inherit; }
.sidebar-user-name {
  font-size: var(--text-sm);
  font-weight: 600;
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sidebar-user-role { font-size: var(--text-xs); color: var(--shell-ink-faint); text-transform: capitalize; }
.sidebar-biz { margin-bottom: var(--space-2); }
.sidebar-biz > .btn {
  color: var(--shell-ink-muted);
  border-color: var(--shell-line);
  background: transparent;
}
.sidebar-biz > .btn:hover,
.sidebar-biz > .btn:focus-visible {
  color: var(--shell-ink);
  border-color: var(--shell-ink-faint);
  background: var(--shell-hover);
}
.sidebar-biz-menu { width: min(15rem, calc(100vw - 1.5rem)); }
.sidebar-biz-menu .dropdown-item { white-space: normal; }
body.sidebar-mini .sidebar-biz > .btn span,
body.sidebar-mini .sidebar-biz > .btn::after { display: none; }
.app-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}
.app-topbar {
  position: sticky;
  top: 0;
  z-index: 1030;
  display: flex;
  align-items: center;
  gap: var(--space-3);
  min-height: var(--topbar-h);
  padding: var(--space-2) var(--space-4);
  background: var(--shell);
  border-bottom: 1px solid var(--shell-line);
}
@supports (animation-timeline: scroll()) {
  @media (prefers-reduced-motion: no-preference) {
    .app-topbar {
      animation-name: topbarLift;
      animation-fill-mode: both;
      animation-timing-function: linear;
      animation-timeline: scroll(root block);
      animation-range: 0 96px;
    }
  }
}
@keyframes topbarLift {
  from { box-shadow: 0 0 0 rgba(0,0,0,0); }
  to   { box-shadow: var(--shadow-md); }
}
@supports (animation-timeline: scroll()) {
  @media (prefers-reduced-motion: no-preference) {
    .app-topbar::after {
      content: "";
      position: absolute;
      left: 0;
      right: 0;
      bottom: -1px;
      height: 2px;
      background: var(--grad-primary);
      transform: scaleX(0);
      transform-origin: left center;
      pointer-events: none;
      animation-name: readProgress;
      animation-fill-mode: both;
      animation-timing-function: linear;
      animation-timeline: scroll(root block);
    }
  }
}
@keyframes readProgress {
  from { transform: scaleX(0); }
  to   { transform: scaleX(1); }
}
.app-content {
  flex: 1;
  padding: var(--space-5) var(--space-5) var(--space-6-5);
animation: pageFade var(--dur-3) var(--ease-out) backwards;
}
@keyframes pageFade {
  from { opacity: 0; }
  to   { opacity: 1; }
}
.app-foot {
  margin-top: var(--space-6);
  text-align: center;
  font-size: var(--text-xs);
  letter-spacing: .02em;
  color: var(--ground-ink-muted);
}
.app-foot-mark { color: var(--ground-ink); font-weight: 700; }
.app-content:has(.tm-chat, .tm-shell, .tm-panel) .app-foot { display: none; }
@media (max-width: 576px) {
  .app-content { padding: var(--space-4) var(--space-3) var(--space-6); }
  .app-topbar { padding: var(--space-2) var(--space-3); }
}
@keyframes pageIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: none; }
}
.install-bar { display: none; }
@media (max-width: 991.98px) {
  .install-bar.is-on {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-2) var(--space-3);
    background: var(--primary-soft);
    border-bottom: 1px solid var(--primary-line);
  }
  .install-bar-icon {
    flex: 0 0 auto;
    color: var(--primary-text);
    font-size: var(--text-lg);
  }
.install-bar-text {
    flex: 1 1 auto;
    min-width: 0;
    color: var(--primary-text);
    font-size: var(--text-sm);
    line-height: 1.25;
  }
  .install-bar-go,
  .install-bar-x { flex: 0 0 auto; }
  .install-bar-go { white-space: nowrap; }
  .install-bar-x {
    width: 32px;
    height: 32px;
    background: transparent;
    border-color: transparent;
    color: var(--primary-text);
  }
}
:root { --bottomnav-h: 0px; }
@media (max-width: 991.98px) {
  :root { --bottomnav-h: calc(3.55rem + env(safe-area-inset-bottom)); }
  .app-content { padding-bottom: calc(var(--space-5) + var(--bottomnav-h)); }
}
.bottom-nav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1035;              
  display: flex;
  height: var(--bottomnav-h);
  padding-bottom: env(safe-area-inset-bottom);
  background: var(--shell-strong);
  border-top: 1px solid var(--shell-line);
  box-shadow: var(--shadow-up);
}
.bottom-nav-item {
  position: relative;
  flex: 1 1 0;
  min-width: 0;               
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-1);
  padding: var(--space-1) var(--space-1);
  border: 0;
  background: transparent;
  color: var(--shell-ink-faint);
  text-decoration: none;
  font-weight: 600;
  transition: color var(--dur-2) var(--ease-out);
}
@media (hover: hover) {
  .bottom-nav-item:hover { color: var(--shell-ink); }
}
.bottom-nav-item:focus-visible, .bottom-nav-item:active { color: var(--shell-ink); }
.bottom-nav-icon { position: relative; display: block; font-size: var(--text-lg); line-height: 1; }
.bottom-nav-label {
  font-size: var(--text-2xs);
  letter-spacing: .01em;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.bottom-nav-item.active { color: var(--shell-ink); }
.bottom-nav-item.active::before {
  content: "";
  position: absolute;
  top: 0;
  width: 1.7rem;
  height: 3px;
  border-radius: 0 0 var(--radius-xs) var(--radius-xs);
  background: var(--grad-primary);
}
.bottom-nav-dot {
  position: absolute;
  top: -.35rem;
  left: 60%;
  min-width: 1.05rem;
  padding: var(--space-0) var(--space-1);
  background: var(--grad-primary);
  color: #fff;
  font-size: var(--text-2xs);
  font-weight: 700;
  line-height: 1.3;
  border-radius: var(--radius-pill);
  text-align: center;
  box-shadow: var(--ring-cut);
}
.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  transition: color var(--dur-1) var(--ease-out),
              border-color var(--dur-1) var(--ease-out),
              background var(--dur-1) var(--ease-out),
              transform var(--dur-2) var(--ease-spring),
              box-shadow var(--dur-2) var(--ease-out);
}
.icon-btn:hover {
  color: var(--primary);
  border-color: var(--primary-line);
  background: var(--primary-soft);
  transform: translateY(-1px);
}
.icon-btn:active { transform: none; }
.topbar-back i {
  display: block;
  transition: transform var(--dur-2) var(--ease-spring);
}
.topbar-back:hover i { transform: translateX(-2px); }
.topbar-search {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  width: min(340px, 34vw);
  padding: var(--space-2) var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--faint);
  font-size: var(--text-sm);
  cursor: pointer;
  transition: border-color var(--dur-2) var(--ease-out), box-shadow var(--dur-2) var(--ease-out), color var(--dur-2) var(--ease-out);
}
.topbar-search:hover { border-color: var(--primary-line); color: var(--muted); }
.topbar-search .kbd { margin-left: auto; }
@media (max-width: 575.98px) {
  .topbar-search { width: auto; padding: var(--space-2); }
}
.pub-nav {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  margin-inline-start: var(--space-2);
}
.pub-nav-link {
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-sm);
  border-bottom: 2px solid transparent;
  color: var(--shell-ink-muted);
  font-size: var(--text-sm);
  font-weight: 500;
  text-decoration: none;
  white-space: nowrap;
  transition: color var(--dur-2) var(--ease-out), background-color var(--dur-2) var(--ease-out);
}
.pub-nav-link:hover,
.pub-nav-link:focus-visible {
  color: var(--shell-ink);
  background: var(--shell-hover);
}
.pub-nav-link.active {
  color: var(--shell-ink);
  border-bottom-color: var(--shell-ink);
}
@media (max-width: 767.98px) {
  .app-topbar:has(.pub-nav) { flex-wrap: wrap; row-gap: 0; }
  .pub-nav {
    order: 9;
    flex: 0 0 100%;
    margin-inline-start: calc(var(--space-4) * -1);
    margin-inline-end: calc(var(--space-4) * -1);
    padding-inline: var(--space-4);
    padding-block-start: var(--space-1);
    border-top: 1px solid var(--shell-line);
    overflow-x: auto;
scrollbar-width: none;
  }
  .pub-nav::-webkit-scrollbar { display: none; }
  .pub-nav-link { padding-inline: var(--space-2); }
}
.lang-switch {
  display: inline-flex;
  align-items: center;
  padding: var(--space-0);
  gap: var(--space-0);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-muted);
}
.lang-opt {
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-sm);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: .04em;
  color: var(--faint);
  text-decoration: none;
  transition: background var(--dur-2) var(--ease-out), color var(--dur-2) var(--ease-out);
}
.lang-opt:hover { color: var(--text); }
.lang-opt.active {
  background: var(--surface);
  color: var(--primary-text);
  box-shadow: var(--shadow-sm);
}
.lang-switch-shell {
  background: var(--shell-well);
  border-color: var(--shell-line);
}
.lang-switch-shell .lang-opt { color: var(--shell-ink-muted); }
.lang-switch-shell .lang-opt:hover { color: var(--shell-ink); }
.lang-switch-shell .lang-opt.active {
  background: var(--shell-well-strong);
  color: var(--shell-ink);
  box-shadow: none;
}
.view-menu { min-width: 12.5rem; padding-bottom: var(--space-2); }
.view-menu .dropdown-header {
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--faint);
  padding-bottom: var(--space-0);
}
.view-menu-row { padding: var(--space-1) var(--space-3) var(--space-1); }
.view-opt {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  width: 100%;
  padding: var(--space-2) var(--space-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-muted);
  color: var(--text);
  font-size: var(--text-sm);
  font-weight: 600;
  text-align: left;
  transition: background var(--dur-2) var(--ease-out), border-color var(--dur-2) var(--ease-out), color var(--dur-2) var(--ease-out);
}
.view-opt:hover {
  background: var(--surface-hover);
  border-color: var(--primary);
  color: var(--primary-text);
}
.view-opt i { font-size: var(--text-base); color: var(--faint); }
.view-opt:hover i { color: var(--primary); }
.view-menu .lang-switch { display: flex; width: 100%; }
.view-menu .lang-opt { flex: 1; text-align: center; padding: var(--space-1) var(--space-2); }
.worklist { display: flex; flex-direction: column; }
.worklist-row {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  color: var(--text);
  text-decoration: none;
  border-top: 1px solid var(--border);
  transition: background var(--dur-2) var(--ease-out);
}
.worklist-row:first-child { border-top: 0; }
.worklist-row:hover { background: var(--surface-hover); }
.worklist-icon {
  display: grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  border-radius: var(--radius-sm);
  font-size: var(--text-md);
}
.worklist-count {
  font-family: 'Sora Variable', 'Inter Variable', Inter, sans-serif;
  font-size: var(--text-lg);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  min-width: 2ch;
}
.worklist-text { color: var(--muted); font-size: var(--text-sm); }
.worklist-go { margin-left: auto; color: var(--faint); font-size: var(--text-sm); }
.worklist-danger .worklist-icon { background: var(--danger-soft); color: var(--danger); }
.worklist-danger .worklist-count { color: var(--danger); }
.worklist-warning .worklist-icon { background: var(--warning-soft); color: var(--warning); }
.worklist-warning .worklist-count { color: var(--warning); }
.worklist-info .worklist-icon { background: var(--info-soft); color: var(--info); }
.wq { display: flex; flex-direction: column; }
.wq-row {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-2) var(--space-4);
  color: var(--text);
  text-decoration: none;
  border-top: 1px solid var(--border);
  border-left: 3px solid transparent;
  transition: background var(--dur-2) var(--ease-out);
}
.wq-row:first-child { border-top: 0; }
.wq-row:hover { background: var(--surface-hover); }
.wq-when {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 3.4rem;
  font-variant-numeric: tabular-nums;
}
.wq-date { font-weight: 700; font-size: var(--text-md); }
.wq-time { font-size: var(--text-2xs); color: var(--muted); }
.wq-main { flex: 1; min-width: 0; }
.wq-title {
  display: block;
  font-weight: 600;
  font-size: var(--text-sm);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.wq-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-1) var(--space-2);
  margin-top: var(--space-0);
  font-size: var(--text-2xs);
  color: var(--muted);
}
.wq-tag {
  flex-shrink: 0;
  font-size: var(--text-2xs);
  font-weight: 600;
  color: var(--muted);
  text-align: right;
}
.wq-late { border-left-color: var(--danger); }
.wq-late .wq-date, .wq-late .wq-tag { color: var(--danger); }
.wq-today { border-left-color: var(--warning); }
.wq-today .wq-tag { color: var(--warning); }
.wq-sub {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--faint);
  text-transform: uppercase;
  letter-spacing: .04em;
}
.wq-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(7rem, 1fr));
  gap: var(--space-3);
  text-align: center;
}
.wq-stat-value {
  font-family: 'Sora Variable', 'Inter Variable', Inter, sans-serif;
  font-size: var(--text-xl);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
}
.wq-stat-label { font-size: var(--text-2xs); color: var(--muted); margin-top: var(--space-0); }
.table-responsive.table-sticky { max-height: min(70vh, 720px, var(--tbl-fit, 100vh)); overflow: auto; }
.table-responsive.table-sticky { scrollbar-width: auto; scrollbar-color: var(--border-strong) var(--surface-muted); }
.table-responsive.table-sticky::-webkit-scrollbar { width: .75rem; height: .75rem; }
.table-responsive.table-sticky::-webkit-scrollbar-track { background: var(--surface-muted); }
.table-responsive.table-sticky::-webkit-scrollbar-thumb { border-width: 2px; }
.table-sticky thead th {
  position: sticky;
  top: 0;
  z-index: 3;
  background: var(--surface);
  box-shadow: inset 0 -1px 0 var(--border-strong);
}
.table-sticky tbody th:first-child,
.table-sticky td.sticky-col,
.table-sticky th.sticky-col {
  position: sticky;
  left: 0;
  z-index: 2;
  background: var(--surface);
}
.table-sticky thead th.sticky-col { z-index: 4; }
.table-responsive .dropdown-menu { z-index: 1040; }
body.density-compact .table > :not(caption) > * > * { padding-top: var(--space-1); padding-bottom: var(--space-1); }
body.density-compact .card-body { padding: var(--space-3) var(--space-4); }
body.density-compact .stat-card { padding: var(--space-3); }
.cpc-logo {
  width: 100%;
  height: 100%;
  display: block;
}
.navbar-brand, .brand {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  text-decoration: none;
  font-weight: 700;
  letter-spacing: .04em;
}
.brand-mark-lg {
  display: inline-flex;
  width: 36px;
  height: 36px;
  border-radius: var(--radius);
  box-shadow: var(--shadow-glow);
}
.brand-word {
  font-family: 'Sora Variable', 'Inter Variable', Inter, sans-serif;
  font-weight: 700;
  font-size: var(--text-base);
letter-spacing: .04em;
  white-space: nowrap;
color: var(--shell-ink);
}
.navbar { position: relative; z-index: 2000; backdrop-filter: blur(14px);
          border-bottom: 1px solid var(--border); }
.navbar, .sidebar { background: var(--shell); color: var(--shell-ink); }
.navbar .dropdown-menu { position: absolute !important; z-index: 3000 !important; }
.sidebar { min-height: 100vh; border-right: 1px solid var(--border); }
.sidebar .nav-link.active { color: var(--primary-text); background: var(--primary-soft); font-weight: 600; }
.main-panel { padding-top: var(--space-4); }
.btn {
  border-radius: var(--radius-sm);
  font-weight: 500;
transition: background var(--dur-1) var(--ease-out),
              border-color var(--dur-1) var(--ease-out),
              color var(--dur-1) var(--ease-out),
              box-shadow var(--dur-2) var(--ease-out),
              transform var(--dur-2) var(--ease-spring),
              filter var(--dur-1) var(--ease-out),
              --grad-angle var(--dur-3) var(--ease-out);
}
.btn:active { transform: translateY(1px); }
.btn.is-busy, .icon-btn.is-busy {
  pointer-events: none;    
  opacity: .78;
}
.is-busy::before {
  content: "";
  display: inline-block;
  width: 1em;
  height: 1em;
  vertical-align: -.125em;
  margin-inline-end: .45em;
  border: 2px solid currentColor;
  border-inline-end-color: transparent;
  border-radius: var(--radius-round);
  animation: ka-spin var(--spin) linear infinite;
}
.is-busy-bare::before { margin-inline-end: 0; }
.is-busy > i.bi, .is-busy > svg { display: none; }
@keyframes ka-spin { to { transform: rotate(360deg); } }
.btn-primary {
background: linear-gradient(var(--grad-angle), var(--grad-from), var(--grad-to));
  border: 0;
  color: #fff;
  box-shadow: var(--shadow-glow);
  padding-top: calc(var(--space-1-5) + 1px);
  padding-bottom: calc(var(--space-1-5) + 1px);
}
.btn-primary:hover, .btn-primary:focus {
  --grad-from: var(--grad-from-hover);
  --grad-to: var(--grad-to-hover);
  --grad-angle: 100deg;
  color: #fff;
  transform: translateY(-1px);
  box-shadow: var(--shadow-glow-strong);
}
.btn-primary:active { transform: none; }
.btn-primary.btn-sm { padding-top: calc(var(--space-1) + 1px); padding-bottom: calc(var(--space-1) + 1px); }
.btn-outline-primary {
  --bs-btn-color: var(--primary-text);
  --bs-btn-border-color: var(--primary-line);
  --bs-btn-hover-color: var(--primary-contrast);
  --bs-btn-hover-bg: var(--primary);
  --bs-btn-hover-border-color: var(--primary);
  --bs-btn-active-color: var(--primary-contrast);
  --bs-btn-active-bg: var(--primary);
  --bs-btn-active-border-color: var(--primary);
  --bs-btn-disabled-color: var(--faint);
  --bs-btn-disabled-border-color: var(--border);
}
.btn-secondary {
  background: var(--surface-muted);
  color: var(--text);
  border-color: var(--border-strong);
}
.btn-secondary:hover { background: var(--surface-hover); color: var(--text); border-color: var(--border-strong); }
.btn-outline-secondary {
  --bs-btn-color: var(--text);
  --bs-btn-border-color: var(--border-strong);
  --bs-btn-hover-color: var(--text);
  --bs-btn-hover-bg: var(--surface-hover);
  --bs-btn-hover-border-color: var(--border-strong);
  --bs-btn-active-color: var(--text);
  --bs-btn-active-bg: var(--surface-muted);
  --bs-btn-active-border-color: var(--border-strong);
  --bs-btn-disabled-color: var(--faint);
  --bs-btn-disabled-border-color: var(--border);
}
.btn-outline-success {
  --bs-btn-color: var(--success);
  --bs-btn-border-color: var(--success);
  --bs-btn-hover-color: var(--success);
  --bs-btn-hover-bg: var(--success-soft);
  --bs-btn-hover-border-color: var(--success);
  --bs-btn-active-color: var(--success);
  --bs-btn-active-bg: var(--success-soft);
  --bs-btn-active-border-color: var(--success);
}
.btn-outline-danger {
  --bs-btn-color: var(--danger);
  --bs-btn-border-color: var(--danger);
  --bs-btn-hover-color: var(--danger);
  --bs-btn-hover-bg: var(--danger-soft);
  --bs-btn-hover-border-color: var(--danger);
  --bs-btn-active-color: var(--danger);
  --bs-btn-active-bg: var(--danger-soft);
  --bs-btn-active-border-color: var(--danger);
}
.form-control, .form-select {
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-strong);
  color: var(--text);
background-color: var(--surface-muted);
  transition: border-color var(--dur-2) var(--ease-out), box-shadow var(--dur-2) var(--ease-out), background-color var(--dur-2) var(--ease-out);
}
.form-control::placeholder { color: var(--faint); }
.form-control:focus, .form-select:focus {
  background-color: var(--surface);
  border-color: var(--primary);
  box-shadow: var(--ring);
  color: var(--text);
}
.form-control:user-invalid, .form-select:user-invalid {
  border-color: var(--danger);
}
.form-control:user-invalid:focus, .form-select:user-invalid:focus {
  box-shadow: 0 0 0 var(--ring-w-lg) color-mix(in srgb, var(--danger) 28%, transparent);
}
.card:has(.form-control:user-invalid, .form-select:user-invalid) {
  border-color: color-mix(in srgb, var(--danger) 45%, var(--border));
}
@supports (field-sizing: content) and (height: 1lh) {
  textarea.form-control {
    field-sizing: content;
max-height: 40vh;
  }
  textarea.form-control[rows="1"] { min-height: calc(1lh + .75rem + 2px); }
  textarea.form-control[rows="2"] { min-height: calc(2lh + .75rem + 2px); }
  textarea.form-control[rows="3"] { min-height: calc(3lh + .75rem + 2px); }
  textarea.form-control[rows="4"] { min-height: calc(4lh + .75rem + 2px); }
  textarea.form-control[rows="5"] { min-height: calc(5lh + .75rem + 2px); }
  textarea.form-control[rows="6"] { min-height: calc(6lh + .75rem + 2px); }
}
.form-label { font-weight: 500; font-size: var(--text-sm); color: var(--muted); }
.form-text { color: var(--faint); }
.form-check-input[type="checkbox"] { border-radius: var(--radius-xs); }
.form-switch .form-check-input { border-radius: var(--radius-pill); }
.btn-close { border-radius: var(--radius-sm); }
.input-group-text {
  background: var(--surface-muted);
  border-color: var(--border-strong);
  color: var(--muted);
}
.dropdown-menu {
  background-color: var(--surface-raised);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: var(--space-1-5);
}
.dropdown-item {
  color: var(--text);
  border-radius: var(--radius-sm);
  padding: var(--space-2) var(--space-3);
  font-size: var(--text-sm);
}
.dropdown-item:hover, .dropdown-item:focus {
  background-color: var(--surface-hover);
  color: var(--text);
}
.dropdown-divider { border-color: var(--border); }
.dropdown-header { color: var(--faint); font-size: var(--text-xs); text-transform: uppercase; letter-spacing: .07em; }
.modal-content {
  background-color: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}
.modal-header, .modal-footer { border-color: var(--border); }
.modal-backdrop { --bs-backdrop-opacity: .6; }
.offcanvas { background-color: var(--surface); color: var(--text); border-color: var(--border); }
.list-group-item { background-color: transparent; color: var(--text); border-color: var(--border); }
.list-group-item-action:hover, .list-group-item-action:focus {
  background-color: var(--surface-hover);
  color: var(--text);
}
.toast {
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(10px);
}
.toast.text-bg-primary {
  background: var(--grad-primary) !important;
  border: 0;
}
.toast.text-bg-success, .toast.text-bg-danger, .toast.text-bg-warning { border: 0; }
.ka-toast-secret {
  background: var(--surface);
  color: var(--text);
  box-shadow: inset 0 0 0 var(--hairline) var(--border-strong), var(--shadow-lg);
}
.ka-toast-secret .ka-toast-icon { color: var(--primary); opacity: 1; }
.toast-stack {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 1090;              
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  padding: var(--space-4);
  max-width: min(26rem, calc(100vw - 2rem));
  pointer-events: none;       
}
.toast-stack > * { pointer-events: auto; }
@media (max-width: 576px) {
  .toast-stack {
    top: auto;
bottom: var(--bottomnav-h);
    left: 0;
    right: 0;
    max-width: none;
    padding: var(--space-3);
    flex-direction: column-reverse;    
  }
}
.ka-toast-icon {
  flex: 0 0 auto;
  font-size: var(--text-lg);
  line-height: 1.35;
  opacity: .92;
}
.ka-toast .toast-body { line-height: 1.35; }
.toast-undo {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-0) var(--space-2);
  font-size: var(--text-xs);
  font-weight: 600;
  white-space: nowrap;
}
.toast-link {
  color: #fff;
  text-decoration: underline;
  font-size: var(--text-xs);
  font-weight: 600;
}
.toast-link:hover, .toast-link:focus-visible { color: #fff; }
.badge { font-weight: 600; letter-spacing: .01em; border-radius: var(--radius-sm); }
.badge.bg-primary, .badge.text-bg-primary { background: var(--grad-primary) !important; color: #fff !important; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-0) var(--space-2);
  border-radius: var(--radius-pill);
  font-size: var(--text-xs);
  font-weight: 600;
  line-height: 1.4;
  background: var(--surface-muted);
  color: var(--muted);
  border: 1px solid var(--border);
  white-space: nowrap;
}
.chip i { font-size: .8em; }
.chip-primary { background: var(--primary-soft); color: var(--primary-text); border-color: var(--primary-line); }
.chip-success { background: var(--success-soft); color: var(--success); border-color: transparent; }
.chip-warning { background: var(--warning-soft); color: var(--warning); border-color: transparent; }
.chip-danger  { background: var(--danger-soft);  color: var(--danger);  border-color: transparent; }
.chip-info    { background: var(--info-soft);    color: var(--info);    border-color: transparent; }
.pulse-dot {
  display: inline-block;
  width: .55rem;
  height: .55rem;
  border-radius: var(--radius-round);
  background: var(--success);
  box-shadow: 0 0 0 0 color-mix(in srgb, var(--live) 50%, transparent);
  animation: pulseDot var(--beat-slow) var(--ease-in-out) infinite;
}
@keyframes pulseDot {
  0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--live) 45%, transparent); }
  70% { box-shadow: 0 0 0 .45rem transparent; }
  100% { box-shadow: 0 0 0 0 transparent; }
}
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
box-shadow: var(--edge-light-soft), var(--shadow-sm);
  color: var(--text);
}
.card-header {
  background: transparent;
  border-bottom: 1px solid var(--border);
  font-weight: 600;
  letter-spacing: -.01em;
  font-size: var(--text-md);
  color: var(--text);
}
.card-footer { background: transparent; border-top: 1px solid var(--border); }
.card-lift {
  transition: transform var(--dur-2) var(--ease-spring),
              box-shadow var(--dur-2) var(--ease-out),
              border-color var(--dur-2) var(--ease-out);
}
.card-lift:hover {
  transform: translateY(-2px);
  box-shadow: var(--edge-light), var(--shadow-md);
  border-color: var(--primary-line);
}
.glass-card {
  background: var(--glass);
  backdrop-filter: blur(var(--glass-blur)) saturate(1.2);
  -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(1.2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--edge-light), var(--shadow-md);
}
.page-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-3) var(--space-4);
  margin-bottom: var(--space-4);
}
.page-head-main { min-width: 0; }
.page-eyebrow {
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--ground-accent);
  margin-bottom: var(--space-1);
}
.page-head { color: var(--ground-ink); }
.page-title {
  font-size: var(--display-sm);
  font-weight: 700;
  letter-spacing: -.02em;
  margin-bottom: var(--space-0);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.page-title .page-title-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  border-radius: var(--radius);
  background: var(--ground-wash);
  color: var(--ground-ink);
  font-size: var(--text-lg);
  box-shadow: inset 0 0 0 var(--hairline) var(--ground-line);
}
.page-sub { color: var(--ground-ink-muted); font-size: var(--text-md); margin-bottom: 0; }
.page-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-2);
  position: relative;
  z-index: 5;
}
.dash-grid {
column-width: min(26rem, 100%);
  column-gap: var(--space-4);
}
.dash-grid > * {
  break-inside: avoid;
  margin-bottom: var(--space-4);
}
.dash-grid .stat-grid { margin-bottom: var(--space-4); }
.dash-wide { column-span: all; }
.dash-people {
  display: grid;
  gap: var(--space-3);
  align-content: start;
}
@media (max-width: 575.98px) {
  .dash-people { grid-template-columns: 1fr; }
  .dash-people > .stat-grid { display: contents; }
  .dash-people > .stat-grid > .stat-card:nth-child(1) { order: 1; }
  .dash-people > .collapse:nth-child(2)               { order: 2; }
  .dash-people > .stat-grid > .stat-card:nth-child(2) { order: 3; }
  .dash-people > .collapse:nth-child(3)               { order: 4; }
  .dash-people > .stat-grid > .stat-card:nth-child(3) { order: 5; }
  .dash-people > .collapse:nth-child(4)               { order: 6; }
}
.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(13.5rem, 1fr));
  gap: var(--space-3);
  margin-bottom: var(--space-5);
}
.stat-card {
  position: relative;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-4);
  box-shadow: var(--edge-light-soft), var(--shadow-sm);
  transition: transform var(--dur-2) var(--ease-spring),
              box-shadow var(--dur-2) var(--ease-out),
              border-color var(--dur-2) var(--ease-out);
container-type: inline-size;
  container-name: stat;
isolation: isolate;
}
.stat-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--edge-light), var(--shadow-md);
  border-color: var(--primary-line);
}
.stat-card::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--grad-primary);
  pointer-events: none;
  z-index: -1;
}
@media (hover: hover) {
  .stat-card::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    border-radius: inherit;
    pointer-events: none;
    opacity: var(--spot-o);
    transition: opacity var(--dur-3) var(--ease-out);
    background: radial-gradient(circle 16rem at var(--spot-x) var(--spot-y),
                color-mix(in srgb, var(--primary) 16%, transparent), transparent 70%);
  }
}
.stat-card.stat-success::after {
  background: linear-gradient(90deg, var(--success-fill-strong), var(--success-fill));
}
.stat-card.stat-warning::after {
  background: linear-gradient(90deg, var(--warning-fill-strong), var(--warning-fill));
}
.stat-card.stat-danger::after {
  background: linear-gradient(90deg, var(--danger-fill-strong), var(--danger-fill));
}
.stat-card.stat-accent::after {
  background: linear-gradient(90deg, var(--accent-fill-strong), var(--accent-fill));
}
.stat-top { display: flex; align-items: center; justify-content: space-between; gap: var(--space-2); }
.stat-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: var(--radius);
  background: var(--primary-soft);
  color: var(--primary);
  font-size: var(--text-lg);
  box-shadow: inset 0 0 0 var(--hairline) var(--primary-line);
  flex-shrink: 0;
}
.stat-card.stat-success .stat-icon {
  background: var(--success-soft);
  color: var(--success);
  box-shadow: inset 0 0 0 var(--hairline) color-mix(in srgb, var(--success) 24%, transparent);
}
.stat-card.stat-warning .stat-icon {
  background: var(--warning-soft);
  color: var(--warning);
  box-shadow: inset 0 0 0 var(--hairline) color-mix(in srgb, var(--warning) 24%, transparent);
}
.stat-card.stat-danger .stat-icon {
  background: var(--danger-soft);
  color: var(--danger);
  box-shadow: inset 0 0 0 var(--hairline) color-mix(in srgb, var(--danger) 24%, transparent);
}
.stat-card.stat-accent .stat-icon {
  background: var(--accent-soft);
  color: var(--accent);
  box-shadow: inset 0 0 0 var(--hairline) color-mix(in srgb, var(--accent) 24%, transparent);
}
.stat-card-filter { cursor: pointer; user-select: none; }
.stat-card-filter:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.stat-card-filter.is-active {
  border-color: var(--primary);
  box-shadow: inset 0 0 0 var(--ring-w) var(--primary), var(--shadow-md);
}
tr.u-filter-hidden { display: none !important; }
.stat-label {
  font-size: var(--text-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .07em;
  color: var(--muted);
  margin-bottom: var(--space-0);
}
.stat-value {
  font-family: 'Sora Variable', 'Inter Variable', Inter, sans-serif;
  font-size: var(--text-2xl);
  font-weight: 700;
  letter-spacing: -.02em;
  line-height: 1.15;
}
@container stat (max-width: 13rem) {
  .stat-icon { width: 34px; height: 34px; border-radius: var(--radius); font-size: var(--text-md); }
  .stat-value { font-size: var(--text-xl); }
  .stat-label { font-size: var(--text-2xs); letter-spacing: .05em; }
}
.stat-note { font-size: var(--text-xs); color: var(--faint); margin-top: var(--space-0); }
.stat-carry {
  margin-top: var(--space-2);
  padding-top: var(--space-2);
  border-top: 1px solid var(--border);
  font-size: var(--text-xs);
  color: var(--muted);
}
.stat-carry-line {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--space-2);
}
.stat-carry-due {
  margin-top: var(--space-0);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--text);
}
.stat-value .stat-unit {
  font-size: .62em;
  font-weight: 600;
  color: var(--muted);
  margin-left: .18em;
  letter-spacing: 0;
  font-variant-numeric: normal;
}
.stat-go {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  width: 100%;
  margin-top: var(--space-3);
  padding: var(--space-2) 0 0;
  border: 0;
  border-top: 1px solid var(--border);
  background: none;
  font: inherit;
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--muted);
  text-align: left;
  cursor: pointer;
  transition: color var(--dur-2) var(--ease-out);
}
.stat-go .stat-go-icon { font-size: 1.05em; transition: transform var(--dur-2) var(--ease-spring); }
.stat-go:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}
.stat-card:hover .stat-go,
.stat-card:focus-visible .stat-go,
.stat-go:hover,
.stat-go:focus-visible { color: var(--primary); }
.stat-card:hover .stat-go .stat-go-icon { transform: translateX(3px); }
.stat-go[aria-expanded] .stat-go-icon { transform: none; }
.stat-card:hover .stat-go[aria-expanded] .stat-go-icon { transform: none; }
.stat-go[aria-expanded="true"] { color: var(--primary); }
.stat-go[aria-expanded="true"] .stat-go-icon,
.stat-card:hover .stat-go[aria-expanded="true"] .stat-go-icon { transform: rotate(180deg); }
.stat-delta { font-size: var(--text-xs); font-weight: 700; display: inline-flex; align-items: center; gap: var(--space-1); }
.stat-delta.up { color: var(--success); }
.stat-delta.down { color: var(--danger); }
.stat-spark { display: block; width: 100%; height: 34px; margin-top: var(--space-2); }
.stat-spark polyline { fill: none; stroke: var(--primary); stroke-width: 2; }
.stat-spark .spark-fill { fill: var(--primary-soft); stroke: none; }
.invoice-calc {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: var(--space-2) var(--space-4);
  padding: var(--space-3) var(--space-4);
  border: 1px dashed var(--primary-line);
  border-radius: var(--radius-lg);
  background: var(--primary-soft);
}
.invoice-calc .calc-item { display: flex; flex-direction: column; gap: var(--space-0); min-width: 6.5rem; }
.invoice-calc .calc-label {
  font-size: var(--text-xs); font-weight: 600; text-transform: uppercase;
  letter-spacing: .06em; color: var(--muted);
}
.invoice-calc .calc-num {
  font-family: 'Sora Variable', 'Inter Variable', Inter, sans-serif;
  font-size: var(--text-lg); font-weight: 700; letter-spacing: -.01em;
}
.invoice-calc .calc-op { display: flex; align-items: center; font-size: var(--text-lg); font-weight: 700; color: var(--muted); }
.invoice-calc .calc-total .calc-num { color: var(--primary); }
.collapse-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.collapse-card:focus-visible { outline: none; box-shadow: var(--ring); }
.action-card { background: var(--surface); border: 1px solid var(--primary-line); }
.action-card .list-group-item {
  border-radius: var(--radius);
  margin-bottom: var(--space-2);
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}
.action-card .list-group-item:last-child { margin-bottom: 0; }
.action-card .list-group-item-action { transition: background var(--dur-2) var(--ease-out), color var(--dur-2) var(--ease-out), transform var(--dur-2) var(--ease-out); }
.action-card .list-group-item-action:hover {
  background: var(--primary-soft);
  color: var(--text);
  transform: translateX(2px);
}
.table { color: var(--text); --bs-table-bg: transparent; --bs-table-color: var(--text); }
.table > :not(caption) > * > * {
  background-color: transparent;
  border-bottom-color: var(--border);
  color: inherit;
}
.table thead th {
  color: var(--muted);
  font-weight: 600;
  font-size: var(--text-xs);
  letter-spacing: .05em;
  text-transform: uppercase;
  border-bottom: 1px solid var(--border-strong);
  white-space: nowrap;
}
.table-sm th, .table-sm td { padding: var(--space-3); }
.table-hover tbody tr { transition: background var(--dur-1) var(--ease-out); }
.table-hover tbody tr:hover > * { background-color: var(--surface-hover); }
.table-striped > tbody > tr:nth-of-type(odd) > * {
  --bs-table-accent-bg: var(--surface-muted);
  color: inherit;
}
.table-light th, .table-light td, thead.table-light tr {
  background-color: var(--surface-muted);
  color: var(--text) !important;
}
.table-bordered th, .table-bordered td { border-color: var(--border); }
.table > tbody > tr.table-warning > * { background-color: var(--warning-soft); color: var(--text); }
.table > tbody > tr.table-success > * { background-color: var(--success-soft); color: var(--text); }
.table > tbody > tr.table-danger  > * { background-color: var(--danger-soft);  color: var(--text); }
.table > tbody > tr:has(> td:first-child input[type="checkbox"]:checked) > * {
  background-color: var(--primary-soft);
}
.table-card { overflow: hidden; }
.table-card .table { margin-bottom: 0; }
.table-card .table > :not(caption) > * > *:first-child { padding-left: var(--space-4); }
.table-card .table > :not(caption) > * > *:last-child { padding-right: var(--space-4); }
.table-card-narrow { max-width: 76rem; }
.table-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-3);
}
.toolbar-filters,
.toolbar-filters > form,
.part-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
}
.toolbar-filters .form-select { width: auto; }
.toolbar-filters .btn-group { flex-wrap: wrap; row-gap: var(--space-1); }
.toolbar-filters .btn-group > .btn { flex: 0 0 auto; white-space: nowrap; }
@media screen and (max-width: 767.98px) {
  .dek-raporti .sticky-col { min-width: 10rem; }
  .dek-raporti .sticky-col::before {
    content: "";
    position: absolute;
    inset-block: 0;
    inset-inline-end: 0;
    width: 1px;
    background: var(--border);
  }
  .dek-raporti > thead > tr > th { white-space: normal; }
.stat-grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--space-2);
  }
  .stat-grid-3 .stat-card { padding: var(--space-3); }
  .stat-grid-3 .stat-icon { display: none; }
}
@media screen and (max-width: 767.98px) {
  .table-cards > thead { display: none; }
  .table-cards, .table-cards > tbody, .table-cards > tbody > tr,
  .table-cards > tbody > tr > td, .table-cards > tbody > tr > th { display: block; }
  .table-cards { width: 100%; }
.table-cards > tbody > tr {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    padding: var(--space-1) 0;
    margin-bottom: var(--space-2);
  }
.table-cards > tbody > tr.table-warning { border-left: 3px solid var(--warning); }
  .table-cards > tbody > tr.table-success { border-left: 3px solid var(--success); }
  .table-cards > tbody > tr.table-danger  { border-left: 3px solid var(--danger); }
  .table-cards > tbody > tr.table-warning > *,
  .table-cards > tbody > tr.table-success > *,
  .table-cards > tbody > tr.table-danger > *,
  .table-striped.table-cards > tbody > tr:nth-of-type(odd) > * {
    background-color: transparent;
  }
.table-cards > tbody > tr > td {
    display: grid;
    grid-template-columns: minmax(5.5rem, 34%) 1fr;
    gap: var(--space-3);
    align-items: baseline;
    border: 0;
    padding: var(--space-1) var(--space-3);
    white-space: normal;
  }
  .table-cards > tbody > tr > td::before {
    content: attr(data-label);
    color: var(--faint);
    font-size: var(--text-2xs);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .05em;
    line-height: 1.5;
  }
.table-cards > tbody > tr > td:not([data-label]) {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-2);
    padding: var(--space-2) var(--space-3);
  }
.table-cards > tbody > tr > td:first-child {
    display: block;
    font-weight: 600;
    font-size: var(--text-base);
    padding: var(--space-2) var(--space-3) var(--space-1);
  }
  .table-cards > tbody > tr > td:first-child::before { content: none; }
  .table-cards > tbody > tr > td:last-child { padding-bottom: var(--space-2); }
.table-cards > tbody > tr:has(> td:first-child input[type="checkbox"]) {
    position: relative;
  }
  .table-cards > tbody > tr > td:first-child:has(input[type="checkbox"]) {
    position: absolute;
    inset-block-start: var(--space-2);
    inset-inline-end: var(--space-3);
    width: auto;
    padding: 0;
  }
.table-cards > tbody > tr > td:first-child:has(input[type="checkbox"]) + td {
    display: block;
    font-weight: 600;
    font-size: var(--text-base);
    padding: var(--space-2) calc(var(--space-3) + 1.75rem) var(--space-1) var(--space-3);
  }
  .table-cards > tbody > tr > td:first-child:has(input[type="checkbox"]) + td::before {
    content: none;
  }
.table-cards > tbody > tr:has(> td[colspan]) {
    background: none;
    border: 0;
    box-shadow: none;
    padding: 0;
  }
  .table-cards > tbody > tr > td[colspan] { display: block; text-align: center; }
  .table-cards > tbody > tr > td[colspan]::before { content: none; }
.table-responsive:has(> .table-cards) { overflow: visible; }
  .table-responsive.table-sticky:has(> .table-cards) { max-height: none; overflow: visible; }
  .table-cards > tbody > tr > td.sticky-col,
  .table-cards > tbody > tr > th.sticky-col { position: static; }
.table-card .table-cards > :not(caption) > * > *:first-child { padding-left: var(--space-3); }
  .table-card .table-cards > :not(caption) > * > *:last-child { padding-right: var(--space-3); }
}
.empty-state {
  text-align: center;
  padding: var(--space-6-5) var(--space-4);
  color: var(--muted);
}
.empty-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 62px;
  height: 62px;
  border-radius: var(--radius-lg);
  background: var(--primary-soft);
  color: var(--primary);
  font-size: var(--text-2xl);
  margin-bottom: var(--space-3);
  box-shadow: inset 0 0 0 var(--hairline) var(--primary-line);
}
.empty-title { font-weight: 600; color: var(--text); margin-bottom: var(--space-0); }
.empty-text { font-size: var(--text-sm); margin-bottom: var(--space-3); }
.empty-action {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-2);
  margin-top: var(--space-1);
}
.timeline { position: relative; padding-left: var(--space-5); }
.timeline::before {
  content: "";
  position: absolute;
  left: .35rem;
  top: .4rem;
  bottom: .4rem;
  width: 2px;
  border-radius: var(--radius-xs);
  background: linear-gradient(to bottom, var(--primary-line), transparent);
}
.timeline-item { position: relative; padding: var(--space-1-5) 0 var(--space-2); }
.timeline-item::before {
  content: "";
  position: absolute;
  left: -1.35rem;
  top: .62rem;
  width: .6rem;
  height: .6rem;
  border-radius: var(--radius-round);
  background: var(--surface);
  border: 2px solid var(--primary);
}
.timeline-time { font-size: var(--text-xs); color: var(--faint); }
.avatar { width: 42px; height: 42px; border-radius: var(--radius-round); }
.avatar-initial {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius);
  background: var(--grad-primary);
  color: #fff;
  font-weight: 700;
  font-size: var(--text-md);
  flex-shrink: 0;
}
.avatar-xs {
  width: 1.35rem;
  height: 1.35rem;
  border-radius: var(--radius-sm);
  font-size: var(--text-2xs);
}
.avatar-large {
  width: 72px;
  height: 72px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-lg);
  font-size: var(--text-2xl);
  font-weight: 700;
}
.bg-primary-soft { background: var(--primary-soft); }
.bg-warning-soft { background: var(--warning-soft); }
.debt-paid { color: var(--success) !important; font-weight: 600; }
.debt-unpaid { color: var(--danger) !important; font-weight: 600; }
.file-input-hidden { display: none; }
.skeleton {
  position: relative;
  overflow: hidden;
  background: var(--surface-muted);
  border-radius: var(--radius-sm);
  min-height: 1em;
}
.skeleton::after {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(-100%);
  background: linear-gradient(90deg, transparent, var(--surface-hover), transparent);
  animation: shimmer var(--beat) linear infinite;
}
@keyframes shimmer { to { transform: translateX(100%); } }
.auth-wrap {
  min-height: calc(100vh - var(--topbar-h) - 4rem);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-5) 0;
}
.auth-card {
  width: 100%;
  max-width: 960px;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  border-radius: var(--radius-xl);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
}
.auth-visual {
  position: relative;
  padding: var(--space-6-5);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: var(--space-4);
  color: #fff;
  background:
radial-gradient(120% 90% at 85% 10%, rgba(34,211,238,.22), transparent 55%),
    linear-gradient(140deg, #24457f 0%, #1a2a33 55%, #2c509b 100%);
  overflow: hidden;
}
.auth-visual::after {
content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.06) 1px, transparent 1px);
  background-size: 34px 34px;
  mask-image: radial-gradient(90% 80% at 50% 40%, #000 30%, transparent 100%);
  -webkit-mask-image: radial-gradient(90% 80% at 50% 40%, #000 30%, transparent 100%);
  pointer-events: none;
}
.auth-visual > * { position: relative; z-index: 1; }
.auth-visual h2 { color: #fff; }
.auth-visual p { color: rgba(255,255,255,.92); }
.auth-feature {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-size: var(--text-md);
  color: rgba(255,255,255,.96);
}
.auth-feature i {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  background: rgba(255,255,255,.14);
  flex-shrink: 0;
}
.auth-form { padding: var(--space-6-5); }
.auth-form-head { margin-bottom: var(--space-5); }
.auth-input {
  display: grid;
  transition: transform var(--dur-2) var(--ease-out);
}
.auth-input > .form-control,
.auth-input > .pw-wrap { grid-area: 1 / 1; }
.auth-input > .caps-hint { grid-area: 2 / 1; }
.auth-input > .bi {
  grid-area: 1 / 1;
  align-self: center;
  justify-self: start;
z-index: 1;
  pointer-events: none;
  margin-inline-start: var(--space-4);
  font-size: var(--text-lg);
  line-height: 1;
  color: var(--faint);
  transition: color var(--dur-1) var(--ease-out);
}
.auth-input .form-control {
  padding-inline-start: 2.75rem;
  border-radius: var(--radius);
}
.auth-field .form-label {
  font-weight: 600;
  transition: color var(--dur-1) var(--ease-out);
}
.auth-field:focus-within .form-label,
.auth-field:focus-within .auth-input > .bi { color: var(--primary-text); }
.auth-field:focus-within .auth-input { transform: translateY(-1px); }
.auth-submit {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
}
.auth-submit > .bi { transition: transform var(--dur-2) var(--ease-out); }
.auth-submit:hover > .bi { transform: translateX(3px); }
.auth-submit::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(100deg, transparent 38%, rgba(255,255,255,.28) 50%,
                              transparent 62%);
  transform: translateX(-110%);
  transition: transform var(--dur-3) var(--ease-out);
}
.auth-submit:hover::after,
.auth-submit:focus-visible::after { transform: translateX(110%); }
@media (max-width: 900px) {
  .auth-card { grid-template-columns: 1fr; max-width: 460px; }
  .auth-visual { display: none; }
  .auth-form { padding: var(--space-6) var(--space-5); }
}
.pw-lock {
  position: fixed;
  inset: 0;
  z-index: 1060;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-5) var(--space-4);
  overflow: auto;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
}
body:has(.pw-lock) .app-sidebar,
body:has(.pw-lock) .app-topbar,
body:has(.pw-lock) .bottom-nav { display: none; }
.pw-lock-box {
  width: 100%;
  max-width: 28rem;
  padding: var(--space-6-5);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  animation: pageIn var(--dur-3) var(--ease-out) both;
}
.pw-lock-head {
  display: flex;
  gap: var(--space-3);
  margin-bottom: var(--space-5);
}
.pw-lock-icon {
  flex: none;
  width: 2.75rem;
  height: 2.75rem;
  display: grid;
  place-items: center;
  border-radius: var(--radius);
  font-size: var(--text-xl);
  color: var(--primary-text);
  background: var(--primary-soft);
}
.pw-lock-title {
  margin: 0;
  font-size: var(--text-xl);
  font-weight: 700;
}
.pw-lock-sub {
  margin: var(--space-1) 0 0;
  color: var(--muted);
  font-size: var(--text-sm);
}
.pw-lock-foot {
  margin: var(--space-4) 0 0;
  color: var(--faint);
  font-size: var(--text-xs);
  text-align: center;
}
@media (max-width: 576px) {
  .pw-lock { padding: var(--space-3); align-items: flex-start; }
  .pw-lock-box { padding: var(--space-5); }
}
.btn-outline-dark,
.btn-outline-light {
  --bs-btn-color: var(--text);
  --bs-btn-border-color: var(--border-strong);
  --bs-btn-hover-color: var(--primary-contrast);
  --bs-btn-hover-bg: var(--text);
  --bs-btn-hover-border-color: var(--text);
  --bs-btn-active-color: var(--primary-contrast);
  --bs-btn-active-bg: var(--text);
  --bs-btn-active-border-color: var(--text);
  --bs-btn-disabled-color: var(--faint);
  --bs-btn-disabled-border-color: var(--border);
}
.last-io-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  border-radius: var(--radius);
  font-size: var(--text-lg);
color: #fff;
  background: var(--grad-primary);
}
.last-io-icon.in { background: linear-gradient(135deg, #047857, var(--success-fill-strong)); }
.last-io-time {
  font-family: 'Sora Variable', 'Inter Variable', Inter, sans-serif;
  font-weight: 800;
  font-size: var(--text-2xl);
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
  color: var(--text);
}
.io-line {
  display: flex;
  align-items: center;
  gap: var(--space-1-5);
  font-variant-numeric: tabular-nums;
}
.io-line + .io-line { margin-top: var(--space-0); }
.io-line .io-in { color: var(--bs-success, var(--success-fill-strong)); }
.io-line .io-out { color: var(--muted, #6b7280); }
.io-line .io-check { color: var(--muted); }
.io-check-row > td { opacity: .72; }
.io-check-row > td:first-child { box-shadow: inset var(--rail) 0 0 var(--border); }
.io-line .io-now { color: var(--success); }
.last-io-icon.now { background: linear-gradient(135deg, var(--primary), #24363f); }
.io-applied {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-1-5);
  min-height: 2rem;
}
.io-applied-label {
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--muted);
}
.io-chip-clear { text-decoration: none; gap: var(--space-1); }
.io-chip-clear .bi-x-lg { font-size: var(--text-2xs); opacity: .7; }
.io-chip-clear:hover .bi-x-lg { opacity: 1; }
.io-inside { display: flex; flex-wrap: wrap; gap: var(--space-1); margin-top: var(--space-1); }
.io-inside .chip { text-decoration: none; }
.io-inside-since { font-variant-numeric: tabular-nums; opacity: .75; }
.io-chart {
  display: flex;
  align-items: flex-end;
  gap: var(--space-0);
  height: 96px;
}
.io-chart-col {
  flex: 1 1 0;
  min-width: 0;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  border-radius: var(--radius-xs);
  transition: background var(--dur-2) var(--ease-out);
}
.io-chart-col:hover { background: var(--surface-muted); }
.io-chart-bar { display: block; width: 100%; border-radius: var(--radius-xs); }
.io-chart-bar.has { min-height: 3px; }
.io-bar-ok { background: var(--grad-primary); }
.io-bar-bad {
  background: linear-gradient(180deg, var(--danger-fill), var(--danger-fill-strong));
  border-radius: var(--radius-xs) var(--radius-xs) 0 0;
}
.io-chart-axis {
  display: flex;
  justify-content: space-between;
  gap: var(--space-2);
  margin-top: var(--space-2);
  font-size: var(--text-xs);
  color: var(--faint);
}
.io-legend { display: inline-flex; align-items: center; gap: var(--space-3); font-size: var(--text-xs); color: var(--muted); }
.io-legend-item { display: inline-flex; align-items: center; gap: var(--space-1); font-weight: 600; }
.io-dot { width: .6rem; height: .6rem; border-radius: var(--radius-xs); display: inline-block; }
.io-dot-ok { background: var(--grad-primary); }
.io-dot-bad { background: linear-gradient(180deg, var(--danger-fill), var(--danger-fill-strong)); }
.io-signal-quiet {
  margin: var(--space-3) 0 0;
  font-size: var(--text-sm);
  color: var(--success);
  font-weight: 600;
}
.io-evidence-more {
  margin: var(--space-1-5) 0 0;
  font-size: var(--text-xs);
  color: var(--faint);
}
.io-heat-wrap { overflow-x: auto; padding-bottom: var(--space-1); }
.io-heat {
  display: grid;
  grid-template-columns: max-content repeat(24, minmax(13px, 1fr));
  gap: var(--space-0);
  align-items: center;
min-width: 34rem;
}
.io-heat-hour {
  font-size: var(--text-2xs);
  color: var(--faint);
  font-variant-numeric: tabular-nums;
  line-height: 1;
  text-align: center;
}
.io-heat-day {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--muted);
  padding-right: var(--space-2);
  text-align: right;
  white-space: nowrap;
}
.io-heat-cell {
  position: relative;
  height: 15px;
  border-radius: var(--radius-xs);
  background: var(--surface-muted);
  overflow: hidden;
}
.io-heat-cell::after {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--grad-primary);
  opacity: var(--io-heat, 0);
}
.io-heat-cell.is-sour::after {
  background: linear-gradient(180deg, var(--danger-fill), var(--danger-fill-strong));
}
.io-heat-scale { display: inline-flex; align-items: center; gap: var(--space-0); }
.io-legend .io-heat-cell { width: 12px; height: 12px; --io-heat: .8; }
.io-profile {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: var(--space-4);
  align-items: start;
}
.io-profile .list-kv + .list-kv { border-top: 1px solid var(--border); }
.io-profile-title {
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--muted);
  margin-bottom: var(--space-1-5);
}
.io-hours {
  display: flex;
  align-items: flex-end;
  gap: var(--space-0);
  height: 54px;
}
.io-hours-col {
  flex: 1 1 0;
  min-width: 0;
  height: 100%;
  display: flex;
  align-items: flex-end;
  border-radius: var(--radius-xs);
  transition: background var(--dur-2) var(--ease-out);
}
.io-hours-col:hover { background: var(--surface-muted); }
.io-hours-bar {
  display: block;
  width: 100%;
  border-radius: var(--radius-xs);
  background: var(--grad-primary);
}
.io-hours-col.is-peak .io-hours-bar {
  background: linear-gradient(180deg, var(--warning-fill), var(--warning-fill-strong));
}
.stat-delta.flat { color: var(--muted); font-weight: 600; }
a.stat-card { color: inherit; text-decoration: none; display: block; }
a.stat-card:hover { border-color: var(--primary-line); box-shadow: var(--shadow-md); }
.acc-confirm {
  position: sticky;
  top: calc(var(--topbar-h) + .5rem);
  z-index: 15;
  border-color: var(--primary-line);
  box-shadow: var(--shadow-md);
}
.acc-card .acc-matrix th { font-size: var(--text-xs); color: var(--muted); font-weight: 600; }
.acc-card .acc-matrix td { padding-top: var(--space-1-5); padding-bottom: var(--space-1-5); }
.acc-na { color: var(--faint); user-select: none; }
.acc-sub-title {
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .07em;
  color: var(--faint);
  margin-bottom: var(--space-2);
}
.acc-days, .acc-pages { display: flex; flex-wrap: wrap; gap: var(--space-1); }
.acc-day, .acc-page { margin: 0; cursor: pointer; }
.acc-day input, .acc-page input { position: absolute; opacity: 0; width: 0; height: 0; }
.acc-day span, .acc-page span {
  display: inline-block;
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-pill);
  font-size: var(--text-xs);
  border: 1px solid var(--border-strong);
  color: var(--muted);
  transition: background var(--dur-2) var(--ease-out), color var(--dur-2) var(--ease-out), border-color var(--dur-2) var(--ease-out);
}
.acc-day input:checked + span,
.acc-page input:checked + span {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--primary-contrast);
}
.acc-day input:focus-visible + span,
.acc-page input:focus-visible + span { box-shadow: var(--ring); }
.acc-clients {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(13rem, 1fr));
  gap: var(--space-1) var(--space-3);
  max-height: 11rem;
  overflow-y: auto;
  padding: var(--space-1-5) var(--space-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-muted);
}
.acc-client {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin: 0;
  font-size: var(--text-sm);
  cursor: pointer;
}
.acc-client small { display: block; font-size: var(--text-xs); }
.acc-headcheck {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1-5);
  margin: 0;
  cursor: pointer;
}
.acc-headcheck-col { flex-direction: column; gap: var(--space-0); }
.acc-headcheck .form-check-input { margin: 0; float: none; flex-shrink: 0; }
.acc-card.acc-dirty {
  border-color: var(--warning);
  box-shadow: 0 0 0 var(--hairline) var(--warning), var(--shadow-md);
}
.acc-card.acc-dirty > .card-header { background: var(--warning-soft); }
.acc-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-3);
  padding-bottom: var(--space-3);
  margin-bottom: var(--space-1);
  border-bottom: 1px solid var(--border);
}
.acc-bar-find {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  flex: 1 1 14rem;
  max-width: 22rem;
  color: var(--muted);
}
.acc-bar-chips { display: flex; align-items: center; flex-wrap: wrap; gap: var(--space-1-5); }
.acc-find .acc-bar { padding-bottom: 0; margin-bottom: 0; border-bottom: 0; }
@media (max-width: 767.98px) {
  .acc-confirm { position: static; }
}
.chip-button {
  cursor: pointer;
  font: inherit;
  font-size: var(--text-xs);
  transition: background var(--dur-2) var(--ease-out), color var(--dur-2) var(--ease-out);
}
.chip-button[aria-pressed="true"] { box-shadow: var(--ring); }
.acc-save-count {
  display: inline-block;
  min-width: 1.25rem;
  padding: 0 var(--space-1-5);
  margin-left: var(--space-1-5);
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, .25);
  font-size: var(--text-xs);
  font-weight: 700;
}
.acc-plan > summary {
  cursor: pointer;
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--warning);
}
.acc-plan-body {
  margin-top: var(--space-2);
  max-height: 16rem;
  overflow-y: auto;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(16rem, 1fr));
  gap: var(--space-2);
}
.acc-plan-worker {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: var(--space-1-5) var(--space-2);
  background: var(--surface-muted);
}
.acc-plan-name {
  display: block;
  font-weight: 600;
  font-size: var(--text-sm);
  text-decoration: none;
  margin-bottom: var(--space-1);
}
.acc-diff { display: grid; gap: var(--space-0); }
.acc-diff-line {
  font-size: var(--text-xs);
  padding-left: var(--space-4);
  position: relative;
  line-height: 1.5;
}
.acc-diff-line::before { position: absolute; left: 0; font-weight: 700; }
.acc-diff-up { color: var(--success); }
.acc-diff-up::before { content: '+'; }
.acc-diff-down { color: var(--danger); }
.acc-diff-down::before { content: '−'; }
.acc-diff-flat { color: var(--muted); }
.acc-diff-flat::before { content: '~'; }
.acc-overview .acc-ov-name { font-weight: 600; text-decoration: none; }
.acc-overview .acc-ov-sub { font-size: var(--text-2xs); }
.acc-ov-row.acc-dirty > td { background: var(--warning-soft); }
.acc-ov-row[data-tone="warning"] > td:first-child {
  box-shadow: inset var(--rail) 0 0 var(--warning);
}
.acc-hint {
  font-size: var(--text-2xs);
  color: var(--faint);
  max-width: 22rem;
  margin-top: var(--space-0);
  font-weight: 400;
}
.acc-client-tools {
  display: flex;
  align-items: center;
  gap: var(--space-1-5);
  margin-bottom: var(--space-1-5);
}
.acc-client-tools input { max-width: 14rem; }
.acc-picker-head { position: relative; }
.acc-picker-toggle {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  width: 100%;
  padding: var(--space-1-5) var(--space-3);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font-size: var(--text-sm);
  text-align: left;
  cursor: pointer;
  list-style: none;                     
  transition: border-color var(--dur-2) var(--ease-out), box-shadow var(--dur-2) var(--ease-out);
}
.acc-picker-toggle::-webkit-details-marker { display: none; }
.acc-picker-toggle:hover { border-color: var(--primary); }
.acc-picker-toggle:focus-visible { outline: none; box-shadow: var(--ring); }
.acc-picker-head[open] > .acc-picker-toggle { border-color: var(--primary); box-shadow: var(--ring); }
.acc-picker-text { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.acc-picker-caret { color: var(--muted); transition: transform var(--dur-2) var(--ease-out); }
.acc-picker-head[open] .acc-picker-caret { transform: rotate(180deg); }
.acc-picker-menu {
  position: absolute;
  z-index: 30;
  top: calc(100% + .3rem);
  left: 0;
  right: 0;
  padding: var(--space-2);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
}
.acc-picker-menu .acc-clients {
  grid-template-columns: 1fr;
  max-height: 14rem;
  padding: var(--space-0);
  border: 0;
  background: transparent;
}
.acc-picker-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  margin-top: var(--space-1-5);
  padding-top: var(--space-1-5);
  border-top: 1px solid var(--border);
}
.acc-picker-acts {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.acc-picker-sep {
  width: 1px;
  height: .85em;
  background: var(--border-strong);
}
.acc-chosen {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1);
  margin-top: var(--space-2);
  max-height: 8rem;
  overflow-y: auto;
}
.acc-chosen-chip {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-0) var(--space-2);
  border-radius: var(--radius-pill);
  border: 1px solid var(--border-strong);
  background: var(--surface-muted);
  color: var(--text);
  font-size: var(--text-xs);
  cursor: pointer;
  transition: border-color var(--dur-2) var(--ease-out), color var(--dur-2) var(--ease-out);
}
.acc-chosen-chip:hover { border-color: var(--danger); color: var(--danger); }
.acc-chosen-chip:focus-visible { outline: none; box-shadow: var(--ring); }
.acc-chosen-chip i { font-size: .9em; opacity: .7; }
.acc-fold {
  border: 0;
  background: none;
  color: var(--muted);
  padding: 0 var(--space-1-5) 0 0;
  line-height: 1;
}
.acc-fold i { transition: transform var(--dur-2) var(--ease-out); display: inline-block; }
.acc-card.acc-folded .acc-body { display: none; }
.acc-card.acc-folded .acc-fold i { transform: rotate(-90deg); }
.acc-card.acc-folded > .card-footer { display: none; }
.acc-trail > summary { cursor: pointer; color: var(--muted); }
.acc-trail-list { list-style: none; padding-left: 0; margin: var(--space-1-5) 0 0; }
.acc-trail-list > li { padding: var(--space-0) 0; border-top: 1px dashed var(--border); }
.acc-trail-lines { color: var(--muted); font-size: var(--text-2xs); }
.export-sections {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-4);
  padding: var(--space-1-5) var(--space-3);
  border-radius: var(--radius);
  background: var(--surface-muted);
  border: 1px solid var(--border);
}
.export-sections-label {
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .07em;
  color: var(--faint);
}
.export-chk {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1-5);
  font-size: var(--text-sm);
  color: var(--text);
  cursor: pointer;
  margin: 0;
}
.export-chk i { color: var(--muted); margin-right: var(--space-1); }
.export-chk input:checked ~ span i { color: var(--primary-text); }
.drill-month {
  color: var(--primary-text);
  text-decoration: none;
  font-weight: 600;
}
.drill-month:hover { text-decoration: underline; }
.drill-month i { font-size: .7em; opacity: .6; }
.drill-bar {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-lg);
  border: 1px solid var(--primary-line);
  background: var(--primary-soft);
}
.drill-bar-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
  color: var(--primary-contrast);
  background: var(--primary);
}
.drill-bar-main { display: flex; flex-direction: column; line-height: 1.35; }
.drill-bar-main span { font-size: var(--text-sm); }
.drill-bar .btn { margin-left: auto; }
.margin-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(4.2rem, 1fr));
  gap: var(--space-1-5);
  margin-top: var(--space-3);
  padding-top: var(--space-3);
  border-top: 1px solid var(--border);
}
.margin-cell {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-0);
  text-align: center;
}
.margin-month { font-size: var(--text-xs); color: var(--faint); }
.margin-pct {
  font-size: var(--text-sm);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  display: inline-flex;
  align-items: center;
  gap: var(--space-0);
}
.margin-pct i { font-size: .7em; }
.margin-pct.pos  { color: var(--success); }
.margin-pct.neg  { color: var(--danger); }
.margin-pct.none { color: var(--faint); font-weight: 500; }
@media print {
  body.hide-print-financat  [data-bipage="financat"],
  body.hide-print-klientet  [data-bipage="klientet"],
  body.hide-print-arketimet [data-bipage="arketimet"],
  body.hide-print-tvsh      [data-bipage="tvsh"],
  body.hide-print-puna      [data-bipage="puna"] { display: none !important; }
}
.bi-card.is-offpage { display: none; }
@media print {
  .bi-card.is-offpage { display: block; }
}
:root { --chart-bar: #2c509b; }
.chase-hero,
.tt-hero {
  font-family: 'Sora Variable', 'Inter Variable', Inter, sans-serif;
  font-weight: 800;
  font-size: var(--text-3xl);
  line-height: 1;
  letter-spacing: -.02em;
  color: var(--text);           
}
.chase-bar {
  display: flex;
  gap: var(--space-0);
  height: 10px;
  margin: var(--space-3) 0;
  border-radius: var(--radius-pill);
  overflow: hidden;
  background: var(--surface-sunken);
}
.chase-bar > span { display: block; min-width: 3px; }
.chase-bar .is-sent    { background: var(--success); }
.chase-bar .is-late    { background: var(--danger); }
.chase-bar .is-chase   { background: var(--warning); }
.chase-bar .is-waiting { background: var(--border-strong); }
.chase-key {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1-5) var(--space-4);
  font-size: var(--text-sm);
  color: var(--muted);
}
.chase-key span { display: inline-flex; align-items: center; gap: var(--space-1); }
.chase-key i { font-size: var(--text-sm); color: var(--success); }
.chase-key .is-late i    { color: var(--danger); }
.chase-key .is-chase i   { color: var(--warning); }
.chase-key .is-waiting i { color: var(--faint); }
.spark {
  display: block;
  height: 2.1rem;
  margin: var(--space-1-5) 0 var(--space-2);
}
.spark svg {
  width: 100%;
  height: 100%;
  display: block;
  overflow: visible;       
}
.spark-line {
  fill: none;
  stroke: var(--primary);
  stroke-width: 1.75;
  stroke-linejoin: round;
  stroke-linecap: round;
}
.spark-area { fill: var(--primary); opacity: .12; stroke: none; }
.spark-dot {
  stroke: var(--primary);
  stroke-width: 4.5;
  stroke-linecap: round;
}
.spark-success .spark-line, .spark-success .spark-dot { stroke: var(--success-fill); }
.spark-success .spark-area { fill: var(--success-fill); }
.spark-accent .spark-line, .spark-accent .spark-dot { stroke: var(--accent, var(--primary-2)); }
.spark-accent .spark-area { fill: var(--accent, var(--primary-2)); }
.age-strip {
  display: flex;
  gap: var(--space-0);
  height: 8px;
  margin: var(--space-2) 0 var(--space-1-5);
  border-radius: var(--radius-pill);
  overflow: hidden;
  background: var(--surface-sunken);
}
.age-strip > span { display: block; min-width: 3px; }
.age-key {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1) var(--space-2);
  font-size: var(--text-xs);
  color: var(--muted);
  margin-bottom: var(--space-2);
}
.age-key-item { display: inline-flex; align-items: center; gap: var(--space-1); }
.age-key-item b { font-variant-numeric: tabular-nums; color: var(--text); font-weight: 600; }
.age-dot {
  width: .5rem;
  height: .5rem;
  border-radius: var(--radius-xs);
  display: inline-block;
}
.age-1 { background: var(--success-fill); }
.age-2 { background: var(--primary); }
.age-3 { background: var(--warning-fill); }
.age-4 { background: var(--danger-fill); }
.panel-off { display: none !important; }
.panel-prefs-menu { min-width: 15rem; }
.panel-prefs-item {
  display: flex;
  align-items: center;
  cursor: pointer;
  font-size: var(--text-sm);
}
.panel-prefs-item:active { color: inherit; }
.panel-prefs-count {
  display: inline-block;
  margin-left: var(--space-1-5);
  padding: 0 var(--space-1-5);
  border-radius: var(--radius-pill);
  background: var(--primary-soft);
  color: var(--primary-text);
  font-size: var(--text-xs);
  font-weight: 700;
}
.tt-total { display: flex; align-items: baseline; gap: var(--space-2); }
.tt-chart { display: flex; flex-direction: column; gap: var(--space-2); }
.tt-row,
.tt-head {
  display: grid;
grid-template-columns: minmax(5.5rem, 8rem) 1fr 2.4rem 3.4rem;
  align-items: center;
  gap: var(--space-2);
}
.tt-head > .tt-value,
.tt-head > .tt-open {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--faint);
}
.tt-name {
  font-size: var(--text-sm);
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.tt-track {
  position: relative;
  height: 10px;                 
  border-radius: var(--radius-pill);
  background: var(--surface-sunken);
  overflow: hidden;
}
.tt-fill {
  display: block;
  height: 100%;
  min-width: 2px;               
  background: var(--chart-bar);
border-radius: 0 var(--radius-xs) var(--radius-xs) 0;
  transition: width var(--dur-3) var(--ease-out);
}
.tt-value {
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  font-size: var(--text-sm);
  text-align: right;
  color: var(--text);
}
.tt-open {
  font-variant-numeric: tabular-nums;
  font-size: var(--text-xs);
  text-align: right;
  color: var(--muted);
}
@media (max-width: 480px) {
  .tt-row,
  .tt-head { grid-template-columns: minmax(4.5rem, 6rem) 1fr 2rem 2.8rem; }
}
.error-code {
  font-family: 'Sora Variable', 'Inter Variable', Inter, sans-serif;
  font-weight: 800;
  font-size: var(--display-lg);
  line-height: 1;
  letter-spacing: -.04em;
  background: var(--grad-primary-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
input[type="password"]::-ms-reveal,
input[type="password"]::-ms-clear { display: none; width: 0; height: 0; }
.app-content:has(.auth-hero) {
  background:
    radial-gradient(118% 86% at 50% 44%, transparent 26%, rgba(4,6,22,.52) 100%),
    linear-gradient(180deg, rgba(4,6,22,.52) 0%, rgba(4,6,22,.14) 22%,
                    rgba(4,6,22,.12) 58%, rgba(4,6,22,.44) 100%),
    var(--login-scene) center / cover no-repeat,
    #0b0d26;
  box-shadow: inset 0 16px 30px -16px rgba(2,3,12,.9);
}
.auth-card-hero {
  max-width: 1120px;
  grid-template-columns: 1.18fr 1fr;
  box-shadow: 0 46px 92px -30px rgba(2,3,12,.82), 0 10px 28px -14px rgba(2,3,12,.6);
position: relative;
}
@supports ((-webkit-mask-composite: xor) or (mask-composite: exclude)) {
  .auth-card-hero::after {
    content: "";
    position: absolute;
    inset: 0;
z-index: 2;
    border-radius: inherit;
    padding: var(--hairline);
    pointer-events: none;
    background: conic-gradient(from var(--sheen, 200deg),
                transparent 0deg,
                color-mix(in srgb, var(--primary) 62%, transparent) 46deg,
                color-mix(in srgb, var(--accent-fill) 58%, transparent) 92deg,
                transparent 170deg,
                transparent 360deg);
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    mask-composite: exclude;
  }
}
.auth-card-hero .auth-form {
  background-image: radial-gradient(120% 84% at 100% 0%, var(--primary-soft), transparent 62%);
  box-shadow: inset 16px 0 30px -30px color-mix(in srgb, var(--primary) 62%, transparent);
}
.auth-hero {
  padding: var(--space-6-5);
  gap: var(--space-4);
  justify-content: space-between;
background:
    radial-gradient(120% 90% at 82% -5%, rgba(210,171,103,.15), transparent 55%),
    linear-gradient(155deg, rgba(36,69,127,.62) 0%, rgba(44,80,155,.50) 38%,
                    rgba(40,69,96,.44) 72%, rgba(36,54,63,.46) 100%),
linear-gradient(180deg, rgba(6,8,28,.70) 0%, rgba(6,8,28,.62) 22%,
                    rgba(6,8,28,.36) 60%, rgba(6,8,28,.44) 100%),
    var(--login-scene) 62% center / cover no-repeat,
    #241f5e;
}
.hero-guilloche {
  position: absolute;
  top: 50%;
  right: -34%;
  width: 108%;
  aspect-ratio: 1;
  transform: translateY(-50%);
  z-index: 0;                
  background: url('../img/guilloche.svg') center / contain no-repeat;
  opacity: .08;
  pointer-events: none;
  -webkit-mask-image: radial-gradient(64% 64% at 88% 34%, black 24%, transparent 76%);
  mask-image: radial-gradient(64% 64% at 88% 34%, black 24%, transparent 76%);
}
@media (forced-colors: active) {
  .hero-guilloche { display: none; }
.auth-hero { background-image: none; }
  .app-content:has(.auth-hero) { background: none; box-shadow: none; }
.auth-card-hero::after,
  .auth-submit::after { display: none; }
  .auth-card-hero .auth-form { background-image: none; box-shadow: none; }
}
.hero-aurora {
  position: absolute;
  inset: -25%;
  z-index: 0;                
  filter: blur(52px);
opacity: .55;
  pointer-events: none;
}
.hero-aurora span {
  position: absolute;
  display: block;
  border-radius: var(--radius-round);
  mix-blend-mode: screen;
  will-change: transform;
}
.hero-blob-1 {
  width: 58%; height: 58%; left: -8%; top: 4%;
  background: radial-gradient(circle, rgba(34,211,238,.80), transparent 66%);
  animation: heroDrift var(--drift-a) var(--ease-in-out) infinite;
}
.hero-blob-2 {
  width: 52%; height: 52%; right: -10%; top: 22%;
  background: radial-gradient(circle, rgba(168,85,247,.85), transparent 66%);
  animation: heroDrift var(--drift-b) var(--ease-in-out) infinite reverse;
}
.hero-blob-3 {
  width: 46%; height: 46%; left: 26%; bottom: -12%;
  background: radial-gradient(circle, rgba(56,189,248,.55), transparent 68%);
  animation: heroDrift var(--drift-c) var(--ease-in-out) infinite;
}
@keyframes heroDrift {
  0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
  33%      { transform: translate3d(12%, -8%, 0) scale(1.12); }
  66%      { transform: translate3d(-9%, 9%, 0) scale(.92); }
}
@media (hover: hover) {
  .hero-aurora {
    transform: translate3d(var(--sway-x, 0px), var(--sway-y, 0px), 0);
    transition: transform var(--dur-3) var(--ease-out);
  }
}
.hero-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  flex-wrap: wrap;
}
.hero-brand { display: flex; align-items: center; gap: var(--space-3); }
.auth-visual-brand { display: flex; align-items: center; gap: var(--space-3); margin-bottom: var(--space-1); }
.auth-visual-brand h2 { font-family: 'Sora Variable', 'Inter Variable', Inter, sans-serif; }
.hero-mark, .auth-visual-mark {
  display: inline-flex;
  width: 46px;
  height: 46px;
  border-radius: var(--radius);
  box-shadow: 0 0 0 var(--hairline) rgba(255,255,255,.22), 0 10px 24px rgba(9,10,40,.34);
}
.auth-visual-mark { width: 54px; height: 54px; border-radius: var(--radius-lg); flex-shrink: 0; }
.hero-word {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
  color: #fff;
}
.hero-word strong { font-weight: 800; letter-spacing: .16em; font-size: var(--text-md); }
.hero-word small { color: rgba(255,255,255,.74); font-size: var(--text-xs); letter-spacing: .04em; }
.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-pill);
  font-size: var(--text-xs);
  font-weight: 600;
  color: rgba(255,255,255,.92);
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.22);
  white-space: nowrap;
}
.hero-dot {
  width: 7px;
  height: 7px;
  border-radius: var(--radius-round);
  background: #34d399;
  box-shadow: 0 0 0 0 color-mix(in srgb, var(--live) 70%, transparent);
  animation: heroPulse var(--beat-slow) var(--ease-out) infinite;
}
@keyframes heroPulse {
  0%   { box-shadow: 0 0 0 0 color-mix(in srgb, var(--live) 65%, transparent); }
  70%  { box-shadow: 0 0 0 7px transparent; }
  100% { box-shadow: 0 0 0 0 transparent; }
}
.hero-say { max-width: 22ch; }
.hero-say .hero-greet {
  margin: 0;
  font-size: var(--display-md);
  font-weight: 800;
  line-height: 1.04;
  letter-spacing: -.02em;
  color: #fff;
  text-wrap: balance;
}
.hero-say .hero-date {
  margin: var(--space-1-5) 0 0;
  font-size: var(--text-md);
  font-weight: 500;
  color: rgba(255,255,255,.88);
  font-variant-numeric: tabular-nums;
}
@media (max-width: 900px) {
.auth-card-hero { max-width: 460px; grid-template-columns: 1fr; box-shadow: var(--shadow-lg); }
  .auth-hero {
    display: flex;
    padding: var(--space-5);
    gap: var(--space-3);
  }
.hero-guilloche { display: none; }
.hero-greet { display: none; }
  .hero-say { max-width: none; }
  .hero-say .hero-date { font-size: var(--text-sm); }
.auth-card-hero .auth-form { box-shadow: none; }
.app-content:has(.auth-hero) { background: none; box-shadow: none; }
}
@media (max-width: 576px) {
.auth-wrap { min-height: auto; padding: 0; display: block; }
  .auth-card-hero, .auth-card {
    max-width: none;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    background: transparent;
width: auto;
    margin-inline: calc(var(--space-3) * -1);
  }
.auth-card-hero::after { display: none; }
.app-content > .auth-wrap:first-child .auth-card { margin-top: calc(var(--space-4) * -1); }
.auth-wrap { margin-bottom: calc(var(--space-6) * -1); }
.auth-hero { padding: var(--space-4); gap: var(--space-1-5); border-radius: 0; }
  .hero-word small { display: block; }
.hero-aurora { filter: blur(38px); }
.auth-form { padding: var(--space-5) var(--space-4) var(--space-4); }
  .auth-form-head { margin-bottom: var(--space-4); }
.auth-form-head h3 { font-size: var(--text-xl); }
  .auth-form-mark, .auth-form-sub { display: none; }
  .auth-form hr { margin: var(--space-3) 0; }
.auth-form a.small {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: 0 var(--space-2);
  }
}
.login-page { min-height: calc(100vh - 200px); }
.login-visual {
  background:
    radial-gradient(120% 90% at 85% 10%, rgba(34,211,238,.35), transparent 55%),
    linear-gradient(140deg, #24457f, #1a2a33);
  border-top-left-radius: 1.5rem;
  border-bottom-left-radius: 1.5rem;
}
.login-visual h2, .login-visual p, .login-visual .badge { color: #fff; }
.login-card { border-radius: var(--radius-xl); overflow: hidden; background: var(--surface) !important; }
.hero-section {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--border);
  background:
    radial-gradient(90% 120% at 90% -10%, rgba(44,80,155,.14), transparent 60%),
    radial-gradient(80% 100% at 0% 110%, rgba(210,171,103,.12), transparent 55%),
    var(--surface);
}
.cmdk-backdrop {
  position: fixed;
  inset: 0;
  z-index: 4000;
  display: none;
  align-items: flex-start;
  justify-content: center;
  padding: 12vh var(--space-4) var(--space-4);
  background: rgba(5,8,18,.45);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
.cmdk-backdrop.open { display: flex; }
.cmdk {
  width: 100%;
max-width: 620px;
  background: var(--surface-raised);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  animation: cmdkIn var(--dur-2) var(--ease-out) both;
}
@keyframes cmdkIn {
  from { opacity: 0; transform: translateY(-8px) scale(.985); }
  to   { opacity: 1; transform: none; }
}
.cmdk-input-row {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--border);
  color: var(--muted);
}
.cmdk-input {
  flex: 1;
  border: 0;
  outline: none;
  background: transparent;
  color: var(--text);
  font-size: var(--text-base);
}
.cmdk-input::placeholder { color: var(--faint); }
.cmdk-spinner { display: none; }
.cmdk-backdrop.is-searching .cmdk-glass { display: none; }
.cmdk-backdrop.is-searching .cmdk-spinner {
  display: inline-block;
  width: 1rem;
  height: 1rem;
  border: 2px solid var(--primary-line);
  border-top-color: var(--primary);
  border-radius: var(--radius-round);
  animation: cmdkSpin var(--spin) linear infinite;
}
@keyframes cmdkSpin { to { transform: rotate(360deg); } }
.cmdk-list { max-height: 52vh; overflow-y: auto; padding: var(--space-2); }
.cmdk-group {
  padding: var(--space-2) var(--space-3) var(--space-1);
  font-size: var(--text-2xs);
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--faint);
}
.cmdk-group:first-child { padding-top: var(--space-1); }
.cmdk-item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  width: 100%;
  text-align: left;
  border: 0;
  background: transparent;
  color: var(--text);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius);
  font-size: var(--text-md);
  cursor: pointer;
  text-decoration: none;
}
.cmdk-item i { color: var(--faint); width: 1.3rem; text-align: center; flex-shrink: 0; }
.cmdk-item.active, .cmdk-item:hover {
  background: var(--primary-soft);
  color: var(--primary-text);
}
.cmdk-item.active i, .cmdk-item:hover i { color: inherit; }
.cmdk-item-body { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.cmdk-item-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cmdk-item-sub {
  font-size: var(--text-xs);
  color: var(--faint);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.cmdk-item.active .cmdk-item-sub, .cmdk-item:hover .cmdk-item-sub {
  color: color-mix(in srgb, var(--primary-text) 70%, transparent);
}
.cmdk-item mark {
  background: transparent;
  color: var(--primary-text);
  font-weight: 700;
  padding: 0;
}
.cmdk-item.active mark, .cmdk-item:hover mark { color: inherit; text-decoration: underline; }
.cmdk-item-tag {
  flex-shrink: 0;
  font-size: var(--text-2xs);
  color: var(--faint);
  text-transform: uppercase;
  letter-spacing: .05em;
}
.cmdk-empty { padding: var(--space-5); text-align: center; color: var(--faint); font-size: var(--text-md); }
.cmdk-hint {
  display: flex;
  gap: var(--space-4);
  padding: var(--space-2) var(--space-4);
  border-top: 1px solid var(--border);
  color: var(--faint);
  font-size: var(--text-xs);
}
.sheet-backdrop {
  position: fixed;
  inset: 0;
  z-index: 4000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: var(--space-4);
  background: rgba(5,8,18,.45);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
.sheet-backdrop.open { display: flex; }
.sheet {
  width: 100%;
  max-width: 34rem;
  max-height: min(80vh, 42rem);
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  animation: cmdkIn var(--dur-2) var(--ease-out) both;
}
.sheet-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding: var(--space-4);
  border-bottom: 1px solid var(--border);
}
.sheet-title {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin: 0;
  font-size: var(--text-lg);
  font-weight: 700;
}
.sheet-title i { color: var(--primary); }
.sheet-body { padding: var(--space-4); overflow-y: auto; }
.keys-group + .keys-group { margin-top: var(--space-5); }
.keys-group-title {
  font-size: var(--text-2xs);
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--faint);
  margin-bottom: var(--space-2);
}
.keys-list {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--space-2) var(--space-4);
  align-items: baseline;
  margin: 0;
}
.keys-list dt { display: flex; gap: var(--space-1); align-items: center; justify-content: flex-end; }
.keys-list dd { margin: 0; color: var(--muted); font-size: var(--text-sm); }
.keys-foot {
  margin: var(--space-5) 0 0;
  padding-top: var(--space-3);
  border-top: 1px solid var(--border);
  color: var(--faint);
  font-size: var(--text-xs);
}
@media (max-width: 575.98px) {
.keys-list { grid-template-columns: 1fr; gap: 0; }
  .keys-list dt { justify-content: flex-start; margin-top: var(--space-3); }
  .keys-list dd { margin-bottom: 0; }
}
.nav-key {
  display: none;
  margin-left: auto;
  padding: 0 var(--space-1);
  min-width: 1.1rem;
  text-align: center;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-xs);
  background: var(--surface-muted);
  color: var(--muted);
  font-size: var(--text-2xs);
  font-weight: 700;
  line-height: 1.45;
}
body.alt-keys .app-sidebar .nav-link .nav-key { display: inline-block; }
body.alt-keys .app-sidebar .nav-link .fav-star { display: none; }
body.sidebar-mini .nav-key { display: none !important; }
.net-chip {
  position: fixed;
  left: var(--space-4);
  bottom: calc(var(--space-4) + var(--bottomnav-h));
  z-index: 3500;
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-pill);
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  color: var(--text);
  font-size: var(--text-sm);
  font-weight: 600;
  opacity: 0;
  transform: translateY(.5rem);
  pointer-events: none;
  transition: opacity var(--dur-2) var(--ease-out), transform var(--dur-2) var(--ease-out);
}
.net-chip.show { opacity: 1; transform: none; }
.net-chip.net-off { border-color: var(--danger); color: var(--danger); }
.net-chip.net-off i { color: var(--danger); }
.net-chip.net-on { border-color: var(--success); color: var(--success); }
.table-export { display: inline-flex; align-items: center; gap: var(--space-1); flex-shrink: 0; }
.task-board {
  display: grid;
grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
  gap: var(--space-3);
  align-items: start;
}
.task-col {
  --col-tone: var(--border-strong);
  background: var(--surface-sunken);
  border: 1px solid var(--border);
  border-top: 3px solid var(--col-tone);
  border-radius: var(--radius);
  padding: var(--space-3);
}
.task-col[data-status="created"] { --col-tone: var(--border-strong); }
.task-col[data-status="accepted"] { --col-tone: var(--primary); }
.task-col[data-status="completed"],
.task-col[data-status="finalized"] { --col-tone: var(--success); }
.task-col[data-status="cancelled"] { --col-tone: var(--faint); }
.task-col-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-2);
  padding: 0 var(--space-0);
}
.task-col-title {
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--muted);
}
.task-col-count {
  background: var(--surface-hover);
  color: var(--muted);
  border-radius: var(--radius-pill);
  padding: var(--space-0) var(--space-2);
  font-size: var(--text-2xs);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.task-col[data-status="accepted"] .task-col-count {
  background: var(--primary-soft);
  color: var(--primary-text);
}
.task-col[data-status="completed"] .task-col-count,
.task-col[data-status="finalized"] .task-col-count {
  background: var(--success-soft);
  color: var(--success);
}
.task-col-meta {
  display: flex;
  gap: var(--space-3);
  padding: 0 var(--space-0) var(--space-2);
  margin-top: calc(var(--space-1-5) * -1);
  font-size: var(--text-xs);
  color: var(--muted);
}
.task-col-fold {
  background: none;
  border: 0;
  padding: 0 var(--space-1) 0 0;
  line-height: 1;
  color: var(--faint);
  cursor: pointer;
}
.task-col-fold:hover { color: var(--text); }
.task-col-fold i { display: inline-block; transition: transform var(--dur-2) var(--ease-out); }
.task-col-head { gap: var(--space-1); }
.task-col-head .task-col-title { margin-right: auto; }
.task-col.is-folded { padding-bottom: var(--space-1-5); }
.task-col.is-folded .task-col-body,
.task-col.is-folded .task-col-meta { display: none; }
.task-col.is-folded .task-col-head { margin-bottom: 0; }
.task-col.is-folded .task-col-fold i { transform: rotate(-90deg); }
.task-col-toggle {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: 0;
  opacity: 0;
}
.task-col-toggle:not(:checked) ~ .task-col-body > .task-card.is-extra { display: none; }
.task-col-more {
  display: block;
  margin-top: var(--space-1-5);
  padding: var(--space-1) var(--space-2);
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius-sm);
  color: var(--muted);
  font-size: var(--text-xs);
  font-weight: 700;
  text-align: center;
  cursor: pointer;
}
.task-col-more:hover {
  color: var(--primary-text);
  border-color: var(--primary);
  background: var(--primary-soft);
}
.task-col-toggle:focus-visible ~ .task-col-more {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}
.task-col-toggle:not(:checked) ~ .task-col-more .more-close,
.task-col-toggle:checked ~ .task-col-more .more-open { display: none; }
.task-col.is-folded .task-col-more { display: none; }
.task-col-body {
  min-height: 5rem;
  max-height: min(68vh, 44rem);
  overflow-y: auto;
  overscroll-behavior: contain;
  border-radius: var(--radius-sm);
  transition: background var(--dur-2) var(--ease-out);
  scrollbar-width: thin;
}
.task-col-body.drop-target {
  background: var(--primary-soft);
  outline: 2px dashed var(--primary);
  outline-offset: -2px;
}
.task-board:has(.task-card.dragging) .task-col-body {
  outline: 1px dashed var(--border-strong);
  outline-offset: -2px;
  border-radius: var(--radius-sm);
}
.task-col-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-1);
  margin: 0;
  padding: var(--space-4) var(--space-1-5);
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius-sm);
  text-align: center;
  font-size: var(--text-xs);
  color: var(--faint);
}
.task-col-empty i { font-size: var(--text-lg); opacity: .55; }
.task-board:has(.task-card.dragging) .task-col-empty {
  border-color: var(--primary-line);
  color: var(--primary-text);
}
.task-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 3px solid var(--border-strong);
  border-radius: var(--radius-sm);
  padding: var(--space-2) var(--space-3);
  margin-bottom: var(--space-2);
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--dur-2) var(--ease-out), transform var(--dur-2) var(--ease-out), opacity var(--dur-2) var(--ease-out), border-color var(--dur-2) var(--ease-out);
}
.task-card[draggable="true"] { cursor: grab; }
.task-card[draggable="true"]:active { cursor: grabbing; }
.task-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
  border-color: var(--border-strong);
}
.task-card.dragging { opacity: .45; transform: rotate(1.5deg); }
.task-card.prio-high { border-left-color: var(--danger); }
.task-card.prio-medium { border-left-color: var(--warning); }
.task-card.prio-low { border-left-color: var(--primary); }
.task-card.is-overdue {
  background: var(--danger-soft);
  border: 1px solid var(--danger);
  border-left: 3px solid var(--danger);
}
.task-card[data-status="finalized"],
.task-col[data-status="finalized"] .task-card {
  border: 1px solid var(--success);
  border-left: 3px solid var(--success);
}
.task-card.prio-cancelled,
.task-col[data-status="cancelled"] .task-card { opacity: .7; border-left-color: var(--faint); }
.task-col[data-status="cancelled"] .task-card-title {
  text-decoration: line-through;
  text-decoration-color: var(--faint);
}
.task-card-title {
  display: block;
  font-weight: 600;
  font-size: var(--text-sm);
  color: inherit;
  text-decoration: none;
  margin-bottom: var(--space-1-5);
}
.task-card-title:hover { color: var(--primary); text-decoration: underline; }
.task-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1) var(--space-2);
  align-items: center;
  font-size: var(--text-xs);
  color: var(--muted);
}
.task-card-who {
  display: flex;
  align-items: center;
  gap: var(--space-1-5);
  margin-bottom: var(--space-1);
  min-width: 0;
}
.task-card-who-icon { color: var(--muted); font-size: var(--text-xs); }
.task-card-name {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.task-card-client {
  font-size: var(--text-xs);
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}
.task-card-client::before { content: "· "; }
.task-card-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-1) var(--space-2);
  font-size: var(--text-2xs);
  color: var(--muted);
}
.task-card-tag {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.task-due {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  font-weight: 600;
  color: var(--text);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.task-due.is-late {
  color: var(--danger);
  font-weight: 700;
}
.task-card-flags {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  margin-left: auto;
  color: var(--faint);
}
.task-card-flag {
  display: inline-flex;
  align-items: center;
  gap: var(--space-0);
}
.task-moves {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1);
}
.task-moves .btn { font-size: var(--text-2xs); padding: var(--space-0) var(--space-1-5); }
.task-moves-card {
  margin-top: var(--space-2);
  padding-top: var(--space-2);
  border-top: 1px dashed var(--border);
}
.task-moves-tight {
  flex-wrap: nowrap;
  justify-content: flex-end;
  gap: var(--space-1);
}
.task-moves-tight .btn { padding: var(--space-0) var(--space-1-5); line-height: 1; }
.task-moves-tight .btn i { font-size: var(--text-xs); }
.task-moves-card {
  justify-content: flex-start;
  opacity: .5;
  transition: opacity var(--dur-2) var(--ease-out);
}
.task-card:hover .task-moves-card,
.task-card:focus-within .task-moves-card { opacity: 1; }
@media (hover: none) {
  .task-moves-card { opacity: 1; }
}
.task-desc-toggle {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: 0;
  opacity: 0;
}
.task-desc-more { display: none; }
@media (max-width: 991.98px) {
  .task-desc-fold .task-desc-toggle:not(:checked) ~ .task-desc-text {
    display: -webkit-box;
    -webkit-line-clamp: 5;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
.task-desc-fold .task-desc-more {
    position: relative;
    display: flex;
    align-items: center;
    gap: var(--space-1);
    margin-top: var(--space-2);
    color: var(--primary-text);
    font-size: var(--text-xs);
    font-weight: 700;
    cursor: pointer;
  }
.task-desc-fold .task-desc-toggle:not(:checked) ~ .task-desc-more::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 100%;
    height: 2.5em;
    background: linear-gradient(to top, var(--surface), transparent);
    pointer-events: none;
  }
  .task-desc-fold .task-desc-toggle:focus-visible ~ .task-desc-more {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
  }
  .task-desc-fold .task-desc-toggle:not(:checked) ~ .task-desc-more .more-close,
  .task-desc-fold .task-desc-toggle:checked ~ .task-desc-more .more-open { display: none; }
}
.task-progress {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-top: var(--space-2);
}
.task-progress-track {
  flex: 1;
  height: 7px;
  background: var(--surface-muted);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  overflow: hidden;
}
.task-progress-fill {
  height: 100%;
  background: var(--grad-primary);
  border-radius: var(--radius-pill);
  transition: width var(--dur-3) var(--ease-out);
}
.task-progress-fill.done { background: linear-gradient(90deg,var(--success-fill-strong),var(--success-fill)); }
.task-progress-label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  font-size: var(--text-2xs);
  font-weight: 700;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.task-progress-label i { font-size: var(--text-xs); }
.task-progress.is-done .task-progress-label { color: var(--success); }
.task-progress-cell {
  margin-top: 0;
  margin-bottom: var(--space-1);
  min-width: 5rem;
  max-width: 9rem;
}
.task-row-flags { margin-left: 0; }
.task-check-box {
  border: 0;
  background: transparent;
  color: var(--muted);
  padding: 0;
  font-size: var(--text-base);
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
}
.task-check-box:hover { color: var(--primary); }
.task-check.is-done .task-check-box { color: var(--success); }
.task-check.is-done .task-check-text {
  text-decoration: line-through;
  color: var(--faint);
}
.task-event {
  background: var(--surface-hover);
  border-left: 2px solid var(--border-strong);
  font-size: var(--text-xs);
  color: var(--muted);
}
.panel-fold i { display: inline-block; transition: transform var(--dur-2) var(--ease-out); }
.panel-fold.collapsed i { transform: rotate(180deg); }
.task-form-grid { display: grid; gap: 0; }
.task-form-sec + .task-form-sec { margin-top: var(--space-4); }
.task-form-actions { margin-top: var(--space-4); }
@media (min-width: 992px) {
  .task-form-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    grid-template-areas:
      "what who"
      "what whom";
    column-gap: var(--space-4);
    row-gap: var(--space-4);
    align-items: start;
  }
  .task-form-what { grid-area: what; }
  .task-form-who { grid-area: who; }
  .task-form-whom { grid-area: whom; }
.task-form-sec + .task-form-sec { margin-top: 0; }
}
.load-rail {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-3);
}
.load-rail-label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--muted);
}
.load-rail-cycle {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  margin-left: var(--space-0);
  padding: var(--space-0) var(--space-1-5);
  border-radius: var(--radius-pill);
  background: var(--ground-shade);
  border: var(--hairline) solid var(--ground-line);
  color: var(--ground-ink);
  font-variant-numeric: tabular-nums;
}
.load-chip {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1-5);
  min-width: 8.5rem;
  max-width: 13rem;
  padding: var(--space-1) var(--space-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  background: var(--surface);
  color: inherit;
  text-decoration: none;
  transition: border-color var(--dur-2) var(--ease-out), box-shadow var(--dur-2) var(--ease-out), transform var(--dur-2) var(--ease-out);
}
.load-chip:hover {
  border-color: var(--primary-line);
  box-shadow: var(--shadow-sm);
  transform: translateY(-1px);
  color: inherit;
}
.load-chip.is-active {
  border-color: var(--primary);
  background: var(--primary-soft);
}
.load-chip-main {
  display: flex;
  flex-direction: column;
  gap: var(--space-0);
  min-width: 0;
  flex: 1 1 auto;
}
.load-chip-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--space-2);
  min-width: 0;
}
.load-chip-name {
  font-size: var(--text-xs);
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.load-chip-count {
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--primary-text);
  font-variant-numeric: tabular-nums;
}
.load-chip.is-late .load-chip-count { color: var(--danger); }
.load-chip-track {
  height: .25rem;
  border-radius: var(--radius-pill);
  background: var(--surface-hover);
  overflow: hidden;
}
.load-chip-fill {
  display: block;
  height: 100%;
  border-radius: var(--radius-pill);
  background: linear-gradient(90deg, var(--primary), var(--primary-2));
}
.load-chip-fill.is-late { background: linear-gradient(90deg, var(--danger-fill-strong), var(--danger-fill)); }
.load-chip-slow { color: var(--warning); font-size: var(--text-xs); }
.tl-scroll { overflow-x: auto; }
.tl-table {
  border-collapse: separate;
  border-spacing: 0;
  font-size: var(--text-xs);
}
.tl-table th, .tl-table td {
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}
.tl-who {
  position: sticky;
  left: 0;
  z-index: 2;
  min-width: 8.5rem;
  max-width: 11rem;
  background: var(--surface);
  border-right: 1px solid var(--border);
  text-align: left;
  font-weight: 600;
}
.tl-table thead .tl-who { z-index: 3; }
.tl-who-name {
  display: block;
  color: inherit;
  text-decoration: none;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.tl-who-name:hover { color: var(--primary-text); }
.tl-who-note {
  display: block;
  font-size: var(--text-xs);
  font-weight: 400;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.tl-head-day, .tl-head-late {
  min-width: 6.5rem;
  text-align: center;
  line-height: 1.2;
  padding: var(--space-1) var(--space-1);
}
.tl-day-name { display: block; font-size: var(--text-xs); color: var(--muted); }
.tl-day-num { display: block; font-weight: 700; font-variant-numeric: tabular-nums; }
.tl-day-load {
  display: inline-block;
  margin-top: var(--space-0);
  padding: 0 var(--space-1);
  border-radius: var(--radius-pill);
  background: var(--surface-hover);
  color: var(--muted);
  font-size: var(--text-xs);
  font-variant-numeric: tabular-nums;
}
.tl-head-day.is-weekend { background: var(--surface-muted); }
.tl-head-day.is-today, .tl-head-late { background: var(--primary-soft); }
.tl-head-late .tl-day-num { color: var(--danger); }
.tl-cell {
  position: relative;
  min-width: 6.5rem;
  padding: var(--space-1);
}
.tl-cell::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--primary);
  opacity: calc(var(--heat, 0) * .18);
  pointer-events: none;
}
.tl-cell.is-late::before { background: var(--danger-fill); opacity: calc(var(--heat, 0) * .22); }
.tl-cell.is-weekend { background-color: var(--surface-muted); }
.tl-cell.is-today { box-shadow: inset var(--rail) 0 0 var(--primary); }
.tl-cell.is-muted { background-color: var(--surface-muted); }
.tl-chip {
  position: relative;
  z-index: 1;
  display: block;
  margin-bottom: var(--space-1);
  padding: var(--space-1) var(--space-1-5);
  border-radius: var(--radius-sm);
  border-left: 3px solid var(--border);
  background: var(--surface);
  color: inherit;
  text-decoration: none;
  box-shadow: var(--shadow-sm);
}
.tl-chip:last-child { margin-bottom: 0; }
.tl-chip:hover { color: inherit; border-color: var(--primary-line); background: var(--surface-hover); }
.tl-chip.prio-high { border-left-color: var(--danger); }
.tl-chip.prio-medium { border-left-color: var(--warning); }
.tl-chip.prio-low { border-left-color: var(--primary); }
.tl-chip-title {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 600;
}
.tl-chip-h { color: var(--muted); font-variant-numeric: tabular-nums; }
.tl-legend { display: flex; flex-wrap: wrap; gap: var(--space-1-5); }
.tl-legend-item {
  font-size: var(--text-xs);
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
}
.tl-legend-item.is-late { color: var(--danger); font-weight: 600; }
.bulk-bar {
  position: sticky;
  bottom: calc(var(--space-3) + var(--bottomnav-h));
  z-index: 15;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  margin-bottom: var(--space-3);
  border: 1px solid var(--primary-line);
  border-radius: var(--radius);
  background: var(--surface-raised);
  backdrop-filter: blur(var(--glass-blur));
  box-shadow: var(--shadow-lg);
}
.bulk-count {
  font-size: var(--text-sm);
  color: var(--muted);
  white-space: nowrap;
}
.bulk-count strong {
  color: var(--primary-text);
  font-variant-numeric: tabular-nums;
}
.bulk-field { width: auto; flex: 0 1 13rem; }
.tbl-pick { width: 2.4rem; }
tr.is-picked > td { background: var(--primary-soft); }
.registry-table tbody tr.is-dirty > td { background: var(--warning-soft); }
.registry-table tbody tr.is-dirty > td:first-child {
  box-shadow: inset var(--rail) 0 0 var(--warning);
}
.atk-diff .atk-old { color: var(--muted); text-decoration: line-through; }
.atk-diff tr:has(input[name="apliko"]:not(:checked)) .atk-old {
  color: inherit;
  text-decoration: none;
}
@media (max-width: 900px) {
  .task-board { grid-template-columns: 1fr; }
.task-col-body { min-height: 3rem; max-height: none; overflow-y: visible; }
.task-card { cursor: default; }
  .bulk-field { flex: 1 1 100%; }
}
.group-nav-title {
  font-size: var(--text-2xs);
  text-transform: uppercase;
  letter-spacing: .09em;
  color: var(--faint);
  font-weight: 700;
  padding: var(--space-2) var(--space-2) var(--space-1);
}
.sidebar-add {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  width: 100%;
  padding: var(--space-1-5) var(--space-2);
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  background: transparent;
  color: var(--faint);
  font-size: var(--text-xs);
  font-weight: 600;
  transition: color var(--dur-2) var(--ease-out), border-color var(--dur-2) var(--ease-out), background var(--dur-2) var(--ease-out);
}
.sidebar-add:hover {
  color: var(--primary-text);
  border-color: var(--primary);
  background: var(--surface-hover);
}
.sidebar-add i { font-size: var(--text-sm); }
.tm-chat {
  position: relative;    
  display: flex;
  flex-direction: column;
  height: calc(100vh - var(--topbar-h) - var(--bottomnav-h) - 5.5rem);
  height: calc(100dvh - var(--topbar-h) - var(--bottomnav-h) - 5.5rem);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.tm-header {
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-4);
  flex-shrink: 0;
  background: var(--surface-muted);
}
.tm-clientbox {
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  flex-shrink: 0;
}
.tm-clientsum {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-4);
  cursor: pointer;
  list-style: none;
  font-size: var(--text-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--muted);
}
.tm-clientsum::-webkit-details-marker { display: none; }
.tm-clientsum::marker { content: ''; }
.tm-clientsum:hover { color: var(--text); }
.tm-clientsum-caret { transition: transform var(--dur-2) var(--ease-out); }
.tm-clientbox[open] .tm-clientsum-caret { transform: rotate(180deg); }
.tm-clientsum-peek {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  margin-left: auto;
}
.tm-clientbox[open] .tm-clientsum-peek { display: none; }
.tm-clientbox .tm-clientcard { border-bottom: 0; padding-top: 0; }
.tm-clientcard {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-5);
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  flex-shrink: 0;
}
.tm-clientcard-item { display: flex; flex-direction: column; line-height: 1.2; }
.tm-clientcard-label {
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--muted);
  font-weight: 600;
}
.tm-clientcard-value {
  font-weight: 700;
  font-size: var(--text-base);
  font-variant-numeric: tabular-nums;
}
.tm-clientcard-sub { font-size: var(--text-xs); color: var(--faint); }
.tm-clientcard-links { margin-left: auto; display: flex; gap: var(--space-1-5); flex-wrap: wrap; }
.tm-templates { display: flex; flex-wrap: wrap; gap: var(--space-1-5); }
.tm-template-chip {
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  border-radius: var(--radius-pill);
  padding: var(--space-1) var(--space-3);
  font-size: var(--text-sm);
  font-weight: 600;
  cursor: pointer;
  transition: background var(--dur-2) var(--ease-out), border-color var(--dur-2) var(--ease-out), color var(--dur-2) var(--ease-out);
}
.tm-template-chip:hover {
  background: var(--primary-soft);
  border-color: var(--primary-line);
  color: var(--primary);
}
.tm-filters { display: flex; flex-wrap: wrap; gap: var(--space-2); margin-bottom: var(--space-4); }
.tm-filter {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  border-radius: var(--radius-pill);
  padding: var(--space-1-5) var(--space-3);
  font-size: var(--text-sm);
  font-weight: 600;
  text-decoration: none;
  transition: background var(--dur-2) var(--ease-out), border-color var(--dur-2) var(--ease-out), color var(--dur-2) var(--ease-out);
}
.tm-filter:hover { color: var(--primary); border-color: var(--primary-line); }
.tm-filter.active {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--primary-contrast);
}
.tm-filter-count {
  margin-left: var(--space-2);
  font-size: var(--text-xs);
  background: var(--surface-muted);
  color: var(--muted);
  border-radius: var(--radius-pill);
  padding: var(--space-0) var(--space-2);
  font-weight: 700;
}
.tm-filter.active .tm-filter-count { background: rgba(255,255,255,.25); color: var(--primary-contrast); }
.tm-read { font-size: .9em; margin-right: var(--space-0); }
.tm-avatar {
  width: 34px; height: 34px;
  border-radius: var(--radius-round);
  background: var(--grad-tm);
  color: var(--tm-contrast);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: var(--text-sm);
  flex-shrink: 0;
}
.tm-avatar.sm { width: 26px; height: 26px; font-size: var(--text-2xs); }
.tm-facepile { display: flex; align-items: center; }
.tm-facepile .tm-avatar { margin-left: -6px; border: 2px solid var(--surface); }
.tm-facepile .tm-avatar:first-child { margin-left: 0; }
.tm-facepile-more { font-size: var(--text-2xs); color: var(--muted); margin-left: var(--space-1-5); }
.tm-messages { flex: 1; overflow-y: auto; padding: var(--space-3) var(--space-4); }
.tm-older {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-1-5);
  width: fit-content;
  margin: 0 auto var(--space-3);
  padding: var(--space-1) var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  background: var(--surface);
  color: var(--muted);
  font-size: var(--text-xs);
  font-weight: 600;
  text-decoration: none;
  transition: color var(--dur-1) var(--ease-out),
              border-color var(--dur-1) var(--ease-out);
}
.tm-older:hover, .tm-older:focus-visible {
  color: var(--tm-accent);
  border-color: var(--tm-accent-line);
}
.tm-day { text-align: center; margin: var(--space-4) 0 var(--space-3); border-top: 1px solid var(--border); }
.tm-day span {
  position: relative;
  top: -.65rem;
  background: var(--surface);
  padding: 0 var(--space-3);
  font-size: var(--text-2xs);
  color: var(--muted);
  font-weight: 600;
}
.tm-msg {
  position: relative;
  display: flex;
  gap: var(--space-3);
  padding: var(--space-2);
  border-radius: var(--radius-sm);
}
.tm-msg-main {
  min-width: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.tm-msg-head { display: flex; align-items: baseline; gap: var(--space-2); }
.tm-msg-author { font-weight: 600; font-size: var(--text-sm); }
.tm-msg-time { font-size: var(--text-2xs); color: var(--muted); }
.tm-msg-edited { font-size: var(--text-2xs); color: var(--faint); font-style: italic; }
.tm-msg-text { white-space: pre-wrap; word-break: break-word; line-height: 1.45; }
.tm-bubble {
  min-width: 0;
  max-width: min(78%, 38rem);
  padding: var(--space-2) var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  border-top-left-radius: var(--radius-xs);
  background: var(--surface-muted);
  transition: border-color var(--dur-1) var(--ease-out);
}
.tm-msg-cont > .tm-msg-main > .tm-bubble { border-top-left-radius: var(--radius); }
.tm-msg:hover > .tm-msg-main > .tm-bubble { border-color: var(--border-strong); }
.tm-msg-cont { padding-top: var(--space-0); padding-bottom: var(--space-0); }
.tm-msg-when {
  width: 34px;
  flex-shrink: 0;
  text-align: right;
  font-size: var(--text-2xs);
  color: var(--faint);
  line-height: 1.5;
  font-variant-numeric: tabular-nums;
  opacity: 0;
  transition: opacity var(--dur-1) var(--ease-out);
}
.tm-msg:hover > .tm-msg-when,
.tm-msg:focus-within > .tm-msg-when { opacity: 1; }
@media (hover: none) {
  .tm-msg-when { opacity: 1; }
}
.tm-quote {
  display: flex;
  align-items: baseline;
  gap: var(--space-1-5);
  width: 100%;
  margin-bottom: var(--space-1);
  padding: var(--space-1) var(--space-2);
  border: 0;
  border-left: 3px solid var(--tm-accent);
  border-radius: var(--radius-xs);
  background: var(--tm-accent-soft);
  color: var(--muted);
  font-size: var(--text-xs);
  text-align: left;
  cursor: pointer;
  transition: background var(--dur-1) var(--ease-out);
}
.tm-quote-who { font-weight: 700; color: var(--tm-accent); flex-shrink: 0; }
.tm-quote-text {
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.tm-quote:hover { background: color-mix(in srgb, var(--tm-accent) 16%, transparent); }
.tm-msg.mine .tm-quote { background: var(--surface); }
.mention {
  background: var(--tm-accent-soft);
  color: var(--tm-accent);
  font-weight: 600;
  padding: 0 var(--space-1);
  border-radius: var(--radius-xs);
}
.tm-msg-actions {
  position: absolute;
  top: -.55rem;
  right: .5rem;
  display: flex;
  align-items: center;
  gap: var(--space-0);
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-md);
  padding: var(--space-0);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--dur-1) var(--ease-out);
}
.tm-msg:hover > .tm-msg-actions,
.tm-msg:focus-within > .tm-msg-actions { opacity: 1; pointer-events: auto; }
@media (hover: none) {
  .tm-msg-actions { opacity: 0; pointer-events: none; }
  .tm-msg.is-open > .tm-msg-actions { opacity: 1; pointer-events: auto; }
}
.tm-action {
  border: 0;
  background: transparent;
  color: var(--text);
  padding: var(--space-0) var(--space-1);
  border-radius: var(--radius-xs);
  cursor: pointer;
  font-size: var(--text-sm);
  line-height: 1;
}
.tm-action:hover { background: var(--primary-soft); }
.tm-action-danger:hover { background: var(--danger-soft); color: var(--danger); }
.tm-reactions { display: flex; flex-wrap: wrap; gap: var(--space-1); margin-top: var(--space-1); }
.tm-reaction {
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--text);
  border-radius: var(--radius-pill);
  padding: var(--space-0) var(--space-1-5);
  font-size: var(--text-xs);
  cursor: pointer;
  line-height: 1.5;
}
.tm-reaction:hover { border-color: var(--tm-accent); }
.tm-reaction.mine { background: var(--tm-accent-soft); border-color: var(--tm-accent); font-weight: 700; }
.tm-seen-who {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  margin-top: var(--space-0);
  padding-inline: var(--space-1);
  font-size: var(--text-2xs);
  color: var(--faint);
  cursor: default;
}
.tm-seen-who .bi-check2-all { color: var(--tm-accent); }
.tm-reply-btn, .tm-thread-toggle {
  border: 0;
  background: transparent;
  color: var(--tm-accent);
  font-size: var(--text-xs);
  font-weight: 600;
  padding: var(--space-0) 0;
  margin-top: var(--space-1);
  cursor: pointer;
}
.tm-reply-btn:hover, .tm-thread-toggle:hover { text-decoration: underline; }
.tm-thread {
  border-left: 2px solid var(--tm-accent-line);
  margin: var(--space-1-5) 0 var(--space-1);
  padding-left: var(--space-2);
}
.tm-reply { padding: var(--space-1) var(--space-1-5); }
.tm-reply .tm-msg-author { font-size: var(--text-xs); }
.tm-reply .tm-msg-text { font-size: var(--text-sm); }
.tm-edit-form { margin-top: var(--space-1); }
.tm-edit-actions { display: flex; gap: var(--space-1-5); margin-top: var(--space-1); }
.tm-typing {
  height: 1.15rem;
  padding: 0 var(--space-4);
  font-size: var(--text-xs);
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: var(--space-1-5);
}
.tm-drop {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: flex;
  padding: var(--space-3);
  background: color-mix(in srgb, var(--surface) 82%, transparent);
  pointer-events: none;
}
.tm-drop-in {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  border: 2px dashed var(--tm-accent);
  border-radius: var(--radius-lg);
  color: var(--tm-accent);
  font-size: var(--text-sm);
  font-weight: 600;
  text-align: center;
}
.tm-drop-in .bi { font-size: var(--text-3xl); }
.tm-composer {
  position: relative;
  padding: var(--space-3) var(--space-4) var(--space-4);
  border-top: 1px solid var(--border);
  flex-shrink: 0;
}
.tm-jump {
  position: absolute;
  left: 50%;
  bottom: calc(100% - var(--space-2));
  transform: translateX(-50%);
  display: inline-flex;
  align-items: center;
  gap: var(--space-1-5);
  padding: var(--space-1) var(--space-3);
  border: 0;
  border-radius: var(--radius-pill);
  background: var(--tm-accent);
  color: var(--primary-contrast);
  font-size: var(--text-xs);
  font-weight: 600;
  white-space: nowrap;
  box-shadow: var(--shadow-md);
  cursor: pointer;
  z-index: 3;
}
.tm-composer-row { display: flex; align-items: flex-end; gap: var(--space-2); }
.tm-composer input[type="text"],
.tm-composer textarea { border-radius: var(--radius-sm); }
.tm-composer input[type="text"]:focus,
.tm-composer textarea:focus {
  border-color: var(--tm-accent);
  box-shadow: 0 0 0 var(--ring-w-lg) var(--tm-accent-line);
}
.tm-composer textarea {
  resize: none;
  min-height: 2.375rem;
  max-height: 9rem;
  overflow-y: auto;
  line-height: 1.45;
}
.tm-reply-context {
  display: flex;
  align-items: center;
  gap: var(--space-1-5);
  background: var(--tm-accent-soft);
  border-left: 3px solid var(--tm-accent);
  border-radius: var(--radius-xs);
  padding: var(--space-1) var(--space-2);
  margin-bottom: var(--space-1-5);
  font-size: var(--text-xs);
  color: var(--muted);
}
.tm-reply-context .btn-close { margin-left: auto; font-size: var(--text-2xs); }
.tm-mention-box {
  position: absolute;
  bottom: 100%;
  left: 1.25rem;
  right: 1.25rem;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  z-index: 20;
}
.tm-mention-item {
  display: block;
  width: 100%;
  text-align: left;
  border: 0;
  background: transparent;
  color: var(--text);
  padding: var(--space-1-5) var(--space-2);
  font-size: var(--text-sm);
  cursor: pointer;
}
.tm-mention-item:hover { background: var(--primary-soft); }
.group-attach-form {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: 0 var(--space-4) var(--space-3);
  flex-shrink: 0;
}
.group-attach-form .icon-btn { width: 34px; height: 34px; cursor: pointer; }
.chat-link { word-break: break-all; }
.tm-search {
  display: flex;
  align-items: center;
  gap: var(--space-1-5);
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-pill);
  padding: var(--space-1) var(--space-3);
  color: var(--muted);
  transition: border-color var(--dur-2) var(--ease-out), box-shadow var(--dur-2) var(--ease-out);
}
.tm-search:focus-within {
  border-color: var(--tm-accent);
  box-shadow: 0 0 0 var(--ring-w-lg) var(--tm-accent-line);
}
.tm-search .bi-search { font-size: var(--text-sm); }
.tm-search input {
  border: 0;
  background: transparent;
  outline: none;
  color: var(--text);
  font-size: var(--text-sm);
  width: 11rem;
  max-width: 40vw;
}
.tm-search input::placeholder { color: var(--faint); }
.tm-search-clear {
  text-decoration: none;
  color: var(--muted);
  font-size: var(--text-lg);
  line-height: 1;
  padding: 0 var(--space-0);
  background: none;
  border: 0;
  cursor: pointer;
}
.tm-search-clear[hidden] { display: none; }
.tm-search-clear:hover { color: var(--danger); }
.tm-pinned {
  flex-shrink: 0;
  border-bottom: 1px solid var(--border);
  background: var(--warning-soft);
  padding: var(--space-2) var(--space-4);
  max-height: 8.5rem;
  overflow-y: auto;
}
.tm-pinned-head {
  display: flex;
  align-items: center;
  gap: var(--space-1-5);
  font-size: var(--text-2xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--warning);
  margin-bottom: var(--space-1-5);
}
.tm-pinned-list { display: flex; flex-direction: column; gap: var(--space-1); }
.tm-pinned-item {
  display: flex;
  align-items: center;
  gap: var(--space-1-5);
  border-radius: var(--radius-sm);
  padding: var(--space-0) var(--space-0) var(--space-0) var(--space-1);
}
.tm-pinned-item:hover { background: var(--surface); }
.tm-pinned-jump {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: baseline;
  gap: var(--space-1-5);
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
  color: var(--text);
  font-size: var(--text-sm);
  padding: var(--space-0) 0;
}
.tm-pinned-author { font-weight: 700; flex-shrink: 0; }
.tm-pinned-text {
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.tm-pinned-unpin {
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  padding: var(--space-0) var(--space-1-5);
  border-radius: var(--radius-sm);
  font-size: var(--text-xs);
  flex-shrink: 0;
}
.tm-pinned-unpin:hover { background: var(--danger-soft); color: var(--danger); }
.tm-pin-tag { color: var(--warning); font-size: var(--text-sm); }
.tm-action-on { color: var(--warning); }
.tm-msg.is-pinned > .tm-msg-main > .tm-bubble { box-shadow: inset var(--rail) 0 0 var(--warning); }
.tm-flash { animation: tm-flash var(--beat) var(--ease-out); }
@keyframes tm-flash {
  0%, 40% { background: var(--tm-accent-soft); }
  100% { background: transparent; }
}
.tm-search-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  flex-wrap: wrap;
  padding: var(--space-1-5) var(--space-1) var(--space-3);
  border-bottom: 1px solid var(--border);
  margin-bottom: var(--space-2);
  color: var(--muted);
  font-size: var(--text-sm);
}
.tm-search-hit {
  display: flex;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-1-5);
  border-radius: var(--radius-sm);
  text-decoration: none;
  color: inherit;
}
.tm-search-hit:hover { background: var(--surface-muted); }
.tm-search-hit-main { min-width: 0; flex: 1; }
.tm-search-hit-head {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-0);
}
.tm-search-file {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  font-size: var(--text-xs);
  color: var(--tm-accent);
  margin-top: var(--space-1);
}
.tm-attach-trigger { width: 38px; flex-shrink: 0; }
.tm-attach-preview {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  width: 100%;
  background: var(--surface-muted);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: var(--space-1-5) var(--space-2);
}
.tm-attach-icon { color: var(--tm-accent); flex-shrink: 0; }
.tm-attach-glyph {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-xs);
  background: var(--surface);
  color: var(--tm-accent);
  font-size: var(--text-base);
  flex-shrink: 0;
}
.tm-attach-name {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--text);
  max-width: 12rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex-shrink: 0;
}
.tm-attach-preview .form-control { flex: 1; min-width: 6rem; }
.tm-attach-thumb {
  width: 2.25rem;
  height: 2.25rem;
  object-fit: cover;
  border-radius: var(--radius-xs);
  border: 1px solid var(--border);
  flex-shrink: 0;
}
.tm-attach-hint {
  flex: 1;
  min-width: 0;
  font-size: var(--text-xs);
  color: var(--muted);
}
.tm-role-form { display: inline-flex; }
.tm-role-select { width: auto; min-width: 8rem; }
.tm-mention-toast {
  position: fixed;
  bottom: 1.25rem;
  right: 1.25rem;
  background: var(--tm-accent);
  color: var(--primary-contrast);
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
  font-size: var(--text-sm);
  z-index: 1080;
}
@media (max-width: 768px) {
.tm-chat { height: calc(100vh - var(--bottomnav-h) - 12rem); }
  .tm-chat { height: calc(100dvh - var(--bottomnav-h) - 12rem); }
.tm-bubble { max-width: 92%; }
.tm-header { padding: var(--space-2) var(--space-3); gap: var(--space-2); }
  .tm-messages { padding: var(--space-2); }
  .tm-composer { padding: var(--space-2) var(--space-3) var(--space-3); }
  .tm-msg { gap: var(--space-2); }
.tm-composer-row .btn,
  .tm-composer-row .icon-btn { padding-left: var(--space-2); padding-right: var(--space-2); }
.tm-clientcard {
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: var(--space-4);
    padding: var(--space-2) var(--space-3);
  }
  .tm-clientcard-item, .tm-clientcard-links { flex-shrink: 0; }
  .tm-clientcard-links { flex-wrap: nowrap; }
}
.tm-msg.mine > .tm-msg-main { align-items: flex-end; }
.tm-msg.mine > .tm-msg-main > .tm-bubble {
  background: var(--tm-accent-soft);
  border-color: var(--tm-accent-line);
  border-top-left-radius: var(--radius);
  border-top-right-radius: var(--radius-xs);
}
.tm-msg.mine.tm-msg-cont > .tm-msg-main > .tm-bubble { border-top-right-radius: var(--radius); }
.tm-msg.mine:hover > .tm-msg-main > .tm-bubble { border-color: var(--tm-accent); }
.tm-msg.mine > .tm-msg-main > .tm-bubble > .tm-reactions { justify-content: flex-end; }
.tm-msg.mine.tm-msg-cont > .tm-msg-main > .tm-bubble > .tm-msg-head { justify-content: flex-end; }
.tm-msg.mine > .tm-msg-actions { right: auto; left: .5rem; }
.tm-msg-main > .collapse { align-self: stretch; }
.tm-seen {
  font-size: var(--text-2xs);
  color: var(--muted);
  margin-top: var(--space-1);
  text-align: right;
}
.tm-attachment {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: var(--space-2);
  margin: var(--space-1) 0;
  background: var(--surface-muted);
  max-width: 26rem;
}
.tm-attachment-head { margin-bottom: var(--space-1); font-size: var(--text-xs); }
.tm-attachment-img {
  max-width: 100%;
  max-height: 16rem;
  border-radius: var(--radius-xs);
  display: block;
}
.tm-attachment-video {
  max-width: 100%;
  max-height: 20rem;
  border-radius: var(--radius-xs);
  display: block;
  background: var(--text);
}
.foto-shikues {
  position: fixed;
  inset: 0;
  z-index: 4600;
  display: flex;
  align-items: center;
  justify-content: center;
background: color-mix(in srgb, var(--text) 82%, transparent);
padding: calc(env(safe-area-inset-top) + var(--space-5)) var(--space-3)
           calc(env(safe-area-inset-bottom) + var(--space-3));
}
.foto-shikues img {
  max-width: 100%;
  max-height: 100%;
object-fit: contain;
  border-radius: var(--radius-xs);
}
.foto-mbyll {
  position: absolute;
  top: calc(env(safe-area-inset-top) + var(--space-2));
  right: var(--space-2);
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  background: var(--surface);
  color: var(--text);
  font-size: var(--text-lg);
  line-height: 1;
  cursor: pointer;
  box-shadow: var(--shadow-lg);
}
.foto-mbyll:hover { background: var(--surface-hover); }
body.foto-hapur { overflow: hidden; }
body.skedar-hapur { overflow: hidden; }
.skedar-shikues {
  position: fixed;
  inset: 0;
  z-index: 4600;
  display: flex;
  align-items: center;
  justify-content: center;
  background: color-mix(in srgb, var(--text) 82%, transparent);
  padding: calc(env(safe-area-inset-top) + var(--space-6)) var(--space-4)
           calc(env(safe-area-inset-bottom) + var(--space-4));
}
.skedar-karta {
  width: min(22rem, 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-5) var(--space-4) var(--space-4);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-lg);
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow-lg);
  text-align: center;
}
.skedar-ikona { font-size: var(--text-3xl); color: var(--primary); line-height: 1; }
.skedar-emri { font-weight: 700; overflow-wrap: anywhere; }
.skedar-gjendja { font-size: var(--text-sm); color: var(--muted); }
.skedar-gjendja.is-error { color: var(--danger); }
.skedar-karta .btn { margin-top: var(--space-2); }
.skedar-shenim { font-size: var(--text-xs); color: var(--muted); }
.ndryshim-pikat {
  list-style: none;
  margin: 0;
  padding: var(--space-3) var(--space-4);
  display: grid;
  gap: var(--space-2);
}
.ndryshim-pikat li {
  display: flex;
  align-items: baseline;
  gap: var(--space-3);
  color: var(--text);
}
.ndryshim-pikat .chip { flex: 0 0 6.5rem; justify-content: center; }
.tm-presence { font-variant-numeric: tabular-nums; }
.tm-shell {
  display: flex;
  gap: var(--space-4);
  height: calc(100vh - var(--topbar-h) - var(--bottomnav-h) - 4.5rem);
  height: calc(100dvh - var(--topbar-h) - var(--bottomnav-h) - 4.5rem);
  min-height: 24rem;
}
.tm-sidebar {
  width: 340px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.tm-sidebar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--border);
  background: var(--surface-muted);
  flex-shrink: 0;
}
.tm-sidebar-title { display: flex; align-items: center; gap: var(--space-2); font-weight: 700; font-size: var(--text-base); }
.chat-access-list {
  max-height: 15rem;
  overflow-y: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: var(--space-1);
}
.chat-access-row {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-sm);
  cursor: pointer;
}
.chat-access-row:hover { background: var(--surface-muted); }
.chat-access-name { flex: 1; font-size: var(--text-sm); }
.chat-access-note { font-size: var(--text-2xs); color: var(--muted); }
.chat-access-row.is-locked { cursor: default; }
.chat-access-row.is-locked .chat-access-name { color: var(--muted); }
.tm-sidebar-search {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin: var(--space-3) var(--space-3) var(--space-1-5);
  padding: var(--space-1-5) var(--space-3);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-pill);
  color: var(--muted);
  background: var(--surface);
  flex-shrink: 0;
  transition: border-color var(--dur-2) var(--ease-out), box-shadow var(--dur-2) var(--ease-out);
}
.tm-sidebar-search:focus-within {
  border-color: var(--tm-accent);
  box-shadow: 0 0 0 var(--ring-w-lg) var(--tm-accent-line);
}
.tm-sidebar-search input {
  border: 0; background: transparent; outline: none;
  color: var(--text); font-size: var(--text-sm); width: 100%;
}
.tm-sidebar-search input::placeholder { color: var(--faint); }
.tm-sidebar-filters { margin: var(--space-0) var(--space-3) var(--space-2); gap: var(--space-1-5); flex-shrink: 0; }
.tm-sidebar-filters .tm-filter { padding: var(--space-1) var(--space-2); font-size: var(--text-xs); }
.tm-sidebar-filters .tm-filter > .bi { display: none; }
.tm-sidebar-list { flex: 1; overflow-y: auto; }
.tm-main { flex: 1; min-width: 0; display: flex; }
.tm-main > .tm-chat, .tm-main > .tm-empty-main, .tm-main > .tm-overview,
.tm-main > .tm-layout {
  flex: 1;
  width: 100%;
min-width: 0;
}
.tm-shell .tm-chat, .tm-shell .tm-panel { height: 100%; }
.tm-shell .tm-header { flex-wrap: wrap; row-gap: var(--space-2); }
.tm-shell .tm-header .tm-search { flex: 1 1 7rem; min-width: 0; }
.tm-empty-main {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: var(--space-1-5);
  padding: var(--space-6);
  background: var(--surface);
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius-lg);
  color: var(--muted);
}
.tm-empty-main-icon { font-size: var(--text-3xl); color: var(--tm-accent); opacity: .55; }
.tm-empty-main-title { font-weight: 700; font-size: var(--text-base); color: var(--text); }
.tm-empty-main-text { font-size: var(--text-sm); max-width: 22rem; }
.tm-back {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px; height: 34px;
  border-radius: var(--radius-sm);
  color: var(--text);
  text-decoration: none;
  flex-shrink: 0;
}
.tm-back:hover { background: var(--surface-hover); color: var(--text); }
.tm-people { display: flex; flex-direction: column; }
.tm-person {
  position: relative;
  display: flex;
  align-items: stretch;
  border-bottom: 1px solid var(--border);
  transition: background var(--dur-1) var(--ease-out);
}
.tm-person:last-child { border-bottom: 0; }
.tm-person:hover { background: var(--surface-hover); }
.tm-person.has-unread { background: var(--tm-accent-faint); box-shadow: inset var(--rail) 0 0 var(--tm-accent); }
.tm-person.active { background: var(--tm-accent-soft); box-shadow: inset var(--rail) 0 0 var(--tm-accent); }
.tm-person.active:hover { background: var(--tm-accent-soft); }
.tm-await-ic { color: var(--tm-accent); font-size: var(--text-xs); }
.tm-await-ic.is-warm { color: var(--warning); }
.tm-await-ic.is-old  { color: var(--danger); }
.tm-person-link {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  flex: 1;
  min-width: 0;
padding: var(--space-2) var(--space-1) var(--space-2) var(--space-4);
  text-decoration: none;
  color: inherit;
}
.tm-person-link:hover { color: inherit; }
.tm-person-avatar { position: relative; flex-shrink: 0; }
.tm-dot {
  position: absolute;
  right: -1px;
  bottom: -1px;
  width: 10px;
  height: 10px;
  border-radius: var(--radius-round);
  background: var(--faint);
  border: 2px solid var(--surface);
}
.tm-dot.on { background: var(--success-fill); }
.tm-person-main { flex: 1; min-width: 0; }
.tm-person-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: var(--space-2);
}
.tm-person-name {
  font-weight: 600; font-size: var(--text-sm);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  min-width: 0;
}
.tm-person-role { margin-right: auto; }
.tm-person.has-unread .tm-person-name { font-weight: 700; }
.tm-pin-ic { color: var(--tm-accent); font-size: var(--text-2xs); margin-right: var(--space-0); }
.tm-person-role {
  font-size: var(--text-2xs);
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--muted);
  background: var(--surface-muted);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  padding: 0 var(--space-1-5);
  white-space: nowrap;
  flex-shrink: 0;
}
.tm-person-time { font-size: var(--text-2xs); color: var(--faint); white-space: nowrap; flex-shrink: 0; }
.tm-person-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-2);
  margin-top: var(--space-0);
}
.tm-person-preview {
  font-size: var(--text-xs);
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
}
.tm-person.has-unread .tm-person-preview { color: var(--text); font-weight: 500; }
.tm-person-badges { display: flex; align-items: center; gap: var(--space-1); flex-shrink: 0; }
.tm-muted-ic { color: var(--faint); font-size: var(--text-xs); }
.tm-person-unread {
  background: var(--tm-accent);
  color: var(--primary-contrast);
  font-size: var(--text-2xs);
  font-weight: 700;
  padding: var(--space-0) var(--space-1-5);
  border-radius: var(--radius-pill);
  min-width: 1.2rem;
  text-align: center;
}
.tm-menu { display: flex; align-items: center; flex-shrink: 0; padding-right: var(--space-1); }
.tm-menu-btn {
  border: 0;
  background: transparent;
  color: var(--muted);
  width: 28px; height: 28px;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: var(--text-md);
  line-height: 1;
}
.tm-menu-btn:hover,
.tm-menu-btn[aria-expanded="true"] { background: var(--surface-hover); color: var(--text); }
.tm-menu-pop {
  position: fixed;
  z-index: 1090;
  min-width: 196px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
  padding: var(--space-1);
}
.tm-menu-pop[hidden] { display: none; }
.tm-menu-form { margin: 0; }
.tm-menu-item {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  width: 100%;
  border: 0;
  background: transparent;
  color: var(--text);
  padding: var(--space-2);
  border-radius: var(--radius-sm);
  font-size: var(--text-sm);
  font-weight: 500;
  text-align: left;
  cursor: pointer;
}
.tm-menu-item i { font-size: var(--text-sm); width: 1rem; text-align: center; color: var(--muted); }
.tm-menu-item:hover { background: var(--surface-hover); }
.tm-menu-item.danger { color: var(--danger); }
.tm-menu-item.danger i { color: var(--danger); }
.tm-menu-item.danger:hover { background: var(--danger-soft); }
.tm-menu-sep { height: 1px; background: var(--border); margin: var(--space-1); }
.tm-people-empty { padding: var(--space-5) var(--space-4); text-align: center; color: var(--muted); font-size: var(--text-sm); }
.tm-avatar.is-group {
  border-radius: var(--radius);
  background: var(--tm-accent-soft);
  color: var(--tm-accent);
}
.tm-person.is-group .tm-person-link { padding-top: var(--space-3); padding-bottom: var(--space-3); }
.tm-sidebar-list .group-nav-title { padding-left: var(--space-4); }
.tm-list-foot { padding: var(--space-2) var(--space-3) var(--space-3); }
.tm-sidebar-search .tm-search-clear { font-size: var(--text-sm); padding: 0; }
.tm-sidebar-search input::-webkit-search-cancel-button,
.tm-sidebar-search input::-webkit-search-decoration { -webkit-appearance: none; appearance: none; }
.tm-hits { border-bottom: 1px solid var(--border); background: var(--surface-muted); }
.tm-hits[hidden] { display: none; }
.tm-hits-head {
  padding: var(--space-2) var(--space-3) var(--space-1-5);
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--muted);
}
.tm-hit-group { padding: 0 0 var(--space-1-5); }
.tm-hit-who {
  display: flex;
  align-items: center;
  gap: var(--space-1-5);
  padding: var(--space-1) var(--space-3);
}
.tm-hit-name { font-size: var(--text-xs); font-weight: 700; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tm-hit-count {
  margin-left: auto;
  font-size: var(--text-2xs);
  color: var(--muted);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  padding: 0 var(--space-1-5);
  flex-shrink: 0;
}
.tm-hit {
  display: block;
  padding: var(--space-1) var(--space-3) var(--space-1-5) var(--space-5);
  color: var(--text);
  text-decoration: none;
  border-left: 2px solid transparent;
}
.tm-hit:hover { background: var(--surface-hover); border-left-color: var(--tm-accent); color: var(--text); }
.tm-hit-text {
  font-size: var(--text-xs);
  line-height: 1.35;
display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.tm-hit-mine { color: var(--muted); }
.tm-hit-mark {
  background: var(--warning-soft);
  color: inherit;
  padding: 0 var(--space-0);
  border-radius: var(--radius-xs);
}
.tm-hit-time { font-size: var(--text-2xs); color: var(--faint); margin-top: var(--space-0); }
.tm-hit-more { padding: var(--space-0) var(--space-3) var(--space-1) var(--space-5); font-size: var(--text-2xs); color: var(--faint); font-style: italic; }
.tm-hit-person { padding: 0; }
.tm-hit-person .tm-hit-who { padding: var(--space-1) var(--space-3); }
.tm-hit-role {
  margin-left: auto;
  font-size: var(--text-2xs);
  color: var(--muted);
  flex-shrink: 0;
}
.tm-overview {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  overflow-y: auto;
  padding: var(--space-0) var(--space-0) var(--space-4);
}
.tm-stale {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-1-5) var(--space-3);
  border: 1px solid var(--tm-accent-line);
  background: var(--tm-accent-soft);
  border-radius: var(--radius-sm);
  color: var(--tm-accent);
  font-size: var(--text-xs);
  font-weight: 600;
  text-decoration: none;
}
.tm-stale[hidden] { display: none; }
.tm-stale:hover { background: var(--tm-accent-line); color: var(--text); }
.tm-ov-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-4);
  flex-wrap: wrap;
  color: var(--ground-ink);
}
.tm-ov-title {
  font-family: 'Inter Variable', Inter, sans-serif;
  font-size: var(--text-xl);
  font-weight: 700;
  letter-spacing: -.02em;
  margin: 0;
}
.tm-ov-sub { margin: var(--space-0) 0 0; font-size: var(--text-sm); color: var(--ground-ink-muted); }
.tm-ov-actions { display: flex; gap: var(--space-1-5); flex-wrap: wrap; }
.tm-ov-stats { grid-template-columns: repeat(auto-fit, minmax(min(8.5rem, 100%), 1fr)); gap: var(--space-2); margin-bottom: 0; }
.tm-ov-stats .stat-card { padding: var(--space-3) var(--space-4); }
.tm-ov-stats .stat-icon { align-self: flex-start; }
.tm-ov-pair { display: flex; gap: var(--space-3); }
.tm-ov-pair i { opacity: .75; }
.tm-ov-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(17rem, 100%), 1fr));
  gap: var(--space-3);
  align-items: stretch;
}
.tm-ov-grid > .card { display: flex; flex-direction: column; }
.tm-ov-grid > .card > .card-body { flex: 1; }
.tm-ov-card { margin-bottom: 0; }
.tm-ov-more {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-1-5);
  padding: var(--space-2);
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--tm-accent);
  text-decoration: none;
  border-top: 1px solid var(--border);
}
.tm-ov-more:hover { background: var(--surface-hover); color: var(--tm-accent); }
.tm-await { display: flex; flex-direction: column; }
.tm-await-row {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-4);
  border-bottom: 1px solid var(--border);
  color: inherit;
  text-decoration: none;
  box-shadow: inset var(--rail) 0 0 transparent;
  transition: background var(--dur-1) var(--ease-out);
}
.tm-await-row:last-child { border-bottom: 0; }
.tm-await-row:hover { background: var(--surface-hover); color: inherit; }
.tm-await-row.is-warm { box-shadow: inset var(--rail) 0 0 var(--warning); }
.tm-await-row.is-old { box-shadow: inset var(--rail) 0 0 var(--danger); }
.tm-await-main { flex: 1; min-width: 0; }
.tm-await-top { display: flex; align-items: baseline; justify-content: space-between; gap: var(--space-2); }
.tm-await-name { font-weight: 600; font-size: var(--text-sm); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tm-await-wait {
  font-size: var(--text-2xs);
  font-variant-numeric: tabular-nums;
  color: var(--muted);
  flex-shrink: 0;
}
.tm-await-row.is-warm .tm-await-wait { color: var(--warning); font-weight: 700; }
.tm-await-row.is-old .tm-await-wait { color: var(--danger); font-weight: 700; }
.tm-await-text {
  font-size: var(--text-xs);
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.tm-await-badges { display: flex; align-items: center; gap: var(--space-1); flex-shrink: 0; }
.tm-feed { display: flex; flex-direction: column; }
.tm-feed-row {
  display: flex;
  align-items: flex-start;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-4);
  border-bottom: 1px solid var(--border);
  color: inherit;
  text-decoration: none;
}
.tm-feed-row:last-child { border-bottom: 0; }
.tm-feed-row:hover { background: var(--surface-hover); color: inherit; }
.tm-feed-dir {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px; height: 24px;
  border-radius: var(--radius-round);
  font-size: var(--text-xs);
  flex-shrink: 0;
  margin-top: var(--space-0);
}
.tm-feed-dir.is-in { background: var(--tm-accent-soft); color: var(--tm-accent); }
.tm-feed-dir.is-out { background: var(--surface-hover); color: var(--muted); }
.tm-feed-main { flex: 1; min-width: 0; }
.tm-feed-top { display: flex; align-items: baseline; justify-content: space-between; gap: var(--space-2); }
.tm-feed-name { font-weight: 600; font-size: var(--text-sm); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tm-feed-time { font-size: var(--text-2xs); color: var(--faint); flex-shrink: 0; }
.tm-feed-more { font-size: var(--text-2xs); color: var(--faint); font-style: italic; margin-top: var(--space-0); }
.tm-feed-text {
  font-size: var(--text-xs);
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.tm-overview .mini-chart { height: 108px; gap: var(--space-1); }
.mini-bar.is-in { background: var(--tm-accent); }
.mini-bar.is-out { background: color-mix(in srgb, var(--tm-accent) 34%, transparent); }
.tm-ov-legend { display: flex; align-items: center; gap: var(--space-2); font-size: var(--text-xs); color: var(--muted); }
.tm-legend-key { display: inline-flex; align-items: center; gap: var(--space-1); }
.tm-legend-dot { width: .55rem; height: .55rem; border-radius: var(--radius-round); display: inline-block; }
.tm-legend-dot.is-in { background: var(--tm-accent); }
.tm-legend-dot.is-out { background: color-mix(in srgb, var(--tm-accent) 34%, transparent); }
.tm-newmark {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin: var(--space-4) 0 var(--space-2);
  color: var(--danger);
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .07em;
}
.tm-newmark::before, .tm-newmark::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--danger-soft);
}
.tm-msg { transition: background var(--dur-3) var(--ease-out), box-shadow var(--dur-3) var(--ease-out); }
.tm-msg.is-target {
  background: var(--warning-soft);
  box-shadow: inset var(--rail) 0 0 var(--warning);
}
@media (max-width: 768px) {
  .tm-shell {
    gap: 0;
    height: calc(100vh - var(--topbar-h) - var(--bottomnav-h) - 2.5rem);
    height: calc(100dvh - var(--topbar-h) - var(--bottomnav-h) - 2.5rem);
  }
  .tm-sidebar { width: 100%; }
.tm-shell[data-view="list"] {
    height: auto;
    min-height: 0;
    flex-direction: column;
    gap: var(--space-3);
  }
  .tm-shell[data-view="list"] .tm-sidebar-list,
  .tm-shell[data-view="list"] .tm-overview { overflow-y: visible; max-height: none; }
.tm-shell[data-view="list"] .tm-main,
  .tm-shell[data-view="list"] .tm-overview { display: contents; }
  .tm-shell[data-view="list"] .tm-stale     { order: -4; }
  .tm-shell[data-view="list"] .tm-ov-head   { order: -3; }
  .tm-shell[data-view="list"] .tm-ov-stats  { order: -2; }
  .tm-shell[data-view="list"] .tm-sidebar   { order: -1; }
  .tm-shell[data-view="list"] .tm-ov-grid,
  .tm-shell[data-view="list"] .tm-overview > .card { order: 0; }
.tm-shell[data-view="list"] .tm-empty-main { order: -1; }
}
@media (max-width: 575.98px) {
.tm-ov-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tm-ov-head { gap: var(--space-2); }
.tm-overview .mini-col { min-width: 0; }
  .tm-overview .mini-bars { gap: var(--space-0); }
  .tm-overview .mini-bar { max-width: 10px; }
  .tm-overview .mini-label { font-size: var(--text-2xs); padding-top: var(--space-1); }
  .tm-overview .mini-chart { gap: var(--space-0); }
}
.today-card { border-color: var(--primary-line); }
.today-card .card-header {
  background: var(--primary-soft);
  border-bottom-color: var(--primary-line);
}
.today-row {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  padding: var(--space-2) var(--space-4);
}
.today-time {
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  font-size: var(--text-md);
  min-width: 3.2rem;
  flex-shrink: 0;
}
.today-main { flex: 1; min-width: 0; }
.today-title { font-weight: 600; }
.today-badge { flex-shrink: 0; }
.today-row.state-past { opacity: .5; }
.today-row.state-past .today-title { text-decoration: line-through; }
.today-row.state-soon { background: var(--warning-soft); }
.today-row.state-ongoing {
  background: var(--success-soft);
  box-shadow: inset var(--rail) 0 0 var(--success);
}
.today-row.state-now {
  background: var(--danger-soft);
  box-shadow: inset var(--rail) 0 0 var(--danger);
}
@media (max-width: 576px) {
  .today-row { flex-wrap: wrap; gap: var(--space-1-5); }
  .today-time { min-width: auto; }
}
.tm-layout { display: block; }
.tm-layout.has-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 19rem;
  gap: var(--space-3);
  align-items: stretch;
}
.tm-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  height: calc(100vh - var(--topbar-h) - var(--bottomnav-h) - 5.5rem);
  height: calc(100dvh - var(--topbar-h) - var(--bottomnav-h) - 5.5rem);
  overflow: hidden;
}
.tm-panel-head {
  padding: var(--space-3);
  border-bottom: 1px solid var(--border);
  background: var(--surface-muted);
  flex-shrink: 0;
}
.tm-panel-head .min-w-0 { min-width: 0; }
.tm-panel-body { flex: 1; overflow-y: auto; padding: var(--space-3); }
.tm-stat {
  border: 1px solid var(--border);
  border-left: 3px solid var(--border-strong);
  border-radius: var(--radius-sm);
  padding: var(--space-2);
  margin-bottom: var(--space-2);
}
.tm-stat.danger { border-left-color: var(--danger); background: var(--danger-soft); }
.tm-stat.warn { border-left-color: var(--warning); background: var(--warning-soft); }
.tm-stat.ok { border-left-color: var(--success); }
.tm-stat-label {
  font-size: var(--text-2xs);
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--muted);
  font-weight: 700;
}
.tm-stat-value { font-size: var(--text-xl); font-weight: 700; line-height: 1.2; }
.tm-stat.danger .tm-stat-value { color: var(--danger); }
.tm-stat-note { font-size: var(--text-2xs); color: var(--muted); }
.tm-panel-section {
  border-top: 1px solid var(--border);
  padding-top: var(--space-2);
  margin-top: var(--space-2);
}
.tm-panel-title {
  font-size: var(--text-2xs);
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--muted);
  font-weight: 700;
  margin-bottom: var(--space-1-5);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-1-5);
}
.tm-panel-row {
  display: flex;
  justify-content: space-between;
  gap: var(--space-2);
  padding: var(--space-1) 0;
  font-size: var(--text-xs);
  color: inherit;
  text-decoration: none;
}
a.tm-panel-row:hover { color: var(--tm-accent); }
.tm-panel-row-main { min-width: 0; flex: 1; }
.tm-panel-row-side { flex-shrink: 0; font-variant-numeric: tabular-nums; }
.tm-panel-kv { font-size: var(--text-xs); word-break: break-word; }
.tm-panel-private {
  background: var(--warning-soft);
  border-radius: var(--radius-sm);
  padding: var(--space-2);
  border-top: 0;
  margin-top: var(--space-2);
}
.tm-panel-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1);
  margin-top: var(--space-3);
  padding-top: var(--space-2);
  border-top: 1px solid var(--border);
}
.tm-panel-actions .btn { font-size: var(--text-2xs); padding: var(--space-1) var(--space-2); }
@media (max-width: 1100px) {
  .tm-layout.has-panel { grid-template-columns: 1fr; }
  .tm-panel { height: auto; max-height: 26rem; }
}
@media (max-width: 1360px) {
  .tm-shell .tm-layout.has-panel { grid-template-columns: 1fr; overflow-y: auto; }
  .tm-shell .tm-layout.has-panel .tm-panel { height: auto; max-height: 26rem; }
}
.deadline-card { border-color: rgba(220, 38, 38, .25); }
.deadline-card .card-header {
  background: var(--danger-soft);
  border-bottom-color: rgba(220, 38, 38, .15);
}
.deadline-row {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}
.deadline-when {
  min-width: 3.4rem;
  flex-shrink: 0;
  text-align: center;
  font-variant-numeric: tabular-nums;
}
.deadline-main { flex: 1; min-width: 0; }
tr.deadline-row { display: table-row; }
.deadline-row.state-late { box-shadow: inset var(--rail) 0 0 var(--danger-fill-strong); background: rgba(220, 38, 38, .05); }
.deadline-row.state-urgent { box-shadow: inset var(--rail) 0 0 var(--urgent); background: var(--urgent-soft); }
.deadline-row.state-soon { box-shadow: inset var(--rail) 0 0 var(--warning-fill-strong); }
.deadline-row.state-done { opacity: .55; }
tr.deadline-row.state-late > td:first-child { border-left: 3px solid var(--danger-fill-strong); }
tr.deadline-row.state-urgent > td:first-child { border-left: 3px solid var(--urgent); }
tr.deadline-row.state-soon > td:first-child { border-left: 3px solid var(--warning-fill-strong); }
tr.deadline-row.state-late { background: rgba(220, 38, 38, .04); }
@media (max-width: 576px) {
  .deadline-row { flex-wrap: wrap; }
}
.view-toggle .btn { font-weight: 600; }
.cal-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-4);
  margin-bottom: var(--space-4);
}
.cal-title {
  font-family: 'Inter Variable', Inter, sans-serif;
  font-weight: 700;
  font-size: var(--text-lg);
  min-width: 11rem;
  text-align: center;
}
.tax-calendar {
  width: 100%;
  min-width: 44rem;
  border-collapse: separate;
  border-spacing: 0;
  table-layout: fixed;
}
.tax-calendar th {
  padding: var(--space-2);
  text-align: center;
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--muted);
  font-weight: 600;
}
.tax-cal-cell {
  vertical-align: top;
  height: 6.5rem;
  width: 14.28%;
  border: 1px solid var(--border);
  padding: var(--space-1-5);
  background: var(--surface);
}
.tax-cal-cell.out { background: var(--surface-muted); }
.tax-cal-cell.out .tax-cal-daynum { opacity: .4; }
.tax-cal-cell.today {
  outline: 2px solid var(--primary);
  outline-offset: -2px;
  background: var(--primary-soft);
}
.tax-cal-daynum { display: block; font-size: var(--text-sm); font-weight: 600; color: var(--muted); }
.tax-cal-cell.today .tax-cal-daynum { color: var(--primary); }
.tax-cal-daynum.is-link { color: var(--primary); text-decoration: none; }
.tax-cal-daynum.is-link:hover { text-decoration: underline; }
.tax-cal-daynum.is-link:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.tax-cal-item {
  display: flex;
  align-items: center;
  gap: var(--space-1-5);
  margin-top: var(--space-1);
  font-size: var(--text-xs);
  line-height: 1.2;
}
.tax-cal-item:hover .tax-cal-item-text { color: var(--primary); }
.tax-cal-item-text { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tax-cal-more {
  display: block;
  margin-top: var(--space-1);
  color: var(--faint);
  font-size: var(--text-2xs);
  text-decoration: none;
}
.tax-cal-more:hover { color: var(--primary); text-decoration: underline; }
.tax-dot {
  width: .6rem;
  height: .6rem;
  border-radius: var(--radius-round);
  flex-shrink: 0;
  display: inline-block;
}
.tax-dot.state-late   { background: var(--danger-fill-strong); }
.tax-dot.state-urgent { background: var(--urgent); }
.tax-dot.state-soon   { background: var(--warning-fill-strong); }
.tax-dot.state-ahead  { background: var(--success-fill-strong); }
.tax-dot.state-done   { background: var(--primary); }
.cal-legend {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  margin-top: var(--space-4);
  padding-top: var(--space-4);
  border-top: 1px solid var(--border);
  font-size: var(--text-xs);
  color: var(--muted);
}
.cal-legend span { display: inline-flex; align-items: center; gap: var(--space-1-5); }
.cal-legend .cal-legend-sep { margin-left: var(--space-2); padding-left: var(--space-4); border-left: 1px solid var(--border); }
.dek-cover { display: grid; gap: var(--space-2); }
.dek-cover-row {
  display: grid;
  grid-template-columns: minmax(6rem, 1.4fr) auto minmax(4rem, 1fr) auto;
  grid-template-areas: 'name period bar num' 'note note note note';
  align-items: center;
  gap: var(--space-1-5) var(--space-3);
  padding: var(--space-2) var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  color: inherit;
  text-decoration: none;
  transition: border-color var(--dur-2) var(--ease-out), box-shadow var(--dur-2) var(--ease-out);
}
.dek-cover-row:hover { border-color: var(--primary-line); box-shadow: var(--shadow-sm); }
.dek-cover-row:focus-visible { outline: 2px solid var(--primary); outline-offset: 1px; }
.dek-cover-name {
  grid-area: name;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.dek-cover-period {
  grid-area: period;
  font-size: var(--text-xs);
  font-variant-numeric: tabular-nums;
  color: var(--muted);
}
.dek-cover-bar {
  grid-area: bar;
  height: .5rem;
  border-radius: var(--radius-pill);
  background: var(--surface-muted);
  box-shadow: inset 0 0 0 var(--hairline) var(--border);
  overflow: hidden;
  position: relative;
}
.dek-cover-bar::before {
  content: '';
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--bar, 0%);
  border-radius: inherit;
  background: var(--primary);
}
.dek-cover-num {
  grid-area: num;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  font-size: var(--text-sm);
}
.dek-cover-note { grid-area: note; font-size: var(--text-xs); color: var(--faint); }
.dek-cover-row.state-late .dek-cover-bar::before { background: var(--danger-fill-strong); }
.dek-cover-row.state-urgent .dek-cover-bar::before { background: var(--urgent); }
.dek-cover-row.state-soon .dek-cover-bar::before { background: var(--warning-fill-strong); }
.dek-cover-row.state-done .dek-cover-bar::before { background: var(--success-fill-strong); }
.dek-cover-row.state-late { border-color: var(--danger-fill); }
.dek-cover-row.state-done { opacity: .7; }
.dek-load {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  align-items: end;
  gap: var(--space-0);
grid-template-rows: 3.25rem;
}
.dek-load-cell {
  display: block;
  height: max(2px, var(--bar, 0%));
  min-height: 2px;
  border-radius: var(--radius-xs) var(--radius-xs) 0 0;
  background: var(--success-fill-strong);
  transition: filter var(--dur-1) var(--ease-out);
}
.dek-load-cell:hover { filter: brightness(1.15); }
.dek-load-cell:focus-visible { outline: 2px solid var(--primary); outline-offset: 1px; }
.dek-load-cell.state-urgent { background: var(--urgent); }
.dek-load-cell.state-soon { background: var(--warning-fill-strong); }
.dek-load-cell.is-empty { background: var(--border); }
.dek-load-foot {
  display: flex;
  justify-content: space-between;
  margin-top: var(--space-1-5);
  font-size: var(--text-xs);
  color: var(--faint);
  font-variant-numeric: tabular-nums;
}
.page-aside .dek-signals { grid-template-columns: repeat(auto-fit, minmax(8rem, 1fr)); }
.dek-pick { width: 2.25rem; text-align: center; }
.dek-pick .form-check-input { margin: 0; vertical-align: middle; }
.dek-bulk-bar {
  position: sticky;
  bottom: var(--space-3);
  z-index: 3;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  margin-top: var(--space-3);
  padding: var(--space-3);
  border: 1px solid var(--primary-line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-md);
}
.dek-bulk-bar[hidden] { display: none; }
.dek-bulk-count { font-size: var(--text-sm); color: var(--muted); }
.dek-bulk-count strong { font-variant-numeric: tabular-nums; color: var(--text); }
.dek-bulk-ref { max-width: 12rem; }
.dek-ref {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.dek-frozen-toggle {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  margin-top: var(--space-1);
  padding: 0;
  border: 0;
  background: none;
  color: var(--primary);
  font-size: var(--text-xs);
}
.dek-frozen-toggle:hover { text-decoration: underline; }
.dek-frozen-toggle:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}
.dek-frozen {
  min-width: 13rem;
  margin-top: var(--space-1);
  padding: var(--space-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-muted);
  font-size: var(--text-xs);
  font-variant-numeric: tabular-nums;
}
.dek-frozen-row {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: var(--space-2);
  color: var(--muted);
}
.dek-frozen-row > span + span { min-width: 4rem; text-align: right; }
.dek-frozen-row.is-head { color: var(--faint); }
.dek-frozen-row.is-total {
  margin-top: var(--space-1);
  padding-top: var(--space-1);
  border-top: 1px solid var(--border);
  color: var(--text);
  font-weight: 600;
}
.dek-frozen-foot { margin-top: var(--space-1); color: var(--faint); }
.dek-actions {
  width: 14rem;
  max-width: 100%;
  margin-top: var(--space-2);
  margin-left: auto;
  padding: var(--space-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-muted);
  text-align: left;
  white-space: normal;
}
.dek-actions > form + form { margin-top: var(--space-2); }
.dek-file-label {
  display: block;
  margin-bottom: var(--space-1);
  color: var(--muted);
  font-size: var(--text-xs);
}
@media (max-width: 575.98px) {
.dek-bulk-bar { position: static; }
  .dek-cover-row { grid-template-columns: 1fr auto; grid-template-areas: 'name num' 'period num' 'bar bar' 'note note'; }
}
.cal-event {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  margin-top: var(--space-1);
  padding: var(--space-0) var(--space-1-5);
  border-radius: var(--radius-sm);
  font-size: var(--text-xs);
  line-height: 1.25;
  background: var(--surface-muted);
  border-left: 3px solid var(--faint);
  overflow: hidden;
}
.cal-event-time { font-weight: 700; flex-shrink: 0; font-variant-numeric: tabular-nums; }
.cal-event-text { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cal-event.state-now      { border-left-color: var(--danger-fill-strong); background: rgba(220, 38, 38, .10); }
.cal-event.state-today    { border-left-color: var(--primary); background: var(--primary-soft); }
.cal-event.state-soon     { border-left-color: var(--warning-fill-strong); background: rgba(217, 119, 6, .10); }
.cal-event.state-upcoming { border-left-color: var(--success-fill-strong); background: var(--success-soft); }
.cal-event.state-past     { border-left-color: var(--faint); opacity: .6; }
.cal-event.is-afat {
  background: transparent;
  border-left-style: dashed;
  border-left-color: var(--border);
}
.cal-event.is-afat:hover .cal-event-text { color: var(--primary); }
.cal-swatch {
  width: .7rem;
  height: .7rem;
  border-radius: var(--radius-xs);
  flex-shrink: 0;
  display: inline-block;
  background: var(--faint);
}
.cal-swatch.state-now      { background: var(--danger-fill-strong); }
.cal-swatch.state-today    { background: var(--primary); }
.cal-swatch.state-soon     { background: var(--warning-fill-strong); }
.cal-swatch.state-upcoming { background: var(--success-fill-strong); }
.cal-swatch.state-past     { background: var(--faint); }
.alert { border-radius: var(--radius); border: 1px solid transparent; }
.alert-danger  { background: var(--danger-soft);  color: var(--danger);  border-color: rgba(220,38,38,.22); }
.alert-warning { background: var(--warning-soft); color: var(--warning); border-color: rgba(245,158,11,.25); }
.alert-success { background: var(--success-soft); color: var(--success); border-color: rgba(16,185,129,.25); }
.alert-info    { background: var(--info-soft);    color: var(--info);    border-color: rgba(14,165,233,.25); }
.alert-secondary { background: var(--surface-muted); color: var(--muted); border-color: var(--border); }
.alert .alert-link { color: inherit; font-weight: 700; }
.alert-heading { color: inherit; }
.deadline-banner {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  padding: var(--space-3) var(--space-4);
  margin-bottom: var(--space-4);
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid rgba(245,158,11,.28);
  color: var(--text);
}
.deadline-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  flex-shrink: 0;
  border-radius: var(--radius);
  background: linear-gradient(135deg,var(--warning-fill-strong),var(--warning-fill));
  color: #fff;
  font-size: var(--text-lg);
  box-shadow: var(--glow-warning);
}
.deadline-title { font-weight: 700; line-height: 1.35; }
.deadline-text { font-size: var(--text-sm); color: var(--muted); margin-top: var(--space-0); }
.deadline-copy { flex: 1; min-width: 0; }
.deadline-banner-soon { border-color: var(--warning-fill-strong); }
.deadline-banner-late { border-color: var(--danger-fill); }
.deadline-banner-late .deadline-icon {
  background: linear-gradient(135deg,var(--danger-fill-strong),var(--danger-fill));
  box-shadow: var(--glow-danger);
}
.check-card { border-top: 3px solid var(--border); }
.check-card-critical { border-top-color: var(--danger-fill); }
.check-card-warning { border-top-color: var(--warning-fill); }
.check-card-clear { border-top-color: var(--success-fill); }
.check-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-2);
}
.check-item {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  padding: var(--space-3);
  border-radius: var(--radius-sm);
  background: var(--surface-hover);
  border-left: 3px solid var(--border);
  text-decoration: none;
  color: inherit;
  transition: background var(--dur-2) var(--ease-out), transform var(--dur-2) var(--ease-out);
}
.check-item:hover { background: var(--surface-muted); color: inherit; transform: translateX(2px); }
.check-critical { border-left-color: var(--danger-fill); }
.check-warning { border-left-color: var(--warning-fill); }
.check-info { border-left-color: var(--primary); }
.check-icon {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 1.9rem;
  height: 1.9rem;
  border-radius: var(--radius-sm);
  background: var(--surface);
  font-size: var(--text-md);
}
.check-critical .check-icon { color: var(--danger); }
.check-warning .check-icon { color: var(--warning); }
.check-info .check-icon { color: var(--primary-text); }
.check-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: var(--space-0); }
.check-title { font-weight: 600; font-size: var(--text-md); }
.check-count {
  display: inline-block;
  min-width: 1.4rem;
  padding: 0 var(--space-1-5);
  margin-left: var(--space-1);
  border-radius: var(--radius-pill);
  background: var(--surface);
  border: 1px solid var(--border);
  font-size: var(--text-xs);
  text-align: center;
  font-variant-numeric: tabular-nums;
}
.check-text { font-size: var(--text-sm); color: var(--muted); line-height: 1.35; }
.check-sample {
  font-size: var(--text-xs);
  color: var(--faint);
  font-variant-numeric: tabular-nums;
}
.check-go { color: var(--faint); align-self: center; font-size: var(--text-sm); }
.check-item.check-on {
  background: var(--surface-muted);
  box-shadow: inset 0 0 0 var(--hairline) var(--primary);
}
.check-item.check-on .check-go { color: var(--primary-text); }
.vat-now {
  display: grid;
  grid-template-columns: minmax(min(24rem, 100%), 1.3fr) minmax(min(19rem, 100%), 1fr);
  gap: var(--space-4);
  align-items: stretch;
  margin-bottom: var(--space-4);
}
@media (max-width: 62rem) {
  .vat-now { grid-template-columns: 1fr; }
}
.vat-now > .deadline-banner { margin-bottom: 0; }
.vat-file { margin-bottom: 0; }
.vat-file > .card-body { display: flex; flex-direction: column; justify-content: center; }
.filter-quick.vat-quick { margin-bottom: 0; margin-top: var(--space-3); }
.vat-boxes {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(22rem, 100%), 1fr));
  gap: var(--space-4);
  align-items: start;
}
.vat-box-group { min-width: 0; }
.vat-box {
  display: grid;
  grid-template-columns: 2.6rem minmax(0, 1fr) auto;
  align-items: baseline;
  column-gap: var(--space-2);
  padding: var(--space-1-5) 0;
  border-bottom: 1px solid var(--border);
}
.vat-box:last-child { border-bottom: 0; }
.vat-box-no {
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--faint);
  font-variant-numeric: tabular-nums;
}
.vat-box-label {
  font-size: var(--text-sm);
  color: var(--muted);
  line-height: 1.3;
  min-width: 0;
}
.vat-box-count {
  display: block;
  font-size: var(--text-xs);
  color: var(--faint);
  font-variant-numeric: tabular-nums;
}
.vat-box-value { font-size: var(--text-sm); }
.vat-box-total {
  border-bottom: 0;
  border-top: 1px solid var(--border);
  margin-top: var(--space-1);
  padding-top: var(--space-2);
}
.vat-box-total .vat-box-label { color: var(--text); font-weight: 600; }
.vat-box-total .vat-box-value { font-size: var(--text-md); font-weight: 700; }
.vat-box:has(.vat-box-filed) {
  grid-template-columns: 2.6rem minmax(0, 1fr) auto auto 3.2rem;
}
.vat-box-filed { font-size: var(--text-sm); text-align: right; min-width: 4.5rem; }
.vat-box-delta { font-size: var(--text-sm); text-align: right; }
.vat-box-diff .vat-box-no { color: var(--danger); }
.vat-manual { display: grid; gap: var(--space-2); }
.vat-manual-row {
  display: grid;
  grid-template-columns: minmax(0, 11rem) minmax(0, 1fr);
  column-gap: var(--space-3);
  align-items: baseline;
}
@media (max-width: 48rem) {
  .vat-manual-row { grid-template-columns: 1fr; }
}
.vat-manual-boxes {
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--primary-text);
  font-variant-numeric: tabular-nums;
}
.vat-manual-body { min-width: 0; }
.vat-manual-title { display: block; font-size: var(--text-sm); font-weight: 600; }
.vat-manual-why {
  display: block;
  font-size: var(--text-xs);
  color: var(--muted);
  line-height: 1.4;
}
.text-primary { color: var(--primary) !important; }
.border-primary { border-color: var(--primary) !important; }
.btn-link {
  --bs-btn-color: var(--primary-text);
  --bs-btn-hover-color: var(--primary);
}
.progress { background-color: var(--surface-muted); border-radius: var(--radius-pill); }
.progress-bar { background-color: var(--primary); background-image: var(--grad-primary); }
.nav-pills .nav-link { color: var(--muted); }
.nav-pills .nav-link.active {
  background: var(--grad-primary);
  color: #fff;
}
.nav-tabs { border-bottom-color: var(--border); }
.nav-tabs .nav-link { color: var(--muted); }
.nav-tabs .nav-link:hover { border-color: var(--border) var(--border) transparent; }
.nav-tabs .nav-link.active {
  color: var(--primary-text);
  background-color: transparent;
  border-color: var(--border) var(--border) var(--surface);
}
.folder-tab {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1-5);
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--muted);
  border-radius: var(--radius) var(--radius) var(--radius-sm) var(--radius-sm);
  font-weight: 600;
  transition: color var(--dur-2) var(--ease-out), border-color var(--dur-2) var(--ease-out), background var(--dur-2) var(--ease-out);
}
.folder-tab:hover {
  color: var(--text);
  border-color: var(--accent);
}
.folder-tab.active {
  background: var(--accent-soft);
  border-color: var(--accent);
  color: var(--accent);
}
.folder-tab .chip { border-color: transparent; }
.folder-tab.empty { opacity: .6; }
.folder-tab.empty:hover { opacity: 1; }
.kpi-card { cursor: pointer; }
.kpi-card.kpi-active {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.history-diff { font-size: var(--text-sm); }
.history-diff td, .history-diff th { vertical-align: top; word-break: break-word; }
.history-diff-changed { background: var(--warning-soft); }
.history-diff-changed .history-old {
  color: var(--danger);
  text-decoration: line-through;
  text-decoration-color: rgba(220, 38, 38, .4);
}
.history-diff-changed .history-new { color: var(--success); font-weight: 600; }
.hist-only-changed .history-diff-same { display: none; }
.hist-spark {
  display: flex;
  align-items: flex-end;
  gap: var(--space-0);
  height: 68px;
}
.hist-spark-col {
  flex: 1 1 0;
  display: flex;
  align-items: flex-end;
  height: 100%;
  min-width: 0;
  border-radius: var(--radius-xs);
  transition: background var(--dur-2) var(--ease-out);
}
.hist-spark-col:hover { background: var(--surface-muted); }
.hist-spark-col:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.hist-spark-bar {
  display: block;
  width: 100%;
  min-height: 3px;
  border-radius: var(--radius-xs) var(--radius-xs) 0 0;
  background: var(--border);
}
.hist-spark-col.has-hits .hist-spark-bar { background: var(--grad-primary); }
.hist-spark-axis {
  display: flex;
  justify-content: space-between;
  gap: var(--space-2);
  margin-top: var(--space-2);
  font-size: var(--text-xs);
  color: var(--faint);
}
.hist-signals,
.io-signals,
.dek-signals,
.cl-signals,
.inv-signals {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
  gap: var(--space-3);
}
.hist-signal,
.io-signal,
.dek-signal,
.cl-signal,
.inv-signal {
  padding: var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.hist-signal.is-warm,
.io-signal.is-warm,
.dek-signal.is-warm,
.cl-signal.is-warm,
.inv-signal.is-warm { border-color: var(--warning-fill); }
.hist-signal.is-hot,
.io-signal.is-hot,
.dek-signal.is-hot,
.cl-signal.is-hot,
.inv-signal.is-hot { border-color: var(--danger-fill); }
.hist-signal-top,
.io-signal-top,
.dek-signal-top,
.cl-signal-top,
.inv-signal-top {
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: var(--space-1-5);
}
.hist-signal-value,
.io-signal-value,
.dek-signal-value,
.cl-signal-value,
.inv-signal-value {
  font-family: 'Sora Variable', 'Inter Variable', Inter, sans-serif;
  font-size: var(--text-2xl);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
  margin-top: var(--space-1);
}
.hist-signal-value a,
.cl-signal-note a { color: inherit; text-decoration: none; }
.hist-signal-value a:hover,
.cl-signal-note a:hover { text-decoration: underline; }
.hist-signal-delta { font-size: var(--text-sm); font-weight: 600; color: var(--muted); }
.hist-signal-delta.up { color: var(--warning-fill); }
.hist-signal-delta.down { color: var(--success-fill); }
.hist-signal-note,
.io-signal-note,
.dek-signal-note,
.cl-signal-note,
.inv-signal-note {
  font-size: var(--text-xs);
  color: var(--faint);
  margin-top: var(--space-1);
}
.hist-signal-list,
.io-evidence,
.dek-evidence,
.cl-evidence { margin-top: var(--space-3); }
.hist-signal-list-title,
.io-evidence-title,
.dek-evidence-title,
.cl-evidence-title {
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--muted);
}
.hist-hours { border-top: 1px solid var(--border); padding-top: var(--space-3); }
.hist-hours-title { font-size: var(--text-xs); font-weight: 600; margin-bottom: var(--space-2); }
.hist-hours-grid {
  display: flex;
  align-items: flex-end;
  gap: var(--space-0);
  height: 46px;
}
.hist-hour {
  flex: 1 1 0;
  display: flex;
  align-items: flex-end;
  height: 100%;
  min-width: 0;
}
.hist-hour-bar {
  display: block;
  width: 100%;
  min-height: 2px;
  border-radius: var(--radius-xs) var(--radius-xs) 0 0;
  background: var(--grad-primary);
}
.hist-hour.is-night .hist-hour-bar {
  background: linear-gradient(180deg, var(--warning-fill-strong), var(--warning-fill));
}
.hist-hours-axis {
  display: flex;
  justify-content: space-between;
  margin-top: var(--space-1-5);
  font-size: var(--text-xs);
  color: var(--faint);
}
.hist-matrix td, .hist-matrix th { font-size: var(--text-sm); }
.hist-matrix td.text-end { font-variant-numeric: tabular-nums; }
.hist-matrix a { text-decoration: none; }
.hist-matrix a:hover { text-decoration: underline; }
.hist-entry mark {
  background: color-mix(in srgb, var(--primary) 22%, transparent);
  color: inherit;
  border-radius: var(--radius-xs);
  padding: 0 .1em;
}
.hist-facet-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-1-5);
}
.hist-facet-label {
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--muted);
  min-width: 5.5rem;
}
.hist-facet-count {
  margin-left: var(--space-1-5);
  padding: 0 var(--space-1);
  border-radius: var(--radius-pill);
  background: var(--surface-muted);
  font-size: var(--text-2xs);
  font-weight: 700;
}
.chip-primary .hist-facet-count { background: rgba(255, 255, 255, .35); }
.hist-quick-summary {
  cursor: pointer;
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--muted);
  list-style: none;
}
.hist-quick-summary::-webkit-details-marker { display: none; }
.hist-quick-summary::before {
  content: "\f285";
  font-family: "bootstrap-icons";
  margin-right: var(--space-1-5);
  font-size: .7em;
  display: inline-block;
  transition: transform var(--dur-2) var(--ease-out);
}
.hist-quick[open] .hist-quick-summary::before { transform: rotate(90deg); }
.hist-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-1-5);
}
.hist-day {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin: var(--space-4) 0 var(--space-2);
  padding: var(--space-1) 0;
  background: var(--surface);
}
.hist-day:first-child { margin-top: 0; }
.hist-day-label {
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--muted);
}
.hist-day-count {
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--faint);
  padding: var(--space-0) var(--space-1-5);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
}
.hist-day::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}
.hist-tone-danger::before  { border-color: var(--danger); }
.hist-tone-success::before { border-color: var(--success); }
.hist-tone-warning::before { border-color: var(--warning); }
.hist-tone-info::before    { border-color: var(--info); }
.hist-entry-main { min-width: 0; }
.hist-entry-side { flex-shrink: 0; }
.hist-entry-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-3);
}
.hist-link {
  font-size: var(--text-xs);
  color: var(--muted);
  text-decoration: none;
  border-bottom: 1px dashed var(--border);
}
.hist-link:hover { color: var(--primary); border-bottom-color: var(--primary-line); }
.hist-pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-4);
  margin-top: var(--space-4);
}
.hist-pager-mid { font-size: var(--text-sm); font-weight: 600; color: var(--muted); }
.hist-pagesize {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-1-5);
  margin-top: var(--space-2);
}
.dropdown-menu.show { animation: dropIn var(--dur-2) var(--ease-out); }
@keyframes dropIn {
  from { opacity: 0; transform: translateY(-4px); }
  to   { opacity: 1; transform: none; }
}
@media (min-width: 992px) {
  body.sidebar-mini .app-sidebar { width: 84px; }
  body.sidebar-mini .app-sidebar .brand-word,
  body.sidebar-mini .app-sidebar .sidebar-section-title,
  body.sidebar-mini .app-sidebar .sidebar-badge,
  body.sidebar-mini .app-sidebar .sidebar-user-name,
  body.sidebar-mini .app-sidebar .sidebar-user-role { display: none; }
  body.sidebar-mini .app-sidebar .nav-link {
    font-size: 0;
    justify-content: center;
    gap: 0;
    padding: var(--space-2) var(--space-1-5);
  }
  body.sidebar-mini .app-sidebar .nav-link i { font-size: var(--text-lg); }
  body.sidebar-mini .sidebar-head { flex-direction: column; gap: var(--space-2); padding: var(--space-3) var(--space-2); }
  body.sidebar-mini .sidebar-user { justify-content: center; padding: var(--space-2) var(--space-1); }
  body.sidebar-mini .sidebar-user > .icon-btn { display: none; }
  body.sidebar-mini #sidebar-collapse-btn i { transform: rotate(180deg); }
}
#sidebar-collapse-btn i { transition: transform var(--dur-2) var(--ease-out); }
.chart {
  display: flex;
  align-items: flex-end;
  gap: var(--space-2);
  height: 200px;
  padding-top: var(--space-2);
}
.chart-col {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  height: 100%;
}
.chart-bars {
  flex: 1;
  width: 100%;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: var(--space-1);
}
.chart-bar {
  width: clamp(14px, 40%, 30px);
  min-height: 3px;
  border-radius: var(--radius-xs) var(--radius-xs) 0 0;
  transition: filter var(--dur-2) var(--ease-out), transform var(--dur-2) var(--ease-out);
  animation: barGrow var(--dur-4) var(--ease-out) both;
  transform-origin: bottom;
}
.chart-bar:hover { filter: brightness(1.12); }
@keyframes barGrow { from { transform: scaleY(0); } to { transform: scaleY(1); } }
.chart-col:nth-child(2) .chart-bar { animation-delay: .06s; }
.chart-col:nth-child(3) .chart-bar { animation-delay: .12s; }
.chart-col:nth-child(4) .chart-bar { animation-delay: .18s; }
.chart-col:nth-child(5) .chart-bar { animation-delay: .24s; }
.chart-col:nth-child(6) .chart-bar { animation-delay: .3s; }
.chart-bar-sale { background: var(--grad-primary); box-shadow: var(--shadow-glow); }
.chart-bar-purchase { background: linear-gradient(180deg, #d2ab67, #b8904a); box-shadow: var(--glow-accent); }
.chart-label {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .04em;
}
.chart-legend { display: inline-flex; align-items: center; gap: var(--space-3); font-size: var(--text-xs); color: var(--muted); }
.chart-legend-item { display: inline-flex; align-items: center; gap: var(--space-1-5); font-weight: 600; }
.chart-dot { width: .6rem; height: .6rem; border-radius: var(--radius-xs); display: inline-block; }
.chart-dot-sale { background: var(--grad-primary); }
.chart-dot-purchase { background: linear-gradient(180deg, #d2ab67, #b8904a); }
.bi-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: var(--space-3);
container: bi-grid / inline-size;
}
.bi-card { min-width: 0; }
.bi-span-4 { grid-column: span 4; }
.bi-span-5 { grid-column: span 5; }
.bi-span-6 { grid-column: span 6; }
.bi-span-7 { grid-column: span 7; }
.bi-span-8 { grid-column: span 8; }
.bi-span-12 { grid-column: span 12; }
@container bi-grid (max-width: 880px) {
  .bi-span-4 { grid-column: span 6; }
.bi-span-5, .bi-span-7 { grid-column: span 6; }
  .bi-span-8 { grid-column: span 12; }
}
@container bi-grid (max-width: 660px) {
  .bi-span-4, .bi-span-5, .bi-span-6,
  .bi-span-7, .bi-span-8 { grid-column: span 12; }
}
.chart-box { position: relative; height: clamp(240px, 20cqi, 380px); }
.bi-span-4 .chart-box { height: clamp(200px, 15cqi, 280px); }
.card:not(.bi-card) > .card-body > .chart-box { height: clamp(240px, 32vh, 360px); }
.kpi-spark {
  position: relative;
  width: 100%;
  height: 40px;
  margin-top: var(--space-2);
  overflow: hidden;
animation: wipeIn var(--dur-4) var(--ease-out) both;
}
.live-point {
  position: absolute;
  left: 0;
  top: 0;
  width: var(--space-1-5);
  height: var(--space-1-5);
  margin: calc(var(--space-1-5) / -2) 0 0 calc(var(--space-1-5) / -2);
transform: translate(var(--px, 0), var(--py, 0));
  border-radius: var(--radius-round);
  background: var(--live);
  animation: livePulse var(--beat-slow) var(--ease-in-out) infinite;
  pointer-events: none;
}
@keyframes livePulse {
  0%   { box-shadow: 0 0 0 0 color-mix(in srgb, var(--live) 55%, transparent); }
  70%  { box-shadow: 0 0 0 var(--space-2) transparent; }
  100% { box-shadow: 0 0 0 0 transparent; }
}
.bi-tabs {
  position: sticky;
  bottom: 0;
  z-index: 900;
  display: flex;
  align-items: stretch;
  gap: 0;
  max-width: 100%;
  overflow-x: auto;
  margin: 0;
  padding: 0 var(--space-1-5);
  background: var(--bi-chrome);
  border: 1px solid var(--bi-line);
  border-top: 0;
  border-radius: 0 0 var(--bi-radius) var(--bi-radius);
}
.bi-tab {
  border: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: var(--bi-ink-2);
  font-size: var(--text-sm);
  font-weight: 400;
  padding: var(--space-2) var(--space-3);
  white-space: nowrap;
  cursor: pointer;
  transition: background var(--dur-1) var(--ease-out), color var(--dur-1) var(--ease-out);
}
.bi-tab:hover { color: var(--bi-ink); background: var(--bi-visual); }
.bi-tab.active {
  background: var(--bi-visual);
  color: var(--bi-ink);
  font-weight: 600;
  border-bottom-color: var(--bi-accent);
}
.bi-status {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: var(--space-1-5);
  padding: 0 var(--space-2);
  font-size: var(--text-xs);
  color: var(--bi-ink-2);
  white-space: nowrap;
}
.bi-focus-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1900;
  display: none;
  background: rgba(5,8,18,.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
body.bi-focus-open .bi-focus-backdrop { display: block; }
.bi-card.bi-focused {
  position: fixed;
  inset: 4vh 4vw;
  z-index: 1950;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-lg);
}
.bi-card.bi-focused .card-body { flex: 1; min-height: 0; }
.bi-card.bi-focused .chart-box { height: 100%; }
.cell-bar {
  background-image: linear-gradient(90deg, var(--primary-soft) var(--bar, 0%), transparent var(--bar, 0%));
  background-repeat: no-repeat;
}
.cell-bar-accent {
  background-image: linear-gradient(90deg, var(--accent-soft) var(--bar, 0%), transparent var(--bar, 0%));
}
.conc-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-2);
  margin-bottom: var(--space-4);
}
.conc-item {
  text-align: center;
  padding: var(--space-2) var(--space-1-5);
  border-radius: var(--radius-sm);
  background: var(--surface-hover);
}
.conc-value {
  font-size: var(--text-xl);
  font-weight: 800;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}
.conc-label { font-size: var(--text-xs); color: var(--muted); margin-top: var(--space-0); line-height: 1.25; }
.conc-hhi {
  padding: var(--space-3);
  border-radius: var(--radius-sm);
  border-left: 3px solid var(--border);
  background: var(--surface-hover);
}
.conc-hhi-num { font-weight: 800; font-variant-numeric: tabular-nums; }
.conc-hhi-low { border-left-color: var(--success-fill); }
.conc-hhi-mid { border-left-color: var(--warning-fill); }
.conc-hhi-high { border-left-color: var(--danger-fill); }
.movers-key {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1-5);
  margin-top: var(--space-3);
}
.movers-key-item {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1-5);
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-sm);
  background: var(--surface-hover);
  border-left: 3px solid var(--border);
  font-size: var(--text-xs);
  color: var(--muted);
}
.movers-key-item b {
  font-variant-numeric: tabular-nums;
  color: var(--text);
}
.movers-key-item.is-new,
.movers-key-item.is-up { border-left-color: var(--success-fill); }
.movers-key-item.is-down,
.movers-key-item.is-lost { border-left-color: var(--danger-fill); }
.movers-table { font-size: var(--text-sm); }
.movers-table td, .movers-table th { padding: var(--space-1-5) var(--space-2); }
.movers-table td { font-variant-numeric: tabular-nums; }
.movers-table tbody tr { border-left: 3px solid transparent; }
.movers-table tbody tr.mover-new,
.movers-table tbody tr.mover-up { border-left-color: var(--success-fill); }
.movers-table tbody tr.mover-down,
.movers-table tbody tr.mover-lost { border-left-color: var(--danger-fill); }
.sla-box {
  border-left: 3px solid var(--border);
  padding: var(--space-0) 0 var(--space-0) var(--space-3);
}
.sla-rate {
  font-size: var(--text-2xl);
  font-weight: 800;
  line-height: 1.05;
  font-variant-numeric: tabular-nums;
  color: var(--text);
}
.sla-label {
  font-size: var(--text-xs);
  color: var(--muted);
}
.sla-good { border-left-color: var(--bi-good); }
.sla-good .sla-rate { color: var(--bi-good); }
.sla-warn { border-left-color: var(--bi-warn); }
.sla-warn .sla-rate { color: var(--bi-warn); }
.sla-bad { border-left-color: var(--bi-bad); }
.sla-bad .sla-rate { color: var(--bi-bad); }
.sla-track {
  position: relative;
  height: .375rem;
  margin-top: var(--space-3);
  border-radius: var(--radius-xs);
  background: var(--surface-hover);
  overflow: hidden;
}
.sla-fill {
  display: block;
  height: 100%;
  width: var(--bar, 0%);
  border-radius: var(--radius-xs);
  background: var(--bi-good);
}
.sla-warn .sla-fill { background: var(--bi-warn); }
.sla-bad .sla-fill { background: var(--bi-bad); }
.sla-legend {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1-5);
  margin-top: var(--space-2);
}
.sla-leg {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-sm);
  background: var(--surface-hover);
  border-left: 3px solid var(--border);
  font-size: var(--text-xs);
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.sla-leg.is-on { border-left-color: var(--success-fill); }
.sla-leg.is-late { border-left-color: var(--danger-fill); }
.cyc-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(7.5rem, 1fr));
  gap: var(--space-2);
  margin-bottom: var(--space-4);
}
.cyc-item {
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-sm);
  background: var(--surface-hover);
  border-left: 3px solid var(--border);
}
.cyc-item-lead { border-left-color: var(--primary); }
.cyc-val {
  display: block;
  font-size: var(--text-lg);
  font-weight: 700;
  line-height: 1.15;
  font-variant-numeric: tabular-nums;
  color: var(--text);
}
.cyc-lab {
  display: block;
  font-size: var(--text-xs);
  color: var(--muted);
}
.load-table, .workclients-table { font-size: var(--text-sm); }
.load-table td, .load-table th,
.workclients-table td, .workclients-table th { padding: var(--space-1-5) var(--space-2); }
.load-table td, .workclients-table td { font-variant-numeric: tabular-nums; }
@media (hover: hover) {
  .bi-report .bi-card .card-header .icon-btn {
    opacity: 0;
    transition: opacity var(--dur-2) var(--ease-out);
  }
.bi-report .bi-card:hover .card-header .icon-btn,
  .bi-report .bi-card:focus-within .card-header .icon-btn,
  .bi-report .bi-card.bi-focused .card-header .icon-btn { opacity: 1; }
}
@media (hover: hover) {
  .bi-report .bi-card:not(.bi-focused) {
    transition: transform var(--dur-2) var(--ease-out),
                box-shadow var(--dur-2) var(--ease-out);
  }
  .bi-report .bi-card:not(.bi-focused):hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
  }
}
body.bi-xf-on .bi-report .bi-card[data-xf="live"] {
  box-shadow: inset 0 2px 0 0 var(--primary);
}
@media (hover: hover) {
  body.bi-xf-on .bi-report .bi-card[data-xf="live"]:not(.bi-focused):hover {
    box-shadow: inset 0 2px 0 0 var(--primary), var(--shadow-lg);
  }
}
.xf-follow {
  font-size: var(--text-xs);
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.bi-report .bi-hero {
  position: relative;
  overflow: hidden;
  isolation: isolate;
}
.bi-report .bi-hero::before {
  content: '';
  position: absolute;
  inset: -45%;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(38% 46% at 18% 32%, color-mix(in oklab, var(--primary) 26%, transparent), transparent 68%),
    radial-gradient(34% 42% at 80% 22%, color-mix(in oklab, var(--bi-cat-2) 22%, transparent), transparent 68%),
    radial-gradient(30% 38% at 56% 84%, color-mix(in oklab, var(--bi-cat-3) 20%, transparent), transparent 68%);
  animation: bi-aurora var(--drift-c) var(--ease-in-out) infinite alternate;
  will-change: transform;
}
@keyframes bi-aurora {
  from { transform: translate3d(-2.5%, -1.5%, 0) scale(1.04) rotate(0deg); }
  to   { transform: translate3d(2.5%, 1.5%, 0) scale(1.12) rotate(5deg); }
}
.present-progress {
  position: absolute;
  left: .6rem;
  top: .3rem;
  width: calc(100% - 1.2rem);
  height: 2px;
transform: scaleX(0);
  transform-origin: left center;
  background: var(--primary);
  border-radius: var(--radius-xs);
}
.present-progress.is-running {
animation: bi-present-sweep 12s linear forwards;
}
@keyframes bi-present-sweep {
  from { transform: scaleX(0); }
  to   { transform: scaleX(1); }
}
.heat-table { font-size: var(--text-xs); }
.heat-table th { font-weight: 600; }
.heat-cell {
  position: relative;
  min-width: 3.1rem;
  font-variant-numeric: tabular-nums;
  isolation: isolate;
}
.heat-fill {
  position: absolute;
  inset: 1px;
  border-radius: var(--radius-xs);
  background: var(--primary);
  z-index: -1;
}
.heat-val { position: relative; }
.heat-cell.is-hot .heat-val { color: #fff; font-weight: 700; }
.heat-cell.is-future { color: var(--faint); }
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
.heat-table .heat-fill {
      animation-name: heatIgnite;
      animation-fill-mode: both;
      animation-timing-function: var(--ease-out);
      animation-timeline: view();
      animation-range: entry 0% entry 200px;
    }
.heat-table td:nth-child(4n+2) .heat-fill { animation-range: entry 0% entry 260px; }
    .heat-table td:nth-child(4n+3) .heat-fill { animation-range: entry 0% entry 320px; }
    .heat-table td:nth-child(4n) .heat-fill { animation-range: entry 0% entry 380px; }
.mult-spark path:nth-of-type(2) {
      stroke-dasharray: 320;
      animation-name: sparkDraw;
      animation-fill-mode: both;
      animation-timing-function: var(--ease-out);
      animation-timeline: view();
      animation-range: entry 0% entry 220px;
    }
.mult-spark path:nth-of-type(1),
    .mult-spark circle {
      animation-name: heatIgnite;
      animation-fill-mode: both;
      animation-timing-function: var(--ease-out);
      animation-timeline: view();
      animation-range: entry 60px entry 260px;
    }
.ribbon-svg,
    .cal-svg {
      animation-name: wipeIn;
      animation-fill-mode: both;
      animation-timing-function: var(--ease-out);
      animation-timeline: view();
      animation-range: entry 0% entry 260px;
    }
  }
}
@keyframes heatIgnite { from { opacity: 0; } }
@keyframes sparkDraw { from { stroke-dashoffset: 320; } }
@keyframes wipeIn {
  from { clip-path: inset(0 100% 0 0); }
  to   { clip-path: inset(0 0 0 0); }
}
.vat-matrix { font-size: var(--text-xs); }
.vat-roomy .vat-matrix { font-size: var(--text-sm); }
.bi-report .vat-roomy .table > :not(caption) > * > * {
  padding: var(--space-2) var(--space-3);
}
.vat-matrix th { font-weight: 600; white-space: nowrap; }
.vat-owner-col, .vat-owner {
  position: sticky;
  left: 0;
  z-index: 2;
  background: var(--surface);
  min-width: 12rem;
}
.vat-owner { border-right: 1px solid var(--border); vertical-align: top; padding-top: var(--space-2); }
.vat-owner-name { display: block; font-weight: 700; line-height: 1.2; }
.vat-owner-nf, .vat-owner-count {
  display: block;
  font-size: var(--text-2xs);
  color: var(--faint);
  font-variant-numeric: tabular-nums;
}
.vat-year-col { min-width: 3.4rem; }
.vat-year { font-weight: 700; color: var(--muted); font-variant-numeric: tabular-nums; }
.vat-owner-first > .vat-year, .vat-owner-first > .vat-cell, .vat-owner-first > .vat-total {
  border-top: 2px solid var(--border);
}
.vat-cell { padding: var(--space-0); }
.vat-dash { color: var(--faint); }
.vat-total { font-variant-numeric: tabular-nums; white-space: nowrap; }
.rows-more-toggle {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: 0;
  opacity: 0;
}
.rows-more-toggle:not(:checked) ~ .table-responsive tr.is-extra { display: none; }
.rows-more {
  display: block;
  margin-top: var(--space-2);
  padding: var(--space-1) var(--space-2);
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius-sm);
  color: var(--muted);
  font-size: var(--text-xs);
  font-weight: 700;
  text-align: center;
  cursor: pointer;
}
.rows-more:hover {
  color: var(--primary-text);
  border-color: var(--primary);
  background: var(--primary-soft);
}
.rows-more-toggle:focus-visible ~ .rows-more {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}
.rows-more-toggle:not(:checked) ~ .rows-more .more-close,
.rows-more-toggle:checked ~ .rows-more .more-open { display: none; }
@media print {
  .rows-more-toggle ~ .table-responsive tr.is-extra { display: table-row; }
  .rows-more { display: none; }
}
.vat-chip {
  position: relative;
  display: block;
  width: 100%;
  min-width: 3.6rem;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  padding: var(--space-1);
  background: color-mix(in srgb, var(--primary) calc(var(--heat, 0) * 70%), var(--surface-muted));
  color: inherit;
  font: inherit;
  font-variant-numeric: tabular-nums;
  cursor: pointer;
  transition: transform var(--dur-1) var(--ease-out), box-shadow var(--dur-1) var(--ease-out), border-color var(--dur-1) var(--ease-out);
}
.vat-chip:hover { transform: translateY(-1px); box-shadow: var(--shadow-sm); }
.vat-chip:focus-visible { outline: 2px solid var(--primary); outline-offset: 1px; }
.vat-chip.is-active { border-color: var(--primary); box-shadow: 0 0 0 var(--ring-w) var(--primary-soft); }
.vat-chip-year { margin-top: var(--space-1); font-size: var(--text-xs); border-style: dashed; border-color: var(--border); }
.vat-chip-dup {
  position: absolute;
  top: -.3rem;
  right: -.3rem;
  min-width: 1rem;
  border-radius: var(--radius-lg);
background: var(--warning);
  color: var(--primary-contrast);
  font-size: var(--text-2xs);
  line-height: 1rem;
  font-weight: 700;
}
.pay-matrix .vat-chip,
.wr-matrix .vat-chip {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.pay-heads,
.vat-chip-paid {
  align-self: flex-end;
  margin-top: var(--space-0);
  padding: 0 var(--space-1);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
  color: var(--muted);
  font-size: var(--text-2xs);
  line-height: 1.05rem;
  font-weight: 700;
}
.vat-chip-paid { white-space: nowrap; }
.vat-chip-word {
  display: block;
  font-size: var(--text-2xs);
  font-weight: 600;
  line-height: 1;
  color: var(--faint);
}
.pay-total-heads,
.vat-total-note {
  display: block;
  color: var(--faint);
  font-size: var(--text-2xs);
  font-weight: 500;
}
.gap-chip {
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  padding: var(--space-1) var(--space-2);
  font-size: var(--text-xs);
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  cursor: pointer;
  transition: transform var(--dur-1) var(--ease-out), box-shadow var(--dur-1) var(--ease-out);
}
.gap-chip:hover { transform: translateY(-1px); box-shadow: var(--shadow-sm); }
.gap-chip:focus-visible { outline: 2px solid var(--primary); outline-offset: 1px; }
.gap-chip-late {
  background: color-mix(in srgb, var(--danger) 14%, var(--surface));
  border-color: color-mix(in srgb, var(--danger) 45%, transparent);
  color: var(--danger);
}
.gap-chip-soon {
  background: color-mix(in srgb, var(--warning) 14%, var(--surface));
  border-color: color-mix(in srgb, var(--warning) 40%, transparent);
  color: var(--warning);
}
.gap-table tr.gap-stopped > td:first-child {
  box-shadow: inset var(--rail) 0 0 var(--danger);
}
.gap-chip {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  text-decoration: none;
}
.gap-chip-held {
  background: color-mix(in srgb, var(--success) 12%, var(--surface));
  border-color: color-mix(in srgb, var(--success) 40%, transparent);
  color: var(--success);
}
.gap-chip-held .bi { font-size: var(--text-xs); }
.gap-strip {
  display: flex;
  gap: var(--space-0);
  margin-top: var(--space-1);
}
.gap-strip-cell {
  width: 9px;
  height: 12px;
  border-radius: var(--radius-xs);
  background: var(--surface-muted);
}
.gap-strip-cell.is-filed { background: color-mix(in srgb, var(--success) 45%, transparent); }
.gap-strip-cell.is-late { background: var(--danger); }
.gap-strip-cell.is-soon { background: var(--warning); }
.gap-strip-cell.is-old { background: var(--border-strong); }
.gap-owners {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}
.gap-owner {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: var(--space-0) var(--space-2);
  min-width: 12rem;
  padding: var(--space-2) var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: inherit;
  text-decoration: none;
  transition: border-color var(--dur-1) var(--ease-out), box-shadow var(--dur-1) var(--ease-out);
}
.gap-owner:hover { border-color: var(--primary-line); box-shadow: var(--shadow-sm); }
.gap-owner.is-active { border-color: var(--primary); box-shadow: var(--shadow-sm); }
.gap-owner.is-orphan { border-style: dashed; }
.gap-owner-name {
  font-weight: 600;
  font-size: var(--text-sm);
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.gap-owner-count {
  grid-row: 1 / span 2;
  grid-column: 2;
  font-family: 'Sora Variable', 'Inter Variable', Inter, sans-serif;
  font-size: var(--text-xl);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--muted);
}
.gap-owner-count.is-late { color: var(--danger); }
.gap-owner-note { font-size: var(--text-xs); color: var(--faint); }
.vat-detail {
  margin-top: var(--space-4);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-muted);
  padding: var(--space-4);
}
.vat-detail-empty {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  color: var(--faint);
  font-size: var(--text-sm);
}
.vat-detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-3);
  flex-wrap: wrap;
  margin-bottom: var(--space-3);
}
.vat-detail-name { font-weight: 700; font-size: var(--text-base); }
.vat-detail-sub { color: var(--faint); font-size: var(--text-sm); }
.vat-highlights {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
  gap: var(--space-2);
  margin-bottom: var(--space-4);
}
.vat-hl {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  padding: var(--space-2);
}
.vat-hl.is-zero { opacity: .55; }
.vat-hl-total { border-color: var(--primary-line); background: var(--primary-soft); }
.vat-hl-total.is-zero { opacity: 1; }
.vat-hl-settle { border-width: 2px; }
.vat-hl-settle.is-zero { opacity: 1; }
.vat-hl-settle.is-pagese { border-color: var(--warning); background: var(--warning-soft); }
.vat-hl-settle.is-pagese .vat-hl-no { color: var(--warning); }
.vat-hl-settle.is-kreditim { border-color: var(--success); background: var(--success-soft); }
.vat-hl-settle.is-kreditim .vat-hl-no { color: var(--success); }
.vat-hl-no { font-size: var(--text-2xs); font-weight: 700; color: var(--primary-text); }
.vat-hl-label { display: block; font-size: var(--text-2xs); color: var(--faint); line-height: 1.25; }
.vat-hl-val {
  display: block;
  margin-top: var(--space-1);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.vat-measure-form { display: flex; align-items: center; gap: var(--space-1-5); }
.vat-measure-form .form-select { min-width: 14rem; }
@media (max-width: 767.98px) {
  .vat-measure-form { flex-wrap: wrap; width: 100%; }
  .vat-measure-form .form-select { flex: 1 1 100%; min-width: 0; }
}
#vat-card.is-swapping .card-body { opacity: .45; pointer-events: none; }
.narrative-card { border-top: 2px solid transparent; border-image: var(--grad-primary) 1; }
.narrative-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--space-2) var(--space-4);
}
.insight {
  display: flex;
  align-items: flex-start;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-sm);
  background: var(--surface-hover);
  font-size: var(--text-sm);
  line-height: 1.35;
}
.insight-icon {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 1.7rem;
  height: 1.7rem;
  border-radius: var(--radius-pill);
  font-size: var(--text-md);
  color: #fff;
  background: var(--grad-primary);
}
.insight-text { color: var(--text); padding-top: var(--space-0); }
.insight-good .insight-icon { background: linear-gradient(135deg,var(--success-fill-strong),var(--success-fill)); }
.insight-bad  .insight-icon { background: linear-gradient(135deg,var(--danger-fill-strong),var(--danger-fill)); }
.insight-neutral .insight-icon { background: linear-gradient(135deg,#b8904a,#d2ab67); }
.xf-bar {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  flex-wrap: wrap;
  margin-bottom: var(--space-3);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 3px solid var(--primary);
  box-shadow: var(--shadow-sm);
  animation: xf-in var(--dur-2) var(--ease-out);
}
@keyframes xf-in { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.xf-label {
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--primary);
}
.xf-drill {
  font-size: var(--text-sm);
  font-weight: 600;
  text-decoration: none;
  color: var(--primary);
}
.xf-drill:hover { text-decoration: underline; }
button.xf-drill {
  padding: 0;
  border: 0;
  background: transparent;
  font-family: inherit;
  font-size: var(--text-sm);
  font-weight: 600;
  cursor: pointer;
}
.xf-clear {
  margin-left: auto;
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  padding: var(--space-0) var(--space-1-5);
  border-radius: var(--radius-sm);
  line-height: 1;
}
.xf-clear:hover { color: var(--danger); background: var(--surface-hover); }
tr.xf-row > td {
  background: var(--primary-soft) !important;
  box-shadow: inset var(--rail) 0 0 var(--primary);
}
.bi-report {
--surface: var(--bi-visual);
  --surface-muted: var(--bi-chrome);
  --surface-sunken: var(--bi-chrome-hover);
  --surface-hover: rgba(0,0,0,.035);
  --border: var(--bi-line);
  --border-strong: var(--bi-line);
  --surface-border: var(--bi-line);
  --text: var(--bi-ink);
  --muted: var(--bi-ink-2);
  --faint: var(--bi-ink-2);
  --primary: var(--bi-accent);
  --primary-dark: var(--bi-accent-dark);
  --primary-2: var(--bi-accent);
  --primary-text: var(--bi-accent-dark);
  --grad-primary: var(--bi-accent);
  --grad-primary-hover: var(--bi-accent-dark);
  --grad-primary-text: var(--bi-accent);
  --success: #0e6b28;
  --warning: #7a6100;
  --danger: #a4262c;
  --radius-xs: 2px;
  --radius-sm: 2px;
  --radius: var(--bi-radius);
  --radius-lg: var(--bi-radius);
  --radius-xl: var(--bi-radius);
  --shadow-sm: var(--bi-shadow);
  --shadow-md: var(--bi-shadow-hover);
  --shadow-glow: none;
  --card-shadow: var(--bi-shadow);
}
.bi-frame {
  border-radius: var(--bi-radius);
overflow: visible;
}
.bi-body {
  display: flex;
  align-items: stretch;
  background: var(--bi-canvas);
  border-left: 1px solid var(--bi-line);
  border-right: 1px solid var(--bi-line);
}
.bi-surface {
  flex: 1 1 auto;
  min-width: 0;
  padding: var(--space-2);
}
.bi-hero {
  position: relative;
  overflow: hidden;
  padding: var(--space-3);
  border: 1px solid var(--bi-line);
  border-radius: var(--bi-radius) var(--bi-radius) 0 0;
  background: var(--bi-chrome);
  box-shadow: none;
  align-items: center;
  gap: var(--space-3);
}
.bi-hero::after { display: none; }    
.bi-hero .page-eyebrow { font-size: var(--text-2xs); letter-spacing: .06em; color: var(--bi-ink-2); }
.bi-hero .page-title {
  font-size: var(--text-lg);
  font-weight: 600;
  letter-spacing: 0;
  margin: 0;
  gap: var(--space-2);
}
.bi-hero .page-title-icon {
  width: 1.6rem;
  height: 1.6rem;
  border-radius: var(--radius-xs);
  background: var(--bi-accent);
  box-shadow: none;
  font-size: var(--text-sm);
}
.bi-hero .page-sub { font-size: var(--text-xs); margin: var(--space-0) 0 0; color: var(--bi-ink-2); }
.bi-tick {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-1-5) var(--space-2);
  border: 1px solid var(--bi-line);
  border-top: 0;
  background: var(--bi-chrome);
  overflow: hidden;
}
.bi-tick[hidden] { display: none; }
.bi-tick-lead {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  flex: 0 0 auto;
  padding-right: var(--space-2);
  border-right: 1px solid var(--bi-line);
  font-size: var(--text-2xs);
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--bi-accent);
}
.bi-tick-window {
  position: relative;
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
mask-image: linear-gradient(to right, transparent, #000 var(--space-4),
                              #000 calc(100% - var(--space-4)), transparent);
}
.bi-tick-track {
  display: flex;
  width: max-content;
  animation: biTick var(--drift-tick) linear infinite;
}
.bi-tick:hover .bi-tick-track,
.bi-tick:focus-within .bi-tick-track { animation-play-state: paused; }
@keyframes biTick {
from { transform: translate3d(0, 0, 0); }
  to   { transform: translate3d(-50%, 0, 0); }
}
.bi-tick-run { display: flex; flex: 0 0 auto; }
.bi-tick-item {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1-5);
  padding: 0 var(--space-3);
  border-right: 1px solid var(--bi-line);
  font-size: var(--text-xs);
  white-space: nowrap;
  text-decoration: none;
  color: var(--bi-ink);
  transition: color var(--dur-1) var(--ease-out);
}
.bi-tick-item:hover { color: var(--bi-accent); text-decoration: underline; }
.bi-tick-item .bi { font-size: var(--text-sm); }
.bi-tick-invoice .bi { color: var(--bi-cat-1); }
.bi-tick-task    .bi { color: var(--bi-good); }
.bi-tick-due     .bi { color: var(--bi-bad); }
.bi-tick-time {
  font-size: var(--text-2xs);
  font-variant-numeric: tabular-nums;
  color: var(--bi-ink-2);
}
.bi-report .reveal,
.bi-report .stagger > * {
  opacity: 1 !important;
  transform: none !important;
  animation: none !important;
}
.bi-report .bi-grid {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
  gap: var(--space-2);
}
.bi-report .bi-card {
  background: var(--bi-visual);
  border: 1px solid var(--bi-line);
  border-radius: var(--bi-radius);
  box-shadow: var(--bi-shadow);
  transition: box-shadow var(--dur-1) var(--ease-out), border-color var(--dur-1) var(--ease-out);
}
.bi-report .bi-card:hover {
  transform: none;
  box-shadow: var(--bi-shadow-hover);
  border-color: var(--bi-ink-2);
}
.bi-report .bi-card.bi-focused:hover { box-shadow: var(--bi-shadow-hover); }
.bi-report .bi-card > .card-header {
  background: transparent;
  border-bottom: 0;
  padding: var(--space-2) var(--space-3) var(--space-0);
  font-size: var(--text-sm);
  font-weight: 600;
  letter-spacing: 0;
  color: var(--bi-ink);
  min-height: 0;
}
.bi-report .bi-card > .card-body { padding: var(--space-1-5) var(--space-3) var(--space-3); }
.bi-grid > .bi-card:has(> .card-body > .empty-state) {
  order: 2;
  opacity: .58;
  box-shadow: none;
  border-style: dashed;
}
.bi-grid > .bi-card:has(> .card-body > .empty-state):hover {
  box-shadow: none;
  border-color: var(--bi-line);
}
.bi-grid > .bi-card:has(> .card-body > .empty-state) .card-header .icon-btn,
.bi-grid > .bi-card:has(> .card-body > .empty-state) .card-header .seg,
.bi-grid > .bi-card:has(> .card-body > .empty-state) .card-header form {
  display: none;
}
.bi-grid > .bi-card:has(> .card-body > .empty-state) > .card-body {
  pointer-events: none;
  padding: var(--space-0) var(--space-3) var(--space-2);
}
.bi-grid > .bi-card:has(> .card-body > .empty-state) .empty-state {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-1) var(--space-0);
  text-align: left;
}
.bi-grid > .bi-card:has(> .card-body > .empty-state) .empty-icon {
  width: 1.6rem;
  height: 1.6rem;
  border-radius: var(--radius-sm);
  font-size: var(--text-sm);
  margin-bottom: 0;
  box-shadow: none;
}
.bi-grid > .bi-card:has(> .card-body > .empty-state) .empty-title {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--muted);
}
.bi-grid > .bi-card:has(> .card-body > .empty-state) .empty-text,
.bi-grid > .bi-card:has(> .card-body > .empty-state) .empty-action {
  display: none;
}
.bi-report .table > :not(caption) > * > * { padding: var(--space-1-5) var(--space-2); }
.bi-report .table thead th {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--bi-ink-2);
  text-transform: none;
  letter-spacing: 0;
}
.bi-report .stat-grid {
  grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
  gap: var(--space-2);
  margin-bottom: var(--space-2);
}
.bi-report .stat-card {
  background: var(--bi-visual);
  border: 1px solid var(--bi-line);
  border-radius: var(--bi-radius);
  box-shadow: var(--bi-shadow);
  padding: var(--space-3);
  transition: box-shadow var(--dur-1) var(--ease-out), border-color var(--dur-1) var(--ease-out);
}
.bi-report .stat-card:hover {
  transform: none;
  box-shadow: var(--bi-shadow-hover);
  border-color: var(--bi-ink-2);
}
.bi-report .stat-card::after { display: none; }
.bi-report .stat-top > div:first-child { display: flex; flex-direction: column; min-width: 0; }
.bi-report .stat-label {
  order: 2;
  margin: var(--space-0) 0 0;
  font-size: var(--text-xs);
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0;
  color: var(--bi-ink-2);
}
.bi-report .stat-value {
  order: 1;
  font-family: inherit;
  font-size: var(--text-2xl);
  font-weight: 600;
  letter-spacing: -.02em;
  color: var(--bi-ink);
}
.bi-report .stat-note { order: 3; font-size: var(--text-xs); color: var(--bi-ink-2); }
.bi-report .stat-delta { font-weight: 600; }
.bi-report .stat-delta.up { color: var(--bi-good); }
.bi-report .stat-delta.down { color: var(--bi-bad); }
.bi-report .stat-icon { display: none; }
.bi-report .kpi-spark { height: 34px; margin-top: var(--space-1-5); }
.bi-pane {
  flex: 0 0 15.5rem;
  width: 15.5rem;
  display: flex;
  flex-direction: column;
  background: var(--bi-chrome);
  border-left: 1px solid var(--bi-line);
  transition: flex-basis var(--dur-2) var(--ease-out), width var(--dur-2) var(--ease-out);
}
.bi-pane-head {
  display: flex;
  align-items: center;
  gap: var(--space-1-5);
  padding: var(--space-2);
  border-bottom: 1px solid var(--bi-line);
}
.bi-pane-title {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--bi-ink);
  flex: 1;
  white-space: nowrap;
}
.bi-pane-icon { color: var(--bi-ink-2); font-size: var(--text-sm); }
.bi-pane-toggle {
  border: 0;
  background: transparent;
  color: var(--bi-ink-2);
  padding: var(--space-1) var(--space-1-5);
  border-radius: var(--radius-xs);
  cursor: pointer;
  line-height: 1;
}
.bi-pane-toggle:hover { background: var(--bi-chrome-hover); color: var(--bi-ink); }
.bi-pane-body {
  padding: var(--space-2);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}
.bi-filter {
  background: var(--bi-visual);
  border: 1px solid var(--bi-line);
  border-radius: var(--bi-radius);
  padding: var(--space-2);
}
.bi-filter-name {
  display: block;
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--bi-ink-2);
  margin-bottom: var(--space-1-5);
}
.bi-filter .form-select { font-size: var(--text-sm); }
.bi-pane-foot {
  margin-top: auto;
  padding: var(--space-2);
  border-top: 1px solid var(--bi-line);
  display: flex;
  align-items: center;
  gap: var(--space-1-5);
  flex-wrap: wrap;
}
.bi-report.pane-collapsed .bi-pane { flex-basis: 2.4rem; width: 2.4rem; }
.bi-report.pane-collapsed .bi-pane-body,
.bi-report.pane-collapsed .bi-pane-foot { display: none; }
.bi-report.pane-collapsed .bi-pane-head { cursor: pointer; }
.bi-report.pane-collapsed .bi-pane-head:hover { background: var(--bi-chrome-hover); }
.bi-report.pane-collapsed .bi-pane-head {
  flex-direction: column-reverse;
  justify-content: flex-start;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-1);
  border-bottom: 0;
flex: 1 1 auto;
  align-items: center;
}
.bi-report.pane-collapsed .bi-pane-title {
  writing-mode: vertical-rl;
  flex: 0 0 auto;
  font-size: var(--text-xs);
}
.bi-pane-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.1rem;
  height: 1.1rem;
  padding: 0 var(--space-1);
  border-radius: var(--radius-pill);
  background: var(--bi-accent);
  color: #fff;
  font-size: var(--text-2xs);
  font-weight: 700;
}
.bi-pane-count:empty { display: none; }
.seg {
  display: inline-flex;
  gap: 0;
  padding: 0;
  border-radius: var(--bi-radius);
  background: var(--surface);
  border: 1px solid var(--border);
  overflow: hidden;
}
.seg-btn {
  border: 0;
  border-right: 1px solid var(--border);
  background: transparent;
  color: var(--muted);
  font-size: var(--text-xs);
  font-weight: 400;
  letter-spacing: 0;
  padding: var(--space-1) var(--space-2);
  border-radius: 0;
  line-height: 1.35;
  cursor: pointer;
  transition: color var(--dur-1) var(--ease-out), background var(--dur-1) var(--ease-out);
}
.seg-btn:last-child { border-right: 0; }
.seg-btn:hover { color: var(--text); background: var(--surface-hover); }
.seg-btn.active {
  background: var(--bi-accent, var(--primary));
  color: #fff;
  font-weight: 600;
  box-shadow: none;
}
.bi-pane .seg { width: 100%; }
.bi-pane .seg-btn { flex: 1; text-align: center; }
.seg-stack { flex-direction: column; }
.seg-stack .seg-btn { border-right: 0; border-bottom: 1px solid var(--border); text-align: left; }
.seg-stack .seg-btn:last-child { border-bottom: 0; }
.bi-report .export-bar,
.bi-report .alarm-panel,
.bi-report .drill-bar,
.bi-report .xf-bar {
  border-radius: var(--bi-radius);
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.bi-report .export-bar { background: var(--bi-visual); border: 1px solid var(--bi-line); }
.bi-report .insight-good .insight-icon,
.bi-report .alarm-panel-clear .alarm-head-icon { background: var(--success-fill-strong); }
.bi-report .insight-bad .insight-icon,
.bi-report .alarm-panel-critical .alarm-head-icon,
.bi-report .alarm-critical .alarm-item-icon { background: var(--danger-fill-strong); }
.bi-report .alarm-panel-warning .alarm-head-icon,
.bi-report .alarm-warning .alarm-item-icon { background: var(--warning-fill-strong); }
.bi-report .insight-neutral .insight-icon,
.bi-report .alarm-info .alarm-item-icon { background: var(--bi-cat-1); }
.bi-report .whatif-bar-fill.up { background: var(--success-fill-strong); }
.bi-report .whatif-bar-fill.down { background: var(--danger-fill-strong); }
.bi-report,
.bi-report .page-title,
.bi-report .card-header,
.bi-report .stat-value,
.bi-report h1, .bi-report h2, .bi-report h3,
.bi-report h4, .bi-report h5, .bi-report h6 {
  font-family: var(--bi-font);
  letter-spacing: 0;
}
.bi-report .bi-card > .card-header .small,
.bi-report .bi-card > .card-header .text-muted { font-size: var(--text-2xs); }
.bi-report .export-bar {
  padding: var(--space-1) var(--space-2);
  gap: var(--space-2);
  border-left-width: 1px;
  border-left-color: var(--bi-line);
}
.bi-report .export-bar-icon { display: none; }
.bi-report .export-bar-title { font-size: var(--text-xs); font-weight: 600; }
.bi-report .export-bar-sub { font-size: var(--text-2xs); }
.bi-report .export-sections {
  padding-left: var(--space-2);
  border-left: 1px solid var(--bi-line);
}
.bi-report .export-sections-label,
.bi-report .export-chk { font-size: var(--text-2xs); }
.bi-report .export-bar .btn {
  padding: var(--space-0) var(--space-2);
  font-size: var(--text-xs);
  font-weight: 400;
}
.bi-report .bi-tab { font-size: var(--text-xs); padding: var(--space-2) var(--space-3); }
.bi-report .bi-tab.active { font-weight: 600; }
.bi-report .bi-card.bi-focused {
  border-radius: var(--bi-radius);
  box-shadow: var(--bi-shadow-focus);
}
@media (max-width: 900px) {
  .bi-body { flex-direction: column; }
  .bi-pane {
    flex: 0 0 auto;
    width: auto;
    order: -1;
    border-left: 0;
    border-bottom: 1px solid var(--bi-line);
  }
  .bi-report.pane-collapsed .bi-pane { flex-basis: auto; width: auto; }
  .bi-report.pane-collapsed .bi-pane-head {
    flex-direction: row;
    height: auto;
    padding: var(--space-2);
  }
  .bi-report.pane-collapsed .bi-pane-title { writing-mode: horizontal-tb; flex: 1; }
  .bi-surface { padding: var(--space-2); }
}
@media print {
  .bi-frame, .bi-body { border: 0; background: none; }
  .bi-hero { background: none; border: 0; padding: 0; }
  .bi-surface { padding: 0; }
  .bi-pane, .bi-tabs { display: none !important; }
  .bi-report .bi-card { box-shadow: none; }
}
@media (hover: hover) {
  .bi-card .card-header .icon-btn { opacity: 0; transition: opacity var(--dur-1) var(--ease-out); }
  .bi-card:hover .card-header .icon-btn,
.bi-card:focus-within .card-header .icon-btn,
  .bi-card.bi-focused .card-header .icon-btn,
  .bi-card .card-header .icon-btn:focus-visible { opacity: 1; }
}
.bi-menu {
  position: absolute;
  left: var(--menu-x, 0);
  top: var(--menu-y, 0);
  z-index: 1080;
  min-width: 12rem;
  padding: var(--space-1);
  background: var(--bi-visual);
  border: 1px solid var(--bi-line);
  border-radius: var(--bi-radius);
  box-shadow: var(--bi-shadow-hover);
}
.bi-menu[hidden] { display: none; }
.bi-menu-sep {
  padding: var(--space-1-5) var(--space-2) var(--space-0);
  font-size: var(--text-2xs);
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--bi-ink-2);
}
.bi-menu-item {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  width: 100%;
  padding: var(--space-1-5) var(--space-2);
  border: 0;
  border-radius: var(--radius-xs);
  background: transparent;
  color: var(--bi-ink);
  font-size: var(--text-xs);
  text-align: left;
  cursor: pointer;
}
.bi-menu-item:hover { background: var(--bi-chrome-hover); }
.bi-menu-item .bi { color: var(--bi-ink-2); }
.bi-menu-item.is-on { font-weight: 600; color: var(--bi-accent); }
.bi-menu-item.is-on .bi { color: var(--bi-accent); }
.bi-tip {
  position: absolute;
  left: var(--tip-x, 0);
  top: var(--tip-y, 0);
  transform: translate(-50%, -100%) translateY(-.6rem);
  z-index: 1080;
  min-width: 11rem;
  padding: var(--space-2);
  pointer-events: none;
  background: var(--bi-visual);
  border: 1px solid var(--bi-line);
  border-radius: var(--bi-radius);
  box-shadow: var(--bi-shadow-hover);
}
.bi-tip[hidden] { display: none; }
.bi-tip-head { font-size: var(--text-sm); font-weight: 600; color: var(--bi-ink); }
.bi-tip-sub { font-size: var(--text-2xs); color: var(--bi-ink-2); margin-bottom: var(--space-1); }
.bi-tip-row { display: flex; justify-content: space-between; gap: var(--space-4); font-size: var(--text-xs); }
.bi-tip-key { color: var(--bi-ink-2); display: inline-flex; align-items: center; gap: var(--space-1-5); }
.bi-tip-dot {
  width: .5rem;
  height: .5rem;
  border-radius: var(--radius-round);
  flex: 0 0 auto;
  background: var(--dot, currentColor);
}
.bi-tip-val { font-weight: 600; color: var(--bi-ink); font-variant-numeric: tabular-nums; }
.bi-tip-val.is-good { color: var(--bi-good); }
.bi-tip-val.is-bad { color: var(--bi-bad); }
.bi-tip-foot {
  margin-top: var(--space-1);
  padding-top: var(--space-1);
  border-top: 1px solid var(--bi-line);
  font-size: var(--text-2xs);
  color: var(--bi-ink-2);
}
body.bi-spot-on .bi-report .bi-card:not(.bi-spot),
body.bi-spot-on .bi-report .stat-card,
body.bi-spot-on .bi-report .export-bar,
body.bi-spot-on .bi-report .alarm-panel {
  opacity: .28;
  filter: saturate(.45);
}
.bi-report .bi-card,
.bi-report .stat-card,
.bi-report .export-bar,
.bi-report .alarm-panel { transition: opacity var(--dur-2) var(--ease-out), filter var(--dur-2) var(--ease-out), box-shadow var(--dur-1) var(--ease-out), border-color var(--dur-1) var(--ease-out); }
.bi-report .bi-card.bi-spot { border-color: var(--bi-accent); box-shadow: var(--bi-shadow-hover); }
.bi-card.bi-as-table .chart-box,
.bi-card.bi-as-table .bi-canvas { display: none; }
.bi-datagrid { max-height: 22rem; overflow: auto; }
.bi-datagrid .table { font-variant-numeric: tabular-nums; }
.bi-drill {
  display: inline-flex;
  align-items: center;
  gap: var(--space-0);
  padding: var(--space-0);
  border: 1px solid var(--border);
  border-radius: var(--bi-radius);
}
.bi-drill-btn {
  border: 0;
  padding: var(--space-0) var(--space-1);
  border-radius: var(--radius-xs);
  background: transparent;
  color: var(--muted);
  font-size: var(--text-xs);
  line-height: 1;
  cursor: pointer;
}
.bi-drill-btn:hover:not(:disabled) { background: var(--surface-hover); color: var(--text); }
.bi-drill-btn:disabled { opacity: .35; cursor: default; }
.bi-drill-level {
  padding: 0 var(--space-1);
  font-size: var(--text-2xs);
  color: var(--muted);
  white-space: nowrap;
}
.seg-sm .seg-btn { padding: var(--space-1) var(--space-2); font-size: var(--text-2xs); }
.decomp {
  display: flex;
  gap: var(--space-2);
  align-items: flex-start;
  overflow-x: auto;
  padding-bottom: var(--space-1);
}
.decomp-col {
  position: relative;
  flex: 0 0 13.5rem;
  min-width: 13.5rem;
  padding: var(--space-1-5);
  border: 1px solid var(--border);
  border-radius: var(--bi-radius);
  background: var(--surface);
}
.decomp-col-head {
  margin-bottom: var(--space-1);
  font-size: var(--text-2xs);
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--muted);
}
.decomp-nodes { display: flex; flex-direction: column; gap: var(--space-1); max-height: 17rem; overflow-y: auto; }
.decomp-node {
  position: relative;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0 var(--space-1-5);
  width: 100%;
  padding: var(--space-1) var(--space-1-5);
  border: 1px solid transparent;
  border-radius: var(--radius-xs);
  background: var(--surface-muted);
  color: var(--text);
  text-align: left;
  cursor: pointer;
  overflow: hidden;
}
.decomp-node::before {
  content: '';
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--bar, 0%);
  background: var(--bi-cat-1);
  opacity: .14;
}
.decomp-node > * { position: relative; }
.decomp-node:hover { border-color: var(--bi-ink-2); }
.decomp-node.is-on { border-color: var(--bi-accent); background: var(--surface); }
.decomp-node.is-on::before { opacity: .24; }
.decomp-node-name {
  font-size: var(--text-xs);
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.decomp-node-val { font-size: var(--text-xs); font-weight: 600; font-variant-numeric: tabular-nums; }
.decomp-node-val.is-bad { color: var(--bi-bad); }
.decomp-node-share { grid-column: 1 / -1; font-size: var(--text-2xs); color: var(--muted); }
.decomp-drop {
  position: absolute;
  top: .25rem;
  right: .3rem;
  padding: 0 var(--space-1);
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: var(--text-2xs);
  line-height: 1;
  cursor: pointer;
}
.decomp-drop:hover { color: var(--bi-bad); }
.decomp-col-add {
  flex-basis: 10.5rem;
  min-width: 10.5rem;
  background: transparent;
  border-style: dashed;
}
.decomp-add-btn {
  display: flex;
  align-items: center;
  gap: var(--space-1-5);
  width: 100%;
  margin-top: var(--space-1);
  padding: var(--space-1) var(--space-1-5);
  border: 1px solid var(--border);
  border-radius: var(--radius-xs);
  background: var(--surface);
  color: var(--text);
  font-size: var(--text-xs);
  cursor: pointer;
}
.decomp-add-btn:hover { border-color: var(--bi-accent); color: var(--bi-accent); }
.decomp-add-auto .bi { color: var(--bi-accent); }
.explain-card[hidden] { display: none; }
.explain { display: flex; flex-direction: column; gap: var(--space-2); }
.explain-head { display: flex; align-items: baseline; flex-wrap: wrap; gap: var(--space-2); }
.explain-delta {
  font-size: var(--text-xl);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.explain-delta.is-up { color: var(--bi-good); }
.explain-delta.is-down { color: var(--bi-bad); }
.explain-say { font-size: var(--text-sm); color: var(--muted); }
.explain-rows { display: flex; flex-direction: column; gap: var(--space-1); }
.explain-row {
  display: grid;
  grid-template-columns: minmax(7rem, 15rem) 1fr auto;
  align-items: center;
  gap: 0 var(--space-2);
  width: 100%;
  padding: var(--space-1) var(--space-2);
  border: 1px solid transparent;
  border-radius: var(--radius-xs);
  background: var(--surface-muted);
  color: var(--text);
  text-align: left;
  font-family: inherit;
}
button.explain-row { cursor: pointer; }
button.explain-row:hover { border-color: var(--bi-ink-2); }
.explain-row.is-on { border-color: var(--bi-accent); background: var(--surface); }
.explain-row.is-rest .explain-row-name { color: var(--muted); }
.explain-row-name {
  font-size: var(--text-xs);
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.explain-row-val { font-size: var(--text-xs); font-weight: 700; font-variant-numeric: tabular-nums; }
.explain-row.is-up .explain-row-val { color: var(--bi-good); }
.explain-row.is-down .explain-row-val { color: var(--bi-bad); }
.explain-row-sub {
  grid-column: 1 / -1;
  font-size: var(--text-2xs);
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.explain-bar { position: relative; height: .5rem; }
.explain-bar::before {
  content: '';
  position: absolute;
  left: 50%;
  top: -.1rem;
  bottom: -.1rem;
  width: 1px;
  background: var(--border);
}
.explain-bar-fill {
  position: absolute;
  top: 0;
  bottom: 0;
width: calc(var(--bar, 0%) / 2);
  border-radius: var(--radius-xs);
}
.explain-row.is-up .explain-bar-fill { left: 50%; background: var(--bi-good); }
.explain-row.is-down .explain-bar-fill { right: 50%; background: var(--bi-bad); }
.explain-foot { font-size: var(--text-2xs); color: var(--muted); }
.ribbon { width: 100%; }
.ribbon-svg { display: block; width: 100%; }
.ribbon-band, .ribbon-link, .ribbon-name {
  transition: opacity var(--dur-1) var(--ease-out);
}
.ribbon-band { cursor: pointer; }
.ribbon-band.is-dim, .ribbon-link.is-dim, .ribbon-name.is-dim { opacity: .16; }
.ribbon-band.is-on { stroke: var(--bi-ink); stroke-width: 1; }
.ribbon-link.is-on { opacity: 1; }
.ribbon-name { font-size: var(--text-2xs); font-weight: 600; }
.ribbon-name.is-on { font-weight: 700; }
.ribbon-axis { font-size: var(--text-2xs); }
.multiples {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr));
  gap: var(--space-2);
}
.mult {
  display: flex;
  flex-direction: column;
  gap: var(--space-0);
  padding: var(--space-2) var(--space-2) var(--space-1);
  border: 1px solid var(--border);
  border-radius: var(--bi-radius);
  background: var(--surface);
  color: var(--text);
  text-align: left;
  font-family: inherit;
  transition: opacity var(--dur-1) var(--ease-out), border-color var(--dur-1) var(--ease-out);
}
button.mult { cursor: pointer; }
button.mult:hover { border-color: var(--bi-ink-2); }
.mult.is-on { border-color: var(--bi-accent); }
.mult.is-dim { opacity: .35; }
.mult.is-group { background: var(--surface-muted); }
.mult-head { display: flex; align-items: baseline; justify-content: space-between; gap: var(--space-1-5); }
.mult-name {
  font-size: var(--text-xs);
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.mult-delta { font-size: var(--text-2xs); font-weight: 700; font-variant-numeric: tabular-nums; }
.mult-delta.is-up { color: var(--bi-good); }
.mult-delta.is-down { color: var(--bi-bad); }
.mult-val { font-size: var(--text-sm); font-weight: 700; font-variant-numeric: tabular-nums; }
.mult-spark { width: 100%; height: 2.4rem; display: block; }
.bi-focused .ribbon { height: 100%; }
.bi-focused .multiples { align-content: start; }
.play-bar {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-top: var(--space-2);
  padding-top: var(--space-2);
  border-top: 1px solid var(--border);
}
.play-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  flex: 0 0 auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-round);
  background: var(--surface);
  color: var(--bi-accent);
  font-size: var(--text-base);
  line-height: 1;
  cursor: pointer;
}
.play-btn:hover { border-color: var(--bi-accent); }
.play-range { flex: 1 1 auto; min-width: 6rem; accent-color: var(--bi-accent); }
.play-label {
  min-width: 4.5rem;
  font-size: var(--text-sm);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.cal-scroll { overflow-x: auto; padding-bottom: var(--space-1); }
.cal-svg { display: block; }
.cal-day { cursor: pointer; }
.cal-day:hover { stroke: var(--bi-ink); stroke-width: 1; }
.cal-wd, .cal-month { font-size: var(--text-2xs); }
.cal-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-top: var(--space-1-5);
  font-size: var(--text-2xs);
  color: var(--muted);
}
.cal-legend { display: inline-flex; align-items: center; gap: var(--space-1); }
.cal-legend-box {
  width: .7rem;
  height: .7rem;
  border-radius: var(--radius-xs);
  background: var(--bi-cat-1);
  opacity: var(--lvl, 1);
}
body.bi-present .app-sidebar,
body.bi-present .app-topbar,
body.bi-present .bi-tabs,
body.bi-present .export-bar,
body.bi-present .bi-pane,
body.bi-present .page-head,
body.bi-present .app-content > :not(.bi-report) { display: none !important; }
body.bi-present { overflow: hidden; }
body.bi-present .app-content { padding: 0; }
body.bi-present .bi-report {
  position: fixed;
  inset: 0;
  z-index: 1900;
  overflow: auto;
padding: var(--space-4) var(--space-4) 4rem;
  background: var(--bi-canvas);
}
body.bi-present .bi-frame { border: 0; box-shadow: none; }
body.bi-present .bi-card { break-inside: avoid; }
.bi-present-bar {
  position: fixed;
  left: 50%;
  bottom: 1rem;
  transform: translateX(-50%);
  z-index: 1960;
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-1-5) var(--space-2);
  border: 1px solid var(--bi-line);
  border-radius: var(--radius-pill);
  background: var(--bi-visual);
  box-shadow: var(--bi-shadow-hover);
}
.bi-present-bar[hidden] { display: none; }
.present-nav, .present-exit {
  border: 0;
  background: transparent;
  color: var(--bi-ink);
  font-size: var(--text-sm);
  cursor: pointer;
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-sm);
}
.present-nav:hover, .present-exit:hover { background: var(--surface-hover); }
.present-title { font-size: var(--text-sm); font-weight: 700; color: var(--bi-ink); }
.present-count { font-size: var(--text-2xs); color: var(--bi-ink-2); font-variant-numeric: tabular-nums; }
.present-exit kbd {
  font-size: var(--text-2xs);
  padding: 0 var(--space-1);
  border: 1px solid var(--bi-line);
  border-radius: var(--radius-xs);
}
@media (max-width: 640px) {
  .explain-row { grid-template-columns: 1fr auto; }
  .explain-bar { display: none; }
}
.export-bar {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  flex-wrap: wrap;
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  box-shadow: var(--shadow-sm);
}
.export-bar-lead { display: flex; align-items: center; gap: var(--space-3); }
.export-bar-icon {
  display: grid; place-items: center;
  width: 2.2rem; height: 2.2rem; flex: 0 0 auto;
  border-radius: var(--radius);
  background: var(--accent-soft); color: var(--accent);
  font-size: var(--text-lg);
}
.export-bar-title { font-weight: 700; font-size: var(--text-md); letter-spacing: -.01em; }
.export-bar-sub { font-size: var(--text-xs); color: var(--muted); }
.export-bar-actions { display: flex; gap: var(--space-2); margin-left: auto; flex-wrap: wrap; }
.btn-export {
  display: inline-flex; align-items: center; gap: var(--space-2);
  font-weight: 600; font-size: var(--text-sm);
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius);
  border: 1px solid var(--border-strong);
  background: var(--surface); color: var(--text);
  transition: transform var(--dur-2) var(--ease-out), box-shadow var(--dur-2) var(--ease-out), background var(--dur-2) var(--ease-out);
}
.btn-export:hover { transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-export-pdf { border-color: rgba(220,38,38,.35); color: var(--danger); }
.btn-export-pdf:hover { background: var(--danger-soft); }
.btn-export-excel { border: 0; background: linear-gradient(135deg, var(--excel-strong), var(--excel)); color: #fff; }
.btn-export-excel:hover { color: #fff; box-shadow: var(--glow-success); }
.alarm-panel {
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.alarm-panel-critical { border-left: 4px solid var(--danger); }
.alarm-panel-warning  { border-left: 4px solid var(--warning); }
.alarm-panel-clear    { border-left: 4px solid var(--success); }
.alarm-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--space-3); flex-wrap: wrap;
  padding: var(--space-3) var(--space-4);
}
.alarm-panel:not(.alarm-panel-clear) .alarm-head { border-bottom: 1px solid var(--border); }
.alarm-head-title { display: flex; align-items: center; gap: var(--space-3); }
.alarm-head-icon {
  display: grid; place-items: center;
  width: 2.3rem; height: 2.3rem; flex: 0 0 auto;
  border-radius: var(--radius);
  font-size: var(--text-lg); color: #fff;
}
.alarm-panel-critical .alarm-head-icon { background: linear-gradient(135deg,var(--danger-fill-strong),var(--danger-fill)); }
.alarm-panel-warning  .alarm-head-icon { background: linear-gradient(135deg,var(--warning-fill-strong),var(--warning-fill)); }
.alarm-panel-clear    .alarm-head-icon { background: linear-gradient(135deg,var(--success-fill-strong),var(--success-fill)); }
.alarm-head-name { font-weight: 700; font-size: var(--text-base); letter-spacing: -.01em; }
.alarm-head-sub { font-size: var(--text-xs); color: var(--muted); }
.alarm-head-counts { display: flex; gap: var(--space-1-5); flex-wrap: wrap; }
.alarm-badge {
  font-size: var(--text-xs); font-weight: 700; padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-pill); white-space: nowrap;
}
.alarm-badge-critical { background: var(--danger-soft); color: var(--danger); }
.alarm-badge-warning  { background: var(--warning-soft); color: var(--warning); }
.alarm-badge-clear    { background: var(--success-soft); color: var(--success); }
.alarm-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(310px, 1fr));
  gap: var(--space-2);
  padding: var(--space-3) var(--space-4);
}
.alarm-item {
  display: flex; align-items: flex-start; gap: var(--space-3);
  padding: var(--space-3);
  border-radius: var(--radius);
  background: var(--surface-hover);
  border: 1px solid transparent;
  text-decoration: none; color: inherit;
  transition: transform var(--dur-2) var(--ease-out), box-shadow var(--dur-2) var(--ease-out), border-color var(--dur-2) var(--ease-out);
}
a.alarm-item:hover { transform: translateY(-1px); box-shadow: var(--shadow-sm); border-color: var(--border-strong); }
.alarm-item-icon {
  flex: 0 0 auto; display: grid; place-items: center;
  width: 1.9rem; height: 1.9rem; border-radius: var(--radius-pill);
  font-size: var(--text-md); color: #fff;
}
.alarm-critical { border-left: 3px solid var(--danger); }
.alarm-warning  { border-left: 3px solid var(--warning); }
.alarm-critical .alarm-item-icon { background: linear-gradient(135deg,var(--danger-fill-strong),var(--danger-fill)); }
.alarm-warning  .alarm-item-icon { background: linear-gradient(135deg,var(--warning-fill-strong),var(--warning-fill)); }
.alarm-info     .alarm-item-icon { background: linear-gradient(135deg,#b8904a,#d2ab67); }
.alarm-item-body { display: flex; flex-direction: column; gap: var(--space-0); min-width: 0; }
.alarm-item-title { font-weight: 700; font-size: var(--text-sm); }
.alarm-item-text { font-size: var(--text-sm); color: var(--muted); line-height: 1.35; }
.alarm-item-go { margin-left: auto; align-self: center; color: var(--muted); font-size: var(--text-sm); }
.alarm-empty {
  display: flex; align-items: center; gap: var(--space-2);
  padding: var(--space-1-5) var(--space-4) var(--space-4); color: var(--success); font-weight: 600; font-size: var(--text-md);
}
.alarm-empty .bi { font-size: var(--text-lg); }
.yoy-toggle {
  display: inline-flex; align-items: center; gap: var(--space-1-5);
  cursor: pointer; user-select: none; margin: 0;
  font-size: var(--text-xs); font-weight: 600; color: var(--muted);
  white-space: nowrap;
}
.yoy-toggle input { position: absolute; opacity: 0; width: 0; height: 0; }
.yoy-track {
  position: relative; width: 34px; height: 18px; flex: 0 0 auto;
  border-radius: var(--radius-pill); background: rgba(120,131,155,.45);
  transition: background var(--dur-2) var(--ease-out);
}
.yoy-thumb {
  position: absolute; top: 2px; left: 2px;
  width: 14px; height: 14px; border-radius: var(--radius-round);
  background: #fff; box-shadow: var(--shadow-sm);
  transition: transform var(--dur-2) var(--ease-out);
}
.yoy-toggle input:checked + .yoy-track { background: var(--warning); }
.yoy-toggle input:checked + .yoy-track .yoy-thumb { transform: translateX(16px); }
.yoy-toggle input:focus-visible + .yoy-track { box-shadow: 0 0 0 var(--ring-w-lg) var(--warning-soft); }
.yoy-toggle input:checked ~ .yoy-text { color: var(--warning); }
.yoy-toggle-off { opacity: .5; cursor: not-allowed; }
.chart-box-sm { height: 210px; }
.forecast-foot { display: flex; gap: var(--space-2); flex-wrap: wrap; margin-bottom: var(--space-3); }
.forecast-kpi {
  flex: 1 1 0; min-width: 92px;
  display: flex; flex-direction: column; gap: var(--space-0);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius);
  background: var(--surface-hover);
}
.forecast-kpi-label { font-size: var(--text-xs); color: var(--muted); font-weight: 600; }
.forecast-kpi-val { font-size: var(--text-lg); font-weight: 800; letter-spacing: -.01em; }
.forecast-kpi-val.up { color: var(--success); }
.forecast-kpi-val.down { color: var(--danger); }
.forecast-table { font-size: var(--text-sm); }
.forecast-table thead th {
  font-size: var(--text-xs); text-transform: uppercase; letter-spacing: .04em; color: var(--muted);
}
.whatif-margin-box {
  text-align: center; padding: var(--space-3);
  border-radius: var(--radius-lg);
  background: var(--surface-hover);
  margin-bottom: var(--space-3);
}
.whatif-margin { font-size: var(--text-3xl); font-weight: 800; line-height: 1; color: var(--primary); transition: color var(--dur-2) var(--ease-out); }
.whatif-margin.pos { color: var(--success); }
.whatif-margin.warn { color: var(--warning); }
.whatif-margin.neg { color: var(--danger); }
.whatif-margin-label { font-size: var(--text-xs); color: var(--muted); margin-top: var(--space-1); }
.whatif-baseline { font-size: var(--text-xs); font-weight: 600; margin-top: var(--space-1); color: var(--muted); }
.whatif-baseline.pos { color: var(--success); }
.whatif-baseline.neg { color: var(--danger); }
.whatif-controls { display: flex; flex-direction: column; gap: var(--space-3); margin-bottom: var(--space-4); }
.whatif-row > label { display: flex; justify-content: space-between; align-items: center; font-size: var(--text-sm); font-weight: 600; margin-bottom: var(--space-1); }
.whatif-delta { font-weight: 800; font-variant-numeric: tabular-nums; }
.whatif-delta.up { color: var(--success); }
.whatif-delta.down { color: var(--danger); }
.whatif-range { width: 100%; cursor: pointer; accent-color: var(--primary); }
.whatif-range-up { accent-color: var(--success); }
.whatif-range-down { accent-color: var(--danger); }
.whatif-bars { display: flex; flex-direction: column; gap: var(--space-2); }
.whatif-bar { display: grid; grid-template-columns: 3.4rem 1fr auto; align-items: center; gap: var(--space-2); font-size: var(--text-sm); }
.whatif-bar-name { color: var(--muted); font-weight: 600; }
.whatif-bar-track { height: .55rem; border-radius: var(--radius-pill); background: var(--surface-hover); overflow: hidden; }
.whatif-bar-fill { height: 100%; border-radius: var(--radius-pill); width: 0; transition: width var(--dur-3) var(--ease-out); }
.whatif-bar-fill.up { background: linear-gradient(90deg,var(--success-fill-strong),var(--success-fill)); }
.whatif-bar-fill.down { background: linear-gradient(90deg,var(--danger-fill-strong),var(--danger-fill)); }
.whatif-bar-fill.neu { background: var(--grad-primary); }
.whatif-bar-val { font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
@media print {
  .bi-pane, .bi-tabs, .bi-focus-backdrop, .bi-focus-btn, .export-bar { display: none !important; }
  .bi-grid { display: block; }
  .bi-card { break-inside: avoid; margin-bottom: var(--space-3); page-break-inside: avoid; }
  .chart-box { height: 260px !important; }
  .kpi-spark { display: none; }
  .alarm-panel { break-inside: avoid; }
}
.outside-access-menu { width: min(12.5rem, calc(100vw - 1.5rem)); }
.geo-zone-menu { width: min(17rem, calc(100vw - 1.5rem)); max-height: 70vh; overflow-y: auto; }
.outside-access-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-1-5);
}
.outside-access-grid .btn { padding: var(--space-1); font-weight: 600; }
.outside-hours-row {
  display: grid;
  grid-template-columns: auto 1fr auto 1fr;
  align-items: center;
  gap: var(--space-1-5);
}
.outside-days-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: var(--space-1);
}
.outside-day {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-0);
  font-size: var(--text-2xs);
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
}
.outside-day input { cursor: pointer; }
.outside-day:has(input:checked) { color: var(--primary); }
th.sortable { cursor: pointer; user-select: none; white-space: nowrap; }
th.sortable:hover { color: var(--primary); }
th.sortable::after {
  content: "↕";
  opacity: .32;
  margin-left: var(--space-1);
  font-size: .85em;
}
th.sortable.sorted-asc::after { content: "↑"; opacity: 1; color: var(--primary); }
th.sortable.sorted-desc::after { content: "↓"; opacity: 1; color: var(--primary); }
th.sortable:focus-visible {
  outline: none;
  box-shadow: var(--ring);
  border-radius: var(--radius-sm);
}
.table-filter {
  min-width: 150px;
  max-width: 220px;
  font-size: var(--text-sm);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-pill);
}
.table-count { font-variant-numeric: tabular-nums; }
.table-tools {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-1-5);
  margin-left: auto;
}
.table-toolbar-auto { justify-content: flex-end; }
.row-linked { cursor: pointer; }
.row-linked:hover { background: var(--surface-hover); }
.row-linked td:has(> form),
.row-linked td:has(.btn),
.row-linked td:has(input),
.row-linked td:has(select) { cursor: default; }
.tbl-col-off { display: none !important; }
.table-cols-menu {
  min-width: 12rem;
  padding: var(--space-1-5);
  max-height: min(60vh, 22rem);
  overflow: auto;
}
.table-col-opt {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-1-5) var(--space-2);
  border-radius: var(--radius-sm);
  font-size: var(--text-sm);
  cursor: pointer;
  user-select: none;
}
.table-col-opt:hover { background: var(--surface-hover); }
.table-col-opt input { flex: none; margin: 0; cursor: pointer; }
.table-cols-reset {
  width: 100%;
  text-align: left;
  font-size: var(--text-sm);
  padding: var(--space-1-5) var(--space-2);
  text-decoration: none;
}
.table-sum > td {
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  background: var(--surface-muted);
  border-top: 2px solid var(--border-strong);
  color: var(--text);
}
.table-sticky tfoot .table-sum > td {
  position: sticky;
  bottom: 0;
  z-index: 3;
}
@media screen and (max-width: 767.98px) {
.table-cards > tfoot { display: block; }
  .table-cards > tfoot > tr { display: flex; flex-wrap: wrap; gap: var(--space-1-5) var(--space-4); }
  .table-cards > tfoot > tr > td {
    display: inline-block;
    border: 0;
    padding: var(--space-1) 0;
  }
  .table-cards > tfoot > tr > td:empty { display: none; }
  .table-sum > td { background: transparent; }
  .table-cards > tfoot > tr { border-top: 2px solid var(--border-strong); padding-top: var(--space-2); }
}
@media print {
.table-filter, .table-cols, .table-copy, .table-export { display: none !important; }
  th.sortable::after { content: none; }
  .table-sum > td { background: transparent; }
}
.pw-wrap { position: relative; display: block; }
.pw-wrap > input { padding-right: 2.7rem; }
.pw-toggle {
  position: absolute;
  top: 50%;
  right: .45rem;
  transform: translateY(-50%);
  border: 0;
  background: transparent;
  color: var(--faint);
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-sm);
  cursor: pointer;
  line-height: 1;
}
.pw-toggle:hover { color: var(--primary); background: var(--primary-soft); }
.caps-hint {
  display: none;
  margin-top: var(--space-1);
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--warning);
}
.caps-hint.on { display: block; }
.page-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0;
  z-index: 5000;
  background: var(--grad-primary);
  box-shadow: 0 0 8px color-mix(in srgb, var(--primary-2) 55%, transparent);
  opacity: 0;
  transition: width 4s var(--ease-out), opacity var(--dur-2) var(--ease-out);
  pointer-events: none;
}
.page-progress.loading { width: 82%; opacity: 1; }
.is-clickable { cursor: pointer; }
.tcol-sm { min-width: 8rem; }
.tcol-md { min-width: 10rem; }
.tcol-lg { min-width: 12rem; }
.tcol-xl { min-width: 14rem; }
.tcol-tiny { width: 2.5rem; }
.tcol-num { width: 3.5rem; }
.tcol-act { width: 6rem; }
.history-diff thead th:first-child { width: 26%; }
.history-diff-fields td:first-child { width: 35%; }
.field-xs { max-width: 8rem; }     
.field-sm { max-width: 12rem; }
.field-md { max-width: 15rem; }    
.field-lg { max-width: 22rem; }
.field-xl { max-width: 30rem; }    
.select-auto { width: auto; min-width: 8.25rem; }
.dropdown-panel { width: min(16rem, calc(100vw - 1.5rem)); overflow-wrap: anywhere; }
.panel-narrow { width: 100%; max-width: 32rem; }
.progress-xs { height: .3rem; }
.progress-sm { height: .5rem; }
.progress-inline { min-width: 9rem; }
.tracking-wide { letter-spacing: .12em; }
.pre-scroll { max-height: 22rem; white-space: pre-wrap; }
.offline-main { max-width: 34rem; margin: var(--space-7) auto; text-align: center; }
.offline-logo { border-radius: var(--radius-lg); }
.offline-title { justify-content: center; margin-top: var(--space-5); }
.offline-hint {
  margin-top: var(--space-5);
  font-size: var(--text-sm);
  color: var(--muted);
}
.passkey-status {
  margin: var(--space-3) 0 0;
  font-size: var(--text-sm);
  color: var(--muted);
}
.passkey-status.is-bad { color: var(--danger); }
.passkey-status.is-ok { color: var(--success); }
.geo-status {
  margin: var(--space-2) 0 0;
  font-size: var(--text-sm);
  color: var(--muted);
}
.geo-status.is-bad { color: var(--danger); }
.geo-status.is-ok { color: var(--success); }
.harta-kanavace {
  position: relative;
  height: min(58vh, 27rem);
  overflow: hidden;
  background: var(--surface-sunken);
  cursor: grab;
touch-action: none;
  user-select: none;
}
.harta-kanavace.is-duke-terhequr { cursor: grabbing; }
.harta-kanavace:focus-visible { outline: none; box-shadow: var(--ring); }
.harta-shtresa { position: absolute; inset: 0; }
.harta-pllake {
  position: absolute;
  width: 256px;
  height: 256px;
  background-repeat: no-repeat;
  background-size: 256px 256px;
  pointer-events: none;
}
.harta-pllake.is-bosh {
  background-color: var(--surface-muted);
  background-image: linear-gradient(var(--border) 1px, transparent 1px),
                    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 32px 32px;
}
.harta-rrethi {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  border: 2px solid var(--primary);
  background: color-mix(in srgb, var(--primary) 12%, transparent);
  border-radius: var(--radius-round);
  pointer-events: none;
}
.harta-pin {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -100%);
  font-size: var(--text-2xl);
  line-height: 1;
  color: var(--danger);
  pointer-events: none;
}
.harta-zoom {
  position: absolute;
  top: var(--space-2);
  right: var(--space-2);
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}
.harta-zoom .btn { box-shadow: var(--shadow-sm); }
.harta-shkalla {
  position: absolute;
  left: var(--space-2);
  bottom: var(--space-2);
  border: 1px solid var(--text);
  border-top: none;
  height: .55rem;
  font-size: var(--text-2xs);
  color: var(--text);
  pointer-events: none;
}
.harta-shkalla span {
  position: absolute;
  left: 0;
  bottom: 100%;
  padding: 0 var(--space-1);
  background: var(--glass-strong);
  border-radius: var(--radius-xs);
  white-space: nowrap;
}
.harta-kredit {
  position: absolute;
  right: 0;
  bottom: 0;
  margin: 0;
  padding: 0 var(--space-1);
  font-size: var(--text-2xs);
  color: var(--muted);
  background: var(--glass-strong);
  pointer-events: none;
}
.harta-mungon {
  position: absolute;
  left: 50%;
  top: var(--space-3);
  transform: translateX(-50%);
  max-width: 30rem;
  margin: 0;
  padding: var(--space-2) var(--space-3);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface-raised);
  box-shadow: var(--shadow-md);
  font-size: var(--text-sm);
  color: var(--muted);
}
.harta-kerkimi {
  position: relative;
  z-index: 3;
  padding: var(--space-2) var(--space-3);
  border-bottom: 1px solid var(--border);
}
.harta-kerkimi .form-control { padding-left: var(--space-6); }
.harta-kerkimi-ikona {
  position: absolute;
  left: calc(var(--space-3) + var(--space-2));
  top: 50%;
  transform: translateY(-50%);
  color: var(--muted);
  pointer-events: none;
}
.harta-rezultatet {
  position: absolute;
  left: var(--space-3);
  right: var(--space-3);
  top: 100%;
  z-index: 4;
  max-height: 14rem;
  overflow-y: auto;
  margin: 0;
  padding: var(--space-1);
  list-style: none;
  background: var(--surface-raised);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-md);
}
.harta-rezultat {
  display: flex;
  align-items: baseline;
  gap: var(--space-2);
  padding: var(--space-1-5) var(--space-2);
  border-radius: var(--radius-xs);
  font-size: var(--text-sm);
  cursor: pointer;
}
.harta-rezultat:hover,
.harta-rezultat.is-zgjedhur { background: var(--surface-hover); }
.harta-rezultat-emri { color: var(--text); }
.harta-rezultat-afer {
  margin-left: auto;
  font-size: var(--text-2xs);
  color: var(--muted);
  white-space: nowrap;
}
.harta-kerkimi-fjala {
  margin: var(--space-1) 0 0;
  font-size: var(--text-2xs);
  color: var(--muted);
}
.harta-fundi { display: block; }
.harta-fundi > * { width: 100%; }
.harta-rreze-rresht {
  display: grid;
  grid-template-columns: auto 6rem 1fr auto;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-2);
}
.harta-slajder { accent-color: var(--primary); cursor: pointer; }
.harta-rreze-tekst {
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.harta-butonat {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1-5);
  margin-bottom: var(--space-2);
}
.harta-butonat .btn { flex: 1 1 auto; }
.harta-fund-rresht {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-2);
}
.harta-koordinatat {
  font-size: var(--text-sm);
  font-variant-numeric: tabular-nums;
  color: var(--muted);
}
.harta-fund-veprimet { display: flex; gap: var(--space-2); }
.harta-njoftim {
  margin: var(--space-2) 0 0;
  font-size: var(--text-sm);
  color: var(--muted);
}
.harta-njoftim.is-bad { color: var(--danger); }
.harta-njoftim.is-ok { color: var(--success); }
.harta-vetem-pamje { display: none; }
#hartaModal.is-pamje .harta-rreze-rresht,
#hartaModal.is-pamje .harta-butonat,
#hartaModal.is-pamje .harta-vetem-zone { display: none; }
#hartaModal.is-pamje .harta-vetem-pamje { display: inline-flex; }
#hartaModal.is-pamje .harta-kanavace { cursor: default; }
#hartaModal.is-pa-rreth .harta-rrethi { display: none; }
.passkey-list { list-style: none; margin: 0 0 var(--space-4); padding: 0; }
.passkey-item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) 0;
  border-bottom: 1px solid var(--border);
}
.passkey-item:last-child { border-bottom: 0; }
.passkey-name { font-weight: 600; }
.passkey-when { margin-left: auto; }
.auth-passkey { margin-top: var(--space-4); text-align: center; }
.auth-or {
  display: block;
  margin-bottom: var(--space-3);
  font-size: var(--text-xs);
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .12em;
}
.access-ask {
  margin-bottom: var(--space-4);
  padding: var(--space-4);
  border: 1px solid var(--warning);
  border-radius: var(--radius);
  background: var(--warning-soft);
}
.access-ask-head {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin: 0 0 var(--space-2);
  font-weight: 600;
}
.access-ask-say {
  margin: 0 0 var(--space-3);
  font-size: var(--text-sm);
  color: var(--muted);
}
.access-ask-who {
  margin: 0 0 var(--space-3);
  font-size: var(--text-sm);
  font-weight: 600;
}
.access-ask-form { display: grid; gap: var(--space-2); }
.access-ask-form .form-label {
  margin: 0;
  font-size: var(--text-xs);
  color: var(--muted);
}
.access-ask-quiet {
  border-color: var(--border);
  background: var(--surface-muted);
}
.access-ask-quiet > summary {
  cursor: pointer;
  font-size: var(--text-sm);
  color: var(--muted);
}
.access-ask-quiet[open] > summary { margin-bottom: var(--space-3); }
.access-list { display: grid; gap: var(--space-4); }
.access-card {
  padding: var(--space-4);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-muted);
}
.access-card.is-stale { opacity: .75; }
.access-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-3);
}
.access-card-name {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin: 0;
  font-size: var(--text-lg);
}
.access-card-meta {
  margin: var(--space-1) 0 0;
  font-size: var(--text-sm);
  color: var(--muted);
}
.access-facts {
  list-style: none;
  margin: var(--space-3) 0;
  padding: 0;
  display: grid;
  gap: var(--space-2);
  font-size: var(--text-sm);
}
.access-facts > li { display: flex; align-items: baseline; gap: var(--space-2); }
.access-facts > li > i { color: var(--muted); }
.access-note > span { font-style: italic; }
.access-warn { color: var(--warning); }
.access-decide {
  display: grid;
  gap: var(--space-2);
  padding-top: var(--space-3);
  border-top: 1px solid var(--border);
}
.access-decide .form-label {
  margin: 0;
  font-size: var(--text-xs);
  color: var(--muted);
}
.access-decide .form-control,
.access-decide .pw-wrap { width: min(16rem, 100%); }
.access-hours { display: flex; flex-wrap: wrap; gap: var(--space-2); }
.access-deny { margin-top: var(--space-3); }
.lock-main {
  display: grid;
  place-items: center;
  min-height: 100dvh;
  padding: var(--space-5);
cursor: pointer;
  user-select: none;
}
.lock-card { width: min(26rem, 100%); text-align: center; }
.lock-logo { border-radius: var(--radius-lg); }
.lock-title { margin: var(--space-4) 0 var(--space-1); font-size: var(--text-2xl); }
.lock-who { margin: 0; font-weight: 600; }
.lock-sub {
  margin: var(--space-2) 0 var(--space-5);
  font-size: var(--text-sm);
  color: var(--muted);
}
.lock-face {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  width: 100%;
  padding: var(--space-6) var(--space-4);
  margin-bottom: var(--space-2);
  font-size: var(--text-lg);
  font-weight: 600;
}
.lock-face .bi { font-size: var(--text-3xl); }
.lock-more { margin-top: var(--space-4); }
.lock-more > summary {
  cursor: pointer;
  font-size: var(--text-sm);
  color: var(--muted);
}
.lock-more[open] > summary { margin-bottom: var(--space-2); }
.lock-form { margin-top: var(--space-5); text-align: left; user-select: text; }
.lock-submit { margin-top: var(--space-3); }
.lock-note { margin-top: var(--space-4); font-size: var(--text-xs); color: var(--muted); }
.lock-flash { margin-top: var(--space-3); }
.lock-out {
  display: inline-block;
  margin-top: var(--space-5);
  font-size: var(--text-sm);
  color: var(--muted);
}
.push-note { margin-top: var(--space-4); }
.otp-input {
  letter-spacing: .4em;
  font-size: var(--text-2xl);
}
.edi-pass.is-masked {
  -webkit-text-security: disc;
  text-security: disc;
}
.subj-menu { max-height: 17rem; overflow-y: auto; min-width: 20rem; }
.subj-menu .form-check-input { flex: 0 0 auto; }
.subj-dd .subj-toggle { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.subj-row { display: flex; align-items: flex-start; gap: var(--space-2); }
.subj-row[hidden] { display: none !important; }
.rule-col.dd-open { position: relative; z-index: 1080; }
.rule-col.dd-open .card { overflow: visible; }
.subj-dd .dropdown-menu { z-index: 1085; }
.biz-menu { width: min(20rem, calc(100vw - 1.5rem)); }
.biz-menu .form-check-input { flex: 0 0 auto; }
.biz-list { max-height: 14rem; overflow-y: auto; }
.biz-row { display: flex; align-items: flex-start; gap: var(--space-2); }
.biz-row[hidden] { display: none !important; }
.access-menu { max-height: 15rem; overflow-y: auto; min-width: 14rem; }
.access-menu .form-check-input { flex: 0 0 auto; }
.decl-child { padding-left: var(--space-4); }
.access-dd .access-toggle { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qr-box svg { width: 220px; height: 220px; max-width: 100%; display: block; }
@media print {
  nav.navbar,
  aside.sidebar,
  .app-sidebar,
  .app-topbar,
  .no-print,
  .toast-container,
  .toast-stack,
  .bottom-nav {
    display: none !important;
  }
body { background: #fff !important; color: #000 !important; }
  body::before { display: none !important; }
body::after { display: none !important; }
.app-shell::after { display: none !important; }
main, .app-content {
    width: 100% !important;
    max-width: 100% !important;
    flex: 0 0 100% !important;
    padding: 0 !important;
    animation: none !important;
  }
.statement-sheet { border: 0 !important; box-shadow: none !important; }
  .statement-sheet .card-body { padding: 0 !important; }
.table { font-size: 11pt; }
.table-light th,
  .table-light td,
  thead.table-light tr {
    background-color: #f1f1f1 !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
.table-bordered th, .table-bordered td { border-color: #999 !important; }
tr, .row { page-break-inside: avoid; }
  h5 { page-break-after: avoid; }
a { text-decoration: none !important; color: #000 !important; }
@page { margin: 1.5cm; }
}
:where(a, button, .btn, .form-control, .form-select, .form-check-input,
       [tabindex]:not([tabindex="-1"])):focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}
.skip-link {
  position: absolute;
  left: .5rem;
  top: -3rem;
  z-index: 4000;
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-sm);
  background: var(--primary);
  color: var(--primary-contrast);
  font-weight: 600;
  transition: top var(--dur-2) var(--ease-out);
}
.skip-link:focus { top: .5rem; color: #fff; }
.reveal { opacity: 1; transform: none; }
.js-reveal .reveal {
  opacity: 0;
transform: translateY(12px) scale(.985);
  transition: opacity var(--dur-3) var(--ease-out), transform var(--dur-3) var(--ease-out);
  transition-delay: var(--reveal-delay, 0ms);
}
.js-reveal .reveal.in { opacity: 1; transform: none; }
.js-reveal .reveal:nth-child(2) { --reveal-delay: 50ms; }
.js-reveal .reveal:nth-child(3) { --reveal-delay: 100ms; }
.js-reveal .reveal:nth-child(n+4) { --reveal-delay: 140ms; }
.stagger > * { animation: pageIn var(--dur-3) var(--ease-out) both; }
.stagger > *:nth-child(1) { animation-delay: .02s; }
.stagger > *:nth-child(2) { animation-delay: .07s; }
.stagger > *:nth-child(3) { animation-delay: .12s; }
.stagger > *:nth-child(4) { animation-delay: .17s; }
.stagger > *:nth-child(5) { animation-delay: .22s; }
.stagger > *:nth-child(6) { animation-delay: .27s; }
.stagger > *:nth-child(n+7) { animation-delay: .3s; }
.app-content .page-head:not(.bi-hero) .page-head-main > *,
.app-content .page-head:not(.bi-hero) > .page-actions {
  animation: pageIn var(--dur-3) var(--ease-out) both;
}
.app-content .page-head:not(.bi-hero) .page-head-main > *:nth-child(2) { animation-delay: .05s; }
.app-content .page-head:not(.bi-hero) .page-head-main > *:nth-child(n+3) { animation-delay: .1s; }
.app-content .page-head:not(.bi-hero) > .page-actions { animation-delay: .14s; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }
  .collapse-card:hover,
  .stat-card:hover,
  .card-lift:hover,
  .task-card:hover,
  .btn-primary:hover,
  .icon-btn:hover,
  .topbar-back:hover i,
.bi-report .bi-card:not(.bi-focused):hover,
  .btn:active {
    transform: none;
  }
  .js-reveal .reveal { opacity: 1; transform: none; }
.present-progress.is-running { transform: scaleX(1); }
.is-busy::before,
.cmdk-backdrop.is-searching .cmdk-spinner {
    animation-duration: var(--beat) !important;
    animation-iteration-count: infinite !important;
  }
body::after { animation: none; }
.stagger > *,
  .app-content .page-head .page-head-main > *,
  .app-content .page-head > .page-actions {
    animation-delay: 0s !important;
  }
.bi-tick-track { animation: none; }
.bi-tick-window { overflow-x: auto; mask-image: none; }
.bi-tick-run[aria-hidden="true"] { display: none; }
}
.form-select.is-uploaded {
  border-color: var(--success);
  background-color: var(--success-soft);
}
.form-select option.is-uploaded { color: var(--success); }
.btn-check:disabled + .btn.is-uploaded { opacity: 1; }
.owner-picker { position: relative; }
.owner-picker .js-owner-toggle {
cursor: pointer;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.owner-picker.has-selection .js-owner-toggle {
  border-color: var(--primary);
  box-shadow: 0 0 0 var(--ring-w) var(--primary-soft);
}
.owner-menu {
  position: absolute;
  z-index: 20;
  left: 0;
  right: 0;
  margin-top: var(--space-1);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.owner-menu-head {
  padding: var(--space-2) var(--space-3);
  border-bottom: 1px solid var(--border);
  background: var(--surface-muted);
}
.owner-menu-actions {
  display: flex;
  align-items: center;
  gap: var(--space-1-5);
  margin-top: var(--space-2);
  flex-wrap: wrap;
}
.owner-menu-list { max-height: 15rem; overflow-y: auto; }
.owner-option {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-1-5) var(--space-3);
  margin: 0;
  cursor: pointer;
  font-size: var(--text-sm);
}
.owner-option:hover { background: var(--surface-muted); }
.owner-option input { flex-shrink: 0; margin: 0; }
.owner-option-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.owner-picker.is-invalid-picker .js-owner-toggle {
  border-color: var(--danger);
  animation: ownerNudge var(--dur-3) var(--ease-in-out) 2;
}
@keyframes ownerNudge {
  0%, 100% { transform: translateX(0); }
  25%      { transform: translateX(-4px); }
  75%      { transform: translateX(4px); }
}
.doc-mix {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1);
  margin-top: var(--space-0);
}
.doc-mix-chip {
  font-size: var(--text-2xs);
  font-weight: 500;
  line-height: 1.5;
  padding: 0 var(--space-1-5);
  border-radius: var(--radius-pill);
  background: var(--surface-hover);
  color: var(--muted);
  white-space: nowrap;
}
.doc-mix-chip.is-more { background: var(--primary-soft); color: var(--primary-text); }
.doc-recent-row {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding-top: var(--space-2);
  padding-bottom: var(--space-2);
}
.doc-recent-icon { color: var(--muted); flex-shrink: 0; }
.doc-recent-main { min-width: 0; flex: 1; }
.doc-recent-name {
  display: block;
  font-weight: 600;
  font-size: var(--text-sm);
  text-decoration: none;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.doc-recent-meta {
  display: block;
  font-size: var(--text-xs);
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.doc-recent-when {
  flex-shrink: 0;
  font-size: var(--text-xs);
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.doc-crumbs {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-1-5);
  font-size: var(--text-md);
}
.doc-crumbs a {
  color: var(--muted);
  text-decoration: none;
  padding: var(--space-0) var(--space-2);
  border-radius: var(--radius-sm);
}
.doc-crumbs a:hover { color: var(--primary); background: var(--primary-soft); }
.doc-crumbs .bi-chevron-right { font-size: var(--text-xs); color: var(--muted); opacity: .6; }
.doc-crumbs .current { font-weight: 600; color: var(--text); padding: var(--space-0) var(--space-2); }
.folder-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr));
  gap: var(--space-3);
}
.folder-grid-sm { grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr)); }
.folder-card {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  text-decoration: none;
  color: var(--text);
  transition: transform var(--dur-2) var(--ease-out), box-shadow var(--dur-2) var(--ease-out), border-color var(--dur-2) var(--ease-out);
}
.folder-card:hover {
  transform: translateY(-2px);
  border-color: var(--primary);
  box-shadow: var(--shadow-md);
  color: var(--text);
}
.folder-card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  border-radius: var(--radius);
  font-size: var(--text-lg);
  color: #fff;
  background: var(--grad-primary);
}
.folder-card-body { display: flex; flex-direction: column; min-width: 0; }
.folder-card-name {
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.folder-card-meta { font-size: var(--text-xs); color: var(--muted); }
.folder-card-go { margin-left: auto; color: var(--muted); opacity: .5; font-size: var(--text-sm); }
.folder-card.is-empty .folder-card-icon { background: var(--surface-muted); color: var(--muted); }
.folder-card.is-empty .folder-card-name { color: var(--muted); font-weight: 500; }
.voice-note {
  margin: var(--space-3) 0 0;
  padding: var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-muted);
}
.voice-bar { display: flex; align-items: center; gap: var(--space-2); flex-wrap: wrap; }
.voice-mic {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  border: 0;
  border-radius: var(--radius-round);
  color: #fff;
  font-size: var(--text-base);
  background: var(--grad-primary);
  box-shadow: var(--shadow-sm);
  transition: transform var(--dur-1) var(--ease-out), box-shadow var(--dur-2) var(--ease-out), background var(--dur-2) var(--ease-out);
}
.voice-mic:hover { transform: translateY(-1px); box-shadow: var(--shadow-glow); }
.voice-mic:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.voice-note.is-recording .voice-mic {
  background: var(--danger);
  animation: voice-pulse var(--beat) var(--ease-in-out) infinite;
}
@keyframes voice-pulse {
  0%, 100% { box-shadow: 0 0 0 0 var(--danger-soft); }
  50% { box-shadow: 0 0 0 .55rem transparent; }
}
@media (prefers-reduced-motion: reduce) {
  .voice-note.is-recording .voice-mic { animation: none; }
}
.voice-text { font-size: var(--text-sm); color: var(--muted); flex: 1 1 12rem; min-width: 0; }
.voice-text-ok { color: var(--success); }
.voice-text-bad { color: var(--danger); }
.voice-timer {
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  color: var(--danger);
}
.voice-list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-2); }
.voice-item:first-child { margin-top: var(--space-3); }
.voice-item {
  padding: var(--space-2) var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
}
.voice-item-head {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-sm);
  color: var(--muted);
  margin-bottom: var(--space-1-5);
}
.voice-item-who { color: var(--text); }
.voice-item-when { margin-left: auto; }
.voice-item audio { width: 100%; height: 34px; display: block; }
.voice-del {
  border: 0;
  background: none;
  padding: 0 var(--space-0);
  color: var(--muted);
  line-height: 1;
}
.voice-del:hover { color: var(--danger); }
.voice-empty { margin-top: var(--space-2); }
.voice-note-inline {
  margin-top: var(--space-2);
  padding: var(--space-2);
  background: transparent;
  border-style: dashed;
}
.voice-note-inline .voice-mic { width: 34px; height: 34px; font-size: var(--text-md); }
.voice-note-chat { margin: 0; padding: 0; border: 0; background: none; }
.voice-bar-chat { min-height: 0; margin-bottom: 0; }
.voice-bar-chat:not(:empty) .voice-text:not(:empty) { margin-bottom: var(--space-1-5); }
.tm-composer .voice-mic {
  width: auto;
  height: auto;
  border-radius: var(--radius-sm);
  background: none;
  color: inherit;
  box-shadow: none;
}
.tm-composer .voice-mic:hover { transform: none; box-shadow: none; }
.voice-note-chat.is-recording .voice-mic { color: #fff; border-color: var(--danger); }
.voice-bar-chat .voice-text { flex: 1 1 auto; }
.tm-voice { display: flex; align-items: center; gap: var(--space-2); margin: var(--space-0) 0; }
.tm-voice-icon { color: var(--tm-accent); flex-shrink: 0; }
.tm-voice audio { height: 34px; max-width: 15rem; flex: 1 1 auto; min-width: 0; }
.tm-voice-len {
  font-size: var(--text-xs);
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.tm-call {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-pill);
  background: var(--surface-muted);
  border: 1px solid var(--border);
  color: var(--muted);
  font-size: var(--text-sm);
  font-variant-numeric: tabular-nums;
}
.tm-call.is-missed {
  background: var(--danger-soft);
  border-color: color-mix(in srgb, var(--danger) 25%, transparent);
  color: var(--danger);
}
.note-dot {
  position: absolute;
  top: -2px;
  right: -2px;
  min-width: 1.05rem;
  padding: var(--space-0) var(--space-1);
  background: var(--grad-primary);
  color: #fff;
  font-size: var(--text-2xs);
  font-weight: 700;
  line-height: 1.25;
  border-radius: var(--radius-pill);
  text-align: center;
  box-shadow: var(--ring-cut);
}
.note-menu { width: min(22rem, calc(100vw - 1.5rem)); padding-bottom: var(--space-1); }
.note-menu-body { max-height: 22rem; overflow-y: auto; }
.note-menu .dropdown-item { white-space: normal; }
.note-unread { background: var(--primary-soft); }
.note-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 34px;
  height: 34px;
  border-radius: var(--radius);
  background: var(--primary-soft);
  color: var(--primary);
  box-shadow: inset 0 0 0 var(--hairline) var(--primary-line);
}
.print-head { display: none; }
@media print {
  @page { margin: 14mm 12mm; }
.app-sidebar, .app-topbar, .bottom-nav, .toast-stack, .skip-link,
  .cmdk-backdrop, .sheet-backdrop, .offcanvas-backdrop, .modal, .modal-backdrop,
  .page-actions, .net-chip, .btn-close, .dropdown-menu, .page-head-toggle,
  .tbl-col-actions { display: none !important; }
html, body {
    background: #fff !important;
    color: #000 !important;
  }
:root {
    --ground-ink: #000;
    --ground-ink-muted: #333;
    --ground-accent: #000;
    --ground-success: #000;
    --ground-warning: #000;
    --ground-danger: #000;
    --ground-info: #000;
    --ground-wash: transparent;
    --ground-line: rgba(0,0,0,.25);
  }
.app-shell, .app-main, .app-content {
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
    max-width: none !important;
    width: auto !important;
    height: auto !important;
    overflow: visible !important;
  }
.stagger > *,
  .app-content .page-head .page-head-main > *,
  .app-content .page-head > .page-actions {
    animation: none !important;
  }
.print-head {
    display: flex !important;
    align-items: baseline;
    justify-content: space-between;
    gap: var(--space-4);
    padding-bottom: var(--space-1-5);
    margin-bottom: var(--space-3);
    border-bottom: 2px solid #000;
  }
  .print-brand { display: inline-flex; align-self: center; }
  .print-brand .cpc-logo { width: 28px; height: 28px; }
  .print-title { font-weight: 700; }
  .print-meta { font-size: var(--text-xs); text-align: right; line-height: 1.35; }
.card, .table-card, .stat-card, .bi-card {
    box-shadow: none !important;
    border: 1px solid #999 !important;
    background: #fff !important;
    backdrop-filter: none !important;
    break-inside: avoid;
    page-break-inside: avoid;
  }
  .stat-grid { display: grid !important; grid-template-columns: repeat(4, 1fr); gap: var(--space-2); }
  .stat-value { font-size: var(--text-lg) !important; }
.stat-go { display: none !important; }
.card-header:has(> .toolbar-filters),
.card-header:has(> .part-filters) { display: none !important; }
  body:has(.card-header > .toolbar-filters) .app-content > .page-head ~ .stat-grid,
  body:has(.card-header > .toolbar-filters) .app-content .page-figs {
    display: none !important;
  }
.table-responsive, .table-sticky {
    max-height: none !important;
    overflow: visible !important;
  }
.card.table-card {
    break-inside: auto;
    page-break-inside: auto;
    overflow: visible;
  }
  table.table thead { display: table-header-group; }
  table.table tfoot { display: table-footer-group; }
  table.table tr { break-inside: avoid; page-break-inside: avoid; }
  table.table { font-size: var(--text-xs); width: 100% !important; }
  table.table th, table.table td { padding: var(--space-1) var(--space-1-5) !important; }
  .table-hover > tbody > tr:hover > * { background: transparent !important; }
.chip {
    background: transparent !important;
    color: #000 !important;
    border: 1px solid #666 !important;
  }
body.head-mini .page-eyebrow,
  body.head-mini .page-sub { display: block !important; }
  body.head-mini .page-crumbs,
  body.head-mini .page-figs { display: flex !important; }
  body.head-mini .page-head:not(.bi-hero) .page-title { font-size: var(--display-sm); }
  body.head-mini .load-rail,
  body.head-mini .filter-bar,
  body.head-mini .filter-quick { display: flex !important; }
  body.head-mini .page-head-fold { display: block !important; }
  body.head-mini .app-content > .page-head ~ .stat-grid { display: grid !important; }
  body.head-mini .app-content > .page-head ~ .alert.notice,
  body.head-mini .app-content > .section-title:has(+ .filter-bar) { display: flex !important; }
  body.head-mini .vat-now { display: grid !important; }
body.head-mini .worklist-card,
  body.head-mini .bi-surface > .alarm-panel { display: block !important; }
  body.head-mini .bi-surface > .stat-grid { display: grid !important; }
.collapse:not(.show) { display: block !important; }
h1, h2, h3, h4, .page-title { break-after: avoid; page-break-after: avoid; }
  a { text-decoration: none !important; color: #000 !important; }
}
.pulse-chip {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1-5);
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-pill);
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--success);
  background: var(--success-soft);
  white-space: nowrap;
}
.pulse-chip.is-stale { color: var(--muted); background: var(--surface-sunken); }
.app-content > .page-head:not(.bi-hero) .pulse-chip {
  background: var(--ground-shade);
  color: var(--ground-success);
}
.page-head.bi-hero .pulse-chip {
  background: var(--bi-visual);
  border: 1px solid var(--bi-line);
}
.pulse-chip.is-stale .pulse-dot { background: var(--faint); animation: none; box-shadow: none; }
@keyframes pulseChanged {
  0%   { background: var(--primary-soft); }
  100% { background: transparent; }
}
.pulse-changed {
  animation: pulseChanged var(--beat) var(--ease-out);
  border-radius: var(--radius-xs);
}
@media (prefers-reduced-motion: reduce) {
  .pulse-changed { animation: none; }
}
.kpi-delta {
  display: inline-flex;
  align-items: center;
  font-weight: 700;
  font-size: var(--text-xs);
  font-variant-numeric: tabular-nums;
}
.kpi-delta.is-up { color: var(--success); }
.kpi-delta.is-down { color: var(--danger); }
.kpi-delta.is-none { color: var(--faint); font-weight: 600; }
.kpi-delta i { font-size: 1.1em; margin-left: calc(var(--space-0) * -1); }
.mini-chart {
  display: flex;
  align-items: flex-end;
  gap: var(--space-2);
  height: 132px;
}
.mini-col { flex: 1; display: flex; flex-direction: column; height: 100%; min-width: 0; }
.mini-bars {
  flex: 1;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: var(--space-0);
}
.mini-bar {
  display: block;
  width: 46%;
  max-width: 22px;
min-height: 2px;
  border-radius: var(--radius-xs) var(--radius-xs) 0 0;
  transition: height var(--dur-3) var(--ease-out);
}
.mini-bar.is-sale { background: var(--chart-revenue); }
.mini-bar.is-purchase { background: var(--chart-expense); }
.mini-label {
  text-align: center;
  font-size: var(--text-xs);
  color: var(--muted);
  padding-top: var(--space-1-5);
  border-top: 1px solid var(--border);
  margin-top: var(--space-1);
  white-space: nowrap;
}
.mini-col.is-now .mini-label { color: var(--text); font-weight: 700; }
.mini-now {
  font-size: var(--text-2xs);
  font-weight: 700;
  color: var(--primary-text);
  background: var(--primary-soft);
  border-radius: var(--radius-pill);
  padding: 0 var(--space-1-5);
}
.mini-legend { display: inline-flex; gap: var(--space-4); font-size: var(--text-xs); color: var(--muted); }
.mini-legend span { display: inline-flex; align-items: center; gap: var(--space-1-5); }
.mini-dot {
  display: inline-block;
  width: .6rem;
  height: .6rem;
  border-radius: var(--radius-xs);
  margin-right: var(--space-1-5);
  vertical-align: -1px;
}
.mini-dot.is-sale { background: var(--chart-revenue); }
.mini-dot.is-purchase { background: var(--chart-expense); }
.mini-table { font-size: var(--text-xs); }
.mini-table td, .mini-table th { font-variant-numeric: tabular-nums; }
.mini-col-link {
  text-decoration: none;
  color: inherit;
  border-radius: var(--radius-sm);
  padding: var(--space-1) var(--space-0) 0;
  transition: background var(--dur-2) var(--ease-out);
}
.mini-col-link:hover { background: var(--surface-hover); color: inherit; }
.mini-col-link:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.mini-col.is-picked { background: var(--primary-soft); }
.mini-col.is-picked .mini-label { color: var(--primary-text); font-weight: 700; }
@media (max-width: 575.98px) {
.mini-chart { overflow-x: auto; }
  .mini-col { min-width: 46px; }
}
.dup-group + .dup-group { margin-top: var(--space-4); }
.dup-head {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  flex-wrap: wrap;
  font-size: var(--text-md);
  margin-bottom: var(--space-1-5);
}
.dup-head > i { color: var(--warning); }
.dup-rows {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
}
.dup-row {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  flex-wrap: wrap;
  padding: var(--space-2) var(--space-3);
  font-size: var(--text-sm);
  text-decoration: none;
  color: inherit;
  background: var(--warning-soft);
}
.dup-row + .dup-row { border-top: 1px solid var(--border); }
.dup-row:hover { background: var(--surface-hover); color: inherit; }
.inv-signal { text-decoration: none; color: inherit; display: block; }
.inv-signal:hover { background: var(--surface-hover); color: inherit; }
.inv-signal:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.inv-signal.is-picked {
  border-color: var(--primary);
  box-shadow: 0 0 0 var(--ring-w-lg) var(--primary-soft);
}
.inv-signal.is-picked .inv-signal-top { color: var(--primary-text); }
.inv-gaps {
  margin-top: var(--space-3);
  display: flex;
  flex-direction: column;
  gap: var(--space-1-5);
}
.inv-gap {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: var(--space-2);
  font-size: var(--text-sm);
}
.inv-gap-name { font-weight: 600; text-decoration: none; }
.inv-gap-nums { display: flex; flex-wrap: wrap; gap: var(--space-1); }
.inv-gap-num {
  font-variant-numeric: tabular-nums;
  font-size: var(--text-xs);
  padding: var(--space-0) var(--space-1-5);
  border: 1px dashed var(--danger-fill);
  border-radius: var(--radius-sm);
  color: var(--danger);
  background: var(--danger-soft);
}
.inv-sub {
  display: block;
  font-size: var(--text-xs);
  font-weight: 400;
  color: var(--faint);
  line-height: 1.35;
max-width: 9rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.inv-num { font-variant-numeric: tabular-nums; }
.inv-rate {
  display: inline-block;
  margin-left: var(--space-1-5);
  padding: 0 var(--space-1);
  border-radius: var(--radius-sm);
  background: var(--surface-muted);
  color: var(--faint);
  font-size: var(--text-2xs);
  font-variant-numeric: tabular-nums;
  vertical-align: .05em;
}
.row-act-btn.is-danger:hover,
.row-act-btn.is-danger:focus-visible {
  color: var(--danger);
  background: var(--danger-soft);
  border-color: var(--danger-fill);
}
.row-act-btn.is-locked { color: var(--warning); cursor: help; }
.timeline-item { display: flex; gap: var(--space-2); align-items: flex-start; }
.timeline-item:has(.timeline-icon)::before { content: none; }
.timeline-icon {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.6rem;
  height: 1.6rem;
  margin-left: -1.75rem;
  border-radius: var(--radius-round);
  font-size: var(--text-xs);
  background: var(--surface);
  color: var(--primary);
  box-shadow: inset 0 0 0 var(--ring-w) var(--primary-line);
}
.timeline-body { min-width: 0; }
.timeline-task .timeline-icon { color: var(--primary); }
.timeline-reminder .timeline-icon { color: var(--warning); box-shadow: inset 0 0 0 var(--ring-w) var(--warning-soft); }
.timeline-announcement .timeline-icon { color: var(--accent); box-shadow: inset 0 0 0 var(--ring-w) var(--accent-soft); }
.timeline-meeting .timeline-icon { color: var(--info); box-shadow: inset 0 0 0 var(--ring-w) var(--info-soft); }
a.timeline-item.is-linked {
  text-decoration: none;
  color: inherit;
  border-radius: var(--radius-sm);
  padding-right: var(--space-1-5);
}
a.timeline-item.is-linked:hover { background: var(--surface-hover); }
a.timeline-item.is-linked:hover .small { color: var(--primary-text); }
@media print {
.pulse-chip, #pulseNew { display: none !important; }
.deadline-extra.d-none { display: flex !important; }
}
a.stat-card-filter { color: inherit; text-decoration: none; }
a.stat-card-filter:hover .stat-label { color: var(--primary-text); }
.cl-aging {
  display: flex;
  height: .7rem;
  border-radius: var(--radius-pill);
  overflow: hidden;
  background: var(--surface-muted);
  box-shadow: inset 0 0 0 var(--hairline) var(--border);
}
.cl-aging-seg { width: var(--seg, 0%); min-width: 2px; }
.cl-aging-seg.is-now { background: var(--success-fill); }
.cl-aging-seg.is-mid { background: var(--warning-fill); }
.cl-aging-seg.is-old { background: var(--danger-fill); }
.cl-aging-keys {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-2);
  font-size: var(--text-xs);
  color: var(--muted);
}
.cl-aging-key::before {
  content: '';
  display: inline-block;
  width: .55rem;
  height: .55rem;
  margin-inline-end: var(--space-1-5);
  border-radius: var(--radius-round);
  vertical-align: baseline;
}
.cl-aging-key.is-now::before { background: var(--success-fill); }
.cl-aging-key.is-mid::before { background: var(--warning-fill); }
.cl-aging-key.is-old::before { background: var(--danger-fill); }
.cl-aging-pct { color: var(--faint); font-variant-numeric: tabular-nums; }
.chip-count {
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  opacity: .7;
}
.cl-ident { display: flex; align-items: center; gap: var(--space-2); min-width: 0; }
.cl-ident-main { min-width: 0; }
.cl-ident-name { font-weight: 600; color: inherit; text-decoration: none; }
.cl-ident-name:hover { color: var(--primary-text); text-decoration: underline; }
.cl-ident-meta {
  font-size: var(--text-xs);
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.cl-ident-num { font-variant-numeric: tabular-nums; }
.cl-contact { color: inherit; text-decoration: none; }
.cl-contact:hover { color: var(--primary-text); text-decoration: underline; }
.cl-ok { color: var(--success); }
.cl-flags { display: inline-flex; gap: var(--space-1); margin-inline-start: var(--space-1); }
.cl-flag { color: var(--faint); font-size: var(--text-sm); }
.row-act { display: inline-flex; align-items: center; justify-content: flex-end; gap: var(--space-1); }
.row-act-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.85rem;
  height: 1.85rem;
  padding: 0;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--muted);
  font-size: var(--text-md);
  line-height: 1;
  text-decoration: none;
}
tr:hover > td .row-act-btn { color: var(--text); }
.row-act-btn:hover,
.row-act-btn:focus-visible {
  color: var(--primary-text);
  background: var(--primary-soft);
  border-color: var(--primary-line);
}
.peek-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(8.5rem, 1fr));
  gap: var(--space-3);
  margin-bottom: var(--space-4);
}
.peek-fig {
  padding: var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-muted);
}
.peek-label {
  font-size: var(--text-2xs);
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--faint);
}
.peek-value {
  font-size: var(--text-lg);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.peek-fig-good .peek-value { color: var(--success); }
.peek-fig-warn .peek-value { color: var(--warning); }
.peek-fig-bad  .peek-value { color: var(--danger); }
.peek-gaps { margin-bottom: var(--space-4); }
.peek-block + .peek-block { margin-top: var(--space-4); }
.peek-block-title {
  font-size: var(--text-2xs);
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--faint);
  margin-bottom: var(--space-2);
}
.peek-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--space-3);
  padding: var(--space-1-5) 0;
  border-bottom: 1px solid var(--border);
  font-size: var(--text-sm);
}
.peek-row:last-child { border-bottom: 0; }
.peek-row-main { min-width: 0; overflow-wrap: anywhere; }
.peek-row-side {
  flex-shrink: 0;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.peek-row-late .peek-row-side { color: var(--danger); font-weight: 700; }
.peek-empty {
  font-size: var(--text-sm);
  color: var(--faint);
  padding: var(--space-1-5) 0;
}
.peek-actions {
  margin-top: var(--space-4);
  padding-top: var(--space-3);
  border-top: 1px solid var(--border);
}
.peek-actions-row { display: flex; flex-wrap: wrap; gap: var(--space-2); }
.ai-thread {
max-height: min(52vh, 560px);
min-height: min(52vh, 560px);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}
.ai-thread > .empty-state { margin: auto; }
.ai-msg { max-width: min(46rem, 100%); min-width: 0; }
.ai-msg-user { align-self: flex-end; }
.ai-msg-assistant { align-self: flex-start; }
.ai-msg-who {
  display: flex;
  align-items: center;
  gap: var(--space-1-5);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--faint);
  margin-bottom: var(--space-1);
}
.ai-msg-user .ai-msg-who { justify-content: flex-end; }
.ai-msg-time { font-weight: 500; text-transform: none; letter-spacing: 0; }
.ai-msg-body {
white-space: pre-wrap;
  overflow-wrap: anywhere;
  padding: var(--space-3);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  line-height: 1.55;
}
.ai-msg-user .ai-msg-body {
  background: var(--accent-soft);
  border-color: color-mix(in srgb, var(--accent) 35%, transparent);
}
.ai-msg-assistant .ai-msg-body { background: var(--surface, transparent); }
.ai-examples { display: flex; flex-wrap: wrap; gap: var(--space-2); justify-content: center; }
.ai-msg-failed { border-color: var(--danger); color: var(--danger); }
.ai-warn {
  display: flex;
  align-items: flex-start;
  gap: var(--space-2);
  margin-top: var(--space-2);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius);
  border: var(--hairline) solid color-mix(in srgb, var(--danger) 30%, transparent);
  border-left: var(--rail) solid var(--danger);
  background: var(--danger-soft);
  color: var(--danger);
  font-size: var(--text-sm);
  line-height: 1.5;
}
.ai-warn-icon { flex: 0 0 auto; margin-top: .15em; }
.ai-warn-text { overflow-wrap: anywhere; }
.ai-typing { display: inline-flex; gap: var(--space-1); align-items: center; padding: var(--space-0) 0; }
.ai-typing i {
  width: .45rem; height: .45rem; border-radius: var(--radius-round);
  background: var(--faint);
  animation: ai-typing-dot var(--beat-fast) infinite var(--ease-in-out);
}
.ai-typing i:nth-child(2) { animation-delay: .15s; }
.ai-typing i:nth-child(3) { animation-delay: .3s; }
@keyframes ai-typing-dot {
  0%, 60%, 100% { opacity: .25; transform: translateY(0); }
  30% { opacity: 1; transform: translateY(-.15rem); }
}
@media (prefers-reduced-motion: reduce) {
  .ai-typing i { animation: none; opacity: .5; }
}
.ai-box { position: relative; }
.ai-box textarea { padding-bottom: 2.75rem; min-height: 6rem; }
.ai-tools {
  position: absolute;
  right: .5rem;
  bottom: .5rem;
  display: flex;
  gap: var(--space-1);
}
.ai-tool {
  display: inline-flex;
  align-items: center;
  justify-content: center;
width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--radius-round);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  cursor: pointer;
  transition: background var(--dur-2) var(--ease-out), color var(--dur-2) var(--ease-out), border-color var(--dur-2) var(--ease-out);
}
.ai-tool:hover, .ai-tool:focus-visible { color: var(--primary-text); border-color: var(--primary-line); }
.ai-tool.is-on {
  background: var(--danger-soft);
  border-color: var(--danger);
  color: var(--danger);
  animation: ai-mic-pulse var(--beat) infinite var(--ease-in-out);
}
@keyframes ai-mic-pulse {
  0%, 100% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--danger) 45%, transparent); }
  50% { box-shadow: 0 0 0 .45rem transparent; }
}
@media (prefers-reduced-motion: reduce) { .ai-tool.is-on { animation: none; } }
.ai-file-chip {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1-5);
  margin-top: var(--space-2);
  padding: var(--space-1) var(--space-2);
  font-size: var(--text-sm);
  border-radius: var(--radius-pill);
  background: var(--accent-soft);
  border: 1px solid var(--border);
  max-width: 100%;
  overflow-wrap: anywhere;
}
.ai-docs {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  padding: var(--space-3);
}
.ai-docs-head {
  font-size: var(--text-sm);
  font-weight: 700;
  color: var(--muted);
  margin-bottom: var(--space-2);
}
.ai-docs-grid {
  display: grid;
grid-template-columns: repeat(auto-fill, minmax(min(100%, 13rem), 1fr));
  gap: var(--space-3);
}
.ai-doc { margin: 0; }
.ai-doc-shot {
  position: relative;
  display: block;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface-2, var(--surface));
  aspect-ratio: 4 / 3;
}
.ai-doc-shot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
background: #fff;
}
.ai-doc-icon {
  display: none;
  position: absolute;
  inset: 0;
  align-items: center;
  justify-content: center;
  font-size: var(--text-3xl);
  color: var(--faint);
}
.ai-doc-flat .ai-doc-shot img { display: none; }
.ai-doc-flat .ai-doc-icon { display: flex; }
.ai-doc figcaption { display: flex; flex-direction: column; margin-top: var(--space-1-5); }
.ai-doc-title { font-size: var(--text-sm); font-weight: 600; overflow-wrap: anywhere; }
.ai-doc-meta { font-size: var(--text-xs); color: var(--faint); }
.ai-doc-snippet {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-top: var(--space-1);
  padding-left: var(--space-2);
  border-left: 2px solid var(--border);
  font-size: var(--text-xs);
  font-style: italic;
  color: var(--muted, var(--faint));
}
.ai-plan {
  border: 1px solid var(--warning);
  border-radius: var(--radius);
  background: var(--warning-soft);
  padding: var(--space-3);
}
.ai-plan-head { display: flex; align-items: center; gap: var(--space-2); flex-wrap: wrap; }
.ai-plan-note { font-size: var(--text-sm); color: var(--muted); margin: var(--space-2) 0 var(--space-3); }
.ai-plan-hint { font-size: var(--text-xs); color: var(--faint); margin: var(--space-1-5) 0 var(--space-3); }
.ai-plan-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-1-5);
max-height: 15rem;
  overflow-y: auto;
  padding: var(--space-2);
  border-radius: var(--radius-sm);
  background: var(--surface);
  border: 1px solid var(--border);
}
.ai-plan-row { display: flex; flex-wrap: wrap; gap: var(--space-1) var(--space-2); align-items: baseline; }
.ai-plan-who { font-weight: 600; }
.ai-plan-why { font-size: var(--text-sm); color: var(--muted); }
.ai-plan-text { font-size: var(--text-sm); color: var(--faint); flex-basis: 100%; }
.ai-plan-actions { display: flex; gap: var(--space-2); flex-wrap: wrap; margin-top: var(--space-3); }
.ai-job-fields {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(14rem, 100%), 1fr));
  gap: var(--space-2) var(--space-3);
  margin-top: var(--space-2);
}
.ai-job-field { min-width: 0; }
@media (max-width: 991.98px) {
  .page-aside > .ai-brief { order: -1; }
}
.ai-brief-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 10rem), 1fr));
  gap: var(--space-2);
}
.ai-tile {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  gap: var(--space-0) var(--space-2);
  align-items: center;
  padding: var(--space-2) var(--space-3);
  border: 1px solid var(--border);
  border-left-width: 3px;
  border-radius: var(--radius);
  background: var(--surface);
  text-decoration: none;
  color: inherit;
}
a.ai-tile:hover { border-color: var(--primary, #4c6ef5); }
.ai-tile-icon { grid-row: span 2; font-size: var(--text-xl); color: var(--faint); }
.ai-tile-value { font-size: var(--text-lg); font-weight: 700; line-height: 1.1; }
.ai-tile-label { font-size: var(--text-xs); color: var(--muted); }
.ai-tile-danger { border-left-color: var(--danger, #e03131); }
.ai-tile-danger .ai-tile-icon { color: var(--danger, #e03131); }
.ai-tile-warn { border-left-color: var(--warning, #f08c00); }
.ai-tile-warn .ai-tile-icon { color: var(--warning, #f08c00); }
.ai-tile-info { border-left-color: var(--primary, #4c6ef5); }
.ai-table {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  padding: var(--space-3);
}
.ai-table-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--space-2);
  flex-wrap: wrap;
  margin-bottom: var(--space-2);
}
.ai-table-title { font-size: var(--text-sm); font-weight: 700; }
.ai-table-link { font-size: var(--text-xs); white-space: nowrap; }
.ai-table-scroll { overflow-x: auto; }
.ai-table-grid {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--text-sm);
  font-variant-numeric: tabular-nums;
}
.ai-table-grid th,
.ai-table-grid td {
  padding: var(--space-1-5) var(--space-2);
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
.ai-table-grid th {
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: .03em;
  color: var(--faint);
  font-weight: 700;
}
.ai-table-grid tbody tr:last-child td { border-bottom: 0; }
.ai-table-grid .num { text-align: right; }
.ai-table-grid td:first-child { white-space: normal; overflow-wrap: anywhere; }
.ai-bars { display: flex; flex-direction: column; gap: var(--space-1); margin-top: var(--space-3); }
.ai-bar { display: grid; grid-template-columns: minmax(3.5rem, 8rem) 1fr; gap: var(--space-2); align-items: center; }
.ai-bar-label { font-size: var(--text-xs); color: var(--muted); overflow-wrap: anywhere; }
.ai-bar-track {
  display: block;
  height: .5rem;
  border-radius: var(--radius-pill);
  background: var(--surface-2, rgba(127, 127, 127, .16));
  overflow: hidden;
}
.ai-bar-track i {
  display: block;
  height: 100%;
  border-radius: var(--radius-pill);
  background: var(--primary, #4c6ef5);
}
.ai-table-empty { font-size: var(--text-sm); color: var(--muted); margin: var(--space-1) 0; }
.ai-count { display: flex; align-items: baseline; gap: var(--space-2); flex-wrap: wrap; }
.ai-count-n {
font-size: var(--display-md);
  font-weight: 800;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  color: var(--primary, #4c6ef5);
}
.ai-count-label { font-size: var(--text-sm); color: var(--muted); }
.ai-table-foot {
  font-size: var(--text-xs);
  color: var(--faint);
  margin: var(--space-2) 0 0;
}
.ai-thread-count {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--muted);
  white-space: nowrap;
}
.ai-find {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  color: var(--faint);
  margin: 0;
  min-width: 0;
}
.ai-find input { width: 12rem; max-width: 100%; }
.ai-find-empty {
  font-size: var(--text-sm);
  color: var(--muted);
  text-align: center;
  margin: var(--space-3) 0;
}
.ai-day {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-size: var(--text-2xs);
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--faint);
}
.ai-day::before,
.ai-day::after {
  content: '';
  flex: 1;
  height: var(--hairline);
  background: var(--border);
}
.ai-msg-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2) var(--space-3);
  flex-wrap: wrap;
  margin-top: var(--space-1);
  min-height: 1.35rem;
}
.ai-msg-user .ai-msg-foot { flex-direction: row-reverse; }
.ai-sign {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  flex-wrap: wrap;
  font-size: var(--text-2xs);
  color: var(--faint);
  min-width: 0;
}
.ai-sign-bit { display: inline-flex; align-items: center; gap: var(--space-1); }
.ai-sign-bit i { font-size: var(--text-xs); }
.ai-msg-acts {
  display: flex;
  gap: var(--space-0);
  opacity: 0;
  transition: opacity var(--dur-1) var(--ease-out);
}
.ai-msg:hover .ai-msg-acts,
.ai-msg:focus-within .ai-msg-acts { opacity: 1; }
@media (hover: none) {
  .ai-msg-acts { opacity: 1; }
}
.ai-act {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.6rem;
  height: 1.6rem;
  padding: 0;
  border: 0;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--faint);
  font-size: var(--text-xs);
  line-height: 1;
  cursor: pointer;
}
.ai-act:hover,
.ai-act:focus-visible { background: var(--surface-hover); color: var(--primary-text); }
.ai-act.is-done { color: var(--success); }
.ai-act.is-done .bi-clipboard::before { content: '\f26b'; }    
.ai-msg-stopped {
  border-left: var(--rail) solid var(--warning);
  color: var(--muted);
}
.ai-ask-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2) var(--space-3);
  flex-wrap: wrap;
  margin-top: var(--space-2);
}
.ai-hint {
  font-size: var(--text-xs);
  color: var(--muted);
  flex: 1 1 16rem;
  min-width: 0;
}
.ai-ask-send {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  flex-wrap: wrap;
}
.ai-chars {
  font-size: var(--text-xs);
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.ai-ask.is-drop {
  border-color: var(--primary);
  box-shadow: var(--glow-accent);
}
.ai-empty-more { font-size: var(--text-xs); color: var(--faint); margin: var(--space-3) 0 0; }
.copy-sink { position: fixed; opacity: 0; pointer-events: none; }
.ai-state {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  flex-wrap: wrap;
  margin-bottom: var(--space-2);
}
.ai-state-mark {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1-5);
  padding: var(--space-1) var(--space-2);
  border: 1px solid transparent;
  border-radius: var(--radius-pill);
  font-size: var(--text-2xs);
  font-weight: 700;
}
.ai-state-safe {
  background: var(--success-soft);
  border-color: color-mix(in srgb, var(--success) 30%, transparent);
  color: var(--success);
}
.ai-state-out {
  background: var(--warning-soft);
  border-color: color-mix(in srgb, var(--warning) 30%, transparent);
  color: var(--warning);
}
.ai-state-model {
  font-family: var(--bi-font, monospace);
  font-size: var(--text-xs);
  color: var(--muted);
  overflow-wrap: anywhere;
}
.ai-state-list { margin: 0; }
.ai-state-list .list-kv + .list-kv { border-top: var(--hairline) solid var(--border); }
.ai-state-n {
  font-size: var(--text-xs);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.ai-quota {
  display: block;
  height: .3rem;
  border-radius: var(--radius-pill);
  background: var(--surface-sunken);
  overflow: hidden;
  margin-top: var(--space-2);
}
.ai-quota::before {
  content: '';
  display: block;
  width: var(--bar, 0%);
  height: 100%;
  border-radius: inherit;
  background: var(--accent-fill);
}
.ai-quota-note { font-size: var(--text-2xs); color: var(--faint); margin: var(--space-1-5) 0 0; }
.ai-subjects { display: flex; flex-wrap: wrap; gap: var(--space-2); }
.ai-lib-head {
  display: flex;
  align-items: center;
  gap: var(--space-1-5);
  font-size: var(--text-2xs);
  font-weight: 700;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: var(--faint);
  margin: var(--space-3) 0 var(--space-2);
}
.ai-lib-head:first-of-type { margin-top: 0; }
.ai-lib-list { display: grid; gap: var(--space-1); }
.ai-lib-item {
  text-align: left;
  padding: var(--space-1-5) var(--space-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: inherit;
  font-size: var(--text-xs);
  line-height: 1.4;
  cursor: pointer;
  transition: border-color var(--dur-1) var(--ease-out),
              background-color var(--dur-1) var(--ease-out);
}
.ai-lib-item:hover,
.ai-lib-item:focus-visible {
  border-color: var(--primary-line);
  background: var(--primary-soft);
  color: var(--primary-text);
}
.ai-msg-body p { margin: 0 0 var(--space-2); }
.ai-msg-body p:last-child,
.ai-msg-body ul:last-child,
.ai-msg-body ol:last-child,
.ai-md-scroll:last-child { margin-bottom: 0; }
.ai-msg-body ul,
.ai-msg-body ol { margin: 0 0 var(--space-2); padding-left: var(--space-5); }
.ai-msg-body li + li { margin-top: var(--space-1); }
.ai-msg-body li::marker { color: var(--faint); }
.ai-msg-body strong { font-weight: 700; color: var(--text); }
.ai-msg-body code {
  font-size: .9em;
  padding: 0 .3em;
  border-radius: var(--radius-sm);
  background: var(--surface-sunken);
}
.ai-md-h { font-weight: 700; margin: var(--space-2) 0 var(--space-1); }
.ai-md-h:first-child { margin-top: 0; }
.ai-md-scroll { overflow-x: auto; margin: 0 0 var(--space-2); }
.ai-md-table {
  border-collapse: collapse;
  font-size: var(--text-sm);
  font-variant-numeric: tabular-nums;
}
.ai-md-table th,
.ai-md-table td {
  padding: var(--space-1) var(--space-2);
  border-bottom: var(--hairline) solid var(--border);
  text-align: left;
  white-space: nowrap;
}
.ai-md-table th { font-size: var(--text-xs); color: var(--faint); font-weight: 700; }
.ai-md-table tbody tr:last-child td { border-bottom: 0; }
.ai-work { margin-top: var(--space-2); font-size: var(--text-xs); color: var(--muted); }
.ai-work > summary {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1-5);
  cursor: pointer;
  list-style: none;
  color: var(--faint);
  font-weight: 600;
}
.ai-work > summary::-webkit-details-marker { display: none; }
.ai-work > summary .bi-chevron-down { transition: transform var(--dur-1) var(--ease-out); }
.ai-work[open] > summary .bi-chevron-down { transform: rotate(180deg); }
.ai-steps {
  list-style: none;
  margin: var(--space-2) 0 0;
  padding: 0;
  display: grid;
  gap: var(--space-1);
}
.ai-steps li { display: flex; gap: var(--space-1-5); align-items: flex-start; line-height: 1.45; }
.ai-steps li > i { flex: 0 0 auto; color: var(--success); }
.ai-steps li.is-live > i { color: var(--primary-text); animation: ai-step-pulse var(--beat-fast) infinite var(--ease-in-out); }
@keyframes ai-step-pulse {
  0%, 100% { opacity: .35; }
  50% { opacity: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .ai-steps li.is-live > i { animation: none; }
}
.ai-live { font-size: var(--text-xs); color: var(--muted); }
.ai-live .ai-steps { margin: 0 0 var(--space-2); }
.ai-srcs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-1);
  margin-top: var(--space-2);
}
.ai-srcs-label {
  font-size: var(--text-2xs);
  font-weight: 700;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: var(--faint);
  margin-right: var(--space-1);
}
.ai-suggest {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  align-self: flex-start;
  max-width: 46rem;
}
.ai-suggest-item {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1-5);
  padding: var(--space-1) var(--space-3);
  border: 1px solid var(--primary-line);
  border-radius: var(--radius-pill);
  background: var(--surface);
  color: var(--primary-text);
  font-size: var(--text-xs);
  line-height: 1.4;
  text-align: left;
  cursor: pointer;
  transition: background-color var(--dur-1) var(--ease-out);
}
.ai-suggest-item:hover,
.ai-suggest-item:focus-visible { background: var(--primary-soft); }
.ai-act.is-on { color: var(--primary-text); background: var(--primary-soft); }
.ai-conv-new { width: 100%; margin-bottom: var(--space-2); }
.ai-conv-find { margin-bottom: var(--space-2); }
.ai-convs {
  display: grid;
  gap: var(--hairline);
  max-height: 22rem;
  overflow-y: auto;
}
.ai-conv {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-1-5) var(--space-2);
  border-radius: var(--radius-sm);
  color: inherit;
  text-decoration: none;
  font-size: var(--text-sm);
}
.ai-conv:hover { background: var(--surface-hover); }
.ai-conv.is-active { background: var(--primary-soft); color: var(--primary-text); font-weight: 600; }
.ai-conv > i { flex: 0 0 auto; color: var(--faint); }
.ai-conv.is-active > i { color: inherit; }
.ai-conv-title { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ai-conv-when { font-size: var(--text-2xs); color: var(--faint); white-space: nowrap; }
.ai-convs-empty { font-size: var(--text-xs); color: var(--faint); margin: 0; }
.ai-thread-head { display: flex; align-items: center; gap: var(--space-2); min-width: 0; flex-wrap: wrap; }
.ai-thread-title {
  font-weight: 700;
  font-size: var(--text-sm);
  min-width: 0;
  max-width: 22rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ai-rename > summary { list-style: none; cursor: pointer; }
.ai-rename > summary::-webkit-details-marker { display: none; }
.ai-rename-form { display: flex; gap: var(--space-1); margin-top: var(--space-1); }
.ai-rename-form input { width: 14rem; max-width: 100%; }
.ai-thread-wrap { position: relative; }
.ai-jump {
  position: absolute;
  right: var(--space-3);
  bottom: var(--space-3);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  background: var(--surface);
  color: var(--primary-text);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
}
.ai-chart-box { position: relative; height: 13rem; margin-top: var(--space-3); }
.ai-table.has-chart .ai-bars { display: none; }
.data-table {
--data-head-h: 2.6rem;
  --data-pad-x: 1.1rem;
}
.data-table > thead > tr > th,
.data-table > thead > tr > td {
  height: var(--data-head-h);
  padding-top: 0;
  padding-bottom: 0;
  vertical-align: middle;
  background: var(--surface);
}
.data-table > tbody > tr > td,
.data-table > tbody > tr > th {
  border-bottom-color: var(--border);
}
.data-table > tbody > tr:last-child > td,
.data-table > tbody > tr:last-child > th {
  border-bottom-width: 0;
}
.data-table > tbody > tr {
  scroll-margin-top: calc(var(--data-head-h) + var(--topbar-h) + var(--space-2));
}
.data-table > tbody > tr.row-new    { --row-flag: var(--primary); }
.data-table > tbody > tr.row-soon   { --row-flag: var(--warning); }
.data-table > tbody > tr.row-late   { --row-flag: var(--danger); }
.data-table > tbody > tr.row-done   { --row-flag: var(--success); }
.data-table > tbody > tr.row-new > *:first-child,
.data-table > tbody > tr.row-soon > *:first-child,
.data-table > tbody > tr.row-late > *:first-child,
.data-table > tbody > tr.row-done > *:first-child {
  border-left: 3px solid var(--row-flag, var(--border-strong));
padding-left: calc(var(--data-pad-x) - 3px);
}
.data-table > tbody > tr.row-quiet > td,
.data-table > tbody > tr.row-quiet > th { color: var(--muted); }
.num,
th.num,
td.num,
.money,
th.money,
td.money {
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-feature-settings: 'tnum' 1;
}
.money { white-space: nowrap; font-weight: 600; }
.date-cell { font-variant-numeric: tabular-nums; white-space: nowrap; }
.money-pos { color: var(--success); }
.money-neg { color: var(--danger); }
.money-nil { color: var(--muted); font-weight: 500; }
tr.row-sum > td,
tr.row-sum > th {
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  background: var(--surface-muted);
  border-top: 2px solid var(--border-strong);
  border-bottom: 0;
  color: var(--text);
}
.table-sticky tfoot tr.row-sum > td,
.table-sticky tfoot tr.row-sum > th {
  position: sticky;
  bottom: 0;
  z-index: 3;
}
@media screen and (max-width: 767.98px) {
.table-cards > tbody > tr.row-new,
  .table-cards > tbody > tr.row-soon,
  .table-cards > tbody > tr.row-late,
  .table-cards > tbody > tr.row-done {
    border-left: 3px solid var(--row-flag, var(--border-strong));
  }
  .table-cards > tbody > tr.row-new > *:first-child,
  .table-cards > tbody > tr.row-soon > *:first-child,
  .table-cards > tbody > tr.row-late > *:first-child,
  .table-cards > tbody > tr.row-done > *:first-child {
    border-left: 0;
    padding-left: var(--space-3);
  }
.table-cards > tbody > tr > td.num,
  .table-cards > tbody > tr > td.money { text-align: left; }
}
.kv {
  display: grid;
  grid-template-columns: fit-content(45%) minmax(0, 1fr);
  column-gap: var(--space-3);
  margin: 0;
}
.kv-row {
  display: grid;
  grid-template-columns: fit-content(45%) minmax(0, 1fr);
  column-gap: var(--space-3);
  align-items: baseline;
  padding: var(--space-2) 0;
  border-bottom: 1px solid var(--border);
  min-width: 0;
}
.kv-row:last-child { border-bottom: 0; }
.kv-row:first-child { padding-top: 0; }
.kv-label {
  font-size: var(--text-sm);
  color: var(--muted);
  margin: 0;
  font-weight: 500;
  min-width: 0;
  overflow-wrap: anywhere;
}
.kv-value {
  font-size: var(--text-sm);
  color: var(--text);
  font-weight: 600;
  margin: 0;
  min-width: 0;
  overflow-wrap: anywhere;
}
.kv-value:empty::before { content: "—"; color: var(--muted); font-weight: 400; }
@supports (grid-template-columns: subgrid) {
  .kv-row {
    grid-column: 1 / -1;
    grid-template-columns: subgrid;
  }
}
@media (min-width: 768px) {
  .kv-2col { grid-template-columns: fit-content(22%) minmax(0, 1fr) fit-content(22%) minmax(0, 1fr); }
  .kv-2col > .kv-row { grid-column: span 2; }
}
.kv-stack,
.kv-stack > .kv-row { display: block; }
.kv-stack .kv-label { display: block; font-size: var(--text-xs); }
.kv-flush > .kv-row { border-bottom: 0; padding: var(--space-1) 0; }
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--edge-light-soft), var(--shadow-sm);
  margin-bottom: var(--space-4);
}
.filter-bar-plain {
  background: none;
  border: 0;
  box-shadow: none;
  padding: 0;
  margin-bottom: 0;
}
.filter-field {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  flex: 1 1 var(--filter-w, 11rem);
  min-width: 0;
}
.filter-field-sm { --filter-w: 7.5rem; flex-grow: 0; }
.filter-field-sm:has(input[type="date"]) { --filter-w: 9.25rem; }
.filter-field-lg { --filter-w: 16rem; }
.filter-field-grow { flex-grow: 3; }
.filter-label {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--muted);
  line-height: 1.4;
  margin: 0;
}
.filter-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  margin-left: auto;
}
.status-rail {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1);
  margin-bottom: var(--space-3);
  border-bottom: 1px solid var(--border);
}
.status-rail-item {
  display: flex;
  align-items: baseline;
  gap: var(--space-1-5);
  padding: var(--space-1-5) var(--space-3);
  border-bottom: 2px solid transparent;
  border-radius: var(--radius-sm) var(--radius-sm) 0 0;
  color: var(--muted);
  text-decoration: none;
  transition: background var(--dur-2) var(--ease-out), color var(--dur-2) var(--ease-out), border-color var(--dur-2) var(--ease-out);
}
.status-rail-item:hover,
.status-rail-item:focus-visible { background: var(--surface-hover); color: var(--text); }
.status-rail-num {
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--text);
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.status-rail-label { font-size: var(--text-xs); font-weight: 600; }
.status-rail-item.is-accepted .status-rail-num { color: var(--primary-text); }
.status-rail-item.is-completed .status-rail-num,
.status-rail-item.is-finalized .status-rail-num { color: var(--success); }
.status-rail-item.is-cancelled .status-rail-num { color: var(--muted); }
.status-rail-item.is-zero .status-rail-num { color: var(--muted); font-weight: 600; }
.status-rail-item.is-active {
  color: var(--text);
  background: var(--surface-hover);
  border-bottom-color: var(--primary);
}
.status-rail-item.is-active.is-completed,
.status-rail-item.is-active.is-finalized { border-bottom-color: var(--success); }
.status-rail-item.is-active.is-cancelled { border-bottom-color: var(--muted); }
.filter-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--edge-light-soft), var(--shadow-sm);
  padding: var(--space-3) var(--space-4);
  margin-bottom: var(--space-4);
}
.filter-panel > .filter-quick,
.filter-panel > .filter-applied {
  margin: 0;
  padding-top: var(--space-3);
  margin-top: var(--space-3);
  border-top: 1px solid var(--border);
}
.filter-panel > .filter-quick + .filter-applied {
  border-top: 0;
  padding-top: 0;
  margin-top: var(--space-2);
}
.filter-quick {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-3);
}
.filter-quick-label {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--ground-ink-muted);
}
:is(.card, .filter-panel) .filter-quick-label { color: var(--muted); }
.filter-applied {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-3);
}
.filter-applied-label {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--muted);
}
.filter-applied-edit {
  margin-left: auto;
  font-size: var(--text-xs);
  font-weight: 600;
  text-decoration: none;
  color: var(--primary-text);
}
.filter-applied-edit:hover { text-decoration: underline; }
.chip-x {
  display: inline-flex;
  align-items: center;
  border: 0;
  padding: 0;
  margin-left: var(--space-0);
  background: none;
  color: inherit;
  line-height: 1;
  opacity: .7;
  transition: opacity var(--dur-1) var(--ease-out);
}
.chip-x:hover,
.chip-x:focus-visible { opacity: 1; }
@media (max-width: 575.98px) {
.filter-bar { padding: var(--space-3); gap: var(--space-2); }
  .filter-field,
  .filter-field-sm,
  .filter-field-lg { flex-basis: 100%; flex-grow: 1; }
  .filter-actions { margin-left: 0; width: 100%; }
  .filter-actions > .btn { flex: 1 1 auto; }
}
.empty-search .empty-icon {
  background: var(--surface-muted);
  color: var(--muted);
  box-shadow: inset 0 0 0 var(--hairline) var(--border);
}
.empty-state-sm { padding: var(--space-5) var(--space-3); }
.empty-state-sm .empty-icon {
  width: 42px;
  height: 42px;
  border-radius: var(--radius);
  font-size: var(--text-lg);
  margin-bottom: var(--space-2);
}
.empty-state-sm .empty-title { font-size: var(--text-sm); }
.empty-state-sm .empty-text { font-size: var(--text-xs); }
.empty-hint {
  font-size: var(--text-xs);
  color: var(--muted);
  margin: var(--space-3) 0 0;
}
.table > tbody > tr > td > .empty-state { padding-block: var(--space-5); }
.skeleton-line {
  display: block;
  height: .72rem;
  width: 100%;
  border-radius: var(--radius-pill);
}
.skeleton-line-title { height: 1rem; }
.skeleton-circle {
  flex: none;
  width: 2.4rem;
  height: 2.4rem;
  border-radius: var(--radius-round);
}
.skeleton-block { min-height: 4.5rem; border-radius: var(--radius); }
.skeleton-text { display: grid; gap: var(--space-1-5); min-width: 0; }
.skeleton-text > .skeleton-line:nth-child(2) { width: 86%; }
.skeleton-text > .skeleton-line:nth-child(3) { width: 62%; }
.skeleton-list { display: grid; gap: 0; }
.skeleton-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) 5rem;
  gap: var(--space-3);
  align-items: center;
  padding: var(--space-3) 0;
  border-bottom: 1px solid var(--border);
}
.skeleton-row:last-child { border-bottom: 0; }
.skeleton-row:nth-child(2) .skeleton::after { animation-delay: .12s; }
.skeleton-row:nth-child(3) .skeleton::after { animation-delay: .24s; }
.skeleton-row:nth-child(n+4) .skeleton::after { animation-delay: .36s; }
.skeleton-card {
  display: grid;
  gap: var(--space-3);
  padding: var(--space-4);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
}
@media (prefers-reduced-motion: reduce) {
.skeleton::after { display: none; }
}
.page-crumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-0) var(--space-1-5);
  font-size: var(--text-xs);
  margin-bottom: var(--space-1);
  min-width: 0;
}
.page-crumbs a { color: var(--muted); text-decoration: none; }
.page-crumbs a:hover { color: var(--primary-text); text-decoration: underline; }
.page-crumb-sep { color: var(--muted); }
.page-crumbs [aria-current="page"] { color: var(--text); font-weight: 600; }
.page-figs {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: var(--space-2) var(--space-4);
  margin-top: var(--space-2);
  min-width: 0;
}
.page-fig { display: flex; align-items: baseline; gap: var(--space-1-5); min-width: 0; }
.page-fig-value {
  font-weight: 700;
  font-size: var(--text-lg);
  line-height: 1.1;
  letter-spacing: -.01em;
  font-variant-numeric: tabular-nums;
}
.page-fig-label { font-size: var(--text-xs); color: var(--ground-ink-muted); }
.page-fig-danger .page-fig-value { color: var(--ground-danger); }
.page-fig-warning .page-fig-value { color: var(--ground-warning); }
.page-fig-success .page-fig-value { color: var(--ground-success); }
.page-actions-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
}
.page-actions-sep {
  flex: 0 0 1px;
  align-self: stretch;
  min-height: 1.4rem;
  background: var(--border-strong);
  margin-inline: var(--space-0);
}
@media (max-width: 575.98px) {
.page-actions-sep { display: none; }
}
.page-head.has-head-toggle { justify-content: flex-start; }
.page-head.has-head-toggle > .page-head-main { margin-inline-end: auto; }
.page-head-toggle { flex: 0 0 auto; align-self: center; }
.page-head-toggle i { display: block; transition: transform var(--dur-2) var(--ease-spring); }
body.head-mini .page-head-toggle i { transform: rotate(180deg); }
body.head-mini .page-crumbs,
body.head-mini .page-sub,
body.head-mini .page-figs { display: none; }
body.head-mini .page-eyebrow { display: none; }
body.head-mini .page-head:not(.bi-hero) { margin-bottom: var(--space-3); }
body.head-mini .page-head:not(.bi-hero) .page-title { font-size: var(--text-lg); }
body.head-mini .page-head:not(.bi-hero) .page-title .page-title-icon {
  width: 30px;
  height: 30px;
  font-size: var(--text-sm);
}
body.head-mini .load-rail,
body.head-mini .filter-bar,
body.head-mini .filter-quick,
body.head-mini .page-head-fold { display: none; }
body.head-mini .app-content > .page-head ~ .stat-grid,
body.head-mini .app-content > .page-head ~ .alert.notice,
body.head-mini .app-content > .section-title:has(+ .filter-bar),
body.head-mini .vat-now,
body.head-mini .bi-tick,
body.head-mini .export-bar { display: none; }
body.head-mini .worklist-card,
body.head-mini .bi-surface > .alarm-panel,
body.head-mini .bi-surface > .stat-grid { display: none; }
body.head-mini .filter-panel {
  background: none;
  border: 0;
  box-shadow: none;
  padding: 0;
  margin-bottom: 0;
}
body.head-mini .filter-panel > .filter-applied {
  border-top: 0;
  padding-top: 0;
  margin: 0 0 var(--space-3);
}
.page-head-sticky {
  position: sticky;
  top: calc(var(--topbar-h) - 1px);
  z-index: 5;
  background: var(--bg);
  margin: calc(var(--space-5) * -1) calc(var(--space-5) * -1) var(--space-4);
  padding: var(--space-5) var(--space-5) var(--space-3);
  border-bottom: 1px solid var(--border);
}
@media (max-width: 991.98px) {
  .page-head-sticky { position: static; }
}
@media (max-width: 576px) {
.page-head-sticky {
    margin-inline: calc(var(--space-3) * -1);
    padding-inline: var(--space-3);
    padding-top: var(--space-4);
  }
}
.detail-card { min-width: 0; }
.detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-4);
  padding-bottom: var(--space-3);
  margin-bottom: var(--space-4);
  border-bottom: 1px solid var(--border);
}
.detail-head-main { min-width: 0; flex: 1 1 14rem; }
.detail-title {
  font-size: var(--text-lg);
  font-weight: 700;
  letter-spacing: -.01em;
  margin: 0 0 var(--space-0);
  overflow-wrap: anywhere;
}
.detail-sub { font-size: var(--text-sm); color: var(--muted); margin: 0; }
.detail-side {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: var(--space-1);
  text-align: right;
  flex: 0 0 auto;
}
.detail-figure {
  font-size: var(--text-xl);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -.02em;
  font-variant-numeric: tabular-nums;
}
.detail-body { display: grid; gap: var(--space-4); min-width: 0; }
.detail-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  padding-top: var(--space-3);
  margin-top: var(--space-4);
  border-top: 1px solid var(--border);
}
.detail-foot-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  margin-left: auto;
}
.complete-hours { flex: 0 0 auto; width: 9rem; }
@media (max-width: 576px) {
  .complete-hours { flex: 1 1 100%; width: auto; }
}
.card-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-3);
}
.card-bar-end { justify-content: flex-end; }
.app-content > .section-title,
.app-content > p,
.app-content > .small { color: var(--ground-ink-muted); }
.page-head :is(.btn-outline-primary, .btn-outline-secondary, .btn-outline-success,
               .btn-outline-dark, .btn-outline-light, .btn-link),
.load-rail :is(.btn-outline-primary, .btn-outline-secondary, .btn-link),
.filter-quick :is(.btn-outline-primary, .btn-outline-secondary, .btn-link),
.form-actions :is(.btn-outline-primary, .btn-outline-secondary, .btn-link),
.tm-ov-actions :is(.btn-outline-primary, .btn-outline-secondary, .btn-link),
.app-content > :is(.btn-outline-primary, .btn-outline-secondary, .btn-outline-success,
                   .btn-outline-dark, .btn-outline-light, .btn-link) {
  --bs-btn-color: var(--ground-ink);
  --bs-btn-border-color: var(--ground-line);
  --bs-btn-hover-color: var(--primary-text);
  --bs-btn-hover-bg: var(--ground-ink);
  --bs-btn-hover-border-color: var(--ground-ink);
  --bs-btn-active-color: var(--primary-text);
  --bs-btn-active-bg: var(--ground-ink);
  --bs-btn-active-border-color: var(--ground-ink);
  --bs-btn-disabled-color: var(--ground-ink-muted);
  --bs-btn-disabled-border-color: var(--ground-line);
}
.page-head.bi-hero { color: var(--bi-ink); }
.page-head.bi-hero :is(.btn-outline-primary, .btn-outline-secondary, .btn-outline-success,
                       .btn-outline-dark, .btn-outline-light, .btn-link) {
  --bs-btn-color: var(--bi-ink);
  --bs-btn-border-color: var(--bi-line);
  --bs-btn-hover-color: var(--bi-ink);
  --bs-btn-hover-bg: var(--bi-chrome-hover);
  --bs-btn-hover-border-color: var(--bi-line);
  --bs-btn-active-color: var(--bi-ink);
  --bs-btn-active-bg: var(--bi-chrome-hover);
  --bs-btn-active-border-color: var(--bi-line);
  --bs-btn-disabled-color: var(--bi-ink-2);
  --bs-btn-disabled-border-color: var(--bi-line);
}
.page-head.bi-hero a:not(.btn) { color: var(--bi-accent-dark); }
.page-head .btn-outline-danger,
.app-content > .btn-outline-danger {
  --bs-btn-color: var(--ground-danger);
  --bs-btn-border-color: var(--ground-danger);
  --bs-btn-hover-color: var(--danger);
  --bs-btn-hover-bg: var(--ground-danger);
  --bs-btn-hover-border-color: var(--ground-danger);
  --bs-btn-active-color: var(--danger);
  --bs-btn-active-bg: var(--ground-danger);
  --bs-btn-active-border-color: var(--ground-danger);
}
.app-content > .alert,
.app-content > .chip,
.app-content > :is(.filter-quick, .load-rail, .filter-bar) .chip {
  background: var(--ground-shade);
  border-color: var(--ground-line);
  color: var(--ground-ink);
}
.app-content > .alert-danger  { border-color: color-mix(in srgb, var(--ground-danger) 42%, transparent); }
.app-content > .alert-warning { border-color: color-mix(in srgb, var(--ground-warning) 42%, transparent); }
.app-content > .alert-success { border-color: color-mix(in srgb, var(--ground-success) 42%, transparent); }
.app-content > .alert-info    { border-color: color-mix(in srgb, var(--ground-info) 42%, transparent); }
.app-content > .alert-danger  :is(strong, b, .alert-heading, .notice-title),
.app-content > .chip-danger  { color: var(--ground-danger); }
.app-content > .alert-warning :is(strong, b, .alert-heading, .notice-title),
.app-content > .chip-warning { color: var(--ground-warning); }
.app-content > .alert-success :is(strong, b, .alert-heading, .notice-title),
.app-content > .chip-success { color: var(--ground-success); }
.app-content > .alert-info    :is(strong, b, .alert-heading, .notice-title),
.app-content > .chip-info    { color: var(--ground-info); }
.app-content > .alert :is(a:not(.btn), .alert-link) { color: var(--ground-ink); }
.app-content > :is(.filter-quick, .load-rail, .filter-bar) .chip-success { color: var(--ground-success); }
.app-content > :is(.filter-quick, .load-rail, .filter-bar) .chip-warning { color: var(--ground-warning); }
.app-content > :is(.filter-quick, .load-rail, .filter-bar) .chip-danger  { color: var(--ground-danger); }
.app-content > :is(.filter-quick, .load-rail, .filter-bar) .chip-info    { color: var(--ground-info); }
.app-content > .chip-primary,
.app-content > :is(.filter-quick, .load-rail, .filter-bar) .chip-primary {
  background: var(--ground-ink);
  border-color: var(--ground-ink);
  color: var(--primary-text);
  font-weight: 700;
}
.load-rail-label,
.app-content > .small,
.app-content > .text-body-secondary { color: var(--ground-ink-muted); }
:is(.card, .filter-panel) :is(.filter-quick, .load-rail, .form-actions)
  :is(.btn-outline-primary, .btn-outline-secondary, .btn-outline-success,
      .btn-outline-dark, .btn-outline-light, .btn-link) {
  --bs-btn-color: var(--text);
  --bs-btn-border-color: var(--border-strong);
  --bs-btn-hover-color: var(--text);
  --bs-btn-hover-bg: var(--surface-hover);
  --bs-btn-hover-border-color: var(--border-strong);
  --bs-btn-active-color: var(--text);
  --bs-btn-active-bg: var(--surface-hover);
  --bs-btn-active-border-color: var(--border-strong);
  --bs-btn-disabled-color: var(--faint);
  --bs-btn-disabled-border-color: var(--border);
}
:is(.card, .filter-panel) :is(.filter-quick, .load-rail, .form-actions) .btn-outline-primary {
  --bs-btn-color: var(--primary-text);
  --bs-btn-border-color: var(--primary-line);
  --bs-btn-hover-color: var(--primary-contrast);
  --bs-btn-hover-bg: var(--primary);
  --bs-btn-hover-border-color: var(--primary);
  --bs-btn-active-color: var(--primary-contrast);
  --bs-btn-active-bg: var(--primary);
  --bs-btn-active-border-color: var(--primary);
}
.auth-foot {
  text-align: center;
  margin-top: var(--space-3);
  font-size: var(--text-sm);
  color: var(--ground-ink-muted);
}
.auth-foot a { color: var(--ground-ink); }
.app-content > .bi-report > :is(p, .small) { color: var(--ground-ink-muted) !important; }
.app-content > a:not(.btn),
.app-content > p a:not(.btn),
.app-content > .small a:not(.btn),
.app-content > .text-muted a:not(.btn),
.app-content > .section-title a:not(.btn),
.page-head a:not(.btn) { color: var(--ground-ink); }
.page-head .dropdown-menu a:not(.btn) { color: var(--text); }
.section-title {
  display: flex;
  align-items: center;
  gap: var(--space-1-5);
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .07em;
  color: var(--muted);
  margin: 0 0 var(--space-2);
}
.section-title-rule::after {
  content: "";
  flex: 1 1 auto;
  height: 1px;
  background: var(--border);
}
.page-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--space-4);
  align-items: start;
}
.page-main,
.page-aside {
  display: grid;
  gap: var(--space-4);
  align-content: start;
  min-width: 0;
}
@media (min-width: 992px) {
  .page-grid {
    grid-template-columns: minmax(0, 1fr) var(--aside-w, 20rem);
    gap: var(--space-5);
  }
  .page-grid-wide { --aside-w: 24rem; }
  .page-grid-narrow { --aside-w: 16rem; }
.page-grid-left { grid-template-columns: var(--aside-w, 20rem) minmax(0, 1fr); }
  .page-grid-left > .page-aside { order: -1; }
.page-aside-sticky {
    position: sticky;
    top: calc(var(--topbar-h) + var(--space-4));
  }
}
.page-stack { display: grid; gap: var(--space-5); align-content: start; }
.page-stack-sm { gap: var(--space-3); }
.page-stack-lg { gap: var(--space-6); }
.card-rail {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(var(--rail-min, 17rem), 1fr));
  gap: var(--space-4);
}
.card-rail-wide { --rail-min: 22rem; }
.card-slot { min-width: 0; }
@supports (grid-template-rows: subgrid) {
  .card-slot {
    display: grid;
    grid-row: span 3;
    grid-template-rows: subgrid;
    row-gap: 0;
  }
}
@keyframes revealUp {
  from { opacity: 0; transform: translateY(12px) scale(.985); }
  to   { opacity: 1; transform: none; }
}
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .js-reveal .reveal {
      opacity: 1;
      transform: none;
      transition: none;
      animation-name: revealUp;
      animation-timing-function: var(--ease-out);
      animation-fill-mode: both;
      animation-timeline: view();
      animation-range: entry 0% entry 240px;
    }
  }
}
@media print {
  .js-reveal .reveal {
    opacity: 1;
    transform: none;
    transition: none;
    animation-name: none;
  }
}
.form-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-2);
}
.form-actions > .form-actions-end { margin-left: auto; }
.form-actions-rule {
  margin-top: var(--space-4);
  padding-top: var(--space-3);
  border-top: 1px solid var(--border);
}
@media (max-width: 575.98px) {
  .form-actions-stack { flex-direction: column; align-items: stretch; }
  .form-actions-stack > .form-actions-end { margin-left: 0; }
}
.inset {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-muted);
  padding: var(--space-3);
  min-width: 0;
}
.inset-plain { background: transparent; }
.inset-lg { padding: var(--space-4); border-radius: var(--radius); }
.inset-figure {
  font-size: var(--text-xl);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -.02em;
  font-variant-numeric: tabular-nums;
}
.notice {
  display: flex;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-3);
}
.notice-icon {
  flex: 0 0 auto;
  font-size: var(--text-lg);
line-height: 1.5;
}
.notice-body { flex: 1 1 14rem; min-width: 0; }
.notice-body > :last-child { margin-bottom: 0; }
.notice-title { font-weight: 700; margin: 0 0 var(--space-0); }
.notice-actions { margin-left: auto; flex: 0 0 auto; }
.list-kv {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding-top: var(--space-2);
  padding-bottom: var(--space-2);
  min-width: 0;
}
.list-kv-value {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  flex: 0 0 auto;
}
.user-cell {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  min-width: 0;
}
.user-cell-main {
  display: flex;
  flex-direction: column;
  min-width: 0;
  line-height: 1.25;
}
.user-more-toggle {
  --bs-btn-padding-x: var(--space-1-5);
  --bs-btn-padding-y: var(--space-0);
  line-height: 1;
  flex: 0 0 auto;
}
.user-more-toggle i { transition: transform var(--dur-2) var(--ease-out); }
.user-more-toggle.is-open i { transform: rotate(90deg); }
.user-more > td { background: var(--surface-2, rgba(127, 127, 127, .07)); }
.user-more-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: var(--space-3);
  padding: var(--space-2) var(--space-1);
}
.user-more-title {
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--muted);
  margin-bottom: var(--space-2);
}
.user-more-kv {
  display: grid;
  grid-template-columns: minmax(6.5rem, auto) 1fr;
  gap: var(--space-0) var(--space-2);
  margin: 0;
  font-size: var(--text-sm);
}
.user-more-kv dt { font-weight: 500; color: var(--muted); }
.user-more-kv dd { margin: 0; overflow-wrap: anywhere; }
.user-more-links {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-top: var(--space-2);
}
.user-more-people {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: var(--text-sm);
}
.user-more-people li {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-1);
}
.user-more-state,
.user-more-acts {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-1) var(--space-2);
}
.user-more-state { font-size: var(--text-sm); }
.user-more-state > div { flex: 1 0 100%; }
.user-more-actions { grid-column: 1 / -1; }
@media print {
  .filter-bar,
  .filter-quick,
  .filter-applied,
  .page-crumbs,
  .skeleton-text,
  .skeleton-list,
  .skeleton-card { display: none !important; }
.page-grid,
  .card-rail { display: block !important; }
  .page-aside-sticky { position: static; }
  .card-slot { display: block; }
.detail-card,
  .card-slot,
  .kv-row,
  .data-table > tbody > tr { break-inside: avoid; }
.page-head-sticky {
    position: static;
    margin: 0 0 var(--space-4);
    padding: 0 0 var(--space-3);
  }
}
.land {
  display: grid;
  gap: var(--space-7);
  padding-bottom: var(--space-7);
}
.land-hero {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(0, 1.04fr) minmax(0, .96fr);
  align-items: center;
  gap: clamp(var(--space-5), 3vw, var(--space-7));
  padding: clamp(var(--space-5), 3.4vw, var(--space-7));
  border-radius: var(--radius-xl);
  color: rgba(255,255,255,.96);
background:
    radial-gradient(120% 92% at 86% -10%, rgba(210,171,103,.20), transparent 56%),
    linear-gradient(152deg, rgba(36,69,127,.97) 0%, rgba(44,80,155,.94) 36%,
                    rgba(40,69,96,.92) 72%, rgba(36,54,63,.95) 100%),
    rgba(16,26,33,1);
  box-shadow: var(--shadow-lg);
}
.land-hero-copy { display: grid; gap: var(--space-4); justify-items: start; }
.land-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-pill);
background: var(--ground-shade);
  border: 1px solid var(--ground-line);
  font-size: var(--text-sm);
  font-weight: 500;
}
.land-eyebrow b {
  font-family: 'Sora Variable', 'Inter Variable', Inter, sans-serif;
  font-weight: 700;
}
.land-title {
  margin: 0;
  font-size: var(--display-md);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -.02em;
}
.land-title em {
  font-style: normal;
  box-shadow: inset 0 -.22em 0 color-mix(in srgb, var(--warning-fill) 62%, transparent);
}
.land-lead {
  margin: 0;
  max-width: 34rem;
  font-size: var(--text-lg);
  line-height: 1.62;
  color: rgba(255,255,255,.86);
}
.land-cta { display: flex; flex-wrap: wrap; gap: var(--space-3); }
.land-cta .btn-land-solid {
  background: rgba(255,255,255,.96);
  border: 1px solid rgba(255,255,255,.96);
  color: rgba(36,69,127,1);
  font-weight: 600;
}
.land-cta .btn-land-solid:hover,
.land-cta .btn-land-solid:focus-visible {
  background: rgba(255,255,255,1);
  border-color: rgba(255,255,255,1);
  color: rgba(36,69,127,1);
}
.land-cta .btn-land-ghost {
  color: rgba(255,255,255,.94);
  border: 1px solid rgba(255,255,255,.34);
  background: rgba(255,255,255,.08);
}
.land-cta .btn-land-ghost:hover,
.land-cta .btn-land-ghost:focus-visible {
  color: rgba(255,255,255,1);
  background: rgba(255,255,255,.16);
  border-color: rgba(255,255,255,.5);
}
.land-returning {
  margin: 0;
  font-size: var(--text-sm);
  color: rgba(255,255,255,.8);
}
.land-returning a {
  color: rgba(255,255,255,.96);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: rgba(255,255,255,.42);
  text-underline-offset: .22em;
}
.land-returning a:hover,
.land-returning a:focus-visible {
  color: rgba(255,255,255,1);
  text-decoration-color: currentColor;
}
.land-returning a:focus-visible {
  outline: 2px solid rgba(255,255,255,.96);
  outline-offset: 3px;
  border-radius: var(--radius-xs);
}
.land-returning a i { margin-inline-start: var(--space-1); }
.land-shot {
  aspect-ratio: 3 / 2;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(11,13,38,1) center / cover no-repeat;
  box-shadow: var(--shadow-lg);
}
.land-shot-1 { background-image: var(--land-shot-1); }
.land-shot-2 { background-image: var(--land-shot-2); }
.land-shot-3 { background-image: var(--land-shot-3); }
.land-app {
  position: relative;
  padding: var(--space-6) var(--space-5) var(--space-7) var(--space-4);
  animation: pageIn var(--dur-4) var(--ease-out) both;
  animation-delay: .12s;
}
.land-app-window {
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow-lg);
}
.land-app-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-2) var(--space-3);
  border-bottom: 1px solid var(--border);
  background: var(--surface-muted);
}
.land-app-dots { display: inline-flex; gap: var(--space-1-5); }
.land-app-dots span {
  width: .625rem;
  height: .625rem;
  border-radius: var(--radius-round);
  background: var(--danger-fill);
}
.land-app-dots span:nth-child(2) { background: var(--warning-fill); }
.land-app-dots span:nth-child(3) { background: var(--success-fill); }
.land-app-address {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1-5);
  padding: var(--space-0) var(--space-4);
  border-radius: var(--radius-pill);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  font-size: var(--text-xs);
  font-weight: 600;
}
.land-app-address i { color: var(--success); }
.land-app-body {
  display: grid;
  grid-template-columns: 3.75rem minmax(0, 1fr);
}
.land-app-side {
  display: grid;
  align-content: start;
  justify-items: center;
  gap: var(--space-3);
  padding: var(--space-4) var(--space-2);
  background: var(--shell);
}
.land-app-nav {
  width: 1.75rem;
  height: .45rem;
  border-radius: var(--radius-pill);
  background: var(--shell-well-strong);
}
.land-app-nav:first-child {
  width: 2rem;
  height: 2rem;
  margin-bottom: var(--space-2);
  border-radius: var(--radius-sm);
  background: var(--grad-primary);
  box-shadow: var(--shadow-sm);
}
.land-app-nav.is-on { background: var(--primary); }
.land-app-main {
  display: grid;
  align-content: start;
  gap: var(--space-3);
  min-width: 0;
  padding: var(--space-4);
}
.land-app-head { display: flex; align-items: center; gap: var(--space-3); }
.land-app-avatar {
  flex: none;
  width: 2.25rem;
  height: 2.25rem;
  display: grid;
  place-items: center;
  border-radius: var(--radius);
  background: var(--grad-primary);
  color: var(--primary-contrast);
}
.land-app-title { display: grid; min-width: 0; line-height: 1.3; }
.land-app-title b { font-size: var(--text-sm); }
.land-app-title small { color: var(--muted); font-size: var(--text-xs); }
.land-app-rows {
  display: grid;
  gap: var(--space-1-5);
  margin: 0;
  padding: 0;
  list-style: none;
}
.land-app-rows li {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: var(--text-sm);
}
.land-app-rows li > span:not(.chip) {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.land-app-rows i { color: var(--primary-text); }
.land-app-chart {
  display: flex;
  align-items: flex-end;
  gap: var(--space-1-5);
  height: 4.25rem;
  padding: var(--space-2) var(--space-3) 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}
.land-app-chart span {
  flex: 1;
  height: 45%;
  border-radius: var(--radius-xs) var(--radius-xs) 0 0;
  background: var(--primary-line);
  transform-origin: bottom;
  animation: barGrow var(--dur-4) var(--ease-out) both;
}
.land-app-chart span:nth-child(2) { height: 62%; }
.land-app-chart span:nth-child(3) { height: 38%; }
.land-app-chart span:nth-child(4) { height: 70%; }
.land-app-chart span:nth-child(5) { height: 54%; }
.land-app-chart span:nth-child(6) { height: 78%; }
.land-app-chart span:nth-child(7) { height: 66%; }
.land-app-chart span:nth-child(8) { height: 92%; background: var(--grad-primary); }
.land-app-toast {
  position: absolute;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: var(--space-3);
  max-width: 16rem;
  padding: var(--space-2) var(--space-4) var(--space-2) var(--space-2);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow-lg);
  font-size: var(--text-sm);
}
.land-app-toast > i {
  flex: none;
  width: 2.25rem;
  height: 2.25rem;
  display: grid;
  place-items: center;
  border-radius: var(--radius-sm);
  background: var(--success-soft);
  color: var(--success);
  font-size: var(--text-lg);
}
.land-app-toast-file > i { background: var(--primary-soft); color: var(--primary-text); }
.land-mock-toast > i { background: var(--warning-soft); color: var(--warning); }
.land-app-toast > span { display: grid; min-width: 0; line-height: 1.3; }
.land-app-toast b { font-weight: 600; }
.land-app-toast small { color: var(--muted); font-size: var(--text-xs); }
.land-app-toast-done { top: 0; right: 0; }
.land-app-toast-file { bottom: 0; left: 0; }
.land-proof {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--space-5);
  margin: 0;
  padding: var(--space-5) 0;
  list-style: none;
  border-block: 1px solid var(--ground-line);
  color: var(--ground-ink-muted);
  font-size: var(--text-sm);
}
.land-proof li { display: flex; align-items: flex-start; gap: var(--space-3); }
.land-proof i {
  flex: none;
  width: 2.75rem;
  height: 2.75rem;
  display: grid;
  place-items: center;
  border-radius: var(--radius);
  border: 1px solid var(--ground-line);
  background: var(--ground-shade);
  color: var(--ground-accent);
  font-size: var(--text-lg);
}
.land-proof span { display: grid; gap: var(--space-0); line-height: 1.5; }
.land-proof b {
  color: var(--ground-ink);
  font-size: var(--text-base);
  font-weight: 600;
}
.land-head { display: grid; gap: var(--space-2); margin-bottom: var(--space-5); max-width: 46rem; }
.land-kicker {
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ground-accent);
}
.land-kicker a {
  color: var(--ground-accent);
  text-decoration-color: var(--ground-line);
  text-underline-offset: .25em;
}
.land-kicker a:hover { color: var(--ground-ink); text-decoration-color: currentColor; }
.land-kicker a:focus-visible {
  outline: 2px solid var(--ground-ink);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}
.land-h2 {
  margin: 0;
  font-size: var(--display-sm);
  font-weight: 700;
  letter-spacing: -.01em;
  color: var(--ground-ink);
}
.land-sub { margin: 0; color: var(--ground-ink-muted); font-size: var(--text-lg); line-height: 1.6; }
.land-close .land-h2 { color: var(--text); }
.land-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
  gap: var(--space-4);
}
@media (min-width: 1100px) {
  .land-grid { grid-template-columns: repeat(3, 1fr); }
}
.land-card {
  display: grid;
  gap: var(--space-2);
  padding: var(--space-5);
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: transform var(--dur-2) var(--ease-out),
              box-shadow var(--dur-2) var(--ease-out),
              border-color var(--dur-2) var(--ease-out);
}
.land-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary-line);
}
.land-card > i {
  width: 2.6rem;
  height: 2.6rem;
  display: grid;
  place-items: center;
  border-radius: var(--radius);
  background: var(--primary-soft);
  color: var(--primary-text);
  font-size: var(--text-lg);
  margin-bottom: var(--space-2);
}
.land-card b { font-size: var(--text-base); }
.land-card span { color: var(--muted); font-size: var(--text-sm); line-height: 1.55; }
.land-card:has(> .land-card-more) { grid-template-rows: auto auto 1fr auto; }
.land-card .land-card-more {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1-5);
  margin-top: var(--space-2);
  color: var(--primary-text);
  font-weight: 600;
}
.land-card-more i { transition: transform var(--dur-2) var(--ease-out); }
a.land-card:hover .land-card-more i,
a.land-card:focus-visible .land-card-more i { transform: translateX(var(--space-1)); }
a.land-card { color: var(--text); text-decoration: none; }
a.land-card:hover b { color: var(--primary-text); }
a.land-card:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}
.land-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-5);
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: land-step;
}
.land-step {
  position: relative;
  display: grid;
  align-content: start;
  gap: var(--space-2);
  counter-increment: land-step;
  color: var(--ground-ink);
}
.land-step::before {
  content: counter(land-step);
  width: 3rem;
  height: 3rem;
  display: grid;
  place-items: center;
  margin-bottom: var(--space-2);
  border-radius: var(--radius-round);
  border: 1px solid transparent;
  background: var(--shell);
  color: var(--shell-ink);
  box-shadow: var(--shadow-md);
  font-family: 'Sora Variable', 'Inter Variable', Inter, sans-serif;
  font-size: var(--text-lg);
  font-weight: 700;
}
.land-step:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 1.5rem;
  left: calc(3rem + var(--space-3));
  right: calc(var(--space-3) - var(--space-5));
  height: 1px;
  background: var(--ground-line);
}
.land-step b { color: var(--ground-ink); font-size: var(--text-lg); }
.land-step span {
  max-width: 22rem;
  color: var(--ground-ink-muted);
  font-size: var(--text-base);
  line-height: 1.6;
}
.land-tour { display: grid; gap: var(--space-7); }
.land-tour > .land-head { margin-bottom: 0; }
.land-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: center;
  gap: clamp(var(--space-5), 4vw, var(--space-7));
  margin: 0;
}
.land-row figcaption,
.land-row-copy {
  display: grid;
  justify-items: start;
  gap: var(--space-3);
  color: var(--ground-ink-muted);
}
.land-row .land-shot { border-color: var(--ground-line); }
.land-row-label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  color: var(--ground-accent);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.land-row-title {
  margin: 0;
  color: var(--ground-ink);
  font-size: var(--display-sm);
  font-weight: 700;
  letter-spacing: -.01em;
}
.land-row p {
  margin: 0;
  max-width: 34rem;
  color: var(--ground-ink-muted);
  font-size: var(--text-lg);
  line-height: 1.6;
}
.land-ticks {
  display: grid;
  gap: var(--space-2);
  margin: var(--space-2) 0 0;
  padding: 0;
  list-style: none;
  color: var(--ground-ink);
}
.land-ticks li { display: flex; align-items: baseline; gap: var(--space-2); }
.land-ticks i { color: var(--ground-success); }
.land-mock {
  position: relative;
  justify-self: center;
  width: 100%;
  max-width: 26rem;
  padding: var(--space-5) var(--space-6) var(--space-7) 0;
}
.land-mock-card {
  display: grid;
  gap: var(--space-4);
  padding: var(--space-5);
  border-radius: var(--radius-xl);
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow-lg);
}
.land-mock-head { display: flex; align-items: center; gap: var(--space-2); }
.land-mock-head i { color: var(--primary-text); }
.land-mock-cal {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: var(--space-1-5);
}
.land-mock-cal span {
  aspect-ratio: 5 / 4;
  border-radius: var(--radius-sm);
  background: var(--surface-sunken);
}
.land-mock-list {
  display: grid;
  gap: var(--space-2);
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: var(--text-sm);
}
.land-mock-list li {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: var(--space-2);
}
.land-mock-dot {
  width: .625rem;
  height: .625rem;
  border-radius: var(--radius-round);
}
.land-mock-cal .is-done,
.land-mock-dot.is-done { background: var(--success-fill); }
.land-mock-cal .is-soon,
.land-mock-dot.is-soon { background: var(--warning-fill); }
.land-mock-cal .is-plan,
.land-mock-dot.is-plan { background: var(--primary); }
.land-mock-toast { right: 0; bottom: 0; }
.land-trust {
  display: grid;
  gap: var(--space-6);
  padding: clamp(var(--space-5), 3.4vw, var(--space-7));
  border-radius: var(--radius-xl);
  color: rgba(255,255,255,.92);
  background:
    radial-gradient(110% 140% at 0% 0%, rgba(34,211,238,.14), transparent 58%),
    linear-gradient(140deg, rgba(23,26,72,1) 0%, rgba(16,18,52,1) 60%, rgba(11,13,38,1) 100%);
  box-shadow: var(--shadow-lg);
}
.land-trust-head { display: grid; gap: var(--space-2); max-width: 46rem; }
.land-trust-kicker {
  color: var(--ground-accent);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.land-trust-title {
  margin: 0;
  color: rgba(255,255,255,.96);
  font-size: var(--display-sm);
  font-weight: 700;
  letter-spacing: -.01em;
}
.land-trust-head p {
  margin: 0;
  color: rgba(255,255,255,.76);
  font-size: var(--text-lg);
  line-height: 1.6;
}
.land-trust-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-6) var(--space-5);
}
.land-trust-item {
  display: grid;
  gap: var(--space-1);
  align-content: start;
  padding-top: var(--space-4);
  border-top: 1px solid rgba(255,255,255,.14);
}
.land-trust-item i {
  width: 2.5rem;
  height: 2.5rem;
  display: grid;
  place-items: center;
  margin-bottom: var(--space-2);
  border-radius: var(--radius-round);
  border: 1px solid rgba(255,255,255,.18);
  color: var(--warning-fill);
  font-size: var(--text-lg);
}
.land-trust-item b { font-size: var(--text-base); }
.land-trust-item span { color: rgba(255,255,255,.72); font-size: var(--text-sm); line-height: 1.55; }
.land-close {
  display: grid;
  justify-items: center;
  gap: var(--space-3);
  padding: clamp(var(--space-5), 3vw, var(--space-6-5));
  border-radius: var(--radius-xl);
  text-align: center;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}
.land-close p { margin: 0; color: var(--muted); max-width: 34rem; }
.land-home .land-close {
  grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr);
  justify-items: stretch;
  align-items: center;
  gap: clamp(var(--space-5), 4vw, var(--space-7));
  padding: clamp(var(--space-5), 3.4vw, var(--space-7));
  overflow: hidden;
  text-align: start;
  border: 0;
  color: rgba(255,255,255,.96);
  background:
    radial-gradient(120% 92% at 86% -10%, rgba(210,171,103,.20), transparent 56%),
    linear-gradient(152deg, rgba(36,69,127,.97) 0%, rgba(44,80,155,.94) 36%,
                    rgba(40,69,96,.92) 72%, rgba(36,54,63,.95) 100%),
    rgba(16,26,33,1);
  box-shadow: var(--shadow-lg);
}
.land-close-copy { display: grid; justify-items: start; gap: var(--space-4); }
.land-home .land-close .land-h2 {
  color: rgba(255,255,255,.96);
  font-size: var(--display-md);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -.02em;
}
.land-home .land-close p {
  max-width: 32rem;
  color: rgba(255,255,255,.84);
  font-size: var(--text-lg);
  line-height: 1.6;
}
.land-faq {
  display: grid;
  grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr);
  align-items: start;
  gap: clamp(var(--space-5), 4vw, var(--space-7));
}
.land-faq > .land-head { margin-bottom: 0; }
.land-more {
  display: inline-flex;
  align-items: center;
  justify-self: start;
  gap: var(--space-1-5);
  margin-top: var(--space-2);
  color: var(--ground-accent);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: var(--ground-line);
  text-underline-offset: .25em;
}
.land-more:hover,
.land-more:focus-visible { color: var(--ground-ink); text-decoration-color: currentColor; }
.land-more:focus-visible {
  outline: 2px solid var(--ground-ink);
  outline-offset: 3px;
  border-radius: var(--radius-xs);
}
.land-more i { transition: transform var(--dur-2) var(--ease-out); }
.land-more:hover i,
.land-more:focus-visible i { transform: translateX(var(--space-1)); }
.land-faq-list {
  display: grid;
  overflow: hidden;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow-sm);
}
.land-faq-item + .land-faq-item { border-top: 1px solid var(--border); }
.land-faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding: var(--space-4) var(--space-5);
  cursor: pointer;
  list-style: none;
  font-weight: 600;
}
.land-faq-item summary::-webkit-details-marker { display: none; }
.land-faq-item summary:hover { color: var(--primary-text); }
.land-faq-item summary:focus-visible { outline: 2px solid var(--primary); outline-offset: -2px; }
.land-faq-item summary i {
  flex: none;
  width: 2rem;
  height: 2rem;
  display: grid;
  place-items: center;
  border-radius: var(--radius-round);
  background: var(--primary-soft);
  color: var(--primary-text);
  transition: transform var(--dur-2) var(--ease-out);
}
.land-faq-item[open] summary i { transform: rotate(45deg); }
.land-faq-item p {
  margin: 0;
  padding: 0 var(--space-5) var(--space-3);
  color: var(--muted);
  line-height: 1.7;
}
.land-faq-item p:last-child { padding-bottom: var(--space-5); }
.pub-foot {
  display: grid;
  gap: var(--space-6);
  padding-top: var(--space-6);
  border-top: 1px solid var(--ground-line);
  color: var(--ground-ink-muted);
  font-size: var(--text-sm);
}
.pub-foot-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) repeat(3, minmax(0, 1fr));
  gap: var(--space-6) var(--space-5);
}
.pub-foot-brand {
  display: grid;
  align-content: start;
  justify-items: start;
  gap: var(--space-3);
}
.pub-foot-home {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
}
.pub-foot-mark {
  display: inline-flex;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}
.pub-foot-word {
  font-family: 'Sora Variable', 'Inter Variable', Inter, sans-serif;
  font-size: var(--text-lg);
  font-weight: 700;
}
.pub-foot-brand p { margin: 0; max-width: 24rem; line-height: 1.6; }
.pub-foot-contact,
.pub-foot-col ul {
  display: grid;
  gap: var(--space-2);
  margin: 0;
  padding: 0;
  list-style: none;
}
.pub-foot-contact li { display: flex; align-items: center; gap: var(--space-2); min-width: 0; }
.pub-foot-contact a { overflow-wrap: anywhere; }
.pub-foot-contact i,
.pub-foot-note i { color: var(--ground-accent); }
.pub-foot-h {
  margin: 0 0 var(--space-3);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ground-accent);
}
.pub-foot a { color: var(--ground-ink-muted); text-decoration: none; }
.pub-foot .pub-foot-home { color: var(--ground-ink); }
.pub-foot .pub-foot-h a { color: var(--ground-accent); }
.pub-foot a:hover,
.pub-foot a:focus-visible,
.pub-foot .pub-foot-h a:hover,
.pub-foot .pub-foot-h a:focus-visible {
  color: var(--ground-ink);
  text-decoration: underline;
  text-underline-offset: .2em;
}
.pub-foot a:focus-visible {
  outline: 2px solid var(--ground-ink);
  outline-offset: 3px;
  border-radius: var(--radius-xs);
}
.pub-foot-note {
  display: flex;
  align-items: baseline;
  gap: var(--space-2);
  margin: var(--space-4) 0 0;
  font-size: var(--text-xs);
  line-height: 1.5;
}
.pub-foot-base {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2) var(--space-5);
  padding-top: var(--space-4);
  border-top: 1px solid var(--ground-line);
  font-size: var(--text-xs);
}
.pub-foot-legal { display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-4); }
.pub-card { max-width: 56rem; }
.pub-doc { max-width: 52rem; }
.pub-doc h2 {
  font-size: var(--text-lg);
  margin: var(--space-5) 0 var(--space-2);
  color: var(--text);
}
.pub-doc h2:first-of-type { margin-top: 0; }
.pub-doc p, .pub-doc li { color: var(--muted); line-height: 1.7; }
.pub-doc p { margin: 0 0 var(--space-3); }
.pub-doc ul, .pub-doc ol { margin: 0 0 var(--space-3); padding-left: var(--space-4); display: grid; gap: var(--space-2); }
.pub-doc strong { color: var(--text); }
.pub-meta {
  color: var(--faint);
  font-size: var(--text-sm);
  margin: 0 0 var(--space-4);
}
@media (max-width: 1100px) {
  .land-proof { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
.land-hero { grid-template-columns: 1fr; }
  .land-lead { font-size: var(--text-base); }
  .land-sub { font-size: var(--text-base); }
.land-steps { grid-template-columns: 1fr; }
  .land-step { grid-template-columns: auto minmax(0, 1fr); column-gap: var(--space-4); }
  .land-step::before { grid-row: span 2; margin-bottom: 0; }
  .land-step:not(:last-child)::after {
    top: 3rem;
    bottom: calc(-1 * var(--space-5));
    left: 1.5rem;
    right: auto;
    width: 1px;
    height: auto;
  }
.land-row,
  .land-faq,
  .land-home .land-close { grid-template-columns: 1fr; }
  .land-row figcaption { order: -1; }
  .land-row p { font-size: var(--text-base); }
  .land-trust-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.pub-foot-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .pub-foot-brand { grid-column: 1 / -1; }
}
@media (max-width: 576px) {
  .land { gap: var(--space-5); }
  .land-cta { width: 100%; }
  .land-cta .btn { flex: 1 1 12rem; }
  .land-proof,
  .land-trust-grid { grid-template-columns: 1fr; }
.land-app { padding: var(--space-5) 0 var(--space-7); }
  .land-app-body { grid-template-columns: minmax(0, 1fr); }
  .land-app-side,
  .land-app-toast-file { display: none; }
  .land-app-toast { max-width: 15rem; }
  .land-mock { padding: var(--space-4) 0 var(--space-7); }
.land-home .land-close .land-shot { display: none; }
.pub-foot-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pub-foot-base { flex-direction: column; align-items: flex-start; }
}
@media (prefers-reduced-motion: reduce) {
  .land-card:hover,
  a.land-card:hover .land-card-more i,
  a.land-card:focus-visible .land-card-more i,
  .land-more:hover i,
  .land-more:focus-visible i { transform: none; }
}
@keyframes landFloat {
  from { transform: translateY(0); }
  to   { transform: translateY(-.75rem); }
}
@media (prefers-reduced-motion: no-preference) {
  .land-app-toast { animation: landFloat var(--drift-a) var(--ease-in-out) infinite alternate; }
  .land-app-toast-file { animation-duration: var(--drift-b); }
  .land-mock-toast { animation-duration: var(--drift-c); }
}
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .land-home .land-head,
    .land-home .land-grid,
    .land-home .land-row,
    .land-home .land-steps,
    .land-home .land-trust,
    .land-home .land-faq-list,
    .land-home .land-close {
      animation-name: revealUp;
      animation-timing-function: var(--ease-out);
      animation-fill-mode: both;
      animation-timeline: view();
      animation-range: entry 0% entry 240px;
    }
  }
}
@media print {
  .land-home .land-head,
  .land-home .land-grid,
  .land-home .land-row,
  .land-home .land-steps,
  .land-home .land-trust,
  .land-home .land-faq-list,
  .land-home .land-close {
    animation-name: none;
  }
}
.app-main:has(.door) .app-topbar { display: none; }
.app-content:has(.door) {
position: relative;
  display: grid;
  place-items: center;
  padding: var(--space-5) var(--space-4);
  background:
    radial-gradient(120% 92% at 84% -12%, rgba(210,171,103,.20), transparent 56%),
    linear-gradient(152deg, rgba(36,69,127,.97) 0%, rgba(44,80,155,.94) 36%,
                    rgba(40,69,96,.92) 72%, rgba(36,54,63,.95) 100%),
    rgba(16,26,33,1);
}
.door { color: rgba(255,255,255,.96); text-align: center; }
.door-panel {
  display: grid;
  justify-items: center;
  gap: var(--space-2);
  max-width: 30rem;
}
.door-mark {
  display: inline-flex;
  width: 5.5rem;
  height: 5.5rem;
  margin-bottom: var(--space-3);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}
.door-hi {
  margin: 0;
  font-size: var(--text-lg);
  font-weight: 500;
  letter-spacing: .04em;
  color: rgba(255,255,255,.76);
}
.door-name {
  margin: 0;
  font-size: var(--display-md);
  font-weight: 800;
  letter-spacing: .02em;
}
.door-line {
  margin: 0;
  margin-top: var(--space-2);
  font-size: var(--text-lg);
  color: rgba(255,255,255,.78);
}
.door-corner {
  position: absolute;
  top: var(--space-4);
  right: var(--space-4);
  display: flex;
  align-items: center;
  gap: var(--space-4);
}
.door-about {
  color: rgba(255,255,255,.82);
  font-size: var(--text-sm);
  font-weight: 500;
  text-decoration: none;
  white-space: nowrap;
}
.door-about:hover,
.door-about:focus-visible {
  color: rgba(255,255,255,1);
  text-decoration: underline;
}
.door-go {
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-pill);
  background: rgba(255,255,255,.14);
  border: 1px solid rgba(255,255,255,.38);
  color: rgba(255,255,255,.96);
  font-size: var(--text-sm);
  font-weight: 600;
  backdrop-filter: blur(6px);
}
.door-go:hover,
.door-go:focus-visible {
  background: rgba(255,255,255,.96);
  border-color: rgba(255,255,255,.96);
  color: rgba(36,69,127,1);
}
@media (max-width: 576px) {
  .door-panel { max-width: 22rem; }
.door-corner {
    top: var(--space-3);
    right: var(--space-3);
    gap: var(--space-3);
  }
}
.ka-call {
  position: fixed;
  z-index: 5000;
  inset: auto var(--space-4) var(--space-4) auto;
  display: flex;
  align-items: center;
  justify-content: center;
pointer-events: none;
}
.ka-call[data-state="idle"] { display: none; }
.ka-call-card {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  max-width: min(24rem, calc(100vw - 2rem));
}
.ka-call[data-state="ringing"] {
  inset: 0;
  background: color-mix(in srgb, var(--text) 55%, transparent);
}
.ka-call[data-state="ringing"] .ka-call-card {
  flex-direction: column;
  text-align: center;
  gap: var(--space-4);
  padding: var(--space-6) var(--space-5);
  min-width: min(21rem, calc(100vw - 2rem));
}
.ka-call-avatar {
  flex: none;
  width: 2.9rem;
  height: 2.9rem;
  border-radius: var(--radius-round);
  display: grid;
  place-items: center;
  background: var(--grad-primary);
  color: var(--primary-contrast);
  font-weight: 700;
  font-size: var(--text-lg);
}
.ka-call[data-state="ringing"] .ka-call-avatar {
  width: 5.5rem;
  height: 5.5rem;
  font-size: var(--text-3xl);
animation: kaCallPulse var(--beat) var(--ease-out) infinite;
}
@keyframes kaCallPulse {
  0%   { box-shadow: 0 0 0 0 color-mix(in srgb, var(--primary) 55%, transparent); }
100% { box-shadow: 0 0 0 1.5rem transparent; }
}
.ka-call-who { min-width: 0; flex: 1 1 auto; }
.ka-call-name {
  font-weight: 600;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ka-call[data-state="ringing"] .ka-call-name { font-size: var(--text-xl); }
.ka-call-state { font-size: var(--text-sm); color: var(--muted); }
.ka-call-state > span { display: none; }
.ka-call[data-state="ringing"] .ka-call-in,
.ka-call[data-state="calling"] .ka-call-out,
.ka-call[data-state="live"] .ka-call-on { display: inline; }
.ka-call-on {
font-variant-numeric: tabular-nums;
  color: var(--success);
  font-weight: 600;
}
.ka-call-note {
  font-size: var(--text-sm);
  color: var(--muted);
}
.ka-call-note:empty { display: none; }
.ka-call-actions { display: flex; gap: var(--space-3); flex: none; }
.ka-call-act {
  display: none;                       
  flex-direction: column;
  align-items: center;
  gap: var(--space-1);
}
.ka-call[data-state="ringing"] .ka-call-act:has(.ka-call-yes),
.ka-call[data-state="ringing"] .ka-call-act:has(.ka-call-no),
.ka-call[data-state="calling"] .ka-call-act:has(.ka-call-no),
.ka-call[data-state="live"] .ka-call-act:has(.ka-call-mute),
.ka-call[data-state="live"] .ka-call-act:has(.ka-call-loud),
.ka-call[data-state="live"] .ka-call-act:has(.ka-call-no) { display: flex; }
.ka-call-act-name {
  display: none;
  font-size: var(--text-xs);
  color: var(--muted);
}
.ka-call[data-state="ringing"] .ka-call-act-name { display: block; }
.ka-call-btn {
  width: 2.9rem;
  height: 2.9rem;
  border-radius: var(--radius-round);
  border: 0;
  padding: 0;
  display: grid;
  place-items: center;
  font-size: var(--text-lg);
  cursor: pointer;
}
.ka-call[data-state="ringing"] .ka-call-btn { width: 3.6rem; height: 3.6rem; }
.ka-call-yes {
  background: var(--success-fill);
  color: var(--primary-contrast);
  box-shadow: var(--glow-success);
}
.ka-call-no {
  background: var(--danger-fill);
  color: var(--primary-contrast);
  box-shadow: var(--glow-danger);
}
.ka-call-mute {
  background: var(--surface-muted);
  color: var(--text);
  border: 1px solid var(--border);
}
.ka-call-mute.is-off { background: var(--warning-soft); color: var(--warning); }
.ka-call-loud {
  background: var(--surface-muted);
  color: var(--text);
  border: 1px solid var(--border);
}
.ka-call-loud.is-on {
  background: var(--primary-soft);
  color: var(--primary);
  border-color: var(--primary);
}
@media (max-width: 576px) {
.ka-call { inset: auto 0 var(--bottomnav-h) 0; }
  .ka-call-card {
    max-width: none;
    width: 100%;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  }
.ka-call[data-state="ringing"] { inset: 0; }
  .ka-call[data-state="ringing"] .ka-call-card {
    width: 100%;
    height: 100%;
    max-width: none;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    justify-content: space-between;
    padding: var(--space-7) var(--space-5) var(--space-6);
  }
  .ka-call[data-state="ringing"] .ka-call-who { flex: 0 0 auto; }
  .ka-call[data-state="ringing"] .ka-call-actions {
    width: 100%;
    justify-content: space-evenly;
  }
}
@media (prefers-reduced-motion: reduce) {
  .ka-call[data-state="ringing"] .ka-call-avatar { animation: none; }
}
}   
@layer base {
h1, .h1 { font-size: var(--text-3xl); }
h2, .h2 { font-size: var(--text-2xl); }
h3, .h3 { font-size: var(--text-xl); }
h4, .h4 { font-size: var(--text-lg); }
h5, .h5 { font-size: var(--text-base); }
h6, .h6 { font-size: var(--text-md); }
.small, small { font-size: var(--text-sm); }
.lead { font-size: var(--text-lg); }
}   
@layer components {
.btn                           { --bs-btn-font-size: var(--text-base); }
.btn-sm, .btn-group-sm > .btn  { --bs-btn-font-size: var(--text-sm); }
.btn-lg, .btn-group-lg > .btn  { --bs-btn-font-size: var(--text-lg); }
.dropdown-menu                 { --bs-dropdown-font-size: var(--text-base); }
.tooltip                       { --bs-tooltip-font-size: var(--text-sm); }
.toast                         { --bs-toast-font-size: var(--text-sm); }
.popover {
  --bs-popover-font-size: var(--text-sm);
  --bs-popover-header-font-size: var(--text-base);
}
.progress, .progress-stacked   { --bs-progress-font-size: var(--text-2xs); }
.badge                         { --bs-badge-font-size: var(--text-xs); }
.form-control, .form-select    { font-size: var(--text-base); }
.form-control-sm, .form-select-sm,
.input-group-sm > .btn, .input-group-sm > .form-control,
.input-group-sm > .form-select, .input-group-sm > .input-group-text {
  font-size: var(--text-sm);
}
.form-control-lg, .form-select-lg,
.input-group-lg > .btn, .input-group-lg > .form-control,
.input-group-lg > .form-select, .input-group-lg > .input-group-text {
  font-size: var(--text-lg);
}
.form-text                     { font-size: var(--text-sm); }
.form-control, .form-select, .form-check-input,
.btn-close, .nav-link, .fade {
  transition-duration: var(--dur-1);
  transition-timing-function: var(--ease-out);
}
.modal.fade .modal-dialog, .collapsing {
  transition-duration: var(--dur-3);
  transition-timing-function: var(--ease-out);
}
.offcanvas, .offcanvas-sm, .offcanvas-md,
.offcanvas-lg, .offcanvas-xl, .offcanvas-xxl {
  --bs-offcanvas-transition: transform var(--dur-3) var(--ease-in-out);
}
.progress, .progress-stacked { --bs-progress-bar-transition: width var(--dur-4) var(--ease-out); }
.spinner-border, .spinner-grow { --bs-spinner-animation-speed: var(--spin); }
}   
@layer utilities {
.fs-1 { font-size: var(--text-3xl) !important; }
.fs-2 { font-size: var(--text-2xl) !important; }
.fs-3 { font-size: var(--text-xl) !important; }
.fs-4 { font-size: var(--text-lg) !important; }
.fs-5 { font-size: var(--text-base) !important; }
.fs-6 { font-size: var(--text-md) !important; }
}   
@layer utilities {
@media (forced-colors: active) {
:root {
    --glass: Canvas;
    --border: CanvasText;
    --border-strong: CanvasText;
  }
.app-sidebar, .app-topbar, .bottom-nav, .navbar,
  .dropdown-menu, .toast, .glass-card, .cmdk, .bulk-bar,
  .bi-report .export-bar, .bi-report .alarm-panel,
  .bi-report .drill-bar, .bi-report .xf-bar {
    background: Canvas;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
.dropdown-menu, .toast, .glass-card, .cmdk, .bulk-bar,
  .bi-report .export-bar, .bi-report .alarm-panel,
  .bi-report .drill-bar, .bi-report .xf-bar {
    border: 1px solid CanvasText;
  }
.cmdk-backdrop, .sheet-backdrop, .bi-focus-backdrop, .pw-lock {
    background: Canvas;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
.hero-aurora,
  .auth-visual::after { display: none; }
body::after { display: none; }
.land-shot { background-image: none; }
.land-hero,
  .land-trust,
  .land-home .land-close { background: none; }
  .land-app-window,
  .land-app-toast,
  .land-mock-card { border: 1px solid CanvasText; }
.app-content:has(.door) { background: none; }
  .door-go {
    background: Canvas;
    border: 1px solid CanvasText;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
.text-gradient,
  .error-code {
    background: none;
    -webkit-text-fill-color: CanvasText;
    color: CanvasText;
    animation: none;
  }
:where(a, button, .btn, .form-control, .form-select, .form-check-input,
         [tabindex]:not([tabindex="-1"])):focus-visible {
    outline: 2px solid Highlight;
    outline-offset: 2px;
  }
.collapse-card:focus-visible,
  .harta-kanavace:focus-visible,
  .acc-picker-toggle:focus-visible,
  .acc-chosen-chip:focus-visible,
  th.sortable:focus-visible,
  .acc-day input:focus-visible + span,
  .acc-page input:focus-visible + span,
  .yoy-toggle input:focus-visible + .yoy-track,
  .tm-search:focus-within,
  .tm-sidebar-search:focus-within {
    outline: 2px solid Highlight;
    outline-offset: 2px;
  }
.tax-dot, .cal-swatch {
    width: .85rem;
    height: .85rem;
    background: Canvas;
    border: 2px solid CanvasText;
  }
  .tax-dot.state-late,   .cal-swatch.state-now      { background: CanvasText; }
  .tax-dot.state-soon,   .cal-swatch.state-soon     { border-style: dashed; }
  .tax-dot.state-ahead,  .cal-swatch.state-upcoming { border-style: dotted; }
  .tax-dot.state-done,   .cal-swatch.state-today    { background: Highlight; }
  .cal-swatch.state-past { background: GrayText; }
.tax-dot.state-urgent { background: CanvasText; border-style: double; }
.age-1 { background: Canvas;     border: 2px dotted CanvasText; }
  .age-2 { background: Canvas;     border: 2px dashed CanvasText; }
  .age-3 { background: Canvas;     border: 2px solid  CanvasText; }
  .age-4 { background: CanvasText; border: 2px solid  CanvasText; }
.tm-dot    { background: Canvas; border: 2px solid CanvasText; }
  .tm-dot.on { background: Highlight; }
}
@media (prefers-contrast: more) {
:root {
    --faint: var(--muted);
    --border: var(--border-strong);
    --glass: var(--surface);
  }
.app-sidebar, .app-topbar, .bottom-nav, .navbar,
  .dropdown-menu, .toast, .glass-card, .cmdk, .bulk-bar,
  .bi-report .export-bar, .bi-report .alarm-panel,
  .bi-report .drill-bar, .bi-report .xf-bar {
    background: var(--surface);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
.card, .table-card, .stat-card, .bi-card,
  .form-control, .form-select, .dropdown-menu, .toast {
    border-width: 2px;
  }
}
}   
