/* CIAS.io shared enhancements.
   Loaded after each page's inline <style> block so these rules win on equal
   specificity. First-party only: no external fonts, images or requests. */

/* Some page styles set `display` on classes that are also used on elements we
   hide before enhancement, so normalise the hidden attribute. */
[hidden] { display: none !important; }

/* ---------------------------------------------------------------- focus --- */
:focus-visible {
  outline: 3px solid #533afd;
  outline-offset: 2px;
  border-radius: 6px;
}
header nav a:focus-visible,
.lang-switch a:focus-visible,
.footer-inner a:focus-visible { outline-offset: 4px; }

/* ------------------------------------------------- mobile nav disclosure --- */
.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 42px;
  padding: 0 14px;
  border: 0;
  border-radius: 9px;
  cursor: pointer;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
  color: #071526;
  background: rgba(255, 255, 255, .8);
  box-shadow: rgba(7, 21, 38, .1) 0 0 0 1px;
}
.nav-toggle-icon {
  position: relative;
  display: block;
  width: 16px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
}
.nav-toggle-icon::before,
.nav-toggle-icon::after {
  content: "";
  position: absolute;
  left: 0;
  width: 16px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
}
.nav-toggle-icon::before { top: -5px; }
.nav-toggle-icon::after { top: 5px; }
.nav-toggle[aria-expanded="true"] {
  color: #ffffff;
  background: #071526;
  box-shadow: none;
}

@media (max-width: 940px) {
  /* The page styles hide the list at this width; the links must stay reachable. */
  header nav ul { display: flex; }
  header .nav {
    height: auto;
    min-height: 72px;
    flex-wrap: wrap;
    row-gap: 10px;
    padding: 8px 0;
  }

  /* --- with JavaScript: a collapsible panel driven by [data-nav-toggle] --- */
  html.cias-js .nav-toggle { display: inline-flex; order: 3; }
  html.cias-js header .nav { position: relative; }
  html.cias-js header nav[data-nav-panel] {
    display: none;
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    padding: 10px;
    border-radius: 16px;
    background: #ffffff;
    box-shadow: rgba(7, 21, 38, .1) 0 0 0 1px, rgba(50, 50, 93, .22) 0 24px 45px -26px;
    z-index: 40;
  }
  html.cias-js header nav[data-nav-panel].is-open { display: block; }
  html.cias-js header nav[data-nav-panel] ul {
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
  }
  html.cias-js header nav[data-nav-panel] a {
    display: block;
    padding: 12px;
    border-radius: 10px;
    font-size: 15px;
  }
  html.cias-js header nav[data-nav-panel] a:hover,
  html.cias-js header nav[data-nav-panel] a[aria-current] {
    background: rgba(83, 58, 253, .07);
  }

  /* --- without JavaScript: the toggle is useless, so reflow the links --- */
  html:not(.cias-js) header nav[data-nav-panel] { flex-basis: 100%; order: 3; }
  html:not(.cias-js) header nav[data-nav-panel] ul { flex-wrap: wrap; gap: 10px 18px; }
}

@media (max-width: 640px) {
  header .nav { min-height: 64px; }
  /* Keep brand + menu button on one row and the language links on the next,
     so both stay visible down to 320px. */
  html.cias-js header .nav-actions { order: 4; flex-basis: 100%; }
  html.cias-js header nav[data-nav-panel] { top: calc(100% + 4px); }
}

/* ------------------------------------------------------- email actions --- */
.email-actions {
  margin-top: 26px;
  padding: 20px 22px;
  border-radius: 18px;
  background: rgba(83, 58, 253, .06);
  box-shadow: rgba(83, 58, 253, .18) 0 0 0 1px inset;
}
.email-actions h2 {
  margin: 0 0 10px;
  font-size: clamp(22px, 2.4vw, 26px);
  letter-spacing: -.04em;
  line-height: 1.15;
}
.email-actions p {
  margin: 0 0 14px;
  color: #445269;
  line-height: 1.65;
  max-width: 760px;
}
.email-actions-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}
.email-actions .email-actions-note {
  margin: 14px 0 0;
  font-size: 14px;
  color: #5c6a7d;
}
.email-actions [data-email-status] {
  display: block;
  margin: 12px 0 0;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.5;
  color: #34219c;
}
.email-actions [data-email-status]:empty { margin: 0; }
.email-actions .email-address { user-select: all; }

@media (max-width: 640px) {
  .email-actions { padding: 18px; }
  .email-actions-row .btn { width: 100%; }
}

/* Cards on secondary pages have no link styling of their own. */
.link-more {
  display: inline-block;
  color: #533afd;
  font-weight: 650;
  text-decoration: none;
}
.link-more:hover { text-decoration: underline; }

/* -------------------------------------------- illustrative / cta notes --- */
.console-note {
  margin: 12px 6px 2px;
  color: #5c6a7d;
  font-size: 12.5px;
  line-height: 1.5;
}
.cta-note {
  margin: 18px 0 0;
  max-width: 640px;
  color: #5c6a7d;
  font-size: 14px;
  line-height: 1.6;
}
