@import url("./design-tokens.css");

/* =============================================================================
   QUANTSAGE DESIGN TOKENS V1.0 — LEGACY SHIM (QS + MarCo legacy HTML)

   After DS-consolidate (2026-04-22), the canonical source of truth is
   web/design-tokens.json → public/quantsage/css/design-tokens.css (imported
   above). This file now owns ONLY the legacy-specific tokens that don't have
   a canonical equivalent yet:
     - font-size/weight/line-height/letter-spacing scales (--fs-*, --fw-*, --lh-*, --ls-*)
     - legacy semantic UI tokens (--bg-*, --text-*, --border-*, --accent*, --agent-brand-*)
     - component tokens (--card-*, --btn-*, --table-*, --toggle-*, --tab-*, --kpi-*)
     - sizing / icon / spinner / z-index scales
     - utility classes (.tabular-nums, .text-primary, etc.)

   Token categories now sourced from design-tokens.css (do NOT redefine here):
     - --space-0..16     (canonical px scale)
     - --font-primary, --font-mono, --font-body, --font-sans, --font-display
     - --color-positive, --color-negative, --color-warning, --color-info + subtle variants
     - --radius-none/hair/soft/sm/md/lg/xl/pill/full/xs
     - --shadow-sm/md/lg/sticky
     - --qs-*, --mc-* legacy shell names

   Edit web/design-tokens.json and run 'pnpm tokens:build' to change canonical
   values. Edit this file only for legacy names that have no canonical yet.
   ============================================================================= */

:root {
  /* ===========================================================================
     1. SPACING — sourced from design-tokens.css (--space-0..16); legacy
     half-step kept here because the canonical scale uses integer steps only
     =========================================================================== */
  --space-1-5: 0.375rem;  /* 6px — no canonical equivalent (half-step) */

  /* ===========================================================================
     2. TYPOGRAPHY — font families sourced from design-tokens.css
     (--font-primary/--font-body/--font-sans/--font-display/--font-mono)
     =========================================================================== */

  /* Font Sizes - Industry Standard 14px Base */
  --fs-2xs: 0.625rem;     /* 10px - Tiny labels, badges */
  --fs-xs: 0.6875rem;     /* 11px - Small labels, table headers */
  --fs-sm: 0.75rem;       /* 12px - Secondary text, captions */
  --fs-base: 0.8125rem;   /* 13px - Body text (terminal standard) */
  --fs-md: 0.875rem;      /* 14px - Emphasis text */
  --fs-lg: 1rem;          /* 16px - Section titles */
  --fs-xl: 1.125rem;      /* 18px - Page subtitles */
  --fs-2xl: 1.25rem;      /* 20px - Page titles */
  --fs-3xl: 1.5rem;       /* 24px - Hero text */

  /* Font Weights */
  --fw-normal: 400;       /* Body text */
  --fw-medium: 500;       /* Slight emphasis */
  --fw-semibold: 600;     /* Headings, labels */
  --fw-bold: 700;         /* Strong emphasis */

  /* Line Heights */
  --lh-tight: 1.25;       /* Headings */
  --lh-normal: 1.5;       /* Body text */
  --lh-relaxed: 1.75;     /* Long-form content */

  /* Letter Spacing */
  --ls-tight: -0.01em;    /* Large headings */
  --ls-normal: 0;         /* Body text */
  --ls-wide: 0.03em;      /* Small caps, labels */
  --ls-wider: 0.05em;     /* Uppercase labels */

  /* ===========================================================================
     3. COLORS
     =========================================================================== */

  /* Background Colors (tinted toward teal for brand cohesion) */
  --bg-canvas: #F7F9F9;           /* Page background */
  --bg-panel: #FFFFFF;            /* Card/panel background */
  --bg-secondary: #F2F5F4;        /* Secondary backgrounds */
  --bg-hover: #EFF2F1;            /* Hover states */
  --bg-muted: #E8ECEB;            /* Muted/disabled backgrounds */
  --bg-tertiary: #EBEEED;          /* Third-tier background */
  --bg-dark-console: #1a1a2e;     /* Dark mode console */

  /* Border Colors (tinted toward teal) */
  --border-subtle: #E0E4E3;       /* Default borders */
  --border-default: #E0E4E3;      /* Alias for --border-subtle */
  --border-color: #E0E4E3;        /* Generic alias */
  --border-strong: #D0D5D3;       /* Emphasized borders */
  --border-focus: #00be8c;        /* Focus state borders (platform teal) */

  /* Text Colors (tinted toward teal) */
  --text-primary: #232A2D;        /* Primary text */
  --text-secondary: #566068;      /* Secondary text */
  --text-muted: #68737B;          /* Muted/disabled text */
  --text-inverse: #FFFFFF;        /* Text on dark backgrounds */

  /* Platform Accent (teal — consistent across all agents) */
  --accent: #00be8c;
  --accent-hover: #009970;
  --accent-light: rgba(0, 190, 140, 0.08);

  /* Agent Brand Colors (black — consistent across all agents) */
  --accent-blue: #111111;         /* Legacy alias — use --agent-brand instead */
  --accent-blue-hover: #000000;
  --accent-blue-light: rgba(0, 0, 0, 0.06);
  --agent-brand: #111111;
  --agent-brand-hover: #000000;
  --agent-brand-light: rgba(0, 0, 0, 0.06);

  /* Semantic colors (--color-positive/--color-negative/--color-warning/--color-info
     + -subtle variants) sourced from design-tokens.css — editorial palette, not Tailwind. */
  --color-neutral: #6B7280;       /* Neutral/unchanged — legacy-only, no canonical */
  --accent-green: var(--color-positive);  /* Alias */

  /* Semantic Light Backgrounds */
  --color-positive-light: rgba(34, 197, 94, 0.1);
  --color-negative-light: rgba(239, 68, 68, 0.1);
  --color-warning-light: rgba(245, 158, 11, 0.1);
  --color-info-light: rgba(59, 130, 246, 0.1);

  /* ── Canonical Shared Names (same across all design systems) ── */
  --bg-page: var(--bg-canvas);
  --bg-surface: var(--bg-panel);
  --border: var(--border-subtle);
  --border-focus: var(--accent);
  --success: var(--color-positive);
  --warning: var(--color-warning);
  --danger: var(--color-negative);
  --font-body: var(--font-primary);

  /* ── QuantSage-Specific Aliases (backward compat) ── */
  --color-success: var(--color-positive);
  --color-success-light: var(--color-positive-light);
  --color-danger: var(--color-negative);
  --color-danger-light: var(--color-negative-light);
  --color-primary: var(--accent);
  --color-primary-hover: var(--accent-hover);
  --color-primary-light: var(--accent-light);
  --color-background: var(--bg-canvas);
  --color-surface: var(--bg-panel);
  --color-card: var(--bg-panel);
  --color-border: var(--border-subtle);
  --color-text: var(--text-primary);
  --color-text-primary: var(--text-primary);
  --color-text-secondary: var(--text-secondary);
  --color-text-muted: var(--text-muted);
  --color-text-inverse: var(--text-inverse);

  /* Strategy Colors (for trading) */
  --color-dividend: #28A745;
  --color-dividend-light: #f4fbf6;
  --color-momentum: #0066FF;
  --color-momentum-light: #f0f6ff;
  --color-fundamental: #6C757D;
  --color-fundamental-light: #f5f5f6;

  /* ===========================================================================
     4. SHADOWS & ELEVATION — --shadow-sm/md/lg/sticky sourced from
     design-tokens.css (editorial 0.04/0.06/0.12 rgba(10,10,10,*) scale).
     Legacy hard-shadow --shadow-xs/xl/card/modal kept here — no canonical yet.
     =========================================================================== */
  --shadow-xs: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);

  /* Component-specific shadows */
  --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.08);
  --shadow-card-hover: 0 4px 12px rgba(0, 0, 0, 0.12);
  --shadow-dropdown: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-modal: 0 25px 50px -12px rgba(0, 0, 0, 0.25);

  /* ===========================================================================
     5. BORDER RADII — sourced from design-tokens.css (--radius-xs/sm/md/lg/xl/full)
     =========================================================================== */

  /* ===========================================================================
     6. TRANSITIONS
     =========================================================================== */
  --transition-fast: 0.1s ease;
  --transition-normal: 0.15s ease;
  --transition-slow: 0.2s ease;
  --transition-slower: 0.3s ease;

  /* Specific transitions */
  --transition-color: color 0.15s ease;
  --transition-bg: background-color 0.15s ease;
  --transition-border: border-color 0.15s ease;
  --transition-shadow: box-shadow 0.15s ease;
  --transition-transform: transform 0.15s ease;
  --transition-opacity: opacity 0.15s ease;
  --transition-all: all 0.15s ease;

  /* ===========================================================================
     7. SIZING (Layout Dimensions)
     =========================================================================== */
  --global-nav-width: 60px;       /* Left icon sidebar */
  --context-sidebar-width: 280px; /* Context sidebar */
  --header-height: 48px;          /* App header height */
  --footer-height: 40px;          /* Footer height */

  /* Content constraints */
  --content-max-width: 1600px;
  --content-narrow: 800px;
  --content-medium: 1200px;

  /* ===========================================================================
     8. COMPONENT TOKENS
     =========================================================================== */

  /* --- Card Components --- */
  --card-padding: var(--space-4);             /* 16px internal padding */
  --card-padding-compact: var(--space-3);     /* 12px compact padding */
  --card-gap: var(--space-4);                 /* 16px between cards */
  --card-radius: var(--radius-md);            /* 8px border radius */
  --card-border: 1px solid var(--border-subtle);
  --card-bg: var(--bg-panel);

  /* --- Section Spacing --- */
  --section-gap: var(--space-8);              /* 32px between major sections */
  --section-gap-y: var(--space-6);            /* 24px vertical spacing */
  --section-padding: var(--space-4);          /* 16px section padding */
  --element-gap: var(--space-3);              /* 12px between small elements */

  /* --- Chart Header --- */
  --header-padding-y: var(--space-3);         /* 12px vertical */
  --header-padding-x: var(--space-4);         /* 16px horizontal */
  --header-padding: var(--header-padding-y) var(--header-padding-x);
  --header-font-size: var(--fs-base);         /* 13px */
  --header-font-weight: var(--fw-semibold);   /* 600 */
  --header-color: var(--text-primary);
  --header-bg: var(--bg-panel);
  --header-border: 1px solid var(--border-subtle);
  --header-gap: var(--space-4);               /* 16px between header items */
  --header-min-height: 44px;

  /* --- Chart Body --- */
  --body-padding: var(--space-3);             /* 12px padding */
  --body-bg: var(--bg-panel);

  /* --- Chart Container --- */
  --chart-height: 320px;
  --chart-height-tall: 400px;
  --chart-height-short: 240px;
  --chart-min-height: 280px;

  /* --- Numeric Display --- */
  /* tabular-nums: aligned columns in tables/stats. Apply via .tabular-nums or component defaults below */

  /* --- Table Components --- */
  --table-header-padding: 0.625rem 0.75rem;   /* 10px 12px */
  --table-cell-padding: 0.625rem 0.75rem;     /* 10px 12px */
  --table-cell-padding-compact: 0.5rem;       /* 8px */
  --table-header-font-size: var(--fs-xs);     /* 11px */
  --table-cell-font-size: var(--fs-sm);       /* 12px */
  --table-header-font-weight: var(--fw-semibold);
  --table-header-color: var(--text-secondary);
  --table-header-bg: var(--bg-panel);
  --table-row-border: 1px solid var(--border-subtle);
  --table-row-hover-bg: var(--bg-hover);

  /* --- KPI Cards --- */
  --kpi-padding: var(--space-4);
  --kpi-label-size: var(--fs-2xs);            /* 10px */
  --kpi-value-size: var(--fs-2xl);            /* 20px */
  --kpi-label-color: var(--text-muted);
  --kpi-value-color: var(--text-primary);

  /* --- Buttons --- */
  --btn-padding-y: 0.375rem;                  /* 6px */
  --btn-padding-x: 0.75rem;                   /* 12px */
  --btn-padding: var(--btn-padding-y) var(--btn-padding-x);
  --btn-font-size: var(--fs-sm);              /* 12px */
  --btn-font-weight: var(--fw-medium);        /* 500 */
  --btn-radius: var(--radius-sm);             /* 6px */
  --btn-height: 32px;
  --btn-height-sm: 28px;
  --btn-height-lg: 40px;

  /* --- Form Inputs --- */
  --input-padding-y: 0.5rem;                  /* 8px */
  --input-padding-x: 0.75rem;                 /* 12px */
  --input-padding: var(--input-padding-y) var(--input-padding-x);
  --input-font-size: var(--fs-base);          /* 13px */
  --input-radius: var(--radius-sm);           /* 6px */
  --input-border: 1px solid var(--border-subtle);
  --input-bg: var(--bg-panel);
  --input-height: 36px;

  /* --- Toggle Buttons (Chart Controls) --- */
  --toggle-padding: 0.25rem 0.5rem;           /* 4px 8px */
  --toggle-font-size: var(--fs-xs);           /* 11px */
  --toggle-radius: var(--radius-xs);          /* 4px */
  --toggle-bg: var(--bg-canvas);
  --toggle-active-bg: var(--bg-panel);
  --toggle-active-color: var(--accent);

  /* --- Badges --- */
  --badge-padding: 0.125rem 0.375rem;         /* 2px 6px */
  --badge-font-size: var(--fs-2xs);           /* 10px */
  --badge-font-weight: var(--fw-semibold);
  --badge-radius: var(--radius-xs);           /* 4px */

  /* --- Tabs --- */
  --tab-padding: 0.5rem 1rem;                 /* 8px 16px */
  --tab-font-size: var(--fs-sm);              /* 12px */
  --tab-font-weight: var(--fw-medium);
  --tab-gap: var(--space-1);                  /* 4px between tabs */
  --tab-active-color: var(--accent);
  --tab-inactive-color: var(--text-muted);

  /* ===========================================================================
     9. ICON SYSTEM
     =========================================================================== */
  --icon-xs: 0.75rem;     /* 12px - Inline with small text */
  --icon-sm: 0.875rem;    /* 14px - Inline with body text */
  --icon-md: 1rem;        /* 16px - Standard icons */
  --icon-lg: 1.25rem;     /* 20px - Feature icons */
  --icon-xl: 1.5rem;      /* 24px - Large icons */
  --icon-2xl: 2rem;       /* 32px - Hero icons */

  --icon-color: var(--text-muted);
  --icon-color-active: var(--accent);
  --icon-gap: var(--space-2);                 /* 8px gap between icon and text */

  /* ===========================================================================
     10. LOADING INDICATORS
     =========================================================================== */

  /* Spinner sizes */
  --spinner-xs: 16px;           /* Inline with text */
  --spinner-sm: 24px;           /* Small buttons */
  --spinner-md: 32px;           /* Standard loading */
  --spinner-lg: 48px;           /* Chart/panel loading */
  --spinner-xl: 64px;           /* Full page loading */

  /* Spinner styling */
  --spinner-border-width: 3px;
  --spinner-border-color: var(--border-subtle);
  --spinner-active-color: var(--accent);
  --spinner-speed: 0.8s;

  /* Loading overlay */
  --loading-overlay-bg: rgba(255, 255, 255, 0.9);
  --loading-overlay-blur: 4px;
  --loading-text-color: var(--text-secondary);
  --loading-text-size: var(--fs-sm);

  /* ===========================================================================
     11. Z-INDEX SCALE
     =========================================================================== */
  --z-below: -1;
  --z-base: 0;
  --z-above: 1;
  --z-sticky: 10;
  --z-fixed: 20;
  --z-table-header: 30;
  --z-table-frozen: 40;
  --z-dropdown: 50;
  --z-overlay: 60;
  --z-modal: 70;
  --z-popover: 80;
  --z-tooltip: 90;
  --z-toast: 100;
}

/* =============================================================================
   UTILITY CLASSES (Optional - can use directly from tokens.css)
   ============================================================================= */

/* Tabular Nums — aligned numeric columns in tables, stats, KPIs */
.tabular-nums,
td,
.kpi-value,
.metric-value,
.stat-value {
  font-variant-numeric: tabular-nums;
}

/* Text Colors */
.text-primary { color: var(--text-primary); }
.text-secondary { color: var(--text-secondary); }
.text-muted { color: var(--text-muted); }
.text-positive { color: var(--color-positive); }
.text-negative { color: var(--color-negative); }
.text-warning { color: var(--color-warning); }
.text-accent { color: var(--accent); }

/* Font Sizes */
.text-xs { font-size: var(--fs-xs); }
.text-sm { font-size: var(--fs-sm); }
.text-base { font-size: var(--fs-base); }
.text-md { font-size: var(--fs-md); }
.text-lg { font-size: var(--fs-lg); }

/* Font Weights */
.font-normal { font-weight: var(--fw-normal); }
.font-medium { font-weight: var(--fw-medium); }
.font-semibold { font-weight: var(--fw-semibold); }
.font-bold { font-weight: var(--fw-bold); }

/* Background Colors */
.bg-canvas { background-color: var(--bg-canvas); }
.bg-panel { background-color: var(--bg-panel); }
.bg-hover { background-color: var(--bg-hover); }

/* Spacing Utilities */
.gap-1 { gap: var(--space-1); }
.gap-2 { gap: var(--space-2); }
.gap-3 { gap: var(--space-3); }
.gap-4 { gap: var(--space-4); }
.gap-6 { gap: var(--space-6); }

.p-1 { padding: var(--space-1); }
.p-2 { padding: var(--space-2); }
.p-3 { padding: var(--space-3); }
.p-4 { padding: var(--space-4); }
.p-6 { padding: var(--space-6); }

.mb-1 { margin-bottom: var(--space-1); }
.mb-2 { margin-bottom: var(--space-2); }
.mb-3 { margin-bottom: var(--space-3); }
.mb-4 { margin-bottom: var(--space-4); }
.mb-6 { margin-bottom: var(--space-6); }

/* Border Radius */
.rounded-sm { border-radius: var(--radius-sm); }
.rounded-md { border-radius: var(--radius-md); }
.rounded-lg { border-radius: var(--radius-lg); }
.rounded-full { border-radius: var(--radius-full); }

/* Shadows */
.shadow-sm { box-shadow: var(--shadow-sm); }
.shadow-md { box-shadow: var(--shadow-md); }
.shadow-lg { box-shadow: var(--shadow-lg); }
.shadow-card { box-shadow: var(--shadow-card); }

/* =============================================================================
   LOADING INDICATOR COMPONENTS
   ============================================================================= */

/* Spinner Animation */
@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* Base spinner - CSS only, no images needed */
.spinner {
  display: inline-block;
  width: var(--spinner-md);
  height: var(--spinner-md);
  border: var(--spinner-border-width) solid var(--spinner-border-color);
  border-top-color: var(--spinner-active-color);
  border-radius: var(--radius-full);
  animation: spin var(--spinner-speed) linear infinite;
}

/* Spinner size variants */
.spinner-xs { width: var(--spinner-xs); height: var(--spinner-xs); border-width: 2px; }
.spinner-sm { width: var(--spinner-sm); height: var(--spinner-sm); border-width: 2px; }
.spinner-md { width: var(--spinner-md); height: var(--spinner-md); }
.spinner-lg { width: var(--spinner-lg); height: var(--spinner-lg); border-width: 4px; }
.spinner-xl { width: var(--spinner-xl); height: var(--spinner-xl); border-width: 4px; }

/* Loading Overlay - covers parent container */
.loading-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--loading-overlay-bg);
  backdrop-filter: blur(var(--loading-overlay-blur));
  z-index: var(--z-overlay);
  gap: var(--space-3);
}

.loading-overlay.hidden { display: none; }
.loading-overlay.visible { display: flex; }

/* Loading text */
.loading-text {
  color: var(--loading-text-color);
  font-size: var(--loading-text-size);
  font-weight: var(--fw-medium);
  text-align: center;
}

/* Chart-specific loading - centered in chart area */
.chart-loading {
  position: absolute;
  inset: 0;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--loading-overlay-bg);
  backdrop-filter: blur(var(--loading-overlay-blur));
  z-index: var(--z-overlay);
  gap: var(--space-3);
}

.chart-loading.visible { display: flex; }

.chart-loading .spinner,
.chart-loading-spinner {
  width: var(--spinner-lg);
  height: var(--spinner-lg);
  border: 4px solid var(--spinner-border-color);
  border-top-color: var(--spinner-active-color);
  border-radius: var(--radius-full);
  animation: spin var(--spinner-speed) linear infinite;
}

.chart-loading-text {
  color: var(--loading-text-color);
  font-size: var(--loading-text-size);
  font-weight: var(--fw-medium);
  text-align: center;
  margin-top: var(--space-2);
}

/* Table loading state */
.loading-row,
.loading-message {
  text-align: center;
  padding: var(--space-8) var(--space-4);
  color: var(--text-muted);
}

.loading-row .spinner,
.loading-message .spinner {
  margin-right: var(--space-2);
}

/* Empty state styling */
.empty-state,
.error-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: var(--space-8);
  text-align: center;
  color: var(--text-muted);
}

.empty-state i,
.error-state i {
  font-size: var(--icon-2xl);
  margin-bottom: var(--space-3);
  opacity: 0.5;
}

.empty-state p,
.error-state p {
  margin: 0;
  font-size: var(--fs-sm);
}

.error-state { color: var(--color-negative); }
.error-state i { color: var(--color-negative); opacity: 0.7; }

/* =============================================================================
   STAGGERED REVEAL ANIMATION
   Usage: add .stagger-reveal to parent, children auto-animate via nth-child.
   Or use .fade-in + .stagger-1 through .stagger-8 for manual control.
   ============================================================================= */

@keyframes fadeSlideIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Parent-driven stagger — add to grid/flex container */
.stagger-reveal > * {
  opacity: 0;
  animation: fadeSlideIn 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.stagger-reveal > *:nth-child(1) { animation-delay: 0s; }
.stagger-reveal > *:nth-child(2) { animation-delay: 0.06s; }
.stagger-reveal > *:nth-child(3) { animation-delay: 0.12s; }
.stagger-reveal > *:nth-child(4) { animation-delay: 0.18s; }
.stagger-reveal > *:nth-child(5) { animation-delay: 0.24s; }
.stagger-reveal > *:nth-child(6) { animation-delay: 0.30s; }
.stagger-reveal > *:nth-child(7) { animation-delay: 0.36s; }
.stagger-reveal > *:nth-child(8) { animation-delay: 0.42s; }

/* Manual stagger — add .fade-in + .stagger-N to individual elements */
.fade-in {
  opacity: 0;
  animation: fadeSlideIn 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.stagger-1 { animation-delay: 0.06s; }
.stagger-2 { animation-delay: 0.12s; }
.stagger-3 { animation-delay: 0.18s; }
.stagger-4 { animation-delay: 0.24s; }
.stagger-5 { animation-delay: 0.30s; }
.stagger-6 { animation-delay: 0.36s; }
.stagger-7 { animation-delay: 0.42s; }
.stagger-8 { animation-delay: 0.48s; }

/* Respect reduced motion preference */
@media (prefers-reduced-motion: reduce) {
  .stagger-reveal > *,
  .fade-in {
    animation: none;
    opacity: 1;
    transform: none;
  }
}

/* Legal disclaimer - fixed footer spanning full width */
.legal-disclaimer {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 200;
  text-align: center;
  padding: 3px 16px;
  font-size: 0.55rem;
  line-height: 1;
  color: var(--text-muted);
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-subtle);
  letter-spacing: 0.02em;
  opacity: 0.7;
}
.legal-disclaimer a {
  color: var(--text-muted);
  text-decoration: underline;
  margin-left: 2px;
}
.legal-disclaimer a:hover { color: var(--accent); opacity: 1; }

/* ═══ FOCUS & ERROR STATES ═══ */
button:focus-visible,
a:focus-visible,
[role="button"]:focus-visible {
  outline: 2px solid var(--accent, #00be8c);
  outline-offset: 2px;
}
input.error, textarea.error, select.error {
  border-color: var(--color-negative, #DC3545) !important;
}
input.error:focus, textarea.error:focus, select.error:focus {
  box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.12) !important;
}
.field-error { font-size: var(--fs-xs, 11px); color: var(--color-negative, #DC3545); margin-top: 4px; }
