/* LexoDive — microcursos enriquecidos (YouTube + identidad académica Lexonari) */

body.lexodive-page,
body.deeplexo-page {
  background: #050508;
  color: #f4f4f5;
}

.lexodive-page,
.deeplexo-page,
.ldx-page {
  --dlx-bg: #050508;
  --dlx-surface: #111116;
  --dlx-surface-2: #1a1a22;
  --dlx-surface-3: #24242e;
  --dlx-border: rgba(255, 255, 255, 0.09);
  --dlx-text: #f4f4f5;
  --dlx-muted: #9ca3af;
  --dlx-accent: #7c6cff;
  --dlx-accent-2: #43b4ff;
  --dlx-glow: rgba(124, 108, 255, 0.35);
  --dlx-cert: #34d399;
  --dlx-yt: #ff3d3d;
}

/* ── Hero ─────────────────────────────────────────────── */
.dlx-hero {
  position: relative;
  padding: 56px 0 40px;
  overflow: hidden;
  border-bottom: 1px solid var(--dlx-border);
}

.dlx-hero::before {
  content: "";
  position: absolute;
  inset: -40% -20% auto;
  height: 420px;
  background:
    radial-gradient(ellipse 60% 80% at 20% 40%, rgba(124, 108, 255, 0.22), transparent 70%),
    radial-gradient(ellipse 50% 60% at 80% 20%, rgba(67, 180, 255, 0.14), transparent 65%);
  pointer-events: none;
}

.dlx-hero-inner {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.dlx-hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 40px;
  align-items: center;
}

@media (max-width: 900px) {
  .dlx-hero-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }
}

.dlx-brand-mark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--dlx-accent);
  margin-bottom: 14px;
}

.dlx-brand-mark::before {
  content: "";
  width: 28px;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--dlx-accent), var(--dlx-accent-2));
}

.dlx-tagline {
  color: var(--dlx-muted);
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.55;
  margin: 0 0 10px;
  max-width: 520px;
}

.dlx-hero h1 {
  font-size: clamp(2rem, 4.5vw, 3rem);
  font-weight: 800;
  line-height: 1.1;
  margin: 0 0 16px;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #fff 0%, #c4b5fd 55%, #93c5fd 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.dlx-lead {
  color: var(--dlx-muted);
  font-size: 1.05rem;
  line-height: 1.65;
  margin: 0 0 24px;
  max-width: 520px;
}

.dlx-hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.dlx-stat {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--dlx-border);
  border-radius: 14px;
  padding: 12px 18px;
  min-width: 100px;
}

.dlx-stat strong {
  display: block;
  font-size: 1.35rem;
  font-weight: 800;
  color: #fff;
  line-height: 1.2;
}

.dlx-stat span {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--dlx-muted);
  font-weight: 600;
}

.dlx-hero-visual {
  position: relative;
}

.dlx-preview-frame {
  position: relative;
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid rgba(124, 108, 255, 0.25);
  box-shadow:
    0 24px 60px rgba(0, 0, 0, 0.55),
    0 0 0 1px rgba(255, 255, 255, 0.04) inset,
    0 0 80px var(--dlx-glow);
  background: var(--dlx-surface);
  aspect-ratio: 16 / 10;
}

.dlx-preview-screen {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(160deg, rgba(124, 108, 255, 0.15) 0%, transparent 50%),
    linear-gradient(220deg, rgba(67, 180, 255, 0.1) 0%, transparent 40%),
    #0c0c12 center/cover;
}

.dlx-preview-play {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.dlx-preview-play span {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: rgba(124, 108, 255, 0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  color: #fff;
  box-shadow: 0 8px 32px var(--dlx-glow);
}

.dlx-preview-chips {
  position: absolute;
  bottom: 14px;
  left: 14px;
  right: 14px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.dlx-preview-chips span {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #e5e7eb;
  backdrop-filter: blur(8px);
}

.dlx-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 32px;
  padding-top: 28px;
  border-top: 1px solid var(--dlx-border);
}

.dlx-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(124, 108, 255, 0.08);
  border: 1px solid rgba(124, 108, 255, 0.22);
  color: #c4b5fd;
  font-size: 0.82rem;
  font-weight: 600;
}

/* ── Catálogo ─────────────────────────────────────────── */
.ldx-catalog,
.dlx-catalog {
  padding: 12px 0 0;
}

.ldx-hero-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.ldx-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 16px;
  align-items: flex-end;
  padding: 24px 0 20px;
  border-bottom: 1px solid var(--dlx-border);
}

.ldx-filter label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--dlx-muted);
  font-weight: 700;
}

.ldx-filter input,
.ldx-filter select {
  background: var(--dlx-surface);
  border: 1px solid var(--dlx-border);
  border-radius: 12px;
  color: var(--dlx-text);
  padding: 11px 14px;
  font-size: 0.9rem;
  min-width: 160px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.ldx-filter input:focus,
.ldx-filter select:focus {
  outline: none;
  border-color: rgba(124, 108, 255, 0.5);
  box-shadow: 0 0 0 3px rgba(124, 108, 255, 0.12);
}

.ldx-results {
  color: var(--dlx-muted);
  font-size: 0.88rem;
  margin: 20px 0 12px;
  font-weight: 500;
}

.ldx-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 22px 18px;
  padding-bottom: 56px;
}

/* ── Tarjetas ─────────────────────────────────────────── */
.ldx-card {
  background: var(--dlx-surface);
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid var(--dlx-border);
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
  cursor: pointer;
  text-align: left;
  width: 100%;
  padding: 0;
  font-family: inherit;
  color: inherit;
}

.ldx-card:hover {
  transform: translateY(-4px);
  border-color: rgba(124, 108, 255, 0.35);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.5), 0 0 40px rgba(124, 108, 255, 0.08);
}

.ldx-card-thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000 center/cover no-repeat;
  background-color: var(--dlx-surface-2);
}

.ldx-card-thumb::after {
  content: "▶";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  color: #fff;
  background: rgba(0, 0, 0, 0.25);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.ldx-card:hover .ldx-card-thumb::after {
  opacity: 1;
}

.ldx-card-duration {
  position: absolute;
  bottom: 10px;
  right: 10px;
  background: rgba(0, 0, 0, 0.88);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 4px 7px;
  border-radius: 6px;
  z-index: 2;
}

.ldx-card-level {
  position: absolute;
  top: 10px;
  left: 10px;
  background: rgba(5, 5, 8, 0.82);
  color: #c4b5fd;
  font-size: 0.65rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 5px 9px;
  border-radius: 8px;
  border: 1px solid rgba(124, 108, 255, 0.35);
  z-index: 2;
  backdrop-filter: blur(6px);
}

.ldx-card-cert {
  position: absolute;
  top: 10px;
  right: 10px;
  background: rgba(16, 185, 129, 0.18);
  color: var(--dlx-cert);
  font-size: 0.65rem;
  font-weight: 800;
  padding: 5px 9px;
  border-radius: 8px;
  border: 1px solid rgba(52, 211, 153, 0.4);
  z-index: 2;
  backdrop-filter: blur(6px);
}

.ldx-card-body {
  padding: 14px 14px 16px;
}

.ldx-card-title {
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--dlx-text);
  line-height: 1.4;
  margin: 0 0 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.ldx-card-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.ldx-card-avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--dlx-surface-2);
  border: 2px solid rgba(124, 108, 255, 0.25);
}

.ldx-card-analyst {
  font-size: 0.82rem;
  color: var(--dlx-muted);
  font-weight: 600;
}

.ldx-card-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  font-size: 0.76rem;
  color: var(--dlx-muted);
}

.ldx-card-progress {
  margin-top: 12px;
  height: 5px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 999px;
  overflow: hidden;
}

.ldx-card-progress-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--dlx-accent), var(--dlx-accent-2));
  border-radius: 999px;
}

.ldx-card-actions {
  margin-top: 12px;
}

.ldx-btn-share {
  background: transparent;
  border: 1px solid var(--dlx-border);
  color: var(--dlx-muted);
  font-size: 0.74rem;
  font-weight: 600;
  padding: 7px 12px;
  border-radius: 999px;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.15s ease;
}

.ldx-btn-share:hover {
  color: #c4b5fd;
  border-color: rgba(124, 108, 255, 0.4);
  background: rgba(124, 108, 255, 0.06);
}

/* ── Player ─────────────────────────────────────────────── */
.ldx-player-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 20000;
  background: rgba(2, 2, 6, 0.94);
  backdrop-filter: blur(12px);
  overflow-y: auto;
  padding: 16px;
}

.ldx-player-overlay.active {
  display: block;
}

.ldx-player-layout {
  max-width: 1280px;
  margin: 48px auto 24px;
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 28px;
  align-items: start;
}

@media (max-width: 960px) {
  .ldx-player-layout {
    grid-template-columns: 1fr;
    margin-top: 56px;
  }
}

.ldx-player-close {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 20001;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--dlx-border);
  color: #fff;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  font-size: 1.5rem;
  cursor: pointer;
  line-height: 1;
  transition: background 0.15s ease;
}

.ldx-player-close:hover {
  background: rgba(124, 108, 255, 0.2);
}

.ldx-video-wrap {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000;
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 18px;
  border: 1px solid var(--dlx-border);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
}

.ldx-video-wrap iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
}

.ldx-player-title {
  font-size: 1.4rem;
  font-weight: 800;
  color: #fff;
  margin: 0 0 10px;
  letter-spacing: -0.01em;
}

.ldx-player-desc {
  color: var(--dlx-muted);
  font-size: 0.94rem;
  line-height: 1.6;
  margin-bottom: 18px;
}

.ldx-yt-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--dlx-yt);
  font-size: 0.88rem;
  font-weight: 700;
  text-decoration: none;
  margin-bottom: 22px;
  padding: 8px 14px;
  border-radius: 10px;
  background: rgba(255, 61, 61, 0.08);
  border: 1px solid rgba(255, 61, 61, 0.2);
}

.ldx-yt-link:hover {
  background: rgba(255, 61, 61, 0.14);
}

.ldx-timeline {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.ldx-timeline-module {
  flex: 1 1 auto;
  min-width: 88px;
  padding: 11px 14px;
  border-radius: 12px;
  border: 1px solid var(--dlx-border);
  background: var(--dlx-surface);
  color: var(--dlx-muted);
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  text-align: center;
  font-family: inherit;
  transition: all 0.15s ease;
}

.ldx-timeline-module.active,
.ldx-timeline-module:hover {
  border-color: var(--dlx-accent);
  color: #c4b5fd;
  background: rgba(124, 108, 255, 0.1);
}

.ldx-sidebar {
  background: var(--dlx-surface);
  border-radius: 16px;
  border: 1px solid var(--dlx-border);
  padding: 20px;
  position: sticky;
  top: 16px;
}

.ldx-sidebar h3 {
  margin: 0 0 16px;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--dlx-accent);
  font-weight: 800;
}

.ldx-structure-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.ldx-structure-list li {
  padding: 11px 0;
  border-bottom: 1px solid var(--dlx-border);
  font-size: 0.88rem;
  color: var(--dlx-muted);
  display: flex;
  align-items: center;
  gap: 10px;
}

.ldx-structure-list li:last-child {
  border-bottom: none;
}

.ldx-structure-icon {
  width: 28px;
  text-align: center;
  flex-shrink: 0;
}

.ldx-cta-box {
  margin-top: 20px;
  padding: 18px;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(124, 108, 255, 0.12), rgba(67, 180, 255, 0.06));
  border: 1px solid rgba(124, 108, 255, 0.25);
}

.ldx-cta-box p {
  margin: 0 0 14px;
  font-size: 0.86rem;
  color: var(--dlx-muted);
  line-height: 1.55;
}

.ldx-empty {
  text-align: center;
  padding: 72px 20px;
  color: var(--dlx-muted);
  font-size: 0.95rem;
}

/* ── Index teaser ───────────────────────────────────────── */
.dlx-index-section {
  text-align: center;
  max-width: 1200px;
  margin: 56px auto 0;
  padding: 52px 36px 44px;
  background:
    linear-gradient(160deg, rgba(124, 108, 255, 0.07) 0%, transparent 45%),
    linear-gradient(180deg, rgba(17, 17, 22, 0.9) 0%, rgba(5, 5, 8, 0.95) 100%);
  border: 1px solid rgba(124, 108, 255, 0.18);
  border-radius: 36px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
}

.dlx-index-section .dlx-index-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #c4b5fd;
  margin-bottom: 14px;
}

.dlx-index-section .dlx-index-eyebrow::before,
.dlx-index-section .dlx-index-eyebrow::after {
  content: "";
  width: 20px;
  height: 2px;
  background: linear-gradient(90deg, transparent, #7c6cff);
  border-radius: 999px;
}

.dlx-index-section .dlx-index-eyebrow::after {
  background: linear-gradient(90deg, #7c6cff, transparent);
}

.dlx-index-section h2 {
  font-size: clamp(1.9rem, 3vw, 2.6rem);
  margin: 0 0 14px;
  color: #fff;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.dlx-index-tagline {
  color: #a78bfa;
  font-weight: 600;
  font-size: 1.05rem;
  margin: 0 0 10px;
}

.dlx-index-lead {
  color: #9ca3af;
  font-size: 1.05rem;
  max-width: 620px;
  margin: 0 auto 32px;
  line-height: 1.65;
}

.dlx-index-teaser .ldx-grid {
  padding-bottom: 28px;
  text-align: left;
}

.dlx-index-actions {
  margin-top: 4px;
}

.dlx-index-actions .btn-primary {
  background: linear-gradient(135deg, #7c6cff, #5b4fd9);
  border: none;
  box-shadow: 0 8px 28px rgba(124, 108, 255, 0.35);
}

a.ldx-card {
  text-decoration: none;
  display: block;
}

/* ═══════════════════════════════════════════════════════
   LexoDive — layout tipo YouTube
   ═══════════════════════════════════════════════════════ */

body.ldx-yt {
  background: #0f0f0f;
  color: #f1f1f1;
  margin: 0;
  min-height: 100vh;
}

body.ldx-yt::before {
  display: none;
}

.ldx-topbar {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 12px 16px;
  min-height: 56px;
  padding: 8px 20px;
  background: rgba(15, 15, 15, 0.96);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(10px);
}

.ldx-topbar-start {
  flex-shrink: 0;
  min-width: 0;
}

.ldx-topbar-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: #fff;
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
}

.ldx-topbar-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: linear-gradient(135deg, #7c6cff, #43b4ff);
  font-size: 0.75rem;
  color: #fff;
}

.ldx-topbar-brand img {
  border-radius: 8px;
}

.ldx-topbar-filters {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  flex: 1 1 auto;
  min-width: 0;
}

.ldx-topbar-filters input,
.ldx-topbar-filters select {
  background: #212121;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  color: #f1f1f1;
  padding: 5px 10px;
  font-size: 0.76rem;
  font-family: inherit;
}

.ldx-topbar-filters input:focus,
.ldx-topbar-filters select:focus {
  outline: none;
  border-color: rgba(124, 108, 255, 0.55);
}

.ldx-topbar-filters input {
  width: auto;
  min-width: 148px;
  flex: 1 1 148px;
  max-width: 220px;
}

.ldx-topbar-filters select {
  width: auto;
  flex: 0 1 auto;
  max-width: 160px;
}

.ldx-topbar-end {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-shrink: 0;
  margin-left: auto;
}

.ldx-nav-auth {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.ldx-topbar-lexonari {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px;
  border-radius: 10px;
  opacity: 0.88;
  transition: opacity 0.15s ease, background 0.15s ease;
  line-height: 0;
}

.ldx-topbar-lexonari:hover {
  opacity: 1;
  background: rgba(255, 255, 255, 0.06);
}

.ldx-topbar-lexonari img {
  display: block;
  width: 28px;
  height: 28px;
  object-fit: contain;
}

.ldx-auth-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 0.76rem;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  font-family: inherit;
}

.ldx-auth-btn--primary {
  background: #7c6cff;
  border-color: transparent;
}

.ldx-auth-btn--outline {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #e5e5e5;
  cursor: pointer;
  font-family: inherit;
}

.ldx-auth-btn--outline:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.ldx-auth-link--name {
  font-size: 0.78rem;
  color: #ccc;
  text-decoration: none;
  font-weight: 600;
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ldx-auth-link--name:hover {
  color: #fff;
}

.ldx-auth-user {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ldx-auth-link {
  font-size: 0.78rem;
  color: #7c6cff;
  text-decoration: none;
  font-weight: 600;
}

.ldx-app {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 24px;
  max-width: 1720px;
  margin: 0 auto;
  padding: 24px 20px 40px;
  align-items: start;
}

@media (max-width: 1100px) {
  .ldx-app {
    grid-template-columns: 1fr;
  }
  .ldx-sidebar {
    order: -1;
  }
}

/* Con una actividad abierta usamos todo el ancho de la pantalla (manteniendo la sidebar). */
.ldx-app--act {
  max-width: 100%;
  padding: 12px 16px 14px;
}
/* La columna principal ocupa el alto disponible, igual que la sidebar.
   IMPORTANTE: height (no min-height) — el iframe de adentro usa height:100%, y los
   porcentajes solo se resuelven si toda la cadena tiene altura DEFINIDA. Con min-height
   el iframe colapsaba a su alto por defecto (~150px). 30px = topbar + paddings reducidos. */
.ldx-app--act .ldx-main {
  height: calc(100vh - 30px);
  display: flex;
  flex-direction: column;
}
.ldx-app--act #ldx-act-section {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.ldx-app--act #ldx-act-mount {
  flex: 1;
  min-height: 0;
  height: 0;
}

.ldx-main {
  min-width: 0;
}

.ldx-welcome {
  background: #0f0f0f;
  border-radius: 16px;
  min-height: min(72vh, 640px);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.ldx-welcome-inner {
  max-width: 640px;
  padding: 40px 32px;
  text-align: left;
}

.ldx-welcome-badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #a78bfa;
  margin-bottom: 12px;
}

.ldx-welcome h1 {
  font-size: clamp(1.75rem, 3vw, 2.35rem);
  font-weight: 800;
  margin: 0 0 16px;
  line-height: 1.15;
  color: #fff;
}

.ldx-welcome-lead {
  color: #aaa;
  font-size: 1.05rem;
  line-height: 1.65;
  margin: 0 0 20px;
}

.ldx-welcome-features {
  margin: 0 0 20px;
  padding: 0;
  list-style: none;
  color: #ccc;
  font-size: 0.92rem;
  line-height: 1.8;
}

.ldx-welcome-hint {
  color: #777;
  font-size: 0.88rem;
  margin: 0 0 20px;
}

.ldx-welcome-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 0.82rem;
  color: #888;
}

.ldx-welcome-stats strong {
  color: #fff;
}

.is-hidden {
  display: none !important;
}

.ldx-player-shell {
  position: relative;
  width: 100%;
  min-height: min(78vh, 860px);
  height: min(78vh, 860px);
  background: #0a0a0a;
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 16px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.ldx-player-shell iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
}

.ldx-player-meta {
  margin-top: 4px;
}

.ldx-player-note {
  margin: 0 0 14px;
  color: #777;
  font-size: 0.84rem;
}

.ldx-list-item--enrolled .ldx-list-title {
  color: #c4b5fd;
}

.ldx-list-item--enrolled.is-active {
  background: rgba(124, 108, 255, 0.14);
  border: 1px solid rgba(124, 108, 255, 0.28);
}

#ldx-enrolled-block {
  border-color: rgba(124, 108, 255, 0.2);
}

.ldx-preview-hero {
  margin-bottom: 18px;
}

.ldx-preview-media {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 16px;
  overflow: hidden;
  background: #111 center / cover no-repeat;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.ldx-preview-level,
.ldx-preview-duration,
.ldx-preview-cert {
  position: absolute;
  padding: 5px 10px;
  border-radius: 8px;
  font-size: 0.72rem;
  font-weight: 700;
  background: rgba(0, 0, 0, 0.72);
  color: #fff;
  backdrop-filter: blur(4px);
}

.ldx-preview-level {
  top: 12px;
  left: 12px;
}

.ldx-preview-duration {
  bottom: 12px;
  right: 12px;
}

.ldx-preview-cert {
  top: 12px;
  right: 12px;
  background: rgba(124, 108, 255, 0.85);
}

.ldx-course-analyst {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
  font-size: 0.88rem;
  color: #bbb;
  font-weight: 600;
}

.ldx-course-analyst img {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.ldx-course-tagline {
  margin: 0 0 12px;
  color: #c4b5fd;
  font-size: 0.95rem;
  line-height: 1.45;
}

.ldx-course-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  margin-bottom: 14px;
  font-size: 0.84rem;
  color: #888;
}

.ldx-course-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0 0 10px;
  line-height: 1.35;
  color: #fff;
}

.ldx-course-desc {
  color: #aaa;
  font-size: 0.92rem;
  line-height: 1.6;
  margin: 0 0 16px;
}

.ldx-course-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.ldx-btn-enroll {
  display: inline-flex;
  padding: 10px 18px;
  border-radius: 999px;
  background: #7c6cff;
  color: #fff;
  font-weight: 700;
  font-size: 0.88rem;
  text-decoration: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
}

.ldx-btn-enroll:disabled,
.ldx-btn-enroll--done {
  background: rgba(52, 211, 153, 0.2);
  border: 1px solid rgba(52, 211, 153, 0.35);
  color: #6ee7b7;
  cursor: default;
}

.ldx-enroll-course {
  margin: 0 0 14px;
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
  line-height: 1.35;
}

.ldx-enroll-user {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 14px;
  margin-bottom: 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.ldx-enroll-user__name {
  font-weight: 700;
  color: #f1f1f1;
  font-size: 0.95rem;
}

.ldx-enroll-user__email {
  color: #888;
  font-size: 0.84rem;
}

.ldx-enroll-note {
  margin: 0 0 16px;
  color: #999;
  font-size: 0.86rem;
  line-height: 1.5;
}

.ldx-enroll-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ldx-enroll-cancel {
  width: 100%;
  text-align: center;
}

.ldx-enroll-success {
  margin: 14px 0 0;
  padding: 12px;
  border-radius: 10px;
  background: rgba(52, 211, 153, 0.12);
  border: 1px solid rgba(52, 211, 153, 0.3);
  color: #6ee7b7;
  font-size: 0.88rem;
  text-align: center;
}

.ldx-enroll-success.is-hidden {
  display: none;
}

.ldx-btn-ghost {
  padding: 10px 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #ccc;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
}

.ldx-btn-ghost:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.ldx-sidebar {
  position: sticky;
  top: 72px;
  max-height: calc(100vh - 88px);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
  scrollbar-width: thin;
  scrollbar-color: #333 transparent;
}

.ldx-sidebar-block {
  background: #0f0f0f;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 14px;
  padding: 14px;
}

.ldx-sidebar-label {
  margin: 0 0 10px;
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #777;
}

.ldx-filters {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ldx-filters input,
.ldx-filters select {
  width: 100%;
  background: #212121;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  color: #f1f1f1;
  padding: 9px 12px;
  font-size: 0.85rem;
  font-family: inherit;
}

.ldx-results {
  margin: 10px 0 0;
  font-size: 0.75rem;
  color: #666;
}

.ldx-course-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ldx-list-item {
  display: flex;
  gap: 10px;
  width: 100%;
  padding: 6px;
  border: none;
  border-radius: 10px;
  background: transparent;
  cursor: pointer;
  text-align: left;
  font-family: inherit;
  color: inherit;
  transition: background 0.15s ease;
}

.ldx-list-item:hover {
  background: rgba(255, 255, 255, 0.06);
}

.ldx-list-item.is-active {
  background: rgba(124, 108, 255, 0.12);
}

.ldx-list-thumb {
  position: relative;
  flex-shrink: 0;
  width: 112px;
  height: 63px;
  border-radius: 10px;
  background: #212121 center/cover no-repeat;
  overflow: hidden;
}

.ldx-list-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.ldx-list-duration {
  position: absolute;
  bottom: 6px;
  right: 6px;
  background: rgba(0, 0, 0, 0.82);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 2px 5px;
  border-radius: 4px;
}

.ldx-list-cert {
  position: absolute;
  top: 6px;
  left: 6px;
  font-size: 0.75rem;
}

.ldx-list-body {
  min-width: 0;
  flex: 1;
  padding-top: 2px;
}

.ldx-list-title {
  margin: 0 0 6px;
  font-size: 0.88rem;
  font-weight: 700;
  line-height: 1.35;
  color: #f1f1f1;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.ldx-list-meta {
  margin: 0;
  font-size: 0.75rem;
  color: #888;
  line-height: 1.4;
}

.ldx-platform-links {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ldx-platform-links a {
  color: #aaa;
  text-decoration: none;
  font-size: 0.84rem;
  font-weight: 600;
  padding: 6px 4px;
  border-radius: 8px;
}

.ldx-platform-links a:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.05);
}

.ldx-platform-note {
  margin: 0 0 10px;
  font-size: 0.78rem;
  color: #666;
  line-height: 1.45;
}

.ldx-powered {
  max-width: 1720px;
  margin: 0 auto;
  padding: 20px 20px 32px;
  font-size: 0.78rem;
  color: #555;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.ldx-powered a {
  color: #888;
  text-decoration: none;
  font-weight: 600;
}

.ldx-powered a:hover {
  color: #c4b5fd;
}

.ldx-powered-sep {
  opacity: 0.4;
}

.ldx-empty {
  color: #666;
  font-size: 0.85rem;
  text-align: center;
  padding: 16px 8px;
  margin: 0;
}

@media (max-width: 900px) {
  .ldx-topbar {
    flex-wrap: wrap;
  }
  .ldx-topbar-filters {
    flex-basis: 100%;
    order: 3;
    flex-wrap: wrap;
  }
}

@media (max-width: 1150px) {
  .ldx-topbar-visits {
    display: none !important;
  }
}

@media (max-width: 1200px) {
  .ldx-topbar {
    gap: 8px 12px;
    padding: 8px 12px;
  }
  .ldx-topbar-filters input {
    max-width: 150px;
    min-width: 100px;
  }
  .ldx-topbar-filters select {
    max-width: 130px;
  }
}

@media (max-width: 600px) {
  .ldx-topbar-filters select {
    flex: 1 1 calc(50% - 4px);
    max-width: none;
  }

  .ldx-topbar-filters input {
    flex: 1 1 100%;
    max-width: none;
  }

  .ldx-list-thumb {
    width: 120px;
    height: 68px;
  }
}

/* Login emergente integrado */
body.ldx-auth-modal-open {
  overflow: hidden;
}

/* Captcha OVNI por encima del modal de auth (2100 < 3000 en styles.css) */
.lexodive-page .modal-captcha-overlay {
  z-index: 4000;
}

.ldx-onboarding-hint {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  padding: 10px 20px;
  background: rgba(124, 108, 255, 0.12);
  border-bottom: 1px solid rgba(124, 108, 255, 0.25);
  color: #ddd;
  font-size: 0.84rem;
}

.ldx-onboarding-hint.is-hidden {
  display: none;
}

.ldx-onboarding-hint a {
  color: #c4b5fd;
  font-weight: 700;
  text-decoration: none;
}

.ldx-onboarding-hint a:hover {
  text-decoration: underline;
}

.ldx-onboarding-hint__dismiss {
  background: none;
  border: none;
  color: #888;
  font-size: 1.2rem;
  cursor: pointer;
  padding: 0 4px;
  line-height: 1;
}

.ldx-auth-modal {
  position: fixed;
  inset: 0;
  z-index: 3000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.ldx-auth-modal.is-open {
  opacity: 1;
  visibility: visible;
}

.ldx-auth-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(6px);
}

.ldx-auth-modal__panel {
  position: relative;
  width: min(440px, 100%);
  max-height: min(90vh, 720px);
  overflow-y: auto;
  padding: 28px 24px 24px;
  border-radius: 18px;
  background: #181818;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
  transform: translateY(12px);
  transition: transform 0.2s ease;
}

.ldx-auth-modal.is-open .ldx-auth-modal__panel {
  transform: translateY(0);
}

.ldx-auth-modal__close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  color: #aaa;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
}

.ldx-auth-modal__close:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

.ldx-auth-modal__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
  font-weight: 800;
  font-size: 1.05rem;
  color: #fff;
}

.ldx-auth-modal__error {
  margin: 0 0 12px;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(248, 113, 113, 0.12);
  border: 1px solid rgba(248, 113, 113, 0.3);
  color: #fca5a5;
  font-size: 0.82rem;
  line-height: 1.45;
}

.ldx-auth-modal__error.is-hidden {
  display: none;
}

.ldx-auth-view.is-hidden {
  display: none;
}

.ldx-auth-view__title {
  margin: 0 0 6px;
  font-size: 1.35rem;
  color: #fff;
}

.ldx-auth-view__sub {
  margin: 0 0 18px;
  color: #999;
  font-size: 0.88rem;
  line-height: 1.5;
}

.ldx-auth-view__sub strong {
  color: #c4b5fd;
}

.ldx-auth-view__note {
  margin: 0 0 14px;
  color: #6ee7b7;
  font-size: 0.84rem;
  line-height: 1.45;
}

.ldx-auth-view__note.is-hidden {
  display: none;
}

.ldx-auth-pending-icon {
  font-size: 2.4rem;
  margin-bottom: 8px;
}

.ldx-auth-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ldx-auth-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

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

.ldx-auth-field span {
  font-size: 0.78rem;
  font-weight: 600;
  color: #aaa;
}

.ldx-auth-field small {
  font-weight: 400;
  color: #666;
}

.ldx-auth-field input,
.ldx-auth-field select {
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: #212121;
  color: #f1f1f1;
  font-size: 0.9rem;
  font-family: inherit;
}

.ldx-auth-field input:focus,
.ldx-auth-field select:focus {
  outline: none;
  border-color: rgba(124, 108, 255, 0.55);
}

.ldx-auth-pass-wrap {
  position: relative;
}

.ldx-auth-pass-wrap input {
  padding-right: 40px;
}

.ldx-auth-pass-toggle {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  border: none;
  background: none;
  color: #777;
  cursor: pointer;
  font-size: 1rem;
  padding: 0;
}

.ldx-auth-remember {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.84rem;
  color: #999;
  cursor: pointer;
}

.ldx-auth-remember input {
  width: 16px;
  height: 16px;
  margin: 0;
}

.ldx-auth-submit {
  margin-top: 4px;
  width: 100%;
  padding: 11px 16px;
  border: none;
  border-radius: 999px;
  background: linear-gradient(135deg, #7c6cff, #43b4ff);
  color: #fff;
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
}

.ldx-auth-submit:disabled {
  opacity: 0.6;
  cursor: wait;
}

.ldx-auth-switch {
  margin: 14px 0 0;
  text-align: center;
  font-size: 0.84rem;
  color: #777;
}

.ldx-auth-switch a {
  color: #a78bfa;
  text-decoration: none;
  font-weight: 600;
}

.ldx-auth-switch a:hover {
  text-decoration: underline;
}

@media (max-width: 480px) {
  .ldx-auth-row {
    grid-template-columns: 1fr;
  }
}
