/* VOLIQA V404 — all public dialogs begin below the actual fixed header.
   This file intentionally overrides only the later V402 overlay geometry.
   Header/footer styling and the frozen live-candidates table are not selected. */
:root{--v404-popup-header-bottom:92px}

:is(
  .v364-about-modal:not([hidden]),
  .v400-how-modal:not([hidden]),
  .v40-faq-modal:not([hidden]),
  .v24-help-modal:not([hidden]),
  .v48-sitemap-modal:not([hidden]),
  .v48-case-modal:not([hidden]),
  .v81-ai-modal:not([hidden]),
  .v339-analysis-modal:not([hidden]),
  #v347-cookie-modal:not([hidden]),
  .v113-legal-modal.is-open,
  .v13-modal.open,
  .v13-modal.is-open,
  .v13-modal[aria-hidden="false"]
){
  inset:var(--v404-popup-header-bottom) 0 0!important;
  height:auto!important;
  max-height:calc(100dvh - var(--v404-popup-header-bottom))!important;
  padding:12px max(12px,env(safe-area-inset-right)) max(12px,env(safe-area-inset-bottom)) max(12px,env(safe-area-inset-left))!important;
}

:is(
  .v13-modalbox,
  .v364-about-dialog,
  .v400-how-dialog,
  .v40-faq-dialog,
  .v48-sitemap-dialog,
  .v48-case-dialog,
  .v81-ai-dialog,
  .v339-analysis-dialog,
  .v347-cookie-dialog,
  .v113-legal-dialog,
  .v24-help-dialog
){
  max-height:calc(100dvh - var(--v404-popup-header-bottom) - 24px - env(safe-area-inset-bottom))!important;
}

/* Roadmap inherited a historical fixed 174 px flex basis. It is now governed
   by the same content-width rule as the neighbouring header controls. */
#top .v48-menubar>a.v151-head-ecosystem.v244-header-btn{
  width:auto!important;
  min-width:0!important;
  max-width:none!important;
  flex:0 0 auto!important;
  justify-content:flex-start!important;
}
