/**
 * DaysAndDates.com - Design System & CSS Custom Properties
 * Inspired by Apple, Linear, Notion, Stripe & Framer
 * Luxury, Editorial, Modern, Glass, Minimal, Fast
 */

:root {
  /* Brand Color Palette - Derived directly from DaysAndDates Logo (days-and-dates.png) */
  --brand-primary: #4f46e5;        /* Electric Indigo / Blue from logo body */
  --brand-primary-hover: #4338ca;
  --brand-primary-light: rgba(79, 70, 229, 0.09);
  --brand-primary-glow: rgba(79, 70, 229, 0.28);

  --brand-accent: #f59e0b;         /* Solar Gold / Amber from logo halo ring */
  --brand-accent-hover: #d97706;
  --brand-accent-light: rgba(245, 158, 11, 0.12);
  --brand-accent-glow: rgba(245, 158, 11, 0.32);

  --brand-coral: #e85942;          /* Coral Crimson / Vermilion from logo binder top */
  --brand-coral-hover: #dc2626;
  --brand-coral-light: rgba(232, 89, 66, 0.12);
  --brand-coral-glow: rgba(232, 89, 66, 0.32);

  --brand-celestial: #8b5cf6;      /* Violet / Purple from logo binder loop */
  --brand-celestial-light: rgba(139, 92, 246, 0.12);

  --brand-rose: #e85942;
  --brand-rose-light: rgba(232, 89, 66, 0.12);

  --brand-emerald: #10b981;
  --brand-emerald-light: rgba(16, 185, 129, 0.1);

  --brand-cyan: #06b6d4;           /* Cyan Turquoise from logo bottom right highlight */
  --brand-cyan-light: rgba(6, 182, 212, 0.12);

  /* Logo Signature Gradients */
  --gradient-logo-primary: linear-gradient(135deg, #4f46e5 0%, #3b82f6 50%, #06b6d4 100%);
  --gradient-logo-warm: linear-gradient(135deg, #e85942 0%, #f59e0b 100%);
  --gradient-logo-full: linear-gradient(135deg, #e85942 0%, #f59e0b 28%, #8b5cf6 65%, #4f46e5 100%);
  --gradient-card-hero: linear-gradient(180deg, rgba(15, 23, 42, 0.15) 0%, rgba(15, 23, 42, 0.5) 45%, rgba(10, 15, 30, 0.96) 100%);

  /* Light Theme Color System (Warm Editorial & Frosted Alabaster) */
  --bg-app: #faf8f5;
  --bg-gradient-mesh: radial-gradient(at 5% 0%, rgba(79, 70, 229, 0.07) 0px, transparent 48%),
                      radial-gradient(at 95% 5%, rgba(245, 158, 11, 0.08) 0px, transparent 48%),
                      radial-gradient(at 50% 50%, rgba(232, 89, 66, 0.05) 0px, transparent 50%),
                      radial-gradient(at 80% 85%, rgba(6, 182, 212, 0.05) 0px, transparent 50%);
  --surface-base: #ffffff;
  --surface-elevated: #ffffff;
  --surface-muted: #f4f1eb;
  --surface-subtle: #f8f6f2;
  --surface-active: #ece7de;

  /* Glassmorphism Light */
  --glass-bg: rgba(255, 255, 255, 0.82);
  --glass-bg-hover: rgba(255, 255, 255, 0.94);
  --glass-border: rgba(0, 0, 0, 0.06);
  --glass-border-hover: rgba(79, 70, 229, 0.28);
  --glass-highlight: rgba(255, 255, 255, 0.9);
  --glass-blur: blur(18px);

  /* Typography Colors (High-Contrast AAA/AA Compliance) */
  --text-primary: #0b0f19;
  --text-secondary: #334155;
  --text-muted: #64748b;
  --text-inverse: #ffffff;
  --text-brand: #4f46e5;

  /* Card Image Overlays & Scrim Tokens */
  --scrim-photo-subtle: linear-gradient(180deg, rgba(7, 10, 18, 0.55) 0%, rgba(7, 10, 18, 0.18) 28%, rgba(7, 10, 18, 0.45) 55%, rgba(5, 7, 14, 0.94) 85%, rgba(3, 5, 10, 0.99) 100%);
  --scrim-photo-hover: linear-gradient(180deg, rgba(7, 10, 18, 0.7) 0%, rgba(7, 10, 18, 0.28) 28%, rgba(7, 10, 18, 0.55) 55%, rgba(5, 7, 14, 0.97) 85%, #03050a 100%);
  --scrim-hero-spotlight: linear-gradient(180deg, rgba(7, 10, 18, 0.65) 0%, rgba(7, 10, 18, 0.22) 28%, rgba(7, 10, 18, 0.5) 55%, rgba(5, 8, 16, 0.94) 85%, rgba(3, 5, 10, 0.99) 100%);

  /* Borders & Dividers */
  --border-subtle: rgba(0, 0, 0, 0.05);
  --border-medium: rgba(0, 0, 0, 0.09);
  --border-strong: rgba(0, 0, 0, 0.16);

  /* Shadows (Multi-layered, smooth natural diffusion) */
  --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.03), 0 1px 2px rgba(0, 0, 0, 0.03);
  --shadow-md: 0 6px 16px -2px rgba(18, 20, 26, 0.06), 0 2px 6px -1px rgba(18, 20, 26, 0.03);
  --shadow-lg: 0 16px 36px -4px rgba(18, 20, 26, 0.08), 0 6px 12px -2px rgba(18, 20, 26, 0.03);
  --shadow-xl: 0 24px 54px -8px rgba(18, 20, 26, 0.12), 0 8px 18px -4px rgba(18, 20, 26, 0.04);
  --shadow-glow-primary: 0 8px 30px rgba(84, 82, 246, 0.22);
  --shadow-glow-accent: 0 8px 30px rgba(245, 158, 11, 0.22);

  /* Status Colors */
  --color-success: #10b981;
  --color-warning: #f59e0b;
  --color-danger: #ef4444;
  --color-info: #0284c7;

  /* Typography Stack */
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --font-editorial: 'Newsreader', 'Libre Baskerville', Georgia, serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;

  /* Font Scales (Fluid clamp sizing for responsive perfection) */
  --fs-xs: clamp(0.75rem, 0.72rem + 0.15vw, 0.8125rem);     /* 12px -> 13px */
  --fs-sm: clamp(0.8438rem, 0.82rem + 0.15vw, 0.9063rem);   /* 13.5px -> 14.5px */
  --fs-base: clamp(0.9375rem, 0.91rem + 0.2vw, 1.0313rem);  /* 15px -> 16.5px */
  --fs-md: clamp(1.0625rem, 1.02rem + 0.3vw, 1.1875rem);    /* 17px -> 19px */
  --fs-lg: clamp(1.25rem, 1.18rem + 0.5vw, 1.4375rem);      /* 20px -> 23px */
  --fs-xl: clamp(1.5rem, 1.38rem + 0.8vw, 1.875rem);        /* 24px -> 30px */
  --fs-2xl: clamp(1.875rem, 1.65rem + 1.2vw, 2.5rem);       /* 30px -> 40px */
  --fs-3xl: clamp(2.35rem, 1.95rem + 2vw, 3.5rem);          /* 37.6px -> 56px */
  --fs-hero: clamp(2.85rem, 2.2rem + 3.2vw, 4.85rem);       /* 45.6px -> 77.6px */

  /* Line Heights */
  --lh-tight: 1.12;
  --lh-snug: 1.25;
  --lh-normal: 1.45;
  --lh-relaxed: 1.65;

  /* Letter Spacing */
  --ls-tight: -0.035em;
  --ls-snug: -0.015em;
  --ls-normal: 0em;
  --ls-wide: 0.035em;
  --ls-wider: 0.08em;

  /* Border Radii (Apple-inspired super-ellipses) */
  --radius-xs: 6px;
  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --radius-2xl: 36px;
  --radius-pill: 9999px;

  /* Spacing Scale */
  --space-1: 0.25rem;   /* 4px */
  --space-2: 0.5rem;    /* 8px */
  --space-3: 0.75rem;   /* 12px */
  --space-4: 1rem;      /* 16px */
  --space-5: 1.25rem;   /* 20px */
  --space-6: 1.5rem;    /* 24px */
  --space-8: 2rem;      /* 32px */
  --space-10: 2.5rem;   /* 40px */
  --space-12: 3rem;     /* 48px */
  --space-16: 4rem;     /* 64px */
  --space-20: 5rem;     /* 80px */
  --space-24: 6rem;     /* 96px */

  /* Layout Max Widths */
  --max-width-content: 1400px;
  --max-width-narrow: 1100px;
  --max-width-prose: 720px;

  /* Transitions & Springs */
  --ease-spring: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);

  --transition-fast: 160ms var(--ease-smooth);
  --transition-base: 240ms var(--ease-smooth);
  --transition-spring: 420ms var(--ease-spring);
  --transition-slow: 600ms var(--ease-spring);

  /* Z-Index Hierarchy */
  --z-negative: -1;
  --z-elevate: 1;
  --z-sticky: 100;
  --z-drawer: 200;
  --z-modal-backdrop: 300;
  --z-modal: 400;
  --z-popover: 500;
  --z-toast: 600;
  --z-tooltip: 700;
}

/* ==========================================================================
   Dark Mode System (Bespoke Linear/Apple Luxury Dark Palette)
   ========================================================================== */
[data-theme="dark"] {
  --bg-app: #080a0f;
  --bg-gradient-mesh: radial-gradient(at 0% 0%, rgba(99, 102, 241, 0.15) 0px, transparent 50%),
                      radial-gradient(at 100% 0%, rgba(245, 158, 11, 0.10) 0px, transparent 50%),
                      radial-gradient(at 50% 50%, rgba(232, 89, 66, 0.08) 0px, transparent 55%),
                      radial-gradient(at 80% 80%, rgba(6, 182, 212, 0.08) 0px, transparent 50%);
  --surface-base: #0f121a;
  --surface-elevated: #151a24;
  --surface-muted: #1a202d;
  --surface-subtle: #131720;
  --surface-active: #222938;

  /* Glassmorphism Dark */
  --glass-bg: rgba(15, 18, 26, 0.82);
  --glass-bg-hover: rgba(21, 26, 36, 0.92);
  --glass-border: rgba(255, 255, 255, 0.09);
  --glass-border-hover: rgba(129, 140, 248, 0.45);
  --glass-highlight: rgba(255, 255, 255, 0.06);
  --glass-blur: blur(20px);

  /* Typography Colors Dark (Enhanced High-Contrast Legibility) */
  --text-primary: #ffffff;
  --text-secondary: #cbd5e1;
  --text-muted: #94a3b8;
  --text-inverse: #080a0f;
  --text-brand: #93c5fd;

  /* Borders & Dividers Dark */
  --border-subtle: rgba(255, 255, 255, 0.07);
  --border-medium: rgba(255, 255, 255, 0.12);
  --border-strong: rgba(255, 255, 255, 0.22);

  /* Shadows Dark */
  --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-sm: 0 2px 5px rgba(0, 0, 0, 0.35);
  --shadow-md: 0 6px 18px -2px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.05);
  --shadow-lg: 0 18px 40px -4px rgba(0, 0, 0, 0.65), 0 0 0 1px rgba(255, 255, 255, 0.07);
  --shadow-xl: 0 28px 60px -8px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(255, 255, 255, 0.09);
  --shadow-glow-primary: 0 8px 32px rgba(99, 102, 241, 0.32);
  --shadow-glow-accent: 0 8px 32px rgba(245, 158, 11, 0.32);

  /* Brand Accents Dark Tuning */
  --brand-primary: #6366f1;
  --brand-primary-hover: #818cf8;
  --brand-primary-light: rgba(99, 102, 241, 0.18);
  --brand-primary-glow: rgba(99, 102, 241, 0.45);

  --brand-accent: #fbbf24;
  --brand-accent-hover: #f59e0b;
  --brand-accent-light: rgba(251, 191, 36, 0.18);
  --brand-accent-glow: rgba(251, 191, 36, 0.38);

  --brand-coral: #fb7185;
  --brand-coral-hover: #f43f5e;
  --brand-coral-light: rgba(251, 113, 133, 0.18);
  --brand-coral-glow: rgba(251, 113, 133, 0.38);

  --brand-celestial: #a78bfa;
  --brand-celestial-light: rgba(167, 139, 250, 0.18);

  --brand-rose: #fb7185;
  --brand-rose-light: rgba(251, 113, 133, 0.18);

  --brand-emerald: #34d399;
  --brand-emerald-light: rgba(52, 211, 153, 0.18);

  --brand-cyan: #22d3ee;
  --brand-cyan-light: rgba(34, 211, 238, 0.18);
}
