/* =============================================
   LUCY'S TREATS — STYLESHEET
   ============================================= */

/* ---- VARIABLES ---- */
:root {
  --primary:       #E8185A;
  --primary-dark:  #C01248;
  --primary-light: #FFD6E7;
  --primary-pale:  #FFF0F5;
  --banner-bg:     #BE1055;
  --cream:         #FFF9F5;
  --brown:         #2C1810;
  --body-text:     #5C3D35;
  --muted:         #9A7070;
  --border:        #F0D0DB;
  --white:         #FFFFFF;
  --shadow-pink:   0 8px 28px rgba(232,24,90,0.14);
  --font-script:   'Dancing Script', cursive;
  --font-body:     'Nunito', sans-serif;
  --nav-h:         80px;
  --radius:        14px;
  --transition:    0.3s ease;
}

/* ---- RESET ---- */
*, *::before, *::after { margin:0; padding:0; box-sizing:border-box; }
html { scroll-behavior:smooth; font-size:16px; }
body {
  font-family: var(--font-body);
  color: var(--brown);
  background: var(--white);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
a { text-decoration:none; color:inherit; }
ul { list-style:none; }
img { max-width:100%; display:block; }
button { font-family: var(--font-body); cursor:pointer; border:none; background:none; }

/* ---- BUTTONS ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 28px;
  border-radius: 50px;
  font-size: 0.92rem;
  font-weight: 700;
  border: 2px solid transparent;
  transition: background var(--transition), border-color var(--transition),
              transform var(--transition), box-shadow var(--transition), color var(--transition);
  white-space: nowrap;
  line-height: 1;
}

.btn-primary {
  background: var(--primary);
  color: var(--white);
  border-color: var(--primary);
}
.btn-primary:hover {
  background: var(--primary-dark);
  border-color: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(232,24,90,0.35);
}

.btn-outline {
  background: transparent;
  color: var(--primary);
  border-color: var(--primary);
}
.btn-outline:hover {
  background: var(--primary);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(232,24,90,0.25);
}

.btn-white {
  background: var(--white);
  color: var(--primary);
  border-color: var(--white);
}
.btn-white:hover {
  background: var(--primary-pale);
  border-color: var(--primary-pale);
}

.btn-sm  { padding: 9px 20px; font-size: 0.82rem; }
.btn-block { width: 100%; }


/* =============================================
   TOP BANNER
   ============================================= */
.top-banner {
  background: var(--banner-bg);
  color: var(--white);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.025em;
  padding: 8px 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.banner-right {
  display: flex;
  align-items: center;
  gap: 14px;
}
.banner-right a {
  color: var(--white);
  opacity: 0.85;
  font-size: 0.9rem;
  transition: opacity 0.2s;
}
.banner-right a:hover { opacity: 1; }


/* =============================================
   NAVBAR
   ============================================= */
.navbar {
  background: var(--white);
  position: sticky;
  top: 0;
  z-index: 900;
  border-bottom: 1px solid var(--border);
  transition: box-shadow var(--transition);
}
.navbar.scrolled { box-shadow: 0 4px 20px rgba(232,24,90,0.1); }

.nav-container {
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 28px;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  gap: 28px;
}

/* Logo */
.nav-logo { flex-shrink: 0; }
.nav-logo img {
  height: 62px;
  width: auto;
  object-fit: contain;
}

/* Nav Links */
.nav-links {
  display: flex;
  align-items: center;
  gap: 2px;
  margin: 0 auto;
}

.nav-links > li { position: relative; }

.nav-links > li > a {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 9px 14px;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--brown);
  border-radius: 8px;
  transition: color var(--transition), background var(--transition);
}
.nav-links > li > a:hover  { color: var(--primary); background: var(--primary-pale); }
.nav-links > li > a.active {
  color: var(--primary);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Dropdown */
.dropdown {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 8px;
  min-width: 190px;
  box-shadow: 0 12px 30px rgba(0,0,0,0.1);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s;
  pointer-events: none;
}
.has-dropdown:hover .dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: all;
}
.dropdown li a {
  display: block;
  padding: 10px 14px;
  font-size: 0.88rem;
  font-weight: 600;
  border-radius: 8px;
  color: var(--brown);
  transition: color 0.2s, background 0.2s;
}
.dropdown li a:hover { color: var(--primary); background: var(--primary-pale); }

/* Nav Actions */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 2px;
  flex-shrink: 0;
}

.icon-btn {
  position: relative;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--brown);
  font-size: 1rem;
  transition: color 0.2s, background 0.2s;
}
.icon-btn:hover { color: var(--primary); background: var(--primary-pale); }

.cart-badge {
  position: absolute;
  top: 3px;
  right: 3px;
  background: var(--primary);
  color: var(--white);
  font-size: 0.6rem;
  font-weight: 800;
  min-width: 16px;
  height: 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 2px;
  line-height: 1;
  border: 1.5px solid var(--white);
}

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  padding: 6px;
  border-radius: 8px;
  transition: background 0.2s;
}
.hamburger:hover { background: var(--primary-pale); }
.hamburger span {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--brown);
  border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.3s ease;
  transform-origin: center;
}
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile Menu */
.mobile-menu {
  display: none;
  border-top: 1px solid var(--border);
  padding: 8px 16px 16px;
  background: var(--white);
}
.mobile-menu.open { display: block; }
.mobile-menu ul { display: flex; flex-direction: column; gap: 2px; }
.mobile-menu ul a {
  display: block;
  padding: 12px 16px;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--brown);
  border-radius: 10px;
  transition: color 0.2s, background 0.2s;
}
.mobile-menu ul a:hover { color: var(--primary); background: var(--primary-pale); }


/* =============================================
   HERO
   ============================================= */
.hero {
  background: linear-gradient(135deg, #fff5f8 0%, #ffe8f0 55%, #ffd6e7 100%);
  overflow: hidden;
}

.hero-inner {
  max-width: 1320px;
  margin: 0 auto;
  padding: 64px 28px 40px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 32px;
  min-height: calc(100vh - var(--nav-h) - 38px);
}

/* Hero text */
.hero-text { z-index: 1; }

.hero-regular {
  display: block;
  font-size: clamp(1.9rem, 3.2vw, 2.9rem);
  font-weight: 900;
  color: var(--brown);
  line-height: 1.1;
}
.hero-script {
  display: block;
  font-family: var(--font-script);
  font-size: clamp(2.6rem, 4.6vw, 4.1rem);
  color: var(--primary);
  line-height: 1.15;
  margin-top: 2px;
}

.hero-hearts {
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 14px 0;
  color: var(--primary);
}

.hero-text p {
  font-size: 1.05rem;
  color: var(--body-text);
  font-weight: 500;
  margin-bottom: 30px;
  max-width: 360px;
  line-height: 1.6;
}

/* Hero image */
.hero-image {
  display: flex;
  justify-content: center;
  align-items: center;
}
.hero-image img {
  width: 100%;
  max-width: 580px;
  filter: drop-shadow(0 24px 48px rgba(232,24,90,0.22));
  animation: floatHero 7s ease-in-out infinite;
}

@keyframes floatHero {
  0%, 100% { transform: translateY(0px); }
  50%       { transform: translateY(-14px); }
}


/* =============================================
   FEATURES BAR
   ============================================= */
.features {
  background: var(--cream);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 48px 28px;
}

.features-inner {
  max-width: 1320px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 28px;
}

.feature-item {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}

.feature-icon {
  flex-shrink: 0;
  width: 52px;
  height: 52px;
  background: var(--white);
  border: 2px solid var(--primary-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
}
.feature-icon svg {
  width: 22px;
  height: 22px;
}

.feature-body h3 {
  font-size: 0.92rem;
  font-weight: 800;
  color: var(--brown);
  margin-bottom: 4px;
}
.feature-body p {
  font-size: 0.8rem;
  color: var(--body-text);
  line-height: 1.55;
}


/* =============================================
   PRODUCTS
   ============================================= */
.products { padding: 80px 28px; background: var(--white); }

.products-inner { max-width: 1320px; margin: 0 auto; }

/* Section Header */
.section-header { text-align: center; margin-bottom: 48px; }
.section-header h2 {
  font-size: clamp(1.7rem, 2.8vw, 2.4rem);
  font-weight: 900;
  color: var(--brown);
  margin-bottom: 14px;
}
.section-rule {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  color: var(--primary);
  font-size: 0.9rem;
}
.rule-line {
  display: block;
  width: 60px;
  height: 2px;
  background: var(--primary-light);
  border-radius: 2px;
}

/* Grid */
.products-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 16px;
  margin-bottom: 44px;
}

/* Card */
.product-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--white);
  transition: transform var(--transition), box-shadow var(--transition);
}
.product-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-pink);
}

/* Product Image Area */
.product-img-wrap { position: relative; overflow: hidden; }

.product-placeholder {
  width: 100%;
  aspect-ratio: 1 / 1;
  background: var(--ph-color, #FFE4EF);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.8rem;
  transition: transform 0.4s ease;
}
.product-card:hover .product-placeholder { transform: scale(1.06); }

.product-hover-overlay {
  position: absolute;
  inset: 0;
  background: rgba(232, 24, 90, 0.72);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.product-card:hover .product-hover-overlay { opacity: 1; }

/* Product Details */
.product-details { padding: 14px 12px; }
.product-details h3 {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--brown);
  margin-bottom: 6px;
  line-height: 1.35;
}
.price {
  font-size: 0.95rem;
  font-weight: 900;
  color: var(--primary);
  margin-bottom: 10px;
}

.add-to-cart {
  font-size: 0.78rem;
  padding: 9px 12px;
}

/* Products Footer */
.products-footer { display: flex; justify-content: center; }


/* =============================================
   ABOUT / CTA
   ============================================= */
.about-cta {
  background: linear-gradient(135deg, #fff5f8 0%, #ffe8f0 60%, #ffd6e7 100%);
  padding: 90px 28px;
}

.about-inner {
  max-width: 1320px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 72px;
}

.about-regular {
  display: block;
  font-size: clamp(1.6rem, 2.4vw, 2.2rem);
  font-weight: 900;
  color: var(--brown);
  line-height: 1.1;
}
.about-script {
  display: block;
  font-family: var(--font-script);
  font-size: clamp(2.2rem, 3.8vw, 3.2rem);
  color: var(--primary);
  line-height: 1.15;
  margin-top: 4px;
}
.about-hearts {
  color: var(--primary);
  margin: 14px 0;
}
.about-text p {
  font-size: 1rem;
  color: var(--body-text);
  font-weight: 500;
  line-height: 1.65;
  margin-bottom: 30px;
  max-width: 400px;
}

.about-img-placeholder {
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(232,24,90,0.18);
  background: var(--primary-pale);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.about-img-placeholder img {
  width: 100%;
  max-width: 440px;
  margin: 0 auto;
  filter: drop-shadow(0 12px 24px rgba(232,24,90,0.15));
}


/* =============================================
   FOOTER BANNER
   ============================================= */
.footer-banner {
  width: 100%;
  overflow: hidden;
  max-height: 320px;
  position: relative;
}
.footer-banner img {
  width: 100%;
  height: 320px;
  object-fit: cover;
  object-position: center;
  display: block;
}

/* =============================================
   FOOTER
   ============================================= */
.footer {
  background: #1C0D08;
  color: rgba(255,255,255,0.75);
  padding: 64px 28px 0;
}

.footer-inner {
  max-width: 1320px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.6fr;
  gap: 52px;
  padding-bottom: 52px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.footer-logo {
  height: 110px;
  width: auto;
  margin-bottom: 14px;
  filter: drop-shadow(0 4px 10px rgba(0,0,0,0.35));
}
.footer-brand p {
  font-size: 0.85rem;
  line-height: 1.75;
  max-width: 260px;
  margin-bottom: 22px;
}
.footer-socials {
  display: flex;
  gap: 10px;
}
.footer-socials a {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,0.1);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.82rem;
  transition: background 0.2s;
}
.footer-socials a:hover { background: var(--primary); }

.footer-col h4 {
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--white);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 22px;
}
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col ul li a {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.6);
  transition: color 0.2s;
}
.footer-col ul li a:hover { color: var(--primary-light); }

.footer-contact-list { display: flex; flex-direction: column; gap: 12px; }
.footer-contact-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.84rem;
  color: rgba(255,255,255,0.65);
}
.footer-contact-list li i {
  color: var(--primary-light);
  width: 14px;
  flex-shrink: 0;
}

.footer-bottom {
  max-width: 1320px;
  margin: 0 auto;
  padding: 22px 0;
  text-align: center;
  font-size: 0.78rem;
  color: rgba(255,255,255,0.35);
}


/* =============================================
   CART SIDEBAR
   ============================================= */
.cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  z-index: 1100;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s;
  backdrop-filter: blur(2px);
}
.cart-overlay.open { opacity: 1; visibility: visible; }

.cart-sidebar {
  position: fixed;
  top: 0;
  right: 0;
  height: 100%;
  width: 380px;
  max-width: 100vw;
  background: var(--white);
  z-index: 1200;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.38s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: -8px 0 40px rgba(0,0,0,0.12);
}
.cart-sidebar.open { transform: translateX(0); }

.cart-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 24px;
  border-bottom: 1px solid var(--border);
}
.cart-header h3 {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--brown);
  display: flex;
  align-items: center;
  gap: 10px;
}
.cart-header h3 i { color: var(--primary); }

.cart-close {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 1rem;
  transition: color 0.2s, background 0.2s;
}
.cart-close:hover { color: var(--primary); background: var(--primary-pale); }

.cart-items {
  flex: 1;
  overflow-y: auto;
  padding: 16px 24px;
}

.cart-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  gap: 14px;
  color: var(--muted);
  text-align: center;
  padding: 40px 0;
}
.cart-empty i { font-size: 3rem; color: var(--primary-light); }
.cart-empty p { font-size: 0.95rem; font-weight: 600; }

.cart-line-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
  gap: 12px;
}
.cart-item-info h4 {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--brown);
  margin-bottom: 4px;
}
.cart-item-price { font-size: 0.85rem; font-weight: 800; color: var(--primary); }
.cart-item-qty {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.qty-btn {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--primary-pale);
  color: var(--primary);
  font-size: 1rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}
.qty-btn:hover { background: var(--primary-light); }
.qty-num { font-size: 0.9rem; font-weight: 800; min-width: 20px; text-align: center; }

.cart-footer {
  padding: 20px 24px;
  border-top: 1px solid var(--border);
  background: var(--cream);
}
.cart-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  font-weight: 700;
  font-size: 1rem;
  color: var(--brown);
}
.cart-total-price { color: var(--primary); font-size: 1.2rem; font-weight: 900; }


/* =============================================
   TOAST
   ============================================= */
.toast {
  position: fixed;
  bottom: 28px;
  right: 28px;
  background: var(--primary);
  color: var(--white);
  padding: 14px 24px;
  border-radius: 50px;
  font-size: 0.88rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 10px;
  box-shadow: 0 10px 28px rgba(232,24,90,0.38);
  transform: translateY(80px);
  opacity: 0;
  z-index: 9999;
  transition: transform 0.42s cubic-bezier(0.175,0.885,0.32,1.275),
              opacity 0.42s ease;
  pointer-events: none;
}
.toast.show { transform: translateY(0); opacity: 1; }


/* =============================================
   RESPONSIVE — TABLET (≤ 1100px)
   ============================================= */
@media (max-width: 1100px) {
  .products-grid { grid-template-columns: repeat(3, 1fr); }

  .features-inner { grid-template-columns: repeat(2, 1fr); }

  .footer-inner { grid-template-columns: 1fr 1fr; gap: 36px; }
}

/* =============================================
   RESPONSIVE — MEDIUM (≤ 880px)
   ============================================= */
@media (max-width: 880px) {
  .nav-links { display: none; }
  .hamburger { display: flex; }

  .hero-inner {
    grid-template-columns: 1fr;
    text-align: center;
    padding: 40px 24px 48px;
    min-height: unset;
    gap: 24px;
  }
  .hero-text p { max-width: 100%; }
  .hero-image { order: -1; }
  .hero-image img { max-width: 340px; }
  .hero-hearts { justify-content: center; }

  .about-inner {
    grid-template-columns: 1fr;
    gap: 40px;
    text-align: center;
  }
  .about-image { order: -1; }
  .about-text p { max-width: 100%; }
  .about-hearts { justify-content: center; }
}

/* =============================================
   RESPONSIVE — MOBILE (≤ 640px)
   ============================================= */
@media (max-width: 640px) {
  .top-banner {
    flex-direction: column;
    gap: 6px;
    text-align: center;
    padding: 8px 16px;
  }

  .nav-container { padding: 0 16px; gap: 12px; }
  .nav-logo img { height: 50px; }

  .products-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }

  /* Mobile-style product card: horizontal layout */
  @media (max-width: 480px) {
    .product-card {
      display: flex;
      flex-direction: row;
      border-radius: 12px;
    }
    .product-img-wrap {
      width: 100px;
      flex-shrink: 0;
    }
    .product-placeholder { aspect-ratio: unset; height: 100%; font-size: 2rem; }
    .product-hover-overlay { display: none; }
    .product-details { padding: 12px 10px; display: flex; flex-direction: column; justify-content: center; flex: 1; }
    .products-grid { grid-template-columns: 1fr; }
  }

  .features-inner { grid-template-columns: 1fr 1fr; gap: 20px; }

  .footer-inner { grid-template-columns: 1fr; gap: 32px; }

  .hero-image img { max-width: 280px; }

  .cart-sidebar { width: 100%; }

  .toast { bottom: 16px; right: 16px; left: 16px; justify-content: center; }
}
