@import url(variaveis.css);

*, *::before, *::after {
  padding: 0;
  margin: 0;
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  overflow-x: hidden;
  font-family: "Montserrat", sans-serif;
}

h1, h2 {
  font-family: "Syne", sans-serif;
}

a {
  color: var(--brand-light);
  font-weight: 600;
}

.container {
  display: flex;
  min-height: 100vh;
}

/* ── Seção esquerda ────────────────────────── */
.left-section {
  flex: 1;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  background: radial-gradient(circle, var(--brand-blue-light) 15%, var(--brand-blue-dark) 100%);
}

.content-wrapper {
  flex: 1;
  display: flex;
  flex-direction: column;
  max-width: 900px;

  & h1 {
    font-size: 2.5rem;
    color: white;
    line-height: 1.1;
    margin-bottom: 1.5rem;

    & span:nth-child(1) { color: var(--brand-pink); }
    & span:nth-child(2) { color: var(--brand-yellow); }
  }

  & img { width: 90%; }
}

.subtitle {
  font-size: 1.25rem;
  line-height: 1.25;
  margin-bottom: 2rem;
  color: white;
}

/* ── Seção direita ─────────────────────────── */
.right-section {
  flex: 1;
  padding: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: black;
}

.form-container {
  width: 100%;
  max-width: 580px;
}

.center {
  text-align: center;

  & h2 {
    color: var(--brand-pink);
    font-size: 2rem;
    margin-bottom: 0.5rem;
  }
}

.form-subtitle {
  font-size: 1.125rem;
  color: white;
  margin-bottom: 2.5rem;
}

/* ── Formulário ────────────────────────────── */
.signup-form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

label {
  font-size: 0.875rem;
  color: var(--text-body);
  display: block;
  margin-bottom: 0.5rem;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="tel"],
input[type="date"] {
  appearance: none;
  width: 100%;
  border: 1px solid var(--input-stroke);
  border-radius: 0.5rem;
  background-color: var(--input-base);
  padding: 0.812rem 1rem;
  font-size: 0.95rem;
  color: var(--text-heading);

  &::placeholder { color: var(--input-placeholder); }

  &:focus {
    outline: 2px solid var(--brand-pink);
    outline-offset: 0.1px;
  }
}

input[type="date"] {
  color: var(--input-placeholder);
  text-transform: uppercase;
  background: var(--input-base) url('../../assets/icons/contact.svg') no-repeat right 10px center;
  background-size: 20px 20px;
  padding-right: 40px;

  &::-webkit-calendar-picker-indicator {
    opacity: 0;
    display: none;
  }
}

input[type="checkbox"] {
  width: 1.25rem;
  height: 1.25rem;
  border-radius: 0.25rem;
  padding: 0;
  background-color: var(--input-base);
  cursor: pointer;
  appearance: none;
  border: 1px solid var(--input-stroke);

  &:checked {
    border-color: var(--brand-light);
    background-image: url(../../assets/icons/checked.svg);
    background-repeat: no-repeat;
    background-position: center;
    background-size: 1rem;
  }

  &:focus { outline: none; }
}

.terms {
  margin-top: 1.875rem;
  display: grid;
  gap: 0.75rem;

  & div {
    display: flex;
    gap: 0.75rem;
    align-items: flex-start;
  }

  & span {
    color: var(--text-body);
    font-size: 0.875rem;
    line-height: 1.4;
  }
}

/* ── Botão ─────────────────────────────────── */
.submit-btn {
  border: none;
  padding: 1.5rem 3rem;
  border-radius: 50px;
  font-size: 1rem;
  font-weight: 600;
  margin-top: 2.6875rem;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  background-color: var(--brand-pink);
  color: white;
  cursor: pointer;
  transition: all 0.3s ease;

  &:hover {
    background-color: #e01e86;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
  }

  &:active { transform: translateY(0); }
}

.login-link {
  text-align: center;
  font-size: 0.875rem;
  margin-top: 0.75rem;
  color: white;

  & a { color: var(--brand-pink); }
}

/* ── Erros ─────────────────────────────────── */
.error-message {
  color: var(--danger);
  font-size: 0.75rem;
  margin-top: 0.25rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;

  &::before {
    content: url("../../assets/icons/circle-alert.svg");
    display: inline-block;
    width: 16px;
    height: 16px;
    vertical-align: middle;
  }
}

input.erro {
  outline: 2px solid var(--danger);
}

/* ── Senha ─────────────────────────────────── */
.password-wrapper {
  position: relative;

  & input { padding-right: 2.6rem; }
}

.toggle-password {
  position: absolute;
  right: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  cursor: pointer;
  z-index: 10;
  width: 18px;
  height: 18px;
  object-fit: contain;

  &:focus { outline: none; }
}

/* ── Responsividade ────────────────────────── */
@media (max-width: 1024px) {
  .content-wrapper h1 { font-size: 2.5rem; }
}

@media (max-width: 768px) {
  .container { flex-direction: column; }

  .left-section {
    min-height: 50vh;
    padding: 1.5rem;
    text-align: center;
  }

  .content-wrapper {
    max-width: none;

    & h1 {
      font-size: 2rem;
      margin-bottom: 1rem;
    }
  }

  .subtitle {
    font-size: 1rem;
    margin-bottom: 1rem;
  }

  .right-section { padding: 1.5rem; }

  .form-row { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .left-section { padding: 1rem; }
  .right-section { padding: 1rem; }

  .content-wrapper h1 { font-size: 1.75rem; }

  .submit-btn { padding: 0.875rem 1.5rem; }
}