/*
 * YourCart Design System — CSS Variables & Design Tokens
 * Source: design-system.css: 1 - 100
 */

/* ─── CSS Custom Properties ─────────────────────────────────────────────────── */
:root {
  /* Primary Brand */
  --ycc-blue-600:     #2563eb;
  --ycc-blue-700:     #1d4ed8;
  --ycc-blue-400:     #60a5fa;
  --ycc-blue-100:     #dbeafe;
  --ycc-blue-50:      #eff6ff;

  /* Semantic Color Aliases */
  --ycc-color-primary:       var(--ycc-blue-600);
  --ycc-color-primary-hover: var(--ycc-blue-700);
  --ycc-color-text:          var(--ycc-text);
  --ycc-color-muted:         var(--ycc-text-muted);
  --ycc-color-border:        var(--ycc-border);

  /* Backgrounds */
  --ycc-bg:           #f8fafc;   /* slate-50  — light page bg */
  --ycc-bg-dark:      #020617;   /* slate-950 — dark page bg  */
  --ycc-surface:      #ffffff;
  --ycc-surface-dark: #0f172a;   /* slate-900 */
  --ycc-slate-850:    #151e2e;   /* custom extension */

  /* Text */
  --ycc-text:         #0f172a;   /* slate-900 */
  --ycc-text-dark:    #f1f5f9;   /* slate-100 */
  --ycc-text-muted:   #64748b;   /* slate-500 */
  --ycc-text-muted-dark: #94a3b8; /* slate-400 */

  /* Borders */
  --ycc-border:       #e2e8f0;   /* slate-200 */
  --ycc-border-dark:  #1e293b;   /* slate-800 */

  /* Semantic */
  --ycc-deal:         #f97316;   /* orange-500 — deal badge */
  --ycc-success:      #16a34a;   /* green-600  */
  --ycc-success-bg:   #f0fdf4;   /* green-50   */
  --ycc-success-text: #15803d;   /* green-700  */
  --ycc-wishlist:     #ec4899;   /* pink-500   */
  --ycc-error:        #dc2626;   /* red-600    */
  --ycc-error-bg:     #fef2f2;   /* red-50     */
  --ycc-error-text:   #991b1b;   /* red-800    */
  --ycc-warning:      #d97706;   /* amber-600  */

  /* Slate scale */
  --ycc-slate-50:     #f8fafc;
  --ycc-slate-100:    #f1f5f9;
  --ycc-slate-200:    #e2e8f0;
  --ycc-slate-300:    #cbd5e1;
  --ycc-slate-400:    #94a3b8;
  --ycc-slate-500:    #64748b;
  --ycc-slate-600:    #475569;
  --ycc-slate-700:    #334155;
  --ycc-slate-800:    #1e293b;
  --ycc-slate-900:    #0f172a;
  --ycc-slate-950:    #020617;

  /* Typography */
  --ycc-font:         'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --ycc-font-size-base: 16px;
  --ycc-line-height:  1.625;

  /* Border Radii */
  --ycc-radius-sm:    4px;
  --ycc-radius-md:    6px;    /* tags, badges */
  --ycc-radius-lg:    8px;
  --ycc-radius-xl:    12px;   /* cards */
  --ycc-radius-2xl:   16px;   /* sections */
  --ycc-radius-3xl:   24px;   /* auth modal */
  --ycc-radius-full:  9999px; /* pills */

  /* Shadows */
  --ycc-shadow-sm:    0 1px 2px 0 rgb(0 0 0 / 0.05);
  --ycc-shadow:       0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
  --ycc-shadow-md:    0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --ycc-shadow-lg:    0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  --ycc-shadow-xl:    0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
  --ycc-shadow-blue:  0 10px 15px -3px rgb(37 99 235 / 0.2), 0 4px 6px -4px rgb(37 99 235 / 0.2);

  /* Transitions */
  --ycc-transition:   all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  --ycc-transition-md: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);

  /* Layout */
  --ycc-max-width:        80rem;  /* max-w-7xl = 1280px */
  --ycc-container-px:     1rem;
  --ycc-container-width:  1280px;
  --ycc-container-gutter: 16px;
  --ycc-navbar-h:         64px;   /* h-16 */

  /* Control Heights */
  --ycc-control-h-sm: 36px;
  --ycc-control-h-md: 42px;
  --ycc-control-h-lg: 48px;

  /* Accessible Focus Ring */
  --ycc-focus-ring: 0 0 0 2px rgba(37, 99, 235, 0.4);
}

/* ─── Responsive Layout Overrides ────────────────────────────────────────────── */
@media (min-width: 640px) {
  :root {
    --ycc-container-gutter: 24px;
  }
}
@media (min-width: 1024px) {
  :root {
    --ycc-container-gutter: 32px;
  }
}

/* ─── Dark Mode Variables ────────────────────────────────────────────────────── */
html.dark {
  --ycc-bg:           #020617;
  --ycc-surface:      #0f172a;
  --ycc-text:         #f1f5f9;
  --ycc-text-muted:   #94a3b8;
  --ycc-border:       #1e293b;
  --ycc-focus-ring:   0 0 0 2px rgba(96, 165, 250, 0.5);
}
