/* ═══════════════════════════════════════
   TBS — Configurações
   Estilos exclusivos da página Configurações
═══════════════════════════════════════ */

/* ─── LAYOUT ─── */
.settings-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 24px;
  align-items: start;
}

/* ─── MENU LATERAL ─── */
.settings-nav-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  overflow: hidden;
  position: sticky;
  top: calc(var(--topbar-h) + 28px);
}
.settings-nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  color: var(--text2);
  border-bottom: 1px solid var(--border);
  transition: all 0.15s;
}
.settings-nav-item:last-child          { border-bottom: none; }
.settings-nav-item:hover               { background: rgba(255,255,255,0.02); color: var(--white); }
.settings-nav-item.active              { background: rgba(109,40,217,0.14); color: var(--white); border-left: 3px solid #8B5CF6; }

/* ─── SEÇÕES ─── */
.settings-section              { margin-bottom: 20px; }
.settings-section:last-child   { margin-bottom: 0; }

/* ─── HERO DO PERFIL ─── */
.profile-hero {
  background: linear-gradient(135deg, #1e0a42 0%, #100528 60%, #070215 100%);
  border: 1px solid rgba(109,40,217,0.3);
  border-radius: 20px;
  padding: 28px;
  display: flex;
  align-items: center;
  gap: 24px;
  margin-bottom: 20px;
  position: relative;
  overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(139,92,246,0.12);
}
.profile-hero::before {
  content: '';
  position: absolute;
  top: -40px; right: -40px;
  width: 160px; height: 160px;
  background: radial-gradient(circle, rgba(90,24,154,0.25), transparent 70%);
  pointer-events: none;
}
.profile-avatar-lg {
  width: 80px; height: 80px;
  border-radius: 22px;
  background: linear-gradient(135deg, var(--accent), var(--purple));
  display: flex; align-items: center; justify-content: center;
  font-family: 'Epilogue', sans-serif;
  font-size: 26px; font-weight: 900; color: white;
  flex-shrink: 0;
  position: relative;
  box-shadow: 0 8px 24px var(--accent-glow);
}
.profile-edit-badge {
  position: absolute;
  bottom: -4px; right: -4px;
  width: 24px; height: 24px;
  background: var(--surface3);
  border: 2px solid var(--bg);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 11px;
  cursor: pointer;
}
.profile-hero-info            { flex: 1; position: relative; }
.profile-hero-name            { font-family: 'Epilogue', sans-serif; font-size: 24px; font-weight: 900; color: var(--white); letter-spacing: -0.3px; margin-bottom: 4px; }
.profile-hero-job             { font-size: 14px; color: var(--purple); font-weight: 600; margin-bottom: 8px; }
.profile-hero-meta            { display: flex; gap: 16px; flex-wrap: wrap; }
.profile-hero-meta-item       { font-size: 12px; color: var(--text2); display: flex; align-items: center; gap: 5px; }

/* ─── GRUPOS DE CAMPOS ─── */
.settings-field-group {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  overflow: hidden;
  margin-bottom: 16px;
}
.settings-field-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
  font-weight: 700;
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.settings-field-body { padding: 20px; }
.settings-field-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}
.settings-field-row:last-child { border-bottom: none; }
.settings-field-label          { font-size: 13px; font-weight: 600; color: var(--text2); }
.settings-field-value          { font-size: 13px; color: var(--white); font-weight: 500; }

/* ─── TOGGLE SWITCH (visual legado) ─── */
.toggle-switch {
  width: 40px; height: 22px;
  background: var(--accent);
  border-radius: 11px;
  position: relative;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.2s;
}
.toggle-switch.off { background: var(--surface3); }
.toggle-switch::after {
  content: '';
  position: absolute;
  top: 3px; left: 3px;
  width: 16px; height: 16px;
  background: white;
  border-radius: 50%;
  transition: transform 0.2s;
}
.toggle-switch.off::after          { transform: translateX(0); }
.toggle-switch:not(.off)::after    { transform: translateX(18px); }

/* ─── TOGGLE SWITCH REAL (input checkbox) ─── */
.toggle-wrap { display: inline-flex; align-items: center; cursor: pointer; }
.toggle-wrap input[type="checkbox"] { display: none; }
.toggle-switch-real {
  width: 40px; height: 22px;
  background: var(--surface3);
  border-radius: 11px;
  position: relative;
  transition: background 0.2s;
  display: block;
  flex-shrink: 0;
}
.toggle-wrap input:checked + .toggle-switch-real { background: var(--accent); }
.toggle-switch-real::after {
  content: '';
  position: absolute;
  top: 3px; left: 3px;
  width: 16px; height: 16px;
  background: white;
  border-radius: 50%;
  transition: transform 0.2s;
}
.toggle-wrap input:checked + .toggle-switch-real::after { transform: translateX(18px); }

/* ─── CANAL DE NOTIFICAÇÃO ─── */
.notif-canal {
  background: var(--surface2);
  border: 1px solid var(--border2);
  color: var(--text2);
  border-radius: 9px;
  padding: 7px 14px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  font-family: 'Plus Jakarta Sans', sans-serif;
  transition: all .18s;
}
.notif-canal.active            { background: rgba(109,40,217,0.18); border-color: rgba(109,40,217,0.4); color: var(--accent-light); }
.notif-canal:hover:not(.active){ background: var(--surface3); color: var(--white); }

/* ─── FILTRO CATEGORIA (sca — agendamento rápido) ─── */
.sca-cat-filtro {
  background: var(--surface2); color: var(--text2);
  border: 1px solid var(--border2); border-radius: 20px;
  padding: 4px 12px; font-size: 11px; font-weight: 600;
  cursor: pointer; font-family: 'Plus Jakarta Sans', sans-serif;
  transition: all .15s;
}
.sca-cat-filtro.active          { background: var(--accent); color: white; border-color: var(--accent); }
.sca-cat-filtro:hover:not(.active) { border-color: var(--accent); color: var(--accent-light); }

/* ─── ABA DOCUMENTOS — sub-abas por tipo ─── */
.doc-type-tab {
  padding: 7px 14px;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 700;
  border: 1px solid var(--border2);
  background: var(--surface2);
  color: var(--text3);
  cursor: pointer;
  transition: all 0.15s;
  font-family: 'Plus Jakarta Sans', sans-serif;
  white-space: nowrap;
}
.doc-type-tab:hover {
  border-color: rgba(109,40,217,0.35);
  color: var(--accent-light);
  background: var(--surface3);
}
.doc-type-tab.active {
  background: linear-gradient(135deg, rgba(109,40,217,0.18), rgba(139,92,246,0.12));
  border-color: rgba(109,40,217,0.45);
  color: var(--accent-light);
}

/* ─── ABA AGENDA — botões de dia da semana ─── */
.blorec-dia-btn {
  padding: 6px 10px;
  border-radius: 8px;
  font-size: 11px;
  font-weight: 700;
  border: 1px solid var(--border2);
  background: var(--surface3);
  color: var(--text3);
  cursor: pointer;
  transition: all 0.15s;
  font-family: 'Plus Jakarta Sans', sans-serif;
}
.blorec-dia-btn:hover {
  border-color: rgba(109,40,217,0.4);
  color: var(--accent-light);
}
.blorec-dia-btn.active {
  background: linear-gradient(135deg, #6D28D9, #8B5CF6);
  border-color: transparent;
  color: white;
  box-shadow: 0 2px 8px rgba(109,40,217,0.35);
}

/* ── Tema Claro ── */
[data-tema="light"] .settings-field-header { color: var(--text) !important; }
[data-tema="light"] .settings-field-value  { color: var(--text2) !important; }
[data-tema="light"] .settings-nav-item:hover { color: var(--text) !important; background: rgba(109,40,217,0.07) !important; }
[data-tema="light"] .settings-nav-item.active { color: var(--accent) !important; }
[data-tema="light"] .notif-canal:hover:not(.active) { color: var(--text) !important; }
[data-tema="light"] .profile-hero {
  background: linear-gradient(135deg, #ede8fb 0%, #e2daf8 60%, #d8cff5 100%);
  border-color: rgba(109,40,217,0.2);
  box-shadow: inset 0 1px 0 rgba(139,92,246,0.08);
}
[data-tema="light"] .profile-hero-name { color: var(--text) !important; }
[data-tema="light"] #plano-hero {
  background: linear-gradient(135deg, #ede8fb 0%, #e2daf8 100%);
  border-color: rgba(109,40,217,0.22);
}
