:root {
  --ink: #10192E;
  --paper: #F5F6F8;
  --card: #FFFFFF;
  --line: #E3E6EC;
  --text: #16181D;
  --text-dim: #64708A;
  --accent: #0F766E;
  --accent-soft: #E6F4F2;
  --radius: 14px;
}

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

body {
  font-family: 'Manrope', system-ui, sans-serif;
  background: var(--paper);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.auth-top {
  padding: 20px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.auth-top a.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
  font-size: 17px;
  color: var(--ink);
  text-decoration: none;
}

.auth-top a.brand img { width: 28px; height: 28px; border-radius: 7px; }
.auth-top a.brand em { font-style: normal; color: var(--text-dim); font-weight: 600; }

.auth-top-link {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-dim);
  text-decoration: none;
}

.auth-top-link:hover { color: var(--accent); }

.auth-main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 20px 48px;
}

.auth-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 36px 32px;
  width: 100%;
  max-width: 420px;
  box-shadow: 0 16px 40px -20px rgba(16, 25, 46, 0.12);
}

.auth-card h1 {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin-bottom: 6px;
}

.auth-sub {
  font-size: 14px;
  color: var(--text-dim);
  margin-bottom: 24px;
  line-height: 1.45;
}

.auth-tabs {
  display: flex;
  gap: 4px;
  background: var(--paper);
  border-radius: 10px;
  padding: 4px;
  margin-bottom: 24px;
}

.auth-tab {
  flex: 1;
  border: none;
  background: transparent;
  padding: 10px 12px;
  border-radius: 8px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-dim);
  cursor: pointer;
}

.auth-tab.active {
  background: var(--card);
  color: var(--ink);
  box-shadow: 0 1px 3px rgba(16, 25, 46, 0.08);
}

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

.auth-field { margin-bottom: 14px; }

.auth-field input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 9px;
  font-family: inherit;
  font-size: 14px;
  background: var(--paper);
}

.auth-field input:focus {
  outline: 2px solid var(--accent-soft);
  border-color: var(--accent);
}

.auth-erro {
  background: #FEE2E2;
  color: #B91C1C;
  font-size: 13px;
  padding: 10px 12px;
  border-radius: 8px;
  margin-bottom: 14px;
  display: none;
}

.auth-sucesso {
  background: var(--accent-soft);
  color: var(--accent);
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 13px;
  margin-bottom: 14px;
  line-height: 1.45;
}

.auth-esqueci {
  text-align: right;
  margin: -6px 0 10px;
  font-size: 12px;
}

.auth-esqueci a {
  color: var(--text-dim);
  text-decoration: none;
  font-weight: 600;
}

.auth-esqueci a:hover { color: var(--accent); }

.auth-termos {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 4px 0 14px;
  font-size: 12px;
  line-height: 1.45;
  color: var(--text-dim);
}

.auth-termos input { margin-top: 3px; accent-color: var(--accent); }
.auth-termos a { color: var(--accent); font-weight: 600; text-decoration: none; }
.auth-termos a:hover { text-decoration: underline; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  border: none;
  border-radius: 9px;
  padding: 13px 20px;
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s, transform 0.15s;
}

.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: #0C5F58; transform: translateY(-1px); }
.btn-primary:disabled { opacity: 0.65; cursor: not-allowed; transform: none; }

.auth-switch {
  text-align: center;
  margin-top: 20px;
  font-size: 13px;
  color: var(--text-dim);
}

.auth-switch a {
  color: var(--accent);
  font-weight: 700;
  text-decoration: none;
}

.auth-switch a:hover { text-decoration: underline; }

.auth-loading .btn-primary { opacity: 0.7; pointer-events: none; }

.auth-foot {
  text-align: center;
  padding: 20px;
  font-size: 12px;
  color: var(--text-dim);
}

.auth-foot a { color: var(--accent); text-decoration: none; font-weight: 600; }
