*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --gold: #C9A84C;
  --gold-light: #E8C97A;
  --gold-dark: #8B6914;
  --cream: #F5F0E8;
  --off-white: #FAF8F4;
  --charcoal: #1A1A1A;
  --charcoal-mid: #2C2C2C;
  --charcoal-light: #3D3D3D;
  --text-muted: #7A7A7A;
}

html { height: 100%; }

body {
  font-family: 'Montserrat', sans-serif;
  background: var(--charcoal);
  display: flex;
  min-height: 100vh;
  overflow-x: hidden;
}

/* ════════════════════════════
   DESKTOP — lado a lado
════════════════════════════ */
.panel-left {
  width: 42%;
  flex-shrink: 0;
  background: var(--charcoal);
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 60px 48px;
  overflow: hidden;
}

.panel-left::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(45deg, transparent, transparent 40px, rgba(201,168,76,0.03) 40px, rgba(201,168,76,0.03) 41px),
    repeating-linear-gradient(-45deg, transparent, transparent 40px, rgba(201,168,76,0.03) 40px, rgba(201,168,76,0.03) 41px);
}

.panel-left::after {
  content: '';
  position: absolute;
  right: 0; top: 8%; bottom: 8%;
  width: 1px;
  background: linear-gradient(to bottom, transparent, var(--gold), transparent);
  opacity: 0.35;
}

.brand-area {
  position: relative;
  z-index: 1;
  text-align: center;
  animation: fadeUp 0.9s ease both;
}

.logo-wrap {
  width: 240px;
  margin: 0 auto 32px;
}

.logo-wrap img {
  width: 100%;
  display: block;
}

.divider-ornament {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0 auto 20px;
  width: 240px;
}

.divider-ornament span {
  flex: 1;
  height: 1px;
}

.divider-ornament span:first-child {
  background: linear-gradient(to right, transparent, var(--gold));
}

.divider-ornament span:last-child {
  background: linear-gradient(to left, transparent, var(--gold));
}

.divider-ornament i {
  color: var(--gold);
  font-size: 9px;
  letter-spacing: 4px;
  font-style: normal;
}

.tagline {
  font-family: 'Cormorant Garamond', serif;
  font-size: 14px;
  font-weight: 300;
  font-style: italic;
  color: var(--gold-light);
  letter-spacing: 2.5px;
  text-transform: uppercase;
  margin-bottom: 40px;
  opacity: 0.85;
}

.benefits-list {
  list-style: none;
  text-align: left;
  width: 240px;
  margin: 0 auto;
}

.benefits-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px solid rgba(201,168,76,0.1);
  color: rgba(255,255,255,0.68);
  font-size: 12px;
  font-weight: 300;
  letter-spacing: 0.4px;
}

.benefits-list li:last-child { border-bottom: none; }

.benefit-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--gold);
  flex-shrink: 0;
}

/* ════════════════════════════
   RIGHT / FORM PANEL
════════════════════════════ */
.panel-right {
  flex: 1;
  background: var(--off-white);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 60px 64px;
  position: relative;
  min-height: 100vh;
}

.panel-right::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: linear-gradient(to right, var(--gold-dark), var(--gold), var(--gold-light), var(--gold));
}

/* Logo inside form panel — hidden on desktop */
.mobile-logo-header {
  display: none;
}

.form-header {
  margin-bottom: 36px;
  animation: fadeUp 0.9s 0.1s ease both;
}

.form-header h1 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 36px;
  font-weight: 600;
  color: var(--charcoal);
  line-height: 1.15;
  margin-bottom: 8px;
}

.form-header h1 em {
  color: var(--gold-dark);
  font-style: italic;
}

.form-header p {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 400;
  letter-spacing: 0.3px;
}

.form-group {
  margin-bottom: 20px;
  animation: fadeUp 0.9s ease both;
}

.form-group:nth-child(1) { animation-delay: 0.2s; }
.form-group:nth-child(2) { animation-delay: 0.28s; }

.form-group label {
  display: block;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 1.8px;
  text-transform: uppercase;
  color: var(--charcoal-light);
  margin-bottom: 8px;
}

.input-wrap { position: relative; }

.input-wrap > svg {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  color: var(--text-muted);
  pointer-events: none;
  transition: color 0.2s;
}

.input-wrap input {
  width: 100%;
  height: 52px;
  padding: 0 50px 0 46px;
  border: 1.5px solid #E0DAD0;
  border-radius: 4px;
  background: #fff;
  font-family: 'Montserrat', sans-serif;
  font-size: 14px;
  font-weight: 400;
  color: var(--charcoal);
  transition: border-color 0.25s, box-shadow 0.25s;
  outline: none;
  -webkit-appearance: none;
}

.input-wrap input::placeholder {
  color: #C0BAB0;
  font-weight: 300;
  font-size: 13px;
}

.input-wrap input:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(201,168,76,0.12);
}

.input-wrap:focus-within > svg { color: var(--gold-dark); }

.toggle-pw {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  -webkit-tap-highlight-color: transparent;
  transition: color 0.2s;
}

.toggle-pw:hover { color: var(--gold-dark); }

.forgot {
  display: block;
  text-align: right;
  font-size: 11.5px;
  color: var(--text-muted);
  text-decoration: none;
  margin-top: 9px;
  transition: color 0.2s;
  -webkit-tap-highlight-color: transparent;
}

.forgot:hover, .forgot:active { color: var(--gold-dark); }

.error-msg {
  display: none;
  font-size: 11px;
  color: #b94a2c;
  margin-top: 6px;
  font-weight: 500;
}

.error-msg.visible { display: block; }
.input-wrap input.error { border-color: #d4614a; }

.btn-login {
  width: 100%;
  height: 54px;
  background: var(--charcoal);
  color: var(--gold-light);
  border: none;
  border-radius: 4px;
  font-family: 'Montserrat', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  margin-top: 6px;
  transition: background 0.25s, transform 0.15s;
  animation: fadeUp 0.9s 0.36s ease both;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

.btn-login:hover { background: var(--charcoal-mid); }
.btn-login:active { transform: scale(0.99); }

.btn-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.gold-divider {
  height: 1px;
  background: linear-gradient(to right, transparent, var(--gold), transparent);
  margin: 28px 0;
  animation: fadeUp 0.9s 0.44s ease both;
}

.register-area {
  text-align: center;
  animation: fadeUp 0.9s 0.5s ease both;
}

.register-area p {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 14px;
}

.btn-register {
  display: inline-block;
  padding: 14px 36px;
  border: 1.5px solid var(--gold);
  border-radius: 4px;
  background: transparent;
  font-family: 'Montserrat', sans-serif;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--gold-dark);
  cursor: pointer;
  text-decoration: none;
  transition: all 0.25s;
  -webkit-tap-highlight-color: transparent;
}

.btn-register:hover, .btn-register:active {
  background: var(--gold-dark);
  color: var(--cream);
  border-color: var(--gold-dark);
}

.tiers {
  display: flex;
  gap: 8px;
  margin-top: 32px;
  animation: fadeUp 0.9s 0.56s ease both;
}

.tier {
  flex: 1;
  padding: 10px 6px;
  border: 1px solid rgba(201,168,76,0.2);
  border-radius: 4px;
  text-align: center;
  background: rgba(201,168,76,0.03);
}

.tier-icon { font-size: 13px; margin-bottom: 4px; }

.tier-name {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--gold-dark);
}

.tier-desc {
  font-size: 8.5px;
  color: var(--text-muted);
  margin-top: 2px;
  font-weight: 300;
}

/* Toast */
.toast {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%) translateY(120px);
  background: var(--charcoal);
  color: var(--gold-light);
  padding: 13px 24px;
  border-radius: 4px;
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: 0.4px;
  border: 1px solid rgba(201,168,76,0.3);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  white-space: nowrap;
  z-index: 999;
  max-width: 90vw;
  text-align: center;
  white-space: normal;
}

.toast.show { transform: translateX(-50%) translateY(0); }

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

/* ════════════════════════════
   TABLET  ≤ 860px
════════════════════════════ */
@media (max-width: 860px) {
  body { flex-direction: column; }

  .panel-left {
    width: 100%;
    padding: 40px 32px 32px;
    min-height: auto;
  }

  .panel-left::after { display: none; }

  .logo-wrap { width: 220px; margin-bottom: 24px; }
  .divider-ornament { width: 220px; }
  .benefits-list { width: 220px; }
  .tagline { margin-bottom: 32px; }

  .panel-right {
    min-height: auto;
    padding: 48px 40px 56px;
    justify-content: flex-start;
  }
}

/* ════════════════════════════
   MOBILE  ≤ 540px
   Logo no topo escuro, formulário em cartão branco
════════════════════════════ */
@media (max-width: 540px) {
  body { flex-direction: column; background: var(--off-white); }

  /* ── Header escuro com logo ── */
  .panel-left {
    width: 100%;
    padding: 36px 24px 30px;
    min-height: auto;
    border-radius: 0 0 24px 24px;
    /* sombra dourada suave embaixo do header */
    box-shadow: 0 4px 24px rgba(0,0,0,0.35);
    position: relative;
    z-index: 2;
  }

  .logo-wrap {
    width: min(200px, 60vw);
    margin-bottom: 16px;
  }

  .divider-ornament {
    width: min(200px, 60vw);
    margin-bottom: 12px;
  }

  .tagline { font-size: 11px; margin-bottom: 0; }

  /* Esconde lista de benefícios no mobile — aparece após login */
  .benefits-list { display: none; }

  /* ── Painel do formulário ── */
  .panel-right {
    padding: 32px 20px 48px;
    background: var(--off-white);
    min-height: auto;
    border-radius: 0;
  }

  /* Remove linha dourada do topo (o header escuro já separa) */
  .panel-right::before { display: none; }

  .form-header { margin-bottom: 28px; }

  .form-header h1 { font-size: 28px; }

  .input-wrap input {
    height: 54px;
    font-size: 16px; /* evita zoom no iOS */
  }

  .input-wrap input::placeholder { font-size: 13px; }

  .btn-login {
    height: 56px;
    font-size: 11px;
    letter-spacing: 2.5px;
  }

  .btn-register {
    width: 100%;
    display: block;
    text-align: center;
    padding: 15px;
  }

  .tiers { flex-direction: row; }

  .tier { padding: 10px 4px; }

  .gold-divider { margin: 22px 0; }
}

/* ════════════════════════════
   EXTRA SMALL  ≤ 360px
════════════════════════════ */
@media (max-width: 360px) {
  .panel-left { padding: 28px 16px 24px; }
  .logo-wrap { width: 170px; }
  .panel-right { padding: 28px 16px 44px; }
  .form-header h1 { font-size: 25px; }
  .tiers { gap: 5px; }
  .tier-name { font-size: 8px; letter-spacing: 1px; }
}