/* ================================================================
   AuraLoop — Shared Styles v2.0
   ================================================================ */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,600;0,700;0,900;1,400;1,600&family=Inter:wght@300;400;500;600;700&display=swap');

/* ── RESET ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', system-ui, sans-serif;
  background: #060410;
  color: #e2e2e8;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* ── VARIABLES ── */
:root {
  --purple-light: #c084fc;
  --purple-mid: #a855f7;
  --purple-dark: #7c3aed;
  --pink: #d946ef;
  --gold: #fbbf24;
  --bg-dark: #060410;
  --bg-card: rgba(18, 14, 36, 0.85);
  --bg-card-hover: rgba(26, 20, 50, 0.95);
  --border: rgba(255, 255, 255, 0.08);
  --border-hover: rgba(192, 132, 252, 0.3);
  --text-primary: #e2e2e8;
  --text-secondary: rgba(255, 255, 255, 0.55);
  --text-muted: rgba(255, 255, 255, 0.3);
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --shadow-purple: 0 8px 40px rgba(120, 60, 220, 0.35);
  --transition: all 0.25s ease;
}

/* ── SCROLLBAR ── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: rgba(255, 255, 255, 0.03); }
::-webkit-scrollbar-thumb { background: rgba(192, 132, 252, 0.3); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: rgba(192, 132, 252, 0.5); }

/* ── SELECTION ── */
::selection { background: rgba(192, 132, 252, 0.25); color: #fff; }

/* ── TYPOGRAPHY ── */
.serif { font-family: 'Playfair Display', serif; }
.gradient-text {
  background: linear-gradient(160deg, #ffffff 0%, #f0e6ff 25%, #c084fc 55%, #e879f9 75%, #fbbf24 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── NAVBAR ── */
.navbar {
  position: sticky;
  top: 0;
  z-index: 200;
  background: rgba(6, 4, 16, 0.92);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-bottom: 1px solid var(--border);
  padding: 0 5vw;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-family: 'Playfair Display', serif;
  font-size: 22px;
  font-weight: 700;
  color: #fff;
  text-decoration: none;
  letter-spacing: 0.02em;
}
.nav-logo span { color: var(--purple-light); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 36px;
  list-style: none;
}
.nav-links a {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-secondary);
  text-decoration: none;
  transition: var(--transition);
  position: relative;
}
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--purple-light);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.3s ease;
}
.nav-links a:hover { color: rgba(255, 255, 255, 0.9); }
.nav-links a:hover::after, .nav-links a.active::after { transform: scaleX(1); transform-origin: left; }
.nav-links a.active { color: var(--purple-light); }

.nav-cart-btn {
  position: relative;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 8px 16px;
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 8px;
}
.nav-cart-btn:hover { border-color: var(--purple-light); color: var(--purple-light); }
.cart-count {
  background: var(--purple-dark);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Mobile Nav Toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: #fff;
  border-radius: 2px;
  transition: var(--transition);
}
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.mobile-menu {
  display: none;
  position: fixed;
  inset: 0;
  top: 72px;
  background: rgba(6, 4, 16, 0.98);
  backdrop-filter: blur(24px);
  z-index: 199;
  padding: 40px 5vw;
  flex-direction: column;
  gap: 0;
}
.mobile-menu.open { display: flex; }
.mobile-menu a {
  font-size: 18px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.75);
  text-decoration: none;
  padding: 18px 0;
  border-bottom: 1px solid var(--border);
  transition: var(--transition);
}
.mobile-menu a:hover, .mobile-menu a.active { color: var(--purple-light); }

/* ── BUTTONS ── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 28px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
  border: none;
  text-decoration: none;
  transition: var(--transition);
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}
.btn-primary {
  background: linear-gradient(135deg, var(--purple-dark), var(--purple-mid), var(--pink));
  color: #fff;
  box-shadow: 0 0 0 1px rgba(192, 132, 252, 0.2), var(--shadow-purple);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 0 1px rgba(192, 132, 252, 0.4), 0 16px 60px rgba(120, 60, 220, 0.55);
}
.btn-secondary {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border);
}
.btn-secondary:hover {
  color: rgba(255, 255, 255, 0.9);
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-2px);
}
.btn-outline-purple {
  background: transparent;
  color: var(--purple-light);
  border: 1px solid rgba(192, 132, 252, 0.4);
}
.btn-outline-purple:hover {
  background: rgba(192, 132, 252, 0.1);
  border-color: var(--purple-light);
  transform: translateY(-2px);
}
.btn:active { transform: translateY(0) !important; }
.btn-sm { padding: 8px 18px; font-size: 11px; }
.btn-lg { padding: 16px 40px; font-size: 13px; }
.btn-full { width: 100%; }

/* ── CARDS ── */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  transition: var(--transition);
}
.card:hover {
  border-color: var(--border-hover);
  transform: translateY(-3px);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

/* ── SECTION ── */
.section { padding: 80px 5vw; }
.section-sm { padding: 48px 5vw; }
.section-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(28px, 4vw, 48px);
  font-weight: 700;
  color: #fff;
  margin-bottom: 12px;
}
.section-subtitle {
  font-size: 15px;
  color: var(--text-secondary);
  max-width: 560px;
  line-height: 1.7;
}
.section-header { margin-bottom: 48px; }

/* ── BADGE ── */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.badge-purple { background: rgba(192, 132, 252, 0.15); color: var(--purple-light); border: 1px solid rgba(192, 132, 252, 0.25); }
.badge-green { background: rgba(34, 197, 94, 0.12); color: #4ade80; border: 1px solid rgba(34, 197, 94, 0.2); }
.badge-red { background: rgba(239, 68, 68, 0.12); color: #f87171; border: 1px solid rgba(239, 68, 68, 0.2); }
.badge-gold { background: rgba(251, 191, 36, 0.12); color: var(--gold); border: 1px solid rgba(251, 191, 36, 0.2); }

/* ── FORM ── */
.form-group { display: flex; flex-direction: column; gap: 8px; }
.form-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-secondary);
}
.form-input, .form-select, .form-textarea {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  color: #fff;
  font-size: 14px;
  font-family: inherit;
  outline: none;
  transition: var(--transition);
  width: 100%;
}
.form-input:focus, .form-select:focus, .form-textarea:focus {
  border-color: rgba(192, 132, 252, 0.5);
  box-shadow: 0 0 0 4px rgba(192, 132, 252, 0.08);
}
.form-input::placeholder, .form-textarea::placeholder { color: var(--text-muted); }
.form-select option { background: #1a1428; }
.form-textarea { min-height: 120px; resize: vertical; }

/* ── LOADER ── */
#page-loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: var(--bg-dark);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 24px;
  transition: opacity 0.6s ease, visibility 0.6s;
}
#page-loader.hidden { opacity: 0; visibility: hidden; }
.loader-logo {
  font-family: 'Playfair Display', serif;
  font-size: 40px;
  font-weight: 700;
  background: linear-gradient(135deg, var(--purple-light), #f0abfc);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.loader-bar-wrap {
  width: 180px;
  height: 2px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 99px;
  overflow: hidden;
}
.loader-bar {
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--purple-dark), var(--pink));
  border-radius: 99px;
  transition: width 0.3s ease;
}
.loader-text { font-size: 11px; color: var(--text-muted); letter-spacing: 0.15em; }

/* ── CART DRAWER ── */
.cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 500;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}
.cart-overlay.open { opacity: 1; visibility: visible; }
.cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 420px;
  max-width: 100vw;
  background: rgba(10, 7, 24, 0.98);
  backdrop-filter: blur(24px);
  border-left: 1px solid var(--border);
  z-index: 501;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}
.cart-drawer.open { transform: translateX(0); }
.cart-header {
  padding: 24px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.cart-title {
  font-family: 'Playfair Display', serif;
  font-size: 20px;
  font-weight: 700;
  color: #fff;
}
.cart-close {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 24px;
  cursor: pointer;
  padding: 4px;
  transition: var(--transition);
  line-height: 1;
}
.cart-close:hover { color: #fff; }
.cart-items { flex: 1; overflow-y: auto; padding: 20px 24px; }
.cart-item {
  display: flex;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
}
.cart-item:last-child { border-bottom: none; }
.cart-item-img {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  background: rgba(192, 132, 252, 0.08);
  flex-shrink: 0;
}
.cart-item-info { flex: 1; }
.cart-item-name { font-size: 14px; font-weight: 600; color: #fff; margin-bottom: 4px; }
.cart-item-meta { font-size: 12px; color: var(--text-muted); margin-bottom: 8px; }
.cart-item-price { font-size: 15px; font-weight: 700; color: var(--purple-light); }
.cart-item-remove {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 18px;
  padding: 0;
  transition: var(--transition);
  align-self: flex-start;
}
.cart-item-remove:hover { color: #f87171; }
.cart-footer {
  padding: 24px;
  border-top: 1px solid var(--border);
}
.cart-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}
.cart-total-label { font-size: 14px; color: var(--text-secondary); }
.cart-total-value { font-size: 22px; font-weight: 700; color: #fff; }
.cart-empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-muted);
}
.cart-empty-icon { font-size: 48px; margin-bottom: 16px; }
.cart-empty-text { font-size: 16px; margin-bottom: 8px; }

/* ── FOOTER ── */
footer {
  background: rgba(6, 4, 16, 0.95);
  border-top: 1px solid var(--border);
  padding: 60px 5vw 32px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}
.footer-brand-name {
  font-family: 'Playfair Display', serif;
  font-size: 24px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 12px;
}
.footer-brand-name span { color: var(--purple-light); }
.footer-desc {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.7;
  max-width: 280px;
}
.footer-heading {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-secondary);
  margin-bottom: 20px;
}
.footer-links { list-style: none; display: flex; flex-direction: column; gap: 12px; }
.footer-links a {
  font-size: 14px;
  color: var(--text-muted);
  text-decoration: none;
  transition: var(--transition);
}
.footer-links a:hover { color: var(--purple-light); }
.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}
.footer-copy { font-size: 13px; color: var(--text-muted); }

/* ── TOAST NOTIFICATION ── */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9000;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.toast {
  background: rgba(18, 14, 36, 0.95);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 280px;
  max-width: 380px;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.5);
  animation: toastIn 0.3s ease;
}
.toast.success { border-color: rgba(34, 197, 94, 0.3); }
.toast.error { border-color: rgba(239, 68, 68, 0.3); }
.toast-icon { font-size: 20px; flex-shrink: 0; }
.toast-msg { font-size: 14px; color: var(--text-primary); }
@keyframes toastIn { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }

/* ── MOUSE EFFECTS (Canvas layers) ── */
#spark-canvas,
#drag-canvas {
  position: fixed;
  inset: 0;
  z-index: 9996;
  pointer-events: none;
}

#spark-canvas { z-index: 9997; }

/* ── RESPONSIVE ── */
@media (max-width: 1024px) {
  .nav-links { display: none; }
  .nav-toggle { display: flex; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
}
@media (max-width: 768px) {
  .section { padding: 60px 5vw; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .footer-bottom { flex-direction: column; text-align: center; }
  .cart-drawer { width: 100vw; }
}
@media (hover: none) {
  .btn:hover { transform: none !important; }
  .card:hover { transform: none !important; }
}
