/* P.B Universe — Design Tokens */
/* Custom palette: Navy Blue + White + Gold accent — professional property management */

:root,
[data-theme='light'] {
  /* Surfaces */
  --color-bg: #f5f6f8;
  --color-surface: #ffffff;
  --color-surface-2: #f0f2f5;
  --color-surface-offset: #e8ebf0;
  --color-surface-offset-2: #dde1e8;
  --color-surface-dynamic: #d0d5de;
  --color-divider: #cdd2db;
  --color-border: #c2c8d4;

  /* Text */
  --color-text: #0f1929;
  --color-text-muted: #4a5568;
  --color-text-faint: #9aa3b2;
  --color-text-inverse: #ffffff;

  /* Primary — Navy Blue */
  --color-primary: #1a3a6b;
  --color-primary-hover: #12295a;
  --color-primary-active: #0c1d42;
  --color-primary-highlight: #d0d8ea;

  /* Accent — Gold */
  --color-accent: #c9981a;
  --color-accent-hover: #b07e0e;
  --color-accent-active: #8a6300;
  --color-accent-highlight: #f5e9c4;

  /* Status */
  --color-success: #2d7a3a;
  --color-success-hover: #1e5c29;
  --color-success-highlight: #d1ebd6;
  --color-error: #c0392b;
  --color-error-hover: #96281d;
  --color-error-highlight: #f5d0cd;
  --color-warning: #e07b00;
  --color-warning-hover: #b56300;
  --color-warning-highlight: #fde8c0;

  /* Radius */
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  --radius-2xl: 1.5rem;
  --radius-full: 9999px;

  /* Transitions */
  --transition-interactive: 180ms cubic-bezier(0.16, 1, 0.3, 1);

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(15, 25, 41, 0.06), 0 1px 2px rgba(15, 25, 41, 0.04);
  --shadow-md: 0 4px 12px rgba(15, 25, 41, 0.08), 0 2px 6px rgba(15, 25, 41, 0.05);
  --shadow-lg: 0 12px 32px rgba(15, 25, 41, 0.12), 0 4px 12px rgba(15, 25, 41, 0.06);
  --shadow-xl: 0 24px 48px rgba(15, 25, 41, 0.16), 0 8px 20px rgba(15, 25, 41, 0.08);

  /* Content widths */
  --content-narrow: 640px;
  --content-default: 960px;
  --content-wide: 1200px;

  /* Type scale */
  --text-xs: clamp(0.75rem, 0.7rem + 0.25vw, 0.875rem);
  --text-sm: clamp(0.875rem, 0.8rem + 0.35vw, 1rem);
  --text-base: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
  --text-lg: clamp(1.125rem, 1rem + 0.75vw, 1.5rem);
  --text-xl: clamp(1.5rem, 1.2rem + 1.25vw, 2.25rem);
  --text-2xl: clamp(2rem, 1.2rem + 2.5vw, 3.5rem);
  --text-3xl: clamp(2.5rem, 1rem + 4vw, 5rem);

  /* Spacing */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;
  --space-32: 8rem;

  /* Fonts */
  --font-display: 'DM Serif Display', 'Georgia', serif;
  --font-body: 'DM Sans', 'Helvetica Neue', sans-serif;
}

/* Dark mode */
[data-theme='dark'] {
  --color-bg: #0c1522;
  --color-surface: #111d2e;
  --color-surface-2: #162236;
  --color-surface-offset: #1a2840;
  --color-surface-offset-2: #1f2f4a;
  --color-surface-dynamic: #243552;
  --color-divider: #253450;
  --color-border: #2e4060;
  --color-text: #e2e8f0;
  --color-text-muted: #94a3b8;
  --color-text-faint: #4a5e7a;
  --color-text-inverse: #0c1522;
  --color-primary: #5b8dd9;
  --color-primary-hover: #3b70c4;
  --color-primary-active: #2558aa;
  --color-primary-highlight: #1e3254;
  --color-accent: #e8b84d;
  --color-accent-hover: #d4a030;
  --color-accent-active: #b8841a;
  --color-accent-highlight: #3d2f0a;
  --color-success: #48bb60;
  --color-success-hover: #2ea048;
  --color-success-highlight: #122d18;
  --color-error: #f87272;
  --color-error-hover: #e05050;
  --color-error-highlight: #3a0f0f;
  --color-warning: #f6ad55;
  --color-warning-hover: #e09030;
  --color-warning-highlight: #3d2200;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.25);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.35);
  --shadow-lg: 0 12px 32px rgba(0, 0, 0, 0.45);
  --shadow-xl: 0 24px 48px rgba(0, 0, 0, 0.55);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    --color-bg: #0c1522;
    --color-surface: #111d2e;
    --color-surface-2: #162236;
    --color-surface-offset: #1a2840;
    --color-surface-offset-2: #1f2f4a;
    --color-surface-dynamic: #243552;
    --color-divider: #253450;
    --color-border: #2e4060;
    --color-text: #e2e8f0;
    --color-text-muted: #94a3b8;
    --color-text-faint: #4a5e7a;
    --color-text-inverse: #0c1522;
    --color-primary: #5b8dd9;
    --color-primary-hover: #3b70c4;
    --color-primary-active: #2558aa;
    --color-primary-highlight: #1e3254;
    --color-accent: #e8b84d;
    --color-accent-hover: #d4a030;
    --color-accent-active: #b8841a;
    --color-accent-highlight: #3d2f0a;
    --color-success: #48bb60;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.25);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.35);
    --shadow-lg: 0 12px 32px rgba(0, 0, 0, 0.45);
    --shadow-xl: 0 24px 48px rgba(0, 0, 0, 0.55);
  }
}
