/* ─────────────────────────────────────────────────────────────────
   SNTE 16 — Diplomado CAPD | Sistema de estilos
   Tema oscuro institucional · SaaS premium (paleta SNTE)
   ───────────────────────────────────────────────────────────────── */
:root {
  /* Paleta oficial SNTE (muestra) */
  --oficial:      #e88423;   /* naranja institucional principal */
  --comp:         #e55b0f;   /* naranja complementario */
  --accent:       #fe5000;   /* rojo‑naranja de acento */
  --accent-soft:  #FF9E1B;   /* naranja luminoso de apoyo */
  --guinda:       #9e2147;   /* apoyo secundario, nunca dominante */
  --beige:        #FEE5C3;   /* crema */

  /* Fondos y texto principales */
  --bg-main:      #0b0b0e;
  --bg-card:      #111118cc;
  --bg-elevated:  #14141ccc;
  --bg-elevated-strong: #14141c;

  --text-primary:   #f4f4f6;
  --text-secondary: #b7b7c2;
  --border-soft:    #232332;

  /* Alias y semántica para compatibilidad previa */
  --snte-cream:         var(--beige);
  --snte-orange:        var(--accent);
  --snte-orange-deep:   var(--comp);
  --snte-orange-soft:   var(--accent-soft);
  --snte-primary:       var(--oficial);
  --snte-primary-hover: var(--accent);
  --snte-primary-dark:  var(--accent);

  --accent-primary:         var(--oficial);
  --accent-primary-soft:    rgba(232,132,35,.25);
  --accent-primary-softer:  rgba(232,132,35,.12);

  --accent-secondary:       var(--accent-soft);
  --accent-secondary-soft:  rgba(255,158,27,.20);
  --accent-secondary-softer:rgba(255,158,27,.10);

  --success:                var(--accent-soft);
  --success-soft:           rgba(255,158,27,.18);
  --warning:                var(--beige);
  --warning-soft:           rgba(254,229,195,.30);
  --danger:                 var(--guinda);               /* guinda solo en contexto destructivo */
  --danger-soft:            rgba(158,33,71,.30);

  /* Superficies y bordes */
  --surface:      rgba(15,15,22,.96);
  --surface2:     rgba(20,20,30,.98);
  --stroke:       #232332;
  --stroke2:      rgba(40,40,60,.98);

  /* Legacy tokens (compatibilidad) */
  --guinda:       var(--oficial); /* ya NO dominante, solo alias mínimo */
  --bg:           var(--bg-main);
  --text:         var(--text-primary);
  --muted:        var(--text-secondary);
  --muted2:       var(--text-secondary);

  /* Sombras y radios */
  --shadow-sm:      0 20px 60px rgba(0,0,0,.45);
  --shadow:         0 26px 80px rgba(0,0,0,.9);

  --radius:     18px;
  --radius-sm:  12px;
  --radius-xs:  8px;
  --transition: 0.22s ease-out;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background:
    radial-gradient(circle at top left, rgba(232,132,35,.25) 0, transparent 55%),
    radial-gradient(circle at top right, rgba(158,33,71,.20) 0, transparent 55%),
    radial-gradient(circle at bottom, rgba(254,80,0,.18) 0, transparent 60%),
    var(--bg-main);
  color: var(--text-primary);
  min-height: 100vh;
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  letter-spacing: -0.01em;
}

a { color: inherit; text-decoration: none; }
input, select, button, textarea { font-family: inherit; font-size: inherit; }
button { cursor: pointer; }

/* ── Topbar / shell ── */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 24px;
  background: linear-gradient(120deg, rgba(11,11,14,.98), rgba(17,17,24,.95));
  border-bottom: 1px solid var(--stroke);
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(16px);
}
.topbar::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: linear-gradient(120deg, var(--oficial), var(--accent), var(--accent-soft));
  opacity: 0.9;
}
.topbar-brand { display: flex; align-items: center; gap: 12px; }
.topbar-logo {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  flex-shrink: 0;
  background:
    linear-gradient(145deg, rgba(254,229,195,.20), transparent 55%),
    linear-gradient(135deg, var(--snte-primary), var(--snte-orange-soft));
  box-shadow: 0 0 0 1px rgba(23,23,29,.7), 0 14px 38px rgba(15,15,19,.85);
  opacity: 0.96;
}
.topbar-name {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--text-primary);
}
.topbar-sub {
  font-size: 11px;
  color: var(--text-secondary);
  margin-top: 1px;
  font-weight: 500;
}
.topbar-right { display: flex; align-items: center; gap: 10px; }
.topbar-user {
  font-size: 12px;
  color: var(--text-secondary);
  max-width: 180px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.topbar-tag {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.04em;
  padding: 4px 10px;
  border-radius: 6px;
  background: rgba(255,158,27,.16);
  color: var(--oficial);
  border: none;
}

/* ── Buttons (minimal, claro) ── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  font-size: 13px;
  font-weight: 500;
  border-radius: var(--radius-sm);
  border: 1px solid var(--stroke);
  background: linear-gradient(135deg, #111118, #14141c);
  color: var(--text-primary);
  box-shadow: 0 10px 30px rgba(15,15,19,.65);
  transition:
    background var(--transition),
    border-color var(--transition),
    color var(--transition),
    box-shadow var(--transition),
    transform var(--transition);
  white-space: nowrap;
}
.btn svg { width: 16px; height: 16px; flex-shrink: 0; opacity: 0.9; }
.btn:hover {
  background: linear-gradient(135deg, #1e1e26, #17171d);
  transform: translateY(-1px);
  box-shadow: 0 18px 45px rgba(15,15,19,.9);
}
.btn-primary {
  background: linear-gradient(135deg, var(--oficial), var(--accent));
  color: #ffffff;
  border-color: transparent;
  box-shadow: 0 18px 42px rgba(15,15,19,.85);
}
.btn-primary:hover {
  background: linear-gradient(135deg, var(--accent), var(--accent-soft));
  filter: brightness(1.03);
  box-shadow: 0 24px 70px rgba(15,15,19,.95);
}
.btn-guinda {
  background: radial-gradient(circle at top left, rgba(254,80,0,.25), rgba(254,80,0,1));
  color: var(--beige);
  border-color: rgba(254,80,0,.45);
}
.btn-guinda:hover { background: rgba(254,80,0,.22); }
.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  border-color: transparent;
}
.btn-ghost:hover {
  background: rgba(23,23,29,.92);
  color: var(--text-primary);
  border-color: var(--border-soft);
}
.btn-danger {
  background: var(--danger-soft);
  color: var(--danger);
  border-color: rgba(158,33,71,.35);
}
.btn-danger:hover { background: rgba(158,33,71,.18); }
.btn-sm { padding: 8px 14px; font-size: 12px; }
.btn-lg { padding: 14px 28px; font-size: 14px; border-radius: var(--radius); }
.btn-google {
  display: flex;
  align-items: center;
  gap: 10px;
  justify-content: center;
  width: 100%;
  padding: 12px 18px;
  border: 1px solid var(--stroke2);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font-size: 13px;
  font-weight: 500;
  transition: background var(--transition), border-color var(--transition);
}
.btn-google svg { width: 18px; height: 18px; }
.btn-google:hover { background: var(--surface2); border-color: var(--stroke); }
.btn-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--stroke2);
  background: var(--surface);
  color: var(--text-secondary);
  transition: all var(--transition);
}
.btn-icon svg { width: 16px; height: 16px; }
.btn-icon:hover { background: var(--surface2); color: var(--text); }

/* ── Cards / Panels (limpios, poco ruido) ── */
/* Tarjetas base con acento lateral derecho tipo producto premium */
.panel,
.glass-card,
.kpi-card,
.region-card,
.action-card,
.login-card {
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(14px);
}

.panel {
  background: linear-gradient(145deg, var(--bg-card), var(--bg-elevated));
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.glass-card {
  background:
    radial-gradient(circle at top left, rgba(255,158,27,.16), transparent 55%),
    var(--surface);
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  padding: 20px 22px;
  transition: border-color var(--transition), box-shadow var(--transition), transform var(--transition);
}
.glass-card:hover {
  border-color: rgba(254,229,195,.70);
  box-shadow: 0 22px 60px rgba(0,0,0,.92);
  transform: translateY(-1px);
}

/* Acento lateral derecho configurable */
.panel-accent::after,
.panel-accent-oficial::after,
.panel-accent-guinda::after,
.panel-accent-beige::after {
  content: "";
  position: absolute;
  top: 10px;
  bottom: 10px;
  right: -2px;
  width: 6px;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--oficial), var(--accent));
  opacity: .9;
  pointer-events: none;
}
.panel-accent-oficial::after {
  background: linear-gradient(180deg, var(--oficial), var(--accent-soft));
}
.panel-accent-guinda::after {
  background: linear-gradient(180deg, var(--accent), var(--accent-soft));
}
.panel-accent-beige::after {
  background: linear-gradient(180deg, rgba(254,229,195,.9), rgba(255,158,27,.9));
}
.glass-card-header {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted2);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.glass-card-header svg { width: 14px; height: 14px; color: var(--oficial); opacity: 0.9; }

/* ── Layout ── */
.wrap { max-width: 1120px; margin: 0 auto; padding: 28px 24px 56px; }
.container-sm { max-width: 640px; margin: 0 auto; padding: 28px 24px 56px; }

/* ── Screens: Login, Loading ── */
.screen-login {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 80px);
  padding: 24px 16px;
}
.login-card {
  width: 100%;
  max-width: 400px;
  background: linear-gradient(155deg, var(--bg-card), var(--bg-elevated));
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 40px 32px;
  text-align: center;
  box-shadow: var(--shadow);
}
.login-card-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  margin: 0 auto 20px;
  background: linear-gradient(135deg, rgba(232,132,35,.2), rgba(158,33,71,.15));
  border: 1px solid rgba(232,132,35,.2);
  display: flex;
  align-items: center;
  justify-content: center;
}
.login-card-icon svg { width: 24px; height: 24px; color: var(--oficial); }
.login-card h2 { font-size: 20px; font-weight: 600; margin-bottom: 8px; letter-spacing: -0.02em; }
.login-card p { font-size: 13px; color: var(--text-secondary); margin-bottom: 24px; line-height: 1.6; }
.screen-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 80px);
  gap: 16px;
}
.hidden { display: none !important; }

/* ── Spinner ── */
.spinner {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 2px solid var(--stroke2);
  border-top-color: var(--oficial);
  animation: spin 0.6s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── KPI (minimal, número grande) ── */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 32px;
}
.kpi-card {
  background:
    linear-gradient(135deg, rgba(17,17,24,.96), rgba(20,20,30,.98));
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  padding: 20px 22px;
  box-shadow: var(--shadow-sm);
  transition: border-color var(--transition), box-shadow var(--transition), transform var(--transition);
}
.kpi-card:hover {
  border-color: rgba(254,229,195,.7);
  box-shadow: 0 20px 60px rgba(0,0,0,.9);
  transform: translateY(-1px);
}
.kpi-label {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted2);
  margin-bottom: 8px;
}
.kpi-value { font-size: 28px; font-weight: 600; letter-spacing: -0.03em; line-height: 1.1; }
.kpi-sub { font-size: 11px; color: var(--muted2); margin-top: 4px; }
.kpi-blue .kpi-value { color: var(--beige); }
.kpi-green .kpi-value { color: var(--accent-soft); }
.kpi-amber .kpi-value { color: var(--oficial); }
.kpi-purple .kpi-value { color: var(--accent); }

/* ── Region cards ── */
.region-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
}
.region-card {
  background: linear-gradient(145deg, rgba(17,17,24,.96), rgba(20,20,30,.98));
  border: 1px solid var(--stroke);
  border-radius: var(--radius-sm);
  padding: 16px 18px;
}
.region-card-name { font-size: 12px; font-weight: 600; margin-bottom: 12px; color: var(--text); }
.region-stat-row {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 4px;
}
.cap-track {
  height: 4px;
  border-radius: 999px;
  background: var(--stroke);
  overflow: hidden;
  flex: 1;
}
.cap-fill { height: 100%; border-radius: 999px; transition: width 0.4s ease; }
.cap-fill.low { background: var(--accent-secondary); }
.cap-fill.mid { background: var(--accent-primary); }
.cap-fill.high { background: var(--snte-primary-dark); }
.cap-bar { display: flex; align-items: center; gap: 8px; margin-top: 10px; }
.cap-text { font-size: 11px; color: var(--muted2); min-width: 32px; text-align: right; }

/* ── Section ── */
.section { margin-bottom: 28px; }
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.section-title {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: -0.01em;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text);
}
.section-title svg { width: 16px; height: 16px; color: var(--muted2); }

/* ── Tabs ── */
.tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--stroke);
}
.tab-btn {
  padding: 10px 18px;
  font-size: 13px;
  font-weight: 500;
  border: none;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: var(--muted2);
  transition: color var(--transition), border-color var(--transition);
  margin-bottom: -1px;
  border-radius: 0;
}
.tab-btn:hover { color: var(--text); }
.tab-btn.active { color: var(--oficial); border-bottom-color: var(--oficial); }
.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* ── Filter bar ── */
.filter-bar {
  display: flex;
  gap: 12px;
  align-items: flex-end;
  flex-wrap: wrap;
  padding: 16px 18px;
  background: linear-gradient(135deg, #17171d, #1e1e26);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-sm);
  margin-bottom: 16px;
}
.filter-bar label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted2);
}
.filter-bar select {
  padding: 8px 12px;
  border: 1px solid var(--stroke2);
  border-radius: var(--radius-xs);
  background: var(--bg);
  color: var(--text);
  font-size: 12px;
  min-width: 140px;
  transition: border-color var(--transition);
}
.filter-bar select:focus { outline: none; border-color: var(--oficial); }
.filter-count { font-size: 11px; color: var(--muted2); margin-left: auto; align-self: center; }
.export-group { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.btn-export {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.03em;
  border: 1px solid var(--stroke2);
  border-radius: var(--radius-xs);
  background: var(--surface);
  color: var(--text-secondary);
  transition: all var(--transition);
}
.btn-export svg { width: 12px; height: 12px; }
.btn-export:hover { background: var(--surface2); color: var(--text); }

/* ── Table ── */
.table-scroll {
  overflow-x: auto;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-soft);
}
.data-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.data-table thead tr { border-bottom: 1px solid var(--stroke); }
.data-table th {
  padding: 12px 16px;
  text-align: left;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted2);
  background: var(--surface);
  white-space: nowrap;
}
.data-table td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--stroke);
  vertical-align: middle;
  color: var(--text);
}
.data-table tbody tr:last-child td { border-bottom: none; }
.data-table tbody tr:hover { background: var(--surface); }
.text-right { text-align: right; }
.text-center { text-align: center; }
.fw-600 { font-weight: 600; }
.mono {
  font-family: ui-monospace, "SF Mono", "Cascadia Code", monospace;
  font-size: 12px;
  color: var(--text-secondary);
}
.table-empty { text-align: center; color: var(--muted2); padding: 32px; font-size: 13px; }

/* ── Badges ── */
.badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  border: none;
  white-space: nowrap;
}
.badge-activo, .badge-active, .badge-open {
  background: var(--success-soft);
  color: var(--success);
}
.badge-pendiente, .badge-pending {
  background: var(--accent-secondary-soft);
  color: var(--accent-secondary);
}
.badge-cerrado, .badge-closed, .badge-inactive {
  background: var(--surface);
  color: var(--muted2);
  border: 1px solid var(--stroke2);
}
.badge-baja, .badge-cancelled {
  background: var(--danger-soft);
  color: var(--danger);
}

/* ── Forms ── */
.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px 24px;
}
.form-field,
.form-group {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.form-grid .full,
.form-grid .full-width { grid-column: 1 / -1; }
.form-field label,
.form-group label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted2);
}
.form-field input,
.form-field select,
.form-field textarea,
.form-group input,
.form-group select,
.form-group textarea {
  box-sizing: border-box;
  width: 100%;
  padding: 10px 14px;
  border: 1px solid rgba(23,23,29,.9);
  border-radius: var(--radius-xs);
  background: radial-gradient(circle at top left, rgba(158,33,71,.12), transparent 55%), var(--bg-elevated);
  color: var(--text-primary);
  font-size: 14px;
  line-height: 1.4;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.form-field input:focus,
.form-field select:focus,
.form-group input:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(158,33,71,.25);
}
.form-field input:disabled,
.form-field select:disabled,
.form-group input:disabled,
.form-group select:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
@media (max-width: 768px) {
  .form-grid { grid-template-columns: 1fr; }
  .form-grid .full,
  .form-grid .full-width { grid-column: 1; }
}
.req { color: var(--accent); font-weight: 600; }
.select-wrap { width: 100%; }
.form-error {
  padding: 12px 16px;
  border-radius: var(--radius-xs);
  border: 1px solid rgba(158,33,71,.35);
  background: var(--danger-soft);
  color: var(--danger);
  font-size: 12px;
  line-height: 1.5;
}
.form-success {
  padding: 14px 16px;
  border-radius: var(--radius-xs);
  border: 1px solid rgba(232,132,35,.35);
  background: var(--success-soft);
  color: var(--success);
  font-size: 13px;
  line-height: 1.5;
}
.status-text { font-size: 12px; color: var(--muted2); margin-bottom: 12px; min-height: 18px; }

/* ── Progress ── */
.progress-track {
  height: 6px;
  border-radius: 999px;
  background: var(--stroke);
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary));
  transition: width 0.5s ease;
}

/* ── Info rows ── */
.info-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 10px 0;
  border-bottom: 1px solid var(--stroke);
}
.info-row:last-child { border-bottom: none; }
.info-label {
  font-size: 11px;
  color: var(--muted2);
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}
.info-value { font-size: 13px; font-weight: 500; text-align: right; max-width: 60%; word-break: break-word; }

/* ── Dashboard grid ── */
.cards-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1.4fr);
  gap: 18px;
}
.card-full { grid-column: 1 / -1; }
.dashboard-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 26px;
}
.welcome-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 12px;
}
.welcome-header h1 { font-size: 22px; font-weight: 600; letter-spacing: -0.02em; }
.welcome-header p { font-size: 13px; color: var(--text-secondary); margin-top: 4px; }
.student-id {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  background: rgba(232,132,35,.1);
  color: var(--oficial);
  white-space: nowrap;
  border: 1px solid rgba(232,132,35,.2);
}

/* ── Landing (hero minimalista) ── */
.landing-hero {
  max-width: 1120px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr);
  align-items: center;
  gap: 28px;
  min-height: calc(100vh - 100px);
  padding: 48px 24px;
}
.landing-main { text-align: left; }
.landing-logotype {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  margin-bottom: 28px;
  background: linear-gradient(135deg, var(--oficial), var(--accent-soft));
  opacity: 0.95;
}
.landing-hero h1 {
  font-size: 28px;
  font-weight: 600;
  letter-spacing: -0.03em;
  max-width: 560px;
  line-height: 1.25;
  color: var(--text);
  margin-bottom: 12px;
}
.landing-hero p {
  font-size: 15px;
  color: var(--text-secondary);
  margin-bottom: 40px;
  max-width: 440px;
  line-height: 1.65;
}
.landing-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: flex-start;
  margin-bottom: 40px;
}
.action-card {
  width: 200px;
  padding: 28px 24px;
  text-align: center;
  border-radius: var(--radius);
  border: 1px solid var(--stroke);
  background: var(--surface);
  transition: all var(--transition);
  display: block;
}
.action-card:hover {
  background: var(--surface2);
  border-color: var(--stroke2);
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}
.action-card-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  margin: 0 auto 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--stroke2);
}
.action-card-icon svg { width: 20px; height: 20px; color: var(--text-secondary); }
.action-card .ac-title { font-size: 14px; font-weight: 600; margin-bottom: 4px; }
.action-card .ac-sub { font-size: 12px; color: var(--muted2); }
.action-card.primary-card {
  border-color: rgba(232,132,35,.3);
  background: rgba(232,132,35,.06);
}
.action-card.primary-card .action-card-icon {
  background: rgba(232,132,35,.12);
  border-color: rgba(232,132,35,.25);
  color: var(--oficial);
}
.action-card.secondary-card {
  border-color: rgba(158,33,71,.25);
  background: rgba(158,33,71,.05);
}
.action-card.secondary-card .action-card-icon {
  background: rgba(158,33,71,.1);
  border-color: rgba(158,33,71,.2);
  color: #FEE5C3;
}
.asesor-link {
  font-size: 12px;
  color: var(--muted2);
  letter-spacing: 0.02em;
  padding-bottom: 2px;
  border-bottom: 1px solid var(--stroke2);
  transition: color var(--transition);
}
.asesor-link:hover { color: var(--text-secondary); }

/* ── Not registered / empty state ── */
.not-registered {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 100px);
  text-align: center;
  padding: 40px 24px;
}
.not-registered h2 { font-size: 22px; font-weight: 600; margin-bottom: 12px; letter-spacing: -0.02em; }
.not-registered p {
  font-size: 14px;
  color: var(--text-secondary);
  max-width: 400px;
  line-height: 1.65;
  margin-bottom: 24px;
}

/* ── Enrollments table ── */
.enrollments-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.enrollments-table th {
  padding: 10px 14px;
  text-align: left;
  font-size: 10px;
  color: var(--muted2);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.enrollments-table td { padding: 12px 14px; border-top: 1px solid var(--stroke); }

/* ── App shell (asesor) ── */
.app-root { display: flex; gap: 20px; min-height: calc(100vh - 80px); }
.app-sidebar {
  width: 220px;
  flex-shrink: 0;
  background: linear-gradient(160deg, rgba(17,17,24,.98), rgba(20,20,30,.98));
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  padding: 20px 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  position: sticky;
  top: 84px;
  height: fit-content;
}
.sidebar-user-name { font-size: 14px; font-weight: 600; padding: 6px 10px 4px; }
.sidebar-user-role {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.04em;
  padding: 4px 10px;
  border-radius: 6px;
  display: inline-block;
  margin: 0 10px 14px;
  background: var(--accent-secondary-softer);
  color: var(--accent-secondary);
}
.sidebar-divider { height: 1px; background: var(--stroke); margin: 8px 6px; }
.menu-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: none;
  background: transparent;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 500;
  width: 100%;
  text-align: left;
  transition: background var(--transition), color var(--transition);
}
.menu-btn svg { width: 16px; height: 16px; flex-shrink: 0; opacity: 0.8; }
.menu-btn:hover { background: var(--surface); color: var(--text); }
.menu-btn.active { background: rgba(232,132,35,.1); color: var(--oficial); }
.app-content { flex: 1; padding: 0 20px 24px; overflow: hidden; min-width: 0; }
.app-section { display: none; }
.app-section.active { display: block; }
.app-hero { padding: 24px 0 20px; }
.app-hero h2 { font-size: 20px; font-weight: 600; margin-bottom: 4px; letter-spacing: -0.02em; }
.app-hero p { font-size: 13px; color: var(--text-secondary); }

/* ── Divider ── */
.divider { height: 1px; background: var(--stroke); margin: 24px 0; }

/* ── Footer ── */
.page-footer {
  text-align: center;
  padding: 28px 16px 16px;
  font-size: 11px;
  color: var(--muted2);
  letter-spacing: 0.02em;
}
.page-footer a {
  color: var(--muted2);
  padding-bottom: 1px;
  border-bottom: 1px solid var(--stroke2);
  margin: 0 6px;
  transition: color var(--transition);
}
.page-footer a:hover { color: var(--text-secondary); }

/* ── Helper ── */
.helper-text { font-size: 11px; color: var(--muted2); margin-top: 6px; }

/* ── Modal ── */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(15,15,19,.6);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.modal-box {
  width: 100%;
  max-width: 440px;
  background: var(--bg-elevated);
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 32px 28px;
}
.modal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.modal-header h3 { font-size: 16px; font-weight: 600; }

/* ── Responsive ── */
@media (max-width: 900px) {
  .kpi-grid { grid-template-columns: 1fr 1fr; }
  .cards-grid { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .app-root { flex-direction: column; }
  .app-sidebar { width: 100%; position: static; margin: 0; }
}
@media (max-width: 600px) {
  .topbar { padding: 12px 16px; }
  .topbar-name { font-size: 14px; }
  .topbar-sub { font-size: 10px; }
  .landing-hero h1 { font-size: 22px; }
  .landing-hero p { font-size: 14px; }
  .filter-bar { flex-direction: column; align-items: stretch; }
  .export-group { flex-wrap: wrap; }
  .wrap, .container-sm { padding: 20px 16px 40px; }
}
