@import url("https://fonts.googleapis.com/css2?family=Cormorant+Garamond:wght@500;600;700&family=Cinzel:wght@400;500&family=DM+Sans:wght@300;400;500;700&display=swap");

:root {
  --ink: #0e1a2b;
  --muted: #667085;
  --line: rgba(245, 230, 200, 0.24);
  --paper: #faf7f1;
  --surface: rgba(255, 255, 255, 0.92);
  --navy: #071a31;
  --navy-2: #0e2340;
  --navy-3: #1a3a5c;
  --gold: #c9973a;
  --gold-soft: #f5e6c8;
  --teal: #48d6c3;
  --purple: #7c6dd8;
  --rose: #b9445a;
  --shadow: 0 28px 80px rgba(0, 0, 0, 0.26);
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--paper);
  background:
    radial-gradient(circle at 18% 16%, rgba(72, 214, 195, 0.12), transparent 28%),
    radial-gradient(circle at 82% 12%, rgba(201, 151, 58, 0.18), transparent 22%),
    linear-gradient(135deg, #04101f, var(--navy) 52%, #0b213d);
  font-family: "DM Sans", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body::before {
  position: fixed;
  inset: 0;
  pointer-events: none;
  content: "";
  background:
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.035) 0 1px, transparent 1px 92px),
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.026) 0 1px, transparent 1px 92px);
  mask-image: radial-gradient(circle at center, black, transparent 76%);
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
}

h1,
h2,
h3,
.brand-name strong {
  font-family: "Cormorant Garamond", Georgia, "Times New Roman", serif;
}

.auth-shell {
  position: relative;
  z-index: 2;
  display: grid;
  min-height: 100vh;
  padding: 32px;
}

.access-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(360px, 440px);
  gap: 32px;
  align-items: center;
  width: min(1180px, 100%);
  margin: auto;
}

.brand-panel,
.form-card,
.register-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.brand-panel {
  display: grid;
  min-height: 520px;
  align-content: center;
  padding: 34px;
  overflow: hidden;
  border-color: rgba(245, 230, 200, 0.1);
  background: rgba(7, 26, 49, 0.26);
  box-shadow: none;
  backdrop-filter: blur(2px);
}

.brand-heading {
  display: flex;
  align-items: center;
  gap: 16px;
}

.brand-mark {
  display: grid;
  width: 76px;
  height: 76px;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(245, 230, 200, 0.26);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  box-shadow: 0 0 34px rgba(201, 151, 58, 0.24);
}

.brand-mark img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.brand-name {
  display: grid;
  gap: 2px;
}

.brand-name strong {
  color: var(--gold-soft);
  font-size: clamp(2rem, 4vw, 4rem);
  line-height: 0.92;
}

.brand-name span {
  color: rgba(250, 247, 241, 0.76);
  font-family: "Cinzel", Georgia, serif;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.brand-copy {
  max-width: 620px;
  margin: 36px 0 0;
}

.brand-copy h1 {
  margin: 0;
  color: #ffffff;
  font-size: clamp(3.2rem, 7vw, 7.6rem);
  line-height: 0.95;
  text-shadow: 0 18px 70px rgba(0, 0, 0, 0.45);
}

.brand-copy p,
.muted {
  color: rgba(250, 247, 241, 0.74);
  line-height: 1.65;
}

.welcome-line {
  margin: 0 0 8px;
  color: var(--gold-soft) !important;
  font-family: "Cinzel", Georgia, serif;
  font-size: clamp(0.9rem, 1.5vw, 1.15rem);
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.network-map {
  position: relative;
  min-height: 330px;
  margin-top: 20px;
  border: 1px solid rgba(201, 151, 58, 0.18);
  border-radius: var(--radius);
  background: #061426;
  overflow: hidden;
}

.network-map-image {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 330px;
  object-fit: contain;
  object-position: center;
}

.form-card {
  padding: 26px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(18px);
}

.form-card header {
  margin-bottom: 20px;
}

.form-card h2,
.register-panel h1 {
  margin: 0 0 8px;
  color: var(--navy-2);
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1;
}

.form-card p,
.register-panel p,
.field-hint {
  color: var(--muted);
  line-height: 1.55;
}

.auth-form,
.register-form,
.field-grid,
.conditional-panel {
  display: grid;
  gap: 14px;
}

label,
.field-group {
  display: grid;
  gap: 7px;
  color: var(--ink);
  font-weight: 800;
}

input,
select,
textarea {
  width: 100%;
  min-height: 46px;
  border: 1px solid #d8cfbf;
  border-radius: var(--radius);
  padding: 11px 12px;
  color: var(--ink);
  background: #ffffff;
  outline: 0;
}

textarea {
  min-height: 104px;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(201, 151, 58, 0.18);
}

.field-error {
  border-color: var(--rose) !important;
  box-shadow: 0 0 0 3px rgba(185, 68, 90, 0.14) !important;
}

.primary-button,
.secondary-button,
.text-button {
  min-height: 44px;
  border-radius: var(--radius);
  cursor: pointer;
}

.primary-button {
  display: inline-grid;
  place-items: center;
  border: 0;
  color: #ffffff;
  background: linear-gradient(145deg, var(--gold), #9d6c1e);
  font-weight: 900;
  text-align: center;
  text-decoration: none;
}

.secondary-button {
  display: inline-grid;
  place-items: center;
  border: 1px solid #d8cfbf;
  color: var(--navy-2);
  background: #ffffff;
  font-weight: 800;
  text-align: center;
  text-decoration: none;
}

.text-button {
  border: 0;
  padding: 0;
  color: var(--navy-2);
  background: transparent;
  font-weight: 900;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.form-actions,
.link-row {
  display: grid;
  gap: 10px;
}

.link-row {
  justify-items: start;
  margin-top: 6px;
}

.divider {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 12px;
  align-items: center;
  color: var(--muted);
  font-size: 0.88rem;
}

.divider::before,
.divider::after {
  height: 1px;
  background: #ded7c9;
  content: "";
}

.modal {
  width: min(460px, calc(100vw - 28px));
  border: 0;
  border-radius: var(--radius);
  padding: 0;
  color: var(--ink);
  box-shadow: var(--shadow);
}

.modal::backdrop {
  background: rgba(4, 16, 31, 0.68);
}

.modal-card {
  display: grid;
  gap: 14px;
  padding: 22px;
  background: #ffffff;
}

.modal-card header,
.modal-card menu {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin: 0;
  padding: 0;
}

.icon-button {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 1px solid #d8cfbf;
  border-radius: 50%;
  background: #ffffff;
  cursor: pointer;
}

.feedback {
  display: none;
  padding: 12px;
  border-radius: var(--radius);
  color: var(--navy-2);
  background: var(--gold-soft);
  line-height: 1.5;
}

.feedback.show {
  display: block;
}

.feedback.error {
  color: #7f1d1d;
  background: #fee2e2;
}

.register-layout {
  display: grid;
  width: min(1180px, 100%);
  margin: auto;
  gap: 22px;
}

.register-header {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 18px;
  align-items: center;
}

.register-brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.register-brand .brand-mark {
  width: 62px;
  height: 62px;
}

.register-panel {
  padding: 26px;
  color: var(--ink);
  background: var(--surface);
  backdrop-filter: blur(18px);
}

.register-intro {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 420px);
  gap: 22px;
  align-items: center;
}

.register-intro .network-map {
  min-height: 230px;
  margin: 0;
}

.register-intro .network-map-image {
  min-height: 230px;
}

.type-switch {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 18px 0 20px;
}

.type-option {
  position: relative;
}

.type-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.type-option span {
  display: grid;
  min-height: 58px;
  place-items: center;
  border: 1px solid #d8cfbf;
  border-radius: var(--radius);
  padding: 10px;
  color: var(--navy-2);
  background: #ffffff;
  font-weight: 900;
  text-align: center;
}

.type-option input:checked + span {
  color: #ffffff;
  border-color: var(--navy-2);
  background: var(--navy-2);
}

.field-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.field-grid .full,
.form-section,
.consent-row {
  grid-column: 1 / -1;
}

.form-section {
  display: grid;
  gap: 14px;
  margin-top: 8px;
  padding-top: 18px;
  border-top: 1px solid #e7dece;
}

.form-section h2 {
  margin: 0;
  color: var(--navy-2);
  font-size: 1.45rem;
}

.checkbox-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.checkbox-grid label,
.consent-row {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  font-weight: 700;
}

.checkbox-grid input,
.consent-row input {
  width: auto;
  min-height: 0;
  margin-top: 4px;
}

.orientation-box {
  grid-column: 1 / -1;
  padding: 14px;
  border: 1px solid rgba(72, 214, 195, 0.34);
  border-radius: var(--radius);
  color: var(--navy-2);
  background: rgba(72, 214, 195, 0.12);
  line-height: 1.55;
}

.hidden {
  display: none !important;
}

.success-actions {
  display: none;
  margin-top: 12px;
}

.success-actions.show {
  display: block;
}

.login-transition {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  padding: 28px;
  color: #ffffff;
  text-align: center;
  background:
    radial-gradient(circle at 50% 42%, rgba(201, 151, 58, 0.28), transparent 24%),
    linear-gradient(135deg, rgba(4, 16, 31, 0.94), rgba(7, 26, 49, 0.98));
  opacity: 0;
  pointer-events: none;
  transform: scale(1.02);
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.login-transition.show {
  opacity: 1;
  transform: scale(1);
}

.login-transition div,
.login-transition p,
.login-transition strong {
  grid-area: 1 / 1;
}

.transition-light {
  width: min(38vw, 220px);
  aspect-ratio: 1;
  border-radius: 50%;
  background:
    radial-gradient(circle, #fff9dc 0 4%, var(--gold) 5% 9%, rgba(201, 151, 58, 0.3) 10% 28%, transparent 62%);
  box-shadow:
    0 0 42px rgba(201, 151, 58, 0.78),
    0 0 130px rgba(72, 214, 195, 0.28);
  animation: lightIgnites 1.8s ease forwards;
}

.login-transition p {
  align-self: end;
  width: min(720px, 100%);
  margin: 0 0 92px;
  color: var(--gold-soft);
  font-family: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  font-size: clamp(2rem, 5vw, 4.5rem);
  line-height: 1;
  opacity: 0;
  animation: transitionText 1.4s ease 0.35s forwards;
}

.login-transition strong {
  align-self: end;
  width: min(620px, 100%);
  margin: 0 0 26px;
  color: rgba(250, 247, 241, 0.86);
  font-size: clamp(1rem, 2vw, 1.28rem);
  line-height: 1.5;
  opacity: 0;
  animation: transitionText 1.4s ease 0.72s forwards;
}

@keyframes lightIgnites {
  0% {
    opacity: 0;
    transform: scale(0.2);
  }
  58% {
    opacity: 1;
    transform: scale(1.12);
  }
  100% {
    opacity: 0.72;
    transform: scale(1);
  }
}

@keyframes transitionText {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 940px) {
  .auth-shell {
    padding: 18px;
  }

  .access-layout,
  .register-intro,
  .register-header {
    grid-template-columns: 1fr;
  }

  .brand-panel {
    min-height: auto;
  }

  .network-map,
  .network-map-image {
    min-height: 240px;
  }

  .type-switch,
  .field-grid,
  .checkbox-grid {
    grid-template-columns: 1fr;
  }

  .register-header {
    align-items: start;
  }
}

@media (max-width: 560px) {
  .auth-shell {
    padding: 12px;
  }

  .brand-panel,
  .form-card,
  .register-panel {
    padding: 18px;
  }

  .brand-heading,
  .register-brand {
    align-items: flex-start;
  }

  .brand-mark {
    width: 62px;
    height: 62px;
  }

  .brand-copy h1 {
    font-size: 2.5rem;
  }

  .support-custom div,
  .modal-card menu {
    display: grid;
    grid-template-columns: 1fr;
  }
}

/* Visual integrado de acesso e cadastro */
body[data-auth-page="login"],
body[data-auth-page="cadastro"] {
  color: var(--ink);
  background: #173e6e;
}

body[data-auth-page="login"]::before,
body[data-auth-page="cadastro"]::before {
  z-index: 0;
  background: linear-gradient(180deg, rgba(255,255,255,0.2), transparent 42%);
  mask-image: none;
}

body[data-auth-page="login"]::after,
body[data-auth-page="cadastro"]::after {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  content: "";
  background: linear-gradient(180deg, rgba(255,255,255,0.12), transparent 46%);
  opacity: 1;
}

.auth-map-shell,
body[data-auth-page="cadastro"] .auth-shell {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  padding: 36px 20px;
}

.auth-home-link {
  position: fixed;
  z-index: 3;
  top: 22px;
  left: 24px;
  color: rgba(255,255,255,0.78);
  font-size: 0.8rem;
  text-decoration: none;
}

.auth-home-link:hover { color: #fff; }

.auth-center {
  display: grid;
  width: min(360px, 100%);
  margin: auto;
  gap: 12px;
}

.auth-identity {
  display: grid;
  justify-items: center;
  gap: 7px;
  color: #fff;
  text-decoration: none;
}

.auth-identity img {
  display: block;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 12px 32px rgba(2, 15, 35, 0.35);
}

.auth-identity span {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 0.86rem;
  font-style: italic;
}

.compact-login {
  padding: 22px;
  border-color: rgba(255,255,255,0.56);
  background: rgba(255,255,255,0.96);
  box-shadow: 0 20px 60px rgba(2, 15, 35, 0.26);
}

.compact-login header {
  margin-bottom: 16px;
  text-align: center;
}

.compact-login header h1,
.register-intro h1 {
  margin: 0 0 4px;
  color: var(--navy-2);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.55rem;
  line-height: 1.1;
}

.compact-login header p,
.register-intro p {
  margin: 0;
  color: var(--muted);
  font-size: 0.78rem;
}

.compact-login label,
.register-form label,
.register-form .field-group {
  font-size: 0.78rem;
  font-weight: 500;
}

.compact-login input,
.register-form input,
.register-form select,
.register-form textarea {
  min-height: 38px;
  padding: 8px 10px;
  border-color: #cad5e2;
  border-radius: 8px;
  font-size: 0.82rem;
  background: #fff;
}

.label-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.inline-link {
  border: 0;
  padding: 0;
  color: #198754;
  background: transparent;
  cursor: pointer;
  font-size: 0.72rem;
}

.compact-login .primary-button,
.register-form .primary-button {
  color: #fff;
  background: #173d72;
  font-weight: 600;
}

.compact-login .primary-button:hover,
.register-form .primary-button:hover { background: #102f5b; }

.compact-login .secondary-button,
.register-form .secondary-button {
  color: #173d72;
  border-color: #cad5e2;
  font-weight: 500;
}

.google-button { width: 100%; }
.google-button span { color: #4285f4; font-weight: 700; }

.register-prompt {
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 0.72rem;
  text-align: center;
}
.register-prompt a { color: #173d72; font-weight: 700; text-decoration: none; }

.register-center {
  width: min(620px, 100%);
  margin: auto;
  gap: 0;
}

.register-header {
  display: flex;
  justify-content: center;
  margin-bottom: 12px;
}

.register-brand.auth-identity { gap: 6px; }
.register-brand.auth-identity img { width: 62px; height: 62px; }

.register-panel {
  padding: 22px 24px;
  border-color: rgba(255,255,255,0.55);
  background: rgba(255,255,255,0.97);
  box-shadow: 0 20px 60px rgba(2, 15, 35, 0.24);
}

.register-intro {
  display: block;
  border-bottom: 0;
  border-radius: 8px 8px 0 0;
  padding-bottom: 8px;
  text-align: center;
}

.register-intro + .register-panel {
  border-top: 0;
  border-radius: 0 0 8px 8px;
  padding-top: 10px;
}

.registration-type-picker > span {
  font-size: 0.75rem;
  font-weight: 600;
}

.type-switch {
  gap: 8px;
  margin: 4px 0 8px;
}

.type-option span {
  min-height: 98px;
  align-content: center;
  justify-items: start;
  gap: 3px;
  border-color: #cad5e2;
  border-radius: 8px;
  padding: 12px;
  text-align: left;
}

.type-option span b { color: #173d72; font-size: 1rem; }
.type-option span strong { font-size: 0.78rem; }
.type-option span small { color: var(--muted); font-size: 0.66rem; font-weight: 400; }
.type-option input:checked + span { color: #173d72; border-color: #173d72; background: #edf3fa; box-shadow: 0 0 0 2px rgba(23,61,114,0.08); }
.type-option input:checked + span small { color: #53667e; }

.registration-note {
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 0.68rem;
  line-height: 1.45;
}

.registration-continue { width: 100%; }
.registration-continue:disabled { color: #77869a; background: #e6edf5; cursor: not-allowed; }

.registration-progress {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 12px;
  align-items: center;
  margin-bottom: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid #dce4ed;
}

.step-back {
  width: 34px;
  height: 34px;
  border: 1px solid #cad5e2;
  border-radius: 50%;
  color: #173d72;
  background: #fff;
  cursor: pointer;
}

.registration-progress div:nth-child(2) { display: grid; gap: 1px; }
.registration-progress span { color: var(--muted); font-size: 0.66rem; }
.registration-progress strong { color: #173d72; font-family: "Cormorant Garamond", Georgia, serif; font-size: 1.2rem; }
.progress-dots { display: flex; gap: 5px; }
.progress-dots span { width: 22px; height: 4px; border-radius: 4px; background: #dce4ed; }
.progress-dots span.active { background: #c9973a; }

.register-form > .form-section { border-top: 0; padding-top: 0; }
.register-form .form-section h2 { color: #173d72; font-size: 1.15rem; }
.register-form .form-section .form-section { padding-top: 14px; }
.registration-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 8px; }
.registration-actions button { min-width: 120px; }
.register-login-link { margin: 12px auto 0; color: rgba(255,255,255,0.82); font-size: 0.76rem; text-decoration: none; }

@media (max-width: 680px) {
  body[data-auth-page="login"]::after,
  body[data-auth-page="cadastro"]::after {
    background-size: 920px auto;
    opacity: 0.42;
  }
  .auth-map-shell,
  body[data-auth-page="cadastro"] .auth-shell { padding: 68px 14px 28px; }
  .auth-home-link { top: 16px; left: 16px; }
  .register-panel { padding: 18px; }
  .type-switch { grid-template-columns: 1fr; }
  .type-option span { min-height: 74px; }
  .field-grid, .checkbox-grid { grid-template-columns: 1fr; }
  .registration-actions { display: grid; grid-template-columns: 1fr; }
  .registration-actions button { width: 100%; }
}

/* Cadastro 2.0 */
.registration-shell {
  align-items: flex-start;
  padding-block: 24px 44px;
}

.register-v2 {
  padding: 18px 20px 20px;
  border-radius: 8px;
}

.register-v2-heading {
  margin-bottom: 10px;
  text-align: center;
}

.register-v2-heading h1 {
  margin: 0 0 3px;
  color: var(--navy-2);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.5rem;
  line-height: 1.1;
}

.register-v2-heading p {
  margin: 0;
  color: var(--muted);
  font-size: 0.72rem;
}

.institutional-profile-notice {
  display: grid;
  gap: 3px;
  margin: 12px 0 16px;
  padding: 11px 13px;
  border: 1px solid rgba(33, 134, 91, 0.28);
  border-left: 4px solid #21865b;
  border-radius: 8px;
  color: var(--navy-2);
  background: #f2f8f5;
}

.institutional-profile-notice strong {
  font-size: 0.8rem;
}

.institutional-profile-notice p {
  margin: 0;
  color: var(--muted);
  font-size: 0.73rem;
  line-height: 1.45;
}

.register-v2 .register-form {
  gap: 12px;
}

.register-v2 .profile-fields,
.register-v2 .shared-fields {
  display: grid;
  gap: 10px;
  padding: 0;
  border: 0;
}

.register-v2 .profile-fields.hidden {
  display: none;
}

.register-v2 .form-section h2,
.register-v2 .pix-section h2 {
  margin: 4px 0 0;
  color: #1d7a58;
  font-family: Inter, Arial, sans-serif;
  font-size: 0.74rem;
  font-weight: 600;
}

.register-v2 .field-grid {
  gap: 8px 10px;
}

.register-v2 label,
.register-v2 .field-group > span,
.register-v2 legend {
  color: #20314a;
  font-size: 0.71rem;
}

.register-v2 label {
  position: relative;
}

.register-v2 label em {
  display: none;
}

.register-v2 label:has(> input[required], > textarea[required], > select[required])::after {
  content: "*";
  position: absolute;
  top: 0;
  right: 0;
  color: #df4b43;
}

.register-v2 .optional {
  position: absolute;
  top: 0;
  right: 0;
  color: #758196;
  font-size: 0.66rem;
  font-weight: 400;
}

.register-v2 .consent-row::after,
.register-v2 .pix-key-types label::after {
  display: none;
}

.register-v2 input,
.register-v2 select,
.register-v2 textarea {
  min-height: 32px;
  border-color: #cbd8e7;
  border-radius: 8px;
  padding: 6px 9px;
  font-size: 0.75rem;
}

.register-v2 textarea {
  min-height: 58px;
  resize: vertical;
}

.register-v2 input:focus,
.register-v2 select:focus,
.register-v2 textarea:focus {
  border-color: #315b90;
  box-shadow: 0 0 0 3px rgba(49, 91, 144, 0.1);
}

.register-v2 input.field-loading {
  background-image: linear-gradient(90deg, #fff, #edf3f8, #fff);
  background-size: 220% 100%;
  animation: fieldLoading 1s linear infinite;
}

@keyframes fieldLoading {
  to { background-position: -220% 0; }
}

.register-v2 .checkbox-grid {
  gap: 6px;
}

.register-v2 .checkbox-grid label {
  min-height: 34px;
  align-items: center;
  border-color: #d4dfeb;
  border-radius: 8px;
  padding: 7px 9px;
  background: #fff;
}

.register-v2 .checkbox-grid input {
  width: 14px;
  min-height: 14px;
}

.pix-section {
  display: grid;
  gap: 8px;
}

.pix-section > p,
.pix-section > small {
  margin: 0;
  color: #66758a;
  font-size: 0.68rem;
  line-height: 1.45;
}

.pix-key-types {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0;
  border: 0;
  padding: 0;
}

.pix-key-types legend {
  width: 100%;
  margin-bottom: 2px;
}

.pix-key-types label {
  position: relative;
}

.pix-key-types input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.pix-key-types label {
  border: 1px solid #cbd8e7;
  border-radius: 999px;
  padding: 4px 9px;
  color: #53647a;
  background: #fff;
  cursor: pointer;
}

.pix-key-types label:has(input:checked) {
  color: #fff;
  border-color: #173d72;
  background: #173d72;
}

.file-field input {
  padding: 4px;
  background: #f8fafc;
}

.privacy-notice {
  display: grid;
  grid-template-columns: 18px 1fr;
  gap: 7px;
  align-items: start;
  border: 1px solid #c8dfd4;
  border-radius: 8px;
  padding: 10px;
  color: #527064;
  background: #f3faf7;
}

.privacy-notice p {
  margin: 0;
  font-size: 0.68rem;
  line-height: 1.5;
}

.consent-row {
  display: grid !important;
  grid-template-columns: 16px 1fr;
  gap: 7px;
  align-items: start;
  border: 1px solid #d4dfeb;
  border-radius: 8px;
  padding: 10px;
  background: #f8fafc;
}

.consent-row input {
  width: 14px;
  min-height: 14px;
  margin-top: 1px;
}

.consent-row a {
  color: #173d72;
}

.registration-submit {
  width: 100%;
}

.registration-submit:disabled {
  color: #eef2f7;
  background: #96a6bd;
  cursor: wait;
}

.register-v2 .form-feedback {
  margin-top: 0;
}

.register-v2 .success-actions {
  margin-top: 0;
}

@media (max-width: 680px) {
  .registration-shell {
    padding: 62px 8px 28px;
  }

  .register-header {
    margin-bottom: 8px;
  }

  .register-brand.auth-identity img {
    width: 52px;
    height: 52px;
  }

  .register-v2 {
    padding: 16px 10px;
  }

  .register-v2 .type-switch {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .register-v2 .type-option span {
    min-height: 84px;
    padding: 8px;
  }

  .register-v2 .type-option span strong {
    font-size: 0.7rem;
  }

  .register-v2 .type-option span small {
    font-size: 0.6rem;
  }

  .register-v2 .field-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .register-v2 .checkbox-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .register-v2 .field-grid .full,
  .register-v2 .field-group.full {
    grid-column: 1 / -1;
  }
}

@media (max-width: 420px) {
  .register-v2 .field-grid {
    grid-template-columns: 1fr;
  }

  .register-v2 .field-grid > * {
    grid-column: 1;
  }
}

.security-primary-link {
  display: none;
  margin-top: 16px;
  text-align: center;
  text-decoration: none;
}

.security-primary-link.show {
  display: block;
}

.security-resend-form {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid #d7dfeb;
}
