/* ==========================================================================
   ÁREA RESTRITA E AUTENTICAÇÃO FAMILIAR (auth.css)
   ========================================================================== */

.auth-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(44, 37, 32, 0.85);
  backdrop-filter: blur(8px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: fadeIn 0.4s ease-out;
}

.auth-card {
  background: var(--bg-book);
  border: 1px solid var(--border-color);
  width: 100%;
  max-width: 460px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-strong);
  overflow: hidden;
  position: relative;
}

.auth-header {
  background: var(--bg-sidebar);
  color: var(--text-light);
  padding: 30px 25px 20px 25px;
  text-align: center;
  position: relative;
}

.auth-header::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, var(--accent-sertao), var(--correction-red));
}

.auth-header h2 {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 6px;
  color: #FFF;
}

.auth-header p {
  font-family: var(--font-ui);
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.8);
}

.auth-tabs {
  display: flex;
  background: var(--bg-book-subtle);
  border-bottom: 1px solid var(--border-color);
}

.auth-tab-btn {
  flex: 1;
  padding: 14px;
  font-family: var(--font-ui);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-muted);
  text-align: center;
  transition: all var(--transition-fast);
}

.auth-tab-btn.active {
  background: var(--bg-book);
  color: var(--accent-header);
  border-bottom: 2px solid var(--accent-sertao);
}

.auth-body {
  padding: 25px;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-family: var(--font-ui);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-main);
}

.form-input {
  width: 100%;
  padding: 11px 14px;
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-sm);
  background: #FFF;
  color: var(--text-main);
  font-size: 0.95rem;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.form-input:focus {
  border-color: var(--accent-sertao);
  box-shadow: 0 0 0 3px rgba(226, 135, 67, 0.15);
  outline: none;
}

.auth-submit-btn {
  margin-top: 10px;
  width: 100%;
  padding: 13px;
  font-size: 1rem;
}

.auth-footer {
  text-align: center;
  margin-top: 15px;
  font-size: 0.8rem;
  color: var(--text-muted);
  font-family: var(--font-ui);
}

.auth-error-msg {
  background: rgba(211, 47, 47, 0.1);
  color: var(--correction-red);
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  display: none;
  border-left: 3px solid var(--correction-red);
}

@keyframes fadeIn {
  from { opacity: 0; transform: scale(0.96); }
  to { opacity: 1; transform: scale(1); }
}
