/* ============================================================
   MELU — Estilos compartidos de Landings de Oposición y Blog
   Diseño profesional, cálido y dinámico (no robótico). Reutiliza
   la identidad de MELU (azul/cian + acento ámbar) con dark mode.
   Usado por: /html/oposiciones/*.html y /html/blog/*.html
   Prefijo l- para no colisionar con landing.css (legacy).
   ============================================================ */

:root {
  --l-text: #0f172a;
  --l-muted: #64748b;
  --l-card: #ffffff;
  --l-bg: #f8fafc;
  --l-bg2: #eef4ff;
  --l-border: #e2e8f0;
  --l-primary: #0c6dff;
  --l-primary-2: #00a6fb;
  --l-accent: #f59e0b;
  --l-accent-2: #ef4444;
  --l-success: #16a34a;
  --l-radius: 16px;
  --l-shadow: 0 8px 28px rgba(2, 6, 23, 0.06);
  --l-shadow-h: 0 16px 40px rgba(2, 6, 23, 0.1);
  --l-max: 1120px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  color: var(--l-text);
  background: var(--l-bg);
  -webkit-font-smoothing: antialiased;
  line-height: 1.55;
}
img { max-width: 100%; }
a { color: inherit; }

/* ---------- Nav ---------- */
.l-nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 28px; background: rgba(255, 255, 255, 0.9);
  border-bottom: 1px solid var(--l-border);
  position: sticky; top: 0; z-index: 100;
  backdrop-filter: blur(10px);
}
.l-nav .brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: inherit; }
.l-nav .brand img { height: 36px; border-radius: 9px; }
.l-nav .brand span { font-weight: 800; font-size: 1.08rem; letter-spacing: -0.02em; }
.l-nav-links { display: flex; align-items: center; gap: 6px; }
.l-nav-links a.navlink { padding: 8px 12px; border-radius: 9px; text-decoration: none; font-weight: 600; font-size: 0.92rem; color: var(--l-muted); }
.l-nav-links a.navlink:hover { color: var(--l-text); background: var(--l-bg2); }

/* ---------- Botones ---------- */
.l-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 0.7rem 1.3rem; border-radius: 11px; border: 1px solid var(--l-border);
  background: #fff; color: var(--l-text); font-weight: 700; font-size: 0.94rem;
  text-decoration: none; cursor: pointer; transition: transform .18s ease, box-shadow .18s ease, opacity .18s;
}
.l-btn:hover { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(0, 0, 0, 0.08); }
.l-btn.primary { background: linear-gradient(135deg, var(--l-primary), var(--l-primary-2)); color: #fff; border: none; box-shadow: 0 6px 18px rgba(12, 109, 255, 0.32); }
.l-btn.accent { background: linear-gradient(135deg, var(--l-accent), var(--l-accent-2)); color: #fff; border: none; box-shadow: 0 6px 18px rgba(245, 158, 11, 0.35); }
.l-btn.ghost { background: transparent; }
.l-btn.lg { padding: 0.95rem 1.8rem; font-size: 1.02rem; }

/* ---------- Layout ---------- */
.l-section { max-width: var(--l-max); margin: 0 auto; padding: 64px 22px; }
.l-section.tight { padding: 44px 22px; }
.l-eyebrow { display: inline-block; font-size: 0.8rem; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--l-primary); margin-bottom: 10px; }
.l-h2 { font-size: 2rem; font-weight: 800; letter-spacing: -0.02em; margin: 0 0 12px; line-height: 1.18; }
.l-sub { color: var(--l-muted); font-size: 1.05rem; max-width: 680px; margin: 0 0 36px; }
.l-center { text-align: center; }
.l-center .l-sub { margin-left: auto; margin-right: auto; }

/* ---------- Hero ---------- */
.l-hero { position: relative; overflow: hidden; background: linear-gradient(180deg, var(--l-bg2) 0%, var(--l-bg) 100%); }
.l-hero::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle at 80% -10%, rgba(12, 109, 255, 0.12), transparent 45%);
  pointer-events: none;
}
.l-hero-inner { max-width: var(--l-max); margin: 0 auto; padding: 56px 22px 40px; position: relative; }
.l-badge { display: inline-flex; align-items: center; gap: 7px; background: #fff; border: 1px solid var(--l-border); color: var(--l-primary); padding: 6px 14px; border-radius: 999px; font-size: 0.82rem; font-weight: 700; box-shadow: var(--l-shadow); }
.l-badge.live::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--l-success); box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.5); animation: lpulse 2s infinite; }
@keyframes lpulse { 0% { box-shadow: 0 0 0 0 rgba(22,163,74,.5);} 70% { box-shadow: 0 0 0 8px rgba(22,163,74,0);} 100%{ box-shadow:0 0 0 0 rgba(22,163,74,0);} }
.l-hero h1 { font-size: 2.9rem; font-weight: 800; letter-spacing: -0.03em; line-height: 1.1; margin: 18px 0 14px; max-width: 880px; }
.l-hero h1 .grad { background: linear-gradient(135deg, var(--l-primary), var(--l-primary-2)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.l-hero .lead { font-size: 1.18rem; color: var(--l-muted); max-width: 660px; margin: 0 0 26px; }
.l-hero .cta-row { display: flex; gap: 12px; flex-wrap: wrap; }
.l-hero-note { margin-top: 14px; font-size: 0.86rem; color: var(--l-muted); }

/* ---------- Stat strip (datos clave / datos vivos) ---------- */
.l-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px; margin-top: 38px; }
.l-stat { background: var(--l-card); border: 1px solid var(--l-border); border-radius: 14px; padding: 18px 16px; text-align: center; box-shadow: var(--l-shadow); }
.l-stat .num { font-size: 1.9rem; font-weight: 800; color: var(--l-primary); line-height: 1; letter-spacing: -0.02em; }
.l-stat .lbl { font-size: 0.82rem; color: var(--l-muted); margin-top: 6px; }

/* ---------- Cards / features ---------- */
.l-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 20px; }
.l-card { background: var(--l-card); border: 1px solid var(--l-border); border-radius: var(--l-radius); padding: 26px 24px; box-shadow: var(--l-shadow); transition: transform .25s ease, box-shadow .25s ease; }
.l-card:hover { transform: translateY(-4px); box-shadow: var(--l-shadow-h); }
.l-card .ico { font-size: 2rem; margin-bottom: 10px; }
.l-card h3 { margin: 0 0 8px; font-size: 1.12rem; font-weight: 700; }
.l-card p { margin: 0; color: var(--l-muted); font-size: 0.94rem; }

/* ---------- Proceso (timeline de pasos) ---------- */
.l-steps { display: grid; gap: 16px; }
.l-step { display: flex; gap: 16px; align-items: flex-start; background: var(--l-card); border: 1px solid var(--l-border); border-radius: 14px; padding: 20px 22px; box-shadow: var(--l-shadow); }
.l-step .n { flex-shrink: 0; width: 40px; height: 40px; border-radius: 12px; background: linear-gradient(135deg, var(--l-primary), var(--l-primary-2)); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 800; }
.l-step h4 { margin: 2px 0 5px; font-size: 1.05rem; font-weight: 700; }
.l-step p { margin: 0; color: var(--l-muted); font-size: 0.93rem; }

/* ---------- FSRS / destacado (banda azul) ---------- */
.l-feature-band { background: linear-gradient(135deg, #0b3a8f 0%, #0c6dff 100%); color: #fff; border-radius: 22px; padding: 44px 36px; display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 30px; align-items: center; }
.l-feature-band .l-eyebrow { color: #bfdbfe; }
.l-feature-band h2 { color: #fff; font-size: 1.8rem; font-weight: 800; margin: 0 0 12px; letter-spacing: -0.02em; }
.l-feature-band p { color: rgba(255,255,255,0.9); margin: 0 0 16px; }
.l-feature-band ul { margin: 0; padding-left: 18px; color: rgba(255,255,255,0.92); }
.l-feature-band li { margin-bottom: 8px; }
.l-retcurve { background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.18); border-radius: 16px; padding: 22px; }
.l-retcurve svg { width: 100%; height: auto; display: block; }
.l-retcurve .cap { font-size: 0.82rem; color: rgba(255,255,255,0.8); margin-top: 10px; text-align: center; }

/* ---------- Temario (acordeón) ---------- */
.l-acc { max-width: 860px; margin: 0 auto; }
.l-acc details { background: var(--l-card); border: 1px solid var(--l-border); border-radius: 12px; margin-bottom: 10px; overflow: hidden; }
.l-acc summary { padding: 16px 20px; font-weight: 700; cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.l-acc summary::-webkit-details-marker { display: none; }
.l-acc summary .tag { font-size: 0.74rem; font-weight: 700; color: var(--l-primary); background: var(--l-bg2); padding: 3px 9px; border-radius: 999px; }
.l-acc summary::after { content: '+'; font-size: 1.4rem; color: var(--l-muted); margin-left: auto; transition: transform .2s; }
.l-acc details[open] summary::after { transform: rotate(45deg); }
.l-acc .body { padding: 0 20px 18px; color: var(--l-muted); font-size: 0.94rem; }
.l-acc .body ul { margin: 6px 0 0; padding-left: 20px; }
.l-acc .body li { margin-bottom: 4px; }

/* ---------- Comparativa MELU vs academia ---------- */
.l-compare { width: 100%; border-collapse: separate; border-spacing: 0; background: var(--l-card); border: 1px solid var(--l-border); border-radius: 16px; overflow: hidden; box-shadow: var(--l-shadow); }
.l-compare th, .l-compare td { padding: 14px 18px; text-align: left; border-bottom: 1px solid var(--l-border); font-size: 0.94rem; }
.l-compare thead th { background: var(--l-bg2); font-weight: 800; }
.l-compare thead th.melu { color: var(--l-primary); }
.l-compare td.melu { font-weight: 600; }
.l-compare td .yes { color: var(--l-success); font-weight: 800; }
.l-compare td .no { color: var(--l-accent-2); font-weight: 800; }
.l-compare tr:last-child td { border-bottom: none; }

/* ---------- Testimonios ---------- */
.l-quotes { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.l-quote { background: var(--l-card); border: 1px solid var(--l-border); border-radius: 16px; padding: 24px; box-shadow: var(--l-shadow); }
.l-quote p { font-size: 1rem; line-height: 1.6; margin: 0 0 16px; }
.l-quote .who { display: flex; align-items: center; gap: 12px; }
.l-quote .av { width: 42px; height: 42px; border-radius: 50%; background: linear-gradient(135deg, var(--l-primary), var(--l-primary-2)); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 800; }
.l-quote .who b { display: block; font-size: 0.92rem; }
.l-quote .who span { font-size: 0.82rem; color: var(--l-muted); }

/* ---------- FAQ ---------- */
.l-faq { max-width: 820px; margin: 0 auto; }
.l-faq details { background: var(--l-card); border: 1px solid var(--l-border); border-radius: 12px; margin-bottom: 10px; }
.l-faq summary { padding: 16px 20px; font-weight: 600; cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; }
.l-faq summary::-webkit-details-marker { display: none; }
.l-faq summary::after { content: '+'; font-size: 1.4rem; color: var(--l-muted); transition: transform .2s; }
.l-faq details[open] summary::after { transform: rotate(45deg); }
.l-faq .body { padding: 0 20px 16px; color: var(--l-muted); font-size: 0.95rem; }

/* ---------- CTA final ---------- */
.l-final { max-width: var(--l-max); margin: 0 auto 30px; padding: 0 22px; }
.l-final-box { background: linear-gradient(135deg, var(--l-primary) 0%, var(--l-primary-2) 100%); color: #fff; border-radius: 24px; padding: 54px 30px; text-align: center; }
.l-final-box h2 { color: #fff; font-size: 2rem; margin: 0 0 10px; letter-spacing: -0.02em; }
.l-final-box p { opacity: 0.94; font-size: 1.08rem; margin: 0 0 26px; }
.l-final-box .l-btn { background: #fff; color: var(--l-primary); }

/* ---------- Sticky CTA inferior (móvil sobre todo) ---------- */
.l-sticky { position: fixed; left: 0; right: 0; bottom: 0; z-index: 90; display: none; gap: 10px; padding: 10px 14px; background: rgba(255,255,255,0.95); backdrop-filter: blur(8px); border-top: 1px solid var(--l-border); }
.l-sticky .l-btn { flex: 1; justify-content: center; }

/* ---------- Footer ---------- */
.l-footer { background: var(--l-card); border-top: 1px solid var(--l-border); margin-top: 40px; }
.l-footer-inner { max-width: var(--l-max); margin: 0 auto; padding: 40px 22px; display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 28px; }
.l-footer h5 { font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--l-muted); margin: 0 0 12px; }
.l-footer a { display: block; text-decoration: none; color: var(--l-text); font-size: 0.92rem; margin-bottom: 8px; opacity: 0.85; }
.l-footer a:hover { opacity: 1; color: var(--l-primary); }
.l-footer .legal { grid-column: 1 / -1; border-top: 1px solid var(--l-border); padding-top: 18px; color: var(--l-muted); font-size: 0.84rem; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; }

/* ============================================================
   BLOG
   ============================================================ */
.blog-hero { background: linear-gradient(180deg, var(--l-bg2) 0%, var(--l-bg) 100%); }
.blog-hero-inner { max-width: var(--l-max); margin: 0 auto; padding: 50px 22px 24px; }
.blog-hero h1 { font-size: 2.4rem; font-weight: 800; letter-spacing: -0.02em; margin: 10px 0 8px; }
.blog-hero p { color: var(--l-muted); font-size: 1.08rem; max-width: 620px; margin: 0; }

.blog-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 24px; }
.post-card { background: var(--l-card); border: 1px solid var(--l-border); border-radius: var(--l-radius); overflow: hidden; box-shadow: var(--l-shadow); transition: transform .25s ease, box-shadow .25s ease; text-decoration: none; color: inherit; display: flex; flex-direction: column; }
.post-card:hover { transform: translateY(-4px); box-shadow: var(--l-shadow-h); }
.post-card .thumb { aspect-ratio: 16 / 9; background: linear-gradient(135deg, var(--l-primary), var(--l-primary-2)); display: flex; align-items: center; justify-content: center; font-size: 2.6rem; }
.post-card .pc-body { padding: 20px; flex: 1; display: flex; flex-direction: column; }
.post-card .cat { font-size: 0.74rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.05em; color: var(--l-primary); }
.post-card h3 { margin: 8px 0 8px; font-size: 1.12rem; font-weight: 700; line-height: 1.3; }
.post-card p { margin: 0 0 14px; color: var(--l-muted); font-size: 0.92rem; flex: 1; }
.post-card .meta { font-size: 0.82rem; color: var(--l-muted); }

/* Artículo (prosa) */
.article-wrap { max-width: 760px; margin: 0 auto; padding: 40px 22px 20px; }
.article-head .cat { font-size: 0.78rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.05em; color: var(--l-primary); }
.article-head h1 { font-size: 2.3rem; font-weight: 800; letter-spacing: -0.02em; line-height: 1.15; margin: 10px 0 14px; }
.article-head .meta { color: var(--l-muted); font-size: 0.9rem; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.article-cover { aspect-ratio: 16 / 7; border-radius: 18px; background: linear-gradient(135deg, var(--l-primary), var(--l-primary-2)); display: flex; align-items: center; justify-content: center; font-size: 4rem; margin: 26px 0; }
.prose { font-size: 1.08rem; line-height: 1.75; color: #1f2937; }
.prose h2 { font-size: 1.5rem; font-weight: 800; letter-spacing: -0.01em; margin: 36px 0 12px; }
.prose h3 { font-size: 1.2rem; font-weight: 700; margin: 28px 0 10px; }
.prose p { margin: 0 0 18px; }
.prose ul, .prose ol { margin: 0 0 18px; padding-left: 24px; }
.prose li { margin-bottom: 8px; }
.prose blockquote { margin: 22px 0; padding: 14px 20px; border-left: 4px solid var(--l-primary); background: var(--l-bg2); border-radius: 0 12px 12px 0; color: var(--l-text); font-style: italic; }
.prose a { color: var(--l-primary); text-decoration: underline; text-underline-offset: 2px; }
.prose .callout { background: #fffbeb; border: 1px solid #fde68a; border-radius: 12px; padding: 16px 20px; margin: 22px 0; color: #78350f; font-size: 0.98rem; }
.article-cta { background: var(--l-bg2); border: 1px solid var(--l-border); border-radius: 18px; padding: 28px; margin: 36px 0 10px; text-align: center; }
.article-cta h3 { margin: 0 0 8px; font-size: 1.3rem; }
.article-cta p { margin: 0 0 18px; color: var(--l-muted); }
.author-box { display: flex; align-items: center; gap: 14px; padding: 20px; border: 1px solid var(--l-border); border-radius: 16px; margin-top: 30px; background: var(--l-card); }
.author-box .av { width: 52px; height: 52px; border-radius: 50%; background: linear-gradient(135deg, var(--l-primary), var(--l-primary-2)); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 1.2rem; }
.author-box b { display: block; }
.author-box span { color: var(--l-muted); font-size: 0.9rem; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 860px) {
  .l-feature-band { grid-template-columns: 1fr; padding: 34px 26px; }
  .l-footer-inner { grid-template-columns: 1fr 1fr; }
  .l-hero h1 { font-size: 2.2rem; }
  .l-h2 { font-size: 1.6rem; }
  .l-nav-links .navlink { display: none; }
  .l-sticky { display: flex; }
  body { padding-bottom: 64px; }
}
@media (max-width: 520px) {
  .l-hero h1 { font-size: 1.85rem; }
  .l-footer-inner { grid-template-columns: 1fr; }
  .l-compare { font-size: 0.85rem; }
  .l-compare th, .l-compare td { padding: 10px 12px; }
}

/* ============================================================
   DARK MODE
   ============================================================ */
[data-theme="dark"] {
  --l-text: #e6edf3; --l-muted: #8b949e; --l-card: #161b22; --l-bg: #0d1117;
  --l-bg2: #161e2e; --l-border: #30363d; --l-primary: #4493f8; --l-primary-2: #58a6ff;
  --l-shadow: 0 8px 28px rgba(0,0,0,0.3); --l-shadow-h: 0 16px 40px rgba(0,0,0,0.45);
}
[data-theme="dark"] body { background: var(--l-bg); }
[data-theme="dark"] .l-nav { background: rgba(22,27,34,0.9); }
[data-theme="dark"] .l-btn { background: #21262d; border-color: #30363d; color: #e6edf3; }
[data-theme="dark"] .l-badge { background: #161b22; }
[data-theme="dark"] .prose { color: #c9d4e0; }
[data-theme="dark"] .prose blockquote { color: #e6edf3; }
[data-theme="dark"] .prose .callout { background: #2d2006; border-color: #5c4813; color: #e3b341; }
[data-theme="dark"] .l-compare thead th { background: #161e2e; }
[data-theme="dark"] .l-sticky { background: rgba(13,17,23,0.95); border-top-color: #30363d; }
