/* =========================================================
   Mimi Global Ice Cream — style.css
   Palette: cream, strawberry pink, chocolate brown, soft yellow,
   light purple, white. Modern, fun, premium ice-cream aesthetic.
   ========================================================= */

:root {
  --cream: #fff8f0;
  --white: #ffffff;
  --surface: #ffffff;
  --heading: var(--brown);
  --pink: #ff6f9c;
  --pink-dark: #ef4c7f;
  --pink-light: #ffe1ec;
  --brown: #6b3e26;
  --brown-light: #8a5a3b;
  --yellow: #ffd166;
  --yellow-light: #fff1d1;
  --purple: #b497d6;
  --purple-light: #efe5fb;
  --text-main: #4a2f24;
  --text-muted: #8a7468;
  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 12px;
  --shadow-soft: 0 10px 30px rgba(107, 62, 38, 0.12);
  --shadow-hover: 0 18px 40px rgba(107, 62, 38, 0.18);
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-out-soft: cubic-bezier(0.16, 1, 0.3, 1);
  --transition: 0.3s var(--ease);
  --transition-slow: 0.45s var(--ease-out-soft);
}

/* Dark theme — toggled via data-theme="dark" on <html>, set and remembered by script.js */
:root[data-theme="dark"] {
  --cream: #17110d;
  --surface: #241a14;
  --heading: #fff3e6;
  --pink: #ff85ac;
  --pink-dark: #ff5c8d;
  --pink-light: #3a2430;
  --brown-light: #c99b7a;
  --yellow-light: #3a2f18;
  --purple: #cbb2e3;
  --purple-light: #2e2438;
  --text-main: #f3e6da;
  --text-muted: #c2a996;
  --shadow-soft: 0 10px 30px rgba(0, 0, 0, 0.45);
  --shadow-hover: 0 18px 40px rgba(0, 0, 0, 0.55);
}

body,
.site-header,
.product-card,
.category-card,
.why-card,
.cart-drawer,
.lightbox,
.search-bar-inner,
.pill,
.fulfillment-option,
.occasions-list li,
.contact-item {
  transition: background-color 0.4s var(--ease), color 0.4s var(--ease), border-color 0.4s var(--ease);
}

@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;
  }
}

/* ---------- Reset ---------- */
* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 90px;
}

body {
  font-family: 'Poppins', system-ui, sans-serif;
  color: var(--text-main);
  background: var(--cream);
  line-height: 1.6;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }

/* Shimmer placeholder shown while an image loads */
.img-shimmer {
  background: linear-gradient(100deg, var(--pink-light) 30%, var(--yellow-light) 50%, var(--pink-light) 70%);
  background-size: 200% 100%;
  animation: shimmer 1.4s ease-in-out infinite;
}
.img-shimmer.loaded { animation: none; background: none; }
@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

a { text-decoration: none; color: inherit; }

ul { list-style: none; }

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

h1, h2, h3 { font-weight: 700; line-height: 1.2; color: var(--heading); }

/* Custom scrollbar */
html { scrollbar-color: var(--pink) var(--cream); scrollbar-width: thin; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--cream); }
::-webkit-scrollbar-thumb { background: var(--pink); border-radius: 50px; border: 2px solid var(--cream); }
::-webkit-scrollbar-thumb:hover { background: var(--pink-dark); }

/* Scroll progress bar */
.scroll-progress {
  position: fixed;
  top: 0; left: 0;
  height: 3px;
  width: 0%;
  background: linear-gradient(90deg, var(--pink), var(--purple), var(--yellow));
  z-index: 2200;
  transition: width 0.1s linear;
}

section { padding: 90px 6vw; }

/* Visible focus states for accessibility */
a:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: 3px solid var(--purple);
  outline-offset: 3px;
  border-radius: 6px;
}

/* ---------- Buttons ---------- */
.btn {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 30px;
  border-radius: 50px;
  font-weight: 600;
  font-size: 1rem;
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition);
  white-space: nowrap;
}

/* Ripple feedback on click, added by script.js */
.btn .ripple {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.55);
  transform: scale(0);
  animation: rippleEffect 0.6s ease-out;
  pointer-events: none;
}
@keyframes rippleEffect {
  to { transform: scale(2.5); opacity: 0; }
}
.btn-outline .ripple { background: rgba(107, 62, 38, 0.18); }
:root[data-theme="dark"] .btn-outline .ripple { background: rgba(255, 243, 230, 0.18); }

.btn-primary {
  background: var(--pink);
  color: var(--white);
  box-shadow: var(--shadow-soft);
}
.btn-primary:hover { background: var(--pink-dark); transform: translateY(-3px); box-shadow: var(--shadow-hover); }
.btn-primary svg { transition: transform var(--transition); }
.btn-primary:hover svg { transform: translateX(4px); }

.btn-outline {
  background: transparent;
  color: var(--heading);
  border: 2px solid var(--heading);
}
.btn-outline:hover { background: var(--brown); color: var(--white); transform: translateY(-3px); }

.btn-whatsapp {
  background: #25d366;
  color: var(--white);
  box-shadow: 0 10px 24px rgba(37, 211, 102, 0.35);
}
.btn-whatsapp:hover { background: #1ebd5a; transform: translateY(-3px); }

.btn-lg { padding: 16px 36px; font-size: 1.05rem; margin-top: 8px; }

/* ---------- Section heading ---------- */
.section-heading { text-align: center; max-width: 640px; margin: 0 auto 50px; }
.section-kicker {
  color: var(--pink-dark);
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  font-size: 0.85rem;
  margin-bottom: 8px;
}
.section-heading h2 { font-size: clamp(1.8rem, 3vw, 2.4rem); margin-bottom: 12px; }
.section-sub { color: var(--text-muted); font-size: 1rem; }

/* =========================================================
   HEADER / NAVBAR
   ========================================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(255, 248, 240, 0.9);
  backdrop-filter: blur(10px);
  transition: box-shadow var(--transition), background var(--transition);
}
.site-header.scrolled {
  background: rgba(255, 248, 240, 0.98);
  box-shadow: 0 4px 20px rgba(107, 62, 38, 0.1);
}
:root[data-theme="dark"] .site-header { background: rgba(23, 17, 13, 0.85); }
:root[data-theme="dark"] .site-header.scrolled {
  background: rgba(23, 17, 13, 0.97);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 6vw;
  max-width: 1400px;
  margin: 0 auto;
}

.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: 'Pacifico', cursive;
  font-size: 1.5rem;
  color: var(--heading);
}
.logo-icon {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}
.logo-accent { color: var(--pink); }

.nav-links {
  display: flex;
  gap: 34px;
  align-items: center;
}
.nav-link {
  position: relative;
  font-weight: 500;
  color: var(--heading);
  padding: 6px 2px;
  transition: color var(--transition);
}
.nav-link::after {
  content: "";
  position: absolute;
  left: 0; bottom: -4px;
  width: 0; height: 2px;
  background: var(--pink);
  transition: width var(--transition);
}
.nav-link:hover,
.nav-link.active { color: var(--pink-dark); }
.nav-link:hover::after,
.nav-link.active::after { width: 100%; }

.nav-actions { display: flex; align-items: center; gap: 12px; position: relative; z-index: 1200; }

.icon-btn {
  width: 42px; height: 42px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  color: var(--heading);
  background: var(--pink-light);
  transition: background var(--transition), transform var(--transition);
}
.icon-btn:hover { background: var(--pink); color: var(--white); transform: scale(1.08); }

#themeToggle svg { transition: transform 0.4s var(--ease-out-soft), opacity 0.3s var(--ease); }
#themeToggle:hover svg { transform: rotate(20deg); }

.cart-toggle { position: relative; }
.cart-badge {
  position: absolute;
  top: -4px; right: -4px;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  border-radius: 50px;
  background: var(--pink);
  color: var(--white);
  font-size: 0.7rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--cream);
}

.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 42px; height: 42px;
  border-radius: 50%;
  background: var(--pink-light);
}
.hamburger span {
  width: 20px; height: 2px;
  background: var(--heading);
  margin: 0 auto;
  transition: transform var(--transition), opacity var(--transition);
  border-radius: 2px;
}
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Search bar (nav dropdown) */
/* Reusable smooth expand/collapse (grid-rows animation trick) */
.collapsible {
  display: grid;
  grid-template-rows: 0fr;
  opacity: 0;
  transition: grid-template-rows var(--transition-slow), opacity var(--transition);
}
.collapsible.is-open {
  grid-template-rows: 1fr;
  opacity: 1;
}
.collapsible-inner {
  overflow: hidden;
  min-height: 0;
}

.search-bar-wrap {
  max-width: 1400px;
  margin: 0 auto;
}
.search-bar-wrap .collapsible-inner {
  padding: 0 6vw 16px;
}
.search-bar-inner {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--surface);
  border: 2px solid var(--pink-light);
  border-radius: 50px;
  padding: 10px 18px;
  color: var(--text-muted);
  transition: border-color var(--transition);
}
.search-bar-inner:focus-within { border-color: var(--pink); }
.search-bar-inner input {
  border: none;
  outline: none;
  flex: 1;
  font-family: inherit;
  font-size: 1rem;
  background: transparent;
  color: var(--text-main);
}

/* =========================================================
   HERO
   ========================================================= */
.hero {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
  gap: 40px;
  padding-top: 60px;
  padding-bottom: 60px;
  position: relative;
  overflow: hidden;
}

.hero-kicker {
  display: inline-block;
  background: var(--yellow-light);
  color: var(--heading);
  padding: 6px 16px;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 18px;
}

.hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  margin-bottom: 20px;
}
.hero h1 span { color: var(--pink); }

.hero-desc {
  color: var(--text-muted);
  font-size: 1.1rem;
  max-width: 520px;
  margin-bottom: 32px;
}

.hero-cta-row { display: flex; gap: 18px; flex-wrap: wrap; }

.trust-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  margin-top: 28px;
  padding-top: 22px;
  border-top: 1px solid var(--pink-light);
}
.trust-strip li {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
}

.hero-image {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  perspective: 1000px;
}
.hero-image img {
  border-radius: 50%;
  width: 100%;
  max-width: 460px;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  box-shadow: var(--shadow-hover);
  border: 8px solid var(--surface);
  position: relative;
  z-index: 2;
  transition: transform 0.2s var(--ease-out-soft);
  will-change: transform;
}
.hero-blob {
  position: absolute;
  border-radius: 50%;
  z-index: 1;
}
.hero-blob-1 {
  width: 340px; height: 340px;
  background: var(--pink-light);
  top: -30px; right: 10%;
  animation: float 6s ease-in-out infinite;
}
.hero-blob-2 {
  width: 220px; height: 220px;
  background: var(--yellow-light);
  bottom: -20px; left: 5%;
  animation: float 7s ease-in-out infinite reverse;
}
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-18px); }
}

/* =========================================================
   CATEGORIES
   ========================================================= */
.categories { background: var(--surface); }

.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 22px;
  max-width: 1200px;
  margin: 0 auto;
}

.category-card {
  background: var(--cream);
  border-radius: var(--radius-md);
  padding: 30px 16px;
  text-align: center;
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition);
  border: 2px solid transparent;
}
.category-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-soft);
}
.category-card.active {
  background: var(--pink-light);
  border-color: var(--pink);
}
.category-emoji { font-size: 2.2rem; margin-bottom: 12px; display: block; }
.category-card h3 { font-size: 1rem; color: var(--heading); }

/* =========================================================
   PRODUCTS
   ========================================================= */
.products-toolbar {
  max-width: 1200px;
  margin: 0 auto 40px;
  display: flex;
  flex-direction: column;
  gap: 22px;
  align-items: center;
}
.products-search { width: 100%; max-width: 480px; }

.filter-pills {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}
.pill {
  padding: 10px 20px;
  border-radius: 50px;
  background: var(--surface);
  color: var(--heading);
  font-weight: 500;
  font-size: 0.9rem;
  border: 2px solid var(--pink-light);
  transition: background var(--transition), color var(--transition), border-color var(--transition);
}
.pill:hover { border-color: var(--pink); }
.pill.active {
  background: var(--pink);
  color: var(--white);
  border-color: var(--pink);
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 28px;
  max-width: 1300px;
  margin: 0 auto;
}

.product-card {
  background: var(--surface);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  transition: transform var(--transition), box-shadow var(--transition);
  display: flex;
  flex-direction: column;
}
.product-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-hover);
}

.product-image-wrap {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--pink-light);
  cursor: zoom-in;
  padding: 0;
  margin: 0;
  appearance: none;
  -webkit-appearance: none;
}
.product-image-wrap img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.product-card:hover .product-image-wrap img { transform: scale(1.08); }

.zoom-hint {
  position: absolute;
  bottom: 10px; right: 10px;
  width: 32px; height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  color: var(--heading);
  display: flex; align-items: center; justify-content: center;
  opacity: 0;
  transform: scale(0.85);
  transition: opacity var(--transition), transform var(--transition);
}
.product-card:hover .zoom-hint { opacity: 1; transform: scale(1); }
/* Touchscreens never trigger :hover, so show the hint faintly all the time instead */
@media (hover: none) {
  .zoom-hint { opacity: 0.85; transform: scale(1); }
}

.product-category-tag {
  position: absolute;
  top: 12px; left: 12px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--pink-dark);
  font-size: 0.72rem;
  font-weight: 600;
  padding: 5px 12px;
  border-radius: 50px;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.product-badge {
  position: absolute;
  top: 12px; right: 12px;
  background: linear-gradient(135deg, var(--pink), var(--purple));
  color: var(--white);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 50px;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  box-shadow: var(--shadow-soft);
}

.product-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}
.product-body h3 { font-size: 1.15rem; }
.product-desc { color: var(--text-muted); font-size: 0.9rem; flex: 1; }

.product-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 10px;
  gap: 10px;
}
.product-price { font-size: 1.2rem; font-weight: 700; color: var(--heading); }

.btn-order {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #25d366;
  color: var(--white);
  padding: 10px 16px;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  transition: background var(--transition), transform var(--transition);
}
.btn-order:hover { background: #1ebd5a; transform: translateY(-2px); }

.no-results {
  text-align: center;
  font-size: 1.1rem;
  color: var(--text-muted);
  margin-top: 40px;
  animation: cardEnter 0.4s var(--ease-out-soft) both;
}

/* =========================================================
   ABOUT
   ========================================================= */
.about {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 50px;
  align-items: center;
  background: var(--purple-light);
  border-radius: var(--radius-lg);
  margin: 0 6vw;
  padding: 60px 6vw;
  width: auto;
}
.about-image img {
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
}
.about-content p { margin-bottom: 16px; color: var(--text-muted); }
.about-content h2 { margin-bottom: 18px; }

/* =========================================================
   WHY CHOOSE US
   ========================================================= */
.why-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 26px;
  max-width: 1200px;
  margin: 0 auto;
}
.why-card {
  background: var(--surface);
  border-radius: var(--radius-md);
  padding: 34px 24px;
  text-align: center;
  box-shadow: var(--shadow-soft);
  transition: transform var(--transition), box-shadow var(--transition);
}
.why-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-hover); }
.why-icon {
  width: 64px; height: 64px;
  border-radius: 50%;
  background: var(--yellow-light);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.8rem;
  margin: 0 auto 16px;
}
.why-card h3 { margin-bottom: 10px; font-size: 1.1rem; }
.why-card p { color: var(--text-muted); font-size: 0.92rem; }

/* =========================================================
   OCCASIONS
   ========================================================= */
.occasions { padding-top: 0; }

.occasions-card {
  background: linear-gradient(135deg, var(--pink-light), var(--yellow-light));
  border-radius: var(--radius-lg);
  padding: 60px 6vw;
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
}

.occasions-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
  margin: 30px 0 34px;
}
.occasions-list li {
  background: var(--surface);
  padding: 12px 22px;
  border-radius: 50px;
  font-weight: 600;
  color: var(--heading);
  box-shadow: var(--shadow-soft);
}

/* =========================================================
   CONTACT
   ========================================================= */
.contact-card {
  background: var(--brown);
  border-radius: var(--radius-lg);
  padding: 60px 6vw;
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
  color: var(--white);
}
.contact .section-kicker { color: var(--yellow); }
.contact .section-heading h2 { color: var(--white); }
.contact .section-sub { color: #f0ddd0; }

.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 26px;
  margin: 40px 0;
}
.contact-item {
  background: rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-md);
  padding: 26px 16px;
  transition: background var(--transition), transform var(--transition);
}
.contact-item:hover { background: rgba(255, 255, 255, 0.15); transform: translateY(-4px); }
.contact-icon { font-size: 1.8rem; display: block; margin-bottom: 10px; }
.contact-item h3 { color: var(--white); font-size: 1rem; margin-bottom: 6px; }
.contact-item p, .contact-item a { color: #f0ddd0; font-size: 0.92rem; }
.contact-item a:hover { color: var(--yellow); }

/* =========================================================
   FOOTER
   ========================================================= */
.site-footer {
  background: #3d2417;
  color: #e8d8ce;
  padding: 70px 6vw 0;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 40px;
  max-width: 1300px;
  margin: 0 auto;
  padding-bottom: 50px;
}
.footer-logo { color: var(--white); margin-bottom: 14px; }
.footer-logo .logo-accent { color: var(--yellow); }
.footer-col p { color: #cbb6a9; font-size: 0.92rem; margin-bottom: 18px; }
.footer-col h3 { color: var(--white); font-size: 1rem; margin-bottom: 18px; }
.footer-col ul li { margin-bottom: 12px; }
.footer-col ul li a { color: #cbb6a9; font-size: 0.92rem; transition: color var(--transition); }
.footer-col ul li a:hover { color: var(--yellow); }
.footer-contact li { color: #cbb6a9; font-size: 0.92rem; }

.social-links { display: flex; gap: 12px; }
.social-icon {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem;
  transition: background var(--transition), transform var(--transition);
}
.social-icon:hover { background: var(--pink); transform: translateY(-3px); }

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 22px 0;
  text-align: center;
  font-size: 0.85rem;
  color: #b39d90;
}

/* =========================================================
   FLOATING WHATSAPP BUTTON
   ========================================================= */
.floating-whatsapp {
  position: fixed;
  bottom: 24px; right: 24px;
  width: 60px; height: 60px;
  background: #25d366;
  color: var(--white);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 10px 26px rgba(37, 211, 102, 0.45);
  z-index: 900;
  transition: transform var(--transition);
  animation: pulse 2.4s ease-in-out infinite;
}
.floating-whatsapp:hover { transform: scale(1.1); }
@keyframes pulse {
  0%, 100% { box-shadow: 0 10px 26px rgba(37, 211, 102, 0.45); }
  50% { box-shadow: 0 10px 26px rgba(37, 211, 102, 0.75); }
}

/* =========================================================
   BACK TO TOP BUTTON
   ========================================================= */
.back-to-top {
  position: fixed;
  bottom: 24px; left: 24px;
  width: 48px; height: 48px;
  background: var(--brown);
  color: var(--white);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-soft);
  z-index: 900;
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: opacity var(--transition), transform var(--transition), background var(--transition);
}
.back-to-top.show {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.back-to-top:hover { background: var(--pink); }

/* =========================================================
   TACTILE PRESS FEEDBACK
   ========================================================= */
.btn:active,
.btn-order:active,
.pill:active,
.category-card:active,
.qty-btn:active,
.icon-btn:active,
.back-to-top:active,
.floating-whatsapp:active {
  transform: scale(0.94);
}

/* Cart badge "bump" feedback when the count changes */
@keyframes badgeBump {
  0% { transform: scale(1); }
  40% { transform: scale(1.35); }
  100% { transform: scale(1); }
}
.cart-badge.bump { animation: badgeBump 0.35s ease; }

/* =========================================================
   CART DRAWER
   ========================================================= */
.cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(74, 47, 36, 0.45);
  z-index: 1400;
  opacity: 0;
  transition: opacity var(--transition);
}
.cart-overlay.open { opacity: 1; }

.cart-drawer {
  position: fixed;
  top: 0; right: 0;
  height: 100vh;
  height: 100dvh;
  width: 100%;
  max-width: 420px;
  background: var(--surface);
  z-index: 1500;
  display: flex;
  flex-direction: column;
  box-shadow: -12px 0 40px rgba(107, 62, 38, 0.2);
  transform: translateX(100%);
  transition: transform var(--transition-slow);
}
.cart-drawer.open { transform: translateX(0); }

.cart-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 22px;
  border-bottom: 1px solid var(--pink-light);
}
.cart-header h2 { font-size: 1.2rem; }

.cart-items {
  flex: 1;
  overflow-y: auto;
  padding: 16px 22px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.cart-item {
  display: grid;
  grid-template-columns: 60px 1fr auto;
  gap: 12px;
  align-items: center;
}
.cart-item img {
  width: 60px; height: 60px;
  border-radius: var(--radius-sm);
  object-fit: cover;
}
.cart-item-info h4 { font-size: 0.95rem; color: var(--heading); margin-bottom: 4px; }
.cart-item-price { font-size: 0.85rem; color: var(--text-muted); }

.cart-item-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}
.qty-control {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--cream);
  border-radius: 50px;
  padding: 4px 8px;
}
.qty-btn {
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--pink-light);
  color: var(--heading);
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  transition: background var(--transition);
}
.qty-btn:hover { background: var(--pink); color: var(--white); }
.qty-value { font-size: 0.85rem; font-weight: 600; min-width: 14px; text-align: center; }

.cart-item-remove {
  font-size: 0.75rem;
  color: var(--pink-dark);
  font-weight: 600;
}
.cart-item-remove:hover { text-decoration: underline; }

.cart-empty {
  text-align: center;
  color: var(--text-muted);
  padding: 40px 20px;
}

.cart-footer {
  border-top: 1px solid var(--pink-light);
  padding: 18px 22px 22px;
}
.cart-total-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--heading);
  margin-bottom: 16px;
}

.checkout-form { display: flex; flex-direction: column; gap: 6px; }
.checkout-form label,
.form-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--heading);
  margin-top: 8px;
}
.checkout-form input[type="text"] {
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 2px solid var(--pink-light);
  background: var(--surface);
  font-family: inherit;
  font-size: 0.95rem;
  color: var(--text-main);
  transition: border-color var(--transition), background-color var(--transition);
}
.checkout-form input[type="text"]:focus { outline: none; border-color: var(--pink); }
.checkout-form input[type="text"]:invalid:not(:placeholder-shown) { border-color: #e0705f; }
.full-width { width: 100%; margin-top: 14px; }

/* Pickup / delivery toggle */
.fulfillment-toggle {
  display: flex;
  gap: 10px;
  margin-top: 6px;
}
.fulfillment-option {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 2px solid var(--pink-light);
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--heading);
  cursor: pointer;
  transition: border-color var(--transition), background var(--transition);
}
.fulfillment-option input {
  position: absolute;
  opacity: 0;
  width: 0; height: 0;
}
.fulfillment-option:has(input:checked) {
  background: var(--pink-light);
  border-color: var(--pink);
}
.fulfillment-option:has(input:focus-visible) {
  outline: 3px solid var(--purple);
  outline-offset: 2px;
}
.pickup-note {
  font-size: 0.85rem;
  color: var(--text-muted);
}
.pickup-note .collapsible-inner {
  background: var(--cream);
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  margin-top: 6px;
}

#locationField.collapsible { margin-top: -6px; }
#locationField .collapsible-inner {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-top: 6px;
}

/* =========================================================
   IMAGE LIGHTBOX
   ========================================================= */
.lightbox-overlay {
  position: fixed;
  inset: 0;
  background: rgba(30, 17, 10, 0.85);
  z-index: 2100;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  transition: opacity var(--transition);
}
.lightbox-overlay:not([hidden]) { display: flex; }
.lightbox-overlay.show { opacity: 1; }

.lightbox {
  position: relative;
  max-width: min(600px, 90vw);
  width: 100%;
  background: var(--surface);
  border-radius: var(--radius-md);
  overflow: hidden;
  text-align: center;
  transform: scale(0.92);
  transition: transform var(--transition-slow);
}
.lightbox-overlay.show .lightbox { transform: scale(1); }

.lightbox img {
  width: 100%;
  max-height: 70vh;
  object-fit: cover;
}
.lightbox-caption {
  padding: 16px;
  font-weight: 600;
  color: var(--heading);
}
.lightbox-close {
  position: absolute;
  top: 12px; right: 12px;
  width: 38px; height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  color: var(--heading);
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem;
  transition: background var(--transition), transform var(--transition);
}
.lightbox-close:hover { background: var(--pink); color: var(--white); }

/* Toast */
.toast {
  position: fixed;
  bottom: 100px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--brown);
  color: var(--white);
  padding: 12px 24px;
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 500;
  box-shadow: var(--shadow-soft);
  z-index: 2000;
  opacity: 0;
  transition: opacity var(--transition), transform var(--transition);
  pointer-events: none;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* =========================================================
   SCROLL ANIMATIONS
   ========================================================= */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s var(--ease-out-soft), transform 0.7s var(--ease-out-soft);
}
.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Staggered entrance for product cards (re-plays on every filter/search) */
@keyframes cardEnter {
  from { opacity: 0; transform: translateY(24px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.card-enter {
  animation: cardEnter 0.45s var(--ease-out-soft) both;
}

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 980px) {
  .hero { grid-template-columns: 1fr; text-align: center; padding-top: 40px; }
  .hero-desc { margin-left: auto; margin-right: auto; }
  .hero-cta-row { justify-content: center; }
  .trust-strip { justify-content: center; }
  .hero-image { order: -1; margin-bottom: 10px; }
  .hero-image img { max-width: 320px; }

  .about { grid-template-columns: 1fr; margin: 0 4vw; padding: 50px 6vw; }
  .about-image { order: -1; }

  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 760px) {
  section { padding: 60px 5vw; }

  .logo-text { font-size: 1.15rem; }
  .nav-actions { gap: 6px; }
  .icon-btn, .hamburger { width: 38px; height: 38px; }

  .nav-links {
    position: fixed;
    top: 0; right: 0;
    height: 100vh;
    height: 100dvh;
    width: 78%;
    max-width: 320px;
    background: var(--surface);
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    padding: 40px;
    gap: 26px;
    box-shadow: -10px 0 30px rgba(0,0,0,0.12);
    transform: translateX(100%);
    transition: transform var(--transition-slow);
    z-index: 1100;
  }
  .nav-links.open { transform: translateX(0); }
  .hamburger { display: flex; }

  .product-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .product-body { padding: 14px; }
  .btn-order { padding: 10px 14px; font-size: 0.8rem; }

  .footer-grid { grid-template-columns: 1fr; text-align: center; }
  .social-links { justify-content: center; }

  .cart-drawer { max-width: 100%; }
  .qty-btn { width: 30px; height: 30px; }
  .cart-item-remove { padding: 4px; }
}

@media (max-width: 480px) {
  .product-grid { grid-template-columns: 1fr; }
  .hero h1 { font-size: 2rem; }
  .btn { width: 100%; }
  .hero-cta-row { flex-direction: column; gap: 12px; }
  .hero-cta-row .btn { padding: 16px 24px; font-size: 1.05rem; }
  .hero-cta-row .btn-outline { border-width: 2px; }
  .btn-lg { width: 100%; }

  /* Keep the nav from overflowing on narrow phones: icon-only logo, tighter icons */
  .logo-text { display: none; }
  .nav-actions { gap: 4px; }
  .icon-btn, .hamburger { width: 36px; height: 36px; }
  .navbar { padding: 12px 4vw; }

  .contact-card, .occasions-card { padding: 40px 5vw; }
  .trust-strip { gap: 8px 14px; }
  .trust-strip li { font-size: 0.78rem; }
}
