/* =============================================================
   Resto AI · Delivery section styles (ported from delivery_v1)
   GENERATED by _handoff_delivery/_build_css.cjs — do not hand-edit.
   All rules scoped under .rai-delivery so they never touch the
   production shell. .resty-mark animations kept global (unique).
   ============================================================= */
/* Self-contained box model for the delivery subtree (design assumes
   border-box; harmless even though the host app already sets it globally). */
.rai-delivery, .rai-delivery *, .rai-delivery *::before, .rai-delivery *::after { box-sizing: border-box; }
.rai-delivery { font-family: var(--font-ui); color: var(--fg-1); font-size: var(--fs-md); line-height: var(--lh-normal); font-variant-numeric: tabular-nums; }
.rai-delivery .rpresent { font-family: var(--font-ui); color: var(--fg-1); }

/* ===== Delivery design tokens — scoped to .rai-delivery ===== */
/* Seed: colors_and_type.css :root (v1 warm palette) */
.rai-delivery {
  

  
  --orange-50:  #FFF1EA;
  --orange-100: #FFD9C5;
  --orange-200: #FFB394;
  --orange-300: #FF8A5C;
  --orange-400: #FB5F2C; 
  --orange-500: #E54E1E;
  --orange-600: #B33B14;
  --orange-700: #7A270B;

  
  --ink-0:    #0E0B09; 
  --ink-50:   #14110D;
  --ink-100:  #1A1612;
  --ink-150:  #211C17;
  --ink-200:  #2A241E;
  --ink-300:  #3A322A;
  --ink-400:  #524739;
  --ink-500:  #756753;
  --ink-600:  #998973;
  --ink-700:  #BAAA94;
  --ink-800:  #D8CBB6;
  --ink-850:  #E8DDCB;
  --ink-900:  #F1E8D9;
  --ink-950:  #F8F2E7;
  --ink-1000: #FDFAF3; 

  
  --brown-400: #9E6D40;
  --brown-200: rgba(158, 109, 64, 0.18);
  --brown-100: rgba(158, 109, 64, 0.10);
  --brown-50:  rgba(158, 109, 64, 0.06);

  
  --green-400: #4FB477;
  --green-500: #2F9D5F;
  --green-bg:  rgba(79, 180, 119, 0.14);

  --red-400:   #F26B5C;
  --red-500:   #E04A38;
  --red-bg:    rgba(242, 107, 92, 0.14);

  --amber-400: #F4A93A;
  --amber-500: #DC8E1C;
  --amber-bg:  rgba(244, 169, 58, 0.14);

  --blue-400:  #6CA9F2;
  --blue-500:  #3F86E0;
  --blue-bg:   rgba(108, 169, 242, 0.14);

  

  
  --surface-page:     var(--ink-50);   
  --surface-rail:     var(--ink-100);  
  --surface-1:        var(--ink-150);  
  --surface-2:        var(--ink-200);  
  --surface-3:        var(--ink-300);  
  --surface-inverse:  var(--ink-950);
  --surface-overlay:  rgba(14, 11, 9, 0.72);

  
  --fg-1:        var(--ink-950); 
  --fg-2:        var(--ink-800); 
  --fg-3:        var(--ink-600); 
  --fg-muted:    var(--ink-500); 
  --fg-inverse:  var(--ink-50);
  --fg-onbrand:  var(--ink-1000);

  
  --border-subtle:  rgba(251, 95, 44, 0.08);
  --border-default: rgba(251, 95, 44, 0.14);
  --border-strong:  rgba(251, 95, 44, 0.28);
  --divider:        rgba(216, 203, 182, 0.07);

  
  --brand:           var(--orange-400);
  --brand-hover:     var(--orange-500);
  --brand-press:     var(--orange-600);
  --brand-soft:      rgba(251, 95, 44, 0.14);
  --brand-soft-hi:   rgba(251, 95, 44, 0.22);

  
  --success:    var(--green-400);
  --success-bg: var(--green-bg);
  --danger:     var(--red-400);
  --danger-bg:  var(--red-bg);
  --warning:    var(--amber-400);
  --warning-bg: var(--amber-bg);
  --info:       var(--blue-400);
  --info-bg:    var(--blue-bg);

  
  --page-gradient:
    radial-gradient(ellipse 70% 50% at 92% -5%,  rgba(251, 95, 44, 0.10) 0%, transparent 60%),
    radial-gradient(ellipse 38% 30% at 0% 95%,   rgba(251, 95, 44, 0.04) 0%, transparent 60%);

  

  --font-display: 'Inter', ui-sans-serif, system-ui, sans-serif;
  --font-ui:      'Inter', ui-sans-serif, system-ui, sans-serif;
  --font-alt:     'Inter', ui-sans-serif, system-ui, sans-serif;
  /* Jesus's dashboard renders ALL numbers/labels in Inter (his font-mono is
     defined but never applied). So "mono" here = Inter too; tabular-nums on the
     .rai-delivery root keeps figures column-aligned without a monospace face. */
  --font-mono:    'Inter', ui-sans-serif, system-ui, sans-serif;

  
  --fs-2xs: 10px;
  --fs-xs:  11px;
  --fs-sm:  12px;
  --fs-md:  13px;  
  --fs-lg:  15px;
  --fs-xl:  18px;
  --fs-2xl: 22px;
  --fs-3xl: 28px;
  --fs-4xl: 36px;
  --fs-5xl: 48px;
  --fs-6xl: 64px;

  --lh-tight:   1.15;
  --lh-snug:    1.25;
  --lh-normal:  1.45;
  --lh-loose:   1.6;

  --tracking-display: -0.02em;
  --tracking-h:       -0.015em;
  --tracking-body:    0;
  --tracking-label:   0.06em; 
  --tracking-mono:    0;

  
  --fw-regular:  400;
  --fw-medium:   500;
  --fw-semibold: 600;
  --fw-bold:     700;

  

  --sp-0:  0;
  --sp-1:  2px;
  --sp-2:  5px;
  --sp-3:  10px;
  --sp-4:  15px;
  --sp-5:  20px;
  --sp-6:  25px;
  --sp-7:  30px;
  --sp-8:  40px;
  --sp-9:  50px;
  --sp-10: 60px;
  --sp-12: 80px;

  

  --radius-xs: 4px;
  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --radius-2xl: 24px;
  --radius-pill: 999px;

  

  --shadow-xs:  0 1px 0 rgba(0,0,0,.20);
  --shadow-sm:  0 1px 2px rgba(0,0,0,.30), 0 0 0 1px rgba(251, 95, 44, 0.06);
  --shadow-md:  0 6px 18px -6px rgba(0,0,0,.45), 0 0 0 1px rgba(251, 95, 44, 0.08);
  --shadow-lg:  0 18px 40px -12px rgba(0,0,0,.55), 0 0 0 1px rgba(251, 95, 44, 0.10);
  --shadow-xl:  0 32px 80px -16px rgba(0,0,0,.65), 0 0 0 1px rgba(251, 95, 44, 0.12);
  --shadow-glow: 0 0 0 4px rgba(251, 95, 44, 0.18);

  

  --ease-out:    cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);

  --dur-instant: 80ms;
  --dur-fast:    140ms;
  --dur-base:    220ms;
  --dur-slow:    380ms;

  

  --rail-width:   72px;   
  --sidebar-width: 240px; 
  --container-max: 1440px;
}
/* Override: tokens-v2.css :root (LIGHT default, v2 wins) */
.rai-delivery {
  

  
  --orange-50:  oklch(0.97 0.025 50);
  --orange-100: oklch(0.93 0.06  50);
  --orange-200: oklch(0.86 0.11  48);
  --orange-300: oklch(0.78 0.16  45);
  --orange-400: oklch(0.68 0.19  42); 
  --orange-500: oklch(0.60 0.18  38);
  --orange-600: oklch(0.50 0.16  35);
  --orange-700: oklch(0.40 0.13  32);

  
  --cream-0:    oklch(1.000 0     0);
  --cream-50:   oklch(0.992 0.003 70);   
  --cream-100:  oklch(0.985 0.005 70);   
  --cream-150:  oklch(0.975 0.006 70);   
  --cream-200:  oklch(0.960 0.007 70);   
  --cream-300:  oklch(0.935 0.008 70);   
  --cream-400:  oklch(0.880 0.010 70);   

  
  --ink-100:  oklch(0.143 0.010 60);   
  --ink-150:  oklch(0.180 0.011 60);
  --ink-200:  oklch(0.220 0.012 60);   
  --ink-300:  oklch(0.290 0.013 60);
  --ink-400:  oklch(0.380 0.013 60);
  --ink-500:  oklch(0.500 0.012 60);   
  --ink-600:  oklch(0.620 0.010 60);   
  --ink-700:  oklch(0.730 0.008 60);
  --ink-800:  oklch(0.830 0.006 60);
  --ink-900:  oklch(0.920 0.005 60);
  --ink-950:  oklch(0.962 0.005 65);

  
  --green-400: oklch(0.72 0.13 155);
  --green-500: oklch(0.62 0.14 155);
  --green-600: oklch(0.52 0.13 155);

  --red-400:   oklch(0.68 0.18  25);
  --red-500:   oklch(0.58 0.20  25);
  --red-600:   oklch(0.48 0.18  25);

  --amber-400: oklch(0.78 0.13  75);
  --amber-500: oklch(0.70 0.14  70);

  --blue-400:  oklch(0.68 0.13 250);
  --blue-500:  oklch(0.58 0.16 250);

  --purple-400: oklch(0.68 0.13 295);

  

  --chart-1:    oklch(0.68 0.19 42);   
  --chart-1-fill: oklch(0.68 0.19 42 / 0.18);
  --chart-2:    oklch(0.42 0.04 50);   
  --chart-2-fill: oklch(0.42 0.04 50 / 0.10);
  --chart-3:    oklch(0.78 0.13 75);   
  --chart-3-fill: oklch(0.78 0.13 75 / 0.18);
  --chart-4:    oklch(0.62 0.14 155);  
  --chart-4-fill: oklch(0.62 0.14 155 / 0.18);
  --chart-5:    oklch(0.58 0.16 250);  
  --chart-5-fill: oklch(0.58 0.16 250 / 0.18);

  --chart-grid:    oklch(0.92 0.005 70);  
  --chart-axis:    oklch(0.55 0.008 60);  
  --chart-tooltip-bg: oklch(0.143 0.010 60);
  --chart-tooltip-fg: oklch(0.962 0.005 65);

  

  
  --surface-page:     var(--cream-50);
  --surface-rail:     var(--cream-0);
  --surface-1:        var(--cream-0);    
  --surface-2:        var(--cream-100);  
  --surface-3:        var(--cream-150);  
  --surface-hover:    var(--cream-200);
  --surface-inverse:  var(--ink-150);
  --surface-overlay:  oklch(0.143 0.010 60 / 0.40);

  
  --fg-1:        var(--ink-100);   
  --fg-2:        var(--ink-400);   
  --fg-3:        var(--ink-500);   
  --fg-muted:    var(--ink-600);   
  --fg-inverse:  var(--cream-0);
  --fg-onbrand:  var(--cream-0);

  
  --border-subtle:  oklch(0 0 0 / 0.06);   
  --border-default: oklch(0 0 0 / 0.09);   
  --border-strong:  oklch(0 0 0 / 0.14);   
  --divider:        oklch(0 0 0 / 0.06);

  
  --brand:           var(--orange-400);
  --brand-hover:     var(--orange-500);
  --brand-press:     var(--orange-600);
  --brand-soft:      oklch(0.68 0.19 42 / 0.10);
  --brand-soft-hi:   oklch(0.68 0.19 42 / 0.18);
  --brand-ring:      oklch(0.68 0.19 42 / 0.22);

  
  --success:    var(--green-500);
  --success-bg: oklch(0.62 0.14 155 / 0.10);
  --danger:     var(--red-500);
  --danger-bg:  oklch(0.58 0.20 25 / 0.10);
  --warning:    var(--amber-500);
  --warning-bg: oklch(0.70 0.14 70 / 0.12);
  --info:       var(--blue-500);
  --info-bg:    oklch(0.58 0.16 250 / 0.10);

  
  --page-gradient: none;

  
  --dot-grid-color: oklch(0 0 0 / 0.04);

  

  --font-display: 'Inter', ui-sans-serif, system-ui, sans-serif;
  --font-ui:      'Inter', ui-sans-serif, system-ui, sans-serif;
  --font-alt:     'Inter', ui-sans-serif, system-ui, sans-serif;
  /* Jesus's dashboard renders ALL numbers/labels in Inter (his font-mono is
     defined but never applied). So "mono" here = Inter too; tabular-nums on the
     .rai-delivery root keeps figures column-aligned without a monospace face. */
  --font-mono:    'Inter', ui-sans-serif, system-ui, sans-serif;

  
  --fs-2xs: 10px;
  --fs-xs:  11px;
  --fs-sm:  12px;
  --fs-md:  13px;   
  --fs-lg:  15px;
  --fs-xl:  18px;
  --fs-2xl: 22px;
  --fs-3xl: 28px;
  --fs-4xl: 36px;
  --fs-5xl: 48px;
  --fs-6xl: 64px;
  --fs-7xl: 88px;   

  --lh-tight:   1.1;
  --lh-snug:    1.25;
  --lh-normal:  1.5;
  --lh-loose:   1.65;

  --tracking-display: -0.025em;
  --tracking-h:       -0.015em;
  --tracking-body:    0;
  --tracking-label:   0.06em;
  --tracking-mono-tight: -0.015em;

  --fw-regular:   400;
  --fw-medium:    500;
  --fw-semibold:  600;
  --fw-bold:      700;

  

  --sp-0:   0;
  --sp-1:   2px;
  --sp-2:   4px;
  --sp-3:   8px;
  --sp-4:  12px;
  --sp-5:  16px;
  --sp-6:  20px;
  --sp-7:  24px;
  --sp-8:  32px;
  --sp-9:  40px;
  --sp-10: 48px;
  --sp-12: 64px;
  --sp-14: 80px;
  --sp-16: 96px;

  

  --radius-xs:  3px;
  --radius-sm:  5px;
  --radius-md:  7px;
  --radius-lg:  10px;
  --radius-xl:  14px;
  --radius-2xl: 18px;
  --radius-3xl: 24px;
  --radius-pill: 999px;

  

  --shadow-xs:  none;
  --shadow-sm:  0 1px 2px oklch(0 0 0 / 0.06);
  --shadow-md:  0 2px 8px -2px oklch(0 0 0 / 0.10), 0 1px 2px oklch(0 0 0 / 0.04);
  --shadow-lg:  0 8px 24px -8px oklch(0 0 0 / 0.16), 0 2px 6px -2px oklch(0 0 0 / 0.06);
  --shadow-xl:  0 24px 56px -12px oklch(0 0 0 / 0.22), 0 4px 12px -4px oklch(0 0 0 / 0.08);
  --shadow-glow: 0 0 0 3px var(--brand-ring);

  

  --ease-out:    cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);

  --dur-instant: 80ms;
  --dur-fast:    140ms;
  --dur-base:    220ms;
  --dur-slow:    380ms;

  

  --rail-width:    52px;
  --sidebar-width: 224px;
  --container-max: 1440px;
  --header-height: 56px;

  color-scheme: light dark;
  --ink-50: var(--cream-100);
}
/* Dark mode — driven by the production [data-theme="dark"] on <html>.
   Claude Design (delivery_v1 / tokens-v2) warm-ink ladder — the actual target:
   page ink-100 oklch(0.143) → rail/cards ink-150 oklch(0.180) → nested/input
   ink-200 oklch(0.220) → hover ink-300 oklch(0.290). Deep cohesive near-blacks,
   subtle step — matches the global theme. */
[data-theme="dark"] .rai-delivery {
  --surface-page:     oklch(0.143 0.010 60);
  --surface-rail:     oklch(0.180 0.011 60);
  --surface-1:        oklch(0.180 0.011 60);
  --surface-2:        oklch(0.220 0.012 60);
  --surface-3:        oklch(0.220 0.012 60);
  --surface-hover:    oklch(0.290 0.013 60);
  --surface-inverse:  var(--cream-0);
  --surface-overlay:  oklch(0 0 0 / 0.60);

  --fg-1:        var(--ink-950);
  --fg-2:        var(--ink-800);
  --fg-3:        var(--ink-700);
  --fg-muted:    var(--ink-600);
  --fg-inverse:  var(--ink-100);
  --fg-onbrand:  var(--ink-950);

  --border-subtle:  oklch(1 0 0 / 0.06);
  --border-default: oklch(1 0 0 / 0.10);
  --border-strong:  oklch(1 0 0 / 0.16);
  --divider:        oklch(1 0 0 / 0.06);

  --chart-grid:    oklch(1 0 0 / 0.06);
  --chart-axis:    oklch(0.65 0 0);
  --chart-tooltip-bg: var(--ink-200);
  --chart-tooltip-fg: var(--ink-950);

  --dot-grid-color: oklch(1 0 0 / 0.04);

  --shadow-sm:  0 1px 2px oklch(0 0 0 / 0.30);
  --shadow-md:  0 2px 12px -2px oklch(0 0 0 / 0.45), 0 1px 2px oklch(0 0 0 / 0.20);
  --shadow-lg:  0 12px 32px -10px oklch(0 0 0 / 0.55), 0 2px 6px -2px oklch(0 0 0 / 0.25);
  --shadow-xl:  0 28px 64px -16px oklch(0 0 0 / 0.65);

  /* Claude Design (tokens-v2) warm-ink ladder so every direct var(--ink-*)
     consumer (surfaces, hatch indicators, gradient stops, status dots,
     dividers, text) reads the same warm near-blacks + warm fg as the target. */
  --ink-50:  oklch(0.120 0.010 60);
  --ink-100: oklch(0.143 0.010 60);
  --ink-150: oklch(0.180 0.011 60);
  --ink-200: oklch(0.220 0.012 60);
  --ink-300: oklch(0.290 0.013 60);
  --ink-400: oklch(0.380 0.013 60);
  --ink-500: oklch(0.500 0.012 60);
  --ink-600: oklch(0.620 0.010 60);
  --ink-700: oklch(0.730 0.008 60);
  --ink-800: oklch(0.830 0.006 60);
  --ink-900: oklch(0.920 0.005 60);
  --ink-950: oklch(0.962 0.005 65);
}
/* v1 light overrides retained for any v1-only var consumers */
[data-theme="light"] .rai-delivery {
  --surface-page:     var(--ink-1000);
  --surface-rail:     #fdfaf5;
  --surface-1:        #ffffff;
  --surface-2:        #fbf6ee;
  --surface-3:        #f1eade;
  --surface-inverse:  var(--ink-50);
  --surface-overlay:  rgba(20, 17, 13, 0.40);

  --fg-1:        #1a1612;
  --fg-2:        #514738;
  --fg-3:        #7a6f66;
  --fg-muted:    #999088;
  --fg-inverse:  var(--ink-1000);
  --fg-onbrand:  #ffffff;

  --border-subtle:  rgba(158, 109, 64, 0.08);
  --border-default: rgba(158, 109, 64, 0.14);
  --border-strong:  rgba(158, 109, 64, 0.28);
  --divider:        rgba(158, 109, 64, 0.08);

  --page-gradient:
    radial-gradient(ellipse 85% 60% at 80% -10%, rgba(251, 100, 50, 0.14) 0%, transparent 65%),
    radial-gradient(ellipse 50% 40% at 100% 40%, rgba(251, 95, 44, 0.05) 0%, transparent 60%);

  --shadow-sm:  0 1px 2px rgba(160, 80, 30, 0.10), 0 0 0 1px rgba(158, 109, 64, 0.06);
  --shadow-md:  0 6px 18px -6px rgba(160, 80, 30, 0.18), 0 0 0 1px rgba(158, 109, 64, 0.08);
  --shadow-lg:  0 18px 40px -12px rgba(160, 80, 30, 0.22), 0 0 0 1px rgba(158, 109, 64, 0.10);
  --shadow-xl:  0 32px 80px -16px rgba(160, 80, 30, 0.28), 0 0 0 1px rgba(158, 109, 64, 0.12);

  --ink-50: var(--cream-100);
}

/* ===== dashboard.css (scoped) ===== */
.rai-delivery .font-mono, .rai-delivery [class*="-mono"], .rai-delivery code, .rai-delivery kbd, .rai-delivery pre {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .client-chip {
  margin: 6px 4px 12px;
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 10px;
  padding: 10px 12px;
  display: flex; align-items: center; gap: 10px;
  cursor: pointer;
  transition: all var(--dur-fast) var(--ease-out);
}
.rai-delivery .client-chip:hover { border-color: var(--border-strong); background: var(--surface-2); }
.rai-delivery .client-chip .mark {
  width: 30px; height: 30px; border-radius: 7px;
  background: linear-gradient(135deg, var(--brand) 0%, #B33B14 100%);
  display: flex; align-items: center; justify-content: center;
  font: 600 12px var(--font-ui); color: white;
  flex-shrink: 0;
}
.rai-delivery .client-chip .info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.rai-delivery .client-chip .info .name { font: 600 12px var(--font-ui); color: var(--fg-1); white-space: nowrap; text-overflow: ellipsis; overflow: hidden; }
.rai-delivery .client-chip .info .meta { font: 500 10px var(--font-mono); color: var(--fg-3); white-space: nowrap; text-overflow: ellipsis; overflow: hidden; }
.rai-delivery .client-chip .switch { color: var(--fg-3); }
/* Fill the full main-content frame: no max-width centering (was 1440px →
   left side-bands on wide screens) and no horizontal padding (the global
   .main already insets by --sp-8; doubling it left a wide empty margin).
   Vertical padding only, trimmed so content reaches closer to the bottom. */
.rai-delivery .page { padding: 18px 0 20px; max-width: none; }

/* Dots are now a single GLOBAL layer on .main (see style.css) so the pattern
   is identical across the whole dashboard — no Delivery-specific dot rule here
   anymore (that caused a second, differently-aligned layer). The global layer
   excludes Delivery's full-bleed Reports/Resty shells via .main:has(...). */
.rai-delivery .page-head {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px;
  align-items: flex-start;
  margin-bottom: 22px;
}
.rai-delivery .page-head .eyebrow {
  font: 600 10px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--brand);
  display: flex; align-items: center; gap: 8px;
  margin-bottom: 10px;
}
.rai-delivery .page-head .eyebrow .crumb-sep { width: 3px; height: 3px; border-radius: 50%; background: var(--ink-400); }
.rai-delivery .page-head .eyebrow .crumb-muted { color: var(--fg-3); letter-spacing: .08em; }
.rai-delivery .page-head h1 {
  font-family: var(--font-ui);
  font-weight: 600;
  letter-spacing: -.022em;
  font-size: 32px;
  line-height: 1.05;
  letter-spacing: -.02em;
  color: var(--fg-1);
  margin: 0;
}
.rai-delivery .page-head h1 em { font-style: italic; color: var(--brand); }
.rai-delivery .page-head .sub { font: 400 14px var(--font-ui); color: var(--fg-3); max-width: 580px; margin-top: 8px; }
.rai-delivery .page-head .actions { display: flex; gap: 8px; align-items: center; }
.rai-delivery .btn {
  display: inline-flex; align-items: center; gap: 8px;
  font: 600 12px var(--font-ui);
  padding: 8px 14px;
  border-radius: 8px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all var(--dur-fast) var(--ease-out);
  white-space: nowrap;
}
.rai-delivery .btn svg { width: 14px; height: 14px; }
.rai-delivery .btn-primary { background: var(--brand); color: var(--fg-onbrand); }
.rai-delivery .btn-primary:hover { background: var(--brand-hover); }
.rai-delivery .btn-secondary { background: var(--surface-1); color: var(--fg-1); border-color: var(--border-default); }
.rai-delivery .btn-secondary:hover { background: var(--surface-2); }
.rai-delivery .btn-ghost { background: transparent; color: var(--fg-2); }
.rai-delivery .btn-ghost:hover { background: var(--surface-1); color: var(--fg-1); }
.rai-delivery .tabs {
  display: flex;
  gap: 2px;
  border-bottom: 1px solid var(--border-subtle);
  margin-bottom: 22px;
  position: relative;
}
.rai-delivery .tab {
  background: transparent;
  border: none;
  color: var(--fg-3);
  font: 500 13px var(--font-ui);
  padding: 10px 14px 12px;
  cursor: pointer;
  position: relative;
  transition: color var(--dur-fast) var(--ease-out);
  display: inline-flex; align-items: center; gap: 7px;
}
.rai-delivery .tab:hover { color: var(--fg-1); }
.rai-delivery .tab.on { color: var(--fg-1); }
.rai-delivery .tab.on::after {
  content: "";
  position: absolute; left: 8px; right: 8px; bottom: -1px;
  height: 2px;
  background: var(--brand);
  border-radius: 2px 2px 0 0;
}
.rai-delivery .tab .badge-tiny {
  background: var(--surface-2);
  color: var(--fg-3);
  font: 600 9px var(--font-mono);
  padding: 1px 6px;
  border-radius: 999px;
}
.rai-delivery .tab.on .badge-tiny { background: var(--brand-soft); color: var(--brand); }
.rai-delivery .card {
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}
.rai-delivery .card-head { padding: 16px 20px; border-bottom: 1px solid var(--divider); display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.rai-delivery .card-head h3 { margin: 0; font: 600 14px var(--font-ui); color: var(--fg-1); }
.rai-delivery .card-head .sub { font: 400 12px var(--font-ui); color: var(--fg-3); margin-top: 2px; }
.rai-delivery .card-body { padding: 20px; }
.rai-delivery .badge {
  display: inline-flex; align-items: center; gap: 5px;
  font: 600 11px var(--font-ui);
  padding: 3px 9px;
  border-radius: 999px;
  border: 1px solid transparent;
}
.rai-delivery .badge .dot { width: 6px; height: 6px; border-radius: 50%; }
.rai-delivery .badge-success { background: var(--success-bg); color: var(--success); border-color: rgba(79,180,119,.3); }
.rai-delivery .badge-danger { background: var(--danger-bg); color: var(--danger); border-color: rgba(242,107,92,.3); }
.rai-delivery .badge-warning { background: var(--warning-bg); color: var(--warning); border-color: rgba(244,169,58,.3); }
.rai-delivery .badge-info { background: var(--info-bg); color: var(--info); border-color: rgba(108,169,242,.3); }
.rai-delivery .badge-brand { background: var(--brand-soft); color: var(--brand); border-color: rgba(251,95,44,.3); }
.rai-delivery .badge-neutral { background: var(--surface-3); color: var(--fg-2); border-color: var(--border-default); }
.rai-delivery .kpi-band {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  margin-bottom: 18px;
}
.rai-delivery .kpi {
  padding: 22px 24px;
  border-right: 1px solid var(--divider);
  position: relative;
  display: flex; flex-direction: column; gap: 8px;
}
.rai-delivery .kpi:last-child { border-right: none; }
.rai-delivery .kpi.is-active { background: linear-gradient(180deg, rgba(251,95,44,.06) 0%, transparent 60%); }
.rai-delivery .kpi.is-active::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: var(--brand);
}
.rai-delivery .kpi .lbl { font: 600 10px var(--font-ui); text-transform: uppercase; letter-spacing: .1em; color: var(--fg-3); display: flex; align-items: center; gap: 6px; }
.rai-delivery .kpi .lbl .dot { width: 6px; height: 6px; border-radius: 50%; }
.rai-delivery .kpi .val { font-family: var(--font-mono); font-size: 32px; font-weight: 500; line-height: 1; letter-spacing: -.025em; font-variant-numeric: tabular-nums; color: var(--fg-1); display: flex; align-items: baseline; gap: 4px; }
.rai-delivery .kpi .val .unit { font-size: 14px; color: var(--fg-3); margin-left: 2px; font-weight: 400; }
.rai-delivery .kpi .val .pre { font-size: 18px; color: var(--fg-3); margin-right: 1px; font-weight: 400; }
.rai-delivery .kpi .delta-row { display: flex; align-items: center; gap: 10px; font-family: var(--font-mono); font-size: 11px; font-variant-numeric: tabular-nums; color: var(--fg-3); }
.rai-delivery .kpi .delta { display: inline-flex; align-items: center; gap: 3px; font-weight: 600; }
.rai-delivery .kpi .delta.up { color: var(--success); }
.rai-delivery .kpi .delta.down { color: var(--danger); }
.rai-delivery .kpi .delta.neutral { color: var(--fg-2); }
.rai-delivery .kpi .vs { color: var(--fg-muted); }
.rai-delivery .kpi .spark { margin-top: 6px; height: 32px; }
.rai-delivery .micro-grid { display: grid; gap: 1px; background: var(--border-subtle); border: 1px solid var(--border-default); border-radius: var(--radius-md); overflow: hidden; }
.rai-delivery .micro {
  padding: 14px 16px;
  background: var(--surface-1);
  display: flex; flex-direction: column; gap: 4px;
}
.rai-delivery .micro .lbl { font: 600 9px var(--font-ui); text-transform: uppercase; letter-spacing: .1em; color: var(--fg-3); }
.rai-delivery .micro .val { font-family: var(--font-mono); font-size: 18px; font-weight: 500; line-height: 1.1; color: var(--fg-1); font-variant-numeric: tabular-nums; }
.rai-delivery .micro .delta { font-family: var(--font-mono); font-size: 10px; }
.rai-delivery .micro .delta.up { color: var(--success); }
.rai-delivery .micro .delta.down { color: var(--danger); }
.rai-delivery .seg {
  display: inline-flex;
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 8px;
  padding: 3px;
  gap: 2px;
}
.rai-delivery .seg button {
  background: transparent;
  border: none;
  color: var(--fg-3);
  font: 600 11px var(--font-ui);
  padding: 5px 12px;
  border-radius: 6px;
  cursor: pointer;
  transition: all var(--dur-fast) var(--ease-out);
}
.rai-delivery .seg button.on { background: var(--surface-3); color: var(--fg-1); }
.rai-delivery .seg button:hover:not(.on) { color: var(--fg-1); }
.rai-delivery .table { width: 100%; border-collapse: collapse; }
.rai-delivery .table th {
  text-align: left;
  font: 600 10px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--fg-3);
  padding: 10px 16px;
  border-bottom: 1px solid var(--divider);
  background: var(--surface-page);
}
.rai-delivery .table td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--divider);
  font: 400 13px var(--font-ui);
  color: var(--fg-2);
  vertical-align: middle;
}
.rai-delivery .table tr:last-child td { border-bottom: none; }
.rai-delivery .table tr:hover td { background: var(--surface-2); }
.rai-delivery .table .num { font-family: var(--font-mono); font-variant-numeric: tabular-nums; color: var(--fg-1); }
.rai-delivery .stars { color: #F4A93A; letter-spacing: 1.5px; font-size: 13px; line-height: 1; }
.rai-delivery .stars .empty { color: var(--ink-300); }
.rai-delivery .timefilter {
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 14px 18px 16px;
  margin-bottom: 18px;
  box-shadow: var(--shadow-sm);
}
.rai-delivery .tf-top {
  display: flex; align-items: center; gap: 14px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}
.rai-delivery .tf-range {
  display: flex; flex-direction: column; gap: 2px;
  margin-right: 6px;
  min-width: 200px;
}
.rai-delivery .tf-range .label { font: 600 9px var(--font-ui); text-transform: uppercase; letter-spacing: .12em; color: var(--fg-3); }
.rai-delivery .tf-range .value {
  font-family: var(--font-ui);
  font-weight: 600;
  letter-spacing: -.012em;
  font-size: 18px;
  line-height: 1.1;
  letter-spacing: -.01em;
  color: var(--fg-1);
}
.rai-delivery .tf-range .value em { font-style: italic; color: var(--brand); }
.rai-delivery .tf-presets {
  display: inline-flex;
  background: transparent;
  border: 1px solid var(--border-default);
  border-radius: 8px;
  padding: 0;
  overflow: hidden;
}
.rai-delivery .tf-presets button {
  background: transparent;
  border: none;
  border-right: 1px solid var(--border-subtle);
  color: var(--fg-3);
  font: 600 11px var(--font-ui);
  padding: 7px 12px;
  cursor: pointer;
  transition: all var(--dur-fast) var(--ease-out);
}
.rai-delivery .tf-presets button:last-child { border-right: none; }
.rai-delivery .tf-presets button:hover { color: var(--fg-1); background: var(--surface-2); }
.rai-delivery .tf-presets button.on { background: var(--brand-soft); color: var(--brand); }
.rai-delivery .tf-grow { flex: 1; }
.rai-delivery .tf-compare {
  display: inline-flex; align-items: center; gap: 8px;
  font: 500 12px var(--font-ui);
  color: var(--fg-2);
  padding: 6px 10px;
  border: 1px solid var(--border-default);
  border-radius: 8px;
  cursor: pointer;
}
.rai-delivery .tf-compare:hover { background: var(--surface-2); }
.rai-delivery .tf-compare svg { width: 13px; height: 13px; color: var(--fg-3); }
.rai-delivery .tf-compare .compare-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--brand); }
.rai-delivery .tf-compare .compare-dot.muted { background: var(--ink-400); }
.rai-delivery .tf-gran {
  display: inline-flex;
  background: var(--surface-page);
  border: 1px solid var(--border-default);
  border-radius: 8px;
  padding: 3px;
  gap: 1px;
}
.rai-delivery .tf-gran button {
  background: transparent; border: none;
  color: var(--fg-3);
  font: 600 11px var(--font-mono);
  padding: 4px 9px;
  border-radius: 6px;
  cursor: pointer;
  width: 26px;
}
.rai-delivery .tf-gran button.on { background: var(--surface-3); color: var(--fg-1); }
.rai-delivery .tf-strip {
  position: relative;
  height: 56px;
  background: var(--surface-page);
  border-radius: 8px;
  border: 1px solid var(--border-subtle);
  padding: 8px 10px;
  display: flex; align-items: stretch;
  gap: 2px;
  user-select: none;
  cursor: crosshair;
}
.rai-delivery .tf-month {
  flex: 1;
  position: relative;
  border-radius: 4px;
  background: var(--surface-2);
  display: flex; align-items: flex-end; justify-content: center;
  padding-bottom: 2px;
  transition: background var(--dur-fast) var(--ease-out);
  cursor: pointer;
  min-width: 0;
}
.rai-delivery .tf-month:hover { background: var(--surface-3); }
.rai-delivery .tf-month .bar {
  position: absolute;
  left: 4px; right: 4px; bottom: 12px;
  background: var(--ink-400);
  border-radius: 2px 2px 0 0;
  transition: background var(--dur-fast) var(--ease-out);
}
.rai-delivery .tf-presets { position: relative; }
.rai-delivery .tf-custom-pop {
  position: absolute; top: calc(100% + 6px); right: 0;
  min-width: 260px;
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 12px;
  box-shadow: 0 14px 36px rgba(0,0,0,.34), 0 2px 8px rgba(0,0,0,.2);
  padding: 14px;
  z-index: 80;
  display: flex; flex-direction: column; gap: 10px;
}
.rai-delivery .tf-custom-row { display: flex; align-items: center; gap: 10px; justify-content: space-between; }
.rai-delivery .tf-custom-row label { font: 600 10px var(--font-ui); text-transform: uppercase; letter-spacing: .1em; color: var(--fg-3); }
.rai-delivery .tf-custom-row input[type="date"] {
  background: var(--surface-2);
  border: 1px solid var(--border-subtle);
  border-radius: 7px;
  padding: 6px 9px;
  color: var(--fg-1);
  font: 500 12px var(--font-ui);
  font-variant-numeric: tabular-nums;
  outline: none;
  color-scheme: dark;
}
.rai-delivery .tf-custom-row input[type="date"]:focus { border-color: var(--brand); }
.rai-delivery .tf-custom-foot { display: flex; justify-content: flex-end; gap: 8px; margin-top: 4px; }
.rai-delivery .tf-custom-foot button {
  background: transparent; border: 1px solid var(--border-subtle);
  color: var(--fg-2); font: 500 12px var(--font-ui);
  padding: 6px 12px; border-radius: 7px; cursor: pointer;
}
.rai-delivery .tf-custom-foot button.primary { background: var(--brand); border-color: var(--brand); color: var(--fg-onbrand); }
.rai-delivery .tf-month .lab {
  font: 600 9px var(--font-mono);
  color: var(--fg-3);
  text-transform: uppercase;
  letter-spacing: .04em;
  position: relative; z-index: 2;
}
.rai-delivery .tf-month.in-range .bar { background: var(--brand); box-shadow: 0 0 12px rgba(251,95,44,.35); }
.rai-delivery .tf-month.in-range .lab { color: var(--fg-1); }
.rai-delivery .tf-month.in-range { background: rgba(251,95,44,.10); }
.rai-delivery .tf-month.now { outline: 1px solid var(--brand); outline-offset: -1px; }
/* Partial / under-loaded month in the strip — amber hatched bar so it reads as
   "incomplete" even before hovering the tooltip. */
.rai-delivery .tf-month.partial .bar {
  background: repeating-linear-gradient(45deg, var(--warning) 0 2px, transparent 2px 5px) !important;
  box-shadow: none !important;
  opacity: .9;
}
.rai-delivery .tf-month.partial.in-range .bar { opacity: 1; }
.rai-delivery .tf-month.partial .lab { color: var(--warning); }

/* Partial-month alert banner (shown above filtered pages by init.rerender). */
.rai-delivery .dlv-partial-banner {
  display: flex; gap: 10px; align-items: flex-start;
  margin: 0 0 16px; padding: 11px 13px;
  border: 1px solid color-mix(in oklch, var(--warning) 42%, var(--border-default));
  background: var(--warning-bg);
  border-radius: var(--radius-md);
}
.rai-delivery .dlv-partial-banner .dpb-ic { color: var(--warning); flex: 0 0 auto; display: flex; margin-top: 1px; }
.rai-delivery .dlv-partial-banner .dpb-title { font: 600 12.5px var(--font-ui); color: var(--fg-1); }
.rai-delivery .dlv-partial-banner .dpb-sub { font: 400 11.5px var(--font-ui); color: var(--fg-3); margin-top: 2px; line-height: 1.45; }
.rai-delivery .dlv-partial-banner strong { color: var(--fg-1); font-weight: 700; }
.rai-delivery .dlv-partial-banner .dpb-sub strong { color: var(--fg-2); font-weight: 600; }
.rai-delivery .dot-matrix { display: grid; grid-template-columns: repeat(53, 1fr); gap: 2px; }
.rai-delivery .dot-cell { aspect-ratio: 1; border-radius: 2px; background: var(--surface-2); }
.rai-delivery .dot-cell.l1 { background: rgba(251,95,44,.18); }
.rai-delivery .dot-cell.l2 { background: rgba(251,95,44,.38); }
.rai-delivery .dot-cell.l3 { background: rgba(251,95,44,.62); }
.rai-delivery .dot-cell.l4 { background: rgba(251,95,44,.95); }
.rai-delivery .statusdot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; flex-shrink: 0; }
.rai-delivery .statusdot.live { background: #4FB477; box-shadow: 0 0 8px #4FB477; }
.rai-delivery .statusdot.warn { background: #F4A93A; box-shadow: 0 0 8px rgba(244,169,58,.6); }
.rai-delivery .statusdot.crit { background: #F26B5C; box-shadow: 0 0 8px rgba(242,107,92,.6); }
.rai-delivery .statusdot.idle { background: var(--ink-400); }
.rai-delivery .log-feed { display: flex; flex-direction: column; gap: 0; }
.rai-delivery .log-row {
  display: grid;
  grid-template-columns: 64px 100px 22px 1fr auto;
  gap: 12px;
  padding: 9px 20px;
  align-items: center;
  border-bottom: 1px solid var(--divider);
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--fg-2);
}
.rai-delivery .log-row:last-child { border-bottom: none; }
.rai-delivery .log-row:hover { background: var(--surface-2); }
.rai-delivery .log-row .ts { color: var(--fg-muted); font-variant-numeric: tabular-nums; }
.rai-delivery .log-row .src { color: var(--brand); font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rai-delivery .log-row .msg { color: var(--fg-1); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-family: var(--font-ui); font-size: 12.5px; }
.rai-delivery .log-row .meta { color: var(--fg-muted); font-size: 10.5px; }
.rai-delivery .bdown-row { display: flex; flex-direction: column; gap: 6px; padding: 12px 0; border-bottom: 1px solid var(--divider); }
.rai-delivery .bdown-row:last-child { border-bottom: none; }
.rai-delivery .bdown-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; font-size: 13px; }
.rai-delivery .bdown-head .name { color: var(--fg-1); font-weight: 500; display: flex; align-items: center; gap: 8px; }
.rai-delivery .bdown-head .vals { font-family: var(--font-mono); font-variant-numeric: tabular-nums; color: var(--fg-3); font-size: 12px; }
.rai-delivery .bdown-head .vals .v { color: var(--fg-1); font-weight: 500; }
.rai-delivery .bdown-bar { height: 6px; background: var(--surface-3); border-radius: 999px; overflow: hidden; position: relative; }
.rai-delivery .bdown-fill { height: 100%; border-radius: 999px; transition: width var(--dur-base) var(--ease-out); }
.rai-delivery .source-pill {
  display: inline-flex; align-items: center; gap: 6px;
  font: 500 11px var(--font-ui);
  padding: 3px 8px 3px 6px;
  background: var(--surface-2);
  border: 1px solid var(--border-subtle);
  border-radius: 999px;
  color: var(--fg-2);
}
.rai-delivery .source-pill .ico { width: 14px; height: 14px; border-radius: 4px; display: flex; align-items: center; justify-content: center; font: 700 8px var(--font-ui); color: white; }
.rai-delivery .source-pill .ico.g { background: #4285F4; }
.rai-delivery .source-pill .ico.y { background: #D32323; }
.rai-delivery .source-pill .ico.t { background: #00B27A; }
.rai-delivery .source-pill .ico.f { background: #1877F2; }
.rai-delivery .star-row { display: grid; grid-template-columns: 36px 1fr 50px; align-items: center; gap: 10px; padding: 5px 0; }
.rai-delivery .star-row .star-lbl { font: 600 11px var(--font-mono); color: var(--fg-3); display: flex; align-items: center; gap: 3px; }
.rai-delivery .star-row .star-bar { height: 8px; background: var(--surface-3); border-radius: 999px; overflow: hidden; }
.rai-delivery .star-row .star-fill { height: 100%; border-radius: 999px; }
.rai-delivery .star-row .star-fill.s5 { background: #4FB477; }
.rai-delivery .star-row .star-fill.s4 { background: #92C580; }
.rai-delivery .star-row .star-fill.s3 { background: #F4A93A; }
.rai-delivery .star-row .star-fill.s2 { background: #ED8845; }
.rai-delivery .star-row .star-fill.s1 { background: #F26B5C; }
.rai-delivery .star-row .star-num { font: 600 11px var(--font-mono); color: var(--fg-1); font-variant-numeric: tabular-nums; text-align: right; }
.rai-delivery .sec-h {
  display: flex; align-items: baseline; justify-content: space-between; gap: 14px;
  margin: 26px 0 12px;
}
.rai-delivery .sec-h h2 {
  font-family: var(--font-ui);
  font-weight: 600;
  letter-spacing: -.014em;
  font-size: 20px;
  letter-spacing: -.015em;
  color: var(--fg-1);
  margin: 0;
}
.rai-delivery .sec-h .h-meta { font: 500 11px var(--font-mono); color: var(--fg-3); text-transform: uppercase; letter-spacing: .08em; }
.rai-delivery .loc-card {
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  padding: 14px;
  display: flex; flex-direction: column; gap: 10px;
  transition: all var(--dur-fast) var(--ease-out);
  cursor: pointer;
}
.rai-delivery .loc-card:hover { border-color: var(--border-strong); transform: translateY(-1px); }
.rai-delivery .loc-card .name { font: 600 13px var(--font-ui); color: var(--fg-1); display: flex; align-items: center; gap: 8px; }
.rai-delivery .loc-card .addr { font: 400 11px var(--font-ui); color: var(--fg-3); }
.rai-delivery .loc-card .row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding-top: 8px; border-top: 1px solid var(--divider); }
.rai-delivery .loc-card .row .k { font: 600 9px var(--font-ui); text-transform: uppercase; letter-spacing: .08em; color: var(--fg-3); margin-bottom: 2px; }
.rai-delivery .loc-card .row .v { font: 500 14px var(--font-mono); color: var(--fg-1); font-variant-numeric: tabular-nums; }
.rai-delivery .rank {
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px;
  background: var(--surface-3); color: var(--fg-2);
  border-radius: 6px;
  font: 700 10px var(--font-mono);
}
.rai-delivery .rank.gold { background: linear-gradient(135deg, #F4A93A, #DC8E1C); color: #1a1612; }
.rai-delivery .rank.silver { background: linear-gradient(135deg, #BAAA94, #998973); color: #1a1612; }
.rai-delivery .rank.bronze { background: linear-gradient(135deg, #B97A4A, #9E6D40); color: #1a1612; }
.rai-delivery .g-12 { display: grid; grid-template-columns: repeat(12, 1fr); gap: 14px; }
.rai-delivery .col-8 { grid-column: span 8; }
.rai-delivery .col-7 { grid-column: span 7; }
.rai-delivery .col-6 { grid-column: span 6; }
.rai-delivery .col-5 { grid-column: span 5; }
.rai-delivery .col-4 { grid-column: span 4; }
.rai-delivery .col-3 { grid-column: span 3; }

/* ===== extensions.css (scoped) ===== */
.rai-delivery .sidebar-client {
  padding: 8px 10px;
  align-items: center;
  gap: 10px;
}
.rai-delivery .sidebar-client .client-mark {
  width: 24px; height: 24px;
  border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
  font: 700 11px var(--font-ui);
  flex-shrink: 0;
}
.rai-delivery .sidebar-client .client-meta {
  display: flex; flex-direction: column; gap: 1px;
  flex: 1; min-width: 0;
  overflow: hidden;
}
.rai-delivery .sidebar-client .client-meta .cn {
  font: 500 12.5px var(--font-ui);
  color: var(--fg-1);
  white-space: nowrap; text-overflow: ellipsis; overflow: hidden;
}
.rai-delivery .sidebar-client .client-meta .cs {
  font: 400 10px var(--font-mono);
  color: var(--fg-3);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .sidebar-client .client-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
  opacity: 0.85;
}
.rai-delivery .sidebar-footer-meta {
  margin-top: auto;
  padding: 10px 12px 4px;
  border-top: 1px solid var(--divider);
  display: flex; align-items: center; gap: 8px;
  font: 500 10.5px var(--font-mono);
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: .05em;
}
.rai-delivery .sidebar-footer-meta svg { color: var(--success); width: 12px; height: 12px; }
.rai-delivery .page-head h1 {
  text-wrap: balance;
  max-width: 920px;
}
.rai-delivery .kpi .lbl .dot { width: 7px; height: 7px; border-radius: 2px; }
.rai-delivery .margin-spread { display: flex; flex-direction: column; gap: 14px; padding-bottom: 6px; }
.rai-delivery .margin-spread .ms-rail {
  position: relative;
  height: 6px; border-radius: 999px;
  background: var(--surface-3);
  margin-bottom: 6px;
}
.rai-delivery .margin-spread .ms-band {
  position: absolute; top: 0; bottom: 0;
  border-radius: 999px;
}
.rai-delivery .margin-spread .ms-band.ok { background: rgba(79,180,119,.16); }
.rai-delivery .margin-spread .ms-band.warn { background: rgba(244,169,58,.16); }
.rai-delivery .margin-spread .ms-band.crit { background: rgba(242,107,92,.16); }
.rai-delivery .margin-spread .ms-tick {
  position: absolute; top: 100%;
  width: 1px; height: 6px;
  background: var(--border-default);
  margin-left: -0.5px;
  margin-top: 2px;
}
.rai-delivery .margin-spread .ms-tick span {
  position: absolute; left: 50%; top: 8px;
  transform: translateX(-50%);
  font: 500 9.5px var(--font-mono);
  color: var(--fg-muted);
}
.rai-delivery .margin-spread .ms-row { display: grid; grid-template-columns: 110px 1fr; gap: 12px; align-items: center; }
.rai-delivery .margin-spread .ms-label { font: 500 12px var(--font-ui); color: var(--fg-1); white-space: nowrap; text-overflow: ellipsis; overflow: hidden; }
.rai-delivery .margin-spread .ms-track {
  position: relative;
  height: 22px;
}
.rai-delivery .margin-spread .ms-line {
  position: absolute; top: 50%; left: 0; right: 0;
  height: 1px; background: var(--divider);
  transform: translateY(-50%);
}
.rai-delivery .margin-spread .ms-dot {
  position: absolute; top: 50%;
  width: 11px; height: 11px;
  border-radius: 50%;
  transform: translate(-50%, -50%);
}
.rai-delivery .margin-spread .ms-value {
  position: absolute; top: 50%;
  transform: translate(-50%, calc(-50% - 14px));
  font: 600 11px var(--font-mono);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.rai-delivery .margin-foot {
  border-top: 1px solid var(--divider);
  margin-top: 18px; padding-top: 12px;
  display: flex; flex-direction: column; gap: 6px;
  font: 500 11px var(--font-ui);
  color: var(--fg-3);
}
.rai-delivery .margin-foot .mf-row { display: flex; align-items: center; gap: 8px; }
.rai-delivery .margin-foot .mf-band {
  width: 12px; height: 8px; border-radius: 3px;
}
.rai-delivery .margin-foot .mf-band.ok { background: rgba(79,180,119,.5); }
.rai-delivery .margin-foot .mf-band.warn { background: rgba(244,169,58,.5); }
.rai-delivery .margin-foot .mf-band.crit { background: rgba(242,107,92,.5); }
.rai-delivery .hmx {
  display: grid;
  grid-template-columns: 230px repeat(4, 1fr) 110px 90px;
  font-size: 12px;
}
.rai-delivery .hmx-row {
  display: contents;
}
.rai-delivery .hmx-row > .hmx-cell:first-child { border-left: 0; }
.rai-delivery .hmx-cell {
  padding: 12px 8px;
  border-top: 1px solid var(--divider);
  display: flex; align-items: center; justify-content: center;
  color: var(--fg-2);
}
.rai-delivery .hmx-row.hmx-head .hmx-cell {
  border-top: 0;
  font: 600 9.5px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--fg-3);
  padding: 4px 8px 14px;
  gap: 4px;
}
/* Header label for a signal we don't have data for yet — dimmed so the grey
   "no data" dots below read as intentional, not broken. */
.rai-delivery .hmx-row.hmx-head .hmx-cell.nd { opacity: .5; }
.rai-delivery .hmx-cell.client {
  justify-content: flex-start;
  gap: 10px;
  padding-left: 4px;
  padding-right: 8px;
}
.rai-delivery .hmx-cell.num {
  justify-content: flex-end;
  font: 500 12.5px var(--font-mono);
  color: var(--fg-1);
  font-variant-numeric: tabular-nums;
  padding-right: 4px;
}
.rai-delivery .hmx-cell .client-mark {
  width: 26px; height: 26px;
  border-radius: 7px;
  display: flex; align-items: center; justify-content: center;
  font: 700 12px var(--font-ui);
  flex-shrink: 0;
}
.rai-delivery .hmx-pending {
  display: inline-block;
  width: 18px; height: 2px; border-radius: 2px;
  background: var(--ink-300);
  position: relative;
}
.rai-delivery .hmx-pending::after {
  content: ""; position: absolute; top: -1.5px; left: 0;
  width: 5px; height: 5px; border-radius: 50%;
  background: var(--ink-400);
  box-shadow: 8px 0 0 var(--ink-400);
}
.rai-delivery .hmx-pending-tag {
  display: inline-block;
  font: 500 8.5px var(--font-mono);
  color: var(--fg-muted);
  text-transform: lowercase;
  letter-spacing: .02em;
  padding: 1px 5px;
  background: var(--surface-3);
  border-radius: 4px;
}
.rai-delivery .ai-strip {
  background:
    radial-gradient(800px 200px at 12% 0%, rgba(251,95,44,.10) 0%, transparent 60%),
    var(--surface-1);
  border: 1px solid var(--border-default);
}
.rai-delivery .ai-strip-head {
  padding: 18px 22px 8px;
  display: flex; align-items: center; justify-content: space-between;
  gap: 14px;
}
.rai-delivery .ai-strip-icon {
  width: 40px; height: 40px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--brand) 0%, #B33B14 100%);
  display: flex; align-items: center; justify-content: center;
  color: white;
  box-shadow: 0 8px 20px -8px rgba(251,95,44,.55), inset 0 1px 0 rgba(255,255,255,.18);
}
.rai-delivery .ai-strip-body { padding: 6px 22px 22px; }
.rai-delivery .ai-strip-prompt {
  display: flex; align-items: center; gap: 10px;
  background: var(--surface-page);
  border: 1px solid var(--border-default);
  border-radius: 10px;
  padding: 11px 14px;
  margin-bottom: 12px;
}
.rai-delivery .ai-strip-prompt:focus-within { border-color: var(--brand); }
.rai-delivery .ai-strip-prompt svg { color: var(--brand); }
.rai-delivery .ai-strip-prompt input {
  flex: 1; background: transparent; border: 0; outline: 0;
  color: var(--fg-1);
  font: 500 13.5px var(--font-ui);
}
.rai-delivery .ai-strip-prompt input::placeholder { color: var(--fg-3); }
.rai-delivery .ai-strip-prompt kbd {
  font: 500 10px var(--font-mono);
  color: var(--fg-3);
  background: var(--surface-2);
  padding: 2px 7px;
  border-radius: 5px;
  border: 1px solid var(--border-subtle);
}
.rai-delivery .ai-strip-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.rai-delivery .ai-chip {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--surface-2);
  border: 1px solid var(--border-subtle);
  color: var(--fg-2);
  font: 500 12px var(--font-ui);
  padding: 6px 11px 6px 10px;
  border-radius: 999px;
  cursor: pointer;
  transition: all var(--dur-fast) var(--ease-out);
}
.rai-delivery .ai-chip:hover {
  background: var(--brand-soft);
  border-color: rgba(251,95,44,.3);
  color: var(--brand);
}
.rai-delivery .ai-chip svg { color: var(--fg-muted); }
.rai-delivery .ai-chip:hover svg { color: var(--brand); }
.rai-delivery .placeholder-card { margin-top: 14px; }
.rai-delivery .planned-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}
@media (max-width: 1100px) {
.rai-delivery .planned-grid { grid-template-columns: 1fr; }
}
.rai-delivery .planned-section {
  display: grid;
  grid-template-columns: 36px 1fr;
  gap: 14px;
  padding: 16px 18px;
  background: var(--surface-page);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  transition: border-color var(--dur-fast) var(--ease-out);
}
.rai-delivery .planned-section:hover { border-color: var(--border-default); }
.rai-delivery .planned-section .ps-num {
  font: 600 11px var(--font-mono);
  color: var(--brand);
  background: var(--brand-soft);
  border-radius: 6px;
  width: 32px; height: 32px;
  display: flex; align-items: center; justify-content: center;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .planned-section .ps-body { min-width: 0; }
.rai-delivery .planned-section .ps-title {
  font: 600 13.5px var(--font-ui);
  color: var(--fg-1);
  margin-bottom: 4px;
}
.rai-delivery .planned-section .ps-desc {
  font: 400 12px var(--font-ui);
  color: var(--fg-3);
  line-height: 1.5;
}
.rai-delivery .planned-section .ps-metrics {
  display: flex; flex-wrap: wrap; gap: 5px;
  margin-top: 10px;
}
.rai-delivery .planned-section .ps-metric {
  font: 500 10.5px var(--font-mono);
  color: var(--fg-2);
  background: var(--surface-2);
  border: 1px solid var(--border-subtle);
  padding: 2px 8px;
  border-radius: 999px;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .planned-section .ps-status {
  display: inline-flex; align-items: center; gap: 6px;
  margin-top: 10px;
  font: 600 10.5px var(--font-mono);
  text-transform: uppercase;
  letter-spacing: .05em;
}
.rai-delivery .planned-section .ps-status.live { color: var(--success); }
.rai-delivery .planned-section .ps-status.pending { color: var(--fg-muted); }
.rai-delivery .cust-table {
  display: grid;
  grid-template-columns: 1.8fr 100px 100px 90px 110px 110px 100px 70px;
  width: 100%;
}
.rai-delivery .cust-row {
  display: contents;
}
.rai-delivery .cust-row > div {
  padding: 14px 14px;
  border-top: 1px solid var(--divider);
  display: flex; align-items: center;
  font: 400 12.5px var(--font-ui);
  color: var(--fg-2);
}
.rai-delivery .cust-row > div.num {
  justify-content: flex-end;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  color: var(--fg-1);
}
.rai-delivery .cust-row.cust-head > div {
  border-top: 0;
  border-bottom: 1px solid var(--divider);
  background: var(--surface-page);
  font: 600 10px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--fg-3);
  padding-top: 12px; padding-bottom: 12px;
}
.rai-delivery .cust-row:not(.cust-head):hover > div { background: var(--surface-2); }
.rai-delivery .tf-compare-wrap { position: relative; }
.rai-delivery .tf-compare-pop {
  position: absolute; top: calc(100% + 6px); right: 0;
  min-width: 220px;
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 10px;
  box-shadow: 0 14px 36px rgba(0,0,0,.34), 0 2px 8px rgba(0,0,0,.2);
  padding: 4px;
  z-index: 80;
  display: flex; flex-direction: column;
}
.rai-delivery .tf-cmp-opt {
  display: flex; align-items: center; gap: 8px;
  width: 100%; padding: 7px 10px;
  background: transparent; border: 0;
  font: 500 12px var(--font-ui);
  color: var(--fg-2);
  border-radius: 6px;
  cursor: pointer; text-align: left;
}
.rai-delivery .tf-cmp-opt:hover { background: var(--surface-2); color: var(--fg-1); }
.rai-delivery .tf-cmp-opt.on { color: var(--brand); }
.rai-delivery .tf-cmp-opt svg { opacity: 0.5; }
.rai-delivery .tf-cmp-opt.on svg { opacity: 1; color: var(--brand); }
.rai-delivery .tf-custom-note {
  font: 400 10.5px var(--font-ui);
  color: var(--fg-muted);
  padding: 4px 2px 0;
  font-style: italic;
}
.rai-delivery .client-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 0;
}
.rai-delivery .client-chip-btn {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  color: var(--fg-2);
  font: 500 12px var(--font-ui);
  padding: 7px 12px 7px 11px;
  border-radius: 999px;
  cursor: pointer;
  transition: all var(--dur-fast) var(--ease-out);
}
.rai-delivery .client-chip-btn:hover { background: var(--surface-2); color: var(--fg-1); }
.rai-delivery .client-chip-btn.on {
  background: var(--brand-soft);
  border-color: rgba(251,95,44,.3);
  color: var(--brand);
}
.rai-delivery .client-chip-btn .cc-dot { width: 8px; height: 8px; border-radius: 2px; flex-shrink: 0; }
.rai-delivery .client-chip-btn .cc-num {
  font: 600 10px var(--font-mono);
  font-variant-numeric: tabular-nums;
  color: var(--fg-3);
  background: var(--surface-2);
  padding: 1px 6px;
  border-radius: 999px;
}
.rai-delivery .client-chip-btn.on .cc-num { background: var(--brand); color: var(--fg-onbrand); }
.rai-delivery .rsec-snapshot {
  background: linear-gradient(135deg, rgba(108,169,242,.04) 0%, var(--surface-1) 60%);
}
.rai-delivery .rcs-heroes {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: 18px;
}
.rai-delivery .rcs-hero {
  padding: 16px 18px;
  background: var(--surface-page);
  border-right: 1px solid var(--divider);
  display: flex; flex-direction: column; gap: 3px;
}
.rai-delivery .rcs-hero:last-child { border-right: 0; }
.rai-delivery .rcs-lbl {
  font: 700 9.5px var(--font-mono);
  letter-spacing: .14em;
}
.rai-delivery .rcs-val {
  font: 600 28px var(--font-mono);
  color: var(--fg-1);
  letter-spacing: -.022em;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rcs-delta {
  font: 600 11px var(--font-mono);
  font-variant-numeric: tabular-nums;
  margin-top: 2px;
}
.rai-delivery .rcs-delta.up { color: var(--success); }
.rai-delivery .rcs-delta.down { color: var(--danger); }
.rai-delivery .rcs-rank {
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--surface-page);
  margin-bottom: 14px;
}
.rai-delivery .rcs-rank-head {
  padding: 11px 14px;
  background: var(--surface-1);
  border-bottom: 1px solid var(--divider);
  font: 700 9.5px var(--font-mono);
  letter-spacing: .14em;
  color: var(--fg-3);
}
.rai-delivery .rcs-rank-grid {
  display: grid;
}
.rai-delivery .rcs-rank-row {
  display: grid;
  grid-template-columns: 1.6fr 80px 70px 80px 70px 90px 80px 130px;
  align-items: center;
  border-bottom: 1px solid var(--divider);
}
.rai-delivery .rcs-rank-row:last-child { border-bottom: 0; }
.rai-delivery .rcs-rank-row > div {
  padding: 10px 12px;
  font: 500 12px var(--font-ui);
  color: var(--fg-1);
}
.rai-delivery .rcs-rank-row > div.num {
  text-align: right;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  justify-self: stretch;
}
.rai-delivery .rcs-rank-row.rcs-rank-head-row > div {
  background: var(--surface-1);
  font: 700 9.5px var(--font-mono);
  letter-spacing: .1em;
  color: var(--fg-muted);
}
.rai-delivery .rcs-rank-name { display: flex; align-items: center; gap: 10px; }
.rai-delivery .rcs-rank-pos {
  font: 700 11px var(--font-mono);
  color: var(--fg-muted);
  font-variant-numeric: tabular-nums;
  background: var(--surface-2);
  width: 24px; height: 24px;
  border-radius: 5px;
  display: inline-flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.rai-delivery .rcs-rl-name { font: 600 13px var(--font-ui); color: var(--fg-1); }
.rai-delivery .rcs-rl-city { font: 400 10.5px var(--font-mono); color: var(--fg-3); font-variant-numeric: tabular-nums; }
.rai-delivery .rcs-badge {
  font: 700 9px var(--font-mono);
  letter-spacing: .08em;
  padding: 2px 8px;
  border-radius: 999px;
  white-space: nowrap;
}
.rai-delivery .rcs-badge.best { background: var(--success-bg); color: var(--success); }
.rai-delivery .rcs-badge.watch { background: var(--warning-bg); color: var(--warning); }
.rai-delivery .rcs-callouts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.rai-delivery .rcs-callout {
  display: flex; gap: 12px;
  padding: 14px 16px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-default);
}
.rai-delivery .rcs-callout svg { flex-shrink: 0; margin-top: 4px; }
.rai-delivery .rcs-callout.rcs-best { background: var(--success-bg); border-color: rgba(79,180,119,.3); }
.rai-delivery .rcs-callout.rcs-best svg { color: var(--success); }
.rai-delivery .rcs-callout.rcs-watch { background: var(--warning-bg); border-color: rgba(244,169,58,.3); }
.rai-delivery .rcs-callout.rcs-watch svg { color: var(--warning); }
.rai-delivery .rcsc-head {
  font: 700 9.5px var(--font-mono);
  letter-spacing: .12em;
  color: var(--fg-muted);
}
.rai-delivery .rcsc-name {
  font: 600 18px var(--font-ui);
  color: var(--fg-1);
  margin: 4px 0 6px;
}
.rai-delivery .rcsc-text {
  font: 400 12px var(--font-ui);
  color: var(--fg-2);
  line-height: 1.55;
}
.rai-delivery .rsec-loc-divider {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 20px;
  align-items: center;
  padding: 22px 22px 22px 28px;
  background: var(--ink-50);
  border: 1px solid var(--border-default);
  border-radius: 12px;
  position: relative;
  overflow: hidden;
}
.rai-delivery .rsec-loc-divider::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 4px;
  background: var(--brand);
}
.rai-delivery .rlocdv-num {
  font: 700 36px var(--font-mono);
  color: var(--brand);
  letter-spacing: -.04em;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.rai-delivery .rlocdv-eyebrow {
  font: 700 10px var(--font-mono);
  letter-spacing: .14em;
  color: var(--fg-3);
  margin-bottom: 4px;
}
.rai-delivery .rlocdv-name {
  font: 600 34px var(--font-ui);
  font-style: italic;
  color: var(--fg-1);
  letter-spacing: -.024em;
  margin: 0;
  line-height: 1.05;
}
.rai-delivery .rlocdv-city {
  font: 500 12px var(--font-mono);
  color: var(--fg-3);
  font-variant-numeric: tabular-nums;
  margin-top: 4px;
}
.rai-delivery .rlocdv-line {
  position: absolute;
  bottom: 0; left: 28px; right: 28px;
  height: 0;
  border-top: 1px dashed var(--border-default);
}
.rai-delivery .rpresent {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: var(--ink-50);
  display: flex; flex-direction: column;
  animation: rpres-in 200ms cubic-bezier(.2,.8,.2,1);
}
@keyframes rpres-in {
  from { opacity: 0; transform: scale(0.98); }
  to   { opacity: 1; transform: scale(1); }
}
.rai-delivery .rpres-topbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 26px;
  background: var(--surface-page);
  border-bottom: 1px solid var(--border-default);
  flex-shrink: 0;
}
.rai-delivery .rpres-brand { display: flex; align-items: center; gap: 12px; }
.rai-delivery .rpres-brand img {
  width: 32px; height: 32px;
  border-radius: 7px;
  object-fit: cover;
}
.rai-delivery .rpres-cli {
  font: 600 14px var(--font-ui);
  color: var(--fg-1);
  letter-spacing: -.005em;
}
.rai-delivery .rpres-period {
  font: 500 11px var(--font-mono);
  color: var(--fg-3);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rpres-exit {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  color: var(--fg-2);
  font: 500 12px var(--font-ui);
  padding: 7px 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: all var(--dur-fast) var(--ease-out);
}
.rai-delivery .rpres-exit:hover { background: var(--surface-2); color: var(--fg-1); }
.rai-delivery .rpres-exit kbd {
  font: 600 9.5px var(--font-mono);
  background: var(--surface-3);
  color: var(--fg-3);
  padding: 1px 6px;
  border-radius: 4px;
  border: 1px solid var(--border-subtle);
}
.rai-delivery .rpres-stage {
  flex: 1; min-height: 0;
  overflow-y: auto;
  padding: 40px 60px;
  display: flex; align-items: flex-start; justify-content: center;
}
.rai-delivery .rpres-slide {
  width: 100%;
  max-width: 1100px;
  
}
.rai-delivery .rpres-slide .rsec {
  padding: 56px 64px;
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 16px;
  box-shadow: 0 24px 60px rgba(0,0,0,.32), 0 2px 8px rgba(0,0,0,.18);
}
.rai-delivery .rpres-slide .rsec-title {
  font-size: 30px;
}
.rai-delivery .rpres-slide .rsec-lead {
  font-size: 16px;
  max-width: 100%;
}
.rai-delivery .rpres-slide .ch-val, .rai-delivery .rpres-slide .rp-val, .rai-delivery .rpres-slide .reh-val, .rai-delivery .rpres-slide .rcs-val {
  font-size: 52px;
}
.rai-delivery .rpres-slide .cov2-name { font-size: 88px; }
.rai-delivery .rpres-slide .rlocdv-name { font-size: 64px; }
.rai-delivery .rpres-slide .rlocdv-num { font-size: 56px; }
.rai-delivery .rpres-slide .rwi-imp-val { font-size: 60px; }
.rai-delivery .rpres-slide .rsec-loc-divider { padding: 64px 72px; }
.rai-delivery .rpres-controls {
  display: flex; align-items: center; gap: 18px;
  padding: 14px 26px;
  background: var(--surface-page);
  border-top: 1px solid var(--border-default);
  justify-content: center;
  flex-shrink: 0;
}
.rai-delivery .rpres-nav {
  width: 38px; height: 38px;
  border-radius: 10px;
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  color: var(--fg-2);
  display: inline-flex; align-items: center; justify-content: center;
  cursor: pointer;
  transition: all var(--dur-fast) var(--ease-out);
}
.rai-delivery .rpres-nav:hover:not(:disabled) {
  background: var(--brand);
  border-color: var(--brand);
  color: var(--fg-onbrand);
}
.rai-delivery .rpres-nav:disabled { opacity: 0.3; cursor: not-allowed; }
.rai-delivery .rpres-counter {
  display: flex; align-items: baseline; gap: 4px;
  font: 600 14px var(--font-mono);
  color: var(--fg-2);
  font-variant-numeric: tabular-nums;
  min-width: 60px; justify-content: center;
}
.rai-delivery .rpres-cur { color: var(--brand); font-size: 18px; }
.rai-delivery .rpres-sep { color: var(--fg-muted); }
.rai-delivery .rpres-total { color: var(--fg-3); }
.rai-delivery .rpres-progress {
  display: flex; gap: 4px;
  flex-wrap: wrap;
  max-width: 480px;
  justify-content: center;
}
.rai-delivery .rpres-dot {
  width: 24px; height: 5px;
  background: var(--surface-3);
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  transition: all var(--dur-fast) var(--ease-out);
  padding: 0;
}
.rai-delivery .rpres-dot:hover { background: var(--ink-400); }
.rai-delivery .rpres-dot.on { background: var(--brand); }
.rai-delivery .rpres-dot.is-loc { background: var(--surface-2); border-top: 2px solid var(--ink-400); border-radius: 0; }
.rai-delivery .rpres-dot.is-loc.on { background: var(--brand); border-color: var(--brand-press); }
.rai-delivery .sidebar-resty-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  margin-left: -1px;
}
.resty-mark {
  display: inline-block;
  position: relative;
  flex-shrink: 0;
}
.resty-mark svg {
  display: block;
  transition: transform 220ms cubic-bezier(.2,.8,.2,1);
}
.resty-mark:hover svg { transform: translateY(-2px); }
.resty-mark:hover .resty-eyes { transform: translateY(-0.3px); }
.resty-mark .resty-body {
  transform-origin: center;
  animation: resty-breathe 4.5s ease-in-out infinite;
}
@keyframes resty-breathe {
  0%, 100% { transform: scale(1); }
  50%      { transform: scale(1.025); }
}
.resty-mark .resty-eyes {
  transform-origin: center;
  animation: resty-blink-eyes 5s ease-in-out infinite;
}
@keyframes resty-blink-eyes {
  0%, 92%, 100% { transform: scaleY(1); }
  94%, 98%      { transform: scaleY(0.08); }
}
.resty-mark .resty-pupil {
  transform-origin: center;
  animation: resty-glance 6.4s ease-in-out infinite;
}
@keyframes resty-glance {
  0%, 18%, 100% { transform: translateX(0); }
  22%, 40%      { transform: translateX(1px); }
  44%, 62%      { transform: translateX(0); }
  66%, 84%      { transform: translateX(-1px); }
  88%           { transform: translateX(0); }
}
.resty-mark .resty-mouth {
  transform-origin: 16px 22px;
  animation: resty-mouth 7s ease-in-out infinite;
}
@keyframes resty-mouth {
  0%, 100% { transform: scaleY(1); }
  50%      { transform: scaleY(0.85); }
}
.resty-mark .resty-breath {
  transform-origin: center;
  animation: resty-breath-glow 4.5s ease-in-out infinite;
}
@keyframes resty-breath-glow {
  0%, 100% { transform: scale(0.97); opacity: 0; }
  50%      { transform: scale(1.10); opacity: 0.25; }
}
.resty-mark .resty-ai-dot {
  transform-origin: 27px 27px;
  animation: resty-ai-pulse 2.4s ease-in-out infinite;
}
@keyframes resty-ai-pulse {
  0%, 100% { transform: scale(1);   opacity: 0;   }
  50%      { transform: scale(2.0); opacity: 0.35; }
}
.resty-mark .resty-hat {
  transform-origin: 16px 8px;
  animation: resty-hat-idle 6.8s ease-in-out infinite;
}
@keyframes resty-hat-idle {
  0%, 100% { transform: rotate(-0.6deg) translateY(0); }
  50%      { transform: rotate(0.6deg)  translateY(-0.4px); }
}
.resty-mark .resty-flame {
  transform-origin: 16px 30px;
  animation: resty-flame-flicker 0.6s ease-in-out infinite alternate;
}
.resty-mark .resty-flame-outer {
  animation: resty-flame-outer 0.8s ease-in-out infinite alternate;
  transform-origin: 16px 30px;
}
.resty-mark .resty-flame-inner {
  animation: resty-flame-inner 0.45s ease-in-out infinite alternate;
  transform-origin: 16px 30px;
}
.resty-mark .resty-flame-spark {
  animation: resty-spark 1.4s ease-out infinite;
}
@keyframes resty-flame-flicker {
  0%   { transform: scaleY(0.95) scaleX(0.98); }
  100% { transform: scaleY(1.08) scaleX(1.02); }
}
@keyframes resty-flame-outer {
  0%   { transform: scaleY(0.9)  translateY(0); opacity: 0.92; }
  100% { transform: scaleY(1.12) translateY(0.5px); opacity: 1; }
}
@keyframes resty-flame-inner {
  0%   { transform: scaleY(0.85); opacity: 0.85; }
  100% { transform: scaleY(1.18); opacity: 1; }
}
@keyframes resty-spark {
  0%   { transform: translateY(0)   scale(1);   opacity: 0; }
  25%  { transform: translateY(0)   scale(1.1); opacity: 1; }
  100% { transform: translateY(-6px) scale(0.2); opacity: 0; }
}
.resty-mark .resty-fins {
  transform-origin: 16px 24px;
}
.resty-mark.is-thinking .resty-body { animation-duration: 1.6s; }
.resty-mark.is-thinking .resty-hat { animation: resty-hat-thinking 0.9s ease-in-out infinite; }
.resty-mark.is-thinking .resty-flame { animation-duration: 0.35s; }
.resty-mark.is-thinking .resty-flame-outer { animation-duration: 0.4s; }
.resty-mark.is-thinking .resty-flame-inner { animation-duration: 0.22s; }
@keyframes resty-hat-thinking {
  0%, 100% { transform: rotate(-2deg) translateY(0); }
  50%      { transform: rotate(2deg)  translateY(-0.8px); }
}
.resty-mark.is-thinking .resty-eyes {
  animation: resty-thinking-eyes 1.2s ease-in-out infinite;
}
@keyframes resty-thinking-eyes {
  0%, 100% { transform: scaleY(0.5); }
  50%      { transform: scaleY(0.85); }
}
.resty-mark.is-thinking .resty-pupil {
  animation: resty-thinking-pupils 1s linear infinite;
}
@keyframes resty-thinking-pupils {
  0%   { transform: translate(0, 0); }
  25%  { transform: translate(0.8px, -0.4px); }
  50%  { transform: translate(0, 0.4px); }
  75%  { transform: translate(-0.8px, -0.4px); }
  100% { transform: translate(0, 0); }
}
.resty-mark.is-thinking .resty-mouth {
  animation: resty-thinking-mouth 1.8s ease-in-out infinite;
}
@keyframes resty-thinking-mouth {
  0%, 100% { transform: scaleX(1); opacity: 0.95; }
  50%      { transform: scaleX(0.3); opacity: 0.7; }
}
.resty-mark.v-hero svg { filter: drop-shadow(0 14px 28px rgba(251,95,44,.42)); }
.rai-delivery .ac-empty-mark {
  width: auto !important;
  height: auto !important;
  background: transparent !important;
  border-radius: 0 !important;
  box-shadow: none !important;
}
.rai-delivery .ac-empty-head h2 em {
  font-style: italic;
  color: var(--brand);
  font-weight: 600;
}
.rai-delivery .ac-msg-avatar.resty-avatar {
  background: transparent !important;
  width: 32px;
  height: 32px;
  padding: 0;
}
.rai-delivery .agent-rail .ar-title {
  font-weight: 700;
  letter-spacing: -.01em;
}
.rai-delivery .agent-shell {
  display: grid;
  grid-template-columns: 280px 1fr 340px;
  height: 100%;
  margin: 0;
}
.rai-delivery .agent-shell.memory-hidden {
  grid-template-columns: 280px 1fr;
}
@media (max-width: 1280px) {
.rai-delivery .agent-shell { grid-template-columns: 240px 1fr 300px; }
.rai-delivery .agent-shell.memory-hidden { grid-template-columns: 240px 1fr; }
}
.rai-delivery .agent-rail {
  background: var(--surface-1);
  border-right: 1px solid var(--border-default);
  display: flex; flex-direction: column;
  overflow: hidden;
  min-height: 0;
  min-width: 0;
}
.rai-delivery .ar-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 16px 12px;
  border-bottom: 1px solid var(--divider);
}
.rai-delivery .ar-title {
  display: inline-flex; align-items: center; gap: 8px;
  font: 600 14px var(--font-ui);
  color: var(--fg-1);
  letter-spacing: -.005em;
}
.rai-delivery .ar-title svg { color: var(--brand); }
.rai-delivery .ar-new-btn {
  width: 26px; height: 26px;
  background: var(--surface-2);
  border: 1px solid var(--border-default);
  border-radius: 6px;
  color: var(--fg-2);
  display: inline-flex; align-items: center; justify-content: center;
  cursor: pointer;
}
.rai-delivery .ar-new-btn:hover { background: var(--brand); border-color: var(--brand); color: var(--fg-onbrand); }
.rai-delivery .ar-new-chat {
  display: flex; align-items: center; gap: 10px;
  margin: 12px;
  padding: 9px 12px;
  background: var(--brand-soft);
  border: 1px solid rgba(251,95,44,.2);
  border-radius: 8px;
  color: var(--brand);
  font: 600 12.5px var(--font-ui);
  cursor: pointer;
  transition: all var(--dur-fast) var(--ease-out);
}
.rai-delivery .ar-new-chat:hover { background: var(--brand); color: var(--fg-onbrand); }
.rai-delivery .ar-new-chat kbd {
  margin-left: auto;
  font: 500 10px var(--font-mono);
  background: rgba(0,0,0,.15);
  color: inherit;
  padding: 1px 6px;
  border-radius: 4px;
  opacity: 0.7;
}
.rai-delivery .ar-section-label {
  font: 700 9.5px var(--font-mono);
  letter-spacing: .14em;
  color: var(--fg-muted);
  padding: 14px 16px 6px;
}
.rai-delivery .ar-clients {
  padding: 0 8px;
  display: flex; flex-direction: column; gap: 2px;
}
.rai-delivery .ar-client {
  display: flex; align-items: center; gap: 10px;
  padding: 7px 10px;
  background: transparent;
  border: 0;
  border-radius: 6px;
  color: var(--fg-2);
  font: 500 12.5px var(--font-ui);
  cursor: pointer;
  text-align: left;
  transition: all var(--dur-fast) var(--ease-out);
}
.rai-delivery .ar-client:hover { background: var(--surface-2); color: var(--fg-1); }
.rai-delivery .ar-client.on {
  background: var(--brand-soft);
  color: var(--brand);
}
.rai-delivery .ar-client svg { opacity: 0.6; }
.rai-delivery .ar-client.on svg { opacity: 1; }
.rai-delivery .ar-mark {
  width: 22px; height: 22px;
  border-radius: 5px;
  display: inline-flex; align-items: center; justify-content: center;
  font: 700 11px var(--font-ui);
  flex-shrink: 0;
}
.rai-delivery .ar-cname { flex: 1; }
.rai-delivery .ar-convos {
  flex: 1;
  overflow-y: auto;
  padding: 0 8px 12px;
  display: flex; flex-direction: column; gap: 2px;
}
.rai-delivery .ar-convo {
  display: flex; flex-direction: column; gap: 4px;
  padding: 9px 10px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 7px;
  color: var(--fg-2);
  cursor: pointer;
  text-align: left;
  transition: all var(--dur-fast) var(--ease-out);
}
.rai-delivery .ar-convo:hover { background: var(--surface-2); border-color: var(--border-subtle); }
.rai-delivery .ar-convo.on { background: var(--surface-2); border-color: var(--border-default); }
.rai-delivery .ar-convo-title {
  font: 500 12.5px var(--font-ui);
  color: var(--fg-1);
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.rai-delivery .ar-convo-meta {
  display: flex; gap: 8px; align-items: center;
  font: 500 10.5px var(--font-mono);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .ar-convo-tag { font-weight: 600; }
.rai-delivery .ar-convo-who { color: var(--fg-2); font-weight: 600; }
.rai-delivery .ar-convo-row .ar-convo-title { padding-right: 20px; }
.rai-delivery .ar-convo-when { color: var(--fg-muted); }
/* Conversation row = the chat button + a hover-reveal delete (collaborative) */
.rai-delivery .ar-convo-row { position: relative; display: flex; }
.rai-delivery .ar-convo-row .ar-convo { flex: 1; min-width: 0; }
.rai-delivery .ar-convo-row.on .ar-convo { background: var(--surface-2); border-color: var(--border-default); }
.rai-delivery .ar-convo-del {
  position: absolute; top: 6px; right: 6px;
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px; border-radius: 6px;
  background: transparent; border: 0; color: var(--fg-muted); cursor: pointer;
  opacity: 0; transition: opacity var(--dur-fast) var(--ease-out), background var(--dur-fast), color var(--dur-fast);
}
.rai-delivery .ar-convo-row:hover .ar-convo-del { opacity: 1; }
.rai-delivery .ar-convo-del:hover { background: rgba(242,107,92,.15); color: #F26B5C; }
.rai-delivery .ar-loadmore {
  margin: 6px 2px 0; padding: 8px; width: calc(100% - 4px);
  background: transparent; border: 1px dashed var(--border-default); border-radius: 7px;
  color: var(--fg-3); font: 600 11.5px var(--font-ui); cursor: pointer;
  transition: all var(--dur-fast) var(--ease-out);
}
.rai-delivery .ar-loadmore:hover { background: var(--surface-2); color: var(--fg-1); }
.rai-delivery .ar-loadmore:disabled { opacity: .6; cursor: default; }
.rai-delivery .ar-empty {
  padding: 16px 12px;
  font: 400 11.5px var(--font-ui);
  color: var(--fg-muted);
  font-style: italic;
  text-align: center;
}
.rai-delivery .ar-foot {
  display: flex; align-items: center; gap: 7px;
  padding: 10px 16px;
  border-top: 1px solid var(--divider);
  font: 500 10.5px var(--font-mono);
  color: var(--fg-muted);
  letter-spacing: .04em;
}
.rai-delivery .ar-foot svg { color: var(--brand); }
.rai-delivery .agent-main {
  display: flex; flex-direction: column;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  background: var(--surface-page);
}
.rai-delivery .ac-topbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 22px;
  border-bottom: 1px solid var(--divider);
  background: var(--surface-page);
}
.rai-delivery .ac-topbar-left {
  display: flex; align-items: center; gap: 12px;
}
.rai-delivery .ac-tb-eyebrow {
  font: 700 9.5px var(--font-mono);
  letter-spacing: .14em;
  color: var(--fg-muted);
}
.rai-delivery .ac-tb-client {
  display: inline-flex; align-items: center; gap: 8px;
  font: 600 13.5px var(--font-ui);
  color: var(--fg-1);
}
.rai-delivery .ac-tb-client svg { color: var(--fg-muted); }
.rai-delivery .ac-tb-meta {
  font: 500 10.5px var(--font-mono);
  color: var(--fg-muted);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .ac-tb-btn {
  display: inline-flex; align-items: center; gap: 6px;
  background: transparent;
  border: 1px solid var(--border-default);
  color: var(--fg-2);
  font: 500 12px var(--font-ui);
  padding: 6px 10px;
  border-radius: 7px;
  cursor: pointer;
  transition: all var(--dur-fast) var(--ease-out);
}
.rai-delivery .ac-tb-btn:hover { background: var(--surface-2); color: var(--fg-1); }
.rai-delivery .ac-stream {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 24px 28px 12px;
}
.rai-delivery .ac-empty {
  max-width: 720px;
  margin: 20px auto;
  display: flex; flex-direction: column; gap: 28px;
}
.rai-delivery .ac-empty-head {
  text-align: center;
  display: flex; flex-direction: column; align-items: center; gap: 12px;
}
.rai-delivery .ac-empty-mark {
  width: 64px; height: 64px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--brand) 0%, #B33B14 100%);
  display: inline-flex; align-items: center; justify-content: center;
  color: white;
  box-shadow: 0 14px 32px -8px rgba(251,95,44,.5);
}
.rai-delivery .ac-empty-head h2 {
  font: 600 24px var(--font-ui);
  color: var(--fg-1);
  letter-spacing: -.016em;
  margin: 0;
}
.rai-delivery .ac-empty-head p {
  font: 400 13.5px var(--font-ui);
  color: var(--fg-3);
  line-height: 1.55;
  max-width: 520px;
  margin: 0;
}
.rai-delivery .ac-starters-label, .rai-delivery .ac-caps-label {
  font: 700 10px var(--font-mono);
  letter-spacing: .12em;
  color: var(--fg-muted);
  margin-bottom: 10px;
}
.rai-delivery .ac-starters-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}
.rai-delivery .ac-starter {
  display: flex; align-items: center; gap: 8px;
  padding: 12px 14px;
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 10px;
  color: var(--fg-2);
  font: 500 12.5px var(--font-ui);
  cursor: pointer;
  text-align: left;
  transition: all var(--dur-fast) var(--ease-out);
}
.rai-delivery .ac-starter:hover {
  background: var(--brand-soft);
  border-color: rgba(251,95,44,.3);
  color: var(--brand);
}
.rai-delivery .ac-starter svg { color: var(--fg-muted); }
.rai-delivery .ac-starter:hover svg { color: var(--brand); }
.rai-delivery .ac-caps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.rai-delivery .ac-cap {
  display: flex; gap: 10px;
  padding: 11px 12px;
  background: var(--surface-1);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
}
.rai-delivery .ac-cap-icon {
  width: 28px; height: 28px;
  border-radius: 7px;
  background: var(--brand-soft);
  color: var(--brand);
  display: inline-flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.rai-delivery .ac-cap-t {
  font: 600 12px var(--font-ui);
  color: var(--fg-1);
}
.rai-delivery .ac-cap-d {
  font: 400 10.5px var(--font-ui);
  color: var(--fg-3);
  line-height: 1.4;
}
.rai-delivery .ac-msg {
  display: flex; gap: 12px;
  margin-bottom: 18px;
  max-width: 820px;
  margin-left: auto;
  margin-right: auto;
}
.rai-delivery .ac-msg-user { justify-content: flex-end; }
.rai-delivery .ac-msg-ai { justify-content: flex-start; }
.rai-delivery .ac-msg-avatar {
  width: 28px; height: 28px;
  border-radius: 7px;
  display: inline-flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  font: 700 10px var(--font-mono);
}
.rai-delivery .ac-msg-avatar.user {
  background: var(--surface-2);
  color: var(--fg-2);
}
.rai-delivery .ac-msg-avatar.ai {
  background: linear-gradient(135deg, var(--brand) 0%, #B33B14 100%);
  color: white;
}
.rai-delivery .ac-msg-body {
  max-width: 620px;
  padding: 12px 16px;
  border-radius: 14px;
  background: var(--surface-1);
  border: 1px solid var(--border-default);
}
.rai-delivery .ac-msg-user .ac-msg-body {
  background: var(--brand);
  border-color: var(--brand);
  color: var(--fg-onbrand);
  font: 500 13px var(--font-ui);
  line-height: 1.5;
}
.rai-delivery .ac-msg-ai .ac-msg-body {
  background: var(--surface-1);
  font: 400 13.5px var(--font-ui);
  color: var(--fg-1);
  line-height: 1.6;
}
.rai-delivery .ac-msg-body.is-error {
  background: var(--danger-bg);
  border-color: rgba(242,107,92,.3);
  color: var(--danger);
}
.rai-delivery .ac-msg-text p { margin: 0 0 10px; }
.rai-delivery .ac-msg-text p:last-child { margin-bottom: 0; }
.rai-delivery .ac-msg-text strong { color: var(--brand); font-weight: 700; }
.rai-delivery .ac-md-list {
  margin: 8px 0;
  padding-left: 22px;
}
.rai-delivery .ac-md-list li { margin-bottom: 4px; line-height: 1.55; }
.rai-delivery .ac-md-ol { list-style: decimal; }
/* Markdown headings inside a Resty message */
.rai-delivery .ac-msg-text .ac-md-h {
  color: var(--fg-1); font-family: var(--font-ui); font-weight: 700;
  margin: 16px 0 8px; line-height: 1.3; letter-spacing: -0.01em;
}
.rai-delivery .ac-msg-text .ac-md-h:first-child { margin-top: 0; }
.rai-delivery .ac-msg-text .ac-md-h1 { font-size: 17px; }
.rai-delivery .ac-msg-text .ac-md-h2 { font-size: 15px; }
.rai-delivery .ac-msg-text .ac-md-h3 { font-size: 13.5px; }
.rai-delivery .ac-msg-text .ac-md-h4 { font-size: 12.5px; color: var(--fg-2); text-transform: none; }
/* Horizontal rule */
.rai-delivery .ac-md-hr { border: 0; border-top: 1px solid var(--divider); margin: 14px 0; }
/* Inline code */
.rai-delivery .ac-md-code {
  font: 500 12px var(--font-mono); background: var(--surface-2);
  border: 1px solid var(--border-subtle); border-radius: 5px; padding: 1px 5px;
  color: var(--fg-1); white-space: nowrap;
}
/* Markdown tables — Resto AI styling */
.rai-delivery .ac-md-table-wrap { margin: 10px 0; overflow-x: auto; border: 1px solid var(--border-default); border-radius: var(--radius-md); }
.rai-delivery .ac-md-table { width: 100%; border-collapse: collapse; font: 500 12.5px var(--font-ui); font-variant-numeric: tabular-nums; }
.rai-delivery .ac-md-table th {
  text-align: left; font: 600 11px var(--font-ui); text-transform: uppercase; letter-spacing: 0.04em;
  color: var(--fg-3); background: var(--surface-2); padding: 8px 12px; white-space: nowrap;
  border-bottom: 1px solid var(--border-default);
}
.rai-delivery .ac-md-table td { padding: 8px 12px; color: var(--fg-1); border-bottom: 1px solid var(--divider); }
.rai-delivery .ac-md-table tr:last-child td { border-bottom: 0; }
.rai-delivery .ac-md-table td:not(:first-child), .rai-delivery .ac-md-table th:not(:first-child) { text-align: right; }
.rai-delivery .ac-md-table tbody tr:hover td { background: var(--surface-1); }
.rai-delivery .ac-msg-actions {
  display: flex; gap: 6px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px dashed var(--border-subtle);
  opacity: 0;
  transition: opacity var(--dur-fast) var(--ease-out);
}
.rai-delivery .ac-msg-ai:hover .ac-msg-actions { opacity: 1; }
.rai-delivery .ac-msg-actions button {
  width: 22px; height: 22px;
  border-radius: 5px;
  background: transparent;
  border: 0;
  color: var(--fg-muted);
  cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
}
.rai-delivery .ac-msg-actions button:hover { background: var(--surface-2); color: var(--brand); }
.rai-delivery .ac-msg-actions button.copied,
.rai-delivery .ac-msg-actions button.liked { color: var(--brand); background: var(--brand-soft, rgba(251,95,44,.12)); }
.rai-delivery .ac-pending {
  display: inline-flex; gap: 5px;
  align-items: center;
  padding: 4px 0;
}
.rai-delivery .ac-pending-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--brand);
  animation: ac-bounce 1.4s infinite ease-in-out;
  opacity: 0.7;
}
.rai-delivery .ac-pending-dot:nth-child(2) { animation-delay: .16s; }
.rai-delivery .ac-pending-dot:nth-child(3) { animation-delay: .32s; }
@keyframes ac-bounce {
  0%, 80%, 100% { transform: translateY(0); opacity: 0.4; }
  40%           { transform: translateY(-4px); opacity: 1; }
}
/* "Thinking" status — cooking-themed phrase that cycles while Resty works,
   with a motion icon beside it (Claude-Design "Caramelizing onions…" feel). */
.rai-delivery .ac-thinking {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 3px 0; font: 500 13px var(--font-ui); color: var(--fg-2);
}
.rai-delivery .ac-thinking-icon {
  display: inline-flex; color: var(--brand);
  animation: ac-think-icon 1.5s ease-in-out infinite;
}
@keyframes ac-think-icon {
  0%, 100% { transform: scale(1) rotate(0deg);   opacity: 0.65; }
  50%      { transform: scale(1.18) rotate(12deg); opacity: 1; }
}
.rai-delivery .ac-thinking-words {
  position: relative; display: inline-block;
  height: 1.25em; min-width: 180px; overflow: hidden; vertical-align: bottom;
}
.rai-delivery .ac-thinking-words > span {
  position: absolute; left: 0; top: 0; white-space: nowrap;
  background: linear-gradient(90deg, var(--fg-2) 0%, var(--brand) 50%, var(--fg-2) 100%);
  background-size: 200% 100%;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
  opacity: 0;
  animation: ac-think-word 9.6s infinite, ac-think-shimmer 2.4s linear infinite;
}
.rai-delivery .ac-thinking-words > span:nth-child(1) { animation-delay: 0s,    0s; }
.rai-delivery .ac-thinking-words > span:nth-child(2) { animation-delay: 1.6s,  0s; }
.rai-delivery .ac-thinking-words > span:nth-child(3) { animation-delay: 3.2s,  0s; }
.rai-delivery .ac-thinking-words > span:nth-child(4) { animation-delay: 4.8s,  0s; }
.rai-delivery .ac-thinking-words > span:nth-child(5) { animation-delay: 6.4s,  0s; }
.rai-delivery .ac-thinking-words > span:nth-child(6) { animation-delay: 8.0s,  0s; }
@keyframes ac-think-word {
  0%   { opacity: 0; transform: translateY(8px); }
  3%   { opacity: 1; transform: translateY(0); }
  14%  { opacity: 1; transform: translateY(0); }
  17%  { opacity: 0; transform: translateY(-8px); }
  100% { opacity: 0; transform: translateY(-8px); }
}
@keyframes ac-think-shimmer {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
.rai-delivery .ac-quick {
  display: flex; flex-wrap: wrap; gap: 6px;
  padding: 12px 28px 0;
  border-top: 1px solid var(--divider);
}
.rai-delivery .ac-quick-btn {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--surface-2);
  border: 1px solid var(--border-subtle);
  color: var(--fg-2);
  font: 500 11.5px var(--font-ui);
  padding: 5px 10px;
  border-radius: 999px;
  cursor: pointer;
  transition: all var(--dur-fast) var(--ease-out);
}
.rai-delivery .ac-quick-btn:hover:not(:disabled) {
  background: var(--brand-soft);
  border-color: rgba(251,95,44,.3);
  color: var(--brand);
}
.rai-delivery .ac-quick-btn:disabled { opacity: 0.4; cursor: not-allowed; }
.rai-delivery .ac-quick-btn svg { opacity: 0.7; }
.rai-delivery .ac-quick-btn:hover:not(:disabled) svg { color: var(--brand); opacity: 1; }
.rai-delivery .ac-input-form {
  padding: 12px 28px 20px;
  background: var(--surface-page);
}
.rai-delivery .ac-input-wrap {
  display: flex; align-items: flex-end; gap: 10px;
  padding: 10px 14px;
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 12px;
  transition: border-color var(--dur-fast) var(--ease-out);
}
.rai-delivery .ac-input-wrap:focus-within {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(251,95,44,.12);
}
.rai-delivery .ac-input-wrap > svg {
  color: var(--brand);
  flex-shrink: 0;
  margin-bottom: 6px;
}
.rai-delivery .ac-input-wrap textarea {
  flex: 1;
  background: transparent;
  border: 0;
  outline: 0;
  resize: none;
  color: var(--fg-1);
  font: 400 13.5px var(--font-ui);
  line-height: 1.55;
  max-height: 200px;
  padding: 4px 0;
  font-family: var(--font-ui);
}
.rai-delivery .ac-input-wrap textarea::placeholder { color: var(--fg-3); }
.rai-delivery .ac-send {
  width: 32px; height: 32px;
  background: var(--brand);
  border: 0;
  border-radius: 8px;
  color: var(--fg-onbrand);
  cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  transition: all var(--dur-fast) var(--ease-out);
}
.rai-delivery .ac-send:hover:not(:disabled) { background: var(--brand-press); transform: scale(1.05); }
.rai-delivery .ac-send:disabled { opacity: 0.4; cursor: not-allowed; }
.rai-delivery .ac-spin {
  width: 14px; height: 14px;
  border: 2px solid rgba(255,255,255,.3);
  border-top-color: white;
  border-radius: 50%;
  animation: ac-spin 0.7s linear infinite;
}
@keyframes ac-spin { to { transform: rotate(360deg); } }
.rai-delivery .ac-input-foot {
  display: flex; align-items: center; justify-content: space-between;
  padding: 8px 4px 0;
  font: 500 10.5px var(--font-mono);
  color: var(--fg-muted);
}
.rai-delivery .ac-input-foot kbd {
  background: var(--surface-2);
  border: 1px solid var(--border-subtle);
  padding: 1px 5px;
  border-radius: 4px;
  font: 500 10px var(--font-mono);
}
.rai-delivery .ac-model {
  display: inline-flex; align-items: center; gap: 6px;
}
.rai-delivery .ac-model-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 6px var(--success);
}
.rai-delivery .agent-context-rail {
  background: var(--surface-1);
  border-left: 1px solid var(--border-default);
  overflow-y: auto;
  min-height: 0;
  padding: 16px 14px;
}
.rai-delivery .acr-head {
  display: flex; flex-direction: column; gap: 2px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--divider);
  margin-bottom: 14px;
}
.rai-delivery .acr-eyebrow {
  font: 700 9.5px var(--font-mono);
  letter-spacing: .14em;
  color: var(--brand);
}
.rai-delivery .acr-meta {
  font: 500 11px var(--font-mono);
  color: var(--fg-muted);
}
.rai-delivery .acr-scope {
  background: var(--brand-soft);
  border: 1px solid rgba(251,95,44,.18);
  border-radius: 8px;
  padding: 10px 12px;
  margin-bottom: 16px;
}
.rai-delivery .acr-scope-lbl {
  font: 700 9.5px var(--font-mono);
  letter-spacing: .12em;
  color: var(--brand);
}
.rai-delivery .acr-scope-val {
  font: 600 14px var(--font-ui);
  color: var(--fg-1);
  margin-top: 2px;
}
.rai-delivery .acr-scope-period {
  font: 500 11px var(--font-mono);
  color: var(--fg-3);
  font-variant-numeric: tabular-nums;
  text-transform: capitalize;
  margin-top: 2px;
}
.rai-delivery .acr-section { margin-bottom: 18px; }
.rai-delivery .acr-section-lbl {
  display: flex; align-items: center; justify-content: space-between;
  font: 700 9.5px var(--font-mono);
  letter-spacing: .14em;
  color: var(--fg-muted);
  margin-bottom: 10px;
}
.rai-delivery .acr-section-cnt {
  font: 600 9px var(--font-mono);
  background: var(--surface-2);
  color: var(--fg-3);
  padding: 1px 6px;
  border-radius: 999px;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .acr-kpis {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.rai-delivery .acr-kpi {
  display: flex; flex-direction: column; gap: 1px;
  padding: 8px 10px;
  background: var(--surface-page);
  border: 1px solid var(--border-subtle);
  border-radius: 7px;
}
.rai-delivery .acr-kpi-lbl {
  font: 600 9px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--fg-muted);
}
.rai-delivery .acr-kpi-val {
  font: 600 16px var(--font-mono);
  color: var(--fg-1);
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
}
.rai-delivery .acr-kpi-d {
  font: 500 9.5px var(--font-mono);
  font-variant-numeric: tabular-nums;
  margin-top: 2px;
}
.rai-delivery .acr-kpi-d.up { color: var(--success); }
.rai-delivery .acr-kpi-d.down { color: var(--danger); }
.rai-delivery .acr-memory {
  display: flex; flex-direction: column; gap: 8px;
}
.rai-delivery .acr-mem-item {
  display: flex; flex-direction: column; gap: 2px;
  padding: 8px 10px;
  background: var(--surface-page);
  border: 1px solid var(--border-subtle);
  border-radius: 7px;
}
.rai-delivery .acr-mem-item.is-decision {
  border-color: rgba(108,169,242,.3);
  background: rgba(108,169,242,.06);
}
.rai-delivery .acr-mem-item.is-contract {
  border-color: rgba(244,169,58,.3);
  background: var(--warning-bg);
}
.rai-delivery .acr-mem-date {
  font: 700 9px var(--font-mono);
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--fg-muted);
}
.rai-delivery .acr-mem-text {
  font: 400 11.5px var(--font-ui);
  color: var(--fg-1);
  line-height: 1.5;
}
.rai-delivery .acr-sources { display: flex; flex-direction: column; gap: 8px; }
.rai-delivery .acr-source {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 8px 10px;
  background: var(--surface-page);
  border: 1px solid var(--border-subtle);
  border-radius: 7px;
}
.rai-delivery .acr-source .statusdot { margin-top: 5px; flex-shrink: 0; }
.rai-delivery .acrs-name { font: 600 12px var(--font-ui); color: var(--fg-1); }
.rai-delivery .acrs-meta { font: 500 10.5px var(--font-mono); color: var(--fg-3); font-variant-numeric: tabular-nums; margin-top: 1px; }
.rai-delivery .page:has(.agent-shell) {
  padding: 0;
  max-width: none;
  overflow: hidden;
  height: calc(100vh - 56px);
}
.rai-delivery .rcs-donut-card {
  margin-top: 14px; margin-bottom: 14px;
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  background: var(--surface-page);
  overflow: hidden;
}
.rai-delivery .rcs-donut-head {
  padding: 11px 14px;
  background: var(--surface-1);
  border-bottom: 1px solid var(--divider);
  font: 700 9.5px var(--font-mono);
  letter-spacing: .14em;
  color: var(--fg-3);
}
.rai-delivery .rcs-donut-body {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 24px;
  padding: 18px 22px;
  align-items: center;
}
.rai-delivery .rcs-donut-legend { display: flex; flex-direction: column; gap: 6px; }
.rai-delivery .rcs-dl-row {
  display: grid;
  grid-template-columns: 14px 1fr auto auto;
  gap: 10px; align-items: center;
  padding: 6px 0;
  border-bottom: 1px solid var(--divider);
}
.rai-delivery .rcs-dl-row:last-child { border-bottom: 0; }
.rai-delivery .rcs-dl-dot { width: 10px; height: 10px; border-radius: 3px; }
.rai-delivery .rcs-dl-name { font: 500 13px var(--font-ui); color: var(--fg-1); }
.rai-delivery .rcs-dl-val { font: 600 12.5px var(--font-mono); color: var(--fg-1); font-variant-numeric: tabular-nums; }
.rai-delivery .rcs-dl-pct { font: 500 11px var(--font-mono); color: var(--fg-muted); min-width: 44px; text-align: right; font-variant-numeric: tabular-nums; }
.rai-delivery .rrk-sales-cell {
  display: flex; align-items: center; gap: 8px;
  justify-content: flex-end;
}
.rai-delivery .rrk-sales-bar {
  flex: 1;
  height: 6px;
  background: var(--surface-3);
  border-radius: 999px;
  overflow: hidden;
  display: block;
}
.rai-delivery .rrk-sales-fill {
  display: block;
  height: 100%;
  background: var(--brand);
  opacity: 0.78;
  border-radius: 999px;
}
.rai-delivery .rrk-sales-val {
  font: 500 12px var(--font-mono);
  color: var(--fg-1);
  font-variant-numeric: tabular-nums;
  min-width: 56px;
  text-align: right;
}
.rai-delivery .rpareto-callout {
  display: flex; gap: 28px;
  padding: 10px 14px 6px;
}
.rai-delivery .rpc-cell { display: flex; flex-direction: column; gap: 1px; }
.rai-delivery .rpc-val {
  font: 600 22px var(--font-mono);
  color: var(--brand);
  letter-spacing: -.015em;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rpc-lbl {
  font: 600 9.5px var(--font-mono);
  letter-spacing: .12em;
  color: var(--fg-muted);
}
.rai-delivery .rrev-trend {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--divider);
  width: 100%;
}
.rai-delivery .rrev-trend-head {
  font: 700 9.5px var(--font-mono);
  letter-spacing: .12em;
  color: var(--fg-muted);
  margin-bottom: 6px;
}
.rai-delivery .reh-spark {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--divider);
}
.rai-delivery .rsec-eyebrow {
  display: flex; align-items: center; gap: 10px;
}
.rai-delivery .rsec-eyebrow-pending {
  font: 600 9px var(--font-mono);
  text-transform: lowercase;
  letter-spacing: .04em;
  padding: 1px 7px;
  background: var(--surface-2);
  border: 1px dashed var(--border-default);
  color: var(--fg-muted);
  border-radius: 999px;
}
.rai-delivery .rrail-loc-list { display: flex; flex-direction: column; gap: 3px; }
.rai-delivery .rrail-loc {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 10px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 6px;
  color: var(--fg-2);
  font: 500 12px var(--font-ui);
  cursor: pointer;
  text-align: left;
  transition: all var(--dur-fast) var(--ease-out);
}
.rai-delivery .rrail-loc:hover { background: var(--surface-2); color: var(--fg-1); }
.rai-delivery .rrail-loc.on { background: var(--brand-soft); color: var(--brand); border-color: rgba(251,95,44,.2); }
.rai-delivery .rrail-loc svg { opacity: 0.6; }
.rai-delivery .rrail-loc.on svg { opacity: 1; }
.rai-delivery .rrail-toggle {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 4px;
  font: 500 11.5px var(--font-ui);
  color: var(--fg-2);
  cursor: pointer;
  margin-top: 4px;
}
.rai-delivery .rrail-toggle input { accent-color: var(--brand); }
.rai-delivery .rrail-pending {
  font: 600 9px var(--font-mono);
  text-transform: lowercase;
  letter-spacing: .04em;
  color: var(--fg-muted);
  background: var(--surface-2);
  padding: 1px 6px;
  border-radius: 4px;
  margin-left: 4px;
}
.rai-delivery .rsec-cover2 {
  min-height: 480px;
  padding: 36px 44px;
  display: flex; flex-direction: column; justify-content: space-between;
  border: 1px solid var(--border-default);
}
.rai-delivery .cov2-top {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px;
}
.rai-delivery .cov2-brand { display: flex; align-items: center; gap: 14px; }
.rai-delivery .cov2-mark {
  width: 54px; height: 54px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font: 700 24px var(--font-ui);
  color: white;
  box-shadow: 0 12px 28px -10px rgba(0,0,0,.5);
}
.rai-delivery .cov2-overline {
  font: 700 12px var(--font-mono);
  letter-spacing: .12em;
  color: var(--fg-2);
  text-transform: uppercase;
}
.rai-delivery .cov2-overline-right {
  font: 500 11.5px var(--font-mono);
  color: var(--fg-3);
  letter-spacing: .04em;
}
.rai-delivery .cov2-overline-right strong { color: var(--fg-1); font-weight: 700; }
.rai-delivery .cov2-title { padding: 18px 0 24px; }
.rai-delivery .cov2-title-eyebrow {
  font: 700 11px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .14em;
  color: var(--fg-3);
  margin-bottom: 8px;
}
.rai-delivery .cov2-name {
  font: 600 60px var(--font-ui);
  font-style: italic;
  letter-spacing: -.028em;
  line-height: 1.0;
  color: var(--fg-1);
  margin: 0;
}
.rai-delivery .cov2-sub {
  font: 500 14px var(--font-ui);
  color: var(--fg-3);
  margin-top: 14px;
  letter-spacing: .01em;
}
.rai-delivery .cov2-heroes {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  padding-top: 24px;
  border-top: 1px solid var(--border-subtle);
}
.rai-delivery .cov2-hero { display: flex; flex-direction: column; gap: 4px; }
.rai-delivery .ch-lbl {
  font: 700 10px var(--font-mono);
  letter-spacing: .14em;
  color: var(--fg-3);
}
.rai-delivery .ch-val {
  font: 600 38px var(--font-mono);
  color: var(--fg-1);
  letter-spacing: -.03em;
  line-height: 1.0;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .ch-delta {
  font: 600 12px var(--font-mono);
  font-variant-numeric: tabular-nums;
  margin-top: 2px;
}
.rai-delivery .ch-delta.up { color: var(--success); }
.rai-delivery .ch-delta.down { color: var(--danger); }
.rai-delivery .ch-delta.flat { color: var(--fg-3); }
.rai-delivery .rsec-perf-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: 20px;
}
.rai-delivery .rperf {
  padding: 18px 18px 16px;
  background: var(--surface-page);
  border-right: 1px solid var(--divider);
  display: flex; flex-direction: column; gap: 4px;
}
.rai-delivery .rperf:last-child { border-right: 0; }
.rai-delivery .rp-lbl {
  font: 700 9.5px var(--font-mono);
  letter-spacing: .14em;
}
.rai-delivery .rp-val {
  font: 600 28px var(--font-mono);
  color: var(--fg-1);
  letter-spacing: -.02em;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rp-delta {
  font: 600 11px var(--font-mono);
  font-variant-numeric: tabular-nums;
  margin-top: 2px;
}
.rai-delivery .rp-delta.up { color: var(--success); }
.rai-delivery .rp-delta.down { color: var(--danger); }
.rai-delivery .rsec-chart-card {
  background: var(--surface-page);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  padding: 14px 18px 16px;
  margin-bottom: 20px;
}
.rai-delivery .rsc-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 10px;
}
.rai-delivery .rsc-title {
  font: 600 11px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--fg-3);
}
.rai-delivery .rsc-legend {
  display: flex; gap: 14px;
  font: 500 11px var(--font-ui);
  color: var(--fg-2);
}
.rai-delivery .rsc-legend > span { display: inline-flex; align-items: center; gap: 6px; }
.rai-delivery .rsec-mini-table {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr 1fr;
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.rai-delivery .rmt-head, .rai-delivery .rmt-row { display: contents; }
.rai-delivery .rmt-head > div {
  padding: 9px 14px;
  background: var(--surface-page);
  border-bottom: 1px solid var(--divider);
  font: 700 9.5px var(--font-mono);
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--fg-muted);
}
.rai-delivery .rmt-row > div {
  padding: 9px 14px;
  border-bottom: 1px solid var(--divider);
  font: 500 12px var(--font-ui);
  color: var(--fg-1);
}
.rai-delivery .rmt-row:last-child > div { border-bottom: 0; }
.rai-delivery .rmt-head > div.num, .rai-delivery .rmt-row > div.num {
  text-align: right;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  justify-self: end;
}
.rai-delivery .rpnl-matrix {
  display: grid;
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--surface-page);
}
.rai-delivery .rpnl-cell {
  padding: 8px 12px;
  border-bottom: 1px solid var(--divider);
  font: 500 12px var(--font-ui);
  color: var(--fg-1);
}
.rai-delivery .rpnl-head {
  font: 700 9.5px var(--font-mono);
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--fg-muted);
  background: var(--surface-1);
  padding-top: 11px; padding-bottom: 11px;
}
.rai-delivery .rpnl-lbl { color: var(--fg-2); }
.rai-delivery .rpnl-indent { padding-left: 24px; color: var(--fg-3); font-size: 11.5px; }
.rai-delivery .rpnl-cell.num {
  text-align: right;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rpnl-divider { border-top: 1px solid var(--border-default); }
.rai-delivery .rpnl-bold { font-weight: 700; color: var(--fg-1); }
.rai-delivery .rpnl-final {
  background: rgba(79,180,119,.08);
  color: var(--success);
  font-weight: 700;
}
.rai-delivery .rpnl-current { background: var(--brand-soft); font-weight: 600; }
.rai-delivery .rsec-rank-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 18px;
}
.rai-delivery .rsec-rank-list {
  display: grid;
  grid-template-columns: 36px 1.6fr 70px 150px 70px;
  background: var(--surface-page);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.rai-delivery .rrk-head, .rai-delivery .rrk-row { display: contents; }
.rai-delivery .rrk-head > div {
  padding: 9px 10px;
  background: var(--surface-1);
  font: 700 9.5px var(--font-mono);
  letter-spacing: .1em;
  color: var(--fg-muted);
}
.rai-delivery .rrk-head > div.num { text-align: right; justify-self: end; }
.rai-delivery .rrk-row > div {
  padding: 9px 10px;
  border-top: 1px solid var(--divider);
  font: 500 12.5px var(--font-ui);
  color: var(--fg-1);
  display: flex; align-items: center;
}
.rai-delivery .rrk-pos {
  font: 700 11px var(--font-mono);
  color: var(--fg-muted);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rrk-name { gap: 8px; }
.rai-delivery .rrk-badge.popular {
  font: 700 8.5px var(--font-mono);
  letter-spacing: .08em;
  background: var(--brand-soft);
  color: var(--brand);
  padding: 1px 6px;
  border-radius: 4px;
}
.rai-delivery .rrk-row > div.num {
  justify-content: flex-end;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rrk-delta.up { color: var(--success); font-weight: 600; }
.rai-delivery .rrk-delta.down { color: var(--danger); font-weight: 600; }
.rai-delivery .rsec-rank-side { display: flex; flex-direction: column; gap: 12px; }
.rai-delivery .rmover-block {
  background: var(--surface-page);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  padding: 12px 14px;
}
.rai-delivery .rmv-head {
  display: flex; align-items: center; gap: 6px;
  font: 700 10px var(--font-mono);
  letter-spacing: .12em;
  color: var(--fg-2);
  margin-bottom: 8px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--divider);
}
.rai-delivery .rmv-arrow {
  width: 18px; height: 18px;
  border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  font: 700 13px var(--font-mono);
}
.rai-delivery .rmv-arrow.up { background: var(--success-bg); color: var(--success); }
.rai-delivery .rmv-arrow.down { background: var(--danger-bg);  color: var(--danger); }
.rai-delivery .rmv-row { padding: 6px 0; }
.rai-delivery .rmv-name { font: 600 12.5px var(--font-ui); color: var(--fg-1); }
.rai-delivery .rmv-delta { font: 500 11px var(--font-mono); font-variant-numeric: tabular-nums; }
.rai-delivery .rmv-delta.up { color: var(--success); }
.rai-delivery .rmv-delta.down { color: var(--danger); }
.rai-delivery .rsec-segments {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 14px;
}
.rai-delivery .rseg-card {
  padding: 18px 18px 16px;
  background: var(--surface-page);
  border: 1px solid var(--border-default);
  border-top-width: 3px;
  border-radius: var(--radius-md);
  display: flex; flex-direction: column; gap: 8px;
}
.rai-delivery .rseg-head {
  display: flex; align-items: baseline; justify-content: space-between;
}
.rai-delivery .rseg-lbl {
  font: 700 11px var(--font-mono);
  letter-spacing: .14em;
}
.rai-delivery .rseg-count {
  font: 600 28px var(--font-mono);
  color: var(--fg-1);
  letter-spacing: -.02em;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rseg-sub { font: 400 11px var(--font-ui); color: var(--fg-3); }
.rai-delivery .rseg-hero {
  display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap;
  padding-top: 8px;
  border-top: 1px solid var(--divider);
}
.rai-delivery .rseg-sales {
  font: 600 22px var(--font-mono);
  color: var(--fg-1);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rseg-pct {
  font: 500 11px var(--font-mono);
  color: var(--fg-3);
}
.rai-delivery .rseg-delta {
  font: 600 11px var(--font-mono);
  margin-left: auto;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rseg-delta.up { color: var(--success); }
.rai-delivery .rseg-delta.down { color: var(--danger); }
.rai-delivery .rseg-stats {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--divider);
}
.rai-delivery .rseg-stats > div { display: flex; flex-direction: column; gap: 1px; }
.rai-delivery .rss-lbl {
  font: 700 9px var(--font-mono);
  letter-spacing: .08em;
  color: var(--fg-muted);
}
.rai-delivery .rss-val {
  font: 600 14px var(--font-mono);
  color: var(--fg-1);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rseg-takeaway {
  display: flex; gap: 10px;
  padding: 12px 14px;
  background: var(--brand-soft);
  border: 1px solid rgba(251,95,44,.18);
  border-radius: var(--radius-md);
  font: 400 12px var(--font-ui);
  color: var(--fg-2);
  line-height: 1.55;
}
.rai-delivery .rseg-takeaway svg { color: var(--brand); flex-shrink: 0; margin-top: 2px; }
.rai-delivery .rseg-takeaway strong { color: var(--brand); font-weight: 700; }
.rai-delivery .rsec-reviews-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  grid-template-rows: auto auto;
  gap: 14px;
}
.rai-delivery .rrev-rating-card {
  grid-row: 1 / 3;
  background: var(--surface-page);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  padding: 24px 20px;
  display: flex; flex-direction: column; gap: 8px; align-items: flex-start;
}
.rai-delivery .rrev-stars {
  font: 600 38px var(--font-mono);
  color: #F4A93A;
  letter-spacing: -.01em;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rrev-total {
  font: 500 12px var(--font-ui);
  color: var(--fg-3);
}
.rai-delivery .rrev-30 {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--divider);
  width: 100%;
}
.rai-delivery .r30-lbl {
  font: 700 9.5px var(--font-mono);
  letter-spacing: .12em;
  color: var(--fg-muted);
  margin-bottom: 10px;
}
.rai-delivery .r30-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.rai-delivery .r30-cell { display: flex; flex-direction: column; gap: 2px; }
.rai-delivery .r30-num {
  font: 600 24px var(--font-mono);
  color: var(--fg-1);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .r30-lbl-sm {
  font: 700 9px var(--font-mono);
  letter-spacing: .1em;
  color: var(--fg-muted);
}
.rai-delivery .rrev-summary {
  background: linear-gradient(135deg, rgba(251,95,44,.06) 0%, var(--surface-page) 60%);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  padding: 14px 16px;
}
.rai-delivery .rrev-summary-head {
  display: flex; align-items: center; gap: 6px;
  font: 700 10px var(--font-mono);
  letter-spacing: .14em;
  color: var(--brand);
  margin-bottom: 8px;
}
.rai-delivery .rrev-summary-head svg { color: var(--brand); }
.rai-delivery .rrev-summary-text {
  font: 400 13px var(--font-ui);
  color: var(--fg-2);
  line-height: 1.55;
  margin: 0;
}
.rai-delivery .rrev-tags {
  background: var(--surface-page);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  display: grid; grid-template-columns: 1fr 1fr; gap: 16px;
}
.rai-delivery .rrev-tag-head {
  font: 700 9.5px var(--font-mono);
  letter-spacing: .12em;
  margin-bottom: 8px;
}
.rai-delivery .rrev-tag-pills { display: flex; flex-wrap: wrap; gap: 5px; }
.rai-delivery .rrev-pill {
  font: 500 11px var(--font-ui);
  padding: 3px 9px;
  border-radius: 999px;
}
.rai-delivery .rrev-pill.good { background: var(--success-bg); color: var(--success); }
.rai-delivery .rrev-pill.bad { background: var(--danger-bg);  color: var(--danger); }
.rai-delivery .rrev-watch {
  grid-column: 1 / 3;
  background: var(--warning-bg);
  border: 1px solid rgba(244,169,58,.3);
  border-radius: var(--radius-md);
  padding: 12px 16px;
}
.rai-delivery .rrev-watch-head {
  display: flex; align-items: center; gap: 6px;
  font: 700 10px var(--font-mono);
  letter-spacing: .12em;
  color: var(--warning);
  margin-bottom: 8px;
}
.rai-delivery .rrev-watch-head svg { color: var(--warning); }
.rai-delivery .rrev-watch-list { display: flex; flex-direction: column; gap: 4px; }
.rai-delivery .rrev-watch-row {
  display: flex; justify-content: space-between;
  font: 500 12px var(--font-ui);
  color: var(--fg-2);
}
.rai-delivery .rrev-watch-count { font-family: var(--font-mono); font-variant-numeric: tabular-nums; color: var(--fg-3); }
.rai-delivery .rmkt-band {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: 18px;
}
.rai-delivery .rmkt-cell {
  padding: 16px 18px;
  background: var(--surface-page);
  border-right: 1px solid var(--divider);
  display: flex; flex-direction: column; gap: 3px;
}
.rai-delivery .rmkt-cell:last-child { border-right: 0; }
.rai-delivery .rmkt-lbl {
  font: 700 9.5px var(--font-mono);
  letter-spacing: .12em;
  color: var(--fg-muted);
}
.rai-delivery .rmkt-val {
  font: 600 22px var(--font-mono);
  color: var(--fg-1);
  letter-spacing: -.018em;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rmkt-sub { font: 400 11px var(--font-ui); color: var(--fg-3); }
.rai-delivery .rsec-promos2 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 12px;
}
.rai-delivery .rpromo2 {
  position: relative;
  padding: 14px 14px 12px;
  background: var(--surface-page);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  display: flex; flex-direction: column; gap: 6px;
}
.rai-delivery .rpromo2.is-star {
  border-color: rgba(244,169,58,.3);
  background: linear-gradient(135deg, rgba(244,169,58,.06) 0%, var(--surface-page) 60%);
}
.rai-delivery .rpromo2-star {
  position: absolute; top: -8px; right: 14px;
  font: 700 9px var(--font-mono);
  letter-spacing: .1em;
  background: #F4A93A;
  color: var(--ink-0);
  padding: 2px 8px;
  border-radius: 999px;
}
.rai-delivery .rpromo2-head {
  display: flex; align-items: center; justify-content: space-between; gap: 6px;
}
.rai-delivery .rpromo2-loc {
  font: 500 10.5px var(--font-mono);
  color: var(--fg-muted);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rpromo2-title { font: 600 13px var(--font-ui); color: var(--fg-1); letter-spacing: -.005em; }
.rai-delivery .rpromo2-target { font: 400 11px var(--font-ui); color: var(--fg-3); }
.rai-delivery .rpromo2-stats {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px;
  padding: 10px 0;
  border-top: 1px solid var(--divider);
  border-bottom: 1px solid var(--divider);
  margin-top: 4px;
}
.rai-delivery .rpromo2-stats > div { display: flex; flex-direction: column; gap: 1px; }
.rai-delivery .rps-lbl { font: 700 8.5px var(--font-mono); letter-spacing: .08em; color: var(--fg-muted); }
.rai-delivery .rps-val { font: 600 14px var(--font-mono); color: var(--fg-1); font-variant-numeric: tabular-nums; }
.rai-delivery .rpromo2-ai {
  display: flex; gap: 6px;
  padding-top: 6px;
  font: 400 11px var(--font-ui);
  color: var(--fg-3);
  line-height: 1.5;
}
.rai-delivery .rpromo2-ai svg { color: var(--brand); flex-shrink: 0; margin-top: 2px; }
.rai-delivery .rops-table {
  display: grid;
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.rai-delivery .rops-cell {
  padding: 12px;
  border-bottom: 1px solid var(--divider);
  font: 500 12px var(--font-ui);
  color: var(--fg-1);
}
.rai-delivery .rops-head {
  background: var(--surface-1);
  font: 700 9.5px var(--font-mono);
  letter-spacing: .1em;
  color: var(--fg-muted);
  text-align: center;
  display: flex; flex-direction: column; gap: 3px;
  align-items: center;
}
.rai-delivery .rops-bench {
  font: 500 9.5px var(--font-mono);
  color: var(--fg-3);
  text-transform: none;
  letter-spacing: 0;
}
.rai-delivery .rops-loc {
  background: var(--surface-page);
}
.rai-delivery .rops-loc-name { font: 600 13px var(--font-ui); color: var(--fg-1); }
.rai-delivery .rops-loc-city { font: 400 10.5px var(--font-mono); color: var(--fg-3); font-variant-numeric: tabular-nums; }
.rai-delivery .rops-data {
  text-align: center;
  background: var(--surface-page);
}
.rai-delivery .rops-pending {
  font: 500 18px var(--font-mono);
  color: var(--fg-muted);
}
.rai-delivery .rops-deepdive {
  margin-top: 18px;
}
.rai-delivery .rops-dd-head {
  font: 700 10px var(--font-mono);
  letter-spacing: .12em;
  color: var(--fg-3);
  margin-bottom: 10px;
}
.rai-delivery .rops-dd-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px;
}
.rai-delivery .rops-dd-card {
  background: var(--surface-page);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  padding: 12px 14px;
}
.rai-delivery .rops-dd-title {
  font: 600 13px var(--font-ui);
  color: var(--fg-1);
  margin-bottom: 8px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--divider);
}
.rai-delivery .rops-dd-items { display: flex; flex-direction: column; gap: 6px; }
.rai-delivery .rops-dd-item { display: flex; justify-content: space-between; font: 500 11.5px var(--font-ui); }
.rai-delivery .rops-dd-lbl { color: var(--fg-3); }
.rai-delivery .rops-dd-val { color: var(--fg-muted); font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.rai-delivery .rsec-whatif {
  background: linear-gradient(135deg, var(--surface-1) 0%, rgba(251,95,44,.04) 100%);
}
.rai-delivery .rwi-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 10px;
}
.rai-delivery .rwi-controls {
  display: flex; flex-direction: column; gap: 14px;
  padding: 18px;
  background: var(--surface-page);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
}
.rai-delivery .rwi-slider { display: flex; flex-direction: column; gap: 6px; }
.rai-delivery .rws-head {
  display: flex; align-items: baseline; justify-content: space-between;
}
.rai-delivery .rws-lbl { font: 600 12px var(--font-ui); color: var(--fg-1); }
.rai-delivery .rws-val {
  font: 600 18px var(--font-mono);
  color: var(--brand);
  font-variant-numeric: tabular-nums;
  letter-spacing: -.01em;
}
.rai-delivery .rwi-slider input[type="range"] {
  width: 100%; accent-color: var(--brand);
  height: 4px;
}
.rai-delivery .rws-help { font: 400 10.5px var(--font-ui); color: var(--fg-muted); font-style: italic; }
.rai-delivery .rwi-reset {
  margin-top: 6px;
  align-self: flex-start;
  padding: 5px 10px;
}
.rai-delivery .rwi-result {
  padding: 18px;
  background: var(--surface-page);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  display: flex; flex-direction: column; gap: 14px;
}
.rai-delivery .rwi-impact {
  text-align: center;
  padding: 14px 16px;
  background: linear-gradient(135deg, var(--brand-soft) 0%, transparent 100%);
  border: 1px solid rgba(251,95,44,.18);
  border-radius: var(--radius-md);
}
.rai-delivery .rwi-imp-lbl {
  font: 700 10px var(--font-mono);
  letter-spacing: .12em;
  color: var(--fg-3);
}
.rai-delivery .rwi-imp-val {
  font: 600 34px var(--font-mono);
  letter-spacing: -.025em;
  font-variant-numeric: tabular-nums;
  margin-top: 4px;
}
.rai-delivery .rwi-imp-val.up { color: var(--success); }
.rai-delivery .rwi-imp-val.down { color: var(--danger); }
.rai-delivery .rwi-imp-pct {
  font: 500 12px var(--font-mono);
  color: var(--fg-3);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rwi-compare {
  display: grid; grid-template-columns: 1fr 1fr; gap: 14px;
}
.rai-delivery .rwi-col { display: flex; flex-direction: column; gap: 4px; }
.rai-delivery .rwic-head {
  font: 700 10px var(--font-mono);
  letter-spacing: .12em;
  color: var(--fg-3);
  padding-bottom: 6px;
  margin-bottom: 4px;
  border-bottom: 1px solid var(--divider);
}
.rai-delivery .rwic-row {
  display: flex; justify-content: space-between;
  font: 500 11.5px var(--font-mono);
  font-variant-numeric: tabular-nums;
  padding: 4px 0;
}
.rai-delivery .rwic-row > span:first-child { color: var(--fg-3); font-family: var(--font-ui); font-weight: 500; }
.rai-delivery .rwic-row > span:last-child { color: var(--fg-1); }
.rai-delivery .rwic-final { padding-top: 8px; border-top: 1px solid var(--divider); font-weight: 700; }
.rai-delivery .rwi-col-new .rwic-row > span:last-child { color: var(--fg-1); }
.rai-delivery .rsec-exec {
  background: linear-gradient(135deg, var(--surface-1) 0%, rgba(108,169,242,.04) 100%);
}
.rai-delivery .rexec-heroes {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin: 18px 0;
  padding: 18px;
  background: var(--surface-page);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
}
.rai-delivery .rexec-hero { display: flex; flex-direction: column; gap: 4px; }
.rai-delivery .reh-val {
  font: 600 30px var(--font-mono);
  letter-spacing: -.022em;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .reh-lbl {
  font: 700 9.5px var(--font-mono);
  letter-spacing: .14em;
  color: var(--fg-muted);
}
.rai-delivery .reh-delta {
  font: 600 11px var(--font-mono);
  font-variant-numeric: tabular-nums;
  margin-top: 2px;
}
.rai-delivery .reh-delta.up { color: var(--success); }
.rai-delivery .reh-delta.down { color: var(--danger); }
.rai-delivery .rexec-wins {
  padding: 18px 22px;
  background: var(--success-bg);
  border: 1px solid rgba(79,180,119,.3);
  border-radius: var(--radius-md);
}
.rai-delivery .rexec-wins-head {
  display: flex; align-items: center; gap: 8px;
  font: 700 11px var(--font-mono);
  letter-spacing: .12em;
  color: var(--success);
  margin-bottom: 10px;
}
.rai-delivery .rexec-wins-list {
  margin: 0; padding: 0;
  list-style: none;
  display: flex; flex-direction: column; gap: 6px;
}
.rai-delivery .rexec-wins-list li {
  font: 400 13px var(--font-ui);
  color: var(--fg-1);
  line-height: 1.55;
}
.rai-delivery .rexec-wins-list li strong { color: var(--success); margin-right: 4px; font-weight: 700; }
.rai-delivery .reports-shell {
  display: flex; flex-direction: column;
  min-height: calc(100vh - 56px);
  margin: 0;
  padding: 0;
}
.rai-delivery .reports-actionbar {
  display: flex; align-items: flex-start; justify-content: space-between;
  padding: 22px 28px 18px;
  gap: 20px;
  border-bottom: 1px solid var(--border-default);
  background: var(--surface-page);
}
.rai-delivery .reports-actionbar h1 {
  font: 600 24px var(--font-ui);
  color: var(--fg-1);
  letter-spacing: -.014em;
  margin: 0;
}
.rai-delivery .reports-actionbar .sub {
  font: 400 12.5px var(--font-ui);
  color: var(--fg-3);
  margin: 0;
}
.rai-delivery .reports-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.rai-delivery .reports-body {
  display: grid;
  grid-template-columns: 300px 1fr;
  flex: 1;
  min-height: 0;
}
.rai-delivery .reports-rail {
  background: var(--surface-1);
  border-right: 1px solid var(--border-default);
  padding: 18px 16px 22px;
  overflow-y: auto;
}
.rai-delivery .rrail-section {
  display: flex; flex-direction: column; gap: 8px;
  padding-bottom: 18px;
  margin-bottom: 14px;
  border-bottom: 1px solid var(--divider);
}
.rai-delivery .rrail-section:last-of-type { border-bottom: 0; }
.rai-delivery .rrail-label {
  font: 600 10px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--fg-3);
}
.rai-delivery .rrail-clients { display: flex; flex-direction: column; gap: 4px; }
.rai-delivery .rrail-client {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 10px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 8px;
  cursor: pointer;
  color: var(--fg-2);
  transition: all var(--dur-fast) var(--ease-out);
  text-align: left;
  width: 100%;
}
.rai-delivery .rrail-client:hover { background: var(--surface-2); color: var(--fg-1); }
.rai-delivery .rrail-client.on {
  background: var(--brand-soft);
  border-color: rgba(251,95,44,.2);
}
.rai-delivery .rrail-client svg { color: var(--brand); flex-shrink: 0; }
.rai-delivery .rrail-client .client-mark {
  width: 28px; height: 28px;
  border-radius: 7px;
  display: flex; align-items: center; justify-content: center;
  font: 700 12px var(--font-ui);
  flex-shrink: 0;
}
.rai-delivery .rc-name { font: 600 13px var(--font-ui); color: var(--fg-1); }
.rai-delivery .rc-on .rc-name { color: var(--brand); }
.rai-delivery .rc-meta { font: 400 10.5px var(--font-mono); color: var(--fg-3); font-variant-numeric: tabular-nums; }
.rai-delivery .rrail-select {
  background: var(--surface-page);
  border: 1px solid var(--border-default);
  border-radius: 8px;
  color: var(--fg-1);
  padding: 8px 12px;
  font: 500 12.5px var(--font-ui);
  cursor: pointer;
  outline: none;
}
.rai-delivery .rrail-select:focus { border-color: var(--brand); }
.rai-delivery .rrail-sections { display: flex; flex-direction: column; gap: 4px; }
.rai-delivery .rrail-checkbox {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 8px;
  border-radius: 6px;
  cursor: pointer;
  font: 500 12px var(--font-ui);
  color: var(--fg-2);
}
.rai-delivery .rrail-checkbox:hover { background: var(--surface-2); color: var(--fg-1); }
.rai-delivery .rrail-checkbox.locked { opacity: 0.7; cursor: default; }
.rai-delivery .rrail-checkbox.locked:hover { background: transparent; }
.rai-delivery .rrail-checkbox input { margin: 0; accent-color: var(--brand); }
.rai-delivery .rrail-checkbox > span { flex: 1; }
.rai-delivery .rrail-locked {
  font: 600 9px var(--font-mono);
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--fg-muted);
}
.rai-delivery .rrail-seg.seg { width: 100%; }
.rai-delivery .rrail-seg.seg button { flex: 1; }
.rai-delivery .rrail-tip {
  display: flex; gap: 8px;
  padding: 10px 12px;
  background: var(--brand-soft);
  border: 1px solid rgba(251,95,44,.18);
  border-radius: 8px;
  font: 400 11px var(--font-ui);
  color: var(--fg-2);
  line-height: 1.45;
}
.rai-delivery .rrail-tip svg { color: var(--brand); flex-shrink: 0; margin-top: 2px; }
.rai-delivery .reports-preview {
  background: var(--ink-50);
  padding: 24px 32px 60px;
  overflow-y: auto;
}
.rai-delivery .rprev-meta {
  display: flex; align-items: baseline; justify-content: space-between;
  margin-bottom: 14px;
  padding: 0 4px;
}
.rai-delivery .rprev-meta-lbl {
  font: 600 9.5px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--fg-muted);
}
.rai-delivery .rprev-meta-pages {
  font: 500 11px var(--font-mono);
  color: var(--fg-muted);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rdoc {
  max-width: 820px;
  margin: 0 auto;
  display: flex; flex-direction: column;
  gap: 16px;
}
.rai-delivery .rsec {
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 12px;
  padding: 34px 38px;
  position: relative;
}
.rai-delivery .rsec-eyebrow {
  position: absolute; top: 24px; right: 28px;
  font: 700 9.5px var(--font-mono);
  color: var(--fg-muted);
  letter-spacing: .12em;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rsec-title {
  font: 600 22px var(--font-ui);
  color: var(--fg-1);
  letter-spacing: -.018em;
  margin: 0 0 12px;
}
.rai-delivery .rsec-lead {
  font: 400 14px var(--font-ui);
  color: var(--fg-2);
  line-height: 1.6;
  margin: 0 0 20px;
  max-width: 720px;
}
.rai-delivery .rsec-cover {
  min-height: 360px;
  display: flex; flex-direction: column; justify-content: space-between;
  border: 1px solid var(--border-default);
}
.rai-delivery .cov-brand {
  display: flex; align-items: center; gap: 14px;
}
.rai-delivery .cov-mark {
  width: 56px; height: 56px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font: 700 24px var(--font-ui);
  color: white;
  letter-spacing: -.01em;
  box-shadow: 0 12px 28px -10px rgba(0,0,0,.5);
}
.rai-delivery .cov-overline {
  font: 600 11px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .14em;
  color: var(--fg-2);
}
.rai-delivery .cov-title-block { padding: 60px 0 30px; }
.rai-delivery .cov-title-eyebrow {
  font: 600 11px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--fg-3);
  margin-bottom: 12px;
}
.rai-delivery .cov-title {
  font: 600 64px var(--font-ui);
  color: var(--fg-1);
  letter-spacing: -.028em;
  line-height: 1.0;
  margin: 0;
  font-style: italic;
}
.rai-delivery .cov-subtitle {
  font: 400 16px var(--font-ui);
  color: var(--fg-2);
  margin-top: 16px;
}
.rai-delivery .cov-foot {
  display: flex; gap: 60px;
  padding-top: 24px;
  border-top: 1px solid var(--border-subtle);
}
.rai-delivery .cov-foot-block { display: flex; flex-direction: column; gap: 4px; }
.rai-delivery .cov-foot-lbl {
  font: 600 9.5px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--fg-3);
}
.rai-delivery .cov-foot-val {
  font: 500 13px var(--font-mono);
  color: var(--fg-1);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rsec-headline-band {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--divider);
}
.rai-delivery .rsec-hk { display: flex; flex-direction: column; gap: 4px; }
.rai-delivery .rsec-hk-dot { width: 10px; height: 10px; border-radius: 3px; }
.rai-delivery .rsec-hk-lbl {
  font: 600 9.5px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--fg-3);
}
.rai-delivery .rsec-hk-val {
  font: 600 22px var(--font-mono);
  color: var(--fg-1);
  font-variant-numeric: tabular-nums;
  letter-spacing: -.018em;
}
.rai-delivery .rsec-kpi-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.rai-delivery .rkpi {
  padding: 18px 18px 16px;
  background: var(--surface-page);
  border-right: 1px solid var(--divider);
  border-bottom: 1px solid var(--divider);
  display: flex; flex-direction: column; gap: 6px;
}
.rai-delivery .rkpi:nth-child(3n) { border-right: 0; }
.rai-delivery .rkpi:nth-last-child(-n+3) { border-bottom: 0; }
.rai-delivery .rkpi-lbl {
  font: 600 9.5px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--fg-3);
  display: flex; align-items: center; gap: 6px;
}
.rai-delivery .rkpi-dot { width: 7px; height: 7px; border-radius: 50%; }
.rai-delivery .rkpi-val {
  font: 600 26px var(--font-mono);
  color: var(--fg-1);
  letter-spacing: -.02em;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rkpi-foot {
  display: flex; gap: 6px; align-items: baseline;
  font: 500 10.5px var(--font-mono);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rkpi-delta.up { color: var(--success); font-weight: 600; }
.rai-delivery .rkpi-delta.down { color: var(--danger); font-weight: 600; }
.rai-delivery .rkpi-delta.neutral { color: var(--fg-3); }
.rai-delivery .rkpi-vs { color: var(--fg-muted); }
.rai-delivery .rkpi-spark { margin-top: 4px; }
.rai-delivery .rsec-chart-legend {
  display: flex; gap: 16px;
  padding-top: 12px;
  font: 500 11.5px var(--font-ui);
  color: var(--fg-3);
}
.rai-delivery .rsec-chart-legend > span { display: inline-flex; align-items: center; gap: 6px; }
.rai-delivery .rcl-dot { width: 10px; height: 10px; border-radius: 2px; }
.rai-delivery .rcl-line {
  display: inline-block; width: 16px; height: 2px;
  border-radius: 999px;
}
.rai-delivery .rpnl-table {
  display: grid;
  grid-template-columns: 1.8fr 110px 70px 1fr;
  gap: 0;
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.rai-delivery .rpnl-row { display: contents; }
.rai-delivery .rpnl-row > div {
  padding: 10px 14px;
  border-top: 1px solid var(--divider);
  display: flex; align-items: center;
  font: 400 12.5px var(--font-ui);
  color: var(--fg-2);
}
.rai-delivery .rpnl-row.is-sub > div { background: var(--surface-page); color: var(--fg-1); }
.rai-delivery .rpnl-row.is-final > div { background: rgba(79,180,119,.08); color: var(--fg-1); }
.rai-delivery .rpnl-row:first-child > div { border-top: 0; }
.rai-delivery .rpnl-val, .rai-delivery .rpnl-pct {
  justify-content: flex-end;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  color: var(--fg-1);
}
.rai-delivery .rpnl-bar { padding: 10px 14px; }
.rai-delivery .rpnl-bar-fill {
  display: block;
  height: 6px;
  border-radius: 999px;
}
.rai-delivery .rsec-mkt-grid {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 20px;
  align-items: center;
}
.rai-delivery .rsec-mkt-hero {
  display: flex; flex-direction: column; gap: 18px;
}
.rai-delivery .rmh-lbl {
  font: 600 9.5px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--fg-3);
}
.rai-delivery .rmh-val {
  font: 600 28px var(--font-mono);
  color: var(--fg-1);
  letter-spacing: -.02em;
  font-variant-numeric: tabular-nums;
  line-height: 1.05;
}
.rai-delivery .rmh-sub { font: 400 11px var(--font-ui); color: var(--fg-3); margin-top: 3px; }
.rai-delivery .rsec-promos {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
.rai-delivery .rpromo {
  padding: 14px 14px 12px;
  background: var(--surface-page);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
}
.rai-delivery .rpromo-head {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  margin-bottom: 8px;
}
.rai-delivery .rpromo-loc {
  font: 500 10.5px var(--font-mono);
  color: var(--fg-muted);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rpromo-title {
  font: 600 13.5px var(--font-ui);
  color: var(--fg-1);
  margin-bottom: 8px;
}
.rai-delivery .rpromo-ai {
  display: flex; gap: 6px;
  padding-top: 8px;
  border-top: 1px dashed var(--border-default);
  font: 400 11.5px var(--font-ui);
  color: var(--fg-2);
  line-height: 1.5;
}
.rai-delivery .rpromo-ai svg { color: var(--brand); flex-shrink: 0; margin-top: 2px; }
.rai-delivery .rsec-twoup {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
}
.rai-delivery .rwlist { display: flex; flex-direction: column; gap: 12px; }
.rai-delivery .rwitem {
  display: flex; gap: 10px;
  padding: 10px 12px;
  background: var(--surface-page);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
}
.rai-delivery .rwi-check, .rai-delivery .rwi-flag {
  width: 22px; height: 22px;
  border-radius: 6px;
  display: inline-flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.rai-delivery .rwi-check { background: var(--success-bg); color: var(--success); }
.rai-delivery .rwi-flag { background: var(--warning-bg); color: var(--warning); }
.rai-delivery .rwi-title { font: 600 13px var(--font-ui); color: var(--fg-1); margin-bottom: 2px; }
.rai-delivery .rwi-desc { font: 400 12px var(--font-ui); color: var(--fg-3); line-height: 1.5; }
.rai-delivery .rplan-list { display: flex; flex-direction: column; gap: 10px; }
.rai-delivery .rplan-item {
  display: grid;
  grid-template-columns: 36px 1fr;
  gap: 14px;
  padding: 14px 16px;
  background: var(--surface-page);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
}
.rai-delivery .rplan-item.tag-priority { border-left: 3px solid var(--danger); }
.rai-delivery .rplan-item.tag-opportunity { border-left: 3px solid var(--brand); }
.rai-delivery .rplan-item.tag-standard { border-left: 3px solid var(--ink-400); }
.rai-delivery .rplan-num {
  font: 700 13px var(--font-mono);
  color: var(--fg-3);
  background: var(--surface-2);
  border-radius: 6px;
  width: 30px; height: 30px;
  display: flex; align-items: center; justify-content: center;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .rplan-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin-bottom: 4px;
}
.rai-delivery .rplan-title { font: 600 13.5px var(--font-ui); color: var(--fg-1); }
.rai-delivery .rplan-tag {
  font: 700 9px var(--font-mono);
  text-transform: uppercase;
  letter-spacing: .08em;
  padding: 2px 7px;
  border-radius: 999px;
}
.rai-delivery .rplan-tag.tag-priority { background: var(--danger-bg); color: var(--danger); }
.rai-delivery .rplan-tag.tag-opportunity { background: var(--brand-soft); color: var(--brand); }
.rai-delivery .rplan-tag.tag-standard { background: var(--surface-2); color: var(--fg-3); }
.rai-delivery .rplan-desc { font: 400 12px var(--font-ui); color: var(--fg-3); line-height: 1.5; }
.rai-delivery .rsec-footer {
  background: linear-gradient(135deg, var(--surface-1) 0%, var(--ink-150) 100%);
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 28px;
  align-items: center;
  padding: 24px 38px;
}
.rai-delivery .rfoot-mark { display: flex; align-items: center; gap: 12px; }
.rai-delivery .rfoot-mark img { width: 36px; height: 36px; border-radius: 8px; object-fit: cover; }
.rai-delivery .rfoot-brand { font: 700 14px var(--font-ui); color: var(--fg-1); letter-spacing: -.01em; }
.rai-delivery .rfoot-sub { font: 500 10.5px var(--font-mono); color: var(--fg-3); margin-top: 1px; }
.rai-delivery .rfoot-contact { display: flex; flex-direction: column; gap: 4px; }
.rai-delivery .rfoot-contact-row {
  display: flex; gap: 10px;
  font: 500 11px var(--font-ui);
  font-variant-numeric: tabular-nums;
  font-family: var(--font-mono);
}
.rai-delivery .rfc-lbl {
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: .08em;
  font-size: 9.5px;
  width: 100px;
}
.rai-delivery .rfc-val { color: var(--fg-1); }
.rai-delivery .rfoot-note {
  font: 400 10.5px var(--font-ui);
  color: var(--fg-muted);
  font-style: italic;
  line-height: 1.5;
  max-width: 280px;
  text-align: right;
}
.rai-delivery .rsec-empty {
  display: flex; align-items: center; gap: 10px;
  padding: 20px 0;
  font: 500 12.5px var(--font-ui);
  color: var(--fg-3);
}
.rai-delivery .rsec-empty svg { color: var(--fg-muted); flex-shrink: 0; }
.rai-delivery .page:has(.reports-shell) { padding: 0; max-width: none; }
.rai-delivery .cust-controls {
  display: flex; align-items: center; gap: 14px;
  margin-top: 12px;
  flex-wrap: wrap;
}
.rai-delivery .cust-search {
  position: relative;
  flex: 1; min-width: 280px;
  max-width: 460px;
}
.rai-delivery .cust-search svg {
  position: absolute; left: 12px; top: 50%; transform: translateY(-50%);
  color: var(--fg-muted);
}
.rai-delivery .cust-search input {
  width: 100%; box-sizing: border-box;
  padding: 10px 32px 10px 34px;
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 8px;
  color: var(--fg-1);
  font: 400 13px var(--font-ui);
  outline: none;
  transition: border-color var(--dur-fast) var(--ease-out);
}
.rai-delivery .cust-search input:focus { border-color: var(--brand); }
.rai-delivery .cust-search input::placeholder { color: var(--fg-3); }
.rai-delivery .cust-search-clear {
  position: absolute; right: 8px; top: 50%; transform: translateY(-50%);
  background: var(--surface-3);
  border: 0;
  color: var(--fg-2);
  width: 20px; height: 20px;
  border-radius: 50%;
  cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
}
.rai-delivery .cust-search-clear:hover { background: var(--surface-hover); color: var(--fg-1); }
.rai-delivery .cust2-table {
  display: grid;
  grid-template-columns: 36px 1.8fr 90px 60px 90px 110px 90px 110px 130px;
  width: 100%;
}
.rai-delivery .cust2-row { display: contents; }
.rai-delivery .cust2-row > div {
  padding: 14px 12px;
  border-top: 1px solid var(--divider);
  display: flex; align-items: center;
  font: 400 12.5px var(--font-ui);
  color: var(--fg-2);
}
.rai-delivery .cust2-row > div.num {
  justify-content: flex-end;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  color: var(--fg-1);
}
.rai-delivery .cust2-row.cust2-head > div {
  border-top: 0;
  border-bottom: 1px solid var(--divider);
  background: var(--surface-page);
  font: 600 10px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--fg-3);
  padding-top: 12px; padding-bottom: 12px;
}
.rai-delivery .cust2-row.cust2-data { cursor: pointer; transition: background var(--dur-fast) var(--ease-out); }
.rai-delivery .cust2-row.cust2-data:hover > div { background: var(--surface-2); }
.rai-delivery .cust2-row.cust2-data.expanded > div {
  background: var(--brand-soft);
  border-bottom: 1px solid rgba(251,95,44,.18);
}
.rai-delivery .cust2-chev { color: var(--fg-3); justify-content: center; transition: transform var(--dur-fast) var(--ease-out); }
.rai-delivery .cust2-row.cust2-data.expanded .cust2-chev { color: var(--brand); }
.rai-delivery .cust2-row.cust2-data:not(.expanded) .cust2-chev svg { transform: rotate(-90deg); }
.rai-delivery .cust2-client { display: flex; align-items: center; gap: 12px; }
.rai-delivery .cust2-client .client-mark {
  width: 30px; height: 30px;
  border-radius: 7px;
  display: flex; align-items: center; justify-content: center;
  font: 700 12px var(--font-ui);
  flex-shrink: 0;
}
.rai-delivery .cust2-name { font: 600 13px var(--font-ui); color: var(--fg-1); }
.rai-delivery .cust2-sub { font: 400 10.5px var(--font-mono); color: var(--fg-3); margin-top: 1px; font-variant-numeric: tabular-nums; }
.rai-delivery .health-badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 9px 4px 8px;
  border-radius: 999px;
  font: 600 11px var(--font-ui);
  letter-spacing: -.005em;
}
.rai-delivery .health-badge .hb-dot { width: 6px; height: 6px; border-radius: 50%; }
.rai-delivery .health-badge .hb-score {
  font: 600 10px var(--font-mono);
  font-variant-numeric: tabular-nums;
  background: rgba(255,255,255,.08);
  padding: 1px 6px;
  border-radius: 999px;
  margin-left: 2px;
  opacity: 0.85;
}
.rai-delivery .cust2-detail {
  grid-column: 1 / -1;
  background: var(--surface-page);
  padding: 20px 22px 22px;
  border-top: 1px solid var(--divider);
  border-bottom: 1px solid var(--divider);
}
.rai-delivery .cdetail-card {
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.rai-delivery .cdetail-card-head {
  padding: 11px 16px;
  border-bottom: 1px solid var(--divider);
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px;
  background: var(--surface-page);
}
.rai-delivery .cdetail-eyebrow {
  font: 600 10px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--fg-3);
}
.rai-delivery .cdetail-meta {
  font: 500 11px var(--font-mono);
  color: var(--fg-muted);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .cdetail-padded { padding: 14px 16px 16px; }
.rai-delivery .loc-mini-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px;
  padding: 12px 14px 14px;
}
.rai-delivery .loc-mini {
  background: var(--surface-page);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 12px 12px 10px;
}
.rai-delivery .lmini-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.rai-delivery .lmini-name { font: 600 13px var(--font-ui); color: var(--fg-1); }
.rai-delivery .lmini-city { font: 400 10.5px var(--font-mono); color: var(--fg-3); margin-top: 1px; }
.rai-delivery .lmini-stats {
  display: grid; grid-template-columns: 1fr 1fr; gap: 10px 12px;
}
.rai-delivery .lmini-stat { display: flex; flex-direction: column; gap: 1px; }
.rai-delivery .ls-lbl {
  font: 600 8.5px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--fg-muted);
}
.rai-delivery .ls-val {
  font: 500 17px var(--font-mono);
  color: var(--fg-1);
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
  letter-spacing: -.01em;
}
.rai-delivery .ls-delta {
  font: 500 10px var(--font-mono);
  color: var(--fg-3);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .ls-delta.up { color: var(--success); }
.rai-delivery .ls-delta.down { color: var(--danger); }
.rai-delivery .ls-delta.muted { color: var(--fg-muted); }
.rai-delivery .cdetail-bignum {
  display: flex; flex-direction: column; gap: 2px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--divider);
}
.rai-delivery .cb-val {
  font: 600 30px var(--font-mono);
  color: var(--success);
  letter-spacing: -.02em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .cb-sub { font: 400 11px var(--font-ui); color: var(--fg-3); }
.rai-delivery .cdetail-grid2 {
  display: grid; grid-template-columns: 1fr 1fr; gap: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--divider);
}
.rai-delivery .cdetail-grid2 > div { display: flex; flex-direction: column; gap: 2px; }
.rai-delivery .health-hero {
  display: flex; align-items: center; gap: 16px;
  padding-bottom: 14px;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--divider);
}
.rai-delivery .health-drivers { display: flex; flex-direction: column; gap: 8px; }
.rai-delivery .health-driver {
  display: grid; grid-template-columns: 78px 1fr 50px;
  align-items: center; gap: 10px;
}
.rai-delivery .hd-lbl { font: 500 11px var(--font-ui); color: var(--fg-2); }
.rai-delivery .hd-bar {
  height: 6px;
  background: var(--surface-3);
  border-radius: 999px;
  overflow: hidden;
}
.rai-delivery .hd-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--brand) 0%, var(--brand) 100%);
  border-radius: 999px;
}
.rai-delivery .hd-val {
  font: 500 11px var(--font-mono);
  color: var(--fg-3);
  font-variant-numeric: tabular-nums;
  text-align: right;
}
.rai-delivery .campaign-mini-list { display: flex; flex-direction: column; gap: 0; }
.rai-delivery .cmini-row {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid var(--divider);
  font: 400 12px var(--font-ui);
  color: var(--fg-2);
}
.rai-delivery .cmini-row:last-child { border-bottom: 0; }
.rai-delivery .cmini-title { flex: 1; color: var(--fg-1); font-weight: 500; }
.rai-delivery .cmini-loc {
  font: 500 10.5px var(--font-mono);
  color: var(--fg-muted);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .cmini-more {
  font: 400 11px var(--font-ui);
  color: var(--fg-3);
  padding: 8px 0 4px;
  font-style: italic;
}
.rai-delivery .cmini-cta {
  margin-top: 8px;
  padding: 6px 10px;
  font: 500 12px var(--font-ui);
  color: var(--brand);
}
.rai-delivery .cmini-cta:hover { background: var(--brand-soft); }
.rai-delivery .cmini-cta svg { color: var(--brand); }
.rai-delivery .activity-list { display: flex; flex-direction: column; gap: 0; }
.rai-delivery .activity-item {
  display: flex; align-items: center; justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px solid var(--divider);
  font: 500 12px var(--font-ui);
  gap: 12px;
}
.rai-delivery .activity-item:last-child { border-bottom: 0; }
.rai-delivery .ai-lbl { color: var(--fg-3); }
.rai-delivery .ai-val { color: var(--fg-1); font-weight: 500; text-align: right; }
.rai-delivery .ai-val.muted {
  color: var(--fg-muted);
  font-style: italic;
  font-weight: 400;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-size: 11.5px;
}
.rai-delivery .cdetail-empty {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 8px 0;
}
.rai-delivery .cdetail-empty svg { color: var(--fg-muted); flex-shrink: 0; margin-top: 2px; }
.rai-delivery .cdetail-actions .cdetail-padded { padding: 12px 14px 14px; }
.rai-delivery .qa-btn {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px;
  background: var(--surface-page);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  color: var(--fg-2);
  cursor: pointer;
  text-align: left;
  width: 100%;
  transition: all var(--dur-fast) var(--ease-out);
}
.rai-delivery .qa-btn:hover {
  background: var(--surface-2);
  border-color: var(--border-default);
  color: var(--fg-1);
}
.rai-delivery .qa-btn.qa-primary {
  background: var(--brand-soft);
  border-color: rgba(251,95,44,.18);
}
.rai-delivery .qa-btn.qa-primary svg { color: var(--brand); }
.rai-delivery .qa-btn.qa-primary:hover { background: rgba(251,95,44,.16); }
.rai-delivery .qa-btn > span:nth-child(2) {
  flex: 1;
  display: flex; flex-direction: column; gap: 1px;
}
.rai-delivery .qa-title { font: 600 12.5px var(--font-ui); color: var(--fg-1); }
.rai-delivery .qa-sub { font: 400 10.5px var(--font-mono); color: var(--fg-3); font-variant-numeric: tabular-nums; }
.rai-delivery .qa-btn.qa-primary .qa-title { color: var(--brand); }
.rai-delivery .qa-btn svg:first-child { color: var(--fg-muted); }
.rai-delivery .qa-btn.qa-primary svg:first-child { color: var(--brand); }
.rai-delivery .qa-btn > svg:last-child { color: var(--fg-muted); opacity: 0.6; }
.rai-delivery .promo-group {
  border-top: 1px solid var(--divider);
}
.rai-delivery .promo-group:first-of-type { border-top: 0; }
.rai-delivery .promo-group-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 20px;
  background: var(--surface-page);
  border-bottom: 1px solid var(--divider);
}
.rai-delivery .pgh-name { display: flex; align-items: center; gap: 12px; }
.rai-delivery .pgh-name .client-mark {
  width: 30px; height: 30px;
  border-radius: 7px;
  display: flex; align-items: center; justify-content: center;
  font: 700 12px var(--font-ui);
}
.rai-delivery .pgh-name .pgh-title {
  font: 600 14px var(--font-ui);
  color: var(--fg-1);
}
.rai-delivery .pgh-name .pgh-sub {
  font: 400 11px var(--font-mono);
  color: var(--fg-3);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .promo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 12px;
  padding: 14px 20px 20px;
}
.rai-delivery .promo-card {
  display: flex; flex-direction: column; gap: 6px;
  padding: 14px 14px 12px;
  background: var(--surface-page);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
}
.rai-delivery .promo-card .promo-head {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  margin-bottom: 2px;
}
.rai-delivery .promo-card .promo-type {
  font: 700 9.5px var(--font-mono);
  text-transform: uppercase;
  letter-spacing: .08em;
  padding: 3px 7px;
  border-radius: 4px;
  background: var(--surface-3);
  color: var(--fg-2);
}
.rai-delivery .promo-card .promo-type.type-bogo {
  background: rgba(108,169,242,.14);
  color: #6CA9F2;
}
.rai-delivery .promo-card .promo-type.type-spend {
  background: rgba(244,169,58,.14);
  color: #F4A93A;
}
.rai-delivery .promo-card .promo-loc {
  font: 500 10.5px var(--font-mono);
  color: var(--fg-muted);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .promo-card .promo-title {
  font: 600 13.5px var(--font-ui);
  color: var(--fg-1);
  letter-spacing: -.005em;
}
.rai-delivery .promo-card .promo-meta {
  font: 400 11.5px var(--font-ui);
  color: var(--fg-3);
}
.rai-delivery .promo-card .promo-meta .promo-target {
  color: var(--fg-muted);
  margin-left: 2px;
}
.rai-delivery .promo-card .promo-ai {
  margin-top: 8px;
  padding-top: 10px;
  border-top: 1px dashed var(--border-default);
}
.rai-delivery .promo-card .promo-ai-head {
  display: flex; align-items: center; gap: 6px;
  margin-bottom: 4px;
}
.rai-delivery .promo-card .promo-ai-head svg { color: var(--brand); }
.rai-delivery .promo-card .promo-ai-text {
  font: 400 11.5px var(--font-ui);
  color: var(--fg-2);
  line-height: 1.5;
}
.rai-delivery .promo-tag {
  font: 700 9.5px var(--font-mono);
  text-transform: uppercase;
  letter-spacing: .06em;
  padding: 2px 8px;
  border-radius: 999px;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .promo-tag.tg-ok { background: var(--success-bg); color: var(--success); }
.rai-delivery .promo-tag.tg-info { background: rgba(108,169,242,.14); color: #6CA9F2; }
.rai-delivery .promo-tag.tg-warn { background: var(--warning-bg); color: var(--warning); }
.rai-delivery .promo-tag.tg-crit { background: var(--danger-bg);  color: var(--danger); }
.rai-delivery .promo-empty {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 20px;
  background: var(--surface-page);
  border-top: 1px solid var(--divider);
  font: 500 12.5px var(--font-ui);
  color: var(--fg-3);
}
.rai-delivery .promo-empty svg { color: var(--warning); flex-shrink: 0; }
.rai-delivery .promo-empty strong { color: var(--fg-1); }
.rai-delivery .promo-empty > span { flex: 1; }
.rai-delivery .adrec-row {
  padding: 16px 22px;
  border-bottom: 1px solid var(--divider);
}
.rai-delivery .adrec-row:last-child { border-bottom: 0; }
.rai-delivery .adrec-name { margin-bottom: 12px; }
.rai-delivery .adrec-loc {
  font: 600 14px var(--font-ui);
  color: var(--fg-1);
}
.rai-delivery .adrec-cli {
  font: 500 11px var(--font-mono);
  color: var(--fg-3);
  text-transform: uppercase;
  letter-spacing: .04em;
}
.rai-delivery .adrec-figs {
  display: flex; align-items: center; gap: 14px;
  padding: 10px 12px;
  background: var(--surface-page);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  margin-bottom: 12px;
}
.rai-delivery .adrec-figs svg { color: var(--fg-muted); flex-shrink: 0; }
.rai-delivery .adrec-fig {
  display: flex; flex-direction: column; gap: 1px;
}
.rai-delivery .adrec-fig .af-lbl {
  font: 600 9px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--fg-3);
}
.rai-delivery .adrec-fig .af-val {
  font: 600 18px var(--font-mono);
  color: var(--fg-1);
  font-variant-numeric: tabular-nums;
  letter-spacing: -.01em;
  display: flex; align-items: baseline; gap: 4px;
}
.rai-delivery .adrec-fig .af-val.af-lift { color: var(--success); }
.rai-delivery .adrec-fig .af-val .af-unit {
  font: 500 10.5px var(--font-mono);
  color: var(--fg-muted);
  font-weight: 400;
}
.rai-delivery .adrec-fig:last-child {
  margin-left: auto;
  text-align: right;
  align-items: flex-end;
}
.rai-delivery .adrec-fig:last-child .af-val { font-weight: 600; }
.rai-delivery .adrec-ai {
  padding-top: 10px;
  border-top: 1px dashed var(--border-default);
}
.rai-delivery .adrec-ai-head { display: flex; align-items: center; gap: 6px; margin-bottom: 4px; }
.rai-delivery .adrec-ai-head svg { color: var(--brand); }
.rai-delivery .adrec-ai-text {
  font: 400 12px var(--font-ui);
  color: var(--fg-2);
  line-height: 1.5;
}
.rai-delivery .q2-row {
  padding: 16px 22px;
  border-top: 1px solid var(--divider);
}
.rai-delivery .q2-row:first-of-type { border-top: 0; }
.rai-delivery .q2-head {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}
.rai-delivery .q2-title {
  font: 600 14px var(--font-ui);
  color: var(--fg-1);
  letter-spacing: -.005em;
}
.rai-delivery .q2-timing {
  font: 500 11px var(--font-mono);
  color: var(--fg-3);
  font-variant-numeric: tabular-nums;
  margin-top: 2px;
}
.rai-delivery .q2-tag {
  flex-shrink: 0;
  font: 700 9.5px var(--font-mono);
  text-transform: uppercase;
  letter-spacing: .06em;
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand);
}
.rai-delivery .q2-sum {
  font: 400 12px var(--font-ui);
  color: var(--fg-2);
  line-height: 1.5;
  margin-bottom: 8px;
}
.rai-delivery .q2-perks {
  display: flex; flex-wrap: wrap; gap: 5px;
  margin-bottom: 10px;
}
.rai-delivery .q2-perk {
  font: 500 10.5px var(--font-mono);
  color: var(--fg-2);
  background: var(--surface-2);
  border: 1px solid var(--border-subtle);
  padding: 2px 8px;
  border-radius: 999px;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .q2-ai {
  display: flex; align-items: flex-start; gap: 6px;
  padding-top: 8px;
  border-top: 1px dashed var(--border-default);
  font: 400 11.5px var(--font-ui);
  color: var(--fg-2);
  line-height: 1.5;
}
.rai-delivery .q2-ai svg { color: var(--brand); flex-shrink: 0; margin-top: 2px; }
.rai-delivery .q2-ai strong { color: var(--brand); font-weight: 600; }
.rai-delivery .mkt-legend {
  display: flex; flex-wrap: wrap; gap: 18px;
  padding-top: 14px; margin-top: 6px;
  border-top: 1px solid var(--divider);
  font: 500 12px var(--font-ui);
  color: var(--fg-2);
}
.rai-delivery .ml-item { display: inline-flex; align-items: center; gap: 8px; }
.rai-delivery .ml-dot { width: 10px; height: 10px; border-radius: 2px; }
.rai-delivery .ml-line {
  display: inline-block; width: 18px; height: 0;
  border-top: 2px dashed #4FB477;
}
.rai-delivery .ml-val {
  font: 600 12px var(--font-mono);
  color: var(--fg-1);
  font-variant-numeric: tabular-nums;
  margin-left: 2px;
}
.rai-delivery .mkteff-table {
  display: grid;
  grid-template-columns: 1.6fr 90px 100px 70px 80px 100px 110px 1fr;
  width: 100%;
}
.rai-delivery .me-row { display: contents; }
.rai-delivery .me-row > div {
  padding: 12px 12px;
  border-top: 1px solid var(--divider);
  display: flex; align-items: center;
  font: 400 12.5px var(--font-ui);
  color: var(--fg-2);
}
.rai-delivery .me-row > div.num {
  justify-content: flex-end;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  color: var(--fg-1);
}
.rai-delivery .me-row.me-head > div {
  border-top: 0;
  border-bottom: 1px solid var(--divider);
  background: var(--surface-page);
  font: 600 10px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--fg-3);
  padding-top: 12px; padding-bottom: 12px;
}
.rai-delivery .me-name { display: flex; align-items: center; gap: 10px; }
.rai-delivery .me-name .mk-dot {
  width: 10px; height: 10px;
  border-radius: 3px;
  flex-shrink: 0;
}
.rai-delivery .me-name .mn { font: 600 13px var(--font-ui); color: var(--fg-1); }
.rai-delivery .me-name .ms { font: 400 10.5px var(--font-mono); color: var(--fg-3); font-variant-numeric: tabular-nums; }
.rai-delivery .me-band {
  width: 100%;
  height: 8px;
  background: var(--surface-3);
  border-radius: 999px;
  overflow: hidden;
}
.rai-delivery .me-band-fill {
  height: 100%;
  border-radius: 999px;
  transition: width var(--dur-base) var(--ease-out);
}
.rai-delivery .me-band-fill.ok { background: linear-gradient(90deg, #4FB477, #2F9D5F); }
.rai-delivery .me-band-fill.warn { background: linear-gradient(90deg, #F4A93A, #DC8E1C); }
.rai-delivery .me-band-fill.crit { background: linear-gradient(90deg, #F26B5C, #E04A38); }
.rai-delivery .dp-legend {
  display: flex; gap: 16px;
  padding-bottom: 14px;
  margin-bottom: 6px;
  border-bottom: 1px solid var(--divider);
  font: 500 11px var(--font-ui);
  color: var(--fg-3);
}
.rai-delivery .dp-le { display: inline-flex; align-items: center; gap: 6px; }
.rai-delivery .dp-sw { width: 10px; height: 8px; border-radius: 2px; }
.rai-delivery .dp-row {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--divider);
  align-items: center;
}
.rai-delivery .dp-row:last-child { border-bottom: none; }
.rai-delivery .dp-name .dp-n { font: 500 12.5px var(--font-ui); color: var(--fg-1); }
.rai-delivery .dp-name .dp-s { font: 400 10.5px var(--font-mono); color: var(--fg-3); margin-top: 1px; }
.rai-delivery .dp-bar {
  position: relative;
  height: 28px;
  background: var(--surface-3);
  border-radius: 6px;
  overflow: hidden;
  display: flex;
}
.rai-delivery .dp-bar-del { background: var(--brand); height: 100%; }
.rai-delivery .dp-bar-pick { background: #998973; height: 100%; opacity: 0.7; }
.rai-delivery .dp-bar-val {
  position: absolute;
  inset: 0;
  display: flex; align-items: center; justify-content: center;
  font: 600 11px var(--font-mono);
  color: var(--fg-1);
  font-variant-numeric: tabular-nums;
  text-shadow: 0 1px 4px rgba(0,0,0,.4);
  letter-spacing: -.005em;
}
.rai-delivery .ops-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-top: 6px;
}
@media (max-width: 1100px) {
.rai-delivery .ops-grid { grid-template-columns: repeat(2, 1fr); }
}
.rai-delivery .ops-card { opacity: 0.92; }
.rai-delivery .ops-card h3 { color: var(--fg-2); font-weight: 500; }
.rai-delivery .ops-badge {
  font: 600 9px var(--font-mono);
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--fg-muted);
  background: var(--surface-2);
  border: 1px dashed var(--border-default);
  padding: 2px 7px;
  border-radius: 999px;
  margin-left: 4px;
}
.rai-delivery .ops-badge.live {
  color: #4FB477;
  background: color-mix(in oklch, #4FB477 14%, transparent);
  border: 1px solid color-mix(in oklch, #4FB477 40%, var(--border-default));
}
.rai-delivery .ops-big {
  display: flex; align-items: baseline; gap: 4px;
  padding-top: 8px;
}
.rai-delivery .ops-val {
  font: 500 38px var(--font-mono);
  color: var(--fg-3);
  letter-spacing: -.02em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .ops-unit {
  font: 500 14px var(--font-mono);
  color: var(--fg-muted);
}
.rai-delivery .ops-sub {
  font: 400 11.5px var(--font-ui);
  color: var(--fg-3);
  margin-top: 6px;
}
.rai-delivery .ops-bench {
  margin-top: 10px;
  font: 500 10.5px var(--font-mono);
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: .04em;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .ops-breakdown { display: flex; flex-direction: column; gap: 10px; padding-top: 8px; }
.rai-delivery .ops-br-row { display: grid; grid-template-columns: 130px 1fr 40px; align-items: center; gap: 10px; }
.rai-delivery .ops-br-lbl { font: 500 11.5px var(--font-ui); color: var(--fg-3); }
.rai-delivery .ops-br-bar { height: 6px; background: var(--surface-3); border-radius: 999px; overflow: hidden; }
.rai-delivery .ops-br-fill.ghost {
  height: 100%;
  width: 30%;
  background: repeating-linear-gradient(
    -45deg,
    var(--surface-3),
    var(--surface-3) 3px,
    var(--ink-300) 3px,
    var(--ink-300) 6px
  );
  border-radius: 999px;
}
.rai-delivery .ops-br-val { font: 500 11px var(--font-mono); color: var(--fg-muted); font-variant-numeric: tabular-nums; text-align: right; }
.rai-delivery .ops-list { display: flex; flex-direction: column; gap: 0; padding-top: 4px; }
.rai-delivery .ops-li {
  display: flex; align-items: center; justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px solid var(--divider);
  font: 500 12px var(--font-ui);
  color: var(--fg-3);
}
.rai-delivery .ops-li:last-child { border-bottom: 0; }
.rai-delivery .ops-li-v {
  font: 500 12px var(--font-mono);
  color: var(--fg-muted);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .ops-cta {
  margin-top: 18px;
  padding: 16px 22px;
  background: var(--surface-1);
  border: 1px dashed var(--border-default);
  border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: space-between;
  gap: 14px;
}
.rai-delivery .minfo { position: relative; display: inline-flex; align-items: center; margin-left: 6px; vertical-align: middle; }
.rai-delivery .minfo-trigger {
  background: transparent;
  border: 0;
  padding: 2px;
  cursor: pointer;
  color: var(--fg-muted);
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 50%;
  transition: all var(--dur-fast) var(--ease-out);
}
.rai-delivery .minfo-trigger:hover { color: var(--brand); background: var(--brand-soft); }
.rai-delivery .minfo-trigger svg { display: block; }
.rai-delivery .minfo-pop {
  position: absolute;
  top: calc(100% + 6px);
  width: 320px;
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 12px;
  box-shadow: 0 18px 44px rgba(0,0,0,.38), 0 2px 8px rgba(0,0,0,.2);
  padding: 0;
  z-index: 100;
  animation: minfo-in 140ms cubic-bezier(.2,.8,.2,1);
}
.rai-delivery .minfo-pop.align-left { left: -8px; }
.rai-delivery .minfo-pop.align-right { right: -8px; }
@keyframes minfo-in {
  from { opacity: 0; transform: translateY(-4px); }
  to   { opacity: 1; transform: translateY(0); }
}
.rai-delivery .minfo-head {
  padding: 14px 16px 10px;
  border-bottom: 1px solid var(--divider);
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
}
.rai-delivery .minfo-title {
  font: 600 13.5px var(--font-ui);
  color: var(--fg-1);
  letter-spacing: -.005em;
}
.rai-delivery .minfo-close {
  background: transparent;
  border: 0;
  color: var(--fg-muted);
  cursor: pointer;
  width: 22px; height: 22px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 5px;
  padding: 0;
}
.rai-delivery .minfo-close:hover { background: var(--surface-2); color: var(--fg-1); }
.rai-delivery .minfo-body { padding: 12px 16px 14px; }
.rai-delivery .minfo-def {
  font: 400 12.5px var(--font-ui);
  color: var(--fg-2);
  margin: 0 0 12px;
  line-height: 1.5;
}
.rai-delivery .minfo-formula {
  display: flex; flex-direction: column; gap: 4px;
  margin-bottom: 12px;
}
.rai-delivery .minfo-formula-lbl {
  font: 600 9px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--fg-muted);
}
.rai-delivery .minfo-formula code {
  font: 500 11.5px var(--font-mono);
  color: var(--fg-1);
  background: var(--surface-page);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  padding: 6px 10px;
  font-variant-numeric: tabular-nums;
  display: inline-block;
  align-self: flex-start;
}
.rai-delivery .minfo-bench {
  display: flex; flex-wrap: wrap; gap: 6px;
  align-items: center;
}
.rai-delivery .minfo-bench .mb {
  font: 600 10px var(--font-mono);
  padding: 2px 8px;
  border-radius: 999px;
  font-variant-numeric: tabular-nums;
}
.rai-delivery .minfo-bench .mb-ok { color: var(--success); background: var(--success-bg); }
.rai-delivery .minfo-bench .mb-warn { color: var(--warning); background: var(--warning-bg); }
.rai-delivery .minfo-bench .mb-crit { color: var(--danger);  background: var(--danger-bg); }
.rai-delivery .minfo-bench .mb-label {
  font: 500 10.5px var(--font-ui);
  color: var(--fg-muted);
  font-style: italic;
}
.rai-delivery .minfo-ai {
  display: flex; align-items: center; gap: 8px;
  width: calc(100% - 16px);
  margin: 0 8px 8px;
  padding: 9px 12px;
  background: var(--brand-soft);
  border: 1px solid rgba(251,95,44,.18);
  color: var(--brand);
  font: 600 12px var(--font-ui);
  border-radius: 8px;
  cursor: pointer;
  text-align: left;
  transition: all var(--dur-fast) var(--ease-out);
}
.rai-delivery .minfo-ai:hover { background: var(--brand); color: var(--fg-onbrand); border-color: var(--brand); }
.rai-delivery .minfo-ai svg { flex-shrink: 0; }
.rai-delivery .minfo-ai-arrow {
  margin-left: auto;
  font: 500 14px var(--font-mono);
  transition: transform var(--dur-fast) var(--ease-out);
}
.rai-delivery .minfo-ai:hover .minfo-ai-arrow { transform: translateX(2px); }
.rai-delivery .card-head h3 .minfo { font-weight: 400; }
.rai-delivery .kpi .lbl .minfo { margin-left: 4px; }
.rai-delivery .location-chips-row {
  display: flex; align-items: center; gap: 14px;
  margin-top: 10px;
  padding: 10px 14px;
  background: var(--surface-page);
  border: 1px dashed var(--border-default);
  border-radius: var(--radius-md);
}
.rai-delivery .loc-chips-label {
  display: inline-flex; align-items: center; gap: 6px;
  font: 600 10px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--fg-3);
  white-space: nowrap;
}
.rai-delivery .loc-chips-label svg { opacity: .6; }
.rai-delivery .location-chips {
  display: flex; flex-wrap: wrap; gap: 5px;
  flex: 1;
}
.rai-delivery .loc-chip-btn {
  display: inline-flex; align-items: center; gap: 6px;
  background: transparent;
  border: 1px solid var(--border-default);
  color: var(--fg-2);
  font: 500 11.5px var(--font-ui);
  padding: 4px 10px;
  border-radius: 999px;
  cursor: pointer;
  transition: all var(--dur-fast) var(--ease-out);
}
.rai-delivery .loc-chip-btn:hover { background: var(--surface-2); color: var(--fg-1); }
.rai-delivery .loc-chip-btn.on {
  background: var(--brand);
  border-color: var(--brand);
  color: var(--fg-onbrand);
}
.rai-delivery .loc-chip-btn.clear {
  color: var(--fg-3);
  border-style: dashed;
}
.rai-delivery .loc-chip-btn.clear:hover { color: var(--danger); border-color: var(--danger); }
.rai-delivery .waterfall-wrap { width: 100%; }
.rai-delivery .waterfall-foot {
  display: flex; flex-wrap: wrap; gap: 16px;
  padding-top: 16px; margin-top: 6px;
  border-top: 1px solid var(--divider);
  font: 500 11px var(--font-ui);
  color: var(--fg-3);
}
.rai-delivery .wf-foot-item { display: inline-flex; align-items: center; gap: 7px; }
.rai-delivery .wf-foot-dot { width: 10px; height: 10px; border-radius: 3px; }
.rai-delivery .cascade-table {
  display: grid;
  grid-template-columns: 2fr 110px 90px 200px 80px;
  width: 100%;
}
.rai-delivery .cascade-table.no-compare, .rai-delivery .cas-row:not(.cas-head):has(:nth-child(5):empty) ~ * {}
.rai-delivery .cas-row { display: contents; }
.rai-delivery .cas-row > div {
  padding: 11px 14px;
  border-top: 1px solid var(--divider);
  display: flex; align-items: center;
  font: 400 13px var(--font-ui);
  color: var(--fg-1);
}
.rai-delivery .cas-row > div.num {
  justify-content: flex-end;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}
.rai-delivery .cas-row.cas-head > div {
  border-top: 0;
  border-bottom: 1px solid var(--divider);
  background: var(--surface-page);
  font: 600 10px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--fg-3);
  padding-top: 12px; padding-bottom: 12px;
}
.rai-delivery .cas-row.is-final > div {
  background: linear-gradient(90deg, rgba(79,180,119,.06) 0%, transparent 80%);
  font-weight: 600;
}
.rai-delivery .cas-row.is-subtotal > div {
  background: var(--surface-page);
}
.rai-delivery .cas-bar {
  width: 100%; height: 6px;
  background: var(--surface-3);
  border-radius: 999px;
  overflow: hidden;
}
.rai-delivery .cas-bar-fill {
  height: 100%;
  border-radius: 999px;
}
.rai-delivery .pnl-table {
  display: grid;
  grid-template-columns: 2fr 80px 80px 80px 70px 80px 80px 80px 80px 80px;
  width: 100%;
}
.rai-delivery .pnl-row { display: contents; }
.rai-delivery .pnl-row > div {
  padding: 12px 12px;
  border-top: 1px solid var(--divider);
  display: flex; align-items: center;
  font: 400 12.5px var(--font-ui);
  color: var(--fg-2);
}
.rai-delivery .pnl-row > div.num {
  justify-content: flex-end;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  color: var(--fg-1);
}
.rai-delivery .pnl-row.pnl-head > div {
  border-top: 0;
  border-bottom: 1px solid var(--divider);
  background: var(--surface-page);
  font: 600 10px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--fg-3);
  padding-top: 12px; padding-bottom: 12px;
}
.rai-delivery .pnl-row.pnl-client { cursor: pointer; }
.rai-delivery .pnl-row.pnl-client:hover > div { background: var(--surface-2); }
.rai-delivery .pnl-row.pnl-client.expanded > div { background: var(--brand-soft); }
.rai-delivery .pnl-row.pnl-client.expanded > div.num { color: var(--fg-1); }
.rai-delivery .pnl-row.pnl-loc > div {
  background: var(--surface-page);
  font-size: 12px;
}
.rai-delivery .pnl-row.pnl-loc:hover > div { background: var(--surface-1); }
.rai-delivery .client-cell {
  display: flex; align-items: center; gap: 10px;
}
.rai-delivery .client-cell .chev {
  display: inline-flex; align-items: center; justify-content: center;
  width: 16px; height: 16px;
  color: var(--fg-3);
  transition: transform var(--dur-fast) var(--ease-out);
}
.rai-delivery .pnl-row.pnl-client.expanded .chev { transform: rotate(0deg); color: var(--brand); }
.rai-delivery .pnl-row.pnl-client:not(.expanded) .chev { transform: rotate(-90deg); }
.rai-delivery .client-cell .client-mark {
  width: 26px; height: 26px;
  border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
  font: 700 11px var(--font-ui);
  flex-shrink: 0;
}
.rai-delivery .client-cell .loc-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px;
  color: var(--fg-muted);
  background: var(--surface-2);
  border-radius: 5px;
  flex-shrink: 0;
}
.rai-delivery .client-cell .cn { font: 500 13px var(--font-ui); color: var(--fg-1); }
.rai-delivery .client-cell .cs { font: 400 10.5px var(--font-mono); color: var(--fg-3); font-variant-numeric: tabular-nums; }
.rai-delivery .takerate-hero {
  display: flex; flex-direction: column; gap: 4px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--divider);
  margin-bottom: 16px;
}
.rai-delivery .tr-val {
  font: 600 38px var(--font-mono);
  font-variant-numeric: tabular-nums;
  color: var(--brand);
  letter-spacing: -.025em;
  line-height: 1;
}
.rai-delivery .tr-sub { font: 400 12px var(--font-ui); color: var(--fg-3); }
.rai-delivery .tr-breakdown { display: flex; flex-direction: column; gap: 8px; margin-bottom: 18px; }
.rai-delivery .tr-row { display: flex; align-items: center; justify-content: space-between; }
.rai-delivery .tr-label { display: inline-flex; align-items: center; gap: 8px; font: 500 12px var(--font-ui); color: var(--fg-2); }
.rai-delivery .tr-dot { width: 8px; height: 8px; border-radius: 2px; }
.rai-delivery .tr-pct { font: 500 12px var(--font-mono); color: var(--fg-1); font-variant-numeric: tabular-nums; }
.rai-delivery .tr-table { padding-top: 12px; border-top: 1px solid var(--divider); }
.rai-delivery .tr-tbl-head {
  font: 600 10px var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--fg-3);
  margin-bottom: 10px;
}
.rai-delivery .tr-tbl-row {
  display: grid;
  grid-template-columns: 1fr 70px 50px;
  align-items: center;
  gap: 10px;
  padding: 6px 0;
}
.rai-delivery .tr-tbl-name { display: inline-flex; align-items: center; gap: 8px; font: 500 12px var(--font-ui); color: var(--fg-1); }
.rai-delivery .tr-tbl-dot { width: 7px; height: 7px; border-radius: 2px; }
.rai-delivery .tr-tbl-bar { height: 5px; background: var(--surface-3); border-radius: 999px; overflow: hidden; }
.rai-delivery .tr-tbl-fill { height: 100%; border-radius: 999px; }
.rai-delivery .tr-tbl-val { font: 500 11.5px var(--font-mono); color: var(--fg-1); font-variant-numeric: tabular-nums; text-align: right; }
.rai-delivery .cofund-hero { display: flex; flex-direction: column; gap: 4px; }
.rai-delivery .cf-val {
  font: 600 32px var(--font-mono);
  font-variant-numeric: tabular-nums;
  color: var(--success);
  letter-spacing: -.02em;
  line-height: 1;
}
.rai-delivery .cf-sub { font: 400 12px var(--font-ui); color: var(--fg-3); }
.rai-delivery .cf-spark {
  margin: 16px 0;
  padding: 8px 0;
  border-top: 1px solid var(--divider);
  border-bottom: 1px solid var(--divider);
}
.rai-delivery .cf-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.rai-delivery .cf-cell { display: flex; flex-direction: column; gap: 3px; }
.rai-delivery .cf-lbl { font: 600 9.5px var(--font-ui); text-transform: uppercase; letter-spacing: .08em; color: var(--fg-3); }
.rai-delivery .cf-num { font: 500 18px var(--font-mono); color: var(--fg-1); font-variant-numeric: tabular-nums; }
.rai-delivery .cf-note {
  margin-top: 14px;
  font: 400 11px var(--font-ui);
  color: var(--fg-muted);
  font-style: italic;
}
.rai-delivery .mc-stack {
  display: flex;
  height: 36px;
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 18px;
}
.rai-delivery .mc-seg { transition: opacity var(--dur-fast) var(--ease-out); }
.rai-delivery .mc-seg:hover { opacity: 0.85; }
.rai-delivery .mc-list { display: flex; flex-direction: column; gap: 0; }
.rai-delivery .mc-row {
  display: grid;
  grid-template-columns: 1fr 90px 60px;
  align-items: center;
  gap: 8px;
  padding: 10px 0;
  border-bottom: 1px solid var(--divider);
}
.rai-delivery .mc-row:last-child { border-bottom: 0; }
.rai-delivery .mc-name { display: inline-flex; align-items: center; gap: 8px; font: 500 12.5px var(--font-ui); color: var(--fg-1); }
.rai-delivery .mc-dot { width: 9px; height: 9px; border-radius: 2px; }
.rai-delivery .mc-val { font: 500 12.5px var(--font-mono); color: var(--fg-1); font-variant-numeric: tabular-nums; text-align: right; }
.rai-delivery .mc-pct { font: 600 11px var(--font-mono); color: var(--fg-3); font-variant-numeric: tabular-nums; text-align: right; }
/* Transparent so the global .main dotted canvas shows through in light too
   (dark .rai-delivery is already transparent). Keeps the dot layer truly
   dashboard-wide instead of being masked under a solid Delivery surface. */
[data-theme="light"] .rai-delivery { background: transparent; }
[data-theme="light"] .rai-delivery .topbar { background: rgba(248, 242, 231, 0.85); }
[data-theme="light"] .rai-delivery .ai-strip { background: radial-gradient(800px 200px at 12% 0%, rgba(251,95,44,.06) 0%, transparent 60%), var(--surface-1); }
/* ===== 2026-06-10 additions: data-integrity banner, freshness chips,
   MoM ranking table, chart hover tooltip, sample-data watermark ===== */

/* Red data-integrity banner (init.js dataIntegrityBannerHtml) — mirrors the
   amber .dlv-partial-banner but in danger colors: fired when the dashboard is
   showing demo data or unmapped locations were dropped from totals. */
.rai-delivery .dlv-integrity-banner {
  display: flex; gap: 10px; align-items: flex-start;
  margin: 12px 0 0;
  padding: 12px 14px;
  background: rgba(242,107,92,.08);
  border: 1px solid rgba(242,107,92,.4);
  border-left: 4px solid var(--danger);
  border-radius: 10px;
}
.rai-delivery .dlv-integrity-banner .dib-ic { color: var(--danger); flex: 0 0 auto; display: flex; margin-top: 1px; }
.rai-delivery .dlv-integrity-banner .dib-title { font: 700 12.5px var(--font-ui); color: var(--danger); }
.rai-delivery .dlv-integrity-banner .dib-sub { font: 400 11.5px var(--font-ui); color: var(--fg-2); margin-top: 2px; line-height: 1.45; }

/* Per-client data-freshness chips (Overview dataStatus card + client page). */
.rai-delivery .dlv-fresh-chips { display: flex; flex-wrap: wrap; gap: 8px; padding-top: 10px; }
.rai-delivery .dlv-fresh-chip {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 5px 10px;
  background: var(--surface-page);
  border: 1px solid var(--border-subtle);
  border-radius: 999px;
  cursor: pointer;
  font-family: var(--font-ui);
}
.rai-delivery .dlv-fresh-chip:hover { background: var(--surface-2); }
.rai-delivery .dlv-fresh-chip.stale { border-color: rgba(244,169,58,.45); background: var(--warning-bg); }
.rai-delivery .dlv-fresh-chip .dfc-name { font: 600 11px var(--font-ui); color: var(--fg-2); }
.rai-delivery .dlv-fresh-chip .dfc-date { font: 600 10.5px var(--font-mono); color: var(--fg-3); }
.rai-delivery span.dlv-fresh-chip { cursor: default; }

/* Overview MoM ranking table (sortable headers + clickable rows). */
.rai-delivery .ovr-rank-table { display: flex; flex-direction: column; }
.rai-delivery .ovr-rank-row {
  display: grid;
  grid-template-columns: 1.8fr repeat(5, 1fr);
  gap: 10px; align-items: center;
  padding: 11px 20px;
  border-top: 1px solid var(--divider);
  font: 500 12.5px var(--font-ui); color: var(--fg-1);
}
.rai-delivery .ovr-rank-row[data-dlv-open-client] { cursor: pointer; }
.rai-delivery .ovr-rank-row[data-dlv-open-client]:hover { background: var(--surface-2); }
.rai-delivery .ovr-rank-row .num { text-align: right; font-variant-numeric: tabular-nums; font-family: var(--font-mono); font-size: 12px; }
.rai-delivery .ovr-rank-row.ovr-rank-head {
  border-top: none; cursor: default;
  padding-top: 4px; padding-bottom: 8px;
  font: 600 10px var(--font-ui); color: var(--fg-3);
  text-transform: uppercase; letter-spacing: .06em;
}
.rai-delivery .ovr-rank-name { display: flex; align-items: center; gap: 8px; min-width: 0; }
.rai-delivery .ovr-rank-name .cc-dot { width: 8px; height: 8px; border-radius: 2px; flex-shrink: 0; }
.rai-delivery .ovr-th {
  background: none; border: none; padding: 0; margin: 0;
  font: 600 10px var(--font-ui); color: var(--fg-3);
  text-transform: uppercase; letter-spacing: .06em;
  cursor: pointer; text-align: left;
}
.rai-delivery .ovr-th.num { text-align: right; }
.rai-delivery .ovr-th:hover { color: var(--fg-1); }

/* Shared SVG chart hover tooltip ([data-dlv-tip] → init.js pointermove). */
.rai-delivery { position: relative; }
.rai-delivery .dlv-chart-tip {
  display: none; position: absolute; z-index: 60;
  max-width: 320px;
  padding: 7px 10px;
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 8px;
  box-shadow: 0 6px 24px rgba(0,0,0,.18);
  font: 500 11.5px var(--font-ui); color: var(--fg-1);
  pointer-events: none; white-space: normal; line-height: 1.45;
}

/* ── Chart hover focus (dim-focus) — spotlight the hovered element, dim the
   rest. Mirrors the reports' .rc-focusable pattern (reports.css). Opt-in via
   .dlv-focusable on the chart container + .dlv-grp on each focusable group. */
.rai-delivery .dlv-focusable .dlv-grp { transition: opacity .12s ease; }
.rai-delivery svg.dlv-focusable:hover .dlv-grp { opacity: .35; }
.rai-delivery svg.dlv-focusable .dlv-grp:hover { opacity: 1; }
/* Margin-spread lollipop rows */
.rai-delivery .margin-spread.dlv-focusable .ms-row { transition: opacity .12s ease; }
.rai-delivery .margin-spread.dlv-focusable:hover .ms-row { opacity: .4; }
.rai-delivery .margin-spread.dlv-focusable .ms-row:hover { opacity: 1; }
/* Delivery vs Pickup rows (focusable class sits on the card body; the
   legend isn't a .dp-row so it keeps full opacity) */
.rai-delivery .card-body.dlv-focusable .dp-row { transition: opacity .12s ease; }
.rai-delivery .card-body.dlv-focusable:hover .dp-row { opacity: .4; }
.rai-delivery .card-body.dlv-focusable .dp-row:hover { opacity: 1; }
/* Real-earnings contribution divided bar */
.rai-delivery .mc-stack.dlv-focusable .mc-seg { transition: opacity .12s ease; }
.rai-delivery .mc-stack.dlv-focusable:hover .mc-seg { opacity: .4; }
.rai-delivery .mc-stack.dlv-focusable .mc-seg:hover { opacity: 1; }
/* Line/area charts + sparklines: focus dot + vertical guide line appear on
   hover of each point's column (.dlv-pt), like the reports' .rc-pt. */
.rai-delivery .dlv-pt .pt-dot, .rai-delivery .dlv-pt .pt-line { opacity: 0; transition: opacity .12s ease; }
.rai-delivery .dlv-pt:hover .pt-dot, .rai-delivery .dlv-pt:hover .pt-line { opacity: 1; }

/* Sample-data report sections (ranking / segmentation / reviews): diagonal
   "DATOS DE EJEMPLO" watermark so fabricated shapes can never pass as real. */
.rai-delivery .rsec-sample { position: relative; overflow: hidden; }
.rai-delivery .rsec-sample::after {
  content: 'DATOS DE EJEMPLO';
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  transform: rotate(-24deg);
  font: 800 44px var(--font-ui);
  letter-spacing: .14em;
  color: rgba(244,169,58,.13);
  pointer-events: none;
  white-space: nowrap;
}
.rai-delivery .rps-nd { color: var(--fg-muted) !important; font-size: 11px !important; font-style: italic; }
.rai-delivery .rsec-note { margin-top: 10px; font: 500 11px var(--font-ui); color: var(--fg-3); line-height: 1.5; }

/* Recent-conversations entries in the agent context rail are now buttons. */
.rai-delivery button.acr-mem-item {
  text-align: left; cursor: pointer; width: 100%;
  font-family: var(--font-ui); color: var(--fg-1);
}
.rai-delivery button.acr-mem-item:hover { background: var(--surface-2); }

/* Time-filter month strip: pointer-event drag (touch included) — disable
   native panning on the cells so a touch drag selects months, not scrolls. */
.rai-delivery .tf-month { touch-action: none; }
