/* Pequena extensão visual, aplicada apenas depois de detetar a navegação admin. */
@media (min-width: 1024px) {
  body.solar-admin-refresh #root header > div.max-w-7xl {
    box-sizing: border-box;
    height: auto !important;
    min-height: 64px;
    flex-wrap: wrap !important;
    align-items: center;
    column-gap: 12px;
    row-gap: 8px;
    padding-top: 9px;
    padding-bottom: 9px;
  }

  body.solar-admin-refresh #root header > div.max-w-7xl > div:first-child {
    order: 0;
    flex: 0 0 auto;
  }

  body.solar-admin-refresh #root header > div.max-w-7xl > div:last-child {
    order: 1;
    flex: 0 0 auto;
    margin-left: auto;
    gap: 8px;
  }

  body.solar-admin-refresh #root header > div.max-w-7xl > nav {
    order: 2;
    display: flex !important;
    flex: 1 0 100%;
    width: 100%;
    min-width: 100%;
    flex-wrap: wrap;
    align-items: stretch;
    justify-content: flex-start;
    gap: 6px !important;
    overflow: visible;
    padding: 4px;
  }

  body.solar-admin-refresh #root header > div.max-w-7xl > nav > button,
  body.solar-admin-refresh #root header > div.max-w-7xl > nav > a {
    box-sizing: border-box;
    display: inline-flex;
    flex: 1 1 116px;
    min-width: 116px;
    max-width: 180px;
    min-height: 42px;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 8px 10px;
    font-size: 13px !important;
    line-height: 1.25;
    text-align: center;
    white-space: normal;
    text-decoration: none;
  }

  body.solar-admin-refresh #root header > div.max-w-7xl > nav > button svg {
    width: 16px;
    height: 16px;
    flex: 0 0 auto;
  }
}

@media (min-width: 1024px) and (max-width: 1350px) {
  body.solar-admin-refresh #root header > div.max-w-7xl > nav > button,
  body.solar-admin-refresh #root header > div.max-w-7xl > nav > a {
    flex-basis: 126px;
    max-width: none;
  }
}

/* Acesso rápido ao correio e módulo de visita integrado ao painel. */
body.solar-admin-refresh #root header > div.max-w-7xl > nav > a[data-solar-mail-link="true"] {
  color: #fff !important;
  font-weight: 700 !important;
}
body.solar-admin-refresh #root header > div.max-w-7xl > nav > a[data-solar-visit-link="true"] {
  background: #eef5ff !important;
  color: #123f82 !important;
  border: 1px solid #cfe0fb !important;
  font-weight: 600 !important;
}
#solar-visit-overlay {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: grid;
  place-items: center;
  padding: clamp(12px, 2.4vw, 28px);
  background: rgba(8, 24, 52, .58);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}
#solar-visit-dialog {
  display: flex;
  flex-direction: column;
  width: min(1180px, 100%);
  height: min(92vh, 900px);
  overflow: hidden;
  background: #f4f7fc;
  border: 1px solid rgba(255,255,255,.72);
  border-radius: 22px;
  box-shadow: 0 28px 90px rgba(3, 19, 49, .34);
}
#solar-visit-toolbar {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 18px 24px;
  background: linear-gradient(120deg, #fff 0%, #f6f9ff 100%);
  border-bottom: 1px solid #e2e9f3;
}
#solar-visit-toolbar h2 {
  margin: 4px 0 2px;
  color: #14243a;
  font: 700 20px/1.25 system-ui, sans-serif;
}
#solar-visit-toolbar p {
  margin: 0;
  color: #64748b;
  font: 400 13px/1.45 system-ui, sans-serif;
}
.solar-visit-eyebrow {
  color: #3972ba;
  font: 700 10px/1.3 system-ui, sans-serif;
  letter-spacing: .11em;
}
#solar-visit-close {
  flex: 0 0 auto;
  padding: 9px 14px;
  color: #173a69;
  background: #edf3fb;
  border: 1px solid #d8e3f1;
  border-radius: 11px;
  font: 600 13px system-ui, sans-serif;
  cursor: pointer;
}
#solar-visit-close:hover { background: #e2ecf9; }
#solar-visit-close:focus-visible { outline: 3px solid #89b6ff; outline-offset: 2px; }
#solar-visit-frame {
  display: block;
  flex: 1 1 auto;
  width: 100%;
  min-height: 0;
  background: #f4f7fc;
  border: 0;
}
@media (max-width: 640px) {
  #solar-visit-overlay { padding: 0; }
  #solar-visit-dialog { width: 100vw; height: 100dvh; border: 0; border-radius: 0; }
  #solar-visit-toolbar { align-items: flex-start; padding: 14px 16px; }
  #solar-visit-toolbar h2 { font-size: 18px; }
  #solar-visit-toolbar p { max-width: 230px; font-size: 12px; }
  #solar-visit-close { padding: 8px 11px; }
}
