/* ═══════════════════════════════════════════════
   YACHAY LAB v6 — DISEÑO PROFESIONAL PREMIUM
   Fuente: Plus Jakarta Sans | JetBrains Mono
═══════════════════════════════════════════════ */
@import url("https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800;900&family=JetBrains+Mono:wght@400;600&display=swap");

:root {
  /* Colores base */
  --bg: #f7f8fc;
  --surface: #ffffff;
  --surface2: #f0f2fa;
  --border: #e4e8f5;
  --border2: #cdd3ec;
  /* Texto */
  --t1: #0a0e1a;
  --t2: #3d4566;
  --t3: #8892b0;
  /* Acento principal */
  --p: #5a5fe0;
  --p-dk: #4449c7;
  --p-lt: #eeeffe;
  --p2: #8056d6;
  /* Acentos secundarios */
  --grn: #0ea876;
  --grn-lt: #e6faf3;
  --red: #e84545;
  --red-lt: #fdeaea;
  --amb: #f0a000;
  --amb-lt: #fef5e0;
  --blu: #2f80ed;
  --blu-lt: #ebf4fe;
  /* Sidebar */
  --sb: #080d1e;
  --sbw: 240px;
  /* Sombras */
  --sh-sm: 0 1px 4px rgba(10, 14, 26, 0.06);
  --sh: 0 4px 16px rgba(10, 14, 26, 0.08);
  --sh-lg: 0 12px 36px rgba(10, 14, 26, 0.12);
  --sh-p: 0 4px 20px rgba(90, 95, 224, 0.3);
  /* Radios */
  --r: 14px;
  --r-sm: 8px;
  --r-xs: 6px;
}

/* ── RESET ── */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html {
  font-size: 14px;
  scroll-behavior: smooth;
}
body {
  font-family: "Plus Jakarta Sans", system-ui, sans-serif;
  background: var(--bg);
  color: var(--t1);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}
button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: inherit;
}
input,
select,
textarea {
  font-family: inherit;
}
::-webkit-scrollbar {
  width: 5px;
  height: 5px;
}
::-webkit-scrollbar-thumb {
  background: var(--border2);
  border-radius: 10px;
}

/* ══════════════════════════════════════════════
   AUTH — PANTALLA DE INICIO
══════════════════════════════════════════════ */

/* Canvas fondo */
#auth-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  width: 100%;
  height: 100%;
}

#auth-screen {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: #060a18;
  display: flex;
  align-items: stretch;
  font-family: "Plus Jakarta Sans", sans-serif;
}

/* ── LADO IZQUIERDO ── */
.auth-left {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 56px 64px;
  position: relative;
  z-index: 1;
  animation: authLeftIn 0.8s cubic-bezier(0.4, 0, 0.2, 1) both;
}
@keyframes authLeftIn {
  from {
    opacity: 0;
    transform: translateX(-28px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.al-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 52px;
}
.al-logo-icon {
  width: 42px;
  height: 42px;
  background: linear-gradient(135deg, #5a5fe0, #8056d6);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  box-shadow: 0 4px 16px rgba(90, 95, 224, 0.4);
  animation: logoPulse 4s ease-in-out infinite alternate;
}
@keyframes logoPulse {
  0% {
    box-shadow: 0 4px 16px rgba(90, 95, 224, 0.4);
  }
  100% {
    box-shadow: 0 4px 28px rgba(90, 95, 224, 0.7);
  }
}
.al-logo-name {
  font-size: 17px;
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.3px;
}
.al-logo-tag {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.3);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  display: block;
  margin-top: 1px;
}

.al-hero {
  margin-bottom: 40px;
}
.al-chip {
  display: inline-flex;
  align-items: center;
  background: rgba(90, 95, 224, 0.15);
  border: 1px solid rgba(165, 180, 255, 0.25);
  color: #a5b4ff;
  font-size: 11px;
  font-weight: 700;
  padding: 5px 14px;
  border-radius: 20px;
  margin-bottom: 18px;
  letter-spacing: 0.05em;
}
.al-headline {
  font-size: clamp(2rem, 3.5vw, 2.8rem);
  font-weight: 900;
  color: #fff;
  line-height: 1.18;
  letter-spacing: -0.04em;
  margin-bottom: 18px;
}
.al-gradient-text {
  background: linear-gradient(135deg, #a5b4ff 0%, #c084fc 50%, #fb7185 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  background-size: 200% auto;
  animation: gradientShift 4s linear infinite alternate;
}
@keyframes gradientShift {
  0% {
    background-position: 0%;
  }
  100% {
    background-position: 100%;
  }
}
.al-desc {
  font-size: 14.5px;
  color: rgba(255, 255, 255, 0.5);
  line-height: 1.75;
  max-width: 460px;
}

/* Stats */
.al-stats {
  display: flex;
  align-items: center;
  gap: 0;
  margin-bottom: 32px;
}
.al-stat {
  display: flex;
  flex-direction: column;
  padding-right: 28px;
}
.al-stat-num {
  font-size: 2.2rem;
  font-weight: 900;
  color: #fff;
  line-height: 1;
  font-family: "Plus Jakarta Sans", sans-serif;
}
.al-stat-txt {
  font-size: 1.6rem;
}
.al-stat-lbl {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.35);
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}
.al-stat-div {
  width: 1px;
  height: 38px;
  background: rgba(255, 255, 255, 0.1);
  margin-right: 28px;
  flex-shrink: 0;
}

/* Checks */
.al-features {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 32px;
}
.al-feat {
  font-size: 13.5px;
  color: rgba(255, 255, 255, 0.55);
  display: flex;
  align-items: center;
  gap: 10px;
}
.al-feat-check {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(16, 185, 129, 0.15);
  border: 1.5px solid rgba(16, 185, 129, 0.35);
  color: #10b981;
  font-size: 11px;
  font-weight: 900;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* Social proof */
.al-social-proof {
  display: flex;
  align-items: center;
  gap: 12px;
}
.al-avatars {
  display: flex;
}
.al-avatars span {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  border: 2px solid #060a18;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  margin-left: -8px;
  transition: 0.2s;
}
.al-avatars span:first-child {
  margin-left: 0;
}
.al-avatars:hover span {
  margin-left: -4px;
}
.al-proof-txt {
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.4);
}
.al-proof-txt strong {
  color: rgba(255, 255, 255, 0.75);
}

/* ── LADO DERECHO ── */
.auth-right {
  width: 480px;
  flex-shrink: 0;
  background: rgba(255, 255, 255, 0.025);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-left: 1px solid rgba(255, 255, 255, 0.06);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px 44px;
  position: relative;
  z-index: 1;
  animation: authRightIn 0.8s cubic-bezier(0.4, 0, 0.2, 1) 0.1s both;
}
@keyframes authRightIn {
  from {
    opacity: 0;
    transform: translateX(28px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Línea decorativa izquierda */
.auth-right::before {
  content: "";
  position: absolute;
  left: 0;
  top: 20%;
  bottom: 20%;
  width: 1px;
  background: linear-gradient(
    180deg,
    transparent,
    rgba(90, 95, 224, 0.4),
    rgba(192, 132, 252, 0.4),
    transparent
  );
}

.auth-card {
  width: 100%;
  max-height: 96vh;
  overflow-y: auto;
  scrollbar-width: none;
}
.auth-card::-webkit-scrollbar {
  display: none;
}

/* Header card */
.ac-header {
  text-align: center;
  margin-bottom: 22px;
}
.ac-logo-badge {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, #5a5fe0, #8056d6);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  margin: 0 auto 10px;
  box-shadow: 0 4px 20px rgba(90, 95, 224, 0.4);
}
.ac-title {
  font-size: 22px;
  font-weight: 900;
  color: #fff;
  letter-spacing: -0.4px;
}
.ac-title em {
  background: linear-gradient(135deg, #a5b4ff, #c084fc);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-style: normal;
}
.ac-sub {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.35);
  margin-top: 4px;
}

/* Tabs */
.ac-tabs {
  display: flex;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 11px;
  padding: 3px;
  gap: 3px;
  margin-bottom: 20px;
}
.ac-tab {
  flex: 1;
  padding: 9px;
  border-radius: 9px;
  font-size: 12.5px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.4);
  transition: 0.2s;
}
.ac-tab.active {
  background: linear-gradient(
    135deg,
    rgba(90, 95, 224, 0.5),
    rgba(128, 86, 214, 0.5)
  );
  color: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

/* Campos */
.field {
  margin-bottom: 13px;
}
.field label {
  display: block;
  font-size: 10.5px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.45);
  margin-bottom: 5px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.field-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 5px;
}
.field-top label {
  margin-bottom: 0;
}

/* Input con ícono */
.field-wrap {
  position: relative;
}
.field-ico {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: rgba(255, 255, 255, 0.25);
  pointer-events: none;
}
.field-wrap input {
  width: 100%;
  padding: 10px 13px 10px 36px;
  background: rgba(255, 255, 255, 0.06);
  border: 1.5px solid rgba(255, 255, 255, 0.09);
  border-radius: 10px;
  color: #fff;
  font-size: 13.5px;
  outline: none;
  transition: 0.25s;
  font-family: inherit;
}
.field-wrap input::placeholder {
  color: rgba(255, 255, 255, 0.2);
}
.field-wrap input:focus {
  border-color: rgba(165, 180, 255, 0.5);
  background: rgba(255, 255, 255, 0.09);
  box-shadow: 0 0 0 3px rgba(90, 95, 224, 0.15);
}
.field-wrap input:focus + .field-ico,
.field-wrap:focus-within .field-ico {
  color: rgba(165, 180, 255, 0.7);
}

/* Inputs sin wrapper (auth en perfil) */
.field input:not(.field-wrap input),
.field select,
.field textarea {
  width: 100%;
  padding: 10px 13px;
  background: rgba(255, 255, 255, 0.06);
  border: 1.5px solid rgba(255, 255, 255, 0.09);
  border-radius: 10px;
  color: #fff;
  font-size: 13.5px;
  outline: none;
  transition: 0.25s;
  font-family: inherit;
}
.field input:not(.field-wrap input)::placeholder {
  color: rgba(255, 255, 255, 0.2);
}
.field input:not(.field-wrap input):focus {
  border-color: rgba(165, 180, 255, 0.5);
  background: rgba(255, 255, 255, 0.09);
}
.field select option {
  background: #1a2040;
  color: #fff;
}
.field textarea {
  background: rgba(255, 255, 255, 0.06);
  border: 1.5px solid rgba(255, 255, 255, 0.09);
  border-radius: 10px;
  color: #fff;
  font-size: 13.5px;
  outline: none;
  resize: vertical;
  min-height: 72px;
}
.field textarea:focus {
  border-color: rgba(165, 180, 255, 0.5);
}

.forgot-link {
  font-size: 11px;
  color: #a5b4ff;
  font-weight: 600;
  text-decoration: none;
  opacity: 0.7;
  transition: 0.15s;
}
.forgot-link:hover {
  opacity: 1;
}
.strength-wrap {
  margin-top: 6px;
}
.strength-bar {
  display: flex;
  gap: 4px;
}
.strength-bar div {
  flex: 1;
  height: 3px;
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.1);
  transition: 0.3s;
}
.strength-lbl {
  font-size: 10.5px;
  color: rgba(255, 255, 255, 0.4);
  margin-top: 3px;
  display: block;
}
.auth-err {
  font-size: 11.5px;
  color: #fb7185;
  font-weight: 600;
  margin-bottom: 8px;
  min-height: 16px;
}

/* Botón principal */
.btn-auth {
  width: 100%;
  padding: 12px 16px;
  background: linear-gradient(135deg, #5a5fe0, #8056d6);
  color: #fff;
  border: none;
  border-radius: 11px;
  font-size: 13.5px;
  font-weight: 800;
  cursor: pointer;
  transition: 0.25s;
  margin-bottom: 6px;
  box-shadow: 0 4px 20px rgba(90, 95, 224, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: inherit;
}
.btn-auth:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(90, 95, 224, 0.55);
}
.btn-auth:active {
  transform: translateY(0);
}

/* Divider */
.auth-divider {
  text-align: center;
  color: rgba(255, 255, 255, 0.2);
  font-size: 11.5px;
  margin: 14px 0;
  position: relative;
}
.auth-divider::before,
.auth-divider::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 36%;
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
}
.auth-divider::before {
  left: 0;
}
.auth-divider::after {
  right: 0;
}

/* Botón invitado */
.btn-guest {
  width: 100%;
  padding: 11px 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1.5px solid rgba(255, 255, 255, 0.1);
  border-radius: 11px;
  color: rgba(255, 255, 255, 0.65);
  display: flex;
  align-items: center;
  gap: 10px;
  transition: 0.25s;
  cursor: pointer;
  text-align: left;
  font-family: inherit;
}
.btn-guest:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
  color: #fff;
  transform: translateY(-1px);
}
.bg-globe {
  font-size: 22px;
  flex-shrink: 0;
}
.bg-body {
  flex: 1;
  min-width: 0;
}
.bg-title {
  display: block;
  font-size: 13px;
  font-weight: 700;
}
.bg-sub {
  display: block;
  font-size: 10.5px;
  color: rgba(255, 255, 255, 0.35);
  margin-top: 1px;
}
.bg-arrow {
  color: rgba(255, 255, 255, 0.25);
  flex-shrink: 0;
  transition: 0.2s;
}
.btn-guest:hover .bg-arrow {
  color: rgba(255, 255, 255, 0.7);
  transform: translateX(3px);
}

/* Idioma */
.auth-lang {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 14px;
}
.alang {
  background: rgba(255, 255, 255, 0.05);
  border: 1.5px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 5px 14px;
  font-size: 11.5px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.35);
  cursor: pointer;
  transition: 0.15s;
  font-family: inherit;
}
.alang.active {
  background: rgba(90, 95, 224, 0.25);
  border-color: rgba(165, 180, 255, 0.35);
  color: #a5b4ff;
}

/* Responsive auth */
@media (max-width: 900px) {
  .auth-left {
    display: none;
  }
  .auth-right {
    width: 100%;
    border-left: none;
    padding: 28px 24px;
  }
  .auth-right::before {
    display: none;
  }
}
@media (max-width: 400px) {
  .auth-right {
    padding: 20px 16px;
  }
}

/* ══════════════════════════════════════════════
   SIDEBAR
══════════════════════════════════════════════ */
#sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: var(--sbw);
  height: 100vh;
  background: var(--sb);
  display: flex;
  flex-direction: column;
  z-index: 100;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.08) transparent;
  border-right: 1px solid rgba(255, 255, 255, 0.05);
}
.sb-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 22px 16px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  flex-shrink: 0;
}
.sb-brand-icon {
  font-size: 24px;
}
.sb-name {
  display: block;
  font-size: 15px;
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.3px;
}
.sb-tagline {
  display: block;
  font-size: 9.5px;
  color: rgba(255, 255, 255, 0.3);
  margin-top: 1px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.nav-section {
  padding: 8px 8px 0;
}
.nav-label {
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.4px;
  color: rgba(255, 255, 255, 0.22);
  padding: 14px 10px 5px;
}
.nav-btn {
  display: flex;
  align-items: center;
  gap: 9px;
  width: 100%;
  padding: 8px 10px;
  border-radius: 7px;
  color: rgba(255, 255, 255, 0.5);
  font-size: 12.5px;
  font-weight: 500;
  text-align: left;
  transition: 0.15s;
  margin-bottom: 1px;
}
.nav-btn:hover {
  background: rgba(255, 255, 255, 0.07);
  color: rgba(255, 255, 255, 0.85);
}
.nav-btn.active {
  background: rgba(90, 95, 224, 0.18);
  color: #fff;
  font-weight: 600;
}
.nav-btn.active .ni {
  opacity: 1;
}
.ni {
  font-size: 14px;
  flex-shrink: 0;
  opacity: 0.6;
}
.nav-pill {
  margin-left: auto;
  background: linear-gradient(135deg, #5a5fe0, #8056d6);
  color: #fff;
  font-size: 9px;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 20px;
  letter-spacing: 0.05em;
}
.sb-usercard {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: auto 8px 8px;
  padding: 11px 10px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 9px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  cursor: pointer;
  transition: 0.15s;
  flex-shrink: 0;
}
.sb-usercard:hover {
  background: rgba(255, 255, 255, 0.09);
}
.sb-avatar {
  font-size: 20px;
  flex-shrink: 0;
}
.sb-userinfo {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1px;
}
.sb-userinfo span {
  font-size: 12px;
  font-weight: 600;
  color: #fff;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sb-userinfo small {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.32);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sb-logout {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.3);
  padding: 4px;
  transition: 0.15s;
  flex-shrink: 0;
}
.sb-logout:hover {
  color: #ef4444;
}

/* ══════════════════════════════════════════════
   MAIN / TOPBAR
══════════════════════════════════════════════ */
#main {
  margin-left: var(--sbw);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
#topbar {
  position: sticky;
  top: 0;
  height: 52px;
  background: rgba(247, 248, 252, 0.9);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 22px;
  z-index: 50;
  box-shadow: var(--sh-sm);
}
#menu-btn {
  color: var(--t2);
  padding: 6px;
  border-radius: 6px;
  display: flex;
  transition: 0.15s;
}
#menu-btn:hover {
  background: var(--surface2);
}
.tb-breadcrumb {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: 1;
  font-size: 13px;
}
.tb-brand {
  font-weight: 700;
  color: var(--p);
}
.tb-sep {
  color: var(--border2);
}
#page-title {
  color: var(--t2);
  font-weight: 600;
}
.tb-right {
  display: flex;
  align-items: center;
  gap: 8px;
}
.lang-toggle {
  display: flex;
  align-items: center;
  gap: 5px;
  background: var(--surface2);
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: 5px 11px;
  font-size: 12px;
  font-weight: 600;
  color: var(--t2);
  transition: 0.2s;
}
.lang-toggle:hover {
  border-color: var(--p);
  color: var(--p);
  background: var(--p-lt);
}
.tb-user {
  display: flex;
  align-items: center;
  gap: 7px;
  background: var(--p-lt);
  border: 1.5px solid rgba(90, 95, 224, 0.2);
  border-radius: 9px;
  padding: 5px 12px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--p);
  transition: 0.2s;
  max-width: 160px;
  overflow: hidden;
}
.tb-user:hover {
  background: #e3e4fa;
}

/* ══════════════════════════════════════════════
   VISTAS
══════════════════════════════════════════════ */
#content {
  flex: 1;
}
.view {
  display: none;
}
.view.active {
  display: block;
}

/* ══════════════════════════════════════════════
   HOME — HERO
══════════════════════════════════════════════ */
#view-home {
  padding: 0;
}
.home-hero {
  position: relative;
  background: linear-gradient(135deg, #080d1e 0%, #0f1735 50%, #080d1e 100%);
  min-height: 460px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
  padding: 60px 52px 0;
}
#hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.35;
  pointer-events: none;
}
.hh-content {
  position: relative;
  z-index: 2;
  max-width: 640px;
  padding-bottom: 32px;
}
.hh-chip {
  display: inline-flex;
  align-items: center;
  background: rgba(90, 95, 224, 0.2);
  border: 1px solid rgba(165, 180, 255, 0.3);
  color: #a5b4ff;
  font-size: 11.5px;
  font-weight: 700;
  padding: 5px 14px;
  border-radius: 20px;
  margin-bottom: 20px;
  letter-spacing: 0.04em;
}
.hh-title {
  font-size: 3rem;
  font-weight: 900;
  color: #fff;
  line-height: 1.15;
  letter-spacing: -0.04em;
  margin-bottom: 16px;
}
.hh-title em {
  background: linear-gradient(135deg, #a5b4ff, #c084fc);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-style: normal;
}
.hh-desc {
  font-size: 15px;
  color: rgba(255, 255, 255, 0.55);
  line-height: 1.75;
  margin-bottom: 28px;
  max-width: 520px;
}
.hh-btns {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.hb-primary {
  display: flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, #5a5fe0, #8056d6);
  color: #fff;
  padding: 12px 24px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 700;
  box-shadow: 0 4px 20px rgba(90, 95, 224, 0.45);
  transition: 0.2s;
}
.hb-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(90, 95, 224, 0.55);
}
.hb-secondary {
  background: rgba(255, 255, 255, 0.08);
  border: 1.5px solid rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.85);
  padding: 12px 22px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  transition: 0.2s;
}
.hb-secondary:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
}
.hh-metrics {
  display: flex;
  align-items: center;
  gap: 0;
  background: rgba(255, 255, 255, 0.04);
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  margin: 0 -52px;
  padding: 20px 52px;
  position: relative;
  z-index: 2;
}
.hm-item {
  display: flex;
  flex-direction: column;
  padding: 0 28px 0 0;
}
.hm-num {
  font-size: 1.7rem;
  font-weight: 900;
  color: #fff;
  line-height: 1;
  font-family: "Plus Jakarta Sans", sans-serif;
}
.hm-lbl {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.4);
  margin-top: 3px;
  text-transform: uppercase;
  letter-spacing: 0.07em;
}
.hm-div {
  width: 1px;
  height: 36px;
  background: rgba(255, 255, 255, 0.1);
  margin-right: 28px;
  flex-shrink: 0;
}

/* PROBLEMA */
.home-problem {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
  padding: 60px 52px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}
.section-chip {
  display: inline-flex;
  align-items: center;
  background: var(--p-lt);
  color: var(--p);
  font-size: 11.5px;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 14px;
  border: 1px solid rgba(90, 95, 224, 0.15);
}
.home-problem h2 {
  font-size: 1.7rem;
  font-weight: 800;
  color: var(--t1);
  letter-spacing: -0.03em;
  margin-bottom: 16px;
  line-height: 1.3;
}
.home-problem p {
  font-size: 14px;
  color: var(--t2);
  line-height: 1.75;
  margin-bottom: 12px;
}
.home-problem p strong {
  color: var(--t1);
}
.prob-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.pc-item {
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: var(--r-sm);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  transition: 0.2s;
}
.pc-item:hover {
  border-color: var(--p);
  background: var(--p-lt);
}
.pci-ico {
  font-size: 22px;
  margin-bottom: 6px;
}
.pc-item strong {
  font-size: 13px;
  font-weight: 700;
  color: var(--t1);
}
.pc-item span {
  font-size: 12px;
  color: var(--t3);
  line-height: 1.5;
}

/* SIMULADORES */
.home-sims {
  padding: 60px 52px;
  background: var(--bg);
}
.section-header {
  margin-bottom: 28px;
}
.section-header h2 {
  font-size: 1.7rem;
  font-weight: 800;
  color: var(--t1);
  letter-spacing: -0.03em;
  margin-bottom: 6px;
}
.section-header p {
  font-size: 14px;
  color: var(--t3);
}
.sim-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 16px;
}
.sg-card {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--r);
  overflow: hidden;
  cursor: pointer;
  transition: 0.25s;
  box-shadow: var(--sh-sm);
}
.sg-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--sh-lg);
  border-color: var(--p);
}
.sg-card.featured {
  grid-column: span 1;
}
.sgc-top {
  padding: 22px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 80px;
}
.sgc-ico {
  font-size: 2rem;
}
.sgc-badge {
  font-size: 10.5px;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  padding: 3px 10px;
  border-radius: 20px;
  letter-spacing: 0.04em;
}
.sgc-body {
  padding: 16px 20px 20px;
}
.sgc-body h3 {
  font-size: 14px;
  font-weight: 700;
  color: var(--t1);
  margin-bottom: 6px;
}
.sgc-body p {
  font-size: 12.5px;
  color: var(--t3);
  line-height: 1.6;
}
.sgc-formula {
  margin-top: 10px;
  font-family: "JetBrains Mono", monospace;
  font-size: 11px;
  color: var(--p);
  background: var(--p-lt);
  border-radius: 6px;
  padding: 6px 10px;
}
.sim-grid-more {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.btn-outline {
  padding: 8px 16px;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  color: var(--t2);
  cursor: pointer;
  transition: 0.15s;
}
.btn-outline:hover {
  border-color: var(--p);
  color: var(--p);
  background: var(--p-lt);
}

/* FEATURES IA + ELO */
.home-features {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  padding: 60px 52px;
  background: var(--surface);
  border-top: 1px solid var(--border);
}
.hf-card {
  border: 1.5px solid var(--border);
  border-radius: var(--r);
  padding: 28px;
  cursor: pointer;
  transition: 0.2s;
  background: var(--bg);
}
.hf-card:hover {
  border-color: var(--p);
  transform: translateY(-2px);
  box-shadow: var(--sh);
}
.hfc-icon {
  font-size: 2.2rem;
  margin-bottom: 14px;
}
.hf-card h3 {
  font-size: 16px;
  font-weight: 800;
  color: var(--t1);
  margin-bottom: 8px;
}
.hf-card p {
  font-size: 13px;
  color: var(--t3);
  line-height: 1.65;
  margin-bottom: 18px;
}
.demo-msg {
  font-size: 12.5px;
  border-radius: 10px;
  padding: 10px 14px;
  margin-bottom: 8px;
  line-height: 1.5;
}
.demo-msg.a {
  background: var(--surface2);
  border: 1px solid var(--border);
  color: var(--t2);
}
.demo-msg.b {
  background: linear-gradient(135deg, var(--p), var(--p2));
  color: #fff;
}
.elo-demo {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  padding: 14px;
  margin-bottom: 16px;
}
.ed-label {
  font-size: 11px;
  color: var(--t3);
  text-transform: uppercase;
  letter-spacing: 0.07em;
  margin-bottom: 6px;
}
.ed-elo {
  font-size: 2rem;
  font-weight: 900;
  color: var(--p);
  font-family: "JetBrains Mono", monospace;
  margin-bottom: 8px;
}
.ed-bar {
  height: 7px;
  background: var(--border);
  border-radius: 20px;
  overflow: hidden;
  margin-bottom: 4px;
}
.ed-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--p), var(--p2));
  border-radius: 20px;
  width: 50%;
  transition: width 0.5s ease;
}
.ed-range {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  color: var(--t3);
}
.hfc-btn {
  font-size: 13px;
  font-weight: 700;
  color: var(--p);
  padding: 0;
  transition: 0.15s;
}
.hfc-btn:hover {
  color: var(--p-dk);
}

/* TECH */
.home-tech {
  padding: 44px 52px;
  background: var(--bg);
  border-top: 1px solid var(--border);
  text-align: center;
}
.home-tech h2 {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--t1);
  margin-bottom: 16px;
}
.tech-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}
.tech-pills span {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 20px;
  padding: 6px 16px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--t2);
}

/* ══════════════════════════════════════════════
   TUTOR IA
══════════════════════════════════════════════ */
.tutor-wrap {
  max-width: 760px;
  margin: 0 auto;
  padding: 28px;
  display: flex;
  flex-direction: column;
  height: calc(100vh - 52px);
}
.tutor-head {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--r);
  padding: 18px 22px;
  margin-bottom: 16px;
  flex-shrink: 0;
  box-shadow: var(--sh-sm);
}
.tutor-avatar {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, #5a5fe0, #8056d6);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  flex-shrink: 0;
  box-shadow: var(--sh-p);
}
.tutor-head-info {
  flex: 1;
}
.tutor-head-info h2 {
  font-size: 16px;
  font-weight: 800;
  color: var(--t1);
}
.tutor-head-info p {
  font-size: 12px;
  color: var(--t3);
  margin-top: 2px;
}
.tutor-status {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 11.5px;
  color: var(--grn);
  font-weight: 600;
  margin-top: 3px;
}
.ts-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--grn);
  box-shadow: 0 0 0 2px rgba(14, 168, 118, 0.2);
}
.tutor-clear {
  color: var(--t3);
  padding: 8px;
  border-radius: 8px;
  font-size: 16px;
  transition: 0.15s;
}
.tutor-clear:hover {
  background: var(--surface2);
  color: var(--t2);
}
.chat-msgs {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 4px 2px;
  margin-bottom: 12px;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}
.msg {
  display: flex;
}
.msg.u {
  justify-content: flex-end;
}
.msg.a {
  justify-content: flex-start;
}
.bubble {
  max-width: 80%;
  padding: 12px 16px;
  border-radius: 14px;
  font-size: 13.5px;
  line-height: 1.7;
}
.msg.a .bubble {
  background: var(--surface);
  border: 1.5px solid var(--border);
  color: var(--t1);
  border-bottom-left-radius: 4px;
  box-shadow: var(--sh-sm);
}
.msg.u .bubble {
  background: linear-gradient(135deg, var(--p), var(--p2));
  color: #fff;
  border-bottom-right-radius: 4px;
}
.dots {
  display: flex;
  gap: 4px;
  align-items: center;
}
.dots span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--t3);
  animation: bounce 0.8s infinite;
}
.dots span:nth-child(2) {
  animation-delay: 0.15s;
}
.dots span:nth-child(3) {
  animation-delay: 0.3s;
}
@keyframes bounce {
  0%,
  60%,
  100% {
    transform: translateY(0);
  }
  30% {
    transform: translateY(-6px);
  }
}
.chat-sugs {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 12px;
  flex-shrink: 0;
}
.chat-sugs button {
  background: var(--surface);
  border: 1.5px solid var(--border);
  color: var(--t2);
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 12.5px;
  font-weight: 500;
  transition: 0.15s;
}
.chat-sugs button:hover {
  background: var(--p-lt);
  border-color: var(--p);
  color: var(--p);
}
.chat-input-wrap {
  display: flex;
  gap: 10px;
  align-items: center;
  background: var(--surface);
  border: 1.5px solid var(--border2);
  border-radius: 12px;
  padding: 10px 14px;
  flex-shrink: 0;
  transition: 0.2s;
}
.chat-input-wrap:focus-within {
  border-color: var(--p);
  box-shadow: 0 0 0 3px rgba(90, 95, 224, 0.1);
}
.chat-input {
  flex: 1;
  border: none;
  background: transparent;
  font-size: 14px;
  color: var(--t1);
  outline: none;
}
.chat-input::placeholder {
  color: var(--t3);
}
.chat-send {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, var(--p), var(--p2));
  color: #fff;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: 0.2s;
  flex-shrink: 0;
  box-shadow: var(--sh-p);
}
.chat-send:hover {
  transform: scale(1.06);
}

/* ══════════════════════════════════════════════
   PRÁCTICA
══════════════════════════════════════════════ */
.prac-wrap {
  max-width: 680px;
  margin: 0 auto;
  padding: 28px;
}
.prac-header {
  margin-bottom: 22px;
}
.prac-header h2 {
  font-size: 22px;
  font-weight: 800;
  color: var(--t1);
  margin-bottom: 4px;
}
.prac-header p {
  font-size: 13px;
  color: var(--t3);
}
.elo-cards {
  display: flex;
  gap: 14px;
  margin-bottom: 20px;
}
.elo-c {
  flex: 1;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--r);
  padding: 18px;
  text-align: center;
  box-shadow: var(--sh-sm);
}
.ec-num {
  font-size: 2rem;
  font-weight: 900;
  color: var(--p);
  font-family: "JetBrains Mono", monospace;
  line-height: 1;
}
.ec-lbl {
  font-size: 11px;
  color: var(--t3);
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.topic-btns {
  display: flex;
  gap: 8px;
  margin-bottom: 18px;
}
.tbtn {
  padding: 9px 20px;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  color: var(--t2);
  transition: 0.15s;
}
.tbtn:hover,
.tbtn.active {
  background: linear-gradient(135deg, var(--p), var(--p2));
  color: #fff;
  border-color: transparent;
  box-shadow: var(--sh-p);
}
.qbox {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--r);
  padding: 28px;
  box-shadow: var(--sh-sm);
}
.qbox-meta {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
  align-items: center;
}
.q-topic {
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--p);
  background: var(--p-lt);
  padding: 3px 10px;
  border-radius: 20px;
}
.q-nivel {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--t3);
}
.q-text {
  font-size: 16px;
  font-weight: 600;
  color: var(--t1);
  line-height: 1.6;
  margin-bottom: 20px;
}
.q-opts {
  display: flex;
  flex-direction: column;
  gap: 9px;
  margin-bottom: 14px;
}
.qopt {
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: var(--r-sm);
  padding: 12px 16px;
  font-size: 14px;
  text-align: left;
  transition: 0.15s;
  color: var(--t1);
  font-weight: 500;
}
.qopt:hover:not(:disabled) {
  border-color: var(--p);
  background: var(--p-lt);
  color: var(--p);
}
.qopt.ok {
  border-color: var(--grn);
  background: var(--grn-lt);
  color: #065f46;
}
.qopt.err {
  border-color: var(--red);
  background: var(--red-lt);
  color: #7f1d1d;
}
.q-feed {
  font-size: 13.5px;
  font-weight: 600;
  min-height: 20px;
}

/* ══════════════════════════════════════════════
   PERFIL
══════════════════════════════════════════════ */
.perfil-wrap {
  max-width: 760px;
  margin: 0 auto;
  padding: 0 0 40px;
}
.perfil-banner {
  height: 160px;
  border-radius: 0;
  background: linear-gradient(135deg, #5a5fe0, #8056d6, #ec4899);
  position: relative;
  overflow: hidden;
  animation: bannerAnim 8s ease infinite;
  background-size: 200% 200%;
}
@keyframes bannerAnim {
  0%,
  100% {
    background-position: 0 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}
.perfil-banner-edit {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(0, 0, 0, 0.35);
  color: #fff;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 12px;
  cursor: pointer;
  transition: 0.15s;
  backdrop-filter: blur(4px);
  font-weight: 600;
}
.perfil-banner-edit:hover {
  background: rgba(0, 0, 0, 0.55);
}
.perfil-avatar-wrap {
  position: absolute;
  bottom: -28px;
  left: 28px;
}
.perfil-avatar {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  background: #fff;
  border: 3px solid #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 34px;
  box-shadow: var(--sh);
  cursor: pointer;
  transition: 0.2s;
}
.perfil-avatar:hover {
  transform: scale(1.06);
}
.perfil-avatar-btn {
  position: absolute;
  bottom: 0;
  right: -4px;
  background: var(--p);
  color: #fff;
  border-radius: 50%;
  width: 22px;
  height: 22px;
  font-size: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border: 2px solid #fff;
}
.perfil-header {
  padding: 40px 28px 16px;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-top: none;
}
.perfil-name-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.perfil-header h2 {
  font-size: 20px;
  font-weight: 800;
  color: var(--t1);
}
.perfil-badge {
  background: linear-gradient(135deg, #f59e0b, #ef4444);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
}
.perfil-email {
  font-size: 13px;
  color: var(--t3);
  margin-top: 4px;
}
.perfil-joined {
  font-size: 11.5px;
  color: var(--border2);
  margin-top: 2px;
  font-family: "JetBrains Mono", monospace;
}
.perfil-stats {
  display: flex;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-top: none;
}
.pstat {
  flex: 1;
  padding: 16px 0;
  text-align: center;
  border-right: 1px solid var(--border);
}
.pstat:last-child {
  border-right: none;
}
.pstat span {
  display: block;
  font-size: 22px;
  font-weight: 900;
  color: var(--p);
  font-family: "JetBrains Mono", monospace;
}
.pstat label {
  font-size: 11px;
  color: var(--t3);
  margin-top: 2px;
  display: block;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.perfil-tabs {
  display: flex;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-top: none;
  padding: 0 16px;
  gap: 4px;
}
.ptab {
  padding: 12px 16px;
  font-size: 13px;
  font-weight: 600;
  color: var(--t3);
  border-bottom: 2.5px solid transparent;
  transition: 0.15s;
  white-space: nowrap;
}
.ptab.active {
  color: var(--p);
  border-bottom-color: var(--p);
}
.ptab:hover {
  color: var(--p);
}
.ptab-content {
  display: none;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-top: none;
  border-radius: 0 0 var(--r) var(--r);
  padding: 24px;
}
.ptab-content.active {
  display: block;
}
.perfil-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.pf-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.pf-field {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.pf-field label {
  font-size: 11.5px;
  font-weight: 700;
  color: var(--t2);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.pf-field input,
.pf-field select,
.pf-field textarea {
  padding: 10px 13px;
  border: 1.5px solid var(--border);
  border-radius: 9px;
  font-size: 14px;
  color: var(--t1);
  background: var(--bg);
  outline: none;
  transition: 0.2s;
  width: 100%;
  font-family: inherit;
}
.pf-field input:focus,
.pf-field select:focus,
.pf-field textarea:focus {
  border-color: var(--p);
  box-shadow: 0 0 0 3px rgba(90, 95, 224, 0.1);
  background: var(--surface);
}
.pf-field textarea {
  resize: vertical;
  min-height: 72px;
}
.pf-field small {
  font-size: 11px;
  color: var(--t3);
  text-align: right;
}
.fav-opts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 4px;
}
.fav-btn {
  padding: 7px 16px;
  border-radius: 20px;
  font-size: 12.5px;
  font-weight: 600;
  background: var(--bg);
  border: 1.5px solid var(--border);
  color: var(--t2);
  cursor: pointer;
  transition: 0.15s;
}
.fav-btn.active {
  background: linear-gradient(135deg, var(--p), var(--p2));
  color: #fff;
  border-color: transparent;
}
.pf-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 8px;
}
.btn-save {
  padding: 10px 22px;
  background: linear-gradient(135deg, var(--p), var(--p2));
  color: #fff;
  border: none;
  border-radius: 9px;
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  transition: 0.2s;
  box-shadow: var(--sh-p);
}
.btn-save:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 22px rgba(90, 95, 224, 0.4);
}
.btn-chpass {
  padding: 10px 18px;
  background: var(--bg);
  border: 1.5px solid var(--border);
  color: var(--t2);
  border-radius: 9px;
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
  transition: 0.2s;
}
.btn-chpass:hover {
  border-color: var(--p);
  color: var(--p);
}
.chpass-box {
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: var(--r-sm);
  padding: 16px;
  margin-top: 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.logros-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 14px;
}
.logro-card {
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: var(--r-sm);
  padding: 16px;
  text-align: center;
  transition: 0.2s;
}
.logro-card.earned {
  border-color: var(--p);
  background: var(--p-lt);
}
.logro-card.earned:hover {
  transform: translateY(-2px);
  box-shadow: var(--sh);
}
.logro-ico {
  font-size: 28px;
  margin-bottom: 8px;
  filter: grayscale(1);
  opacity: 0.35;
  transition: 0.3s;
}
.logro-card.earned .logro-ico {
  filter: none;
  opacity: 1;
}
.logro-name {
  font-size: 12px;
  font-weight: 700;
  color: var(--t1);
  margin-bottom: 3px;
}
.logro-desc {
  font-size: 10.5px;
  color: var(--t3);
  line-height: 1.4;
}
.logro-card.earned .logro-name {
  color: var(--p);
}
.config-list {
  display: flex;
  flex-direction: column;
}
.config-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
  border-bottom: 1px solid var(--bg);
  gap: 12px;
}
.config-item:last-child {
  border-bottom: none;
}
.ci-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.ci-info strong {
  font-size: 13.5px;
  color: var(--t1);
}
.ci-info span {
  font-size: 12px;
  color: var(--t3);
}
.ci-control {
  display: flex;
  gap: 6px;
}
.lang-pill {
  padding: 5px 12px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  background: var(--bg);
  border: 1.5px solid var(--border);
  color: var(--t3);
  cursor: pointer;
  transition: 0.15s;
}
.lang-pill.active {
  background: var(--p-lt);
  border-color: var(--p);
  color: var(--p);
}
.danger-zone {
  margin-top: 8px;
  padding-top: 16px;
  border-top: 1px solid var(--red-lt) !important;
}
.btn-danger {
  padding: 8px 16px;
  background: var(--red-lt);
  border: 1.5px solid #fecaca;
  color: var(--red);
  border-radius: 8px;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  transition: 0.15s;
}
.btn-danger:hover {
  background: var(--red);
  color: #fff;
  border-color: var(--red);
}
.toggle-sw {
  position: relative;
  display: inline-flex;
  align-items: center;
  cursor: pointer;
}
.toggle-sw input {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}
.sw-track {
  width: 44px;
  height: 24px;
  background: var(--border);
  border-radius: 12px;
  position: relative;
  transition: 0.3s;
  flex-shrink: 0;
}
.toggle-sw input:checked + .sw-track {
  background: linear-gradient(135deg, var(--p), var(--p2));
}
.sw-thumb {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.2);
  transition: 0.3s;
}
.toggle-sw input:checked + .sw-track .sw-thumb {
  transform: translateX(20px);
}
.logout-section {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--bg);
  text-align: center;
}
.btn-logout-full {
  padding: 11px 32px;
  background: var(--red-lt);
  border: 1.5px solid #fecaca;
  color: var(--red);
  border-radius: 10px;
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  transition: 0.2s;
}
.btn-logout-full:hover {
  background: var(--red);
  color: #fff;
  border-color: var(--red);
}

/* ══════════════════════════════════════════════
   SIMULADOR
══════════════════════════════════════════════ */
.sim-wrap {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 18px;
  padding: 24px;
  align-items: start;
}
.sim-panel {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--r);
  padding: 20px;
  position: sticky;
  top: 66px;
  box-shadow: var(--sh-sm);
}
.sim-panel-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}
.sph-icon {
  font-size: 22px;
  width: 42px;
  height: 42px;
  background: var(--p-lt);
  border-radius: var(--r-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
#sim-title {
  font-size: 14.5px;
  font-weight: 800;
  color: var(--t1);
}
#sim-desc {
  font-size: 11.5px;
  color: var(--t3);
  margin-top: 2px;
  line-height: 1.4;
}
.ctrl {
  margin-bottom: 13px;
}
.ctrl label {
  display: block;
  font-size: 11px;
  font-weight: 700;
  color: var(--t2);
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.ctrl label strong {
  color: var(--p);
  font-family: "JetBrains Mono", monospace;
  font-size: 12px;
}
.ctrl input[type="range"] {
  width: 100%;
  height: 5px;
  accent-color: var(--p);
  cursor: pointer;
  border-radius: 10px;
}
.ctrl select {
  width: 100%;
  padding: 8px 10px;
  border: 1.5px solid var(--border);
  border-radius: 7px;
  font-family: inherit;
  background: var(--bg);
  color: var(--t1);
  outline: none;
  font-size: 13px;
}
.ctrl select:focus {
  border-color: var(--p);
}
.formula-box {
  background: var(--p-lt);
  border: 1px solid rgba(90, 95, 224, 0.15);
  border-radius: var(--r-sm);
  padding: 12px;
  margin-top: 14px;
}
.formula-box code {
  display: block;
  font-family: "JetBrains Mono", monospace;
  font-size: 11.5px;
  color: var(--p);
  margin-bottom: 3px;
}
.results-box {
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.res-row {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  padding: 4px 0;
  border-bottom: 1px solid var(--border);
}
.res-row:last-child {
  border: none;
}
.res-row span {
  color: var(--t3);
}
.res-row strong {
  font-family: "JetBrains Mono", monospace;
  font-size: 11.5px;
  color: var(--t1);
}
.sim-btns {
  display: flex;
  gap: 8px;
  margin-top: 16px;
}
.btn-sim-play {
  flex: 1;
  padding: 9px;
  background: linear-gradient(135deg, var(--p), var(--p2));
  color: #fff;
  border-radius: var(--r-sm);
  font-size: 13px;
  font-weight: 700;
  box-shadow: var(--sh-p);
  transition: 0.2s;
}
.btn-sim-play:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}
.btn-sim-reset {
  flex: 1;
  padding: 9px;
  background: var(--bg);
  border: 1.5px solid var(--border);
  color: var(--t2);
  border-radius: var(--r-sm);
  font-size: 13px;
  font-weight: 600;
  transition: 0.15s;
}
.btn-sim-reset:hover {
  border-color: var(--p);
  color: var(--p);
}
.btn-ask-tutor {
  width: 100%;
  margin-top: 8px;
  padding: 9px;
  background: transparent;
  border: 1.5px solid var(--border);
  color: var(--t3);
  border-radius: var(--r-sm);
  font-size: 12.5px;
  font-weight: 600;
  transition: 0.15s;
}
.btn-ask-tutor:hover {
  border-color: var(--p);
  color: var(--p);
  background: var(--p-lt);
}
.sim-canvas-wrap canvas {
  border: 1.5px solid var(--border);
  border-radius: var(--r);
  background: #f8f9fd;
  max-width: 100%;
  box-shadow: var(--sh-sm);
  display: block;
}

/* ══════════════════════════════════════════════
   BANNER INVITADO — v3 limpio y elegante
══════════════════════════════════════════════ */
.guest-bar {
  background: #0a0e1a;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  padding: 0 22px;
  position: sticky;
  top: 52px;
  z-index: 40;
  animation: guestBarIn 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}
@keyframes guestBarIn {
  from {
    transform: translateY(-100%);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}
@keyframes guestBarOut {
  to {
    transform: translateY(-100%);
    opacity: 0;
  }
}
.gb-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 42px;
  max-width: 1100px;
  margin: 0 auto;
  gap: 12px;
}
.gb-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1;
}
.gb-online-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #10b981;
  flex-shrink: 0;
  box-shadow: 0 0 6px rgba(16, 185, 129, 0.5);
  animation: dotPulse 2.5s ease-in-out infinite;
}
@keyframes dotPulse {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.4);
  }
  50% {
    box-shadow: 0 0 0 4px rgba(16, 185, 129, 0);
  }
}
.gb-flag-pill {
  font-size: 13px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.85);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 20px;
  padding: 3px 12px;
  white-space: nowrap;
}
.gb-sep {
  color: rgba(255, 255, 255, 0.2);
  font-size: 14px;
}
.gb-mode-lbl {
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.4);
  font-weight: 500;
}
.gb-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.gb-cta {
  background: linear-gradient(135deg, #5a5fe0, #8056d6);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 6px 16px;
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  transition: 0.2s;
  white-space: nowrap;
  font-family: inherit;
  box-shadow: 0 2px 10px rgba(90, 95, 224, 0.35);
  letter-spacing: 0.02em;
}
.gb-cta:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(90, 95, 224, 0.5);
}
.gb-dismiss {
  width: 26px;
  height: 26px;
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: 0.15s;
  flex-shrink: 0;
}
.gb-dismiss:hover {
  background: rgba(239, 68, 68, 0.15);
  border-color: rgba(239, 68, 68, 0.3);
  color: #ef4444;
}
@media (max-width: 600px) {
  .gb-mode-lbl {
    display: none;
  }
  .gb-sep {
    display: none;
  }
  .gb-cta {
    padding: 6px 12px;
    font-size: 12px;
  }
}

/* ══════════════════════════════════════════════
   GEO CARD INVITADO
══════════════════════════════════════════════ */
.guest-geo-card {
  background: linear-gradient(135deg, #fff7ed, #fef3c7);
  border: 1.5px solid #fde68a;
  border-radius: var(--r-sm);
  padding: 18px 20px;
  margin: 0 0 16px;
}
.ggc-title {
  font-size: 13px;
  font-weight: 700;
  color: #92400e;
  margin-bottom: 14px;
}
.ggc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}
.ggc-item {
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid #fde68a;
  border-radius: 8px;
  padding: 9px 12px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.ggc-item span {
  font-size: 10.5px;
  color: #92400e;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.ggc-item strong {
  font-size: 13px;
  color: var(--t1);
  font-family: "JetBrains Mono", monospace;
  word-break: break-all;
}
.ggc-note {
  font-size: 12px;
  color: #78350f;
  margin-bottom: 12px;
  line-height: 1.5;
}
.ggc-cta {
  background: linear-gradient(135deg, #f59e0b, #ef4444);
  color: #fff;
  border: none;
  border-radius: 9px;
  padding: 9px 20px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: 0.2s;
  box-shadow: 0 3px 10px rgba(245, 158, 11, 0.3);
}
.ggc-cta:hover {
  transform: translateY(-1px);
}

/* ══════════════════════════════════════════════
   MODALES
══════════════════════════════════════════════ */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 8000;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(6px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
}
.modal-backdrop.open {
  display: flex;
}
.modal-box {
  background: var(--surface);
  border-radius: var(--r);
  padding: 24px;
  width: 100%;
  max-width: 380px;
  max-height: 70vh;
  overflow-y: auto;
  animation: fadeUp 0.2s ease;
  box-shadow: var(--sh-lg);
  border: 1.5px solid var(--border);
}
.modal-box h3 {
  font-size: 16px;
  font-weight: 800;
  margin-bottom: 16px;
  color: var(--t1);
}
.emoji-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
}
.emoji-grid button {
  font-size: 26px;
  padding: 8px;
  border-radius: 8px;
  border: 1.5px solid transparent;
  background: var(--bg);
  cursor: pointer;
  transition: 0.15s;
  line-height: 1;
}
.emoji-grid button:hover {
  border-color: var(--p);
  background: var(--p-lt);
  transform: scale(1.1);
}
.banner-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.banner-opt {
  height: 60px;
  border-radius: 8px;
  cursor: pointer;
  border: 2px solid transparent;
  transition: 0.2s;
}
.banner-opt:hover {
  border-color: var(--p);
  transform: scale(1.03);
}
.banner-opt.active {
  border-color: var(--p);
  box-shadow: 0 0 0 3px rgba(90, 95, 224, 0.2);
}

/* ══════════════════════════════════════════════
   TOAST
══════════════════════════════════════════════ */
.toast-notif {
  position: fixed;
  bottom: 22px;
  right: 22px;
  z-index: 9998;
  background: var(--t1);
  color: #fff;
  padding: 12px 18px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  box-shadow: var(--sh-lg);
  animation: slideIn 0.3s ease;
  max-width: 340px;
}
@keyframes slideIn {
  from {
    transform: translateX(20px);
    opacity: 0;
  }
}
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
}

/* ══════════════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════════════ */
@media (max-width: 900px) {
  .auth-left {
    display: none;
  }
  .auth-right {
    width: 100%;
    border-left: none;
    padding: 32px 24px;
  }
  #sidebar {
    transform: translateX(-100%);
    transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  }
  #sidebar.open {
    transform: translateX(0);
  }
  #main {
    margin-left: 0;
  }
  #menu-btn {
    display: flex;
  }
  .sim-wrap {
    grid-template-columns: 1fr;
    padding: 16px;
  }
  .sim-panel {
    position: static;
  }
  .home-problem,
  .home-features {
    grid-template-columns: 1fr;
  }
  .sim-grid {
    grid-template-columns: 1fr 1fr;
  }
  .hh-title {
    font-size: 2.2rem;
  }
}
@media (max-width: 600px) {
  .home-hero {
    padding: 40px 24px 0;
  }
  .hh-metrics {
    padding: 20px 24px;
    margin: 0 -24px;
  }
  .home-problem,
  .home-sims,
  .home-features,
  .home-tech {
    padding: 40px 24px;
  }
  .sim-grid {
    grid-template-columns: 1fr;
  }
  .elo-cards {
    flex-direction: column;
  }
  .pf-row {
    grid-template-columns: 1fr;
  }
  #content {
    padding: 0;
  }
  .hh-title {
    font-size: 1.8rem;
  }
  .prob-cards {
    grid-template-columns: 1fr;
  }
}

/* ══════════════════════════════════════════════
   SCROLL REVEAL ANIMATIONS
══════════════════════════════════════════════ */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition:
    opacity 0.65s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.65s cubic-bezier(0.4, 0, 0.2, 1);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}
.reveal-card {
  opacity: 0;
  transform: translateY(20px) scale(0.97);
  transition:
    opacity 0.5s cubic-bezier(0.4, 0, 0.2, 1) var(--delay, 0s),
    transform 0.5s cubic-bezier(0.34, 1.2, 0.64, 1) var(--delay, 0s);
}
.reveal-card.visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* Hover lift en sim-cards */
.sg-card {
  transition:
    transform 0.25s cubic-bezier(0.34, 1.3, 0.64, 1),
    box-shadow 0.25s ease,
    border-color 0.25s ease !important;
}
.sg-card:hover {
  transform: translateY(-6px) scale(1.01) !important;
  box-shadow: 0 16px 40px rgba(90, 95, 224, 0.18) !important;
}

/* Hover lift en pc-items */
.pc-item {
  transition:
    transform 0.2s cubic-bezier(0.34, 1.3, 0.64, 1),
    border-color 0.2s ease,
    background 0.2s ease;
}
.pc-item:hover {
  transform: translateY(-3px);
}

/* Pulse en el chip del hackathon */
.hh-chip {
  animation: chipGlow 3s ease-in-out infinite alternate;
}
@keyframes chipGlow {
  0% {
    box-shadow: 0 0 0 0 rgba(165, 180, 255, 0.3);
  }
  100% {
    box-shadow: 0 0 16px 4px rgba(165, 180, 255, 0.15);
  }
}

/* Botones hero con shimmer */
.hb-primary {
  position: relative;
  overflow: hidden;
}
.hb-primary::after {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.15),
    transparent
  );
  animation: shimmer 2.5s ease-in-out infinite;
}
@keyframes shimmer {
  0% {
    left: -100%;
  }
  60%,
  100% {
    left: 150%;
  }
}

/* Tech pills hover */
.tech-pills span {
  transition:
    transform 0.15s ease,
    background 0.15s ease,
    border-color 0.15s ease;
  cursor: default;
}
.tech-pills span:hover {
  transform: translateY(-2px);
  background: var(--p-lt);
  border-color: var(--p);
  color: var(--p);
}

/* Número en stat animado en auth */
.al-stat-num {
  transition: transform 0.3s cubic-bezier(0.34, 1.5, 0.64, 1);
}
.al-stat-num.popped {
  transform: scale(1.2);
}

/* Statics badge NEW */
.sgc-badge {
  font-size: 10px !important;
}

/* ══ ONBOARDING ═══════════════════════════════════════════ */
.ob-backdrop {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: fadeIn 0.3s ease;
}
.ob-card {
  background: #0a0e1a;
  border: 1.5px solid rgba(90, 95, 224, 0.35);
  border-radius: 24px;
  padding: 40px 36px;
  max-width: 440px;
  width: 100%;
  text-align: center;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.6);
  position: relative;
  animation: slideUp 0.4s cubic-bezier(0.34, 1.2, 0.64, 1);
}
@keyframes slideUp {
  from {
    transform: translateY(24px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}
.ob-progress {
  display: flex;
  gap: 6px;
  justify-content: center;
  margin-bottom: 28px;
}
.ob-step {
  width: 32px;
  height: 4px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.12);
  transition: 0.3s;
}
.ob-step.ob-active {
  background: linear-gradient(90deg, #5a5fe0, #8056d6);
  width: 48px;
}
.ob-icon {
  font-size: 52px;
  margin-bottom: 16px;
  animation: iconBounce 2s ease-in-out infinite alternate;
}
@keyframes iconBounce {
  0% {
    transform: translateY(0);
  }
  100% {
    transform: translateY(-6px);
  }
}
.ob-title {
  font-size: 22px;
  font-weight: 900;
  color: #fff;
  letter-spacing: -0.03em;
  margin-bottom: 12px;
}
.ob-desc {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.55);
  line-height: 1.75;
  margin-bottom: 24px;
}
.ob-desc em {
  color: #a5b4ff;
  font-style: normal;
  font-weight: 600;
}
.ob-btn {
  background: linear-gradient(135deg, #5a5fe0, #8056d6);
  color: #fff;
  border: none;
  border-radius: 12px;
  padding: 13px 28px;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  transition: 0.2s;
  box-shadow: 0 4px 20px rgba(90, 95, 224, 0.4);
  font-family: inherit;
  width: 100%;
  margin-bottom: 8px;
}
.ob-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 26px rgba(90, 95, 224, 0.55);
}
.ob-btn-sec {
  background: transparent;
  border: 1.5px solid rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.55);
  border-radius: 12px;
  padding: 11px 24px;
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
  transition: 0.2s;
  font-family: inherit;
  width: 100%;
}
.ob-btn-sec:hover {
  border-color: rgba(255, 255, 255, 0.35);
  color: rgba(255, 255, 255, 0.8);
}
.ob-skip {
  position: absolute;
  top: 16px;
  right: 16px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 5px 12px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.4);
  cursor: pointer;
  transition: 0.15s;
  font-family: inherit;
}
.ob-skip:hover {
  color: rgba(255, 255, 255, 0.7);
}
.ob-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* ══════════════════════════════════════════════
   PROGRESS CHART + SHARE BADGE
══════════════════════════════════════════════ */

/* Progress tab */
.progress-section {
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.progress-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}
.prog-title {
  font-size: 16px;
  font-weight: 800;
  color: var(--t1);
}
.prog-filters {
  display: flex;
  gap: 6px;
}
.prog-filter {
  padding: 6px 14px;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: 20px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--t2);
  cursor: pointer;
  transition: 0.15s;
}
.prog-filter.active {
  background: linear-gradient(135deg, var(--p), var(--p2));
  color: #fff;
  border-color: transparent;
}

/* Stats row */
.prog-stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.prog-stat {
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: var(--r-sm);
  padding: 14px;
  text-align: center;
}
.prs-num {
  font-size: 22px;
  font-weight: 900;
  color: var(--p);
  font-family: "JetBrains Mono", monospace;
  line-height: 1;
}
.prs-lbl {
  font-size: 11px;
  color: var(--t3);
  margin-top: 3px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Chart wrapper */
.prog-chart-wrap {
  position: relative;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: var(--r);
  padding: 16px;
  min-height: 220px;
  display: flex;
  align-items: center;
  justify-content: center;
}
#elo-chart {
  width: 100% !important;
}

/* Empty state */
.prog-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 32px;
  text-align: center;
}
.pe-icon {
  font-size: 36px;
}
.pe-txt {
  font-size: 14px;
  color: var(--t3);
}
.pe-btn {
  padding: 9px 20px;
  background: linear-gradient(135deg, var(--p), var(--p2));
  color: #fff;
  border: none;
  border-radius: 9px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: 0.2s;
  font-family: inherit;
}

/* Milestones */
.prog-milestones {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.pm-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--t3);
}
.pm-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.pm-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 10px 12px;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: var(--r-sm);
  opacity: 0.4;
  filter: grayscale(1);
  transition: 0.2s;
  min-width: 70px;
}
.pm-item.pm-earned {
  opacity: 1;
  filter: none;
  border-color: rgba(90, 95, 224, 0.3);
  background: var(--p-lt);
}
.pm-ico {
  font-size: 20px;
}
.pm-elo {
  font-size: 12px;
  font-weight: 800;
  color: var(--p);
  font-family: "JetBrains Mono", monospace;
}
.pm-lbl {
  font-size: 10px;
  color: var(--t3);
}

/* ── Botón compartir logro ──────────────────── */
.logro-share-btn {
  width: 100%;
  margin-top: 8px;
  padding: 6px;
  background: linear-gradient(135deg, var(--p), var(--p2));
  color: #fff;
  border: none;
  border-radius: 7px;
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
  transition: 0.2s;
  opacity: 0;
  font-family: inherit;
}
.logro-card:hover .logro-share-btn {
  opacity: 1;
}
.logro-share-btn:hover {
  transform: translateY(-1px);
}

/* ── Auth loading state ─────────────────────── */
.btn-auth:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none !important;
}

@media (max-width: 600px) {
  .prog-stats-row {
    grid-template-columns: 1fr 1fr;
  }
  .pm-row {
    gap: 6px;
  }
  .pm-item {
    min-width: 60px;
    padding: 8px 10px;
  }
}

/* ══════════════════════════════════════════════════════
   AI EXAM GENERATOR
══════════════════════════════════════════════════════ */
.exam-wrap {
  max-width: 800px;
  margin: 0 auto;
  padding: 24px;
}
.exam-screen {
  display: none;
}
.exam-screen.active {
  display: block;
  animation: btScreenIn 0.35s ease;
}

/* Hero */
.exam-hero {
  text-align: center;
  padding: 36px 20px 28px;
  background: linear-gradient(135deg, #080d1e, #0f1735);
  border-radius: 20px;
  margin-bottom: 22px;
  border: 1.5px solid rgba(90, 95, 224, 0.2);
  position: relative;
  overflow: hidden;
}
.exam-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse at 50% 100%,
    rgba(90, 95, 224, 0.1),
    transparent 70%
  );
}
.exam-hero-icon {
  font-size: 52px;
  margin-bottom: 12px;
  animation: floatIcon 3s ease-in-out infinite alternate;
}
.exam-title {
  font-size: 2rem;
  font-weight: 900;
  color: #fff;
  letter-spacing: -0.04em;
  margin-bottom: 8px;
}
.exam-sub {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.5);
}

/* Setup */
.exam-setup-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 20px;
}
.exam-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.exam-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--t2);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.exam-opts {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}
.exam-opt {
  padding: 7px 14px;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: 9px;
  font-size: 13px;
  font-weight: 600;
  color: var(--t2);
  cursor: pointer;
  transition: 0.15s;
}
.exam-opt.active,
.exam-opt:hover {
  background: linear-gradient(135deg, var(--p), var(--p2));
  color: #fff;
  border-color: transparent;
}
.exam-input {
  padding: 10px 14px;
  border: 1.5px solid var(--border);
  border-radius: 9px;
  font-size: 14px;
  color: var(--t1);
  background: var(--bg);
  outline: none;
  transition: 0.2s;
  width: 100%;
  font-family: inherit;
}
.exam-input:focus {
  border-color: var(--p);
  box-shadow: 0 0 0 3px rgba(90, 95, 224, 0.1);
}

/* Elo info */
.exam-elo-info {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(
    135deg,
    rgba(90, 95, 224, 0.08),
    rgba(128, 86, 214, 0.08)
  );
  border: 1.5px solid rgba(90, 95, 224, 0.2);
  border-radius: 12px;
  padding: 16px 20px;
  margin-bottom: 18px;
}
.eei-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--t3);
  margin-bottom: 4px;
}
.eei-num {
  font-size: 2rem;
  font-weight: 900;
  color: var(--p);
  font-family: "JetBrains Mono", monospace;
  line-height: 1;
}
.eei-level {
  font-size: 16px;
  font-weight: 800;
  color: var(--t1);
  margin-bottom: 4px;
}
.eei-hint {
  font-size: 12px;
  color: var(--t3);
}

/* Botón generar */
.exam-generate-btn {
  width: 100%;
  padding: 14px;
  border: none;
  cursor: pointer;
  background: linear-gradient(135deg, var(--p), var(--p2));
  color: #fff;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  box-shadow: 0 4px 20px rgba(90, 95, 224, 0.4);
  transition: 0.2s;
  font-family: inherit;
  margin-bottom: 20px;
}
.exam-generate-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 28px rgba(90, 95, 224, 0.55);
}

/* Historial */
.exam-history {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 12px;
  padding: 16px;
}
.eh-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--t1);
  margin-bottom: 12px;
}
.eh-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.eh-empty {
  font-size: 13px;
  color: var(--t3);
  text-align: center;
  padding: 12px;
}
.eh-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
  background: var(--bg);
  border-radius: 9px;
  border: 1px solid var(--border);
}
.eh-grade {
  font-size: 22px;
  font-weight: 900;
  font-family: "JetBrains Mono", monospace;
  min-width: 32px;
}
.eh-info {
  flex: 1;
}
.eh-subject {
  font-size: 13px;
  font-weight: 600;
  color: var(--t1);
  text-transform: capitalize;
}
.eh-date {
  font-size: 11px;
  color: var(--t3);
}
.eh-score {
  font-size: 13px;
  font-weight: 700;
  color: var(--t2);
  font-family: "JetBrains Mono", monospace;
}

/* Loading */
.exam-loading-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 400px;
  gap: 24px;
}
.el-spinner {
  position: relative;
  width: 80px;
  height: 80px;
}
.el-ring {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  border: 4px solid var(--border);
  border-top-color: var(--p);
  animation: spin 0.9s linear infinite;
}
.el-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 28px;
}
.el-title {
  font-size: 20px;
  font-weight: 800;
  color: var(--t1);
}
.el-steps {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.el-step {
  font-size: 14px;
  color: var(--t3);
  padding: 8px 16px;
  border-radius: 8px;
  transition: 0.3s;
}
.el-step.el-active {
  color: var(--p);
  background: var(--p-lt);
  font-weight: 600;
}

/* Game header */
.exam-header {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 14px;
  padding: 14px 20px;
  margin-bottom: 18px;
  gap: 16px;
}
.exh-left {
}
.exh-title {
  font-size: 15px;
  font-weight: 800;
  color: var(--t1);
}
.exh-sub {
  font-size: 12px;
  color: var(--t3);
  margin-top: 2px;
  text-transform: capitalize;
}
.exh-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}
.exh-progress-text {
  font-size: 13px;
  font-weight: 700;
  color: var(--t2);
  font-family: "JetBrains Mono", monospace;
}
.exh-progress-bar {
  width: 140px;
  height: 6px;
  background: var(--border);
  border-radius: 6px;
  overflow: hidden;
}
.exh-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--p), var(--p2));
  border-radius: 6px;
  transition: width 0.5s ease;
}
.exh-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 5px;
}
.exh-timer {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 13px;
  font-weight: 700;
  color: var(--t2);
  font-family: "JetBrains Mono", monospace;
}
.exh-score {
  font-size: 12px;
  color: var(--t3);
}

/* Question area */
.exam-question-area {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 14px;
  padding: 28px;
  margin-bottom: 14px;
}
.eqa-num {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--t3);
  margin-bottom: 10px;
}
.eqa-text {
  font-size: 18px;
  font-weight: 700;
  color: var(--t1);
  line-height: 1.6;
  margin-bottom: 22px;
}
.eqa-opts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 14px;
}
.eqa-opt {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 15px;
  background: var(--bg);
  border: 2px solid var(--border);
  border-radius: 11px;
  font-size: 14px;
  text-align: left;
  cursor: pointer;
  transition: 0.15s;
  color: var(--t1);
  font-family: inherit;
  font-weight: 500;
}
.eqa-opt:hover:not(:disabled) {
  border-color: var(--p);
  background: var(--p-lt);
  color: var(--p);
}
.eqa-opt:disabled {
  cursor: not-allowed;
}
.eqa-opt.eopt-correct {
  border-color: var(--grn, #10b981) !important;
  background: rgba(16, 185, 129, 0.08) !important;
  color: #059669 !important;
}
.eqa-opt.eopt-wrong {
  border-color: var(--red, #ef4444) !important;
  background: rgba(239, 68, 68, 0.06) !important;
  color: #dc2626 !important;
}
.eopt-letter {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 800;
  flex-shrink: 0;
}
.eopt-text {
  flex: 1;
}
.eqa-feedback {
  font-size: 15px;
  font-weight: 700;
  min-height: 22px;
  margin-bottom: 8px;
}
.eqa-explanation {
  font-size: 13px;
  color: var(--t2);
  line-height: 1.6;
  background: var(--surface2, #f0f2fa);
  border-radius: 8px;
  padding: 10px 13px;
  border-left: 3px solid var(--p);
  display: none;
}
.eqa-explanation:not(:empty) {
  display: block;
}

/* Nav */
.exam-nav {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}
.exam-skip-btn,
.exam-next-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 11px 22px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: 0.2s;
  font-family: inherit;
}
.exam-skip-btn {
  background: var(--bg);
  border: 1.5px solid var(--border);
  color: var(--t2);
}
.exam-skip-btn:hover {
  border-color: var(--p);
  color: var(--p);
}
.exam-next-btn {
  background: linear-gradient(135deg, var(--p), var(--p2));
  color: #fff;
  border: none;
  box-shadow: 0 3px 14px rgba(90, 95, 224, 0.35);
}
.exam-next-btn:hover {
  transform: translateY(-1px);
}

/* Results */
.exam-results-inner {
  max-width: 620px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 24px 0;
}
.exr-banner {
  border-radius: 18px;
  padding: 28px;
  text-align: center;
  border: 2px solid rgba(90, 95, 224, 0.25);
  background: linear-gradient(
    135deg,
    rgba(90, 95, 224, 0.08),
    rgba(128, 86, 214, 0.06)
  );
}
.exr-grade {
  font-size: 4rem;
  font-weight: 900;
  line-height: 1;
  margin-bottom: 6px;
  font-family: "JetBrains Mono", monospace;
}
.exr-score-big {
  font-size: 2rem;
  font-weight: 900;
  color: var(--t1);
}
.exr-label {
  font-size: 16px;
  color: var(--t2);
  margin-top: 4px;
}
.exr-pct {
  font-size: 14px;
  color: var(--t3);
  margin-top: 4px;
}
.exr-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.exrs-item {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 10px;
  padding: 14px;
  text-align: center;
}
.exrs-num {
  font-size: 22px;
  font-weight: 900;
  color: var(--p);
  font-family: "JetBrains Mono", monospace;
  line-height: 1;
}
.exrs-lbl {
  font-size: 11px;
  color: var(--t3);
  margin-top: 3px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.exr-review {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 14px;
  padding: 18px;
}
.exr-review-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--t1);
  margin-bottom: 12px;
}
.exr-item {
  padding: 12px;
  border-radius: 9px;
  margin-bottom: 8px;
  border: 1px solid var(--border);
}
.exr-ok {
  background: rgba(16, 185, 129, 0.05);
  border-color: rgba(16, 185, 129, 0.2);
}
.exr-wrong {
  background: rgba(239, 68, 68, 0.04);
  border-color: rgba(239, 68, 68, 0.15);
}
.exr-skip {
  background: var(--bg);
}
.exri-top {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 5px;
}
.exri-num {
  font-size: 11px;
  font-weight: 800;
  color: var(--t3);
  background: var(--border);
  border-radius: 4px;
  padding: 2px 7px;
  flex-shrink: 0;
}
.exri-q {
  font-size: 13px;
  font-weight: 600;
  color: var(--t1);
  flex: 1;
}
.exri-icon {
  font-size: 16px;
  flex-shrink: 0;
}
.exri-correct {
  font-size: 12px;
  color: var(--grn, #10b981);
  font-weight: 600;
  margin-bottom: 4px;
}
.exri-exp {
  font-size: 12px;
  color: var(--t3);
  line-height: 1.5;
}
.exr-cert {
  background: linear-gradient(135deg, #080d1e, #0f1735);
  border: 1.5px solid rgba(90, 95, 224, 0.3);
  border-radius: 14px;
  padding: 20px;
}
.exrc-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}
.exrc-icon {
  font-size: 28px;
}
.exrc-title {
  font-size: 15px;
  font-weight: 800;
  color: #fff;
}
.exrc-sub {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.45);
  margin-top: 2px;
}
.exrc-actions {
  display: flex;
  gap: 10px;
}
.exrc-btn-dl,
.exrc-btn-share {
  flex: 1;
  padding: 11px;
  border: none;
  border-radius: 10px;
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  transition: 0.2s;
  font-family: inherit;
}
.exrc-btn-dl {
  background: linear-gradient(135deg, var(--p), var(--p2));
  color: #fff;
  box-shadow: 0 3px 12px rgba(90, 95, 224, 0.3);
}
.exrc-btn-share {
  background: rgba(255, 255, 255, 0.08);
  border: 1.5px solid rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.7);
}
.exrc-btn-share:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
}
.exr-actions {
  display: flex;
  gap: 10px;
}
.exam-retry-btn {
  flex: 1;
  padding: 12px;
  background: linear-gradient(135deg, var(--p), var(--p2));
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  transition: 0.2s;
  font-family: inherit;
}
.exam-retry-btn:hover {
  transform: translateY(-1px);
}
.exam-home-btn {
  padding: 12px 20px;
  background: var(--bg);
  border: 1.5px solid var(--border);
  color: var(--t2);
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: 0.15s;
  font-family: inherit;
}
.exam-home-btn:hover {
  border-color: var(--p);
  color: var(--p);
}

/* ══════════════════════════════════════════════════════
   NOTIFICACIONES DE RACHA
══════════════════════════════════════════════════════ */

/* Botón en topbar */
.notif-topbar-btn {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 9px;
  background: var(--surface2, #f0f2fa);
  border: 1.5px solid var(--border, #e4e8f5);
  cursor: pointer;
  transition: 0.2s;
  font-size: 17px;
}
.notif-topbar-btn:hover {
  background: var(--p-lt);
  border-color: var(--p);
}
.ntb-badge {
  position: absolute;
  top: -5px;
  right: -5px;
  background: linear-gradient(135deg, #ef4444, #f59e0b);
  color: #fff;
  font-size: 9px;
  font-weight: 800;
  padding: 2px 5px;
  border-radius: 20px;
  border: 2px solid var(--bg);
  white-space: nowrap;
  line-height: 1.2;
}

/* Panel */
.notif-panel {
  position: fixed;
  top: 60px;
  right: 70px;
  z-index: 5000;
  background: var(--surface, #fff);
  border: 1.5px solid var(--border, #e4e8f5);
  border-radius: 16px;
  padding: 18px;
  width: 300px;
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.15);
  animation: panelIn 0.25s cubic-bezier(0.34, 1.3, 0.64, 1);
}
.np-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.np-title {
  font-size: 14px;
  font-weight: 800;
  color: var(--t1);
}
.np-close {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--surface2);
  border: 1px solid var(--border);
  color: var(--t3);
  font-size: 12px;
  cursor: pointer;
  transition: 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
}
.np-close:hover {
  background: var(--red-lt);
  color: var(--red);
}
.np-unsupported {
  font-size: 13px;
  color: var(--t3);
  padding: 12px;
  text-align: center;
}
.np-request {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 10px 0;
  text-align: center;
}
.np-req-icon {
  font-size: 32px;
}
.np-req-text {
  font-size: 13px;
  color: var(--t2);
  line-height: 1.5;
}
.np-allow-btn,
.np-save-btn,
.np-enable-btn {
  width: 100%;
  padding: 10px;
  background: linear-gradient(135deg, var(--p), var(--p2));
  color: #fff;
  border: none;
  border-radius: 9px;
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  transition: 0.2s;
  font-family: inherit;
}
.np-allow-btn:hover,
.np-save-btn:hover {
  transform: translateY(-1px);
}
.np-status {
  font-size: 13px;
  font-weight: 700;
  padding: 8px 12px;
  border-radius: 8px;
  margin-bottom: 12px;
  text-align: center;
}
.np-on {
  background: rgba(16, 185, 129, 0.1);
  color: #059669;
  border: 1px solid rgba(16, 185, 129, 0.2);
}
.np-off {
  background: var(--surface2);
  color: var(--t3);
  border: 1px solid var(--border);
}
.np-time-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}
.np-time-label {
  font-size: 13px;
  color: var(--t2);
  flex: 1;
  font-weight: 600;
}
.np-time-input {
  width: 60px;
  padding: 7px 10px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-size: 14px;
  font-weight: 700;
  text-align: center;
  font-family: "JetBrains Mono", monospace;
  outline: none;
  color: var(--t1);
}
.np-time-input:focus {
  border-color: var(--p);
}
.np-time-lbl {
  font-size: 14px;
  font-weight: 700;
  color: var(--t2);
}
.np-actions {
  display: flex;
  gap: 8px;
  margin-bottom: 8px;
}
.np-cancel-btn {
  flex: 1;
  padding: 10px;
  background: var(--red-lt);
  border: 1.5px solid rgba(239, 68, 68, 0.2);
  color: var(--red);
  border-radius: 9px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: 0.15s;
  font-family: inherit;
}
.np-cancel-btn:hover {
  background: var(--red);
  color: #fff;
}
.np-test-btn {
  width: 100%;
  padding: 8px;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--t3);
  cursor: pointer;
  transition: 0.15s;
  font-family: inherit;
}
.np-test-btn:hover {
  border-color: var(--p);
  color: var(--p);
}

@media (max-width: 600px) {
  .exam-setup-grid {
    grid-template-columns: 1fr;
  }
  .exr-stats {
    grid-template-columns: 1fr 1fr;
  }
  .eqa-opts {
    grid-template-columns: 1fr;
  }
  .exam-header {
    grid-template-columns: 1fr 80px;
  }
  .exh-right {
    display: none;
  }
  .notif-panel {
    right: 10px;
    width: calc(100vw - 20px);
  }
}

/* ══════════════════════════════════════════════════════
   FOOTER PROFESIONAL
══════════════════════════════════════════════════════ */
.yl-footer {
  background: #080d1e;
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  margin-top: auto;
  font-family: "Plus Jakarta Sans", sans-serif;
}

/* Main grid */
.footer-main {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
  gap: 40px;
  padding: 52px 48px 40px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

/* Brand column */
.ft-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}
.ft-logo-icon {
  font-size: 28px;
  width: 44px;
  height: 44px;
  background: linear-gradient(135deg, #5a5fe0, #8056d6);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(90, 95, 224, 0.35);
  flex-shrink: 0;
}
.ft-logo-name {
  font-size: 16px;
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.3px;
}
.ft-logo-tag {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.3);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-top: 1px;
}
.ft-desc {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.45);
  line-height: 1.75;
  margin-bottom: 16px;
}
.ft-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}
.ft-badge {
  font-size: 11px;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.6);
  padding: 4px 11px;
  border-radius: 20px;
}

/* Columns */
.ft-col {
  display: flex;
  flex-direction: column;
  gap: 1px;
}
.ft-col-title {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.35);
  margin-bottom: 12px;
  margin-top: 4px;
}
.ft-link {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: 0.15s;
  padding: 4px 0;
  display: flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  border: none;
  background: none;
  font-family: inherit;
  text-align: left;
}
.ft-link:hover {
  color: #a5b4ff;
  transform: translateX(2px);
}
.ft-link-ext::after {
  content: "↗";
  font-size: 10px;
  opacity: 0.4;
  margin-left: auto;
}
.ft-link-ext:hover::after {
  opacity: 0.8;
}
.ft-new {
  font-size: 9px;
  font-weight: 800;
  background: linear-gradient(135deg, #10b981, #0ea5e9);
  color: #fff;
  padding: 2px 6px;
  border-radius: 20px;
  letter-spacing: 0.05em;
}

/* Stats row */
.footer-stats {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: 24px 48px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.fst-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 0 36px;
}
.fst-num {
  font-size: 1.8rem;
  font-weight: 900;
  color: #fff;
  font-family: "Plus Jakarta Sans", sans-serif;
  line-height: 1;
}
.fst-lbl {
  font-size: 10.5px;
  color: rgba(255, 255, 255, 0.3);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.fst-div {
  width: 1px;
  height: 36px;
  background: rgba(255, 255, 255, 0.08);
  flex-shrink: 0;
}

/* Bottom bar */
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 48px;
  flex-wrap: wrap;
  gap: 10px;
}
.fb-left {
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.3);
}
.fb-left strong {
  color: rgba(255, 255, 255, 0.5);
}
.fb-right {
  display: flex;
  align-items: center;
  gap: 20px;
}
.fb-link {
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.3);
  cursor: pointer;
  transition: 0.15s;
  text-decoration: none;
  border: none;
  background: none;
  font-family: inherit;
}
.fb-link:hover {
  color: rgba(255, 255, 255, 0.7);
}

/* Ocultar footer en vistas que no son home */
#view-home ~ * .yl-footer,
#main:not(:has(#view-home.active)) .yl-footer {
  display: none;
}

/* Responsive */
@media (max-width: 1000px) {
  .footer-main {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
    padding: 40px 28px 32px;
  }
  .ft-brand {
    grid-column: 1/-1;
  }
}
@media (max-width: 600px) {
  .footer-main {
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    padding: 32px 20px 24px;
  }
  .footer-stats {
    padding: 20px;
    gap: 0;
  }
  .fst-item {
    padding: 0 16px;
  }
  .fst-num {
    font-size: 1.4rem;
  }
  .footer-bottom {
    flex-direction: column;
    text-align: center;
    padding: 16px 20px;
  }
  .fb-right {
    gap: 14px;
  }
}

/* ══════════════════════════════════════════════════════
   SIDEBAR TOGGLE — Desktop + Mobile
══════════════════════════════════════════════════════ */

/* Sidebar con transición suave */
#sidebar {
  transition:
    transform 0.28s cubic-bezier(0.4, 0, 0.2, 1),
    width 0.28s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

/* Estado cerrado en desktop */
#sidebar.sb-closed {
  transform: translateX(-100%);
}

/* Main se expande cuando sidebar está cerrado */
#main {
  transition: margin-left 0.28s cubic-bezier(0.4, 0, 0.2, 1);
}
#main.sb-expanded {
  margin-left: 0 !important;
}

/* Botón menú mejorado */
#menu-btn {
  width: 36px;
  height: 36px;
  display: flex !important;
  align-items: center;
  justify-content: center;
  border-radius: 9px;
  background: var(--surface2);
  border: 1.5px solid var(--border);
  color: var(--t2);
  cursor: pointer;
  transition: all 0.2s;
  flex-shrink: 0;
}
#menu-btn:hover {
  background: var(--p-lt);
  border-color: var(--p);
  color: var(--p);
}
#menu-btn.active {
  background: var(--p);
  border-color: var(--p);
  color: #fff;
}

/* Overlay oscuro detrás del sidebar en móvil */
.sb-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(2px);
  z-index: 99;
  animation: fadeIn 0.2s ease;
}
.sb-overlay.active {
  display: block;
}

@media (max-width: 900px) {
  /* En móvil el sidebar siempre parte cerrado */
  #sidebar {
    transform: translateX(-100%);
    z-index: 100;
  }
  #sidebar.open,
  #sidebar:not(.sb-closed) {
    transform: translateX(0);
  }
  #main {
    margin-left: 0 !important;
  }
}
