/* Phase 0, version 2: side menu. Loaded with phase0_shell.css, which sets the --p0-* values.
   It never styles the header bar. The menu stays above the header (z-index 100003). */

#edcMobileDrawer.edc-p0-menu, #edcMobileDrawer.edc-p0-menu * { box-sizing: border-box; }
#edcMobileDrawer.edc-p0-menu {
  --menu-accent: #028090; --menu-title: #8C5D19;
  --menu-cta: #0B1F3A; --menu-cta-text: #FFFFFF; --menu-cta-hover: #0E171F;
  inset-block: 0; inset-inline: auto 0;
  display: flex; flex-direction: column;
  width: min(400px, 100%); max-width: none; height: auto; max-height: none;
  padding: 0 0 max(var(--p0-menu-notice), env(safe-area-inset-bottom, 0px));
  border: 0; border-radius: 0; overflow: hidden;
  background: var(--p0-surface) !important; color: var(--p0-text);
  -webkit-backdrop-filter: none; backdrop-filter: none;
  font: 400 1rem/1.6 var(--p0-font); text-align: start;
  transform: translate3d(105%, 0, 0);
}
html[data-theme="dark"] #edcMobileDrawer.edc-p0-menu {
  --menu-accent: #C9A86A; --menu-title: #C9A86A;
  --menu-cta: #C9A86A; --menu-cta-text: #0B1F3A; --menu-cta-hover: #E6CD95;
}
#edcMobileDrawer.edc-p0-menu[dir="rtl"] {
  --p0-font: "IBM Plex Sans Arabic", system-ui, "Segoe UI", sans-serif;
  --p0-display: "Amiri", "Times New Roman", serif;
  transform: translate3d(-105%, 0, 0);
}
#edcMobileDrawer.edc-p0-menu.is-open { transform: none; }
/* No letter spacing or italics on Arabic text */
#edcMobileDrawer.edc-p0-menu[lang="ar"], #edcMobileDrawer.edc-p0-menu[lang="ar"] * { letter-spacing: 0 !important; font-style: normal !important; }
.edc-p0-menu :focus-visible { outline: 3px solid var(--p0-focus); outline-offset: -3px; border-radius: 10px; }
.edc-p0-menu svg { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }

.edc-p0-menu__head { display: flex; align-items: center; gap: 12px; padding: calc(10px + env(safe-area-inset-top, 0px)) 16px 10px; border-bottom: 1px solid var(--p0-line); }
.edc-p0-menu__brand { display: flex; flex: 1; align-items: center; gap: 12px; min-width: 0; min-height: 48px; color: inherit; text-decoration: none; }
.edc-p0-menu__brand img { display: block; flex: none; width: 60px; height: 60px; max-width: none; }
.edc-p0-menu__brand span { min-width: 0; font: 600 1.0625rem/1.3 var(--p0-display); text-wrap: balance; }
.edc-p0-menu[lang="ar"] .edc-p0-menu__brand span { font-weight: 700; font-size: 1.1875rem; line-height: 1.45; }
.edc-p0-menu__close { display: grid; place-items: center; flex: none; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 10px; background: transparent; color: inherit; cursor: pointer; }
.edc-p0-menu__close:hover, a.edc-p0-menu__row:hover, a.edc-p0-menu__row[aria-current] { background: var(--p0-hover); }

.edc-p0-menu__body { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 8px 12px 16px; }
.edc-p0-menu__body section + section { margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--p0-line); }
.edc-p0-menu__body h2 { margin: 6px 12px 4px; color: var(--menu-title); font: 600 .9375rem/1.6 var(--p0-font); text-transform: none; }
.edc-p0-menu__row { display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 8px 12px; border-radius: 10px; color: var(--p0-text); font-size: .9375rem; text-decoration: none; }
.edc-p0-menu__row svg { color: var(--menu-accent); }
.edc-p0-menu__row span { flex: 1; min-width: 0; }
.edc-p0-menu__row b { display: block; font-weight: 600; line-height: 1.45; }
.edc-p0-menu__row small { display: block; color: var(--p0-muted); font-size: .8125rem; line-height: 1.5; }
.edc-p0-menu__row.is-soon b, .edc-p0-menu__row em { color: var(--p0-muted); }
.edc-p0-menu__row em { font-size: .8125rem; font-style: normal; }

.edc-p0-menu__foot { display: flex; flex-wrap: wrap; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--p0-line); }
.edc-p0-menu__btn { display: inline-flex; flex: 1 1 auto; align-items: center; justify-content: center; min-height: 48px; padding: 8px 14px; border: 1px solid var(--p0-field); border-radius: 10px; color: var(--p0-text); font-size: .9375rem; font-weight: 600; text-decoration: none; }
.edc-p0-menu__btn:hover { background: var(--p0-hover); }
.edc-p0-menu__btn.is-cta { border-color: transparent; background: var(--menu-cta); color: var(--menu-cta-text); }
.edc-p0-menu__btn.is-cta:hover { background: var(--menu-cta-hover); }
.edc-p0-menu__btn.is-primary { border-color: transparent; background: #028090; color: #FFFFFF; }
.edc-p0-menu__btn.is-primary:hover { background: #0B1F3A; }
html[data-theme="dark"] .edc-p0-menu__btn.is-primary:hover { background: #F8FAFC; color: #0B1F3A; }
@media (prefers-reduced-motion: reduce) { #edcMobileDrawer.edc-p0-menu { transition: none; } }
