/* ==========================================================================
   Mobile Modal Menu – DentaFind
   Standalone mobile menu that replaces the old offcanvas/sliding-menu.
   Brand colour: #47c6f3
   ========================================================================== */

:root {
  --mmm-brand:        #47c6f3;
  --mmm-brand-hover:  #2fb8e8;
  --mmm-brand-light:  #e8f6fd;
  --mmm-brand-mid:    #b6e4f7;
  --mmm-navy:         #0d2b3e;
  --mmm-slate:        #4a6070;
  --mmm-white:        #ffffff;
  --mmm-bg:           #f7fbfd;
  --mmm-border:       #d6e8f0;
  --mmm-radius:       10px;
  --mmm-shadow:       0 4px 24px rgba(71,198,243,.12);
}

/* ── Mobile Header Bar ──────────────────────────────────── */
.mob-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--mmm-white);
  border-bottom: 1.5px solid var(--mmm-border);
  box-shadow: var(--mmm-shadow);
}
.admin-bar .mob-header {
  top: 32px;
}
@media (max-width: 782px) {
  .admin-bar .mob-header {
    top: 46px;
  }
}
@media (max-width: 600px) {
  .admin-bar .mob-header {
    top: 0;
  }
}

.mob-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  height: 62px;
  max-width: 1340px;
  margin: 0 auto;
}

/* logo inside mobile header */
.mob-header .mob-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}
.mob-header .mob-logo img {
  max-height: 36px;
  width: auto;
}

/* right icons group */
.mob-header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* cart icon in header bar */
.mob-header-cart {
  position: relative;
  width: 40px !important;
  height: 40px !important;
  min-width: 40px;
  border: 1.5px solid #d6e8f0 !important;
  border-radius: 10px !important;
  background: #ffffff !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  color: #4a6070 !important;
  text-decoration: none !important;
  transition: background .2s, color .2s, border-color .2s;
  padding: 0 !important;
}
.mob-header-cart svg {
  width: 18px !important;
  height: 18px !important;
  display: block !important;
  flex-shrink: 0;
  stroke: currentColor;
  fill: none;
  pointer-events: none;
}
.mob-header-cart:hover {
  background: var(--mmm-brand-light);
  color: var(--mmm-brand);
  border-color: var(--mmm-brand-mid);
}
.mob-header-cart .mob-cart-badge {
  position: absolute;
  top: -5px;
  right: -5px;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  background: #e84040;
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--mmm-white);
  line-height: 1;
}

/* hamburger button */
.mob-menu-open-btn {
  width: 40px !important;
  height: 40px !important;
  min-width: 40px;
  border: 1.5px solid #d6e8f0 !important;
  border-radius: 10px !important;
  background: #ffffff !important;
  cursor: pointer;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  color: #4a6070 !important;
  transition: background .2s, color .2s, border-color .2s;
  flex-shrink: 0;
  padding: 0 !important;
  margin: 0;
  -webkit-appearance: none;
  appearance: none;
  outline: none;
  box-shadow: none;
  line-height: 1;
}
.mob-menu-open-btn:hover {
  background: var(--mmm-brand-light) !important;
  color: var(--mmm-brand) !important;
  border-color: var(--mmm-brand-mid) !important;
}
.mob-menu-open-btn svg {
  width: 20px !important;
  height: 20px !important;
  display: block !important;
  flex-shrink: 0;
  stroke: currentColor;
  fill: none;
  pointer-events: none;
}
.mob-menu-open-btn svg line {
  stroke: currentColor;
}

/* ── Full-screen Modal ──────────────────────────────────── */
.mob-modal-menu {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(247,251,253,.92);
  backdrop-filter: blur(24px) saturate(1.8);
  -webkit-backdrop-filter: blur(24px) saturate(1.8);
  flex-direction: column;
}
.mob-modal-menu.open {
  display: flex;
  animation: mmmFadeIn .32s cubic-bezier(.4,0,.2,1) forwards;
}
.mob-modal-menu.closing {
  display: flex;
  animation: mmmFadeOut .24s cubic-bezier(.4,0,.2,1) forwards;
}
@keyframes mmmFadeIn  { from { opacity: 0; } to { opacity: 1; } }
@keyframes mmmFadeOut { from { opacity: 1; } to { opacity: 0; } }

/* top bar inside modal */
.mob-modal-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  height: 62px;
  border-bottom: 1.5px solid var(--mmm-border);
  flex-shrink: 0;
}
.mob-modal-bar .mob-logo img {
  max-height: 36px;
  width: auto;
}

/* close button */
.mob-modal-close-btn {
  width: 40px !important;
  height: 40px !important;
  min-width: 40px;
  border: 1.5px solid #d6e8f0 !important;
  border-radius: 10px !important;
  background: transparent !important;
  cursor: pointer;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  color: #4a6070 !important;
  transition: background .2s, color .2s, border-color .2s;
  padding: 0 !important;
  -webkit-appearance: none;
  appearance: none;
  outline: none;
  box-shadow: none;
}
.mob-modal-close-btn:hover {
  background: var(--mmm-brand-light) !important;
  color: var(--mmm-brand) !important;
  border-color: var(--mmm-brand-mid) !important;
}
.mob-modal-close-btn svg {
  width: 20px !important;
  height: 20px !important;
  display: block !important;
  flex-shrink: 0;
  stroke: currentColor;
  fill: none;
  pointer-events: none;
}
.mob-modal-close-btn svg line {
  stroke: currentColor;
}

/* scrollable body */
.mob-modal-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 32px 24px 48px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

/* ── Nav Links ──────────────────────────────────────────── */
.mob-modal-nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-bottom: 32px;
  list-style: none;
  padding: 0;
}
.mob-modal-nav li {
  list-style: none;
}
.mob-modal-nav a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px 16px;
  font-size: 19px;
  font-weight: 500;
  color: var(--mmm-navy);
  text-decoration: none;
  border-radius: 14px;
  opacity: 0;
  animation: mmmSlideUp .38s cubic-bezier(.4,0,.2,1) forwards;
  transition: background .2s, color .2s;
}
.mob-modal-nav li:nth-child(1) a { animation-delay: .06s; }
.mob-modal-nav li:nth-child(2) a { animation-delay: .11s; }
.mob-modal-nav li:nth-child(3) a { animation-delay: .16s; }
.mob-modal-nav li:nth-child(4) a { animation-delay: .21s; }
.mob-modal-nav li:nth-child(5) a { animation-delay: .26s; }
.mob-modal-nav li:nth-child(6) a { animation-delay: .31s; }
.mob-modal-nav li:nth-child(7) a { animation-delay: .36s; }
.mob-modal-nav li:nth-child(8) a { animation-delay: .41s; }
.mob-modal-nav li:nth-child(9) a { animation-delay: .46s; }
.mob-modal-nav li:nth-child(10) a { animation-delay: .51s; }
@keyframes mmmSlideUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}
.mob-modal-nav a:hover {
  background: var(--mmm-brand-light);
  color: var(--mmm-brand);
}
.mob-modal-nav .current-menu-item > a,
.mob-modal-nav .current_page_item > a {
  background: var(--mmm-brand-light);
  color: var(--mmm-brand);
  font-weight: 600;
}
.mob-modal-nav .mob-nav-arrow {
  width: 18px;
  height: 18px;
  color: #c2dce8;
  flex-shrink: 0;
}
.mob-modal-nav a:hover .mob-nav-arrow,
.mob-modal-nav .current-menu-item > a .mob-nav-arrow,
.mob-modal-nav .current_page_item > a .mob-nav-arrow {
  color: var(--mmm-brand);
}

/* sub-menus: flatten into the same list */
.mob-modal-nav .sub-menu {
  display: none;
  list-style: none;
  padding: 0;
  margin: 0;
}
.mob-modal-nav .sub-menu a {
  padding-left: 36px;
  font-size: 16px;
}
.mob-modal-nav .menu-item-has-children.mmm-open > .sub-menu {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.mob-modal-nav .menu-item-has-children > a .mob-nav-arrow {
  transition: transform .25s ease;
}
.mob-modal-nav .menu-item-has-children.mmm-open > a .mob-nav-arrow {
  transform: rotate(90deg);
}

/* ── Section Labels ─────────────────────────────────────── */
.mob-modal-section-label {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: #a0b4bc;
  padding: 0 16px;
  margin-bottom: 10px;
  opacity: 0;
  animation: mmmSlideUp .38s .30s cubic-bezier(.4,0,.2,1) forwards;
}
.mob-modal-section-label.mmm-lang-label {
  animation-delay: .42s;
}

/* ── Dashboard / CTA Button ─────────────────────────────── */
.mob-modal-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px 24px;
  background: var(--mmm-brand);
  color: var(--mmm-white);
  border: none;
  border-radius: 14px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  margin-bottom: 32px;
  opacity: 0;
  animation: mmmSlideUp .38s .36s cubic-bezier(.4,0,.2,1) forwards;
  transition: background .2s, transform .15s, box-shadow .2s;
}
.mob-modal-cta:hover {
  background: var(--mmm-brand-hover);
  color: var(--mmm-white);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(71,198,243,.30);
}
.mob-modal-cta svg {
  width: 20px;
  height: 20px;
}

/* ── Account Links ──────────────────────────────────────── */
.mob-modal-account-links {
  display: flex;
  gap: 12px;
  margin-bottom: 32px;
  opacity: 0;
  animation: mmmSlideUp .38s .34s cubic-bezier(.4,0,.2,1) forwards;
}
.mob-modal-account-link {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px;
  border: 1.5px solid var(--mmm-border);
  border-radius: 14px;
  background: var(--mmm-white);
  font-size: 15px;
  font-weight: 500;
  color: var(--mmm-slate);
  text-decoration: none;
  transition: background .2s, color .2s, border-color .2s;
}
.mob-modal-account-link:hover {
  background: var(--mmm-brand-light);
  color: var(--mmm-brand);
  border-color: var(--mmm-brand-mid);
}
.mob-modal-account-link svg {
  width: 18px;
  height: 18px;
}

/* ── Language Buttons ───────────────────────────────────── */
.mob-modal-lang-row {
  display: flex;
  gap: 12px;
  opacity: 0;
  animation: mmmSlideUp .38s .46s cubic-bezier(.4,0,.2,1) forwards;
}
.mob-modal-lang-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px;
  border: 1.5px solid var(--mmm-border);
  border-radius: 14px;
  background: var(--mmm-white);
  font-size: 15px;
  font-weight: 500;
  color: var(--mmm-slate);
  text-decoration: none;
  transition: background .2s, color .2s, border-color .2s;
}
.mob-modal-lang-btn:hover {
  background: var(--mmm-brand-light);
  color: var(--mmm-brand);
  border-color: var(--mmm-brand-mid);
}
.mob-modal-lang-btn.active {
  background: var(--mmm-brand-light);
  color: var(--mmm-brand);
  border-color: var(--mmm-brand);
  font-weight: 600;
}
.mob-modal-lang-btn .mob-flag {
  font-size: 22px;
  line-height: 1;
}
.mob-modal-lang-btn img {
  width: 22px;
  height: auto;
}

/* ── User Info (logged-in) ──────────────────────────────── */
.mob-modal-user-info {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  margin-bottom: 8px;
  opacity: 0;
  animation: mmmSlideUp .38s .04s cubic-bezier(.4,0,.2,1) forwards;
}
.mob-modal-user-info .mob-user-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--mmm-brand-light);
  color: var(--mmm-brand);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.mob-modal-user-info .mob-user-avatar svg {
  width: 22px;
  height: 22px;
}
.mob-modal-user-name {
  font-weight: 600;
  color: var(--mmm-navy);
  font-size: 15px;
}
.mob-modal-user-email {
  font-size: 12px;
  color: var(--mmm-slate);
}

/* ── Visibility ─────────────────────────────────────────── */
/* Hide on desktop (≥992px) — the WP theme uses lg=992px */
@media (min-width: 992px) {
  .mob-header,
  .mob-modal-menu {
    display: none !important;
  }
}

/* ── Hide old mobile menu elements ──────────────────────── */
/* Handled inline via guido_inject_mobile_modal_menu() in functions.php */
