/**
 * CraftsCanvas Global Design Tokens
 * Plan. Calculate. Visualize. Make.
 * Premium modern maker/product toolkit aesthetic.
 */

:root {
    /* ==========================================================================
       1. Brand Palette
       ========================================================================== */
    --cc-teal-primary: #007979;
    --cc-teal-light: #24B1B1;
    --cc-teal-dark: #004D4D;
    --cc-teal-ultra-light: #E6F7F7;
    --cc-teal-50: #F0FDFD;
    --cc-teal-100: #CCFBFB;
    --cc-teal-200: #99F6F6;
    --cc-teal-700: #006060;
    --cc-teal-900: #003838;

    /* Primary aliases */
    --cc-primary: #007979;
    --cc-primary-light: #24B1B1;
    --cc-primary-dark: #004D4D;
    --cc-primary-ultra-light: #E6F7F7;

    /* Brand Accent Orange */
    --cc-orange: #E37434;
    --cc-orange-hover: #C95E20;
    --cc-orange-light: #FDF1EA;
    --cc-orange-ultra-light: #FFF8F5;
    --cc-orange-50: #FFF7ED;
    --cc-orange-100: #FFEDD5;
    --cc-orange-600: #D9621E;
    --cc-orange-900: #7C2D12;

    /* Brand Warm Cream */
    --cc-cream: #FFE2AF;
    --cc-cream-light: #FFF9EE;
    --cc-cream-ultra-light: #FFFCF7;
    --cc-cream-dark: #F5D397;
    --cc-cream-border: #F0D5A0;

    /* Neutrals, Surfaces & Backgrounds */
    --cc-bg-page: #F8FAFC;
    --cc-bg-surface: #FFFFFF;
    --cc-bg-surface-alt: #F1F5F9;
    --cc-bg-surface-muted: #E2E8F0;
    --cc-border: #E2E8F0;
    --cc-border-light: #F1F5F9;
    --cc-border-dark: #CBD5E1;
    --cc-border-focus: #007979;

    /* Text & Content */
    --cc-text-main: #0F172A;
    --cc-text-muted: #475569;
    --cc-text-light: #64748B;
    --cc-text-subtle: #94A3B8;
    --cc-text-inverse: #FFFFFF;

    /* Status & Feedback Semantic Roles */
    --cc-success: #16A34A;
    --cc-success-bg: #F0FDF4;
    --cc-success-border: #BBF7D0;
    --cc-success-text: #14532D;
    
    --cc-warning: #D97706;
    --cc-warning-bg: #FFFBEB;
    --cc-warning-border: #FDE68A;
    --cc-warning-text: #78350F;
    
    --cc-error: #DC2626;
    --cc-error-bg: #FEF2F2;
    --cc-error-border: #FECACA;
    --cc-error-text: #7F1D1D;

    --cc-info: #0284C7;
    --cc-info-bg: #F0F9FF;
    --cc-info-border: #BAE6FD;
    --cc-info-text: #0C4A6E;

    /* Interactive & State Tokens */
    --cc-disabled-bg: #F1F5F9;
    --cc-disabled-text: #94A3B8;
    --cc-disabled-border: #E2E8F0;
    --cc-focus-ring: 0 0 0 3px rgba(0, 121, 121, 0.25);
    --cc-focus-ring-error: 0 0 0 3px rgba(220, 38, 38, 0.25);

    /* Z-Index Layers */
    --cc-z-dropdown: 1000;
    --cc-z-sticky: 1020;
    --cc-z-header: 1030;
    --cc-z-drawer-backdrop: 1040;
    --cc-z-drawer: 1050;
    --cc-z-modal: 1060;


    /* ==========================================================================
       2. Typography Families & Scale
       ========================================================================== */
    --cc-font-heading: 'Bricolage Grotesque', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --cc-font-body: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --cc-font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;

    /* Semantic Fluid Typography Scale */
    --cc-text-display: clamp(2.4rem, 4.5vw, 3.5rem);
    --cc-text-h1: clamp(1.85rem, 3.5vw, 2.65rem);
    --cc-text-h2: clamp(1.4rem, 2.4vw, 1.95rem);
    --cc-text-h3: clamp(1.15rem, 1.8vw, 1.45rem);
    --cc-text-h4: 1.125rem;     /* 18px */
    --cc-text-base: 1rem;       /* 16px */
    --cc-text-sm: 0.875rem;     /* 14px */
    --cc-text-xs: 0.75rem;      /* 12px */

    /* Legacy Aliases */
    --cc-text-2xl: var(--cc-text-h3);
    --cc-text-3xl: var(--cc-text-h2);
    --cc-text-4xl: var(--cc-text-h1);
    --cc-text-5xl: var(--cc-text-display);
    --cc-text-6xl: clamp(2.75rem, 5vw + 1rem, 3.75rem);
    --cc-text-lg: 1.125rem;
    --cc-text-xl: 1.25rem;

    /* Line Heights */
    --cc-leading-tight: 1.15;
    --cc-leading-snug: 1.3;
    --cc-leading-normal: 1.6;
    --cc-leading-relaxed: 1.75;

    /* ==========================================================================
       3. Centralized Layout Containers & Gutters
       ========================================================================== */
    --cc-container-site: 1320px;
    --cc-container-standard: 1180px;
    --cc-container-editorial: 800px;
    --cc-container-prose: var(--cc-container-editorial);
    --cc-container-breakout: 1440px;
    /* Compatibility aliases for existing components. */
    --cc-container-global: var(--cc-container-standard);
    --cc-container-wide: var(--cc-container-site);
    --cc-container-narrow: 640px;

    --cc-grid-columns: 12;
    --cc-grid-gap: 24px;

    /* Standardized Responsive Page Gutters */
    --cc-gutter-desktop: 32px;
    --cc-gutter-tablet: 24px;
    --cc-gutter-mobile: 20px;

    /* Header & Hero Heights */
    --cc-header-height-desktop: 72px;
    --cc-header-height-mobile: 60px;

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

    /* Border Radii */
    --cc-radius-xs: 4px;
    --cc-radius-sm: 6px;
    --cc-radius-md: 10px;
    --cc-radius-lg: 16px;
    --cc-radius-xl: 24px;
    --cc-radius-2xl: 32px;
    --cc-radius-full: 9999px;

    /* Shadows */
    --cc-shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.04);
    --cc-shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.06), 0 1px 2px rgba(15, 23, 42, 0.04);
    --cc-shadow-md: 0 4px 6px -1px rgba(15, 23, 42, 0.07), 0 2px 4px -1px rgba(15, 23, 42, 0.04);
    --cc-shadow-lg: 0 10px 15px -3px rgba(15, 23, 42, 0.08), 0 4px 6px -2px rgba(15, 23, 42, 0.03);
    --cc-shadow-xl: 0 20px 25px -5px rgba(15, 23, 42, 0.08), 0 8px 10px -6px rgba(15, 23, 42, 0.03);
    --cc-shadow-card-hover: 0 12px 24px -4px rgba(0, 121, 121, 0.12), 0 4px 8px -2px rgba(15, 23, 42, 0.04);

    /* Animation Transitions */
    --cc-transition-fast: all 0.15s cubic-bezier(0.16, 1, 0.3, 1);
    --cc-transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    --cc-transition-slow: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
