:root {
  --bg-color: #FFFDF9; /* Ultra light cream */
  --bg-alt: #FFF6EC; /* Soft peach */
  --primary: #FF5A1F; /* Appetite orange */
  --primary-hover: #E04812;
  --text-main: #111827;
  --text-muted: #6B7280;
  --card-bg: #FFFFFF;
  
  --shadow-sm: 0 4px 6px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 10px 15px rgba(255, 90, 31, 0.05);
  --shadow-lg: 0 20px 40px rgba(255, 90, 31, 0.08);
  
  --radius-sm: 12px;
  --radius-md: 24px;
  --radius-lg: 32px;
  --radius-full: 999px;
  
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

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

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

ul {
  list-style: none;
}

.highlight {
  color: var(--primary);
}

/* Typography */
h1, h2, h3, h4 {
  font-weight: 700;
  line-height: 1.2;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 28px;
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: var(--transition);
  border: none;
}

.btn-primary {
  background-color: var(--primary);
  color: white;
  box-shadow: 0 4px 14px rgba(255, 90, 31, 0.3);
}

.btn-primary:hover {
  background-color: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 90, 31, 0.4);
}

.btn-lg {
  padding: 16px 36px;
  font-size: 1.125rem;
}

.btn-whatsapp {
  background-color: #25D366;
  color: white;
  box-shadow: 0 4px 14px rgba(37, 211, 102, 0.3);
  margin-top: 20px;
}
.btn-whatsapp:hover {
  background-color: #128C7E;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
}

/* Navbar */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 5%;
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 253, 249, 0.8);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(0,0,0,0.03);
}

.logo {
  font-size: 1.5rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-main);
}

.nav-links {
  display: flex;
  gap: 32px;
}

.nav-links a {
  font-weight: 500;
  color: var(--text-muted);
  transition: var(--transition);
}

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

/* Hero Section */
.hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 60px 5% 100px;
  min-height: 85vh;
  gap: 40px;
  position: relative;
}

.hero-content {
  flex: 1;
  max-width: 600px;
}

.badge {
  display: inline-block;
  padding: 8px 16px;
  background-color: var(--bg-alt);
  color: var(--primary);
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: 0.875rem;
  margin-bottom: 24px;
}

.hero-title {
  font-size: 4.5rem;
  margin-bottom: 24px;
  letter-spacing: -0.02em;
}

.hero-desc {
  font-size: 1.125rem;
  color: var(--text-muted);
  margin-bottom: 40px;
  max-width: 80%;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 32px;
}

.delivery-time {
  display: flex;
  align-items: center;
  gap: 12px;
}

.time-icon {
  font-size: 2rem;
  background: white;
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  box-shadow: var(--shadow-sm);
}

.delivery-time div {
  display: flex;
  flex-direction: column;
}

.delivery-time strong {
  font-size: 1rem;
  color: var(--text-main);
}

.delivery-time span {
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* Hero Visual */
.hero-visual {
  flex: 1;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.blob {
  position: absolute;
  width: 500px;
  height: 500px;
  background: var(--primary);
  opacity: 0.08;
  filter: blur(60px);
  border-radius: 50%;
  z-index: -1;
}

.hero-image {
  width: 100%;
  max-width: 500px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  transform: rotate(2deg);
  transition: var(--transition);
}

.hero-image:hover {
  transform: rotate(0deg) scale(1.02);
}

.floating-badge {
  position: absolute;
  background: white;
  padding: 12px 20px;
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-md);
  font-weight: 600;
  font-size: 0.9rem;
  animation: float 4s ease-in-out infinite;
}

.badge-1 {
  top: 10%;
  left: -5%;
}

.badge-2 {
  bottom: 10%;
  right: -5%;
  animation-delay: 2s;
}

@keyframes float {
  0% { transform: translateY(0px); }
  50% { transform: translateY(-15px); }
  100% { transform: translateY(0px); }
}

/* Categories */
.categories {
  padding: 40px 5%;
  text-align: center;
}

.section-subtitle {
  font-size: 1.5rem;
  margin-bottom: 24px;
  color: var(--text-main);
}

.category-list {
  display: flex;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}

.category-btn {
  padding: 12px 24px;
  background: white;
  border: 1px solid rgba(0,0,0,0.05);
  border-radius: var(--radius-full);
  font-family: inherit;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
  font-size: 1rem;
}

.category-btn:hover, .category-btn.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(255, 90, 31, 0.2);
}

/* Menu Section */
.menu-section {
  padding: 60px 5%;
  background-color: var(--bg-alt);
}

.menu-header {
  text-align: center;
  margin-bottom: 50px;
}

.section-title {
  font-size: 2.5rem;
  margin-bottom: 12px;
}

.section-desc {
  color: var(--text-muted);
  font-size: 1.125rem;
}

.menu-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

/* Menu Card */
.menu-card {
  background: var(--card-bg);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  position: relative;
  display: flex;
  flex-direction: column;
}

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

.card-img-wrapper {
  width: 100%;
  height: 200px;
  overflow: hidden;
  background: #f3f4f6;
  position: relative;
  flex-shrink: 0;
  display: block;
}

.card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.menu-card:hover .card-img {
  transform: scale(1.08);
}

.card-price-badge {
  position: absolute;
  top: 16px;
  right: 16px;
  background: var(--card-bg);
  color: var(--primary);
  font-weight: 700;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-sm);
}

.card-content {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.card-title {
  font-size: 1.25rem;
  margin-bottom: 8px;
}

.card-desc {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 16px;
  flex: 1;
}

/* Ingredient Expand/Collapse Component */
.card-ingredients-wrap {
  min-height: 28px; /* consistent card height even when no ingredients */
  margin-bottom: 10px;
}

.card-ingredients-visible {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.card-ingredients-extra {
  display: none;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
  animation: fadeIn 0.2s ease;
}

.card-ingredients-wrap.expanded .card-ingredients-extra {
  display: flex;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-4px); }
  to   { opacity: 1; transform: translateY(0); }
}

.ingredient-pill {
  display: inline-block;
  padding: 3px 10px;
  background: var(--bg-alt);
  color: var(--text-muted);
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 500;
  white-space: nowrap;
}

.ingredient-expand-btn {
  background: none;
  border: none;
  color: var(--primary);
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
  padding: 3px 6px;
  border-radius: var(--radius-full);
  transition: background 0.2s;
}

.ingredient-expand-btn:hover {
  background: var(--bg-alt);
}

.card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.card-add-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg-alt);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  border: none;
  cursor: pointer;
  transition: var(--transition);
}

.card-add-btn:hover {
  background: var(--primary);
  color: white;
}

/* Location CTA */
.location-cta {
  padding: 80px 5%;
}

.location-card {
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  display: flex;
  overflow: hidden;
  min-height: 400px;
}

.location-info {
  flex: 1;
  padding: 60px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.location-info h2 {
  font-size: 2.5rem;
  margin-bottom: 24px;
}

.location-info p {
  font-size: 1.1rem;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.location-map {
  flex: 1;
  background: #E5E7EB;
  position: relative;
}

.map-placeholder {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url('https://images.unsplash.com/photo-1524661135-423995f22d0b?ixlib=rb-4.0.3&auto=format&fit=crop&w=1000&q=80');
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
}

.map-placeholder span {
  background: white;
  padding: 12px 24px;
  border-radius: var(--radius-full);
  font-weight: 600;
  box-shadow: var(--shadow-md);
}

/* Footer */
footer {
  background: white;
  padding: 40px 5%;
  text-align: center;
  color: var(--text-muted);
  border-top: 1px solid rgba(0,0,0,0.05);
}

footer p {
  margin-bottom: 8px;
}

/* Responsive */
@media (max-width: 992px) {
  .hero {
    flex-direction: column;
    text-align: center;
    padding-top: 40px;
  }
  .hero-content {
    max-width: 100%;
  }
  .hero-desc {
    margin: 0 auto 40px;
  }
  .hero-actions {
    justify-content: center;
  }
  .location-card {
    flex-direction: column;
  }
  .location-map {
    min-height: 300px;
  }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
  }
  .hero-title {
    font-size: 3rem;
  }
  .hero-actions {
    flex-direction: column;
  }
  /* On mobile, modal grid should be single column */
  .menu-grid.modal-grid {
    grid-template-columns: 1fr !important;
    gap: 16px;
    padding: 16px;
  }
  /* On mobile, main page menu is also single column */
  .menu-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

/* Modal Styles */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(17, 24, 39, 0.4);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 1000;
  display: flex;
  justify-content: center;
  align-items: flex-end; /* bottom sheet on mobile */
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-content {
  background: var(--bg-color);
  width: 100%;
  max-width: 1200px;
  height: 92vh;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: translateY(30px);
  transition: transform 0.3s ease;
}

@media (min-width: 769px) {
  .modal-overlay {
    align-items: center;
  }
  .modal-content {
    width: 90%;
    height: auto;
    max-height: 90vh;
    border-radius: var(--radius-lg);
  }
}

.modal-overlay.active .modal-content {
  transform: translateY(0);
}

.modal-header {
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid rgba(0,0,0,0.05);
  flex-shrink: 0;
}

.close-btn {
  background: none;
  border: none;
  font-size: 2rem;
  color: var(--text-muted);
  cursor: pointer;
  transition: color 0.2s ease;
  line-height: 1;
  padding: 4px 8px;
}

.close-btn:hover {
  color: var(--primary);
}

.modal-filters {
  padding: 16px 20px;
  display: flex;
  gap: 12px;
  background: var(--card-bg);
  border-bottom: 1px solid rgba(0,0,0,0.05);
  flex-wrap: wrap;
  flex-shrink: 0;
}

@media (min-width: 769px) {
  .modal-header {
    padding: 30px 40px;
  }
  .modal-filters {
    padding: 20px 40px;
    gap: 20px;
  }
}

.search-input {
  flex: 1;
  min-width: 200px;
  padding: 12px 20px;
  border-radius: var(--radius-full);
  border: 1px solid rgba(0,0,0,0.1);
  font-size: 1rem;
  outline: none;
  font-family: inherit;
  transition: var(--transition);
}

.search-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(255, 90, 31, 0.1);
}

.category-select {
  padding: 12px 40px 12px 20px; /* Added right padding for chevron */
  border-radius: var(--radius-full);
  border: 1px solid rgba(0,0,0,0.1);
  font-size: 1rem;
  font-family: inherit;
  outline: none;
  cursor: pointer;
  background: white;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2224%22%20height%3D%2224%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22currentColor%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%3E%3Cpolyline%20points%3D%226%209%2012%2015%2018%209%22%3E%3C%2Fpolyline%3E%3C%2Fsvg%3E");
  background-repeat: no-repeat;
  background-position: right 15px center;
  background-size: 16px;
}

.modal-grid {
  padding: 16px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  flex: 1;
  min-height: 0;
  /* Override grid to use a single column of horizontal cards */
  display: flex !important;
  flex-direction: column;
  gap: 12px;
}

/* Horizontal card layout inside the modal */
.modal-grid .menu-card {
  flex-direction: row;
  align-items: stretch; /* card-content fills full card height */
  border-radius: var(--radius-md);
  min-height: 154px;
  max-height: 154px; /* collapsed: fixed height */
  overflow: hidden;
  transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

/* When expanded, card grows pushing others down */
.modal-grid .menu-card.ingredients-expanded {
  max-height: 400px;
}

.modal-grid .card-img-wrapper {
  width: 120px;
  min-width: 120px;
  height: 154px;
  min-height: 154px;
  border-radius: var(--radius-md) 0 0 var(--radius-md);
  flex-shrink: 0;
  align-self: flex-start; /* image stays at top, doesn't stretch */
}

.modal-grid .card-price-badge {
  display: none;
}

.modal-grid .card-content {
  flex: 1;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start; /* Bulletproof stacking */
  overflow: visible;
  min-width: 0;
}

.modal-grid .card-title {
  font-size: 0.95rem;
  margin: 0 0 6px 0; /* Reset browser margin-top */
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex-shrink: 0;
}

.modal-grid .card-desc {
  display: none;
}

.modal-grid .card-ingredients-wrap {
  margin-bottom: 0;
  flex: 1; /* fill remaining space to push footer down */
}

.modal-grid .card-ingredients-visible {
  flex-wrap: wrap;    /* allow pills to wrap when expanded */
}

.modal-grid .card-ingredients-extra {
  flex-wrap: wrap;
}

.modal-grid .card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: auto; /* Space automatically to pin to bottom */
  padding-right: 6px;
  flex-shrink: 0; /* Footer must never shrink */
}

.modal-grid .card-footer-price {
  font-weight: 700;
  color: var(--primary);
  font-size: 0.95rem;
}

/* Smaller + button with margin from edge */
.modal-grid .card-add-btn {
  width: 26px; /* slightly bigger than 22px so it's clickable */
  height: 26px;
  font-size: 1rem;
  flex-shrink: 0;
  background: var(--primary);
  color: white;
  margin-right: 4px;
}

.modal-grid .card-add-btn:hover {
  background: var(--primary-hover);
}

/* On tablet/desktop, 2-col grid of horizontal cards */
@media (min-width: 769px) {
  .modal-grid {
    padding: 30px 40px;
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    align-content: start;
    gap: 16px;
  }
  .modal-grid .menu-card {
    min-height: 154px;
    max-height: 154px;
  }
  .modal-grid .menu-card.ingredients-expanded {
    max-height: 400px;
  }
  .modal-grid .card-img-wrapper {
    width: 120px;
    min-width: 120px;
    height: 154px;
    min-height: 154px;
  }
}

/* Out of Stock State */
.menu-card.out-of-stock {
  opacity: 0.6;
  filter: grayscale(80%);
}

.menu-card.out-of-stock:hover {
  transform: none;
  box-shadow: var(--shadow-sm);
}

.out-of-stock-badge {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(0,0,0,0.8);
  color: white;
  padding: 10px 20px;
  border-radius: var(--radius-full);
  font-weight: 700;
  z-index: 10;
  font-size: 1.1rem;
  white-space: nowrap;
}

.menu-card.out-of-stock .card-add-btn {
  background: #E5E7EB;
  color: #9CA3AF;
  cursor: not-allowed;
}

.menu-card.out-of-stock a {
  pointer-events: none;
}

/* Shopping Cart Styles */
.floating-cart-btn {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 50px;
  padding: 15px 25px;
  font-size: 1.5rem;
  box-shadow: 0 10px 25px rgba(255, 90, 31, 0.4);
  cursor: pointer;
  z-index: 2000;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.floating-cart-btn:hover {
  transform: translateY(-5px) scale(1.05);
  box-shadow: 0 15px 30px rgba(255, 90, 31, 0.5);
}

.cart-count {
  background: white;
  color: var(--primary);
  font-size: 1rem;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 20px;
}

.cart-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(17, 24, 39, 0.4);
  backdrop-filter: blur(4px);
  z-index: 1001;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.cart-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.cart-sidebar {
  position: fixed;
  top: 0;
  right: -400px;
  width: 100%;
  max-width: 400px;
  height: 100vh;
  background: var(--bg-color);
  z-index: 1002;
  box-shadow: -10px 0 30px rgba(0,0,0,0.1);
  display: flex;
  flex-direction: column;
  transition: right 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.cart-sidebar.active {
  right: 0;
}

.cart-header {
  padding: 25px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid rgba(0,0,0,0.05);
}

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

.empty-cart-msg {
  text-align: center;
  color: var(--text-muted);
  margin-top: 50px;
}

.cart-item {
  display: flex;
  align-items: center;
  gap: 15px;
  background: var(--card-bg);
  padding: 15px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

.cart-item-img {
  width: 60px;
  height: 60px;
  border-radius: var(--radius-sm);
  object-fit: cover;
}

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

.cart-item-title {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 5px;
}

.cart-item-price {
  color: var(--primary);
  font-weight: 600;
  font-size: 0.9rem;
}

.cart-item-controls {
  display: flex;
  align-items: center;
  gap: 10px;
}

.cart-btn-qty {
  background: rgba(0,0,0,0.05);
  border: none;
  width: 25px;
  height: 25px;
  border-radius: 5px;
  cursor: pointer;
  font-weight: bold;
  transition: background 0.2s;
}

.cart-btn-qty:hover {
  background: rgba(0,0,0,0.1);
}

.cart-footer {
  padding: 25px;
  border-top: 1px solid rgba(0,0,0,0.05);
  background: var(--card-bg);
}

.cart-total-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 20px;
}


/* WhatsApp CTA Button Specifics */
.whatsapp-cta-btn {
  width: 100%;
  text-align: center;
}

@media (min-width: 769px) {
  .whatsapp-cta-btn {
    width: 50%;
  }
}



/* Modal Text Ingredients Styles */
.ingredient-text-container {
  margin: 0;
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.4;
}

.ingredient-text-extra {
  display: none;
}

.card-ingredients-wrap.expanded .ingredient-text-extra {
  display: inline;
}

.text-mode-btn {
  display: inline-block;
  margin-left: 4px;
}

/* WhatsApp Simulator Modal CSS */
.wa-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.6); z-index: 2000; display: none; backdrop-filter: blur(5px); }
.wa-overlay.active { display: block; }

.wa-modal { position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%) scale(0.95); width: 100%; max-width: 400px; height: 85vh; max-height: 700px; background: #efeae2; z-index: 2001; border-radius: 20px; overflow: hidden; display: flex; flex-direction: column; opacity: 0; pointer-events: none; transition: 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275); box-shadow: 0 25px 50px -12px rgba(0,0,0,0.5); }
.wa-modal.active { transform: translate(-50%, -50%) scale(1); opacity: 1; pointer-events: auto; }

/* WhatsApp background pattern simulation */
.wa-modal::before { content: ""; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background-image: url('data:image/svg+xml;utf8,<svg width="60" height="60" viewBox="0 0 60 60" xmlns="http://www.w3.org/2000/svg"><g fill="none" fill-rule="evenodd"><g fill="%23d6d0c4" fill-opacity="0.4"><path d="M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z"/></g></g></svg>'); opacity: 0.6; z-index: 0; pointer-events: none; }

.wa-header { position: relative; background: #008069; color: white; padding: 12px 15px; display: flex; align-items: center; justify-content: space-between; z-index: 1; box-shadow: 0 1px 3px rgba(0,0,0,0.1); }
.wa-header-left { display: flex; align-items: center; gap: 12px; }
.wa-back-btn { background: none; border: none; color: white; font-size: 1.5rem; cursor: pointer; padding: 0; display: flex; align-items: center; }
.wa-avatar { width: 40px; height: 40px; background: #ccc; border-radius: 50%; display: flex; justify-content: center; align-items: center; font-weight: bold; color: #333; overflow: hidden; }
.wa-avatar img { width: 100%; height: 100%; object-fit: cover; }
.wa-info { display: flex; flex-direction: column; }
.wa-name { font-weight: 600; font-size: 1.05rem; }
.wa-status { font-size: 0.8rem; opacity: 0.8; }

.wa-chat-window { position: relative; flex: 1; padding: 20px 15px; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; z-index: 1; scroll-behavior: smooth; }
.wa-date { align-self: center; background: #e1f3fb; color: #55626a; font-size: 0.75rem; padding: 5px 12px; border-radius: 10px; font-weight: 500; margin-bottom: 10px; box-shadow: 0 1px 1px rgba(0,0,0,0.05); }
.wa-encryption { align-self: center; background: #ffeecd; color: #54442b; font-size: 0.75rem; padding: 6px 12px; border-radius: 8px; text-align: center; max-width: 90%; margin-bottom: 15px; box-shadow: 0 1px 1px rgba(0,0,0,0.05); }

.wa-msg { max-width: 85%; padding: 8px 12px; border-radius: 10px; font-size: 0.95rem; line-height: 1.4; position: relative; box-shadow: 0 1px 1px rgba(0,0,0,0.1); word-wrap: break-word; animation: popIn 0.3s ease-out forwards; transform-origin: bottom; }
@keyframes popIn { from { opacity: 0; transform: scale(0.9); } to { opacity: 1; transform: scale(1); } }

.wa-msg-bot { align-self: flex-start; background: #fff; color: #111b21; border-top-left-radius: 0; }
.wa-msg-bot::before { content: ""; position: absolute; top: 0; left: -8px; width: 0; height: 0; border-top: 10px solid #fff; border-left: 10px solid transparent; }

.wa-msg-user { align-self: flex-end; background: #dcf8c6; color: #111b21; border-top-right-radius: 0; }
.wa-msg-user::before { content: ""; position: absolute; top: 0; right: -8px; width: 0; height: 0; border-top: 10px solid #dcf8c6; border-right: 10px solid transparent; }

.wa-time { font-size: 0.65rem; color: #667781; float: right; margin-top: 4px; margin-left: 10px; }
.wa-msg-user .wa-time { display: flex; align-items: center; gap: 3px; }
.wa-ticks { color: #53bdeb; font-size: 0.7rem; }

.wa-input-area { position: relative; background: #f0f2f5; padding: 10px 15px; display: flex; align-items: center; gap: 10px; z-index: 1; }
.wa-input { flex: 1; background: #fff; border: none; padding: 12px 20px; border-radius: 24px; font-size: 0.95rem; outline: none; box-shadow: 0 1px 1px rgba(0,0,0,0.05); }
.wa-send-btn { background: #00a884; color: white; border: none; width: 44px; height: 44px; border-radius: 50%; display: flex; justify-content: center; align-items: center; cursor: pointer; transition: 0.2s; box-shadow: 0 1px 3px rgba(0,0,0,0.15); }
.wa-send-btn:hover { background: #008f6f; transform: scale(1.05); }
.wa-send-btn:active { transform: scale(0.95); }

/* Dark mode adjustments for WA Simulator if body is dark */
body.dark-mode .wa-modal { background: #0b141a; }
body.dark-mode .wa-header { background: #202c33; }
body.dark-mode .wa-input-area { background: #202c33; }
body.dark-mode .wa-input { background: #2a3942; color: #e9edef; }
body.dark-mode .wa-input::placeholder { color: #8696a0; }
body.dark-mode .wa-msg-bot { background: #202c33; color: #e9edef; }
body.dark-mode .wa-msg-bot::before { border-top-color: #202c33; }
body.dark-mode .wa-msg-user { background: #005c4b; color: #e9edef; }
body.dark-mode .wa-msg-user::before { border-top-color: #005c4b; }
body.dark-mode .wa-date { background: #182229; color: #8696a0; }
body.dark-mode .wa-encryption { background: #182229; color: #ffd279; }
body.dark-mode .wa-time { color: #8696a0; }
.location-map { min-height: 400px !important; }
