/* Cart Icon Styles */
.cart-icon {
  position: relative;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 35px;
  height: 35px;
  background: #978667;
  color: white;
  border-radius: 50%;
  transition: all 0.3s ease;
}

.cart-icon:hover {
  background: #7c6d50;
  transform: scale(1.1);
}

.cart-badge {
  position: absolute;
  top: -8px;
  right: -8px;
  background: #333;
  color: white;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: bold;
}

/* Add to Cart Button */
.add-to-cart-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 40px;
  height: 40px;
  background: rgba(151, 134, 103, 0.95);
  color: white;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  transition: all 0.3s ease;
  opacity: 0;
  z-index: 10;
}

.item:hover .add-to-cart-btn {
  opacity: 1;
}

.add-to-cart-btn:hover {
  background: #7c6d50;
  transform: scale(1.1);
}

.add-to-cart-btn.added {
  background: #7c6d50;
}

/* Tooltip */
.tooltip-cart {
  position: absolute;
  background: #333;
  color: white;
  padding: 5px 10px;
  border-radius: 4px;
  font-size: 12px;
  white-space: nowrap;
  top: -35px;
  left: 50%;
  transform: translateX(-50%);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.tooltip-cart::after {
  content: "";
  position: absolute;
  bottom: -5px;
  left: 50%;
  transform: translateX(-50%);
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 5px solid #333;
}

.add-to-cart-btn:hover .tooltip-cart {
  opacity: 1;
}

/* Cart Popup */
.cart-popup {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 380px;
  max-height: 500px;
  background: white;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
  border-radius: 10px;
  z-index: 9999;
  transform: translateY(600px);
  transition: transform 0.3s ease;
}

.cart-popup.show {
  transform: translateY(0);
}

.cart-header {
  background: #978667;
  color: white;
  padding: 15px 20px;
  border-radius: 10px 10px 0 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.cart-header h3 {
  margin: 0;
  font-size: 18px;
}

.close-cart {
  background: none;
  border: none;
  color: white;
  font-size: 24px;
  cursor: pointer;
  padding: 0;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cart-items {
  max-height: 300px;
  overflow-y: auto;
  padding: 15px;
}

.cart-item {
  display: flex;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid #eee;
}

.cart-item:last-child {
  border-bottom: none;
}

.cart-item-image {
  width: 60px;
  height: 60px;
  object-fit: cover;
  border-radius: 5px;
}

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

.cart-item-name {
  font-weight: 600;
  font-size: 14px;
  margin-bottom: 5px;
}

.cart-item-price {
  color: #978667;
  font-weight: 500;
  font-size: 13px;
}

.cart-item-remove {
  background: none;
  border: none;
  color: #999;
  cursor: pointer;
  font-size: 18px;
  padding: 0 10px;
}

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

.cart-empty {
  text-align: center;
  padding: 40px 20px;
  color: #999;
}

.cart-footer {
  padding: 15px 20px;
  border-top: 2px solid #eee;
}

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

.checkout-btn {
  width: 100%;
  background: #978667;
  color: white;
  border: none;
  padding: 12px;
  border-radius: 5px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.3s ease;
}

.checkout-btn:hover {
  background: #7c6d50;
}

/* Item position relative for absolute button */
.item {
  position: relative;
}

/* Mobile responsive */
@media (max-width: 768px) {
  .cart-popup {
    width: calc(100% - 40px);
    right: 20px;
  }
}

/* Quantity Popup Styles */
.quantity-popup {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  z-index: 1000;
  justify-content: center;
  align-items: center;
}

.quantity-popup.show {
  display: flex;
}

.quantity-popup-content {
  background: white;
  padding: 30px;
  border-radius: 10px;
  width: 90%;
  max-width: 400px;
  position: relative;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.close-popup {
  position: absolute;
  top: 15px;
  right: 20px;
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: #666;
}

.close-popup:hover {
  color: #333;
}

.quantity-popup h3 {
  margin-bottom: 20px;
  text-align: center;
  color: #333;
}

.product-info {
  display: flex;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 15px;
  border-bottom: 1px solid #eee;
}

.popup-image {
  width: 60px;
  height: 60px;
  object-fit: cover;
  border-radius: 8px;
  margin-right: 15px;
}

.product-details h4 {
  margin: 0 0 5px 0;
  color: #333;
}

.price-display {
  color: #666;
  font-weight: bold;
}

.quantity-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 25px 0;
  gap: 10px;
}

.quantity-btn {
  width: 40px;
  height: 40px;
  border: 1px solid #ddd;
  background: #f8f8f8;
  border-radius: 5px;
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.quantity-btn:hover {
  background: #e8e8e8;
}

.quantity-input {
  width: 80px;
  height: 40px;
  text-align: center;
  border: 1px solid #ddd;
  border-radius: 5px;
  font-size: 16px;
  font-weight: bold;
}

.quantity-unit {
  margin-left: 5px;
  font-weight: bold;
  color: #666;
}

.total-price {
  text-align: center;
  font-size: 18px;
  font-weight: bold;
  margin: 20px 0;
  color: #333;
}

.confirm-btn {
  width: 100%;
  padding: 15px;
  background: #978667;
  color: white;
  border: none;
  border-radius: 5px;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  transition: background 0.3s;
}

.confirm-btn:hover {
  background: #7c6d50;
}

.confirm-btn:disabled {
  background: #ccc;
  cursor: not-allowed;
}

/* ─────────────────────────────────────────────────────────────────────────
   Brand-align Bootstrap semantic utilities to the site's taupe theme.
   The modals (customer_form.js, confirm/checkout pages) use Bootstrap's
   `success` (green) and `primary` (blue) helpers, which clash with the
   #978667 brand. Remap those to the brand; leave `danger` (red) and
   `secondary` (grey) alone — they carry meaningful error/neutral semantics.
   ───────────────────────────────────────────────────────────────────────── */
.bg-success { background-color: #978667 !important; }
.text-success { color: #978667 !important; }
.btn-success {
  background-color: #978667 !important;
  border-color: #978667 !important;
}
.btn-success:hover,
.btn-success:focus {
  background-color: #7c6d50 !important;
  border-color: #7c6d50 !important;
}

.bg-primary { background-color: #978667 !important; }
.text-primary { color: #978667 !important; }
.btn-primary {
  background-color: #978667 !important;
  border-color: #978667 !important;
}
.btn-primary:hover,
.btn-primary:focus {
  background-color: #7c6d50 !important;
  border-color: #7c6d50 !important;
}

/* ─────────────────────────────────────────────────────────────────────────
   Remove focus rings / outlines on all interactive controls.
   The visible "ring" is the box-shadow glow from Bootstrap and the theme
   (e.g. .form-control:focus in style.css, .accordion-button/.btn in
   Bootstrap). This strips the outline + focus box-shadow on buttons, form
   fields, selects, checkboxes/radios, collapsibles/accordions, tabs and
   links, while leaving hover/active colour changes intact.
   ───────────────────────────────────────────────────────────────────────── */
button:focus,
button:focus-visible,
.btn:focus,
.btn:focus-visible,
.btn-check:focus + .btn,
[class*="btn_"]:focus,
[class*="btn_"]:focus-visible,
a:focus,
a:focus-visible,
input:focus,
input:focus-visible,
select:focus,
select:focus-visible,
textarea:focus,
textarea:focus-visible,
.form-control:focus,
.form-select:focus,
.form-check-input:focus,
.accordion-button:focus,
.accordion-button:not(.collapsed),
.nav-link:focus,
.nav-tabs .nav-link:focus,
.page-link:focus,
[data-bs-toggle]:focus,
[contenteditable]:focus,
summary:focus {
  outline: none !important;
  box-shadow: none !important;
}

/* ─────────────────────────────────────────────────────────────────────────
   Cookie consent (js/cookie-consent.js) — brand-themed (#978667).
   ───────────────────────────────────────────────────────────────────────── */
.mlati-cc-banner {
  position: fixed;
  left: 20px;
  right: 20px;
  bottom: 20px;
  z-index: 10000;
  background: #fff;
  color: #333;
  border-radius: 12px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.25);
  padding: 18px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  border-top: 4px solid #978667;
}
.mlati-cc-text { flex: 1 1 320px; min-width: 260px; }
.mlati-cc-text strong { display: block; font-size: 15px; margin-bottom: 4px; color: #262626; }
.mlati-cc-text p { margin: 0; font-size: 13px; line-height: 1.5; color: #666; }
.mlati-cc-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }

.mlati-cc-btn {
  border: 1px solid #978667;
  border-radius: 6px;
  padding: 9px 16px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  line-height: 1;
}
.mlati-cc-btn.solid { background: #978667; color: #fff; }
.mlati-cc-btn.solid:hover { background: #7c6d50; border-color: #7c6d50; }
.mlati-cc-btn.ghost { background: transparent; color: #7c6d50; }
.mlati-cc-btn.ghost:hover { background: #f4f1ec; }

/* Preferences modal */
.mlati-cc-modal {
  position: fixed;
  inset: 0;
  z-index: 10001;
  background: rgba(0, 0, 0, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.mlati-cc-modal-card {
  background: #fff;
  border-radius: 12px;
  max-width: 520px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  padding: 26px;
  position: relative;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
}
.mlati-cc-modal-card h3 { margin: 0 0 16px; color: #262626; font-size: 20px; }
.mlati-cc-close {
  position: absolute; top: 14px; right: 16px;
  background: none; border: none; font-size: 26px; line-height: 1;
  cursor: pointer; color: #999;
}
.mlati-cc-close:hover { color: #333; }
.mlati-cc-row {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 16px;
  padding: 14px 0; border-bottom: 1px solid #eee;
}
.mlati-cc-row strong { display: block; font-size: 14px; color: #262626; }
.mlati-cc-row p { margin: 4px 0 0; font-size: 12.5px; color: #777; line-height: 1.45; }
.mlati-cc-modal-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 20px; }

/* Toggle switch */
.mlati-cc-switch { position: relative; display: inline-block; width: 44px; height: 24px; flex: 0 0 auto; margin-top: 2px; }
.mlati-cc-switch input { opacity: 0; width: 0; height: 0; }
.mlati-cc-switch::after {
  content: ""; position: absolute; inset: 0; border-radius: 24px;
  background: #ccc; transition: background 0.2s ease;
}
.mlati-cc-switch::before {
  content: ""; position: absolute; z-index: 1; height: 18px; width: 18px; left: 3px; top: 3px;
  background: #fff; border-radius: 50%; transition: transform 0.2s ease;
}
.mlati-cc-switch:has(input:checked)::after { background: #978667; }
.mlati-cc-switch:has(input:checked)::before { transform: translateX(20px); }
.mlati-cc-switch:has(input:disabled)::after { background: #978667; opacity: 0.55; }

@media (max-width: 600px) {
  .mlati-cc-banner { left: 10px; right: 10px; bottom: 10px; padding: 16px; }
  .mlati-cc-actions { width: 100%; }
  .mlati-cc-btn { flex: 1 1 auto; text-align: center; }
}

/* ─────────────────────────────────────────────────────────────────────────
   Form dialogs (js/become-customer-modal.js) — brand-themed (#978667).
   Replaces old dead links (reservations.html / leave-review.html).
   ───────────────────────────────────────────────────────────────────────── */
.mlati-modal {
  position: fixed;
  inset: 0;
  z-index: 10002;
  background: rgba(0, 0, 0, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.mlati-modal-card {
  background: #fff;
  border-radius: 12px;
  max-width: 480px;
  width: 100%;
  max-height: 88vh;
  overflow-y: auto;
  padding: 28px;
  position: relative;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
  border-top: 4px solid #978667;
}
.mlati-modal-card h3 { margin: 0 0 6px; color: #262626; font-size: 21px; }
.mlati-modal-sub { margin: 0 0 18px; font-size: 13.5px; color: #777; line-height: 1.5; }
.mlati-modal-close {
  position: absolute; top: 14px; right: 16px;
  background: none; border: none; font-size: 26px; line-height: 1;
  cursor: pointer; color: #999;
}
.mlati-modal-close:hover { color: #333; }
.mlati-field { margin-bottom: 14px; }
.mlati-field label { display: block; font-size: 12.5px; font-weight: 600; color: #555; margin-bottom: 5px; }
.mlati-field input,
.mlati-field select,
.mlati-field textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #d8d2c7;
  border-radius: 6px;
  font-size: 14px;
  font-family: inherit;
  color: #333;
  background: #fff;
}
.mlati-field input:focus,
.mlati-field select:focus,
.mlati-field textarea:focus { border-color: #978667; }
.mlati-modal-msg { min-height: 18px; font-size: 13px; margin: 4px 0 8px; }
.mlati-modal-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 10px; }
.mlati-modal-success { text-align: center; padding: 6px 0 4px; }
.mlati-modal-success h3 { color: #978667; }
.mlati-modal-success p { color: #666; font-size: 14px; margin: 8px 0; }
.mlati-modal-success a { color: #978667; font-weight: 600; }
.mlati-modal-success .mlati-cc-btn { margin-top: 12px; }

/* ─────────────────────────────────────────────────────────────────────────
   Address autocomplete dropdown (js/address-autocomplete.js) — brand-themed.
   ───────────────────────────────────────────────────────────────────────── */
.mlati-addr-dropdown {
  position: absolute;
  z-index: 10050;
  background: #fff;
  border: 1px solid #e2ddd3;
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.18);
  max-height: 260px;
  overflow-y: auto;
  font-size: 14px;
}
.mlati-addr-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  cursor: pointer;
  color: #333;
  border-bottom: 1px solid #f2efe9;
}
.mlati-addr-item:last-child { border-bottom: none; }
.mlati-addr-item:hover,
.mlati-addr-item.active { background: #f4f1ec; }
.mlati-addr-pin { font-style: normal; opacity: 0.7; }

/* ─────────────────────────────────────────────────────────────────────────
   Campaign / promo dialog (js/campaign-modal.js) — image on top, promo text,
   single CTA at the bottom. Reuses the .mlati-modal overlay + brand palette.
   Compact by design (max 400px): not too big, not too small.
   ───────────────────────────────────────────────────────────────────────── */
.mlati-campaign-card {
  max-width: 400px;
  padding: 0;            /* image sits flush to the card edges */
  overflow: hidden;
  animation: mlatiCampaignIn 0.28s ease-out;
}
@keyframes mlatiCampaignIn {
  from { opacity: 0; transform: translateY(14px) scale(0.98); }
  to   { opacity: 1; transform: none; }
}
.mlati-campaign-img {
  width: 100%;
  height: 200px;
  background-color: #f4f1ec;
  background-size: cover;
  background-position: center;
}
.mlati-campaign-body { padding: 22px 24px 24px; }
.mlati-campaign-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #978667;
  background: #f4f1ec;
  padding: 4px 11px;
  border-radius: 999px;
  margin-bottom: 12px;
}
.mlati-campaign-body h3 { margin: 0 0 8px; color: #262626; font-size: 20px; line-height: 1.25; }
.mlati-campaign-body p { margin: 0 0 20px; color: #666; font-size: 14px; line-height: 1.55; }
.mlati-campaign-cta {
  display: inline-block;
  text-decoration: none;
  padding: 11px 22px;
  font-size: 14px;
}
.mlati-campaign-cta:hover { text-decoration: none; color: #fff; }
/* Float the close control over the image so it stays visible on the photo. */
.mlati-campaign-card .mlati-modal-close {
  top: 12px;
  right: 12px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.92);
  color: #333;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}
.mlati-campaign-card .mlati-modal-close:hover { background: #fff; color: #000; }
