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

:root {
  --azul: #1a3a6b;
  --azul-dark: #0f2447;
  --azul-light: #e8f0fb;
  --amarillo: #f0a500;
  --amarillo-dark: #c88900;
  --verde: #27a65c;
  --rojo: #e24b4a;
  --gris: #f5f6fa;
  --gris-borde: #e0e0e0;
  --texto: #1a1a2e;
  --texto-muted: #666;
  --blanco: #ffffff;
  --sombra: 0 4px 24px rgba(26,58,107,0.10);
  --sombra-lg: 0 8px 40px rgba(26,58,107,0.15);
  --radio: 14px;
  --radio-sm: 8px;
  --radio-lg: 20px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: 'Outfit', sans-serif; color: var(--texto); background: var(--gris); min-height: 100vh; }

/* ===== NAVBAR ===== */
.navbar {
  background: var(--azul);
  padding: 0 24px;
  height: 62px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 200;
  box-shadow: 0 2px 16px rgba(0,0,0,0.18);
}
.navbar-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: white;
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -0.3px;
}
.navbar-brand span { color: var(--amarillo); }
.navbar-links { display: flex; align-items: center; gap: 4px; }
.navbar-links a, .btn-nav-link {
  color: rgba(255,255,255,0.85);
  text-decoration: none;
  font-size: 14px;
  padding: 7px 13px;
  border-radius: var(--radio-sm);
  transition: all 0.2s;
  border: none;
  background: none;
  cursor: pointer;
  font-family: inherit;
  font-weight: 500;
}
.navbar-links a:hover, .btn-nav-link:hover { color: white; background: rgba(255,255,255,0.12); }
.btn-nav-premium {
  background: var(--amarillo) !important;
  color: var(--azul-dark) !important;
  font-weight: 700 !important;
  padding: 7px 16px !important;
  border-radius: var(--radio-sm) !important;
}
.btn-nav-premium:hover { background: var(--amarillo-dark) !important; }

/* Hamburguesa mobile */
.nav-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 4px;
  background: none;
  border: none;
}
.nav-hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: white;
  border-radius: 2px;
  transition: all 0.3s;
}
.nav-mobile-menu {
  display: none;
  position: fixed;
  top: 62px;
  left: 0; right: 0;
  background: var(--azul-dark);
  padding: 16px;
  z-index: 199;
  flex-direction: column;
  gap: 4px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}
.nav-mobile-menu.open { display: flex; }
.nav-mobile-menu a, .nav-mobile-menu button {
  color: rgba(255,255,255,0.9);
  text-decoration: none;
  font-size: 15px;
  padding: 12px 16px;
  border-radius: var(--radio-sm);
  border: none;
  background: none;
  cursor: pointer;
  font-family: inherit;
  font-weight: 500;
  text-align: left;
  width: 100%;
}
.nav-mobile-menu a:hover, .nav-mobile-menu button:hover { background: rgba(255,255,255,0.1); }
.nav-mobile-menu .btn-mobile-premium {
  background: var(--amarillo);
  color: var(--azul-dark);
  font-weight: 700;
  margin-top: 8px;
  text-align: center;
}

/* ===== PÁGINAS ===== */
.page { display: none; min-height: calc(100vh - 62px); }
.page.active { display: block; }

/* ===== HERO ===== */
.hero {
  background: linear-gradient(135deg, var(--azul-dark) 0%, var(--azul) 55%, #2a5298 100%);
  color: white;
  padding: 72px 24px 80px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  top: -40%;
  right: -10%;
  width: 500px;
  height: 500px;
  background: rgba(255,255,255,0.03);
  border-radius: 50%;
}
.hero::after {
  content: '';
  position: absolute;
  bottom: -30%;
  left: -5%;
  width: 400px;
  height: 400px;
  background: rgba(240,165,0,0.06);
  border-radius: 50%;
}
.hero-content { position: relative; z-index: 1; max-width: 680px; margin: 0 auto; }
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(240,165,0,0.15);
  border: 1px solid rgba(240,165,0,0.4);
  color: var(--amarillo);
  font-size: 13px;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 20px;
  margin-bottom: 20px;
}
.hero h1 { font-size: 52px; font-weight: 800; margin-bottom: 18px; line-height: 1.15; letter-spacing: -0.5px; }
.hero h1 span { color: var(--amarillo); }
.hero p { font-size: 17px; opacity: 0.88; margin-bottom: 36px; line-height: 1.6; }
.hero-btns { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-bottom: 48px; }
.hero-stats {
  display: flex;
  justify-content: center;
  gap: 40px;
  flex-wrap: wrap;
  padding-top: 32px;
  border-top: 1px solid rgba(255,255,255,0.12);
}
.hero-stat { text-align: center; }
.hero-stat-num { font-size: 28px; font-weight: 800; color: var(--amarillo); }
.hero-stat-label { font-size: 13px; opacity: 0.75; margin-top: 2px; }

/* ===== BOTONES ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 28px;
  border-radius: var(--radio-sm);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  text-decoration: none;
  transition: all 0.2s;
  font-family: inherit;
  white-space: nowrap;
}
.btn-primary { background: var(--amarillo); color: var(--azul-dark); }
.btn-primary:hover { background: var(--amarillo-dark); transform: translateY(-1px); box-shadow: 0 4px 16px rgba(240,165,0,0.4); }
.btn-outline { background: transparent; color: white; border: 2px solid rgba(255,255,255,0.4); }
.btn-outline:hover { border-color: white; background: rgba(255,255,255,0.1); }
.btn-azul { background: var(--azul); color: white; }
.btn-azul:hover { background: var(--azul-dark); }
.btn-rojo { background: var(--rojo); color: white; }
.btn-verde { background: var(--verde); color: white; }
.btn-block { width: 100%; }
.btn-lg { padding: 15px 36px; font-size: 16px; }
.btn:disabled { opacity: 0.6; cursor: not-allowed; transform: none !important; }

/* ===== FEATURES ===== */
.features-section { padding: 72px 24px; background: white; }
.features-section h2 { text-align: center; font-size: 30px; font-weight: 700; color: var(--azul); margin-bottom: 8px; }
.features-subtitle { text-align: center; color: var(--texto-muted); font-size: 15px; margin-bottom: 48px; }
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 28px; max-width: 900px; margin: 0 auto; }
.feature-card {
  text-align: center;
  padding: 28px 20px;
  border-radius: var(--radio);
  border: 1px solid var(--gris-borde);
  transition: all 0.2s;
}
.feature-card:hover { border-color: var(--azul); box-shadow: var(--sombra); transform: translateY(-3px); }
.feature-icon { font-size: 36px; margin-bottom: 14px; }
.feature-card h3 { font-size: 16px; font-weight: 700; color: var(--azul); margin-bottom: 8px; }
.feature-card p { font-size: 13px; color: var(--texto-muted); line-height: 1.6; }

/* ===== TESTIMONIOS ===== */
.testimonios-section { padding: 72px 24px; background: var(--gris); }
.testimonios-section h2 { text-align: center; font-size: 28px; font-weight: 700; color: var(--azul); margin-bottom: 40px; }
.testimonios-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; max-width: 900px; margin: 0 auto; }
.testimonio-card {
  background: white;
  border-radius: var(--radio);
  padding: 24px;
  box-shadow: var(--sombra);
}
.testimonio-stars { color: var(--amarillo); font-size: 16px; margin-bottom: 10px; }
.testimonio-texto { font-size: 14px; color: var(--texto-muted); line-height: 1.6; margin-bottom: 14px; font-style: italic; }
.testimonio-autor { font-size: 13px; font-weight: 700; color: var(--azul); }
.testimonio-ciudad { font-size: 12px; color: var(--texto-muted); }

/* ===== PLANES ===== */
.planes-section { padding: 72px 24px; background: white; }
.planes-section h2 { text-align: center; font-size: 30px; font-weight: 700; color: var(--azul); margin-bottom: 8px; }
.planes-subtitle { text-align: center; color: var(--texto-muted); margin-bottom: 48px; font-size: 15px; }
.planes-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 24px; max-width: 680px; margin: 0 auto; }
.plan-card {
  border: 2px solid var(--gris-borde);
  border-radius: var(--radio);
  padding: 32px 24px;
  text-align: center;
  transition: all 0.2s;
  background: white;
  position: relative;
}
.plan-card:hover { border-color: var(--azul); transform: translateY(-4px); box-shadow: var(--sombra-lg); }
.plan-card.destacado { border-color: var(--amarillo); }
.plan-badge {
  position: absolute;
  top: -13px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--amarillo);
  color: var(--azul-dark);
  font-size: 11px;
  font-weight: 700;
  padding: 4px 16px;
  border-radius: 20px;
  white-space: nowrap;
  letter-spacing: 0.3px;
}
.plan-icon { font-size: 38px; margin-bottom: 12px; }
.plan-nombre { font-size: 19px; font-weight: 700; color: var(--azul); margin-bottom: 4px; }
.plan-duracion { font-size: 13px; color: var(--texto-muted); margin-bottom: 18px; }
.plan-precio { font-size: 38px; font-weight: 800; color: var(--texto); margin-bottom: 4px; line-height: 1; }
.plan-precio small { font-size: 15px; color: var(--texto-muted); font-weight: 400; }
.plan-features { list-style: none; margin: 18px 0 24px; text-align: left; }
.plan-features li { padding: 5px 0; font-size: 13px; color: var(--texto-muted); display: flex; gap: 8px; align-items: flex-start; }
.plan-features li::before { content: '✓'; color: var(--verde); font-weight: 700; flex-shrink: 0; }
.planes-garantia { text-align: center; margin-top: 24px; font-size: 13px; color: var(--texto-muted); }

/* ===== CARDS GENERALES ===== */
.card { background: white; border-radius: var(--radio); padding: 24px; box-shadow: var(--sombra); }
.container { max-width: 960px; margin: 0 auto; padding: 0 16px; }
.section { padding: 40px 16px; }

/* ===== AUTH FORMS ===== */
.auth-page {
  min-height: calc(100vh - 62px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  background: linear-gradient(135deg, var(--azul-dark) 0%, var(--azul) 100%);
}
.auth-card {
  background: white;
  border-radius: var(--radio);
  padding: 36px 32px;
  width: 100%;
  max-width: 420px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.25);
}
.auth-logo { text-align: center; font-size: 22px; font-weight: 800; color: var(--azul); margin-bottom: 20px; }
.auth-logo span { color: var(--amarillo); }
.auth-card h2 { font-size: 22px; font-weight: 700; color: var(--azul); margin-bottom: 4px; }
.auth-card p { font-size: 13px; color: var(--texto-muted); margin-bottom: 24px; }
.form-group { margin-bottom: 16px; }
.form-group label { display: block; font-size: 13px; font-weight: 600; color: var(--texto); margin-bottom: 5px; }
.form-group input {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid var(--gris-borde);
  border-radius: var(--radio-sm);
  font-size: 15px;
  font-family: inherit;
  color: var(--texto);
  transition: border-color 0.2s;
  background: white;
  -webkit-appearance: none;
}
.form-group input:focus { outline: none; border-color: var(--azul); box-shadow: 0 0 0 3px rgba(26,58,107,0.08); }
.form-error { color: var(--rojo); font-size: 13px; margin-top: 10px; display: none; padding: 8px 12px; background: #fef0f0; border-radius: var(--radio-sm); border-left: 3px solid var(--rojo); }
.form-error.show { display: block; }
.auth-switch { text-align: center; margin-top: 18px; font-size: 14px; color: var(--texto-muted); }
.auth-switch a { color: var(--azul); font-weight: 600; text-decoration: none; cursor: pointer; }

/* ===== DASHBOARD ===== */
.dashboard-header {
  background: linear-gradient(135deg, var(--azul-dark), var(--azul));
  color: white;
  padding: 28px 24px;
}
.dashboard-header h2 { font-size: 20px; font-weight: 700; }
.dashboard-header p { font-size: 13px; opacity: 0.8; margin-top: 4px; }
.plan-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(240,165,0,0.2);
  border: 1px solid rgba(240,165,0,0.4);
  color: var(--amarillo);
  font-size: 12px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 20px;
  margin-top: 6px;
}
.stats-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin-bottom: 20px; }
.stat-card {
  background: white;
  border-radius: var(--radio);
  padding: 18px 16px;
  text-align: center;
  box-shadow: var(--sombra);
}
.stat-card .stat-num { font-size: 28px; font-weight: 800; color: var(--azul); }
.stat-card .stat-label { font-size: 12px; color: var(--texto-muted); margin-top: 3px; }

/* ===== SIMULADOR ===== */
.exam-header {
  background: var(--azul);
  color: white;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 62px;
  z-index: 50;
}
.exam-header h1 { font-size: 13px; font-weight: 600; opacity: 0.9; }
.timer-box {
  background: var(--amarillo);
  color: var(--azul-dark);
  border-radius: var(--radio-sm);
  padding: 5px 12px;
  font-size: 15px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 5px;
}
.timer-urgent { background: var(--rojo) !important; color: white !important; }
.exam-layout { display: flex; min-height: calc(100vh - 120px); }
.exam-area {
  flex: 1;
  padding: 24px 20px;
  background: white;
  border-right: 1px solid var(--gris-borde);
  min-width: 0;
}
.exam-sidebar {
  width: 230px;
  padding: 16px;
  background: var(--gris);
  flex-shrink: 0;
}
.q-label { font-size: 11px; font-weight: 700; color: var(--texto-muted); margin-bottom: 5px; text-transform: uppercase; letter-spacing: 0.5px; }
.q-badge {
  display: inline-block;
  background: #fff3cd;
  color: #7a4f00;
  font-size: 11px;
  font-weight: 700;
  border-radius: 4px;
  padding: 3px 8px;
  margin-bottom: 10px;
  border: 1px solid var(--amarillo);
}
.q-text { font-size: 15px; font-weight: 600; line-height: 1.5; margin-bottom: 20px; color: var(--texto); }
.options { display: flex; flex-direction: column; gap: 10px; }
.option-btn {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 12px 14px;
  border: 1.5px solid var(--gris-borde);
  border-radius: var(--radio-sm);
  background: white;
  cursor: pointer; text-align: left;
  font-size: 14px; color: var(--texto);
  transition: all 0.15s;
  font-family: inherit;
  width: 100%;
  -webkit-tap-highlight-color: transparent;
}
.option-btn:hover { border-color: var(--azul); background: var(--azul-light); }
.option-btn:active { transform: scale(0.99); }
.option-btn.selected { border-color: var(--azul); background: var(--azul-light); }
.option-btn.selected .opt-letter { background: var(--azul); color: white; }
.option-btn.correct { border-color: var(--verde); background: #e8f9ee; }
.option-btn.correct .opt-letter { background: var(--verde); color: white; }
.option-btn.wrong { border-color: var(--rojo); background: #fef0f0; }
.option-btn.wrong .opt-letter { background: var(--rojo); color: white; }
.opt-letter {
  min-width: 26px; height: 26px; border-radius: 50%;
  background: var(--gris); border: 1.5px solid var(--gris-borde);
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 700; flex-shrink: 0; margin-top: 1px;
}
.exam-nav { display: flex; gap: 8px; margin-top: 24px; flex-wrap: wrap; }
.btn-exam {
  padding: 9px 18px; border-radius: var(--radio-sm);
  font-size: 14px; font-weight: 600; cursor: pointer;
  border: 1.5px solid var(--gris-borde);
  background: white; color: var(--texto);
  font-family: inherit; transition: all 0.15s;
  -webkit-tap-highlight-color: transparent;
}
.btn-exam:hover { border-color: var(--azul); background: var(--azul-light); }
.btn-exam-primary { background: var(--azul); color: white; border-color: var(--azul); }
.btn-exam-primary:hover { background: var(--azul-dark); }
.btn-exam-danger { background: var(--rojo); color: white; border-color: var(--rojo); margin-left: auto; font-size: 13px; }
.q-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; margin-bottom: 16px; }
.q-cell {
  aspect-ratio: 1; border-radius: 7px; border: 1.5px solid var(--gris-borde);
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 700; cursor: pointer;
  background: white; color: var(--texto-muted); transition: all 0.1s;
  min-height: 36px;
  -webkit-tap-highlight-color: transparent;
}
.q-cell:hover { border-color: var(--azul); color: var(--azul); }
.q-cell.answered { background: var(--azul); color: white; border-color: var(--azul); }
.q-cell.current { border: 2px solid var(--amarillo) !important; }
.q-cell.double { border-color: var(--amarillo); }
.sidebar-label { font-size: 11px; color: var(--texto-muted); font-weight: 700; text-transform: uppercase; letter-spacing: 0.8px; margin-bottom: 10px; }
.legend-item { display: flex; align-items: center; gap: 7px; font-size: 12px; color: var(--texto-muted); margin-bottom: 6px; font-weight: 500; }
.legend-dot { width: 14px; height: 14px; border-radius: 3px; flex-shrink: 0; }
.correction-fb {
  margin-top: 14px; padding: 12px 14px;
  border-radius: var(--radio-sm);
  border-left: 3px solid; font-size: 13px; line-height: 1.5;
}
.fb-correct { border-color: var(--verde); background: #e8f9ee; color: #1a6b3c; }
.fb-wrong { border-color: var(--rojo); background: #fef0f0; color: #a32d2d; }

/* Sidebar móvil del examen (colapsable) */
.exam-sidebar-toggle {
  display: none;
  width: 100%;
  padding: 10px 16px;
  background: var(--azul-dark);
  color: white;
  border: none;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  text-align: center;
}

/* ===== MODAL ===== */
.modal-overlay {
  position: fixed; top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.55);
  display: flex; align-items: center; justify-content: center;
  z-index: 1000;
  padding: 16px;
}
.modal-overlay.hidden { display: none; }
.modal-box {
  background: white; border-radius: var(--radio);
  padding: 32px 24px; max-width: 420px; width: 100%;
  text-align: center;
  box-shadow: 0 24px 64px rgba(0,0,0,0.25);
  animation: modalIn 0.2s ease;
}
@keyframes modalIn { from { transform: scale(0.95); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.modal-box h2 { font-size: 26px; font-weight: 800; margin-bottom: 14px; }
.modal-aprobado h2 { color: var(--verde); }
.modal-reprobado h2 { color: var(--rojo); }
.modal-stat { font-size: 14px; color: var(--texto-muted); margin-bottom: 7px; }
.modal-stat strong { color: var(--texto); font-weight: 700; }
.modal-btns { display: flex; flex-direction: column; gap: 10px; margin-top: 20px; }

/* ===== PLAN EXPIRADO ===== */
.plan-warning {
  background: linear-gradient(135deg, var(--azul-dark), var(--azul));
  min-height: calc(100vh - 62px);
  display: flex; align-items: center; justify-content: center;
  padding: 32px 16px; text-align: center;
}
.plan-warning-card {
  background: white; border-radius: var(--radio);
  padding: 40px 28px; max-width: 460px; width: 100%;
}
.plan-warning-card h2 { font-size: 22px; color: var(--azul); margin-bottom: 10px; }
.plan-warning-card p { color: var(--texto-muted); margin-bottom: 24px; font-size: 14px; line-height: 1.6; }

/* ===== HISTORIAL ===== */
.historial-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.historial-table th { background: var(--gris); padding: 10px 12px; text-align: left; font-weight: 700; font-size: 11px; text-transform: uppercase; letter-spacing: 0.5px; color: var(--texto-muted); }
.historial-table td { padding: 11px 12px; border-bottom: 1px solid var(--gris-borde); }
.historial-table tr:hover td { background: #fafafa; }
.badge { display: inline-block; padding: 3px 10px; border-radius: 20px; font-size: 12px; font-weight: 600; }
.badge-verde { background: #e8f9ee; color: var(--verde); }
.badge-rojo { background: #fef0f0; color: var(--rojo); }
.badge-amarillo { background: #fff8e6; color: var(--amarillo-dark); }

/* ===== ADMIN ===== */
.admin-sidebar {
  width: 210px;
  background: var(--azul-dark);
  min-height: calc(100vh - 62px);
  padding: 16px 0;
  flex-shrink: 0;
}
.admin-sidebar-title { padding: 8px 20px 16px; color: rgba(255,255,255,0.5); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; border-bottom: 1px solid rgba(255,255,255,0.08); margin-bottom: 8px; }
.admin-sidebar a {
  display: flex; align-items: center; gap: 10px;
  padding: 11px 20px; color: rgba(255,255,255,0.7);
  text-decoration: none; font-size: 14px; font-weight: 500;
  transition: all 0.15s; cursor: pointer;
  border: none; background: none; font-family: inherit; width: 100%;
}
.admin-sidebar a:hover, .admin-sidebar a.active { background: rgba(255,255,255,0.1); color: white; }
.admin-main { flex: 1; padding: 24px; overflow-x: auto; }
.admin-layout { display: flex; }
.admin-section { display: none; }
.admin-section.active { display: block; }
.finanzas-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px; margin-bottom: 24px; }
.finanza-card {
  background: white; border-radius: var(--radio); padding: 18px;
  box-shadow: var(--sombra); text-align: center;
}
.finanza-card .f-num { font-size: 26px; font-weight: 800; color: var(--azul); }
.finanza-card .f-label { font-size: 12px; color: var(--texto-muted); margin-top: 3px; }
.finanza-card.verde .f-num { color: var(--verde); }
.finanza-card.amarillo .f-num { color: var(--amarillo-dark); }

/* ===== FOOTER ===== */
.footer {
  background: var(--azul-dark);
  color: rgba(255,255,255,0.6);
  padding: 32px 24px;
  text-align: center;
  font-size: 13px;
}
.footer a { color: rgba(255,255,255,0.6); text-decoration: none; }
.footer a:hover { color: white; }


/* ===== IMAGEN EN PREGUNTA ===== */
.q-img {
  display: block;
  max-width: 220px;
  max-height: 180px;
  margin: 0 0 18px 0;
  border-radius: var(--radio-sm);
  border: 1px solid var(--gris-borde);
  object-fit: contain;
  background: white;
}

/* ===== RESPONSIVE MOBILE ===== */
@media (max-width: 768px) {
  /* Navbar */
  .navbar-links { display: none; }
  .nav-hamburger { display: flex; }

  /* Hero */
  .hero { padding: 48px 20px 56px; }
  .hero h1 { font-size: 32px; letter-spacing: -0.2px; }
  .hero p { font-size: 15px; }
  .hero-btns { flex-direction: column; align-items: center; }
  .hero-btns .btn { width: 100%; max-width: 300px; }
  .hero-stats { gap: 24px; }
  .hero-stat-num { font-size: 24px; }

  /* Features */
  .features-section { padding: 48px 16px; }
  .features-grid { grid-template-columns: 1fr 1fr; gap: 16px; }

  /* Testimonios */
  .testimonios-section { padding: 48px 16px; }

  /* Planes */
  .planes-section { padding: 48px 16px; }
  .planes-grid { grid-template-columns: 1fr; max-width: 360px; }

  /* Auth */
  .auth-card { padding: 28px 20px; }

  /* Dashboard */
  .dashboard-header { padding: 20px 16px; }
  .stats-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .stat-card .stat-num { font-size: 24px; }
  .section { padding: 20px 12px; }
  .card { padding: 16px; }

  /* Examen */
  .exam-layout { flex-direction: column; }
  .exam-area { padding: 16px; border-right: none; border-bottom: 1px solid var(--gris-borde); }
  .exam-sidebar { width: 100%; padding: 12px; }
  .exam-sidebar-toggle { display: block; }
  .exam-sidebar-content { display: none; }
  .exam-sidebar-content.open { display: block; }
  .exam-header h1 { font-size: 12px; }
  .q-text { font-size: 14px; }
  .btn-exam { padding: 10px 14px; font-size: 13px; }
  .btn-exam-danger { font-size: 12px; padding: 10px 12px; }

  /* Admin */
  .admin-sidebar { display: none; }
  .admin-main { padding: 16px; }

  /* Historial tabla scroll */
  .table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }

  /* Modal */
  .modal-box { padding: 24px 18px; }
  .modal-box h2 { font-size: 22px; }
}

@media (max-width: 380px) {
  .hero h1 { font-size: 27px; }
  .features-grid { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .navbar-brand { font-size: 16px; }
}
