/* ===================================================================
   SWEETBREW CAFE — MASTER STYLESHEET
   Brand Identity: Sweet, Modern, Aesthetic, Pastel & Candy Pink Cafe
   Tagline: "Good Coffee, Better Mood ♡"
   =================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,500;0,600;0,700;0,800;1,600&family=Poppins:wght@300;400;500;600;700&display=swap');

:root {
  /* Brand Color Palette */
  --pastel-pink: #F9D3E2;
  --light-pink: #FCE7F0;
  --candy-pink: #F4A6C1;
  --berry-pink: #E83E83;
  --deep-rose: #8F244C;
  --cream-white: #FFF8F5;
  --soft-gray: #F5F3F4;
  --dark-text: #442A35;
  
  /* Additional UI Palette */
  --white: #FFFFFF;
  --muted-text: #7D636E;
  --border-pink: #F5D3E0;
  --card-bg: #FFFFFF;
  --success: #10B981;
  --warning: #F59E0B;
  --danger: #EF4444;
  --info: #3B82F6;
  
  /* Shadows & Radius */
  --shadow-sm: 0 2px 8px rgba(143, 36, 76, 0.05);
  --shadow-md: 0 8px 24px rgba(232, 62, 131, 0.10);
  --shadow-lg: 0 16px 36px rgba(143, 36, 76, 0.14);
  --shadow-glow: 0 0 25px rgba(244, 166, 193, 0.5);
  
  --radius-xs: 6px;
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-full: 9999px;

  /* Transitions */
  --transition-fast: 0.2s ease;
  --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Base Resets */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  color: var(--dark-text);
  background-color: var(--cream-white);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Typography */
h1, h2, h3, h4, .font-serif {
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 700;
  color: var(--deep-rose);
  line-height: 1.25;
}

p {
  color: var(--muted-text);
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition-fast);
}

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

button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  outline: none;
  border: none;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: var(--light-pink);
}
::-webkit-scrollbar-thumb {
  background: var(--candy-pink);
  border-radius: var(--radius-full);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--berry-pink);
}

/* Layout Utilities */
.container {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 20px;
}

.section-padding {
  padding: 80px 0;
}

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-end { justify-content: flex-end; }
.gap-1 { gap: 4px; }
.gap-2 { gap: 8px; }
.gap-3 { gap: 12px; }
.gap-4 { gap: 16px; }
.gap-6 { gap: 24px; }
.gap-8 { gap: 32px; }

/* Demo Disclaimer Banner */
.demo-banner {
  background: linear-gradient(90deg, var(--deep-rose), var(--berry-pink));
  color: var(--white);
  text-align: center;
  padding: 8px 16px;
  font-size: 0.82rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  position: relative;
  z-index: 1000;
  box-shadow: 0 2px 8px rgba(143, 36, 76, 0.2);
}
.demo-banner a {
  color: var(--light-pink);
  text-decoration: underline;
  font-weight: 600;
}
.demo-banner .badge-pill {
  background: rgba(255, 255, 255, 0.25);
  padding: 2px 8px;
  border-radius: var(--radius-full);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Navigation Bar */
.navbar {
  position: sticky;
  top: 0;
  background: rgba(255, 248, 245, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  z-index: 900;
  border-bottom: 1px solid var(--border-pink);
  transition: var(--transition-normal);
}
.navbar.scrolled {
  background: rgba(255, 255, 255, 0.98);
  box-shadow: var(--shadow-sm);
}
.navbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
}

/* Brand Logo */
.brand-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}
.brand-logo-icon {
  width: 46px;
  height: 46px;
  background: linear-gradient(135deg, var(--candy-pink), var(--berry-pink));
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-size: 1.4rem;
  box-shadow: 0 4px 12px rgba(232, 62, 131, 0.3);
  transition: var(--transition-fast);
}
.brand-logo:hover .brand-logo-icon {
  transform: rotate(-6deg) scale(1.05);
}
.brand-logo-text {
  display: flex;
  flex-direction: column;
}
.brand-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.45rem;
  font-weight: 800;
  color: var(--deep-rose);
  letter-spacing: -0.5px;
  line-height: 1.1;
}
.brand-title span {
  color: var(--berry-pink);
}
.brand-tagline {
  font-size: 0.72rem;
  color: var(--muted-text);
  font-weight: 500;
}

/* Nav Menu */
.nav-menu {
  display: flex;
  align-items: center;
  gap: 28px;
  list-style: none;
}
.nav-link {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--dark-text);
  position: relative;
  padding: 6px 0;
  transition: var(--transition-fast);
}
.nav-link:hover, .nav-link.active {
  color: var(--berry-pink);
}
.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0%;
  height: 2px;
  background: var(--berry-pink);
  border-radius: var(--radius-full);
  transition: var(--transition-normal);
}
.nav-link:hover::after, .nav-link.active::after {
  width: 100%;
}

/* Nav Actions */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}
.cart-btn-wrapper {
  position: relative;
}
.icon-btn {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-full);
  background: var(--light-pink);
  color: var(--deep-rose);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  cursor: pointer;
  transition: var(--transition-fast);
  border: 1px solid var(--border-pink);
}
.icon-btn:hover {
  background: var(--candy-pink);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(232, 62, 131, 0.2);
}
.cart-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--berry-pink);
  color: var(--white);
  font-size: 0.7rem;
  font-weight: 700;
  width: 20px;
  height: 20px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--white);
  box-shadow: 0 2px 6px rgba(232, 62, 131, 0.4);
}

/* Mobile Toggle */
.mobile-toggle {
  display: none;
  background: none;
  font-size: 1.4rem;
  color: var(--deep-rose);
  cursor: pointer;
}

/* Button Styles */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: var(--transition-normal);
  text-align: center;
  white-space: nowrap;
}
.btn-sm {
  padding: 8px 16px;
  font-size: 0.85rem;
}
.btn-lg {
  padding: 14px 32px;
  font-size: 1.05rem;
}
.btn-primary {
  background: linear-gradient(135deg, var(--berry-pink), var(--deep-rose));
  color: var(--white);
  box-shadow: 0 6px 18px rgba(232, 62, 131, 0.3);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(232, 62, 131, 0.4);
  color: var(--white);
}
.btn-secondary {
  background: var(--light-pink);
  color: var(--deep-rose);
  border: 1px solid var(--candy-pink);
}
.btn-secondary:hover {
  background: var(--candy-pink);
  color: var(--white);
  transform: translateY(-2px);
}
.btn-outline {
  background: transparent;
  color: var(--deep-rose);
  border: 2px solid var(--berry-pink);
}
.btn-outline:hover {
  background: var(--berry-pink);
  color: var(--white);
  transform: translateY(-2px);
}
.btn-ghost {
  background: transparent;
  color: var(--muted-text);
}
.btn-ghost:hover {
  background: var(--light-pink);
  color: var(--deep-rose);
}
.btn-white {
  background: var(--white);
  color: var(--deep-rose);
  box-shadow: var(--shadow-sm);
}
.btn-white:hover {
  background: var(--light-pink);
  transform: translateY(-2px);
}

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: capitalize;
}
.badge-berry {
  background: var(--light-pink);
  color: var(--berry-pink);
  border: 1px solid var(--candy-pink);
}
.badge-gold {
  background: #FEF3C7;
  color: #B45309;
  border: 1px solid #FDE68A;
}
.badge-success {
  background: #D1FAE5;
  color: #065F46;
}
.badge-warning {
  background: #FEF3C7;
  color: #92400E;
}
.badge-danger {
  background: #FEE2E2;
  color: #991B1B;
}

/* Section Header Component */
.section-header {
  margin-bottom: 48px;
}
.section-tag {
  display: inline-block;
  padding: 6px 14px;
  background: var(--light-pink);
  color: var(--berry-pink);
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-radius: var(--radius-full);
  margin-bottom: 12px;
  border: 1px solid var(--candy-pink);
}
.section-title {
  font-size: 2.4rem;
  margin-bottom: 14px;
  position: relative;
}
.section-title span {
  color: var(--berry-pink);
}
.section-desc {
  max-width: 600px;
  margin: 0 auto;
  font-size: 1rem;
}

/* Product Card Component */
.product-card {
  background: var(--white);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-pink);
  transition: var(--transition-normal);
  display: flex;
  flex-direction: column;
  position: relative;
}
.product-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
  border-color: var(--candy-pink);
}
.product-image-wrap {
  position: relative;
  width: 100%;
  padding-top: 75%; /* 4:3 Aspect Ratio */
  overflow: hidden;
  background: var(--light-pink);
}
.product-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.product-card:hover .product-img {
  transform: scale(1.08);
}
.product-badge-float {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
}
.product-quick-view {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  opacity: 0;
  transform: scale(0.8);
  transition: var(--transition-fast);
}
.product-card:hover .product-quick-view {
  opacity: 1;
  transform: scale(1);
}
.product-content {
  padding: 18px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}
.product-category-name {
  font-size: 0.75rem;
  color: var(--berry-pink);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
}
.product-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--dark-text);
  margin-bottom: 6px;
  line-height: 1.3;
}
.product-title a:hover {
  color: var(--berry-pink);
}
.product-desc {
  font-size: 0.85rem;
  color: var(--muted-text);
  line-height: 1.5;
  margin-bottom: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.product-footer {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 12px;
  border-top: 1px dashed var(--border-pink);
}
.product-price {
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--deep-rose);
}
.product-price small {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--muted-text);
}

/* Product Grid */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 24px;
}

/* Category Pills / Filter */
.category-filter-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 8px;
  margin-bottom: 32px;
  scrollbar-width: thin;
}
.category-pill {
  padding: 10px 20px;
  border-radius: var(--radius-full);
  background: var(--white);
  border: 1px solid var(--border-pink);
  color: var(--dark-text);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  transition: var(--transition-fast);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.category-pill:hover, .category-pill.active {
  background: var(--berry-pink);
  color: var(--white);
  border-color: var(--berry-pink);
  box-shadow: 0 4px 12px rgba(232, 62, 131, 0.25);
}

/* Modals */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(68, 42, 53, 0.6);
  backdrop-filter: blur(4px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-normal);
}
.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}
.modal-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  max-width: 600px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  position: relative;
  transform: translateY(20px) scale(0.95);
  transition: transform var(--transition-normal);
  border: 1px solid var(--border-pink);
}
.modal-overlay.active .modal-card {
  transform: translateY(0) scale(1);
}
.modal-header {
  padding: 20px 24px;
  border-bottom: 1px solid var(--border-pink);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.modal-title {
  font-size: 1.3rem;
  font-family: 'Playfair Display', serif;
  color: var(--deep-rose);
}
.modal-close {
  background: var(--light-pink);
  border-radius: var(--radius-full);
  width: 36px;
  height: 36px;
  color: var(--deep-rose);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.2rem;
  transition: var(--transition-fast);
}
.modal-close:hover {
  background: var(--candy-pink);
  color: var(--white);
}
.modal-body {
  padding: 24px;
}
.modal-footer {
  padding: 16px 24px;
  border-top: 1px solid var(--border-pink);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  background: var(--cream-white);
}

/* Toast Notifications */
#toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 3000;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}
.toast-msg {
  pointer-events: auto;
  background: var(--white);
  border-left: 4px solid var(--berry-pink);
  padding: 14px 20px;
  border-radius: var(--radius-sm);
  box-shadow: 0 10px 25px rgba(68, 42, 53, 0.15);
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 280px;
  max-width: 380px;
  font-size: 0.9rem;
  transform: translateX(100%);
  animation: slideInToast 0.3s forwards ease;
  border-top: 1px solid var(--border-pink);
  border-right: 1px solid var(--border-pink);
  border-bottom: 1px solid var(--border-pink);
}
.toast-msg.toast-success { border-left-color: var(--success); }
.toast-msg.toast-warning { border-left-color: var(--warning); }
.toast-msg.toast-danger { border-left-color: var(--danger); }
.toast-msg.toast-info { border-left-color: var(--info); }
.toast-msg.slide-out { animation: slideOutToast 0.3s forwards ease; }

@keyframes slideInToast {
  to { transform: translateX(0); }
}
@keyframes slideOutToast {
  to { transform: translateX(120%); }
}

/* Footer */
.footer {
  background: var(--deep-rose);
  color: var(--light-pink);
  padding: 70px 0 30px;
  position: relative;
  overflow: hidden;
}
.footer::before {
  content: '🍓';
  position: absolute;
  top: 20px;
  right: 40px;
  font-size: 6rem;
  opacity: 0.05;
  pointer-events: none;
}
.footer h4 {
  color: var(--white);
  font-size: 1.25rem;
  margin-bottom: 20px;
  font-family: 'Playfair Display', serif;
}
.footer p {
  color: var(--light-pink);
  font-size: 0.9rem;
  margin-bottom: 14px;
}
.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.footer-links a {
  color: var(--light-pink);
  font-size: 0.9rem;
}
.footer-links a:hover {
  color: var(--white);
  padding-left: 6px;
}
.footer-bottom {
  margin-top: 50px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.85rem;
  flex-wrap: wrap;
  gap: 16px;
}
