/* Shared Editorial Header V1 — used by homepage and article pages. */
.editorial-header{
  display:block;
  border-block-end:1px solid var(--ds-border-subtle);
  background:var(--paper-0);
  color:var(--ink-1);
}
.editorial-header .signal-bar{
  border-block-end:1px solid var(--ds-border-subtle);
  background:var(--paper-0);
  color:var(--ink-1);
}
.editorial-header .signal-bar__inner{
  min-height:1.85rem;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:1rem;
  font-size:.68rem;
  font-weight:800;
}
.editorial-header .signal-bar__mark{
  display:inline-flex;
  align-items:center;
  gap:.42rem;
  white-space:nowrap;
}
.editorial-header .signal-bar__mark::before{
  content:"";
  width:.42rem;
  height:.42rem;
  background:var(--editorial-accent);
  transform:rotate(45deg);
}
.editorial-header .signal-bar__links{
  display:flex;
  align-items:center;
  gap:.9rem;
}
.editorial-header .signal-bar__links a{
  color:var(--ds-text-muted);
  text-decoration:none;
  white-space:nowrap;
}
.editorial-header .signal-bar__links a:hover,
.editorial-header .signal-bar__links a:focus-visible{color:var(--ds-text-link)}

.editorial-header .masthead{
  background:var(--paper-0);
  border:0;
}
.editorial-header .masthead__row{
  min-height:5.55rem;
  display:grid;
  grid-template-columns:minmax(13rem,1fr) minmax(14rem,auto) minmax(13rem,1fr);
  gap:1rem;
  align-items:center;
  border-block-end:1px solid var(--ds-border-default);
}
.editorial-header .masthead__right-zone{
  min-width:0;
  display:flex;
  align-items:center;
  justify-self:start;
  gap:.5rem;
}
.editorial-header .masthead__wordmark{
  display:grid;
  justify-items:center;
  gap:.28rem;
  justify-self:center;
  color:inherit;
  text-decoration:none;
  line-height:1;
}
.editorial-header .masthead__brand-logo{
  display:block;
  width:clamp(10.8rem,15vw,14.3rem);
}
.editorial-header .masthead__brand-logo img{
  display:block;
  width:100%;
  height:auto;
}
.editorial-header .masthead__arabic{
  margin:0;
  color:var(--editorial-accent);
  font-size:.62rem;
  font-weight:900;
  line-height:1;
  letter-spacing:.035em;
}
.editorial-header .masthead__actions{
  justify-self:end;
  display:flex;
  align-items:center;
  gap:.55rem;
}
.editorial-header .masthead__search{
  display:grid;
  place-items:center;
  width:2.35rem;
  height:2.35rem;
  min-width:2.35rem;
  border:1px solid var(--ds-action-secondary-border);
  border-radius:999px;
  background:var(--ds-action-secondary-bg);
  color:var(--ds-action-secondary-text);
}
.editorial-header .masthead__search:hover{
  border-color:var(--ds-border-active);
  background:var(--ds-action-secondary-hover);
}

.editorial-header .public-membership__link{
  min-height:2.32rem;
  padding:.45rem .72rem;
  font-size:.72rem;
}
.editorial-header .public-membership__icon{
  width:.95rem;
  height:.95rem;
  flex-basis:.95rem;
}

.editorial-header .primary-nav{
  border-block-end:1px solid var(--ds-border-default);
  background:var(--paper-0);
}
.editorial-header .primary-nav__inner{
  min-height:2.72rem;
  display:flex;
  align-items:center;
  overflow:visible;
}
.editorial-header .primary-nav__desktop{
  width:100%;
  display:flex;
  align-items:stretch;
  justify-content:center;
  gap:.12rem;
}
.editorial-header .primary-nav__mobile{display:none}
.editorial-header .primary-nav__item{
  position:relative;
  display:flex;
  align-items:stretch;
}
.editorial-header .primary-nav__item>a,
.editorial-header .primary-nav__more>summary,
.editorial-header .primary-nav__mobile-more>summary{
  position:relative;
  display:flex;
  align-items:center;
  min-height:2.72rem;
  padding:.25rem .78rem;
  border-radius:8px;
  color:var(--ds-text-strong);
  font-size:.76rem;
  font-weight:850;
  line-height:1.25;
  white-space:nowrap;
  text-decoration:none;
  cursor:pointer;
}
.editorial-header .primary-nav__item>a:hover,
.editorial-header .primary-nav__item>a:focus-visible,
.editorial-header .primary-nav__more>summary:hover,
.editorial-header .primary-nav__more>summary:focus-visible,
.editorial-header .primary-nav__more[open]>summary,
.editorial-header .primary-nav__mobile-more[open]>summary{
  background:var(--ds-surface-interactive-hover);
  color:var(--ds-text-link);
}
.editorial-header .primary-nav__more,
.editorial-header .primary-nav__mobile-more{position:relative}
.editorial-header .primary-nav__more>summary,
.editorial-header .primary-nav__mobile-more>summary{list-style:none;gap:.35rem}
.editorial-header .primary-nav__more>summary::-webkit-details-marker,
.editorial-header .primary-nav__mobile-more>summary::-webkit-details-marker{display:none}
.editorial-header .primary-nav__chevron{
  width:.85rem;
  height:.85rem;
  fill:none;
  stroke:currentColor;
  stroke-width:1.8;
  transition:transform .16s ease;
}
.editorial-header details[open]>.primary-nav__chevron,
.editorial-header details[open]>summary .primary-nav__chevron{transform:rotate(180deg)}
.editorial-header .primary-nav__more-menu{
  position:absolute;
  z-index:150;
  inset-block-start:calc(100% + .35rem);
  inset-inline-end:0;
  width:min(22rem,calc(100vw - 2rem));
  max-height:min(70vh,34rem);
  overflow:auto;
  display:grid;
  gap:.18rem;
  padding:.45rem;
  border:1px solid var(--ds-border-default);
  border-radius:12px;
  background:var(--ds-surface-panel);
  box-shadow:var(--ds-shadow-float);
}
.editorial-header .primary-nav__more-menu .primary-nav__item{display:block}
.editorial-header .primary-nav__more-menu .primary-nav__item>a{
  min-height:2.35rem;
  width:100%;
  padding:.45rem .6rem;
  font-size:.74rem;
}

@media(max-width:1100px){
  .editorial-header .masthead__row{
    grid-template-columns:minmax(11rem,1fr) minmax(12rem,auto) minmax(11rem,1fr);
  }
  .editorial-header .masthead__brand-logo{width:11.5rem}
  .editorial-header .public-membership__link{padding-inline:.58rem;font-size:.68rem}
  .editorial-header .primary-nav__item>a,
  .editorial-header .primary-nav__more>summary{padding-inline:.58rem;font-size:.71rem}
}

@media(max-width:760px){
  .editorial-header .signal-bar__inner{
    min-height:1.75rem;
    justify-content:center;
  }
  .editorial-header .signal-bar__links{display:none}
  .editorial-header .masthead__row{
    min-height:auto;
    grid-template-columns:1fr;
    grid-template-rows:auto auto auto;
    gap:.65rem;
    padding-block:.85rem;
  }
  .editorial-header .masthead__wordmark{
    grid-column:1;
    grid-row:1;
  }
  .editorial-header .masthead__brand-logo{width:10.5rem}
  .editorial-header .masthead__arabic{display:none}
  .editorial-header .masthead__right-zone{
    grid-column:1;
    grid-row:2;
    width:100%;
    justify-self:stretch;
    justify-content:center;
  }
  .editorial-header .masthead__membership{
    width:100%;
    justify-content:center;
  }
  .editorial-header .masthead__actions{
    grid-column:1;
    grid-row:3;
    width:100%;
    justify-self:stretch;
    justify-content:center;
  }
  .editorial-header .primary-nav__inner{min-height:2.6rem}
  .editorial-header .primary-nav__desktop{display:none}
  .editorial-header .primary-nav__mobile{
    width:100%;
    display:flex;
    align-items:center;
    justify-content:center;
    gap:.12rem;
  }
  .editorial-header .primary-nav__mobile .primary-nav__item>a,
  .editorial-header .primary-nav__mobile-more>summary{
    min-height:2.55rem;
    padding-inline:.62rem;
    font-size:.72rem;
  }
  .editorial-header .primary-nav__more-menu{
    inset-inline-end:auto;
    inset-inline-start:50%;
    transform:translateX(-50%);
  }
}

@media(max-width:430px){
  .editorial-header .public-membership{gap:.32rem}
  .editorial-header .public-membership__link{
    min-height:2.25rem;
    padding-inline:.55rem;
    font-size:.67rem;
  }
  .editorial-header .masthead__search{width:2.25rem;height:2.25rem;min-width:2.25rem}
}

/* Shared Editorial Header V1.1 — header chrome spans the viewport, page content stays capped. */
.editorial-header .page-shell{
  width:100%;
  max-width:none;
  margin-inline:0;
  padding-inline:clamp(1rem,2vw,2.25rem);
  box-sizing:border-box;
}
.editorial-header .primary-nav__desktop{
  justify-content:space-between;
}
@media(max-width:760px){
  .editorial-header .page-shell{padding-inline:1rem}
  .editorial-header .primary-nav__mobile{justify-content:space-between}
}
