/* Base mínima para las guías estáticas de /aprender (2026-10-18). Reproduce lo que el juego trae de
   Tailwind (preflight) e index.css, para que la guía se vea igual sin cargar los 900 KB de estilos
   ni los 5 MB del juego. El generador la junta con src/pages/user/learnV2.css. */
*,
::before,
::after {
  box-sizing: border-box;
  border-width: 0;
  border-style: solid;
  border-color: #e5e7eb;
}
html {
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
  tab-size: 4;
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
html.xima-public-learn-page,
body.xima-public-learn-page {
  min-height: 100%;
  height: auto;
  overflow-x: hidden;
  overflow-y: auto;
  background: #060b1c;
}
body {
  margin: 0;
  line-height: inherit;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen", "Ubuntu", "Cantarell",
    "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
body.xima-public-learn-page #root {
  min-height: 100vh;
  height: auto;
  overflow: visible;
}
h1,
h2,
h3,
h4,
h5,
h6 {
  font-size: inherit;
  font-weight: inherit;
  margin: 0;
}
a {
  color: inherit;
  text-decoration: inherit;
}
b,
strong {
  font-weight: bolder;
}
small {
  font-size: 80%;
}
table {
  text-indent: 0;
  border-color: inherit;
  border-collapse: collapse;
}
button,
input,
select,
textarea {
  font-family: inherit;
  font-size: 100%;
  font-weight: inherit;
  line-height: inherit;
  color: inherit;
  margin: 0;
  padding: 0;
}
button {
  background-color: transparent;
  background-image: none;
  cursor: pointer;
}
summary {
  display: list-item;
}
blockquote,
dl,
dd,
h1,
h2,
h3,
h4,
h5,
h6,
hr,
figure,
p,
pre {
  margin: 0;
}
ol,
ul,
menu {
  list-style: none;
  margin: 0;
  padding: 0;
}
img,
svg,
video,
canvas,
audio,
iframe,
embed,
object {
  display: block;
  vertical-align: middle;
}
img,
video {
  max-width: 100%;
  height: auto;
}
[hidden] {
  display: none;
}

/* Aprender (/game/learn y /aprender) rediseñado el 2026-10-18: menú lateral Clásico, pestañas,
   buscador, barra de progreso, temas con progreso propio, guías y libros. Clases xle-*. */
.xle-root {
  --xle-line: #1d2f5c;
  --xle-line-soft: #17264d;
  --xle-text: #eef0f5;
  --xle-soft: #c9d4ec;
  --xle-mute: #8d9ab8;
  --xle-gold: #f5b531;
  --xle-neon: #3dff7a;
  --xle-cyan: #38bdf8;
  --xle-red: #ff4d6d;
  --xle-field: #071431;
  --xle-card: linear-gradient(180deg, rgba(14, 28, 64, 0.88), rgba(9, 19, 45, 0.88));
}

.xle-root *,
.xle-root *::before,
.xle-root *::after {
  box-sizing: border-box;
}

.xle-root .xle-main {
  color: var(--xle-text);
  background:
    radial-gradient(900px 500px at 85% -10%, rgba(56, 189, 248, 0.14), transparent 60%),
    radial-gradient(700px 500px at 10% 110%, rgba(61, 255, 122, 0.07), transparent 60%),
    linear-gradient(180deg, #081028, #060b1c);
  padding: 22px 32px 48px;
}

.xle-root.is-public {
  display: block;
  min-height: 100vh;
  background: #060b1c;
  font-family: "Inter", "Segoe UI", system-ui, sans-serif;
  text-align: left;
}

.xle-root.is-public .xle-main {
  min-height: 100vh;
}

.xle-shell {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
}

.xle-root h1,
.xle-root h2,
.xle-root h3,
.xle-root p {
  margin: 0;
}

.xle-root a {
  color: inherit;
  text-decoration: none;
}

.xle-root button {
  font-family: inherit;
  color: inherit;
  cursor: pointer;
}

.xle-root button:disabled {
  cursor: default;
  opacity: 0.5;
}

.xle-mute {
  color: var(--xle-mute);
  font-size: 13px;
}

.xle-back {
  align-self: flex-start;
  padding: 0;
  border: 0;
  background: none;
  color: var(--xle-mute);
  font-size: 13px;
}

.xle-back:hover {
  color: var(--xle-text);
}

/* Cabecera con buscador */
.xle-head {
  display: flex;
  align-items: center;
  gap: 16px;
}

.xle-ico {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 54px;
  height: 54px;
  border: 1px solid rgba(56, 189, 248, 0.6);
  border-radius: 50%;
  background: radial-gradient(circle, #0c2d4a, #081627);
  box-shadow: 0 0 22px rgba(56, 189, 248, 0.35);
  font-size: 26px;
}

.xle-head-text {
  flex: 1;
  min-width: 0;
}

.xle-head h1 {
  font-size: 34px;
  font-weight: 900;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.xle-head-text p {
  margin-top: 2px;
  color: var(--xle-mute);
  font-size: 14px;
}

.xle-search {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 0 1 440px;
  min-width: 0;
  padding: 0 14px;
  border: 1px solid #2f5fa8;
  border-radius: 14px;
  background: var(--xle-field);
  box-shadow: 0 0 20px rgba(56, 189, 248, 0.15);
}

.xle-search input {
  flex: 1;
  min-width: 0;
  height: 46px;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--xle-text);
  font-size: 14px;
}

.xle-search input::placeholder {
  color: var(--xle-mute);
}

.xle-search input::-webkit-search-cancel-button {
  display: none;
}

.xle-search button {
  border: 0;
  background: none;
  color: var(--xle-mute);
  font-size: 14px;
}

.xle-play {
  flex-shrink: 0;
}

/* Pestañas */
.xle-tabs {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  border-bottom: 1px solid var(--xle-line);
  scrollbar-width: none;
}

.xle-tabs::-webkit-scrollbar {
  display: none;
}

.xle-tab {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  flex-shrink: 0;
  padding: 11px 16px;
  border: 0;
  border-bottom: 3px solid transparent;
  background: none;
  color: #9fb3da !important;
  font-size: 14px;
  font-weight: 800;
  white-space: nowrap;
}

.xle-tab:hover {
  color: var(--xle-text) !important;
}

.xle-tab.is-on {
  border-bottom-color: var(--xle-gold);
  color: var(--xle-gold) !important;
}

.xle-tab small {
  padding: 1px 7px;
  border-radius: 8px;
  background: #13254d;
  color: #b9c6e4;
  font-size: 11px;
}

/* Barra de progreso */
.xle-progress {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 11px 16px;
  border: 1px solid var(--xle-line);
  border-radius: 14px;
  background: rgba(9, 19, 45, 0.8);
}

.xle-progress strong {
  flex-shrink: 0;
  font-size: 13px;
}

.xle-progress b {
  color: var(--xle-neon);
}

.xle-bar,
.xle-mini {
  display: block;
  overflow: hidden;
  border-radius: 9px;
  background: #13254d;
}

.xle-bar {
  flex: 1;
  min-width: 60px;
  height: 9px;
}

.xle-mini {
  width: 100%;
  height: 5px;
}

.xle-bar i,
.xle-mini i {
  display: block;
  height: 100%;
  min-width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--xle-neon), var(--xle-cyan));
  transition: width 0.3s ease;
}

.xle-mini i {
  background: var(--xle-neon);
}

/* Piezas comunes */
.xle-card {
  border: 1px solid var(--xle-line);
  border-radius: 16px;
  background: var(--xle-card);
  padding: 18px;
}

.xle-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.xle-pill.is-gold {
  border: 1px solid rgba(245, 181, 49, 0.45);
  background: rgba(245, 181, 49, 0.14);
  color: var(--xle-gold);
}

.xle-pill.is-green {
  border: 1px solid rgba(61, 255, 122, 0.4);
  background: rgba(61, 255, 122, 0.12);
  color: var(--xle-neon);
}

.xle-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 16px;
  border: 1px solid #2a3a66;
  border-radius: 10px;
  background: #0f1d40;
  color: var(--xle-text) !important;
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
}

.xle-btn:hover:not(:disabled) {
  border-color: var(--xle-cyan);
}

.xle-btn.is-go {
  border: 0;
  background: linear-gradient(180deg, #3dff7a, #1fbf55);
  color: #062012 !important;
}

.xle-btn.is-red {
  border-color: rgba(255, 77, 109, 0.5);
  background: rgba(255, 77, 109, 0.08);
  color: #ff8aa0 !important;
}

.xle-btn.is-sm {
  padding: 4px 10px;
  border-radius: 7px;
  font-size: 11px;
}

.xle-link {
  padding: 0;
  border: 0;
  background: none;
  color: var(--xle-cyan) !important;
  font-size: 13px;
  font-weight: 700;
}

.xle-row-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.xle-h2 {
  color: #9fb3da;
  font-size: 15px !important;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.xle-h2-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.xle-side-title {
  padding: 2px 4px 8px;
  color: var(--xle-mute);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.xle-status {
  color: var(--xle-soft);
}

.xle-status.is-error {
  border-color: rgba(255, 77, 109, 0.5);
  color: #ff8aa0;
}

.xle-empty {
  color: var(--xle-mute);
  text-align: center;
}

/* Empezar: tres pasos */
.xle-steps {
  display: grid;
  grid-template-columns: 1.25fr 1fr 1fr;
  gap: 14px;
}

.xle-step {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 16px 18px;
}

.xle-step.is-done {
  border-color: rgba(61, 255, 122, 0.4);
}

.xle-step-head {
  display: flex;
  align-items: center;
  gap: 10px;
}

.xle-step-head strong {
  font-size: 18px;
  font-weight: 900;
}

.xle-num {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--xle-gold);
  color: #1a1200;
  font-size: 15px;
  font-weight: 900;
}

.xle-step.is-done .xle-num {
  background: var(--xle-neon);
  color: #062012;
}

.xle-step p {
  color: var(--xle-mute);
  font-size: 13px;
  line-height: 1.45;
}

.xle-step-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
}

.xle-vthumbs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.xle-vthumb {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  min-height: 96px;
  padding: 8px;
  overflow: hidden;
  border: 1px solid #2a3a66;
  border-radius: 10px;
  background-color: #0a1533;
  background-position: center;
  background-size: cover;
  text-align: center;
}

.xle-vthumb::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(6, 11, 28, 0.15), rgba(6, 11, 28, 0.85));
}

.xle-vthumb > * {
  position: relative;
}

.xle-vthumb-play {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  margin: auto 0 0;
  border-radius: 50%;
  background: var(--xle-red);
  color: #fff;
  font-size: 14px;
}

.xle-vthumb-title {
  color: #e7edfb;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.25;
}

.xle-vthumb small {
  position: absolute;
  top: 6px;
  right: 7px;
  padding: 1px 5px;
  border-radius: 5px;
  background: rgba(0, 0, 0, 0.7);
  color: #fff;
  font-size: 10px;
}

/* Temas con progreso */
.xle-tiles {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
}

.xle-tile {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 5px;
  padding: 14px;
  border: 1px solid var(--xle-line);
  border-radius: 14px;
  background: var(--xle-card);
  text-align: left;
  transition: border-color 0.15s ease, transform 0.15s ease;
}

.xle-tile:hover {
  border-color: var(--xle-cyan);
  transform: translateY(-2px);
}

.xle-tile-icon {
  font-size: 24px;
}

.xle-tile strong {
  font-size: 14px;
  font-weight: 800;
}

.xle-tile-count {
  color: var(--xle-mute);
  font-size: 12px;
}

.xle-tile .xle-mini {
  margin-top: 4px;
}

.xle-tile-new {
  position: absolute;
  top: 10px;
  right: 10px;
}

/* Abajo: libros y canal */
.xle-bottom {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.xle-book-card,
.xle-yt-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px;
  transition: border-color 0.15s ease;
}

.xle-book-card:hover,
.xle-yt-card:hover {
  border-color: var(--xle-cyan);
}

.xle-book-card img {
  flex-shrink: 0;
  width: 62px;
  height: 80px;
  border: 1px solid #2a3a66;
  border-radius: 8px;
  object-fit: cover;
}

.xle-yt-card {
  border-color: rgba(255, 77, 109, 0.4);
}

.xle-yt-icon {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 54px;
  height: 54px;
  border: 1px solid rgba(255, 77, 109, 0.6);
  border-radius: 50%;
  background: radial-gradient(circle, #4a0c1c, #1a0710);
  box-shadow: 0 0 22px rgba(255, 77, 109, 0.3);
  color: var(--xle-red);
  font-size: 20px;
}

.xle-book-card-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  min-width: 0;
}

.xle-book-card-text strong {
  font-size: 15px;
  font-weight: 800;
}

.xle-book-card-text > span:not(.xle-btn) {
  color: var(--xle-mute);
  font-size: 13px;
  line-height: 1.35;
}

.xle-book-card-text .xle-btn {
  margin-top: 4px;
}

/* Videos */
.xle-videos {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.xle-video {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
}

.xle-video-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border: 1px solid #2a3a66;
  border-radius: 12px;
  background: #050a18;
}

.xle-video-frame iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.xle-video-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.xle-video-text strong {
  font-size: 17px;
  font-weight: 900;
}

.xle-video-text span {
  color: var(--xle-mute);
  font-size: 13px;
}

/* Reglas */
.xle-rules {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.xle-rules-head {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.xle-rules-head strong {
  font-size: 20px;
  font-weight: 900;
}

.xle-objective {
  padding: 14px 16px;
  border: 1px solid rgba(245, 181, 49, 0.45);
  border-radius: 12px;
  background: rgba(245, 181, 49, 0.08);
}

.xle-objective span {
  color: var(--xle-gold);
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.xle-objective p {
  margin-top: 4px;
  font-size: 16px;
  font-weight: 700;
}

.xle-rule-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.xle-rule-list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid var(--xle-line-soft);
  border-radius: 12px;
  background: rgba(7, 20, 49, 0.7);
}

.xle-rule-list li > span {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(56, 189, 248, 0.16);
  color: #7dd3fc;
  font-size: 13px;
  font-weight: 900;
}

.xle-rule-list li p {
  color: var(--xle-soft);
  font-size: 14px;
  line-height: 1.5;
}

/* Guías: columna de temas + tarjetas */
.xle-guides-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  align-items: start;
  gap: 16px;
}

.xle-topics {
  position: sticky;
  top: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 12px 10px;
}

.xle-topic {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 9px 11px;
  border: 0;
  border-radius: 10px;
  background: none;
  text-align: left;
}

.xle-topic:hover {
  background: rgba(56, 189, 248, 0.07);
}

.xle-topic.is-on {
  background: rgba(56, 189, 248, 0.14);
  box-shadow: inset 3px 0 0 var(--xle-cyan);
  color: #7dd3fc !important;
}

.xle-topic-row {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  font-size: 14px;
  font-weight: 700;
}

.xle-topic-label {
  flex: 1;
  min-width: 0;
}

.xle-topic small {
  color: var(--xle-mute);
  font-size: 12px;
  font-weight: 600;
}

.xle-guides-main {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}

.xle-theme-head {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.xle-theme-head strong {
  font-size: 20px;
  font-weight: 900;
}

.xle-theme-head .xle-btn {
  margin-left: auto;
}

.xle-theme-section {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.xle-theme-section h3 {
  color: #9fb3da;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.xle-guides {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.xle-guide {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--xle-line);
  border-radius: 14px;
  background: var(--xle-card);
  transition: border-color 0.15s ease;
}

.xle-guide:hover {
  border-color: var(--xle-cyan);
}

.xle-guide strong {
  font-size: 15px;
  font-weight: 800;
}

.xle-guide-desc {
  display: -webkit-box;
  overflow: hidden;
  color: var(--xle-mute);
  font-size: 12.5px;
  line-height: 1.4;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.xle-guide-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: auto;
  padding-top: 6px;
}

.xle-guide.is-read strong {
  color: #b9c6e4;
}

/* Libros */
.xle-books {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.xle-book-big {
  display: flex;
  gap: 18px;
}

.xle-book-big.is-violet {
  border-color: rgba(168, 85, 247, 0.45);
}

.xle-book-big img {
  flex-shrink: 0;
  width: 150px;
  height: 200px;
  border: 1px solid #2a3a66;
  border-radius: 10px;
  object-fit: cover;
}

.xle-book-big-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  min-width: 0;
}

.xle-book-big-text strong {
  font-size: 22px;
  font-weight: 900;
}

.xle-book-big-text span {
  color: var(--xle-soft);
  font-size: 14px;
  line-height: 1.45;
}

.xle-book-big-text small {
  color: var(--xle-mute);
  font-size: 12px;
}

.xle-book-big-text .xle-btn {
  margin-top: auto;
}

/* Ayuda */
.xle-help {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.xle-help-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  text-align: left;
  transition: border-color 0.15s ease;
}

.xle-help-card:hover {
  border-color: var(--xle-cyan);
}

.xle-help-card strong {
  font-size: 17px;
  font-weight: 900;
}

.xle-help-card > span:not(.xle-btn):not(.xle-help-icon) {
  color: var(--xle-mute);
  font-size: 13px;
  line-height: 1.4;
}

.xle-help-card .xle-btn {
  margin-top: auto;
}

.xle-help-icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(56, 189, 248, 0.6);
  border-radius: 50%;
  background: radial-gradient(circle, #0c2d4a, #081627);
  font-size: 20px;
}

.xle-help-icon.is-red {
  border-color: rgba(255, 77, 109, 0.6);
  background: radial-gradient(circle, #4a0c1c, #1a0710);
  color: var(--xle-red);
}

.xle-help-icon.is-green {
  border-color: rgba(61, 255, 122, 0.6);
  background: radial-gradient(circle, #0c3a22, #071a10);
}

/* Migas */
.xle-crumbs {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--xle-mute);
  font-size: 13px;
}

.xle-crumbs a:hover {
  color: var(--xle-text);
}

.xle-crumbs b {
  color: var(--xle-soft);
  font-weight: 700;
}

.xle-kicker {
  color: var(--xle-cyan);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* Página de una guía */
.xle-guide-hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  padding: 22px 24px;
}

.xle-guide-hero-text {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}

.xle-guide-hero h1 {
  font-size: 30px;
  font-weight: 900;
}

.xle-guide-hero p {
  max-width: 820px;
  color: var(--xle-soft);
  font-size: 15px;
  line-height: 1.5;
}

.xle-guide-hero .xle-row-buttons {
  margin-top: 6px;
}

.xle-guide-meta {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex-shrink: 0;
  max-width: 340px;
  color: var(--xle-mute);
  font-size: 12px;
  overflow-wrap: anywhere;
}

.xle-guide-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  align-items: start;
  gap: 16px;
}

.xle-guide-article {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}

.xle-guide-article h2 {
  margin-bottom: 12px;
  font-size: 18px;
  font-weight: 900;
}

.xle-info-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.xle-info {
  padding: 12px 14px;
  border: 1px solid var(--xle-line-soft);
  border-radius: 12px;
  background: rgba(7, 20, 49, 0.7);
}

.xle-info h3 {
  margin-bottom: 4px;
  color: #7dd3fc;
  font-size: 14px;
  font-weight: 800;
}

.xle-info p {
  color: var(--xle-soft);
  font-size: 14px;
  line-height: 1.5;
}

.xle-examples {
  display: grid;
  gap: 8px;
}

.xle-example {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: var(--xle-soft);
  font-size: 14px;
  line-height: 1.45;
}

.xle-example > span {
  color: var(--xle-neon);
  font-weight: 900;
}

.xle-shots {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.xle-shot {
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--xle-line-soft);
  border-radius: 12px;
  background: rgba(7, 20, 49, 0.7);
}

.xle-shot div {
  display: grid;
  place-items: center;
  height: 70px;
  background: #0b1836;
  font-size: 22px;
}

.xle-shot figcaption {
  padding: 8px 10px;
  color: var(--xle-mute);
  font-size: 12px;
}

.xle-faqs {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.xle-faqs details {
  border: 1px solid var(--xle-line-soft);
  border-radius: 12px;
  background: rgba(7, 20, 49, 0.7);
}

.xle-faqs summary {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
}

.xle-faqs summary::-webkit-details-marker {
  display: none;
}

.xle-faqs details p {
  padding: 0 14px 12px 42px;
  color: var(--xle-soft);
  font-size: 14px;
  line-height: 1.5;
}

.xle-pager {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.xle-pager-link {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 16px;
  transition: border-color 0.15s ease;
}

.xle-pager-link:hover {
  border-color: var(--xle-cyan);
}

.xle-pager-link.is-next {
  align-items: flex-end;
  text-align: right;
}

.xle-pager-link small {
  color: var(--xle-cyan);
  font-size: 12px;
  font-weight: 800;
}

.xle-pager-link strong {
  font-size: 15px;
}

.xle-guide-aside {
  position: sticky;
  top: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.xle-next-step {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  border-color: rgba(61, 255, 122, 0.35);
}

.xle-next-step strong {
  font-size: 16px;
}

.xle-next-step p {
  color: var(--xle-mute);
  font-size: 13px;
}

.xle-next-step .xle-btn {
  white-space: normal;
  text-align: left;
}

.xle-links {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px;
}

.xle-links a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 9px 10px;
  border-radius: 9px;
  color: var(--xle-soft);
  font-size: 13px;
  font-weight: 600;
}

.xle-links a:hover {
  background: rgba(56, 189, 248, 0.1);
  color: var(--xle-text);
}

/* Página de un libro */
.xle-book-hero {
  display: flex;
  align-items: center;
  gap: 20px;
}

.xle-book-cover {
  flex-shrink: 0;
  width: 110px;
  height: 140px;
  border: 1px solid #2a3a66;
  border-radius: 10px;
  object-fit: cover;
}

.xle-book-hero-text {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}

.xle-book-hero h1 {
  font-size: 30px;
  font-weight: 900;
}

.xle-book-hero p {
  color: var(--xle-soft);
}

.xle-book-layout {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  align-items: start;
  gap: 16px;
}

.xle-book-toc {
  position: sticky;
  top: 0;
  max-height: calc(100vh - 60px);
  overflow-y: auto;
  padding: 12px 10px;
}

.xle-book-toc ul {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.xle-book-toc button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  width: 100%;
  padding: 8px 10px;
  border: 0;
  border-radius: 9px;
  background: none;
  color: var(--xle-soft) !important;
  font-size: 13px;
  text-align: left;
}

.xle-book-toc button:hover {
  background: rgba(56, 189, 248, 0.07);
}

.xle-book-toc button.is-on {
  background: rgba(56, 189, 248, 0.14);
  box-shadow: inset 3px 0 0 var(--xle-cyan);
  color: #7dd3fc !important;
}

.xle-book-toc small {
  flex-shrink: 0;
  color: var(--xle-mute);
  font-size: 11px;
}

.xle-book-content {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}

.xle-book-article h2,
.xle-book-article h3 {
  font-size: 20px;
  font-weight: 900;
}

.xle-book-article-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.xle-book-article-head span {
  flex-shrink: 0;
  color: var(--xle-mute);
  font-size: 12px;
}

.xle-book-blocks {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 12px;
}

.xle-book-blocks p {
  color: var(--xle-soft);
  font-size: 15px;
  line-height: 1.6;
}

.xle-book-li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.xle-book-li > span {
  flex-shrink: 0;
  width: 6px;
  height: 6px;
  margin-top: 9px;
  border-radius: 50%;
  background: var(--xle-cyan);
}

.xle-book-figure {
  margin: 0;
  overflow: hidden;
  border: 1px solid #2a3a66;
  border-radius: 12px;
  background: #081327;
}

.xle-book-figure img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
}

.xle-book-table {
  overflow-x: auto;
  border: 1px solid #2a3a66;
  border-radius: 12px;
  background: #081327;
}

.xle-book-table table {
  min-width: 100%;
  border-collapse: collapse;
  color: var(--xle-soft);
  font-size: 13px;
}

.xle-book-table td {
  padding: 8px 12px;
  border-bottom: 1px solid #2a3a66;
  vertical-align: top;
}

.xle-notfound {
  display: flex;
  flex-direction: column;
  gap: 14px;
  color: var(--xle-soft);
}

/* Pantallas medianas */
@media (max-width: 1280px) {
  .xle-tiles {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .xle-guides {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .xle-guide-layout {
    grid-template-columns: minmax(0, 1fr) 280px;
  }
}

@media (max-width: 1100px) {
  .xle-head {
    flex-wrap: wrap;
  }

  .xle-search {
    flex: 1 1 100%;
    order: 3;
  }

  .xle-steps {
    grid-template-columns: 1fr 1fr;
  }

  .xle-steps > :first-child {
    grid-column: 1 / -1;
  }

  .xle-tiles {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .xle-bottom,
  .xle-help {
    grid-template-columns: 1fr 1fr;
  }

  .xle-guides-layout {
    grid-template-columns: 240px minmax(0, 1fr);
  }

  .xle-guide-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .xle-guide-aside {
    position: static;
  }

  .xle-guide-hero {
    flex-direction: column;
    align-items: flex-start;
  }

  .xle-guide-meta {
    max-width: none;
  }
}

/* Teléfono y tableta en vertical (el menú lateral se esconde, queda la barra de abajo). */
@media (max-width: 1024px) and (orientation: portrait) {
  .xle-root .xle-main {
    padding: 14px 14px 130px;
  }

  .xle-root.is-public .xle-main {
    padding-bottom: 48px;
  }

  .xle-guides-layout,
  .xle-book-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  /* Los temas pasan a una fila deslizable arriba de las guías. */
  .xle-topics {
    position: static;
    flex-direction: row;
    gap: 8px;
    padding: 8px;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .xle-topics::-webkit-scrollbar {
    display: none;
  }

  .xle-topics .xle-side-title {
    display: none;
  }

  .xle-topic {
    flex: 0 0 auto;
    min-width: 150px;
    border: 1px solid var(--xle-line-soft);
  }

  .xle-topic-label {
    white-space: nowrap;
  }

  .xle-book-toc {
    position: static;
    max-height: 260px;
  }
}

@media (max-width: 760px) {
  .xle-head h1 {
    font-size: 26px;
  }

  .xle-ico {
    width: 44px;
    height: 44px;
    font-size: 21px;
  }

  .xle-progress {
    flex-wrap: wrap;
    gap: 8px 12px;
  }

  .xle-bar {
    flex: 1 1 100%;
    order: 3;
  }

  .xle-steps,
  .xle-bottom,
  .xle-help,
  .xle-videos,
  .xle-books,
  .xle-guides,
  .xle-rule-list,
  .xle-info-grid,
  .xle-shots,
  .xle-pager {
    grid-template-columns: minmax(0, 1fr);
  }

  .xle-tiles {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .xle-tile-new {
    position: static;
    order: 5;
  }

  .xle-book-big {
    flex-direction: column;
  }

  .xle-book-big img {
    width: 100%;
    height: 180px;
  }

  .xle-guide-hero h1,
  .xle-book-hero h1 {
    font-size: 24px;
  }

  .xle-book-hero {
    flex-direction: column;
    align-items: flex-start;
  }

  .xle-pager-link.is-next {
    align-items: flex-start;
    text-align: left;
  }

  .xle-tab {
    padding: 10px 12px;
    font-size: 13px;
  }
}

/* Teléfono: sin el alto fijo largo de la app; la página mide lo que mide Aprender. */
body.xima-mobile-phone.xle-page-active .xima-mobile-scroll-page {
  min-height: 100dvh !important;
}

body.xima-mobile-phone.xle-page-active .xima-mobile-scroll-main {
  min-height: 0 !important;
  padding-bottom: calc(104px + env(safe-area-inset-bottom)) !important;
}

body.xima-mobile-phone.xle-page-active .xima-mobile-scroll-main::after {
  display: none;
}

@media (max-width: 1024px) and (orientation: portrait) {
  body.xle-page-active .xle-root .xle-main {
    padding-bottom: 24px;
  }
}

/* Abajo: 2 libros + TikTok + YouTube en español + YouTube en inglés (5 tarjetas). */
.xle-bottom {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
}

.xle-bottom .xle-book-card,
.xle-bottom .xle-yt-card {
  align-items: flex-start;
  gap: 10px;
  padding: 12px;
}

.xle-bottom .xle-book-card img {
  width: 48px;
  height: 64px;
}

.xle-bottom .xle-yt-icon {
  width: 44px;
  height: 44px;
  font-size: 17px;
}

.xle-bottom .xle-book-card-text strong {
  font-size: 14px;
}

.xle-bottom .xle-book-card-text > span:not(.xle-btn) {
  display: -webkit-box;
  overflow: hidden;
  font-size: 12px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.xle-yt-card.is-tiktok {
  border-color: rgba(37, 244, 238, 0.4);
}

.xle-yt-card.is-tiktok .xle-yt-icon,
.xle-help-icon.is-tiktok {
  border-color: rgba(37, 244, 238, 0.7);
  background: radial-gradient(circle, #1a1a22, #050507);
  box-shadow: -2px 0 0 rgba(37, 244, 238, 0.55), 2px 0 0 rgba(254, 44, 85, 0.55);
  color: #fff;
}

.xle-btn.is-tiktok {
  border-color: rgba(37, 244, 238, 0.5);
  background: rgba(37, 244, 238, 0.08);
  color: #7ff7f3 !important;
}

.xle-help-icon.is-red {
  color: var(--xle-red);
}

@media (max-width: 1280px) {
  .xle-bottom {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 1100px) {
  .xle-bottom {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .xle-bottom {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Guías reescritas (2026-10-18): cada apartado es una tarjeta con texto, listas, tablas y diagramas. */
.xle-prose h2 {
  color: var(--xle-text);
}
.xle-root .xle-prose .xle-prose-p {
  margin: 0 0 12px;
  color: var(--xle-soft);
  font-size: 15px;
  line-height: 1.65;
}
.xle-root .xle-prose .xle-prose-p:last-child {
  margin-bottom: 0;
}
.xle-root .xle-prose .xle-defs dd,
.xle-root .xle-prose dl {
  margin-left: 0;
}
.xle-prose-list {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin: 4px 0 12px;
  padding: 0;
  list-style: none;
}
.xle-prose-list li {
  position: relative;
  padding-left: 22px;
  color: var(--xle-soft);
  font-size: 15px;
  line-height: 1.55;
}
.xle-prose-list li::before {
  content: "";
  position: absolute;
  top: 9px;
  left: 4px;
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: var(--xle-neon);
}
.xle-defs {
  display: grid;
  gap: 8px;
  margin: 4px 0 12px;
}
.xle-defs > div {
  padding: 10px 12px;
  border: 1px solid var(--xle-line-soft);
  border-radius: 10px;
  background: rgba(7, 20, 49, 0.7);
}
.xle-defs dt {
  margin-bottom: 3px;
  color: #7dd3fc;
  font-size: 14px;
  font-weight: 800;
}
.xle-defs dd {
  margin: 0;
  color: var(--xle-soft);
  font-size: 14px;
  line-height: 1.5;
}
.xle-table-wrap {
  margin: 4px 0 12px;
  overflow-x: auto;
  border: 1px solid var(--xle-line-soft);
  border-radius: 10px;
}
.xle-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}
.xle-table th,
.xle-table td {
  padding: 9px 12px;
  border-bottom: 1px solid var(--xle-line-soft);
  color: var(--xle-soft);
  text-align: left;
  vertical-align: top;
  line-height: 1.45;
}
.xle-table thead th {
  background: rgba(7, 20, 49, 0.9);
  color: var(--xle-gold);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.xle-table tbody th {
  color: var(--xle-text);
  font-weight: 800;
  white-space: nowrap;
}
.xle-table tbody tr:last-child th,
.xle-table tbody tr:last-child td {
  border-bottom: 0;
}
.xle-figure {
  margin: 14px 0 0;
}
.xle-figure img {
  display: block;
  width: 100%;
  max-width: 640px;
  height: auto;
  margin: 0 auto;
  border-radius: 12px;
  background: #061029;
}
.xle-figure figcaption {
  margin-top: 8px;
  color: var(--xle-mute);
  font-size: 13px;
  text-align: center;
}
.xle-video-frame {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 12px;
  background: #000 center / cover no-repeat;
}
.xle-video-frame iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.xle-video-thumb span {
  position: absolute;
  top: 50%;
  left: 50%;
  display: grid;
  place-items: center;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: rgba(255, 0, 51, 0.92);
  color: #fff;
  font-size: 28px;
  transform: translate(-50%, -50%);
}
.xle-facts dl {
  display: grid;
  gap: 8px;
  margin: 8px 0 0;
}
.xle-facts dt {
  color: var(--xle-mute);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.xle-facts dd {
  margin: 1px 0 0;
  color: var(--xle-text);
  font-size: 14px;
  font-weight: 700;
}
.xle-links-inline {
  display: grid;
  gap: 8px;
  margin-top: 6px;
}
.xle-links-inline a {
  border: 1px solid var(--xle-line-soft);
  background: rgba(7, 20, 49, 0.7);
}
.xle-links-inline a strong {
  display: block;
  color: var(--xle-text);
  font-size: 14px;
}
.xle-links-inline a small {
  display: block;
  margin-top: 2px;
  color: var(--xle-mute);
  font-size: 12px;
  font-weight: 500;
}
.xle-guide-meta a {
  color: var(--xle-cyan) !important;
  font-weight: 700;
}
@media (max-width: 640px) {
  .xle-prose-p,
  .xle-prose-list li {
    font-size: 14px;
  }
  .xle-table th,
  .xle-table td {
    padding: 8px 9px;
    font-size: 13px;
  }
  .xle-table tbody th {
    white-space: normal;
  }
}

/* Tutorial guiado dentro del paso 3 (Practica). */
.xle-tutorial {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  padding: 12px 14px;
  border: 1px solid rgba(245, 181, 49, 0.55);
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(245, 181, 49, 0.16), rgba(245, 181, 49, 0.04));
  box-shadow: 0 0 18px rgba(245, 181, 49, 0.12);
}

.xle-tutorial-badge {
  color: var(--xle-gold);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.xle-step .xle-tutorial p {
  color: #e7dcc0;
}

.xle-tutorial-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.xle-btn.is-gold {
  border: 0;
  background: linear-gradient(180deg, #ffd166, #f5b531);
  color: #1a1200 !important;
}

.xle-lang-links {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
}
