/* Gelijke scroller/footer-verhoudingen voor Chatbox, Registreren en Contact. */
.scroller-shell,
.contact-marquee {
  display: block !important;
  width: 100% !important;
  max-width: none !important;
  height: 44px !important;
  min-height: 44px !important;
  margin: 0 auto !important;
  padding: 0 !important;
  overflow: hidden !important;
  border: 1px solid rgba(110,190,255,.62) !important;
  border-radius: 14px !important;
  background: rgba(5,12,42,.72) !important;
  box-shadow: 0 8px 22px rgba(0,0,0,.24) !important;
  box-sizing: border-box !important;
  position: relative !important;
  z-index: 0;
}

.scroller-shell::before,
.contact-marquee::before {
  display: none !important;
}

.scroller,
.contact-scroller {
  min-height: 42px !important;
  padding: 5px 10px !important;
  align-items: center !important;
  gap: 10px !important;
  box-sizing: border-box !important;
}

.user-pill,
.contact-user-pill {
  min-width: 92px !important;
  height: 32px !important;
  min-height: 32px !important;
  padding: 3px 10px 3px 5px !important;
  gap: 7px !important;
  border-radius: 999px !important;
  font-size: 11px !important;
  box-sizing: border-box !important;
}

.user-pill img,
.avatar-fallback,
.contact-user-pill img,
.contact-avatar-fallback {
  width: 24px !important;
  height: 24px !important;
  min-width: 24px !important;
  min-height: 24px !important;
}

.login-footer,
.contact-inline-footer {
  display: grid !important;
  width: 100% !important;
  max-width: none !important;
  min-height: 36px !important;
  margin: 0 auto !important;
  padding: 6px 12px !important;
  place-items: center !important;
  border: 1px solid rgba(110,190,255,.52) !important;
  border-radius: 14px !important;
  background: rgba(5,12,42,.72) !important;
  color: rgba(248,251,255,.92) !important;
  box-sizing: border-box !important;
  font-size: 11px !important;
  line-height: 1.35 !important;
  text-align: center !important;
  text-shadow: 0 2px 8px rgba(0,0,0,.66) !important;
  position: relative !important;
  overflow: hidden !important;
}

.login-footer::before,
.contact-inline-footer::before {
  content: none !important;
  display: none !important;
}

body.login-layout-retro .scroller-shell {
  display: block !important;
}

body.login-layout-retro .login-footer {
  display: grid !important;
}

/* De rode bovenrand blijft ook zichtbaar wanneer Chatmee Retro actief is. */
html.site-theme-chatmee-retro body .contact-layout > .contact-card,
html body .contact-layout > .contact-card {
  border: 1px solid #565f85 !important;
  border-top: 5px solid #cf1020 !important;
  border-radius: 7px !important;
  box-shadow: inset 0 4px 0 #cf1020 !important;
}

html body .contact-layout {
  display: flex !important;
  width: 100% !important;
  max-width: none !important;
  min-width: 0 !important;
  flex-direction: column !important;
  gap: 14px !important;
  box-sizing: border-box !important;
}

html body .contact-layout > .contact-card,
html body .contact-layout > .contact-marquee,
html body .contact-layout > .contact-inline-footer {
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  flex: 0 0 auto;
  margin: 0 auto !important;
  box-sizing: border-box !important;
}

/* Contact gebruikt geen intrinsiek groeiende gridkolom: zo blijft rechts exact
   binnen dezelfde rand als de header. */
html body > main.contact-main {
  display: block !important;
  max-width: 1180px !important;
  min-width: 0 !important;
  margin-right: auto !important;
  margin-left: auto !important;
  box-sizing: border-box !important;
}

html body .contact-card,
html body .contact-card-body,
html body .contact-card form,
html body .contact-field-grid,
html body .contact-footer-row,
html body .contact-field-grid > *,
html body .contact-footer-row > * {
  max-width: 100% !important;
  min-width: 0 !important;
  box-sizing: border-box !important;
}

.auth-lower-stack {
  width: 100% !important;
  max-width: none !important;
  margin: 14px auto 8px !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 14px !important;
}

/* Registreren/contact: footer is direct onderdeel van het formulierframe. */
html body main.page > .auth-wrap + .login-footer {
  width: 100% !important;
  max-width: 100% !important;
  margin: -1px auto 0 !important;
  border-top: 0 !important;
  box-sizing: border-box !important;
}

html body main.page > .auth-wrap:has(+ .login-footer) {
  margin-bottom: 0 !important;
  border-bottom-left-radius: 0 !important;
  border-bottom-right-radius: 0 !important;
}

/* Het zichtbare registratiepaneel zit binnen auth-wrap en moet zelf ook
   rechte onderhoeken krijgen voor een volledig naadloze footerverbinding. */
html body main.page > .auth-wrap:has(+ .login-footer) > .auth-panel {
  border-bottom-left-radius: 0 !important;
  border-bottom-right-radius: 0 !important;
}

/* Op Contact sluit de footer direct tegen de kaart; de marquee volgt eronder. */
.contact-layout > .contact-card:has(+ .contact-inline-footer) {
  border-bottom-left-radius: 0 !important;
  border-bottom-right-radius: 0 !important;
}

.contact-layout > .contact-card + .contact-inline-footer {
  margin-top: -15px !important;
  border-top-left-radius: 0 !important;
  border-top-right-radius: 0 !important;
  border-bottom-left-radius: 9px !important;
  border-bottom-right-radius: 9px !important;
}

.auth-lower-stack > .scroller-shell,
.auth-lower-stack > .login-footer {
  width: 100% !important;
  flex: 0 0 auto;
  margin: 0 !important;
}

body .auth-login .head {
  display: flex !important;
  grid-template-columns: none !important;
  justify-content: flex-end !important;
}

body .auth-login .language-switch {
  margin-left: auto !important;
}

/* Hoofdblokken volgen exact dezelfde buitenbreedte als de websiteheader. */
body > .auth-site-header + .page {
  width: min(100% - 32px,1180px) !important;
  max-width: 1180px !important;
  padding-right: 0 !important;
  padding-left: 0 !important;
  box-sizing: border-box !important;
}

body.site-theme-chatmee-retro .auth-wrap[data-active="login"],
body.site-theme-chatmee-retro .auth-wrap[data-active="register"],
body.site-theme-chatmee-retro .auth-wrap[data-active="contact"],
body .auth-wrap[data-active="login"],
body .auth-wrap[data-active="register"],
body .auth-wrap[data-active="contact"] {
  width: 100% !important;
  max-width: none !important;
}

html body.site-theme-chatmee-retro main.page > .auth-wrap[data-active="login"],
html body.site-theme-chatmee-retro main.page > .auth-wrap[data-active="register"],
html body main.page > .auth-wrap[data-active="login"],
html body main.page > .auth-wrap[data-active="register"],
html body main.page > .auth-lower-stack {
  width: 100% !important;
  max-width: 100% !important;
  margin-right: auto !important;
  margin-left: auto !important;
  box-sizing: border-box !important;
}

html body main.page > .auth-lower-stack > .scroller-shell,
html body main.page > .auth-lower-stack > .login-footer {
  width: 100% !important;
  max-width: 100% !important;
  box-sizing: border-box !important;
}

/* In Registreren staat het logo al in de websiteheader; de tekst begint links. */
body .auth-register .retro-register-logo,
body .auth-register .head > .icon {
  display: none !important;
}

body .auth-register .head {
  display: block !important;
  grid-template-columns: 1fr !important;
  padding-left: 0 !important;
  text-align: left !important;
}

body[data-theme="light"] .contact-marquee,
body[data-theme="light"] .contact-inline-footer,
html[data-chatmee-theme="day"] .scroller-shell,
html[data-chatmee-theme="day"] .login-footer {
  border-color: rgba(57,108,176,.38) !important;
  background: rgba(239,246,255,.92) !important;
  color: #526071 !important;
  text-shadow: none !important;
}

body[data-theme="light"] .contact-inline-footer::before,
html[data-chatmee-theme="day"] .login-footer::before {
  background: rgba(57,108,176,.48) !important;
}

@media (max-width: 620px) {
  body > .auth-site-header + .page,
  html body main {
    width: min(100% - 22px,1180px) !important;
  }

  .scroller-shell,
  .contact-marquee,
  .login-footer,
  .contact-inline-footer {
    width: 100% !important;
  }

  .login-footer,
  .contact-inline-footer {
    border-radius: 10px !important;
  }
}
