/* ============================================================
   SPRIHA CLOSET — Shared Design System
   Luxury Pakistani fashion, delivered across Bangladesh
   ============================================================ */

:root {
  /* Palette */
  --ivory: #faf6ef;
  --ivory-deep: #f3ecdf;
  --champagne: #efe3d0;
  --burgundy: #6b1f2e;
  --burgundy-deep: #521624;
  --burgundy-soft: #8a3345;
  --gold: #b9893c;
  --gold-light: #d9b878;
  --charcoal: #2b2320;
  --ink: #4a3f39;
  --muted: #8c7d72;
  --line: #e4d8c6;
  --white: #ffffff;
  --success: #2e6b45;
  --error: #a63232;

  /* Type */
  --font-serif: "Cormorant Garamond", "Georgia", serif;
  --font-sans: "Jost", "Segoe UI", sans-serif;

  /* Spacing rhythm */
  --sp-1: 0.5rem;
  --sp-2: 1rem;
  --sp-3: 1.5rem;
  --sp-4: 2.5rem;
  --sp-5: 4rem;
  --sp-6: 6rem;

  /* Shape & shadow */
  --radius: 4px;
  --radius-lg: 10px;
  --shadow-soft: 0 10px 40px rgba(43, 35, 32, 0.08);
  --shadow-lift: 0 18px 60px rgba(43, 35, 32, 0.14);

  --header-h: 76px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--ivory);
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
input, select, textarea { font-family: inherit; font-size: 1rem; }

/* ---------- Typography ---------- */
h1, h2, h3, h4 {
  font-family: var(--font-serif);
  font-weight: 500;
  color: var(--charcoal);
  line-height: 1.15;
}
h1 { font-size: clamp(2.4rem, 5.5vw, 4.2rem); letter-spacing: 0.01em; }
h2 { font-size: clamp(1.9rem, 3.6vw, 2.9rem); }
h3 { font-size: clamp(1.25rem, 2vw, 1.6rem); }
h4 { font-size: 1.15rem; }

.eyebrow {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--gold);
  display: inline-flex;
  align-items: center;
  gap: 0.9rem;
}
.eyebrow::before, .eyebrow.centered::after {
  content: "";
  width: 34px;
  height: 1px;
  background: var(--gold);
  opacity: 0.6;
}
.eyebrow.no-rule::before, .eyebrow.no-rule::after { display: none; }

.lead { font-size: 1.08rem; color: var(--muted); max-width: 56ch; }

/* ---------- Layout ---------- */
.container { width: min(1200px, 92%); margin-inline: auto; }
.container-wide { width: min(1400px, 94%); margin-inline: auto; }
.section { padding-block: var(--sp-6); }
.section.tight { padding-block: var(--sp-4); }
.section-head { max-width: 640px; margin-bottom: var(--sp-4); }
.section-head.centered { margin-inline: auto; text-align: center; }
.section-head h2 { margin: 0.6rem 0 0.8rem; }
.grid { display: grid; gap: var(--sp-3); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.95rem 2.1rem;
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  border-radius: var(--radius);
  transition: all 0.3s ease;
  border: 1px solid transparent;
  white-space: nowrap;
}
.btn-primary { background: var(--burgundy); color: var(--ivory); }
.btn-primary:hover { background: var(--burgundy-deep); transform: translateY(-2px); box-shadow: var(--shadow-lift); }
.btn-outline { border-color: var(--burgundy); color: var(--burgundy); background: transparent; }
.btn-outline:hover { background: var(--burgundy); color: var(--ivory); }
.btn-light { background: var(--ivory); color: var(--burgundy); }
.btn-light:hover { background: var(--champagne); }
.btn-gold { background: linear-gradient(120deg, var(--gold), var(--gold-light)); color: var(--charcoal); }
.btn-gold:hover { filter: brightness(1.05); transform: translateY(-2px); }
.btn-block { width: 100%; }
.btn:disabled { opacity: 0.55; cursor: not-allowed; transform: none !important; }
.btn .btn-arrow { transition: transform 0.3s ease; }
.btn:hover .btn-arrow { transform: translateX(4px); }

/* ---------- Header ---------- */
.announce {
  background: var(--burgundy);
  color: var(--champagne);
  text-align: center;
  font-size: 0.74rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 0.55rem 1rem;
}
.announce strong { color: var(--gold-light); font-weight: 600; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(250, 246, 239, 0.92);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  height: var(--header-h);
}
.brand { display: flex; align-items: center; gap: 0.75rem; }
.brand-mark {
  width: 44px; height: 44px;
  border: 1.5px solid var(--gold);
  border-radius: 50%;
  display: grid; place-items: center;
  font-family: var(--font-serif);
  font-size: 1.35rem;
  color: var(--burgundy);
  background: var(--white);
  flex-shrink: 0;
}
.brand-name {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  color: var(--charcoal);
  line-height: 1;
}
.brand-name span { color: var(--burgundy); }
.brand-tag {
  display: block;
  font-family: var(--font-sans);
  font-size: 0.58rem;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--gold);
  margin-top: 2px;
}

.main-nav { display: flex; gap: 2rem; }
.main-nav a {
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink);
  padding: 0.4rem 0;
  position: relative;
}
.main-nav a::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 0; height: 1.5px;
  background: var(--gold);
  transition: width 0.3s ease;
}
.main-nav a:hover::after, .main-nav a.active::after { width: 100%; }
.main-nav a.active { color: var(--burgundy); }

.header-actions { display: flex; align-items: center; gap: 1.2rem; }
.icon-btn {
  position: relative;
  color: var(--charcoal);
  display: grid;
  place-items: center;
  width: 40px; height: 40px;
  border-radius: 50%;
  transition: background 0.25s ease;
}
.icon-btn:hover { background: var(--ivory-deep); }
.icon-btn svg { width: 21px; height: 21px; }
.cart-count {
  position: absolute;
  top: 2px; right: 0;
  min-width: 17px; height: 17px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--burgundy);
  color: var(--ivory);
  font-size: 0.62rem;
  font-weight: 600;
  display: grid;
  place-items: center;
}
.cart-count.is-empty { display: none; }
.nav-toggle { display: none; }

/* Mobile nav */
.mobile-nav {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: var(--ivory);
  padding: 1.5rem 6%;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.4s cubic-bezier(0.7, 0, 0.2, 1);
  visibility: hidden;
}
.mobile-nav.open { transform: translateX(0); visibility: visible; }
.mobile-nav .mobile-nav-head { display: flex; justify-content: space-between; align-items: center; }
.mobile-nav nav { margin-top: 3rem; display: flex; flex-direction: column; gap: 1.4rem; }
.mobile-nav nav a {
  font-family: var(--font-serif);
  font-size: 2rem;
  color: var(--charcoal);
  border-bottom: 1px solid var(--line);
  padding-bottom: 1rem;
}
.mobile-nav nav a:hover { color: var(--burgundy); }

/* ---------- Cart drawer ---------- */
.drawer-overlay {
  position: fixed; inset: 0;
  background: rgba(43, 35, 32, 0.45);
  backdrop-filter: blur(2px);
  opacity: 0; visibility: hidden;
  transition: opacity 0.35s ease, visibility 0.35s;
  z-index: 95;
}
.drawer-overlay.open { opacity: 1; visibility: visible; }
.cart-drawer {
  position: fixed;
  top: 0; right: 0;
  width: min(420px, 92vw);
  height: 100dvh;
  background: var(--ivory);
  z-index: 100;
  display: flex;
  flex-direction: column;
  transform: translateX(105%);
  transition: transform 0.45s cubic-bezier(0.7, 0, 0.2, 1);
  box-shadow: var(--shadow-lift);
}
.cart-drawer.open { transform: translateX(0); }
.drawer-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.4rem 1.6rem;
  border-bottom: 1px solid var(--line);
}
.drawer-head h3 { font-size: 1.4rem; }
.drawer-items { flex: 1; overflow-y: auto; padding: 1.2rem 1.6rem; display: flex; flex-direction: column; gap: 1.2rem; }
.drawer-empty { text-align: center; padding: 3rem 1rem; color: var(--muted); }
.drawer-empty .empty-icon { font-size: 2.4rem; margin-bottom: 0.8rem; opacity: 0.5; }
.drawer-item { display: grid; grid-template-columns: 72px 1fr auto; gap: 1rem; align-items: start; }
.drawer-item img { width: 72px; height: 92px; object-fit: cover; border-radius: var(--radius); background: var(--champagne); }
.drawer-item .di-name { font-family: var(--font-serif); font-size: 1.05rem; color: var(--charcoal); line-height: 1.3; }
.drawer-item .di-meta { font-size: 0.78rem; color: var(--muted); margin: 0.2rem 0 0.5rem; }
.drawer-item .di-price { font-weight: 500; color: var(--burgundy); }
.qty-stepper { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); }
.qty-stepper button { width: 28px; height: 28px; font-size: 1rem; color: var(--ink); }
.qty-stepper button:hover { color: var(--burgundy); }
.qty-stepper span { min-width: 30px; text-align: center; font-size: 0.85rem; }
.di-remove { font-size: 0.72rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); margin-top: 0.5rem; text-decoration: underline; text-underline-offset: 3px; }
.di-remove:hover { color: var(--error); }
.drawer-foot { border-top: 1px solid var(--line); padding: 1.4rem 1.6rem; background: var(--white); }
.drawer-subtotal { display: flex; justify-content: space-between; font-size: 1rem; margin-bottom: 0.4rem; }
.drawer-subtotal strong { font-family: var(--font-serif); font-size: 1.35rem; color: var(--burgundy); }
.drawer-note { font-size: 0.76rem; color: var(--muted); margin-bottom: 1rem; }
.drawer-foot .btn { margin-bottom: 0.6rem; }
.drawer-foot .btn:last-child { margin-bottom: 0; }

/* ---------- Toast ---------- */
.toast-stack { position: fixed; bottom: 1.5rem; left: 50%; transform: translateX(-50%); z-index: 120; display: flex; flex-direction: column; gap: 0.6rem; align-items: center; pointer-events: none; }
.toast {
  background: var(--charcoal);
  color: var(--ivory);
  padding: 0.85rem 1.6rem;
  border-radius: var(--radius);
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  box-shadow: var(--shadow-lift);
  display: flex; align-items: center; gap: 0.7rem;
  animation: toastIn 0.35s ease;
}
.toast .toast-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--gold-light); }
.toast.toast-success .toast-dot { background: #7fd6a2; }
.toast.toast-error .toast-dot { background: #f0a0a0; }
@keyframes toastIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
.toast.hide { opacity: 0; transition: opacity 0.3s ease; }

/* ---------- Product cards ---------- */
.product-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.8rem 1.4rem; }
.product-card { position: relative; background: var(--white); border-radius: var(--radius-lg); overflow: hidden; transition: transform 0.35s ease, box-shadow 0.35s ease; }
.product-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lift); }
.product-card .pc-media { position: relative; aspect-ratio: 3 / 4; overflow: hidden; background: var(--champagne); }
.product-card .pc-media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.7s cubic-bezier(0.2, 0.6, 0.2, 1); }
.product-card:hover .pc-media img { transform: scale(1.06); }
.pc-badge {
  position: absolute; top: 0.9rem; left: 0.9rem;
  background: var(--burgundy); color: var(--ivory);
  font-size: 0.62rem; font-weight: 600;
  letter-spacing: 0.18em; text-transform: uppercase;
  padding: 0.35rem 0.7rem; border-radius: 2px;
}
.pc-badge.badge-gold { background: linear-gradient(120deg, var(--gold), var(--gold-light)); color: var(--charcoal); }
.pc-quick {
  position: absolute; left: 0.9rem; right: 0.9rem; bottom: 0.9rem;
  background: rgba(250, 246, 239, 0.95);
  backdrop-filter: blur(6px);
  color: var(--burgundy);
  font-size: 0.72rem; font-weight: 600;
  letter-spacing: 0.2em; text-transform: uppercase;
  text-align: center;
  padding: 0.75rem;
  border-radius: var(--radius);
  opacity: 0; transform: translateY(8px);
  transition: all 0.3s ease;
}
.product-card:hover .pc-quick { opacity: 1; transform: translateY(0); }
.pc-quick:hover { background: var(--burgundy); color: var(--ivory); }
.pc-body { padding: 1.1rem 1.2rem 1.3rem; }
.pc-cat { font-size: 0.66rem; letter-spacing: 0.24em; text-transform: uppercase; color: var(--gold); }
.pc-name { font-family: var(--font-serif); font-size: 1.2rem; color: var(--charcoal); margin: 0.25rem 0 0.45rem; line-height: 1.3; }
.pc-name a:hover { color: var(--burgundy); }
.pc-price { display: flex; align-items: baseline; gap: 0.6rem; }
.pc-price .price { font-weight: 600; color: var(--burgundy); font-size: 1.02rem; }
.pc-price .price-old { font-size: 0.85rem; color: var(--muted); text-decoration: line-through; }

/* ---------- Footer ---------- */
.site-footer { background: var(--charcoal); color: #cfc4b8; margin-top: var(--sp-6); }
.footer-top { padding: var(--sp-5) 0 var(--sp-4); display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.3fr; gap: 2.5rem; }
.footer-brand .brand-name { color: var(--ivory); font-size: 1.7rem; }
.footer-brand p { font-size: 0.9rem; margin-top: 0.9rem; max-width: 34ch; color: #a89a8c; }
.footer-col h4 { color: var(--ivory); font-family: var(--font-sans); font-size: 0.78rem; font-weight: 600; letter-spacing: 0.24em; text-transform: uppercase; margin-bottom: 1.1rem; }
.footer-col ul { display: flex; flex-direction: column; gap: 0.6rem; }
.footer-col a { font-size: 0.9rem; transition: color 0.25s ease; }
.footer-col a:hover { color: var(--gold-light); }
.footer-contact li { font-size: 0.9rem; display: flex; gap: 0.6rem; align-items: flex-start; }
.footer-bottom { border-top: 1px solid rgba(250, 246, 239, 0.12); padding: 1.4rem 0; display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; font-size: 0.78rem; color: #a89a8c; }
.footer-badges { display: flex; gap: 0.6rem; flex-wrap: wrap; }
.footer-badges span { border: 1px solid rgba(250, 246, 239, 0.2); border-radius: 3px; padding: 0.3rem 0.7rem; font-size: 0.68rem; letter-spacing: 0.12em; text-transform: uppercase; }

/* ---------- Forms ---------- */
.form-field { display: flex; flex-direction: column; gap: 0.4rem; margin-bottom: 1.1rem; }
.form-field label { font-size: 0.74rem; font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink); }
.form-field label .req { color: var(--burgundy); }
.form-field input, .form-field select, .form-field textarea {
  padding: 0.85rem 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--charcoal);
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
  width: 100%;
}
.form-field input:focus, .form-field select:focus, .form-field textarea:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(185, 137, 60, 0.15);
}
.form-field .field-error { font-size: 0.76rem; color: var(--error); display: none; }
.form-field.invalid input, .form-field.invalid select, .form-field.invalid textarea { border-color: var(--error); }
.form-field.invalid .field-error { display: block; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }

/* ---------- Reveal animations ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.in { opacity: 1; transform: translateY(0); }
.reveal-delay-1 { transition-delay: 0.12s; }
.reveal-delay-2 { transition-delay: 0.24s; }
.reveal-delay-3 { transition-delay: 0.36s; }

/* ---------- Page hero (interior pages) ---------- */
.page-hero {
  background: linear-gradient(160deg, var(--ivory-deep), var(--champagne));
  padding: var(--sp-5) 0 var(--sp-4);
  text-align: center;
  border-bottom: 1px solid var(--line);
}
.page-hero h1 { margin: 0.6rem 0 0.8rem; }
.page-hero .lead { margin-inline: auto; }
.breadcrumb { font-size: 0.74rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); margin-bottom: 0.6rem; }
.breadcrumb a:hover { color: var(--burgundy); }
.breadcrumb .sep { margin: 0 0.5rem; color: var(--gold); }

/* ---------- Utility ---------- */
.text-center { text-align: center; }
.mt-2 { margin-top: var(--sp-2); } .mt-3 { margin-top: var(--sp-3); } .mt-4 { margin-top: var(--sp-4); }
.hidden { display: none !important; }
.gold-rule { width: 64px; height: 1px; background: var(--gold); margin: 1.2rem auto; opacity: 0.7; }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .product-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-top { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 820px) {
  .main-nav { display: none; }
  .nav-toggle { display: grid; }
  .product-grid { grid-template-columns: repeat(2, 1fr); gap: 1.2rem 0.9rem; }
  .section { padding-block: var(--sp-5); }
  .form-row { grid-template-columns: 1fr; }
  .header-actions { gap: 0.5rem; }
  .brand-tag { display: none; }
  .brand-name { font-size: 1.3rem; }
}
@media (max-width: 480px) {
  .product-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-top { grid-template-columns: 1fr; gap: 1.8rem; }
  .btn { padding: 0.9rem 1.5rem; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
  html { scroll-behavior: auto; }
}
