/* ==========================================================================
   OpenSale Base Theme — Design Tokens (Step 1)
   Visual Direction: ChatGPT & OpenSale Admin UI
   Clean white surfaces, #F9F9F9 panels, #F4F4F4 pills, #4F3BE4 primary,
   hairline borders, Inter typography, balanced vertical rhythm.
   ========================================================================== */

/* Dong sign: webfonts draw U+20AB small and raised; use a system face that sits on the baseline */
@font-face { font-family: "VND Symbol"; src: local("Segoe UI"), local("Tahoma"), local("Verdana"), local("Helvetica Neue"); unicode-range: U+20AB; }

:root {
  /* Fonts */
  --font-body-family: "VND Symbol", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-heading-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-body-scale: 1;
  --font-heading-scale: 1;

  /* Font Sizes */
  --font-size-2xs: 0.6875rem;
  --font-size-xs: 0.75rem;
  --font-size-sm: 0.875rem;
  --font-size-base: 1rem;
  --font-size-lg: 1.125rem;
  --font-size-xl: 1.25rem;
  --font-size-2xl: 1.5rem;
  --font-size-3xl: 1.875rem;
  --font-size-4xl: 2.25rem;
  --font-size-5xl: 3rem;

  /* Line Heights */
  --line-height-none: 1;
  --line-height-tight: 1.15;
  --line-height-snug: 1.3;
  --line-height-normal: 1.5;
  --line-height-relaxed: 1.65;

  /* Font Weights */
  --font-weight-normal: 400;
  --font-weight-medium: 500;
  --font-weight-semibold: 600;
  --font-weight-bold: 700;

  /* Letter Spacing (Tracking) */
  --tracking-tighter: -0.04em;
  --tracking-tight: -0.02em;
  --tracking-normal: 0em;
  --tracking-wide: 0.02em;
  --tracking-caps: 0.05em;

  /* Aspect Ratios & Opacity */
  --aspect-square: 1 / 1;
  --aspect-product: 4 / 5;
  --aspect-portrait: 3 / 4;
  --aspect-landscape: 4 / 3;
  --aspect-video: 16 / 9;
  --opacity-0: 0;
  --opacity-10: 0.1;
  --opacity-disabled: 0.5;
  --opacity-half: 0.5;
  --opacity-70: 0.7;
  --opacity-subtle: 0.72;
  --opacity-muted: 0.7;
  --opacity-75: 0.75;
  --opacity-100: 1;

  /* Border Widths */
  --border-hairline: 1px;
  --border-emphasis: 2px;

  /* Spacing Scale (0.25rem step) */
  --space-0: 0;
  --space-0-5: 0.125rem;
  --space-1: 0.25rem;
  --space-1-5: 0.375rem;
  --space-2: 0.5rem;
  --space-2-5: 0.625rem;
  --space-3: 0.75rem;
  --space-3-5: 0.875rem;
  --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;

  /* Radii */
  --radius-none: 0px;
  --radius-xs: 0.25rem;
  --radius-sm: 0.5rem;
  --radius-md: 0.75rem;
  --radius-lg: 1rem;
  --radius-xl: 1.25rem;
  --radius-2xl: 1.5rem;
  --radius-full: 9999px;

  /* Semantic Surface & Control Radii */
  --surface-radius: var(--radius-xl);
  --card-radius: var(--radius-lg);
  --control-radius: var(--radius-md);
  --button-radius: var(--radius-full);
  --inputs-border-width: 1px;
  --buttons-border-width: 1px;

  /* Layout & Component Dimensions */
  --max-w-xs: 20rem;
  --max-w-sm: 24rem;
  --max-w-md: 28rem;
  --max-w-lg: 32rem;
  --max-w-xl: 36rem;
  --max-w-2xl: 42rem;
  --max-w-3xl: 48rem;
  --max-w-4xl: 56rem;
  --max-w-5xl: 64rem;
  --max-w-6xl: 72rem;
  --max-w-7xl: 80rem;
  --container-max-width: 78rem;
  --container-narrow-width: 48rem;
  --drawer-width: 26rem;
  --chat-popover-height: 34rem;
  --chat-composer-radius: 1.75rem;
  --chat-composer-btn: 2.25rem;
  --modal-width-sm: 28rem;
  --modal-width-md: 42rem;
  --modal-width-lg: 56rem;
  --target-touch-sm: 2rem;
  --target-touch-md: 2.5rem;
  --target-touch-lg: 3rem;
  --icon-xs: 0.875rem;
  --icon-sm: 1rem;
  --icon-md: 1.25rem;
  --icon-lg: 1.5rem;
  --header-height: 4rem;

  /* Z-Index Scale */
  --z-0: 0;
  --z-10: 10;
  --z-20: 20;
  --z-30: 30;
  --z-40: 40;
  --z-50: 50;
  --z-sticky: 30;
  --z-dropdown: 40;
  --z-drawer: 60;
  --z-modal: 70;
  --z-toast: 80;

  /* Elevation & Shadows */
  --shadow-none: none;
  --shadow-soft: 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-card: 0 4px 16px -2px rgba(0, 0, 0, 0.05), 0 1px 3px rgba(0, 0, 0, 0.03);
  --shadow-md: 0 8px 24px -4px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 16px 40px -8px rgba(0, 0, 0, 0.12);
  --shadow-composer: 0 9px 24px rgba(0, 0, 0, 0.05), 0 2px 6px rgba(0, 0, 0, 0.03);
  --shadow-popup: 0 12px 32px rgba(0, 0, 0, 0.1), 0 2px 6px rgba(0, 0, 0, 0.04);

  /* Motion */
  --duration-fast: 150ms;
  --duration-normal: 260ms;
  --duration-base: 260ms;
  --duration-slow: 420ms;
  --duration-hover: 360ms;
  --duration-reveal: 520ms;
  --duration-700: 700ms;
  --duration-1000: 1000ms;
  --ease-default: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-drawer: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-spring: cubic-bezier(0.34, 1.35, 0.64, 1);
  --ease-motion: var(--ease-out-expo);
  --drawer-transition: transform var(--duration-base) var(--ease-drawer);
  --hover-img-scale: 1.04;
  --hover-lift-y: -2px;
  --zoom-inline-scale: 1.9;
  --lightbox-thumb-size: 3.75rem;
  --lightbox-backdrop: rgba(0, 0, 0, 0.88);
  --reveal-distance: 1rem;
  --logo-width: 7.5rem;
  --preloader-bar-h: 2px;
  --preloader-bar-w: 12rem;
  --preloader-bg: var(--color-background);
  --preloader-track: var(--color-border);
  --preloader-fill: var(--color-primary);
  --color-white-rgb: 255, 255, 255;

  /* OpenSale Admin / ChatGPT Color Palette (Default Scheme 1 Fallback) */
  --color-background: #ffffff;
  --color-surface: #f9f9f9;
  --color-surface-hover: #f4f4f4;
  --color-surface-active: #ebebeb;
  --color-bubble: #f4f4f4;
  --color-foreground: #0d0d0d;
  --color-foreground-secondary: #5d5d5d;
  --color-foreground-muted: #8e8e8e;
  --color-primary: #4f3be4;
  --color-primary-hover: #4338ca;
  --color-primary-soft: #eef2ff;
  --color-primary-foreground: #ffffff;
  --color-border: rgba(0, 0, 0, 0.07);
  --color-border-strong: rgba(0, 0, 0, 0.14);
  --color-backdrop: rgba(0, 0, 0, 0.42);
  --color-success: #10a37f;
  --color-success-bg: #ecfdf5;
  --color-info: #0068ff;
  --color-warning: #d97706;
  --color-warning-bg: #fffbeb;
  --color-danger: #ef4444;
  --color-danger-bg: #fef2f2;
  --focus-ring: 0 0 0 3px rgba(79, 59, 228, 0.18);
}
