/* Independent Blade adaptation of the expanding navigation interaction supplied by the owner.
   Reference: https://21st.dev/@larsen66/components/navigation-menu */
.fargah-header.fargah-header--floating {
  --navigation-paper: color-mix(in srgb, var(--card) 94%, transparent);
  --navigation-ink: var(--foreground);
  --navigation-muted: var(--muted-foreground);
  --navigation-line: var(--border);
  --navigation-accent: var(--atelier-gold);
  --navigation-hover: var(--muted);
  position: sticky !important;
  inset-block-start: 0;
  z-index: 1200;
  padding: 12px 20px;
  min-height: 92px;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none;
  isolation: isolate;
}
[data-theme="dark"] .fargah-header.fargah-header--floating {
  --navigation-paper: color-mix(in srgb, var(--card) 95%, transparent);
  --navigation-ink: var(--foreground);
  --navigation-muted: var(--muted-foreground);
  --navigation-line: var(--border);
  --navigation-accent: var(--primary);
  --navigation-hover: var(--muted);
  background: transparent;
}
.fargah-header--floating .fargah-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  position: relative;
  width: min(100%, 1480px);
  max-width: 1480px;
  min-height: 68px;
  margin-inline: auto;
  padding: 10px 16px;
  color: var(--navigation-ink);
  background: var(--navigation-paper);
  border: 1px solid var(--navigation-line);
  border-radius: 999px;
  box-shadow: 0 8px 34px rgb(35 27 13 / 7%), inset 0 1px rgb(255 255 255 / 8%);
  backdrop-filter: blur(18px);
  transition: width 420ms cubic-bezier(.2,.8,.2,1), box-shadow 250ms ease;
}
.fargah-header.fargah-header--floating.is-mobile-menu-open { z-index: 2500; }
.fargah-header--floating .fargah-logo {
  flex: 0 0 170px;
  width: 170px;
  max-width: 170px;
  padding: 0;
}
.fargah-header--floating .fargah-logo .fargah-logo__brand {
  display: block;
  width: 100%;
  max-width: 170px;
  height: auto;
  max-height: 46px;
  object-fit: contain;
}
.fargah-header--floating .fargah-navigation-desktop { flex: 1 1 auto; min-width: 0; }
.fargah-header.fargah-header--floating .fargah-nav {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: center;
  gap: 2px !important;
  padding: 0;
  margin: 0;
  list-style: none;
  border: 0;
  background: transparent;
  box-shadow: none;
}
.fargah-header--floating .fargah-nav > li { flex: 0 0 auto; display: block; }
.fargah-header.fargah-header--floating .fargah-nav > li > :is(a, button) {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-height: 42px;
  padding: 9px 8px;
  margin: 0;
  border: 1px solid transparent;
  border-radius: 999px;
  color: var(--navigation-muted);
  background: transparent;
  box-shadow: none;
  font-size: 12px !important;
  font-weight: 650 !important;
  line-height: 1.5;
  white-space: nowrap;
  text-decoration: none;
  transition: color 180ms ease, background 180ms ease, border-color 180ms ease;
}
.fargah-header--floating .fargah-nav > li > :is(a, button)::before,
.fargah-header--floating .fargah-nav > li > :is(a, button)::after { display: none; }
.fargah-header--floating .fargah-nav > li > :is(a, button):is(:hover, :focus-visible, .active, [aria-current="page"]),
.fargah-header--floating .fargah-nav > .is-open > button {
  color: var(--navigation-accent);
  background: var(--navigation-hover);
  border-color: var(--navigation-line);
  box-shadow: none;
}
.fargah-header--floating :is(a, button, input):focus-visible {
  outline: 2px solid var(--navigation-accent);
  outline-offset: 3px;
}
.fargah-header--floating .fargah-header__end {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0;
  margin: 0;
  border: 0;
  background: transparent;
}
.fargah-header--floating .fargah-header__divider { display: none !important; }
.fargah-header--floating :is(.theme-toggle, .header-icon-btn, .mobile-menu-toggle, .locale-dropdown__trigger) {
  width: 38px;
  height: 38px;
  min-width: 38px;
  min-height: 38px;
  padding: 0;
  color: var(--navigation-ink);
  border: 1px solid var(--navigation-line);
  border-radius: 50%;
  background: transparent;
  box-shadow: none;
}
.fargah-header--floating .locale-dropdown { border: 0; background: transparent; box-shadow: none; }
.fargah-header--floating .locale-dropdown__trigger { width: auto; gap: 5px; padding-inline: 9px; border-radius: 999px; }
.fargah-header--floating .locale-dropdown__label { font-size: 11px; }
.fargah-header--floating .locale-dropdown__flag { width: 20px; }
.fargah-header--floating .fargah-nav__dropdown-anchor {
  inset-inline-start: 50%;
  inset-inline-end: auto;
  inset-block-start: 100%;
  width: 250px;
  padding-block-start: 12px;
  transform: translateX(-50%);
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}
[dir="rtl"] .fargah-header--floating .fargah-nav__dropdown-anchor { transform: translateX(50%); }
.fargah-header--floating .fargah-nav__dropdown {
  width: 100%;
  min-width: 0;
  padding: 8px;
  border: 1px solid var(--navigation-line);
  border-radius: 22px;
  background: var(--navigation-paper);
  box-shadow: 0 18px 42px rgb(29 22 11 / 16%);
  backdrop-filter: blur(18px);
}
.fargah-header--floating .fargah-nav__dropdown a {
  min-height: 48px;
  padding: 13px 14px;
  color: var(--navigation-ink);
  border: 0;
  border-radius: 14px;
  text-align: start;
  justify-content: flex-start;
  font-size: 14px;
  white-space: normal;
}
.fargah-header--floating .fargah-nav__dropdown a::before { display: none; }
.fargah-header--floating .fargah-nav__dropdown a:is(:hover, :focus-visible, .active) { background: var(--navigation-hover); color: var(--navigation-accent); }
.fargah-header--floating .fargah-nav__dropdown-trigger svg { transition: transform 180ms ease; }
.fargah-header--floating .fargah-nav__dropdown-trigger[aria-expanded="true"] svg { transform: rotate(180deg); }
.fargah-header--floating .fargah-navigation-expand {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  border-radius: inherit;
  color: var(--navigation-ink);
  background: transparent;
  cursor: pointer;
}
.fargah-header--floating [hidden] { display: none !important; }
.fargah-header--floating .fargah-navigation-mobile-toggle { display: none; }
.fargah-header--floating .header-search-panel {
  width: min(760px, calc(100% - 40px));
  position: absolute;
  inset-block-start: calc(100% - 4px);
  inset-inline-start: 50%;
  padding: 20px;
  border: 1px solid var(--navigation-line);
  border-radius: 24px;
  background: var(--navigation-paper);
  box-shadow: 0 18px 42px rgb(29 22 11 / 12%);
  transform: translateX(-50%);
}
[dir="rtl"] .fargah-header--floating .header-search-panel { transform: translateX(50%); }
.fargah-header--floating .header-search-panel .fargah-container { width: 100%; padding: 0; }
/* The earlier mobile shell uses important declarations; override only its header shell here. */
.fargah-header.fargah-header--floating .fargah-header__inner {
  direction: inherit;
  height: auto !important;
  border: 1px solid var(--navigation-line) !important;
  border-radius: 999px !important;
  background: var(--navigation-paper) !important;
  box-shadow: 0 8px 34px rgb(35 27 13 / 7%) !important;
}
@media (min-width: 1280px) {
  .fargah-header--floating.is-navigation-collapsed .fargah-header__inner { width: 64px; min-height: 64px; padding: 0; }
  .fargah-header--floating.is-navigation-collapsed .fargah-header__inner > :not(.fargah-navigation-expand) { opacity: 0; visibility: hidden; pointer-events: none; }
  .fargah-header--floating .fargah-mobile-nav-panel { display: none; }
}
@media (min-width: 1280px) and (max-width: 1519.98px) {
  .site-locale-en .fargah-header.fargah-header--floating .fargah-logo,
  .site-locale-ar .fargah-header.fargah-header--floating .fargah-logo { flex-basis: 150px; width: 150px !important; max-width: 150px !important; }
  .site-locale-en .fargah-header.fargah-header--floating .fargah-nav,
  .site-locale-ar .fargah-header.fargah-header--floating .fargah-nav { gap: 1px !important; }
  .site-locale-en .fargah-header.fargah-header--floating .fargah-nav > li > :is(a, button),
  .site-locale-ar .fargah-header.fargah-header--floating .fargah-nav > li > :is(a, button) { padding-inline: 6px; font-size: 11px !important; letter-spacing: 0; }
}
@media (min-width: 1520px) {
  .fargah-header--floating .fargah-logo { flex-basis: 200px; width: 200px; max-width: 200px; }
  .fargah-header--floating .fargah-logo .fargah-logo__brand { max-width: 200px; }
  .fargah-header.fargah-header--floating .fargah-nav > li > :is(a, button) { padding-inline: 11px; font-size: 13px !important; }
}
@media (max-width: 1279.98px) {
  .fargah-header.fargah-header--floating { padding: 10px 18px; min-height: 86px; border: 0 !important; background: transparent !important; }
  .fargah-header.fargah-header--floating .fargah-header__inner { min-height: 66px !important; height: auto !important; padding: 9px 15px !important; gap: 12px; }
  .fargah-header--floating .fargah-navigation-desktop { display: none; }
  .fargah-header--floating .fargah-navigation-mobile-toggle { display: inline-flex; align-items: center; justify-content: center; flex-direction: column; }
  .fargah-header--floating .fargah-navigation-mobile-toggle::before { display: none; }
  .fargah-header--floating .fargah-navigation-mobile-toggle span { width: 16px; height: 1.5px; flex: 0 0 1.5px; margin: 2px 0; background: currentColor; }
  .fargah-header.fargah-header--floating .fargah-mobile-nav-panel {
    display: block;
    position: fixed !important;
    inset: 88px 18px 16px !important;
    width: auto !important;
    max-width: 620px;
    max-height: calc(100dvh - 104px) !important;
    height: auto !important;
    padding: 22px !important;
    margin-inline: auto;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    border: 1px solid var(--navigation-line) !important;
    border-radius: 28px !important;
    color: var(--navigation-ink) !important;
    background: var(--navigation-paper) !important;
    box-shadow: 0 0 0 100vmax rgb(20 14 6 / 25%), 0 18px 60px rgb(20 14 6 / 22%) !important;
    backdrop-filter: blur(20px);
    animation: navigation-panel-in 220ms ease-out;
  }
  .fargah-header.fargah-header--floating .fargah-mobile-nav-panel .fargah-container { width: 100% !important; max-width: none !important; padding: 0 !important; }
  .fargah-header--floating .fargah-mobile-nav__head { position: relative; inset: auto; display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 0 0 16px; padding: 0 0 15px; border-bottom: 1px solid var(--navigation-line); color: var(--navigation-muted); font-size: 13px; direction: inherit; }
  .fargah-header--floating .fargah-mobile-nav__head span { color: var(--navigation-ink); }
  .fargah-header--floating .fargah-mobile-nav__head button { display: grid; place-items: center; width: 42px; height: 42px; padding: 0; border: 1px solid var(--navigation-line); border-radius: 50%; color: var(--navigation-ink); background: transparent; font-size: 24px; }
  .fargah-header--floating .fargah-mobile-nav { display: grid; grid-template-columns: 1fr 1fr !important; gap: 8px !important; background: transparent; padding: 0; }
  .fargah-header.fargah-header--floating .fargah-mobile-nav > a {
    display: flex;
    align-items: center;
    min-width: 0;
    min-height: 56px !important;
    padding: 13px 16px !important;
    margin: 0;
    border: 1px solid var(--navigation-line) !important;
    border-radius: 16px !important;
    color: var(--navigation-ink) !important;
    background: transparent !important;
    font-size: 14px !important;
    font-weight: 600;
    line-height: 1.7;
    text-align: start;
    overflow-wrap: anywhere;
    opacity: 1;
    transform: none;
    animation: none;
  }
  .fargah-header--floating .fargah-mobile-nav > a::after { display: none; }
  .fargah-header.fargah-header--floating .fargah-mobile-nav > a:is(:hover, :focus-visible, .active, [aria-current="page"]) { color: var(--navigation-accent) !important; background: var(--navigation-hover) !important; border-color: var(--navigation-line) !important; transform: none; }
  .fargah-header.fargah-header--floating .fargah-mobile-nav > .fargah-mobile-nav__cta { grid-column: 1 / -1; color: var(--navigation-ink) !important; background: var(--navigation-hover) !important; justify-content: center; }
  .fargah-header--floating .fargah-navigation-languages { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; margin-block-start: 20px; padding-block-start: 16px; border-top: 1px solid var(--navigation-line); }
  .fargah-header--floating .fargah-navigation-languages a { min-height: 44px; display: inline-flex; align-items: center; padding: 8px 16px; border: 1px solid var(--navigation-line); border-radius: 999px; color: var(--navigation-muted); font-size: 13px; }
  .fargah-header--floating .fargah-navigation-languages a[aria-current] { color: var(--navigation-accent); background: var(--navigation-hover); }
  body.fargah-menu-open { overflow: hidden; }
}
@media (max-width: 575.98px) {
  .fargah-header.fargah-header--floating { padding: 8px 10px; min-height: 78px; }
  .fargah-header.fargah-header--floating .fargah-header__inner { min-height: 62px !important; padding: 8px 12px !important; gap: 8px; }
  .fargah-header--floating .fargah-logo { flex: 0 1 140px; width: 140px !important; max-width: 140px; }
  .fargah-header--floating .fargah-logo .fargah-logo__brand { max-width: 140px; }
  .fargah-header--floating .fargah-header__end { gap: 4px !important; }
  .fargah-header.fargah-header--floating :is(.theme-toggle, .header-icon-btn, .mobile-menu-toggle) { width: 38px !important; height: 38px !important; min-width: 38px !important; min-height: 38px !important; }
  .fargah-header.fargah-header--floating .fargah-mobile-nav-panel { inset: 80px 10px 10px !important; padding: 18px !important; max-height: calc(100dvh - 90px) !important; border-radius: 24px !important; }
  .fargah-header--floating .fargah-mobile-nav { grid-template-columns: 1fr !important; }
  .fargah-header.fargah-header--floating .fargah-mobile-nav > a { min-height: 52px !important; padding: 11px 15px !important; }
  .fargah-header--floating .header-search-panel { width: calc(100% - 20px); padding: 16px; }
}
@media (max-width: 359.98px) {
  .fargah-header--floating .fargah-logo { flex-basis: 106px; width: 106px !important; max-width: 106px; }
  .fargah-header--floating .fargah-logo .fargah-logo__brand { max-width: 106px; }
  .fargah-header.fargah-header--floating .fargah-header__inner { padding-inline: 9px !important; }
}
@keyframes navigation-panel-in { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: translateY(0); } }
@media (prefers-reduced-motion: reduce) {
  .fargah-header--floating *, .fargah-header--floating *::before, .fargah-header--floating *::after { transition: none !important; animation: none !important; }
}
@media (forced-colors: active) {
  .fargah-header--floating .fargah-header__inner, .fargah-header--floating .fargah-mobile-nav-panel, .fargah-header--floating .fargah-nav__dropdown { border: 1px solid CanvasText; }
}
@media print { .fargah-header.fargah-header--floating { position: static; padding: 0; } .fargah-header--floating .fargah-navigation-expand { display: none; } }
