/* ==========================================================================
   CALMI HEALTH - SISTEMA DE PUERICULTURA & SAÚDE PEDIÁTRICA
   Visual Scandinavian Health-Tech / Quiet Luxury (Padrão Huckleberry & Devla)
   100% Livre de Emojis • Ícones Vetoriais SVG Minimalistas
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
  --app-bg: #FAF8F5;
  --surface: #FFFFFF;
  --surface-subtle: #F4F1EA;
  --primary: #2D5A46;
  --primary-light: #EFF5F2;
  --primary-hover: #224535;
  --accent-sleep: #3B6B8A;
  --accent-sleep-light: #EBF2F7;
  --accent-feed: #C87438;
  --accent-feed-light: #FAF2EC;
  --accent-diaper: #B58A38;
  --accent-diaper-light: #F9F4EB;
  --accent-mother: #B85869;
  --accent-mother-light: #FBF0F2;
  --text-main: #1D2321;
  --text-muted: #64716C;
  --border: #E8E4DD;
  --border-focus: #2D5A46;
  --danger: #C53030;
  --danger-light: #FDE8E8;
  --shadow-sm: 0 1px 3px rgba(29, 35, 33, 0.04);
  --shadow-md: 0 4px 14px rgba(29, 35, 33, 0.06);
  --shadow-lg: 0 12px 32px rgba(29, 35, 33, 0.08);
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 9999px;
  --font: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* ÍCONES VETORIAIS MINIMALISTAS */
.calmi-icon {
  width: 18px;
  height: 18px;
  display: inline-block;
  vertical-align: middle;
  stroke: currentColor;
  stroke-width: 1.8px;
  fill: none;
  flex-shrink: 0;
}

.calmi-icon.icon-sm {
  width: 14px;
  height: 14px;
}

.calmi-icon.icon-md {
  width: 20px;
  height: 20px;
}

.calmi-icon.icon-lg {
  width: 24px;
  height: 24px;
}

/* AVATAR MONOGRAMADO ELEGANTE */
.baby-monogram {
  width: 26px;
  height: 26px;
  border-radius: var(--radius-full);
  background: var(--primary);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  flex-shrink: 0;
}

/* MODO AMAMENTAÇÃO NOTURNA (Luz Âmbar Quente - Zero Luz Azul) */
body.dark-mode {
  --app-bg: #111412;
  --surface: #181E1A;
  --surface-subtle: #222B25;
  --primary: #8FBCA7;
  --primary-light: #202D25;
  --primary-hover: #A4CEBB;
  --accent-sleep: #79AEC7;
  --accent-sleep-light: #1D2A31;
  --accent-feed: #E09F67;
  --accent-feed-light: #2F241C;
  --accent-diaper: #D6B265;
  --accent-diaper-light: #2C2619;
  --accent-mother: #E493A1;
  --accent-mother-light: #2F1E23;
  --text-main: #E5E7EB;
  --text-muted: #9CA3AF;
  --border: #29342C;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.4);
  --shadow-md: 0 6px 18px rgba(0,0,0,0.5);
  --shadow-lg: 0 12px 30px rgba(0,0,0,0.6);
}

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

body {
  font-family: var(--font);
  background-color: var(--app-bg);
  color: var(--text-main);
  line-height: 1.5;
  transition: background-color 0.3s ease, color 0.3s ease;
  min-height: 100vh;
  min-height: 100dvh;
  width: 100%;
  overflow-x: hidden;
  -webkit-tap-highlight-color: transparent;
}

.app-wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
  max-width: 1440px;
  margin: 0 auto;
  width: 100%;
}

/* TOPBAR */
.app-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 10px clamp(12px, 3vw, 24px);
  display: flex;
  justify-content: space-between;
  align-items: center;
  backdrop-filter: blur(8px);
  gap: 12px;
}

/* PERFIL FAMILIAR NO HEADER */
.user-header-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  padding: 5px 12px;
  border-radius: var(--radius-full);
}

.user-pill-avatar {
  font-size: 1.1rem;
  line-height: 1;
}

.user-pill-info {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.user-pill-parent {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-main);
  white-space: nowrap;
}

.user-pill-baby {
  font-size: 0.72rem;
  color: var(--primary);
  font-weight: 600;
  white-space: nowrap;
}

.user-pill-plan {
  font-size: 0.7rem;
  font-weight: 800;
  background: var(--primary-light);
  color: var(--primary);
  padding: 3px 8px;
  border-radius: var(--radius-full);
  white-space: nowrap;
}

.btn-logout {
  background: var(--surface-subtle);
  color: var(--text-muted);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all 0.2s;
}

.btn-logout:hover {
  background: var(--danger-light);
  color: var(--danger);
  border-color: var(--danger);
}

.header-left {
  display: flex;
  align-items: center;
  gap: clamp(8px, 2vw, 14px);
}

.app-logo {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--primary);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 6px;
}

.baby-selector {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--surface-subtle);
  padding: 6px 12px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border);
}

.baby-avatar {
  width: 24px;
  height: 24px;
  background: var(--primary-light);
  color: var(--primary);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.82rem;
  font-weight: 700;
}

.baby-select-dropdown {
  background: transparent;
  border: none;
  font-size: 0.86rem;
  font-weight: 700;
  color: var(--text-main);
  outline: none;
  cursor: pointer;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-btn {
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  color: var(--text-main);
  padding: 8px 14px;
  border-radius: var(--radius-full);
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.15s;
  min-height: 38px;
  text-decoration: none;
  white-space: nowrap;
}

.header-btn:hover {
  background: var(--primary-light);
  color: var(--primary);
}

/* APP NAVIGATION TABS (DESKTOP) */
.app-nav {
  display: flex;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 0 16px;
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;
}
.app-nav::-webkit-scrollbar { display: none; }

.nav-tab-btn {
  background: transparent;
  border: none;
  padding: 14px 16px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 2px solid transparent;
  white-space: nowrap;
  transition: all 0.15s;
  min-height: 48px;
}

.nav-tab-btn:hover {
  color: var(--text-main);
}

.nav-tab-btn.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

/* LAYOUT MULTI-DISPOSITIVO */
.app-layout-container {
  display: flex;
  gap: 24px;
  width: 100%;
  padding: clamp(14px, 2.5vw, 24px) clamp(12px, 3vw, 20px) 120px;
  align-items: flex-start;
  box-sizing: border-box;
}

.app-body {
  flex: 1;
  min-width: 0;
  padding: 0;
}

/* PAINEL LATERAL DESKTOP (>= 1100px) */
.desktop-side-panel {
  width: 330px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
  position: sticky;
  top: 76px;
}

.desktop-widget-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px;
  box-shadow: var(--shadow-sm);
  transition: all 0.2s ease;
}

.desktop-widget-card:hover {
  box-shadow: var(--shadow-md);
}

.widget-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.widget-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--surface-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  flex-shrink: 0;
}

.widget-title {
  font-size: 0.94rem;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.2;
}

.widget-subtitle {
  font-size: 0.74rem;
  color: var(--text-muted);
}

.widget-status-badge {
  margin-left: auto;
  font-size: 0.7rem;
  font-weight: 700;
  color: #10B981;
  background: rgba(16, 185, 129, 0.12);
  padding: 3px 8px;
  border-radius: var(--radius-full);
}

.widget-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.widget-stat-box {
  background: var(--surface-subtle);
  padding: 8px 6px;
  border-radius: 8px;
  text-align: center;
}

.widget-stat-lbl {
  font-size: 0.68rem;
  color: var(--text-muted);
  display: block;
}

.widget-stat-val {
  font-size: 0.88rem;
  font-weight: 800;
  color: var(--text-main);
}

.side-widget-notice {
  font-size: 0.86rem;
  color: var(--text-main);
  background: var(--surface-subtle);
  padding: 10px 12px;
  border-radius: 8px;
  line-height: 1.45;
}

.tab-pane {
  display: none;
  animation: fadeIn 0.2s ease;
}
.tab-pane.active {
  display: block;
}

/* CARDS SLIM */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: clamp(16px, 3vw, 24px);
  box-shadow: var(--shadow-sm);
  margin-bottom: 20px;
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  flex-wrap: wrap;
  gap: 10px;
}

.card-title {
  font-size: clamp(1.05rem, 2.5vw, 1.15rem);
  font-weight: 700;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 8px;
}

/* RESUMO RÁPIDO DO DIA (METRIC CHIPS) */
.metric-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: clamp(12px, 2vw, 16px);
  margin-bottom: 20px;
}

.metric-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px 18px;
  display: flex;
  align-items: center;
  gap: 14px;
  box-shadow: var(--shadow-sm);
}

.metric-icon-wrap {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  flex-shrink: 0;
}

.metric-val {
  font-size: clamp(1.3rem, 3vw, 1.45rem);
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.2;
}

.metric-lbl {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* BANNER DE JANELA DE SONO */
.sleep-banner {
  background: var(--accent-sleep-light);
  border: 1px solid rgba(74, 122, 150, 0.2);
  border-radius: var(--radius-md);
  padding: clamp(14px, 3vw, 18px) clamp(16px, 3vw, 22px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 12px;
}

.sleep-banner-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.sleep-icon-badge {
  font-size: 1.8rem;
}

/* TIMELINE 24H VISUAL */
.timeline-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.timeline-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: var(--surface);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  gap: 12px;
  transition: all 0.2s ease;
}

.timeline-item:hover {
  background: var(--surface-subtle);
  border-color: rgba(45, 90, 70, 0.2);
}

.timeline-item-left {
  display: flex;
  align-items: center;
  gap: 12px;
  overflow: hidden;
}

.timeline-icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  flex-shrink: 0;
}

.timeline-title {
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.timeline-detail {
  font-size: 0.8rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.timeline-time {
  font-size: 0.78rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--text-muted);
  background: var(--surface-subtle);
  padding: 4px 10px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border);
  flex-shrink: 0;
}

/* BARRA FLUTUANTE DE REGISTRO RÁPIDO */
.quick-log-bar {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  border-radius: var(--radius-full);
  padding: 8px 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  z-index: 80;
  max-width: 95vw;
}

.quick-btn {
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  color: var(--text-main);
  font-size: 0.84rem;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: var(--radius-full);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.15s;
  min-height: 40px;
  white-space: nowrap;
}

.quick-btn:hover {
  background: var(--primary-light);
  color: var(--primary);
  border-color: var(--primary);
}

/* MODAL DE REGISTRO */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  backdrop-filter: blur(4px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 200;
  padding: 16px;
}

.modal-overlay.active {
  display: flex;
}

.modal-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: clamp(20px, 4vw, 28px);
  max-width: 480px;
  width: 100%;
  box-shadow: var(--shadow-lg);
  animation: fadeIn 0.2s ease;
}

/* AGENTE PEDIÁTRICO CHAT */
.agent-chat-box {
  display: flex;
  flex-direction: column;
  height: clamp(420px, 60vh, 540px);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--surface);
  overflow: hidden;
}

.agent-messages-wrap {
  flex: 1;
  padding: clamp(14px, 3vw, 20px);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: var(--surface-subtle);
}

.agent-input-bar {
  padding: 10px 14px;
  background: var(--surface);
  border-top: 1px solid var(--border);
  display: flex;
  gap: 8px;
  align-items: center;
}

.agent-input {
  flex: 1;
  min-height: 44px;
  padding: 10px 16px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border);
  background: var(--surface-subtle);
  color: var(--text-main);
  outline: none;
  font-size: 0.9rem;
}

.voice-btn {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-full);
  background: var(--primary-light);
  color: var(--primary);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  cursor: pointer;
  flex-shrink: 0;
}

.voice-btn.recording {
  background: var(--danger);
  color: #FFF;
  animation: pulse 1s infinite;
}

/* GRÁFICOS OMS (CANVAS) */
.chart-container {
  width: 100%;
  height: 290px;
  position: relative;
  margin: 16px 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px;
}

/* PORTAL DO PEDIATRA */
.doctor-view-box {
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  border-radius: var(--radius-lg);
  padding: clamp(20px, 4vw, 32px);
}

.doctor-badge {
  background: var(--primary-light);
  color: var(--primary);
  font-weight: 700;
  font-size: 0.8rem;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  display: inline-block;
  margin-bottom: 12px;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.08); }
  100% { transform: scale(1); }
}

/* ==========================================================================
   NATIVE MOBILE APP NAVIGATION (@media max-width: 768px)
   Transforma as abas superiores em uma barra inferior de aplicativo nativo
   ========================================================================== */
@media (max-width: 768px) {
  .app-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: var(--surface);
    border-top: 1px solid var(--border);
    border-bottom: none;
    padding: 6px 4px calc(8px + env(safe-area-inset-bottom));
    display: flex;
    justify-content: space-around;
    gap: 0;
    box-shadow: 0 -4px 16px rgba(0,0,0,0.06);
  }

  .nav-tab-btn {
    flex-direction: column;
    padding: 6px 8px;
    font-size: 0.68rem;
    font-weight: 600;
    min-height: 48px;
    border-bottom: none;
    border-radius: 8px;
    gap: 2px;
    flex: 1;
    text-align: center;
  }

  .nav-tab-btn span {
    font-size: 1.25rem;
    line-height: 1;
  }

  .nav-tab-btn.active {
    background: var(--primary-light);
    color: var(--primary);
  }

  /* Ajusta a barra rápida para ficar logo acima da navegação mobile */
  .quick-log-bar {
    bottom: calc(68px + env(safe-area-inset-bottom));
    padding: 6px 10px;
    gap: 6px;
    width: 95vw;
    overflow-x: auto;
    justify-content: flex-start;
  }

  .quick-btn {
    font-size: 0.78rem;
    padding: 6px 12px;
    min-height: 36px;
  }

  .app-body {
    padding-bottom: calc(140px + env(safe-area-inset-bottom));
  }
}

/* ==========================================================================
   ADAPTAÇÃO RESPONSIVA MULTI-DISPOSITIVO (TABLETS & NOTEBOOKS)
   ========================================================================== */

/* Telas menores que 1100px: esconde painel lateral desktop e ajusta padding */
@media (max-width: 1099px) {
  .desktop-side-panel {
    display: none !important;
  }
  .app-layout-container {
    padding: 16px clamp(10px, 2.5vw, 18px) 110px;
  }
}

/* Tablets e Telas Médias (769px a 1099px) */
@media (min-width: 769px) and (max-width: 1099px) {
  .app-header {
    padding: 10px 18px;
  }
  .user-header-pill {
    padding: 4px 10px;
  }
  .metric-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
  }
  .app-nav {
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding: 0 12px;
  }
  .app-nav::-webkit-scrollbar {
    display: none;
  }
  .nav-tab-btn {
    padding: 12px 16px;
    font-size: 0.88rem;
    white-space: nowrap;
  }
}

/* ==========================================================================
   PORTAL DE AUTENTICAÇÃO OBRIGATÓRIA (14 DIAS GRÁTIS / LOGIN)
   ========================================================================== */
.auth-gate-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 99999;
  background: rgba(20, 24, 22, 0.78);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  overflow-y: auto;
  opacity: 1;
  visibility: visible;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.auth-gate-overlay.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.auth-gate-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  max-width: 580px;
  width: 100%;
  padding: clamp(20px, 4vw, 36px);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.25);
  animation: fadeIn 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  margin: auto;
}

body.dark-mode .auth-gate-card {
  background: #181E1A;
  border-color: #2E3B32;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.6);
}

.auth-gate-header {
  text-align: center;
  margin-bottom: 24px;
}

.auth-logo {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--primary);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}

.auth-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 4px;
}

.auth-subtitle {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: 14px;
}

.auth-trial-badge {
  display: inline-block;
  background: linear-gradient(135deg, var(--primary-light), #D8EADF);
  color: var(--primary);
  border: 1px solid var(--primary);
  font-size: 0.78rem;
  font-weight: 800;
  padding: 6px 16px;
  border-radius: var(--radius-full);
  letter-spacing: 0.3px;
}

body.dark-mode .auth-trial-badge {
  background: #202D25;
  color: #8FBCA7;
  border-color: #5A7F6E;
}

/* ABAS DO MODAL */
.auth-nav-tabs {
  display: flex;
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 4px;
  gap: 4px;
  margin-bottom: 22px;
}

.auth-nav-btn {
  flex: 1;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.86rem;
  font-weight: 700;
  padding: 10px 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
  text-align: center;
}

.auth-nav-btn.active {
  background: var(--surface);
  color: var(--text-main);
  box-shadow: var(--shadow-sm);
}

body.dark-mode .auth-nav-btn.active {
  background: #252F28;
  color: #FFF;
}

/* FORMULÁRIOS */
.auth-form-view {
  display: none;
}

.auth-form-view.active {
  display: block;
}

.auth-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 14px;
}

@media (max-width: 580px) {
  .auth-form-row {
    grid-template-columns: 1fr;
    gap: 12px;
    margin-bottom: 12px;
  }
}

.auth-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.auth-field label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-main);
}

.auth-input {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-subtle);
  color: var(--text-main);
  font-size: 0.92rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  box-sizing: border-box;
}

.auth-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(90, 127, 110, 0.15);
  background: var(--surface);
}

.auth-benefits-list {
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  margin: 16px 0 20px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

@media (max-width: 580px) {
  .auth-benefits-list {
    grid-template-columns: 1fr;
  }
}

.auth-benefit-item {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 6px;
}

.auth-submit-btn {
  width: 100%;
  padding: 14px;
  background: var(--primary);
  color: #FFF;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 0.98rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0 4px 14px rgba(90, 127, 110, 0.25);
  box-sizing: border-box;
}

.auth-submit-btn:hover {
  background: var(--primary-hover);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(90, 127, 110, 0.35);
}

.auth-submit-btn:active {
  transform: translateY(0);
}

.auth-privacy-disclaimer {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-align: center;
  margin-top: 12px;
  line-height: 1.4;
}

.auth-alert-box {
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 16px;
  line-height: 1.4;
}

.auth-alert-box.error {
  background: var(--danger-light);
  color: var(--danger);
  border: 1px solid rgba(220, 38, 38, 0.2);
}

.auth-alert-box.success {
  background: #D1FAE5;
  color: #065F46;
  border: 1px solid rgba(16, 185, 129, 0.2);
}
