﻿/* cursos.css - Catálogo público de cursos UNAC (/SLIES/Cursos). Organización del prototipo aprobado 2026-10-02 con la
   apariencia de SION (2026-10-06): barra azul con el logo, fondo y letra de la página de inicio de SION (landingpage.css). */
:root {
    --bg: #f4f7fb; --surface: #ffffff; --surface-2: #eef3f9; --fg: #1f2d3d; --titulo: #1d3f60; --muted: #63748a; --line: #dde5ee;
    --brand: #295884; --brand-ink: #ffffff; --accent: #f2a516; --accent-ink: #2a1d00;
    --ok: #14804a; --ok-bg: #e3f5ea; --warn: #a65d00; --warn-bg: #fff1d9;
    --shadow: 0 1px 2px rgba(29,63,96,.06), 0 8px 24px rgba(29,63,96,.08);
    --hero: linear-gradient(120deg, #ffffff, #eef5ff);
    --f-display: "Segoe UI", Arial, sans-serif;
    --f-body: "Segoe UI", Arial, sans-serif;
    --r: 14px;
    color-scheme: light;
}
/* Siempre en tonos claros, aunque el equipo use modo oscuro (el oscuro se veía muy pesado). */
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--bg); color: var(--fg); font-family: var(--f-body); font-size: 15px; line-height: 1.5; }
h1, h2, h3 { font-family: var(--f-display); text-wrap: balance; margin: 0; color: var(--titulo); }
button, input, select { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
img { max-width: 100%; }
.wrap { max-width: 1180px; margin: 0 auto; padding-inline: 16px; }

header.top { position: sticky; top: 0; z-index: 20; background: var(--brand); color: var(--brand-ink); box-shadow: 0 2px 8px rgba(29,63,96,.25); }
header.top .wrap { display: flex; align-items: center; gap: 16px; height: 56px; }
.logo { display: flex; align-items: center; gap: 12px; font-weight: 600; font-size: 16px; color: var(--brand-ink); text-decoration: none; }
.logo img { width: 87px; height: auto; display: block; }
.logo span { border-left: 1px solid rgba(255,255,255,.35); padding-left: 12px; }
.top nav { margin-left: auto; display: flex; gap: 6px; }
.top nav a { color: rgba(255,255,255,.9); text-decoration: none; font-weight: 600; padding: 8px 12px; border-radius: 8px; font-size: 14px; white-space: nowrap; }
.top nav a:hover { background: rgba(255,255,255,.14); color: #fff; }
@media (max-width: 520px) { .logo span { display: none; } }
/* En celulares angostos no caben los dos enlaces en un renglón: queda el de consultar (los cursos están justo debajo). */
@media (max-width: 420px) { .top nav a[href="#cursos"] { display: none; } }
/* Botón "Descargar certificado": resalta en la barra; en pantallas chicas los textos se acortan para que quepan */
.top nav a.nav-cert { background: var(--accent); color: var(--accent-ink); }
.top nav a.nav-cert:hover { background: #ffb92e; color: var(--accent-ink); }
.t-corto { display: none; }
@media (max-width: 520px) { .top nav a .t-largo { display: none; } .top nav a .t-corto { display: inline; } }

.hero { background: var(--hero); padding-block: 36px 60px; position: relative; overflow: hidden; border-bottom: 1px solid var(--line); }
.hero .wrap { position: relative; z-index: 1; display: grid; gap: 16px; }
.hero .wrap > * { min-width: 0; }
.eyebrow { font-size: 12px; letter-spacing: .1em; text-transform: uppercase; font-weight: 700; color: var(--brand); }
.hero h1 { font-size: clamp(26px, 4vw, 40px); font-weight: 700; line-height: 1.15; max-width: 20ch; }
.hero p { margin: 0; max-width: 58ch; color: var(--muted); font-size: 17px; }
.search { display: flex; gap: 8px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 6px; max-width: 640px; box-shadow: var(--shadow); }
.search input { flex: 1; min-width: 0; border: 0; outline: 0; padding: 10px 12px; background: transparent; font-size: 16px; }
.search select { border: 0; background: var(--surface-2); border-radius: 10px; padding: 0 10px; max-width: 45%; min-width: 0; }
.stats-hero { display: flex; flex-wrap: wrap; gap: 22px; color: var(--muted); font-size: 14px; }
.stats-hero strong { display: block; color: var(--titulo); font-family: var(--f-display); font-size: 24px; }

.chips-bar { margin-top: -26px; position: relative; z-index: 2; }
.chips { display: flex; gap: 8px; overflow-x: auto; padding: 10px; background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); scrollbar-width: thin; }
.chip { flex: none; border: 1px solid var(--line); background: var(--surface); border-radius: 99px; padding: 8px 14px; font-weight: 600; font-size: 14px; cursor: pointer; display: flex; gap: 6px; align-items: center; }
.chip small { color: var(--muted); font-weight: 600; }
.chip[aria-pressed="true"] { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.chip[aria-pressed="true"] small { color: inherit; opacity: .7; }
.filters { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 18px; }
.seg { display: inline-flex; background: var(--surface-2); border-radius: 10px; padding: 3px; }
.seg button { border: 0; background: transparent; padding: 6px 12px; border-radius: 8px; font-weight: 600; font-size: 13px; cursor: pointer; color: var(--muted); }
.seg button[aria-pressed="true"] { background: var(--surface); color: var(--fg); box-shadow: var(--shadow); }
.filters .count { margin-left: auto; color: var(--muted); font-size: 14px; }

main { padding-block: 8px 64px; min-height: 40vh; }
.cat { margin-top: 34px; }
.cat-head { display: flex; align-items: baseline; gap: 12px; margin-bottom: 14px; }
.cat-head h2 { font-size: 22px; }
.cat-head span { color: var(--muted); font-size: 14px; }
.cat-head button { margin-left: auto; border: 0; background: none; color: var(--brand); font-weight: 700; cursor: pointer; }
.row { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(250px, 1fr); gap: 16px; overflow-x: auto; padding-bottom: 8px; scroll-snap-type: x mandatory; }
.row.grid { grid-auto-flow: row; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
@media (min-width: 1000px) { .row { grid-auto-columns: calc((100% - 48px) / 4); } }
.card { scroll-snap-align: start; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; cursor: pointer; display: flex; flex-direction: column; transition: transform .18s ease, box-shadow .18s ease; text-align: left; padding: 0; }
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.cover { aspect-ratio: 16 / 9; max-width: 100%; position: relative; display: flex; align-items: flex-end; padding: 12px; color: #fff; background-size: cover; background-position: center; }
.cover .big { position: absolute; right: 10px; top: 4px; font-family: var(--f-display); font-weight: 700; font-size: 64px; opacity: .18; line-height: 1; }
.badge { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 700; border-radius: 99px; padding: 3px 9px; background: rgba(0,0,0,.5); color: #fff; backdrop-filter: blur(4px); }
.card .body { padding: 14px; display: grid; gap: 8px; flex: 1; align-content: start; }
.card h3 { font-size: 16px; font-weight: 700; line-height: 1.25; }
.meta { display: flex; flex-wrap: wrap; gap: 6px 12px; color: var(--muted); font-size: 13px; }
.card .foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; border-top: 1px solid var(--line); padding: 10px 14px; margin-top: auto; }
.price { font-family: var(--f-display); font-weight: 700; font-size: 17px; font-variant-numeric: tabular-nums; }
.price small { font-family: var(--f-body); font-weight: 500; font-size: 12px; color: var(--muted); }
.price.free { color: var(--ok); }
.closing { font-size: 12px; font-weight: 700; color: var(--warn); background: var(--warn-bg); border-radius: 6px; padding: 2px 7px; white-space: nowrap; }
.note { font-size: 13px; color: var(--muted); }
.hint { font-size: 14px; background: var(--surface-2); border-radius: 10px; padding: 12px 14px; color: var(--muted); }

.scrim { position: fixed; inset: 0; background: rgba(8,10,25,.55); z-index: 40; }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(560px, 100%); background: var(--surface); z-index: 41; overflow-y: auto; box-shadow: -10px 0 40px rgba(0,0,0,.25); display: flex; flex-direction: column; }
.drawer .cover { aspect-ratio: auto; height: 220px; }
.drawer .x { position: absolute; top: 12px; right: 12px; width: 36px; height: 36px; border-radius: 50%; border: 0; background: rgba(0,0,0,.5); color: #fff; font-size: 20px; cursor: pointer; }
.d-body { padding: 20px; display: grid; gap: 16px; }
.facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.fact { background: var(--surface-2); border-radius: 10px; padding: 10px 12px; }
.fact small { display: block; color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .06em; font-weight: 700; }
.fact span { font-weight: 600; }
@media (max-width: 520px) { .facts { grid-template-columns: 1fr; } }
.btn { display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: 12px; padding: 13px 18px; font-weight: 700; cursor: pointer; font-size: 15px; text-decoration: none; }
.btn.primary { background: var(--brand); color: var(--brand-ink); }
.btn.ghost { background: var(--surface-2); color: var(--fg); }
.d-actions { position: sticky; bottom: 0; background: var(--surface); border-top: 1px solid var(--line); padding: 14px 20px; display: flex; gap: 10px; margin-top: auto; }
.d-actions .btn { flex: 1; }
.pie { border-top: 1px solid var(--line); padding-block: 20px; color: var(--muted); font-size: 13px; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* ---------- Asistente de inscripción (inscripcion.js) ---------- */
.ins-head { display: flex; align-items: flex-start; gap: 12px; padding: 18px 20px 10px; border-bottom: 1px solid var(--line); background: var(--surface); position: sticky; top: 0; z-index: 2; }
.ins-head small { color: var(--brand); font-weight: 700; text-transform: uppercase; letter-spacing: .08em; font-size: 11px; }
.ins-head h2 { font-size: 20px; margin-top: 2px; }
.x-plano { margin-left: auto; border: 0; background: var(--surface-2); width: 36px; height: 36px; border-radius: 50%; font-size: 20px; cursor: pointer; flex: none; }
.pasos { display: flex; gap: 5px; padding: 10px 20px 0; }
.pasos i { flex: 1; height: 5px; border-radius: 9px; background: var(--line); }
.pasos i.on { background: var(--brand); }
.d-body h3 { font-size: 17px; margin-top: 4px; }
.d-body p { margin: 0; }
.d-body label { display: grid; gap: 5px; font-weight: 600; font-size: 14px; }
.d-body label small { font-weight: 500; color: var(--muted); }
.d-body input:not([type=checkbox]):not([type=radio]), .d-body select { border: 1.5px solid var(--line); border-radius: 10px; padding: 11px 12px; background: var(--surface); width: 100%; min-width: 0; font-size: 15px; }
.d-body input:focus, .d-body select:focus { border-color: var(--brand); outline: 0; }
.dos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 520px) { .dos { grid-template-columns: 1fr; } }
.tel { display: flex; gap: 6px; }
.tel select { width: 150px !important; flex: none; }
.trampa { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; opacity: 0; }
.alerta { background: #fde6e7; color: #b4232c; border-radius: 10px; padding: 11px 13px; font-weight: 600; font-size: 14px; }
.encontrado { background: var(--ok-bg); color: var(--ok); border-radius: 10px; padding: 11px 13px; font-size: 14px; }
.nota { font-size: 13px; color: var(--muted); }
.nota-clave { font-size: 16px; line-height: 1.5; font-weight: 600; background: var(--ok-bg); color: var(--ok); border-radius: 10px; padding: 12px 14px; }
.precios { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.precios li { display: flex; justify-content: space-between; gap: 10px; background: var(--surface-2); border-radius: 10px; padding: 9px 12px; }
.precios b { font-family: var(--f-display); white-space: nowrap; }
.precios .gratis { color: var(--ok); }
.opciones { display: grid; gap: 8px; }
.opcion { display: flex !important; grid-template-columns: none; align-items: center; gap: 10px; border: 1.5px solid var(--line); border-radius: 12px; padding: 12px; cursor: pointer; }
.opcion:has(input:checked) { border-color: var(--brand); background: var(--surface-2); }
.opcion b { margin-left: auto; font-variant-numeric: tabular-nums; }
.casilla { display: flex !important; align-items: flex-start; gap: 8px; font-weight: 500 !important; }
.casilla input { margin-top: 3px; }
.casilla a { color: inherit; text-decoration: underline; font-weight: 700; }
.seg { display: inline-flex; background: var(--surface-2); border-radius: 10px; padding: 3px; }
.dir { border: 1.5px solid var(--line); border-radius: 14px; padding: 14px; display: grid; gap: 12px; }
.fila-dir { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-end; }
.fila-dir label { font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.fila-dir select { width: 120px !important; }
.fila-dir input { width: 80px !important; }
.fila-dir .bis { display: flex; grid-template-columns: none; align-items: center; gap: 6px; padding-bottom: 12px; text-transform: none; color: var(--fg); font-size: 14px; }
.fila-dir .sim { font-family: var(--f-display); font-weight: 800; font-size: 20px; padding-bottom: 9px; color: var(--muted); }
.comp { display: flex; gap: 8px; align-items: center; }
.comp select { width: 150px !important; flex: none; }
.comp button { border: 0; background: var(--surface-2); border-radius: 8px; width: 36px; height: 36px; cursor: pointer; flex: none; }
.agregar { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: 13px; color: var(--muted); }
.agregar button { border: 1px dashed var(--line); background: transparent; border-radius: 99px; padding: 5px 11px; font-size: 13px; font-weight: 600; cursor: pointer; color: var(--brand); }
.vista { background: var(--surface-2); border-radius: 10px; padding: 10px 12px; display: grid; gap: 2px; }
.vista b { font-family: var(--f-display); font-size: 16px; }
.vista small, .vista code { font-size: 12px; color: var(--muted); }
.sugerencias { display: grid; gap: 2px; }
.sugerencias button { text-align: left; border: 0; background: var(--surface-2); padding: 8px 10px; border-radius: 8px; cursor: pointer; font-weight: 500; }
.sugerencias button:hover { background: var(--line); }
.sugerencias em { font-size: 13px; color: var(--muted); }
.miembro { border: 1.5px solid var(--line); border-radius: 12px; padding: 12px; display: grid; gap: 10px; }
.miembro-head { display: flex; justify-content: space-between; align-items: center; }
.link { border: 0; background: none; color: #b4232c; font-weight: 600; cursor: pointer; }
.btn.ancho { width: 100%; }
.btn.pagar { background: var(--accent); color: var(--accent-ink); }
.btn.chico { padding: 7px 12px; font-size: 13px; }
.btn[disabled] { opacity: .6; cursor: progress; }
.resumen { display: grid; gap: 8px; background: var(--surface-2); border-radius: 12px; padding: 12px 14px; }
.resumen div { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; }
.resumen small { color: var(--muted); }
.resumen span { font-weight: 600; text-align: right; }
.resumen .total { border-top: 1px solid var(--line); padding-top: 8px; font-size: 16px; }
.resumen .total span { font-family: var(--f-display); font-size: 20px; }
.resultado { border-radius: 12px; padding: 14px 16px; }
.resultado.bien { background: var(--ok-bg); color: var(--ok); }
.resultado.pendiente { background: var(--warn-bg); color: var(--warn); }
.referencia { border: 2px dashed var(--brand); border-radius: 14px; padding: 16px; text-align: center; display: grid; gap: 4px; }
.referencia strong { font-family: var(--f-display); font-size: 30px; letter-spacing: .06em; font-variant-numeric: tabular-nums; }
.referencia small { color: var(--muted); }
.referencia span { font-family: var(--f-display); font-weight: 700; font-size: 18px; }
.mis { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.mis li { border: 1px solid var(--line); border-radius: 12px; padding: 12px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.mis li div { display: grid; gap: 2px; flex: 1; min-width: 180px; }
.mis small { color: var(--muted); font-size: 13px; }
.mis-titulo { margin: 24px 0 4px; }
.mis-titulo + .hint { margin: 0 0 10px; }
.estado { font-size: 12px; font-weight: 700; border-radius: 99px; padding: 3px 10px; white-space: nowrap; }
.estado.bien { background: var(--ok-bg); color: var(--ok); }
.estado.pendiente { background: var(--warn-bg); color: var(--warn); }
.estado.info { background: var(--surface-2); color: var(--brand); }