/* ========================================================
   LABUR ADDA — UNIFIED PROFESSIONAL DESIGN SYSTEM
   ======================================================== */

/* ===== 1. DESIGN TOKENS & CSS VARIABLES ===== */
:root {
  /* --- Brand Color Palette (Official Yellow + Blue Theme — The Labour's Adda) --- */
  --primary:           #1976D2; /* Deep Trust Blue */ /* Deep Trust Blue */
  --primary-hover:     #1976D2; /* Darker on hover */ /* Darker Trust Blue */
  --primary-light:     #E3F2FD; /* Ice Blue Tint */ /* Crisp Ice Blue Tint */
  --primary-rgb:       25, 118, 210;
  
  --secondary:         #0B192C; /* Midnight Navy */ /* Deep Midnight Navy */
  --secondary-hover:   #0F294A; /* Deep Navy */ /* Dark Navy Surface */
  --secondary-light:   #F8FAFC; /* Clean Light Page Backdrop */
  --secondary-rgb:     11, 25, 44;
  
  --accent:            #FFE066; /* Brand Yellow */ /* Vibrant Energy Brand Yellow */
  --accent-hover:      #F59E0B; /* Amber hover */ /* Golden Amber */
  --accent-light:      #FFF8D6; /* Cream Yellow */ /* Soft Cream Yellow Tint */
  --accent-blue:       #4DA8FF; /* Sky Blue */ /* Electric Sky Blue */
  --accent-gold:       #FFE066; /* Brand Yellow */ /* Warm Amber for Ratings & Deals */
  --accent-yellow:     #FFE066;

  /* --- Text & Content Colors --- */
  --text-primary:      #0F172A; /* Crisp High-Contrast Slate/Navy Black */
  --text-secondary:    #475569; /* Clean Slate Body & Subtitles */
  --text-muted:        #94A3B8; /* Muted Captions & Placeholders */
  --text-inverse:      #FFFFFF;

  /* --- Backgrounds & Surfaces --- */
  --bg-primary:        #FFFFFF; /* Pure White Surface */
  --bg-secondary:      #F8FAFC; /* Clean Light Page Backdrop */
  --card-bg:           #FFFFFF; /* White Card Surface */

  /* --- Borders & Dividers --- */
  --border:            #E2E8F0; /* Soft Crisp Border */
  --border-focus:      #1976D2;
  --divider:           #F1F5F9;

  /* --- Semantic State Colors --- */
  --success:           #1976D2;
  --success-light:     #E3F2FD;
  --warning:           #F59E0B;
  --warning-light:     #FFF8D6;
  --error:             #EF4444;
  --error-light:       #FEE2E2;
  --info:              #1976D2;
  --info-light:        #E3F2FD;

  /* --- Typography Scale (Plus Jakarta Sans & Inter) --- */
  --font-family:       'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --font-weight-regular: 400;
  --font-weight-medium:  500;
  --font-weight-semibold:600;
  --font-weight-bold:    700;
  --font-weight-extrabold: 800;

  /* --- Spacing Scale --- */
  --space-1:  4px;
  --space-2:  8px;
  --space-3:  12px;
  --space-4:  16px;
  --space-5:  20px;
  --space-6:  24px;
  --space-7:  32px;
  --space-8:  40px;
  --space-9:  48px;
  --space-10: 64px;
  --space-11: 80px;
  --space-12: 96px;

  /* --- Border Radius Scale --- */
  --radius-sm:   6px;
  --radius-md:   10px;
  --radius-lg:   14px;
  --radius-xl:   20px;
  --radius-full: 999px;

  /* --- Professional Shadow Scale --- */
  --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.05), 0 1px 2px rgba(15, 23, 42, 0.03);
  --shadow-md: 0 4px 14px rgba(15, 23, 42, 0.07), 0 2px 6px rgba(15, 23, 42, 0.03);
  --shadow-lg: 0 12px 32px rgba(15, 23, 42, 0.09), 0 4px 12px rgba(15, 23, 42, 0.04);
  --shadow-primary: 0 8px 24px rgba(25, 118, 210, 0.28);
  --shadow-amber: 0 6px 20px rgba(245, 158, 11, 0.35);

  /* --- Transitions --- */
  --transition-fast:   all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-smooth: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);

  /* --- Icon Sizing --- */
  --icon-sm:   16px;
  --icon-base: 18px;
  --icon-md:   20px;
  --icon-lg:   24px;
  --icon-xl:   32px;

  /* --- Container Width --- */
  --container-max-width: 1280px;
}

/* ===== 2. GLOBAL RESET & BASE STYLES ===== */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  max-width: 100%;
  overflow-x: clip;
}

body {
  font-family: var(--font-family) !important;
  font-size: 1rem;
  font-weight: var(--font-weight-regular);
  line-height: 1.6;
  color: var(--text-primary);
  background-color: var(--bg-primary);
  margin: 0;
  padding: 0;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  max-width: 100%;
  overflow-x: clip;
}

/* ===== 3. TYPOGRAPHY SCALE ===== */
h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
  font-family: var(--font-family) !important;
  color: var(--text-primary);
  margin-top: 0;
  letter-spacing: -0.02em;
}

h1, .h1 {
  font-size: clamp(2.2rem, 4vw, 3.25rem);
  font-weight: var(--font-weight-bold);
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin-bottom: var(--space-4);
}

h2, .h2 {
  font-size: clamp(1.75rem, 2.8vw, 2.35rem);
  font-weight: var(--font-weight-bold);
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-bottom: var(--space-3);
}

h3, .h3 {
  font-size: clamp(1.25rem, 2vw, 1.55rem);
  font-weight: var(--font-weight-semibold);
  line-height: 1.3;
  margin-bottom: var(--space-3);
}

h4, .h4 {
  font-size: 1.15rem;
  font-weight: var(--font-weight-semibold);
  line-height: 1.35;
  margin-bottom: var(--space-2);
}

h5, .h5 {
  font-size: 1rem;
  font-weight: var(--font-weight-semibold);
  line-height: 1.4;
  margin-bottom: var(--space-2);
}

h6, .h6 {
  font-size: 0.875rem;
  font-weight: var(--font-weight-semibold);
  line-height: 1.4;
  margin-bottom: var(--space-1);
}

p, .body-text {
  font-size: 1rem;
  font-weight: var(--font-weight-regular);
  line-height: 1.6;
  color: var(--text-secondary);
  margin-top: 0;
  margin-bottom: var(--space-4);
}

small, .text-small {
  font-size: 0.875rem;
  font-weight: var(--font-weight-regular);
  line-height: 1.5;
  color: var(--text-secondary);
}

.caption-text {
  font-size: 0.75rem;
  font-weight: var(--font-weight-semibold);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-muted);
}

a {
  color: var(--primary-hover);
  text-decoration: none;
  transition: var(--transition-fast);
}

a:hover {
  color: var(--primary);
}

/* ===== 4. CONTAINER SYSTEM ===== */
.container-ds {
  width: 100%;
  max-width: var(--container-max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--space-4);
  padding-right: var(--space-4);
}

@media (min-width: 768px) {
  .container-ds {
    padding-left: var(--space-6);
    padding-right: var(--space-6);
  }
}

@media (min-width: 1200px) {
  .container-ds {
    padding-left: var(--space-7);
    padding-right: var(--space-7);
  }
}

/* ===== 5. BUTTON SYSTEM ===== */
.btn-ds {
  font-family: var(--font-family);
  font-size: 0.9375rem;
  font-weight: var(--font-weight-semibold);
  line-height: 1.4;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: 10px 22px;
  border-radius: var(--radius-md);
  border: 1.5px solid transparent;
  cursor: pointer;
  text-align: center;
  white-space: nowrap;
  vertical-align: middle;
  user-select: none;
  min-height: 44px;
  transition: var(--transition-normal);
  text-decoration: none !important;
}

.btn-ds:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.3);
}

.btn-ds:disabled, .btn-ds.disabled {
  opacity: 0.55;
  cursor: not-allowed;
  pointer-events: none;
  box-shadow: none;
}

/* Primary Button (Bright Energy Yellow CTA as shown in official brand mockup) */
.btn-primary-ds {
  background: linear-gradient(135deg, #FFE066 0%, #FBBF24 100%);
  color: #0F172A !important;
  border-color: #F59E0B;
  font-weight: var(--font-weight-bold);
  box-shadow: var(--shadow-amber);
}

.btn-primary-ds:hover {
  background: linear-gradient(135deg, #FBBF24 0%, #F59E0B 100%);
  border-color: #D97706;
  color: #0F172A !important;
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(245, 158, 11, 0.45);
}

.btn-primary-ds:active {
  transform: translateY(0);
}

/* Secondary Button (Deep Trust Blue) */
.btn-secondary-ds {
  background: var(--primary);
  color: #ffffff !important;
  border-color: var(--primary);
  font-weight: var(--font-weight-semibold);
  box-shadow: var(--shadow-sm);
}

.btn-secondary-ds:hover {
  background: var(--primary-hover);
  border-color: var(--primary-hover);
  color: #ffffff !important;
  transform: translateY(-1px);
  box-shadow: var(--shadow-primary);
}

/* Outline Button */
.btn-outline-ds {
  background: transparent;
  color: var(--text-primary) !important;
  border-color: var(--border);
}

.btn-outline-ds:hover {
  background: var(--bg-secondary);
  border-color: var(--text-secondary);
  color: var(--text-primary) !important;
  transform: translateY(-1px);
}

/* Outline Primary */
.btn-outline-primary-ds {
  background: transparent;
  color: var(--primary-hover) !important;
  border-color: var(--primary);
}

.btn-outline-primary-ds:hover {
  background: var(--primary-light);
  color: var(--primary-hover) !important;
  border-color: var(--primary-hover);
}

/* Ghost Button */
.btn-ghost-ds {
  background: transparent;
  color: var(--text-secondary) !important;
  border-color: transparent;
  padding-left: var(--space-3);
  padding-right: var(--space-3);
}

.btn-ghost-ds:hover {
  background: var(--secondary-light);
  color: var(--text-primary) !important;
}

/* Button Sizes */
.btn-sm-ds {
  font-size: 0.8125rem;
  padding: 6px 14px;
  min-height: 36px;
  border-radius: var(--radius-sm);
}

.btn-lg-ds {
  font-size: 1.0625rem;
  padding: 14px 28px;
  min-height: 52px;
  border-radius: var(--radius-lg);
}

/* ===== 6. UNIVERSAL CARD COMPONENT ===== */
.card-ds {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  box-shadow: var(--shadow-sm);
  transition: var(--transition-smooth);
  position: relative;
  overflow: hidden;
}

.card-ds:hover {
  border-color: rgba(var(--primary-rgb), 0.4);
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}

.card-ds-flat {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  box-shadow: none;
}

/* ===== 7. INPUT & FORM SYSTEM ===== */
.form-group-ds {
  margin-bottom: var(--space-4);
}

.form-label-ds {
  display: block;
  font-size: 0.875rem;
  font-weight: var(--font-weight-medium);
  color: var(--text-primary);
  margin-bottom: var(--space-2);
}

.form-input-ds,
.form-select-ds,
.form-textarea-ds {
  width: 100%;
  font-family: var(--font-family);
  font-size: 0.9375rem;
  font-weight: var(--font-weight-regular);
  color: var(--text-primary);
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 10px 16px;
  min-height: 44px;
  outline: none;
  transition: var(--transition-fast);
  box-shadow: var(--shadow-sm);
}

.form-input-ds::placeholder,
.form-textarea-ds::placeholder {
  color: var(--text-muted);
}

.form-input-ds:focus,
.form-select-ds:focus,
.form-textarea-ds:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.2);
}

.form-input-ds:disabled,
.form-select-ds:disabled,
.form-textarea-ds:disabled {
  background: var(--bg-secondary);
  color: var(--text-muted);
  cursor: not-allowed;
  border-color: var(--border);
}

.form-input-ds.is-error,
.form-select-ds.is-error {
  border-color: var(--error);
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.15);
}

.form-input-ds.is-success,
.form-select-ds.is-success {
  border-color: var(--success);
  box-shadow: 0 0 0 3px rgba(25, 118, 210, 0.15);
}

.form-error-msg {
  font-size: 0.8125rem;
  font-weight: var(--font-weight-medium);
  color: var(--error);
  margin-top: var(--space-1);
  display: flex;
  align-items: center;
  gap: var(--space-1);
}

/* ===== 8. BADGES & TAGS SYSTEM ===== */
.badge-ds {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: var(--font-weight-semibold);
  line-height: 1;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.badge-primary-ds {
  background: var(--primary-light);
  color: var(--primary-hover);
  border: 1px solid rgba(var(--primary-rgb), 0.2);
}

.badge-secondary-ds {
  background: var(--secondary-light);
  color: var(--secondary);
}

.badge-success-ds {
  background: var(--success-light);
  color: var(--success);
  border: 1px solid rgba(25, 118, 210, 0.2);
}

.badge-warning-ds {
  background: var(--warning-light);
  color: #b45309;
}

.badge-error-ds {
  background: var(--error-light);
  color: var(--error);
}

.badge-info-ds {
  background: var(--info-light);
  color: var(--info);
}

/* ===== 9. SECTION HEADINGS ===== */
.section-header-ds {
  margin-bottom: var(--space-8);
}

.eyebrow-ds {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: 0.75rem;
  font-weight: var(--font-weight-bold);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--primary-hover);
  background: var(--primary-light);
  padding: 5px 14px;
  border-radius: var(--radius-full);
  margin-bottom: var(--space-3);
  border: 1px solid rgba(var(--primary-rgb), 0.2);
}

.section-title-ds {
  font-size: clamp(1.75rem, 2.8vw, 2.35rem);
  font-weight: var(--font-weight-bold);
  color: var(--text-primary);
  letter-spacing: -0.02em;
  margin-bottom: var(--space-2);
}

.section-desc-ds {
  font-size: 1.05rem;
  font-weight: var(--font-weight-regular);
  color: var(--text-secondary);
  max-width: 620px;
  margin-top: 0;
  margin-bottom: 0;
}

/* ===== 10. PRICE TYPOGRAPHY ===== */
.price-tag-ds {
  display: flex;
  align-items: baseline;
  gap: var(--space-2);
}

.price-current-ds {
  font-size: 1.25rem;
  font-weight: var(--font-weight-bold);
  color: var(--text-primary);
}

.price-old-ds {
  font-size: 0.9375rem;
  font-weight: var(--font-weight-regular);
  color: var(--text-muted);
  text-decoration: line-through;
}

.price-unit-ds {
  font-size: 0.75rem;
  font-weight: var(--font-weight-medium);
  color: var(--text-secondary);
}

/* ===== 11. SEARCH BAR COMPONENT ===== */
.search-box-ds {
  display: flex;
  align-items: center;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  padding: 4px 6px 4px 18px;
  transition: var(--transition-fast);
  box-shadow: var(--shadow-sm);
}

.search-box-ds:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.2);
}

.search-box-ds input {
  flex: 1;
  border: none;
  background: transparent;
  outline: none;
  font-family: var(--font-family);
  font-size: 0.9375rem;
  color: var(--text-primary);
}

.search-box-ds input::placeholder {
  color: var(--text-muted);
}

/* ===== 12. UNIFIED ICON SIZES ===== */
.icon-sm   { width: var(--icon-sm); height: var(--icon-sm); font-size: var(--icon-sm); }
.icon-base { width: var(--icon-base); height: var(--icon-base); font-size: var(--icon-base); }
.icon-md   { width: var(--icon-md); height: var(--icon-md); font-size: var(--icon-md); }
.icon-lg   { width: var(--icon-lg); height: var(--icon-lg); font-size: var(--icon-lg); }
.icon-xl   { width: var(--icon-xl); height: var(--icon-xl); font-size: var(--icon-xl); }

/* ===== 13. ACCESSIBILITY FOCUS RING ===== */
:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
