/* ============================================================
   LUGGAGE COVER BD — Brand CSS
   Blue/Purple Gradient Theme | Version 1.0
   ============================================================ */

/* --- Google Fonts --- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=Poppins:wght@400;500;600;700;800&display=swap');

/* --- CSS Custom Properties (Brand Tokens) --- */
:root {
  /* Brand Gradient Colors */
  --brand-blue: #4A90E2;
  --brand-purple: #7B68EE;
  --brand-teal: #40E0D0;
  --brand-navy: #1a1f3a;
  --brand-dark: #0f1224;
  --brand-black: #0a0c1a;

  /* Gradient Definitions */
  --gradient-primary: linear-gradient(135deg, #4A90E2 0%, #7B68EE 100%);
  --gradient-teal: linear-gradient(135deg, #40E0D0 0%, #4A90E2 100%);
  --gradient-dark: linear-gradient(135deg, #1a1f3a 0%, #0f1224 100%);
  --gradient-purple: linear-gradient(135deg, #7B68EE 0%, #9B59B6 100%);
  --gradient-hero: linear-gradient(135deg, #0f1224 0%, #1a1f3a 40%, #2d2060 100%);

  /* Text Colors */
  --text-white: #ffffff;
  --text-light: #e8eaf6;
  --text-muted: #9fa8c7;
  --text-dark: #1a1f3a;
  --text-body: #2c3060;

  /* UI Colors */
  --success: #27ae60;
  --warning: #f39c12;
  --danger: #e74c3c;
  --info: #3498db;

  /* Surface Colors */
  --surface-card: rgba(255,255,255,0.05);
  --surface-hover: rgba(255,255,255,0.08);
  --surface-light: #f8f9ff;
  --border-color: rgba(255,255,255,0.1);
  --border-light: #e1e5f5;

  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(74,144,226,0.15);
  --shadow-md: 0 8px 32px rgba(74,144,226,0.2);
  --shadow-lg: 0 16px 48px rgba(74,144,226,0.25);
  --shadow-card: 0 4px 20px rgba(0,0,0,0.3);

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

  /* Border Radius */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;

  /* Typography */
  --font-main: 'Inter', sans-serif;
  --font-heading: 'Poppins', sans-serif;
}

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; font-size: 16px; }

body {
  font-family: var(--font-main);
  color: var(--text-dark);
  background: #ffffff;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
button { cursor: pointer; border: none; outline: none; font-family: inherit; }
input, select, textarea { font-family: inherit; outline: none; border: none; }

/* --- Typography Utilities --- */
.font-heading { font-family: var(--font-heading); }
.text-gradient {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.text-gradient-teal {
  background: var(--gradient-teal);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* --- Brand Button Styles --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: 0.95rem;
  transition: var(--transition);
  cursor: pointer;
  border: none;
  font-family: var(--font-main);
}

.btn-primary {
  background: var(--gradient-primary);
  color: var(--text-white);
  box-shadow: 0 4px 20px rgba(74,144,226,0.4);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(74,144,226,0.5);
}

.btn-teal {
  background: var(--gradient-teal);
  color: var(--text-dark);
  box-shadow: 0 4px 20px rgba(64,224,208,0.3);
  font-weight: 700;
}
.btn-teal:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(64,224,208,0.4);
}

.btn-outline {
  background: transparent;
  border: 2px solid var(--brand-blue);
  color: var(--brand-blue);
}
.btn-outline:hover {
  background: var(--gradient-primary);
  border-color: transparent;
  color: white;
  transform: translateY(-2px);
}

.btn-outline-white {
  background: transparent;
  border: 2px solid rgba(255,255,255,0.4);
  color: white;
}
.btn-outline-white:hover {
  background: rgba(255,255,255,0.1);
  border-color: white;
}

.btn-dark {
  background: var(--brand-navy);
  color: var(--text-white);
}
.btn-dark:hover {
  background: var(--brand-dark);
  transform: translateY(-2px);
}

.btn-sm { padding: 8px 20px; font-size: 0.85rem; }
.btn-lg { padding: 16px 40px; font-size: 1.05rem; }
.btn-icon { width: 40px; height: 40px; padding: 0; justify-content: center; border-radius: 50%; }

/* --- Card Styles --- */
.card {
  background: white;
  border-radius: var(--radius-lg);
  box-shadow: 0 2px 16px rgba(0,0,0,0.08);
  overflow: hidden;
  transition: var(--transition);
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.card-dark {
  background: var(--surface-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  transition: var(--transition);
}
.card-dark:hover {
  background: var(--surface-hover);
  transform: translateY(-4px);
}

/* --- Badge --- */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}
.badge-primary { background: rgba(74,144,226,0.15); color: var(--brand-blue); }
.badge-success { background: rgba(39,174,96,0.12); color: var(--success); }
.badge-warning { background: rgba(243,156,18,0.12); color: var(--warning); }
.badge-danger { background: rgba(231,76,60,0.12); color: var(--danger); }
.badge-teal { background: rgba(64,224,208,0.15); color: #20bdb0; }
.badge-purple { background: rgba(123,104,238,0.15); color: var(--brand-purple); }

/* --- Form Styles --- */
.form-group { margin-bottom: 20px; }
.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text-dark);
}
.form-control {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid var(--border-light);
  border-radius: var(--radius-md);
  font-size: 0.95rem;
  transition: var(--transition-fast);
  background: white;
  color: var(--text-dark);
}
.form-control:focus {
  border-color: var(--brand-blue);
  box-shadow: 0 0 0 3px rgba(74,144,226,0.15);
}
.form-control::placeholder { color: #aab0cc; }

/* --- Section Styles --- */
.section { padding: 80px 0; }
.section-dark { background: var(--gradient-dark); color: white; }
.section-navy { background: var(--brand-navy); color: white; }
.section-light { background: var(--surface-light); }

.section-header { text-align: center; margin-bottom: 56px; }
.section-title {
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 3vw, 2.8rem);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 16px;
}
.section-subtitle {
  font-size: 1.1rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto;
}

/* --- Container --- */
.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 20px;
}

/* --- Grid Utilities --- */
.grid { display: grid; }
.grid-2 { grid-template-columns: repeat(2, 1fr); gap: 24px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); gap: 24px; }
.grid-4 { grid-template-columns: repeat(4, 1fr); gap: 24px; }

/* --- Flex Utilities --- */
.flex { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.flex-col { display: flex; flex-direction: column; }
.gap-8 { gap: 8px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }
.gap-24 { gap: 24px; }

/* --- Promo Bar --- */
.promo-bar {
  background: var(--gradient-primary);
  color: white;
  text-align: center;
  padding: 10px 20px;
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.3px;
}
.promo-bar span { background: rgba(255,255,255,0.2); padding: 2px 10px; border-radius: 20px; margin: 0 8px; }

/* --- Product Card (Shared) --- */
.product-card {
  background: white;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 2px 16px rgba(0,0,0,0.08);
  transition: var(--transition);
  position: relative;
}
.product-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 40px rgba(74,144,226,0.2);
}
.product-card-image {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4/3;
  background: linear-gradient(135deg, #f0f3ff 0%, #e8ecfc 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 5rem;
}
.product-card-body { padding: 16px; }
.product-card-code {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 4px;
}
.product-card-name {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1rem;
  color: var(--text-dark);
  margin-bottom: 4px;
}
.product-card-price {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--brand-blue);
}
.product-card-price small {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-muted);
}

/* --- Emoji placeholder for products --- */
.product-emoji-bg {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 4rem;
}

/* --- Toast Notifications --- */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.toast {
  background: var(--brand-navy);
  color: white;
  padding: 14px 20px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 280px;
  max-width: 360px;
  font-size: 0.9rem;
  animation: slideInRight 0.3s ease;
}
.toast-success { border-left: 4px solid var(--success); }
.toast-error { border-left: 4px solid var(--danger); }
.toast-info { border-left: 4px solid var(--brand-blue); }

@keyframes slideInRight {
  from { transform: translateX(100px); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}
@keyframes fadeOut {
  from { opacity: 1; }
  to { opacity: 0; transform: translateX(100px); }
}

/* --- Modal --- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(4px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal-box {
  background: white;
  border-radius: var(--radius-xl);
  padding: 32px;
  max-width: 520px;
  width: 100%;
  position: relative;
  animation: modalIn 0.3s ease;
}
@keyframes modalIn {
  from { opacity: 0; transform: scale(0.9) translateY(20px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}
.modal-close {
  position: absolute;
  top: 16px; right: 16px;
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--surface-light);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  font-size: 1rem;
  color: var(--text-muted);
  transition: var(--transition-fast);
}
.modal-close:hover { background: #f0f0f0; color: var(--text-dark); }

/* --- Loading Spinner --- */
.spinner {
  width: 40px; height: 40px;
  border: 3px solid rgba(74,144,226,0.2);
  border-top-color: var(--brand-blue);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.loading-overlay {
  position: fixed; inset: 0;
  background: rgba(255,255,255,0.9);
  z-index: 9000;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 16px;
}

/* --- Scrollbar Styling --- */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: #f0f3ff; }
::-webkit-scrollbar-thumb { background: var(--brand-blue); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--brand-purple); }

/* --- Utility Classes --- */
.hidden { display: none !important; }
.visible { display: block !important; }
.mt-auto { margin-top: auto; }
.text-center { text-align: center; }
.text-right { text-align: right; }
.w-full { width: 100%; }
.h-full { height: 100%; }
.relative { position: relative; }
.overflow-hidden { overflow: hidden; }
.rounded { border-radius: var(--radius-md); }
.rounded-full { border-radius: var(--radius-full); }

/* --- Divider --- */
.divider { height: 1px; background: var(--border-light); margin: 24px 0; }
.divider-dark { background: var(--border-color); }

/* --- Price Display --- */
.price-tag {
  font-family: var(--font-heading);
  font-weight: 800;
  color: var(--brand-blue);
}
.price-tag.large { font-size: 2rem; }
.price-tag .currency { font-size: 0.7em; }

/* --- Star Rating --- */
.stars { color: #ffc107; letter-spacing: 2px; }

/* --- Responsive Breakpoints --- */
@media (max-width: 1200px) {
  .grid-4 { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 992px) {
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .section { padding: 60px 0; }
}
@media (max-width: 768px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .section { padding: 48px 0; }
  .section-title { font-size: 1.6rem; }
  .btn-lg { padding: 14px 32px; }
}
@media (max-width: 480px) {
  .container { padding: 0 16px; }
}
