/* ===== CAKES BY DARLINA — PREMIUM STYLES ===== */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;600;700&family=Poppins:wght@300;400;500;600&display=swap');

:root {
  --primary: #c4756e;
  --primary-dark: #a85a54;
  --gold: #c9a96e;
  --gold-light: #e8d5a3;
  --cream: #fdf8f4;
  --pink-light: #fff5f5;
  --text: #2d2d2d;
  --text-light: #6b6b6b;
  --white: #ffffff;
  --shadow: 0 4px 30px rgba(196, 117, 110, 0.15);
  --shadow-lg: 0 10px 60px rgba(196, 117, 110, 0.2);
  --radius: 16px;
}

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

html { scroll-behavior: smooth; overflow-x: hidden; }

body {
  font-family: 'Poppins', sans-serif;
  background: var(--cream);
  color: var(--text);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  width: 100%;
  max-width: 100vw;
}

/* ===== LOADER ===== */
.loader {
  position: fixed;
  inset: 0;
  background: linear-gradient(135deg, #fff5f5, #fff0e6);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: transform 0.8s ease, opacity 0.8s ease;
  overflow: hidden;
}

.loader.hide {
  transform: translateY(-100%);
  opacity: 0;
  pointer-events: none;
}

.hearts {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.heart {
  position: absolute;
  color: var(--primary);
  opacity: 0;
  animation: floatHeart 3s ease-in-out infinite;
}

.heart:nth-child(1) { left: 5%; top: 80%; animation-delay: 0s; font-size: 24px; }
.heart:nth-child(2) { left: 15%; top: 85%; animation-delay: 0.3s; font-size: 32px; }
.heart:nth-child(3) { left: 25%; top: 90%; animation-delay: 0.6s; font-size: 20px; }
.heart:nth-child(4) { left: 35%; top: 82%; animation-delay: 0.9s; font-size: 28px; }
.heart:nth-child(5) { left: 45%; top: 88%; animation-delay: 1.2s; font-size: 36px; }
.heart:nth-child(6) { left: 55%; top: 84%; animation-delay: 0.4s; font-size: 24px; }
.heart:nth-child(7) { left: 65%; top: 90%; animation-delay: 0.7s; font-size: 30px; }
.heart:nth-child(8) { left: 75%; top: 86%; animation-delay: 1s; font-size: 22px; }
.heart:nth-child(9) { left: 85%; top: 82%; animation-delay: 0.5s; font-size: 34px; }
.heart:nth-child(10) { left: 92%; top: 88%; animation-delay: 0.8s; font-size: 26px; }
.heart:nth-child(11) { left: 10%; top: 75%; animation-delay: 1.4s; font-size: 20px; }
.heart:nth-child(12) { left: 50%; top: 92%; animation-delay: 1.6s; font-size: 38px; }
.heart:nth-child(13) { left: 70%; top: 78%; animation-delay: 0.2s; font-size: 22px; }
.heart:nth-child(14) { left: 30%; top: 95%; animation-delay: 1.1s; font-size: 30px; }
.heart:nth-child(15) { left: 80%; top: 92%; animation-delay: 1.3s; font-size: 26px; }

@keyframes floatHeart {
  0% { opacity: 0; transform: translateY(0) rotate(0deg) scale(0.5); }
  20% { opacity: 0.7; }
  50% { opacity: 0.5; transform: translateY(-200px) rotate(20deg) scale(1); }
  80% { opacity: 0.2; }
  100% { opacity: 0; transform: translateY(-400px) rotate(-10deg) scale(0.8); }
}

.loader svg {
  width: 140px;
  height: 140px;
  position: relative;
  z-index: 2;
}

.tart-outline {
  fill: none;
  stroke: var(--primary);
  stroke-width: 2;
  stroke-dasharray: 400;
  stroke-dashoffset: 400;
  animation: draw 1.2s ease-in-out 0.2s forwards;
}

.tart-fill {
  opacity: 0;
  animation: fillIn 0.4s ease-out 1.4s forwards;
}

.loader-logo {
  width: 280px;
  max-width: 70vw;
  margin-top: 24px;
  opacity: 0;
  transform: scale(0.3) rotate(-5deg);
  animation: logoWow 1s cubic-bezier(0.175, 0.885, 0.32, 1.275) 1.8s forwards;
  position: relative;
  z-index: 2;
  filter: drop-shadow(0 4px 20px rgba(196, 117, 110, 0.3));
}

.loader p {
  margin-top: 16px;
  font-size: 13px;
  color: var(--primary);
  letter-spacing: 4px;
  text-transform: uppercase;
  opacity: 0;
  animation: fadeIn 0.6s ease-out 2.8s forwards;
  position: relative;
  z-index: 2;
}

.spiral {
  position: absolute;
  border: 2px solid rgba(196, 117, 110, 0.12);
  border-radius: 50%;
  opacity: 0;
  animation: spiralIn 1.5s ease-out forwards;
}

.spiral:nth-child(1) { width: 320px; height: 320px; animation-delay: 1.6s; }
.spiral:nth-child(2) { width: 380px; height: 380px; animation-delay: 1.8s; border-style: dashed; }
.spiral:nth-child(3) { width: 440px; height: 440px; animation-delay: 2s; }

@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes fillIn { to { opacity: 1; } }
@keyframes logoWow { to { opacity: 1; transform: scale(1) rotate(0deg); } }
@keyframes fadeIn { to { opacity: 1; } }
@keyframes spiralIn {
  0% { opacity: 0; transform: scale(0.5) rotate(-180deg); }
  100% { opacity: 1; transform: scale(1) rotate(0deg); }
}

/* ===== HEADER / NAV ===== */
header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(196, 117, 110, 0.1);
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: box-shadow 0.3s;
}

header.scrolled { box-shadow: var(--shadow); }

header img {
  height: 44px;
}

.nav-links {
  display: flex;
  gap: 24px;
  list-style: none;
}

.nav-links a {
  text-decoration: none;
  color: var(--text);
  font-size: 14px;
  font-weight: 500;
  transition: color 0.3s;
}

.nav-links a:hover { color: var(--primary); }

.cart-btn {
  position: relative;
  background: none;
  border: none;
  cursor: pointer;
  font-size: 24px;
  padding: 8px;
}

.cart-badge {
  position: absolute;
  top: 2px;
  right: 2px;
  background: var(--primary);
  color: white;
  font-size: 10px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
}

.cart-badge:empty { display: none; }

/* ===== HERO ===== */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 120px 24px 80px;
  background: linear-gradient(180deg, var(--cream) 0%, var(--pink-light) 100%);
  position: relative;
  overflow: hidden;
  max-width: 100%;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(201, 169, 110, 0.08) 0%, transparent 70%);
  border-radius: 50%;
}

.hero-content { position: relative; z-index: 2; }

.hero h1 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(36px, 8vw, 64px);
  font-weight: 700;
  color: var(--text);
  line-height: 1.2;
  margin-bottom: 16px;
}

.hero h1 span {
  color: var(--primary);
  display: block;
}

.hero-tagline {
  font-size: 16px;
  color: var(--text-light);
  margin-bottom: 32px;
  font-weight: 300;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--primary);
  color: white;
  padding: 16px 36px;
  border-radius: 50px;
  text-decoration: none;
  font-weight: 500;
  font-size: 15px;
  transition: all 0.3s;
  box-shadow: 0 4px 20px rgba(196, 117, 110, 0.4);
}

.hero-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(196, 117, 110, 0.5);
}

.hero-images {
  display: flex;
  gap: 16px;
  margin-top: 48px;
  justify-content: center;
  flex-wrap: wrap;
}

.hero-images img {
  width: 180px;
  height: 220px;
  object-fit: cover;
  object-position: center;
  border-radius: 20px;
  box-shadow: var(--shadow);
  transition: transform 0.3s;
}

.hero-images img:hover { transform: scale(1.05) rotate(2deg); }

/* ===== SECTION COMMON ===== */
section {
  padding: 80px 24px;
  max-width: 1100px;
  margin: 0 auto;
}

.section-title {
  font-family: 'Playfair Display', serif;
  font-size: 32px;
  text-align: center;
  margin-bottom: 8px;
  color: var(--text);
}

.section-subtitle {
  text-align: center;
  color: var(--text-light);
  font-size: 14px;
  margin-bottom: 48px;
}

/* ===== MENU / PRODUCTS ===== */
.products {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 32px;
}

.product-card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.3s, box-shadow 0.3s;
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.product-card img {
  width: 100%;
  height: 280px;
  object-fit: cover;
  object-position: center;
}

.product-info {
  padding: 24px;
}

.product-info h3 {
  font-family: 'Playfair Display', serif;
  font-size: 22px;
  margin-bottom: 8px;
}

.product-info .price {
  color: var(--primary);
  font-weight: 600;
  font-size: 18px;
  margin-bottom: 12px;
}

.product-info .desc {
  color: var(--text-light);
  font-size: 13px;
  line-height: 1.6;
  margin-bottom: 16px;
}

/* Fruit Tart Options */
.tart-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}

.tart-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  border: 2px solid #f0e6e4;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s;
  font-size: 13px;
}

.tart-option:hover, .tart-option.selected {
  border-color: var(--primary);
  background: var(--pink-light);
}

.tart-option .opt-price {
  font-weight: 600;
  color: var(--primary);
}

/* Panna Cotta Qty */
.qty-control {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 16px;
}

.qty-control button {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 2px solid var(--primary);
  background: none;
  color: var(--primary);
  font-size: 18px;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.qty-control button:hover {
  background: var(--primary);
  color: white;
}

.qty-control span {
  font-size: 18px;
  font-weight: 600;
  min-width: 40px;
  text-align: center;
}

.qty-note {
  font-size: 11px;
  color: var(--text-light);
  margin-bottom: 16px;
}

.add-cart-btn {
  width: 100%;
  padding: 14px;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  font-family: 'Poppins', sans-serif;
}

.add-cart-btn:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
}

/* Fruit checkboxes */
.fruit-select {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.fruit-chip {
  padding: 6px 14px;
  border: 2px solid #f0e6e4;
  border-radius: 20px;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.2s;
  user-select: none;
}

.fruit-chip.selected {
  border-color: var(--primary);
  background: var(--primary);
  color: white;
}

.fruit-chip.disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* ===== CART PANEL ===== */
.cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 200;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}

.cart-overlay.open { opacity: 1; pointer-events: all; }

.cart-panel {
  position: fixed;
  top: 0;
  right: -100%;
  width: 380px;
  max-width: 90vw;
  height: 100vh;
  background: var(--white);
  z-index: 201;
  transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  box-shadow: none;
}

.cart-panel.open { right: 0; box-shadow: -10px 0 40px rgba(0,0,0,0.1); }

.cart-header {
  padding: 24px;
  border-bottom: 1px solid #f0e6e4;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.cart-header h2 {
  font-family: 'Playfair Display', serif;
  font-size: 20px;
}

.cart-close {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: var(--text-light);
}

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

.cart-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid #f5f0ee;
}

.cart-item-info { flex: 1; }

.cart-item-info h4 { font-size: 14px; margin-bottom: 4px; }
.cart-item-info p { font-size: 12px; color: var(--text-light); }
.cart-item-price { font-weight: 600; color: var(--primary); font-size: 14px; }

.cart-item-remove {
  background: none;
  border: none;
  color: #ccc;
  cursor: pointer;
  font-size: 18px;
  transition: color 0.2s;
}

.cart-item-remove:hover { color: #e74c3c; }

.cart-empty {
  text-align: center;
  padding: 48px 24px;
  color: var(--text-light);
}

.cart-footer {
  padding: 24px;
  border-top: 1px solid #f0e6e4;
}

.cart-total {
  display: flex;
  justify-content: space-between;
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 16px;
}

.checkout-btn {
  width: 100%;
  padding: 16px;
  background: #25d366;
  color: white;
  border: none;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: 'Poppins', sans-serif;
  transition: all 0.3s;
}

.checkout-btn:hover {
  background: #1fb855;
  transform: translateY(-1px);
}

/* ===== CHECKOUT FORM ===== */
.checkout-form {
  display: none;
  padding: 24px;
  flex-direction: column;
  gap: 14px;
  flex: 1;
  overflow-y: auto;
}

.checkout-form.active { display: flex; }

.checkout-form h3 {
  font-family: 'Playfair Display', serif;
  font-size: 18px;
  margin-bottom: 4px;
}

.form-group { display: flex; flex-direction: column; gap: 4px; }

.form-group label {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-light);
}

.form-group input, .form-group select {
  padding: 12px 14px;
  border: 2px solid #f0e6e4;
  border-radius: 10px;
  font-size: 14px;
  font-family: 'Poppins', sans-serif;
  transition: border-color 0.2s;
  outline: none;
}

.form-group input:focus, .form-group select:focus {
  border-color: var(--primary);
}

.delivery-km {
  display: none;
  gap: 4px;
}

.delivery-km.show { display: flex; flex-direction: column; }

.form-note {
  font-size: 11px;
  color: var(--text-light);
  background: var(--pink-light);
  padding: 10px 14px;
  border-radius: 8px;
}

.back-to-cart {
  background: none;
  border: 2px solid #f0e6e4;
  padding: 12px;
  border-radius: 10px;
  cursor: pointer;
  font-family: 'Poppins', sans-serif;
  font-size: 13px;
  color: var(--text-light);
  transition: all 0.2s;
}

.back-to-cart:hover { border-color: var(--primary); color: var(--primary); }

.send-wa-btn {
  width: 100%;
  padding: 16px;
  background: #25d366;
  color: white;
  border: none;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: 'Poppins', sans-serif;
  transition: all 0.3s;
}

.send-wa-btn:hover { background: #1fb855; }

/* ===== GALLERY ===== */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  max-width: 700px;
  margin: 0 auto;
}

.gallery-grid img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  object-position: center;
  border-radius: 12px;
  cursor: pointer;
  transition: transform 0.3s, box-shadow 0.3s;
}

.gallery-grid img:hover { transform: scale(1.03); box-shadow: var(--shadow-lg); }

/* ===== INFO SECTION ===== */
.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 24px;
}

.info-card {
  background: var(--white);
  padding: 32px;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  text-align: center;
}

.info-card .icon {
  font-size: 36px;
  margin-bottom: 12px;
}

.info-card h3 {
  font-family: 'Playfair Display', serif;
  font-size: 18px;
  margin-bottom: 8px;
}

.info-card p {
  font-size: 13px;
  color: var(--text-light);
  line-height: 1.6;
}

/* ===== FOOTER ===== */
footer {
  background: var(--text);
  color: white;
  padding: 48px 24px;
  text-align: center;
}

footer img { height: 50px; margin-bottom: 16px; }

.footer-links {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-bottom: 16px;
}

.footer-links a {
  color: rgba(255,255,255,0.7);
  text-decoration: none;
  transition: color 0.3s;
  display: flex;
  align-items: center;
}

.footer-links a:hover { color: white; }

footer p {
  font-size: 12px;
  color: rgba(255,255,255,0.5);
}

/* ===== FLOATING WHATSAPP ===== */
.wa-float {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 56px;
  height: 56px;
  background: #25d366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: white;
  text-decoration: none;
  box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
  z-index: 90;
  transition: transform 0.3s;
  animation: pulse 2s infinite;
}

.wa-float:hover { transform: scale(1.1); }

@keyframes pulse {
  0%, 100% { box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4); }
  50% { box-shadow: 0 4px 30px rgba(37, 211, 102, 0.6); }
}

/* ===== FLOATING ORDER BUTTON ===== */
.order-float {
  position: fixed;
  bottom: 24px;
  left: 24px;
  background: var(--primary);
  color: white;
  padding: 12px 20px;
  border-radius: 50px;
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  font-family: 'Poppins', sans-serif;
  display: flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 4px 20px rgba(196, 117, 110, 0.4);
  z-index: 90;
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
  transition: all 0.3s;
}

.order-float.visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: all;
}

.order-float:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(196, 117, 110, 0.5);
}

.gallery-hidden { display: none; }
.gallery-grid.expanded .gallery-hidden { display: block; }

.view-more-btn {
  background: none;
  border: 2px solid var(--primary);
  color: var(--primary);
  padding: 12px 32px;
  border-radius: 50px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  font-family: 'Poppins', sans-serif;
  transition: all 0.3s;
}

.view-more-btn:hover {
  background: var(--primary);
  color: white;
}

/* ===== HAMBURGER & MOBILE NAV ===== */
.hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  flex-direction: column;
  gap: 5px;
}

.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: all 0.3s;
}

.mobile-nav {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(20px);
  z-index: 150;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 28px;
}

.mobile-nav.open { display: flex; }

.mobile-nav a {
  text-decoration: none;
  color: var(--text);
  font-size: 20px;
  font-weight: 500;
  transition: color 0.3s;
}

.mobile-nav a:hover { color: var(--primary); }

.mobile-nav-close {
  position: absolute;
  top: 20px;
  right: 24px;
  background: none;
  border: none;
  font-size: 32px;
  color: var(--text-light);
  cursor: pointer;
}

/* Scroll offset for fixed header */
section[id] { scroll-margin-top: 80px; }

@media (max-width: 768px) {
  .hamburger { display: flex; }
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .nav-links { display: none; }
  .hero { min-height: auto; padding: 100px 16px 60px; }
  .hero h1 { font-size: 36px; }
  .hero-tagline { font-size: 15px; }
  .hero-images { gap: 10px; margin-top: 32px; }
  .hero-images img { width: 100px; height: 130px; border-radius: 14px; }
  .cart-panel { width: 100vw; max-width: 100vw; }
  section { padding: 50px 16px; }
  .section-title { font-size: 26px; }
  .section-subtitle { font-size: 14px; }
  .products { grid-template-columns: 1fr; gap: 20px; }
  .product-card img { height: 220px; }
  .product-info { padding: 20px; }
  .product-info h3 { font-size: 20px; }
  .product-info .desc { font-size: 14px; }
  .product-info .price { font-size: 18px; }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .gallery-grid img { height: 150px; }
  .info-grid { grid-template-columns: 1fr; gap: 16px; }
  .info-card { padding: 24px 20px; }
  .info-card h3 { font-size: 17px; }
  .info-card p { font-size: 14px; }
  header { padding: 10px 16px; }
  header img { height: 36px; }
  .cart-btn { padding: 6px; }
  .order-float { padding: 14px 22px; font-size: 14px; bottom: 20px; left: 20px; }
  .wa-float { width: 50px; height: 50px; bottom: 20px; right: 20px; }
  .loader svg { width: 100px; height: 100px; }
  .loader-logo { width: 200px; }
  .tart-option { padding: 12px 14px; font-size: 14px; }
  .fruit-chip { padding: 8px 14px; font-size: 13px; }
  .add-cart-btn { font-size: 14px; padding: 14px; }
  .qty-note { font-size: 12px; }
  .qty-control span { font-size: 18px; }
  footer { padding: 36px 16px; }
}
