/* Simzies storefront — shared design system (matches the landing page) */

:root {
  --purple: #6d28c9;
  --purple-dark: #5b21a8;
  --purple-light: #a78bda;
  --lavender: #ece7f6;
  --lavender-deep: #ded4f0;
  --white: #fff;
  --ink: #3d1a70;
  --ok: #16a34a;
  --err: #dc2626;
  --radius: 20px;
  --shadow: 0 8px 24px rgba(109, 40, 201, 0.13);
  --shadow-lg: 0 14px 38px rgba(109, 40, 201, 0.2);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: 'Quicksand', system-ui, -apple-system, sans-serif;
  background: var(--lavender);
  color: var(--ink);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, .display { font-family: 'Baloo 2', system-ui, cursive; font-weight: 800; line-height: 1.1; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; border: none; }

/* ---------- Header ---------- */
.site-header {
  background: var(--purple);
  color: var(--white);
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 2px 14px rgba(0, 0, 0, 0.13);
}
.header-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 18px 20px;
  display: flex;
  align-items: center;
  gap: 18px;
}
.brand {
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: 1.65rem;
  letter-spacing: -0.02em;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 8px;
}
.brand-logo { height: 76px; width: auto; display: block; }
.brand-word { font-family: 'Baloo 2', cursive; font-weight: 800; font-size: 1.65rem; }
@media (max-width: 900px) { .brand-logo { height: 62px; } }
@media (max-width: 620px) { .brand-logo { height: 52px; } }

/* ---------- Shop dropdown ---------- */
.shop-menu { position: relative; flex-shrink: 0; }
.shop-toggle {
  background: rgba(255, 255, 255, 0.16);
  color: var(--white);
  font-family: 'Baloo 2', cursive;
  font-weight: 700;
  font-size: 1rem;
  border-radius: 999px;
  padding: 10px 16px 10px 20px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: background 0.15s;
}
.shop-toggle:hover { background: rgba(255, 255, 255, 0.28); }
.shop-toggle svg { width: 16px; height: 16px; transition: transform 0.18s; }
.shop-toggle[aria-expanded='true'] svg { transform: rotate(180deg); }
.shop-toggle[aria-expanded='true'] { background: var(--white); color: var(--purple); }

.shop-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 210px;
  background: var(--white);
  border-radius: 16px;
  box-shadow: 0 12px 32px rgba(61, 26, 112, 0.28);
  padding: 8px;
  z-index: 60;
}
.shop-dropdown[hidden] { display: none; }
.shop-dropdown button,
.shop-dropdown a {
  display: block;
  width: 100%;
  text-align: left;
  background: none;
  color: var(--purple);
  font-family: 'Quicksand', sans-serif;
  font-weight: 700;
  font-size: 0.95rem;
  padding: 10px 14px;
  border-radius: 10px;
  transition: background 0.12s;
}
.shop-dropdown button:hover,
.shop-dropdown a:hover { background: var(--lavender); }
.shop-dropdown button:first-child {
  border-bottom: 1px solid var(--lavender-deep);
  border-radius: 10px 10px 0 0;
  margin-bottom: 4px;
}

.search-wrap { flex: 1; max-width: 460px; position: relative; }
.search-wrap input {
  width: 100%;
  border: none;
  border-radius: 999px;
  padding: 11px 16px 11px 42px;
  font-family: inherit;
  font-weight: 600;
  font-size: 0.97rem;
  color: var(--ink);
  outline: none;
}
.search-wrap input:focus { box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.5); }
.search-wrap svg {
  position: absolute;
  left: 14px; top: 50%;
  transform: translateY(-50%);
  width: 18px; height: 18px;
  color: var(--purple-light);
  pointer-events: none;
}

.header-actions { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.hdr-link {
  font-weight: 700;
  font-size: 0.92rem;
  padding: 9px 14px;
  border-radius: 999px;
  white-space: nowrap;
  transition: background 0.15s;
}
.hdr-link:hover { background: rgba(255, 255, 255, 0.16); }

.cart-btn {
  background: var(--white);
  color: var(--purple);
  font-weight: 800;
  font-size: 0.94rem;
  border-radius: 999px;
  padding: 10px 18px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  position: relative;
  transition: transform 0.15s;
}
.cart-btn:hover { transform: scale(1.05); }
.cart-btn svg { width: 18px; height: 18px; }
.cart-count {
  background: var(--purple);
  color: var(--white);
  border-radius: 999px;
  min-width: 22px;
  height: 22px;
  font-size: 0.78rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 6px;
}

/* ---------- Free shipping banner ---------- */
.ship-banner {
  background: var(--purple-dark);
  color: var(--white);
  text-align: center;
  padding: 8px 16px;
  font-weight: 700;
  font-size: 0.88rem;
  letter-spacing: 0.02em;
}

/* ---------- Hero ---------- */
/* Full-bleed banner directly under the header. The source photo is a wide
   2.75:1 crop, which is far too short on a phone — the subject would be a
   sliver. So the height is clamped and object-position keeps him in frame. */
.hero {
  width: 100%;
  background: var(--lavender-deep);
  line-height: 0;                 /* kills the inline-image gap below */
  overflow: hidden;
}
.hero img {
  width: 100%;
  height: clamp(220px, 34vw, 460px);
  object-fit: cover;
  object-position: 45% 42%;       /* keeps the model centred when cropped */
  display: block;
}
@media (max-width: 620px) {
  .hero img { height: 260px; object-position: 47% 38%; }
}

/* ---------- Layout ---------- */
main { flex: 1; width: 100%; max-width: 1180px; margin: 0 auto; padding: 30px 20px 64px; }

.page-title { font-size: clamp(1.8rem, 5vw, 2.5rem); text-transform: uppercase; color: var(--purple); margin-bottom: 6px; }
.page-sub { font-weight: 600; margin-bottom: 22px; opacity: 0.85; }

/* ---------- Category chips ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 9px; margin-bottom: 26px; }
.chip {
  background: var(--white);
  color: var(--purple);
  font-weight: 700;
  font-size: 0.9rem;
  border-radius: 999px;
  padding: 9px 18px;
  border: 2px solid transparent;
  transition: all 0.15s;
}
.chip:hover { border-color: var(--purple-light); }
.chip[aria-pressed='true'] { background: var(--purple); color: var(--white); }

/* ---------- Product grid ---------- */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 22px;
}
.card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  transition: transform 0.18s, box-shadow 0.18s;
}
.card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.card-img {
  aspect-ratio: 1;
  background: var(--lavender-deep);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.card-img img { width: 100%; height: 100%; object-fit: cover; }
.card-img .ph { font-family: 'Baloo 2', cursive; font-weight: 800; font-size: 2rem; color: var(--purple-light); }
.card-body { padding: 15px 16px 17px; display: flex; flex-direction: column; flex: 1; gap: 7px; }
.card-cat { font-size: 0.72rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.09em; color: var(--purple-light); }
.card-name { font-family: 'Baloo 2', cursive; font-weight: 700; font-size: 1.12rem; color: var(--purple); line-height: 1.22; }
.card-desc { font-size: 0.87rem; font-weight: 500; opacity: 0.78; line-height: 1.45; flex: 1;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 4px; }
.price { font-family: 'Baloo 2', cursive; font-weight: 800; font-size: 1.2rem; color: var(--purple); }

.btn {
  background: var(--purple);
  color: var(--white);
  font-family: 'Baloo 2', cursive;
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 0.03em;
  border-radius: 999px;
  padding: 9px 17px;
  transition: background 0.15s, transform 0.15s;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
}
.btn:hover:not(:disabled) { background: var(--purple-dark); transform: scale(1.04); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-lg { font-size: 1.05rem; padding: 14px 30px; width: 100%; }
.btn-ghost { background: transparent; color: var(--purple); border: 2px solid var(--purple); }
.btn-ghost:hover:not(:disabled) { background: var(--purple); color: var(--white); }
.btn.added { background: var(--ok); }

/* ---------- Cart drawer ---------- */
.overlay {
  position: fixed; inset: 0;
  background: rgba(61, 26, 112, 0.45);
  opacity: 0; pointer-events: none;
  transition: opacity 0.22s;
  z-index: 90;
}
.overlay.open { opacity: 1; pointer-events: auto; }

.drawer {
  position: fixed; top: 0; right: 0; bottom: 0;
  width: min(420px, 100%);
  background: var(--lavender);
  z-index: 100;
  transform: translateX(100%);
  transition: transform 0.28s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex; flex-direction: column;
  box-shadow: -8px 0 30px rgba(0, 0, 0, 0.2);
}
.drawer.open { transform: translateX(0); }
.drawer-head {
  background: var(--purple); color: var(--white);
  padding: 18px 20px;
  display: flex; align-items: center; justify-content: space-between;
}
.drawer-head h2 { font-size: 1.3rem; text-transform: uppercase; }
.close-x { background: none; color: var(--white); font-size: 1.7rem; line-height: 1; padding: 0 4px; opacity: 0.85; }
.close-x:hover { opacity: 1; }

.drawer-body { flex: 1; overflow-y: auto; padding: 16px; }
.cart-line { display: flex; gap: 12px; background: var(--white); border-radius: 15px; padding: 11px; margin-bottom: 11px; }
.cart-line-img { width: 62px; height: 62px; border-radius: 11px; background: var(--lavender-deep); flex-shrink: 0; overflow: hidden;
  display: flex; align-items: center; justify-content: center; }
.cart-line-img img { width: 100%; height: 100%; object-fit: cover; }
.cart-line-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 5px; }
.cart-line-name { font-weight: 700; font-size: 0.93rem; color: var(--purple); line-height: 1.25; }
.cart-line-price { font-weight: 700; font-size: 0.87rem; opacity: 0.75; }
.qty { display: flex; align-items: center; gap: 9px; }
.qty button {
  width: 26px; height: 26px; border-radius: 50%;
  background: var(--lavender); color: var(--purple);
  font-weight: 800; font-size: 1rem; line-height: 1;
  display: inline-flex; align-items: center; justify-content: center;
}
.qty button:hover { background: var(--purple); color: var(--white); }
.qty span { font-weight: 800; min-width: 20px; text-align: center; }
.line-remove { background: none; color: var(--err); font-size: 0.79rem; font-weight: 700; margin-left: auto; padding: 4px; }

.drawer-foot { background: var(--white); padding: 18px 20px 22px; box-shadow: 0 -4px 18px rgba(109, 40, 201, 0.1); }
.sum-row { display: flex; justify-content: space-between; font-weight: 700; font-size: 0.95rem; margin-bottom: 8px; }
.sum-row.total { font-family: 'Baloo 2', cursive; font-weight: 800; font-size: 1.28rem; color: var(--purple);
  border-top: 2px dashed var(--lavender-deep); padding-top: 11px; margin-top: 11px; margin-bottom: 14px; }
.free-note { font-size: 0.83rem; font-weight: 700; text-align: center; margin-bottom: 12px; }
.free-note.hit { color: var(--ok); }
.ship-bar { height: 7px; background: var(--lavender-deep); border-radius: 999px; overflow: hidden; margin-bottom: 12px; }
.ship-bar i { display: block; height: 100%; background: var(--purple); border-radius: 999px; transition: width 0.35s; }

/* ---------- Product detail ---------- */
.pdp { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: start; }
.pdp-media { background: var(--white); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.pdp-media .main { aspect-ratio: 1; background: var(--lavender-deep); display: flex; align-items: center; justify-content: center; }
.pdp-media .main img { width: 100%; height: 100%; object-fit: cover; }
.thumbs { display: flex; gap: 8px; padding: 10px; flex-wrap: wrap; }
.thumbs button { width: 58px; height: 58px; border-radius: 10px; overflow: hidden; border: 2px solid transparent; background: var(--lavender-deep); }
.thumbs button[aria-pressed='true'] { border-color: var(--purple); }
.thumbs img { width: 100%; height: 100%; object-fit: cover; }
.pdp-info h1 { font-size: clamp(1.7rem, 4.5vw, 2.4rem); color: var(--purple); margin-bottom: 10px; }
.pdp-price { font-family: 'Baloo 2', cursive; font-weight: 800; font-size: 1.9rem; color: var(--purple); margin-bottom: 18px; }
.pdp-desc { font-weight: 500; line-height: 1.65; white-space: pre-wrap; margin-bottom: 24px; }
.qty-picker { display: flex; align-items: center; gap: 14px; margin-bottom: 18px; font-weight: 700; }
.qty-picker .qty button { width: 34px; height: 34px; font-size: 1.15rem; background: var(--white); }

/* ---------- Forms / states ---------- */
.panel { background: var(--white); border-radius: var(--radius); padding: 26px; box-shadow: var(--shadow); }
.field { margin-bottom: 15px; }
.field label { display: block; font-weight: 700; font-size: 0.89rem; margin-bottom: 6px; }
.field input {
  width: 100%; border: 2px solid var(--lavender-deep); border-radius: 13px;
  padding: 12px 15px; font-family: inherit; font-weight: 600; font-size: 0.97rem; color: var(--ink); outline: none;
}
.field input:focus { border-color: var(--purple); }

.msg { font-weight: 700; font-size: 0.93rem; padding: 11px 15px; border-radius: 13px; margin-bottom: 15px; }
.msg.err { background: #fee2e2; color: var(--err); }
.msg.ok { background: #dcfce7; color: var(--ok); }

.empty { text-align: center; padding: 66px 20px; }
.empty h3 { font-size: 1.45rem; color: var(--purple); margin-bottom: 9px; }
.empty p { font-weight: 600; opacity: 0.8; margin-bottom: 20px; }

.skeleton { background: var(--white); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.skeleton .sk { background: linear-gradient(90deg, var(--lavender-deep) 25%, #e8e0f7 50%, var(--lavender-deep) 75%);
  background-size: 200% 100%; animation: shimmer 1.4s infinite; }
.skeleton .sk-img { aspect-ratio: 1; }
.skeleton .sk-line { height: 13px; margin: 11px 16px; border-radius: 6px; }
@keyframes shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }

/* ---------- Status pill ---------- */
.status-pill { display: inline-flex; align-items: center; gap: 8px; background: var(--purple); color: var(--white);
  font-family: 'Baloo 2', cursive; font-weight: 700; border-radius: 999px; padding: 8px 20px; font-size: 1rem; margin-bottom: 6px; }
.steps { display: flex; gap: 6px; margin: 22px 0; }
.step { flex: 1; text-align: center; }
.step .dot { width: 100%; height: 7px; border-radius: 999px; background: var(--lavender-deep); margin-bottom: 8px; }
.step.on .dot { background: var(--purple); }
.step span { font-size: 0.78rem; font-weight: 700; opacity: 0.7; }
.step.on span { opacity: 1; color: var(--purple); }

/* ---------- Footer ---------- */
.site-footer { background: var(--purple); color: var(--white); text-align: center; padding: 26px 20px; margin-top: auto; }
.site-footer .fbrand { font-family: 'Baloo 2', cursive; font-weight: 800; font-size: 1.2rem; letter-spacing: 0.05em; margin-bottom: 8px; }
.footer-logo { height: 46px; width: auto; margin: 0 auto 10px; display: block; opacity: .95; }
.site-footer a { font-weight: 700; font-size: 0.88rem; opacity: 0.85; margin: 0 9px; }
.site-footer a:hover { opacity: 1; }
.test-badge { background: #fbbf24; color: #78350f; font-weight: 800; font-size: 0.8rem; text-align: center; padding: 6px; }

@media (max-width: 860px) { .pdp { grid-template-columns: 1fr; gap: 26px; } }
@media (max-width: 620px) {
  .header-inner { flex-wrap: wrap; gap: 11px; }
  .shop-toggle { font-size: .92rem; padding: 9px 13px 9px 16px; }
  .search-wrap { order: 3; flex-basis: 100%; max-width: none; }
  .brand { font-size: 1.35rem; }
  .hdr-link { display: none; }
  .grid { grid-template-columns: repeat(auto-fill, minmax(158px, 1fr)); gap: 14px; }
}

/* ---------- stock states ---------- */
.sold-out-badge {
  position: absolute; top: 10px; left: 10px;
  background: var(--ink); color: var(--white);
  font-family: 'Baloo 2', cursive; font-weight: 700; font-size: .72rem;
  text-transform: uppercase; letter-spacing: .07em;
  padding: 5px 11px; border-radius: 999px; z-index: 2;
}
.low-stock { color: #b45309; font-weight: 800; font-size: .8rem; }
.preorder-badge {
  position: absolute; top: 10px; left: 10px;
  background: var(--purple); color: var(--white);
  font-family: 'Baloo 2', cursive; font-weight: 700; font-size: .72rem;
  text-transform: uppercase; letter-spacing: .07em;
  padding: 5px 11px; border-radius: 999px; z-index: 2;
}
.preorder-note { color: var(--purple); font-weight: 700; font-size: .8rem; }
.card { position: relative; }
.card.is-sold-out .card-img { opacity: .5; filter: grayscale(.6); }
.btn.sold-out { background: var(--lavender-deep); color: var(--ink); opacity: .8; cursor: not-allowed; }
.btn.sold-out:hover { transform: none; background: var(--lavender-deep); }
