/* Mr. Knafah 100% UI Clone Enhancement Styles */

/* Hide WordPress Admin Bar entirely and remove margin offsets */
#wpadminbar {
  display: none !important;
  visibility: hidden !important;
  height: 0 !important;
  min-height: 0 !important;
  max-height: 0 !important;
  pointer-events: none !important;
  overflow: hidden !important;
  opacity: 0 !important;
  z-index: -99999 !important;
}

html, body {
  margin-top: 0px !important;
  padding-top: 0px !important;
}

* html body {
  margin-top: 0px !important;
}

@media screen and (max-width: 782px) {
  html, body {
    margin-top: 0px !important;
    padding-top: 0px !important;
  }
}

/* Ensure video background fills container cleanly */
.et_pb_section_video_bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 0;
  pointer-events: none;
}

.et_pb_section_video_bg video {
  min-width: 100%;
  min-height: 100%;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Toast Notification for Add to Cart */
#mr-knafah-toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #1c1c1c;
  color: #ffffff;
  padding: 16px 24px;
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
  display: flex;
  align-items: center;
  gap: 16px;
  z-index: 1000000;
  font-family: 'Poppins', 'Open Sans', sans-serif;
  font-size: 14px;
  transform: translateY(120%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  border-left: 4px solid #6b1317;
}

#mr-knafah-toast.show {
  transform: translateY(0);
}

#mr-knafah-toast .view-cart-btn {
  background: #6b1317;
  color: #fff;
  padding: 6px 14px;
  border-radius: 4px;
  text-decoration: none;
  font-weight: 600;
  font-size: 13px;
  transition: background 0.2s;
}

#mr-knafah-toast .view-cart-btn:hover {
  background: #8b181e;
}

/* Order Confirmation Modal */
#order-confirmation-modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  padding: 20px;
  font-family: 'Poppins', 'Open Sans', sans-serif;
}

#order-confirmation-modal.show {
  opacity: 1;
  pointer-events: auto;
}

#order-confirmation-modal .modal-content {
  background: #ffffff;
  border-radius: 12px;
  max-width: 550px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
  transform: scale(0.92);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  padding: 32px;
  position: relative;
}

#order-confirmation-modal.show .modal-content {
  transform: scale(1);
}

/* Contact form alert */
.mr-knafah-alert {
  padding: 14px 20px;
  border-radius: 6px;
  margin-top: 15px;
  font-size: 14px;
  line-height: 1.5;
}

.mr-knafah-alert-success {
  background: #e8f5e9;
  color: #2e7d32;
  border: 1px solid #c8e6c9;
}

/* Empty Cart View in Divi Style */
.cart-empty.woocommerce-info {
  display: block !important;
  background: #fbf9f6 !important;
  border: 1px solid #e6d9cc !important;
  border-left: 4px solid #6b1317 !important;
  padding: 28px 24px !important;
  font-size: 20px;
  font-weight: 600;
  text-align: center;
  color: #6b1317 !important;
  opacity: 1 !important;
  visibility: visible !important;
  margin-bottom: 25px;
  border-radius: 4px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.cart-empty.woocommerce-info::before {
  display: none !important;
}

.return-to-shop a.button.et_pb_button {
  display: inline-block;
  background: #6b1317;
  color: #ffffff !important;
  border: 2px solid #6b1317;
  border-radius: 4px;
  padding: 10px 24px;
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  text-decoration: none;
  transition: all 0.2s ease;
}

.return-to-shop a.button.et_pb_button:hover {
  background: #8b181e;
  border-color: #8b181e;
  color: #ffffff;
}

/* Open mobile menu always renders in front of every other row/section.
   Rows carry an inline z-index of 3, so a later row (e.g. the allergen menu row
   or page content) would otherwise paint over the dropdown of an earlier one. */
.et_pb_row--with-menu:has(.mobile_nav.opened) {
  z-index: 99999 !important;
}

.et_pb_row--with-menu .mobile_nav.opened .et_mobile_menu {
  z-index: 99999;
}

/* Live has no id-scoped copy of Divi's global rules, so the plain class rules win there. Locally the scoped
   `.et-db #et-boc .et-l h2` (line-height 1.2em) and `... select` (font stack) beat them; restore live's values. */
.et-db #et-boc .et-l .dnxt-headline {
  line-height: 1;
}

/* Live's select font stack (Divi's id-scoped copy is more specific locally). */
.et-db #et-boc .et-l div.product form.cart .variations td select {
  font-family: "Open Sans", Arial, sans-serif;
}
