* { box-sizing: border-box; }

  :root {
    --paper: #F0E6D2;
    --paper-deep: #E5D8BC;
    --paper-card: rgba(255,255,255,0.34);
    --ink: #2A2420;
    --ink-soft: #5B5048;
    --sindoor: #A8362A;
    --sindoor-deep: #832920;
    --sindoor-azul: #0F4C81;
    --saffron: #B8863D;
    --olive: #5F6E4F;
    --rojo-ladrillo: #5F6E4F;
    --rule: rgba(42, 36, 32, 0.16);
  }

  body {
    margin: 0;
    color: var(--ink);
    font-family: 'Source Sans 3', sans-serif;
    line-height: 1.65;
    background-color: var(--paper);
    background-image:
      radial-gradient(ellipse at 30% 20%, rgba(184, 134, 61, 0.12), transparent 60%),
      radial-gradient(ellipse at 70% 80%, rgba(168, 54, 42, 0.08), transparent 60%);
    animation: fondoVivo 8s ease-in-out infinite alternate, moverDestellos 12s ease-in-out infinite;
  }

  @keyframes fondoVivo {
    0%   { background-color: #F0E6D2; }
    50%  { background-color: #F5EDDE; }
    100% { background-color: #EDE0CA; }
  }

  @keyframes moverDestellos {
    0% { background-position: 30% 20%, 70% 80%; }
    50% { background-position: 40% 30%, 60% 70%; }
    100% { background-position: 20% 15%, 80% 85%; }
  }

  /* ── ESTILOS ESPECÍFICOS PARA ESTA PÁGINA ── */

  .nav-bar {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--rule);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 24px;
  }
  .nav-btn {
    background: rgba(255, 255, 255, 0.8);
    color: var(--sindoor-deep);
    padding: 8px 18px;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s;
    box-shadow: 0 2px 8px rgba(42,36,32,0.05);
  }
  .nav-btn:hover {
    background: var(--paper);
    transform: translateY(-1px);
  }
  .nav-btn.home {
    font-size: 1.1rem;
    padding: 6px 14px;
  }

  .wrap-letras {
    max-width: 520px;
    margin: 0 auto;
    padding: 40px 24px 80px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 28px;
  }

  .intro-header { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 12px; }
  .modulo-badge { font-size: 0.75rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; padding: 6px 16px; border-radius: 50px; background: rgba(168, 54, 42, 0.1); color: var(--sindoor-deep); }
  .intro-header h1 { font-family: 'Fraunces', serif; font-size: clamp(2rem, 5vw, 2.6rem); font-weight: 700; color: var(--ink); margin: 0; line-height: 1.2; }
  .subtitle { color: var(--ink-soft); font-size: 1.15rem; line-height: 1.7; max-width: 440px; margin: 0; }
  .subtitle strong { color: var(--sindoor-deep); }

  .seccion-label { width: 100%; font-size: 0.85rem; color: var(--olive); text-transform: uppercase; letter-spacing: 0.1em; font-weight: 700; text-align: center; margin-top: 12px; border-bottom: 1px dashed var(--rule); padding-bottom: 8px; }

  /* Cuadrícula de Letras */
  .letras-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; width: 100%; }
  .letra-card { background: rgba(255, 255, 255, 0.5); border-radius: 12px; padding: 14px 6px; display: flex; flex-direction: column; align-items: center; gap: 4px; box-shadow: 0 4px 12px rgba(42,36,32,0.03); transition: transform 0.2s; }
  .letra-card:hover { transform: translateY(-2px); background: rgba(255, 255, 255, 0.8); }
  .letra-card .gu { font-family: 'Noto Serif Gujarati', serif; font-size: 2rem; color: var(--ink); line-height: 1; }
  .letra-card .rom { font-size: 0.9rem; color: var(--sindoor); font-weight: 700; }

  /* Cuadrícula de Vocales */
  .vocales-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; width: 100%; }
  .vocal-card { background: rgba(255, 255, 255, 0.5); border-radius: 12px; padding: 14px 6px; display: flex; flex-direction: column; align-items: center; gap: 4px; box-shadow: 0 4px 12px rgba(42,36,32,0.03); }
  .vocal-card .gu { font-family: 'Noto Serif Gujarati', serif; font-size: 1.8rem; color: var(--ink); line-height: 1; }
  .vocal-card .rom { font-size: 0.9rem; color: var(--sindoor); font-weight: 700; }
  .vocal-card .abrev { font-family: 'Noto Serif Gujarati', serif; font-size: 1.3rem; color: var(--ink-soft); margin-top: -2px; }

  .info-box { width: 100%; background: var(--paper-card); border-left: 5px solid var(--saffron); border-radius: 12px; padding: 20px 24px; font-size: 1.05rem; line-height: 1.7; color: var(--ink-soft); box-shadow: 0 6px 16px rgba(42,36,32,0.04); }
  .info-box strong { color: var(--ink); font-weight: 700; }

  /* LISTA DE LECCIONES */
  .lecciones-lista { width: 100%; display: flex; flex-direction: column; gap: 10px; background: rgba(255, 255, 255, 0.4); padding: 10px; border-radius: 16px; border: 1px solid rgba(42,36,32,0.04); }
  .leccion { display: flex; align-items: center; gap: 16px; padding: 16px 20px; background: transparent; border-radius: 12px; text-decoration: none; color: inherit; transition: all 0.2s; }
  .leccion:hover { background: rgba(255, 255, 255, 0.6); }
  .leccion.activa { background: var(--paper-card); box-shadow: 0 4px 12px rgba(184, 134, 61, 0.08); border: 1px solid rgba(184, 134, 61, 0.2); }
  .leccion.proxima { opacity: 0.6; cursor: default; }
  .leccion.proxima:hover { background: transparent; }

  .lec-num { font-family: 'Fraunces', serif; font-size: 1.4rem; font-weight: 700; color: var(--saffron); min-width: 28px; text-align: center; }
  .lec-info { flex: 1; }
  .lec-title { font-size: 1.1rem; font-weight: 600; color: var(--ink); line-height: 1.2; }
  .lec-sub { font-size: 0.95rem; color: var(--ink-soft); margin-top: 3px; line-height: 1.3; }
  .lec-gu { font-family: 'Noto Serif Gujarati', serif; font-size: 1.15rem; color: var(--saffron); margin-top: 2px; }
  .lec-status { font-size: 1.2rem; color: var(--sindoor); }
  .lec-soon { font-size: 0.75rem; color: var(--ink-soft); text-transform: uppercase; letter-spacing: 0.08em; font-weight: 700; }

  /* Botón Principal */
  .btn-empezar { display: block; width: 100%; border: none; padding: 18px; border-radius: 50px; font-weight: 600; font-size: 1.05rem; background: var(--sindoor); color: var(--paper); text-align: center; text-decoration: none; transition: all 0.2s; box-shadow: 0 4px 12px rgba(168, 54, 42, 0.2); margin-top: 10px; }
  .btn-empezar:hover { background: var(--sindoor-deep); transform: translateY(-2px); box-shadow: 0 6px 16px rgba(168, 54, 42, 0.3); }

/* Helpers — sustituyen inline styles del HTML y del JS */
.nav-phantom { opacity:0; pointer-events:none; }
.nav-oculto  { display:none; }
.error-carga { text-align:center; color:var(--ink-soft); padding:40px; }
