:root {
  color-scheme: light;
  --paper: #f7f7f5;
  --white: #fff;
  --navy: #111d36;
  --red: #e7473f;
  --muted: #747b85;
  --font-body: "DM Sans", sans-serif;
  --font-display: "Space Grotesk", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
}

body {
  min-height: 100vh;
  margin: 0;
  background: var(--paper);
  color: var(--navy);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

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

.skip-link:not(:focus) {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link:focus {
  position: fixed;
  z-index: 5;
  top: 12px;
  left: 12px;
  padding: 12px 16px;
  background: var(--white);
}

.auth-header {
  position: relative;
  z-index: 2;
  display: flex;
  height: 80px;
  align-items: center;
  justify-content: space-between;
  padding: 0 7%;
  background: var(--paper);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.brand__mark {
  display: grid;
  width: 37px;
  height: 37px;
  place-items: center;
  border: 1.5px solid var(--navy);
  border-radius: 50%;
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: -.08em;
}

.brand__mark span {
  color: var(--red);
}

.brand__name {
  display: grid;
  gap: 2px;
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .07em;
  line-height: 1.1;
}

.brand__name span {
  color: #7e8490;
  font-size: 8px;
  letter-spacing: .18em;
}

.back-link {
  color: #69717d;
  font-size: 11px;
  transition: color .2s ease;
}

.back-link:hover {
  color: var(--red);
}

.back-link span {
  margin-right: 5px;
}

.auth-layout {
  display: grid;
  min-height: calc(100vh - 80px);
  grid-template-columns: 1fr 1fr;
  padding: 24px 7% 48px;
}

.auth-visual {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 600px;
  padding: 9%;
  overflow: hidden;
  background: var(--red);
  animation: fade-in .7s both;
}

.auth-visual::before,
.auth-visual::after {
  position: absolute;
  width: 450px;
  height: 450px;
  border: 1px solid rgb(255 255 255 / 18%);
  border-radius: 50%;
  content: "";
  pointer-events: none;
}

.auth-visual::before {
  top: -200px;
  right: -155px;
}

.auth-visual::after {
  right: -195px;
  bottom: -285px;
  width: 540px;
  height: 540px;
  border-color: rgb(255 255 255 / 12%);
}

.auth-visual__mark {
  position: relative;
  z-index: 1;
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border: 1.5px solid rgb(255 255 255 / 72%);
  border-radius: 50%;
  color: white;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: -.08em;
}

.auth-visual__mark span {
  color: var(--navy);
}

.auth-visual__message {
  position: relative;
  z-index: 1;
}

.auth-visual__brand {
  display: inline-block;
  color: var(--white);
  font-family: var(--font-display);
  font-size: clamp(24px, 3vw, 43px);
  font-weight: 600;
  letter-spacing: -.06em;
}

.auth-visual__brand span {
  color: var(--navy);
}

.auth-visual__eyebrow {
  margin: 0 0 17px;
  color: rgb(255 255 255 / 84%);
  font-size: 8px;
  font-weight: 700;
  letter-spacing: .16em;
}

.auth-visual__description {
  max-width: 280px;
  margin: 17px 0 0;
  color: rgb(255 255 255 / 84%);
  font-size: 11px;
  line-height: 1.8;
}

.auth-visual__caption {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 9px;
  color: rgb(255 255 255 / 82%);
  font-size: 8px;
  font-weight: 600;
  letter-spacing: .16em;
}

.auth-visual__caption span {
  width: 22px;
  height: 1px;
  background: var(--red);
}

.auth-content {
  display: grid;
  min-height: 600px;
  place-items: center;
  padding: 44px 9%;
  background: var(--white);
  animation: fade-in .7s .08s both;
}

.auth-card {
  width: min(100%, 380px);
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 0 0 18px;
  color: var(--red);
  font-size: 8px;
  font-weight: 700;
  letter-spacing: .14em;
}

.eyebrow span {
  width: 20px;
  height: 1px;
  background: currentColor;
}

.auth-card h1 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(34px, 3.5vw, 47px);
  font-weight: 600;
  letter-spacing: -.065em;
  line-height: 1.08;
}

.auth-card h1 span {
  color: var(--red);
}

.auth-intro {
  margin: 12px 0 27px;
  color: var(--muted);
  font-size: 11px;
}

.auth-tabs {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin-bottom: 22px;
  border-bottom: 1px solid #e9e9e7;
}

.auth-tabs::after {
  position: absolute;
  bottom: -1px;
  left: 0;
  width: 50%;
  height: 2px;
  background: var(--red);
  content: "";
  transition: transform .25s cubic-bezier(.2, .7, .2, 1);
}

.auth-tabs[data-mode="criar-conta"]::after {
  transform: translateX(100%);
}

.auth-tab {
  min-height: 39px;
  padding: 0 5px 12px;
  border: 0;
  background: transparent;
  color: #8a9099;
  cursor: pointer;
  font-size: 10px;
  font-weight: 600;
  transition: color .2s ease;
}

.auth-tab[aria-selected="true"] {
  color: var(--navy);
}

.auth-tab:focus-visible,
.submit-button:focus-visible,
.back-link:focus-visible,
.brand:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 4px;
}

.auth-form-panel[hidden] {
  display: none;
}

.auth-form-panel.is-active {
  animation: form-in .32s ease both;
}

.auth-form {
  display: grid;
  gap: 14px;
}

.form-field {
  display: grid;
  gap: 7px;
  color: #485365;
  font-size: 9px;
  font-weight: 600;
}

.form-field input {
  width: 100%;
  height: 45px;
  padding: 0 13px;
  border: 1px solid #e5e7e8;
  border-radius: 3px;
  outline: none;
  background: #fff;
  color: var(--navy);
  font-size: 11px;
  font-weight: 400;
  transition: border-color .2s ease, box-shadow .2s ease;
}

.form-field input::placeholder {
  color: #a4a9b0;
}

.form-field input:focus {
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgb(17 29 54 / 6%);
}

.form-field input:user-invalid {
  border-color: var(--red);
}

.submit-button {
  display: flex;
  min-height: 46px;
  align-items: center;
  justify-content: space-between;
  margin-top: 5px;
  padding: 0 15px;
  border: 0;
  border-radius: 3px;
  background: var(--navy);
  color: var(--white);
  cursor: pointer;
  font-size: 10px;
  font-weight: 700;
  transition: background .2s ease, transform .2s ease;
}

.submit-button:hover {
  transform: translateY(-1px);
  background: var(--red);
}

.form-message {
  min-height: 16px;
  margin: 12px 0 0;
  color: var(--red);
  font-size: 9px;
  line-height: 1.5;
}

.auth-footnote {
  margin: 4px 0 0;
  color: #9298a1;
  font-size: 8px;
  line-height: 1.7;
}

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes form-in {
  from { opacity: 0; transform: translateY(5px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 760px) {
  .auth-header {
    height: 70px;
    padding: 0 5%;
  }

  .auth-layout {
    min-height: calc(100vh - 70px);
    grid-template-columns: 1fr;
    padding: 10px 5% 30px;
  }

  .auth-visual {
    display: none;
  }

  .auth-content {
    min-height: min(620px, calc(100vh - 110px));
    padding: 34px 7%;
  }

  .auth-card {
    width: min(100%, 390px);
  }
}

@media (max-width: 380px) {
  .auth-header {
    padding-right: 4%;
    padding-left: 4%;
  }

  .brand__name {
    font-size: 9px;
  }

  .brand__name span {
    font-size: 7px;
  }

  .back-link {
    font-size: 10px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}
