/* Hability Formación */

@font-face {
    font-family: "Plus Jakarta Sans";
    font-style: normal;
    font-weight: 400 800;
    font-display: swap;
    src: url("../fonts/plus-jakarta-sans-latin.woff2") format("woff2");
}

:root {
    --acento: #be185d;
    --acento-oscuro: #9d174d;
    --rosa-suave: #fdf2f7;
    --rosa-borde: #f1e4ea;
    --rosa-linea: #f3e6ec;
    --tinta: #1f1a24;
    --tinta-2: #3d3644;
    --texto: #4a4351;
    --apagado: #5b5563;
    --apagado-2: #6b6472;
    --gris-suave: #f4f1f3;
    --verde-suave: #ecfdf3;
    --verde: #166534;
    --radio: 26px;
    --sombra: 0 1px 2px rgb(31 26 36 / 0.04), 0 8px 24px rgb(157 23 77 / 0.06);
    --ancho: 1180px;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scroll-padding-top: 88px; }

body {
    margin: 0;
    font-family: "Plus Jakarta Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
    font-size: 1rem;
    line-height: 1.55;
    color: var(--tinta);
    background: #fff;
    -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3, p, dl, dd, ul { margin: 0; }
:focus-visible { outline: 3px solid var(--acento); outline-offset: 2px; }

.contenedor { width: 100%; max-width: var(--ancho); margin: 0 auto; padding: 0 20px; }

.lector { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.saltar { position: absolute; left: -9999px; }
.saltar:focus { left: 1rem; top: 1rem; z-index: 20; padding: .5rem 1rem; background: #fff; border-radius: 999px; }

.icono { width: 18px; height: 18px; flex: none; }

.titulo-seccion { font-size: clamp(28px, 4vw, 40px); line-height: 1.15; font-weight: 800; letter-spacing: -0.02em; }

/* Botones */
.boton {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 0 20px;
    font: inherit;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.2;
    color: #fff;
    background: var(--acento);
    border: 0;
    border-radius: 999px;
    text-decoration: none;
    cursor: pointer;
    transition: background-color .15s, color .15s;
}
.boton:hover { background: var(--acento-oscuro); }
.boton--pequeno { padding: 0 18px; }
.boton--grande { min-height: 52px; padding: 0 24px; font-size: 16px; }
.boton--oscuro { background: var(--tinta); }
.boton--oscuro:hover { background: #000; }
.boton--blanco { color: var(--tinta); background: #fff; }
.boton--blanco:hover { color: var(--acento); background: #fff; }
.boton--suave { color: var(--acento-oscuro); background: var(--rosa-suave); }
.boton--suave:hover { color: #fff; background: var(--acento); }
.botones { display: flex; flex-wrap: wrap; gap: 12px; }

/* Cabecera */
.cabecera { position: sticky; top: 0; z-index: 10; background: rgb(255 255 255 / 0.94); border-bottom: 1px solid var(--rosa-linea); backdrop-filter: blur(8px); }
.cabecera__fila { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 16px; padding-top: 14px; padding-bottom: 14px; }
.cabecera__logo { display: flex; align-items: center; font-weight: 800; text-decoration: none; }
.cabecera__logo img { height: 40px; width: auto; }
.cabecera__menu { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }
.cabecera__enlace { padding: 10px 12px; font-size: 15px; font-weight: 600; color: var(--tinta-2); text-decoration: none; border-radius: 999px; }
.cabecera__enlace:hover { color: var(--acento); }
.cabecera__menu .boton { margin-left: 4px; }

/* Portada */
.portada { padding-top: clamp(44px, 8vw, 100px); padding-bottom: clamp(32px, 5vw, 52px); }
.portada__etiqueta { margin-bottom: 18px; font-size: 14px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--acento); }
.portada__titular { max-width: 940px; font-size: clamp(38px, 7vw, 74px); line-height: 1.03; font-weight: 800; letter-spacing: -0.04em; }
.resaltado { color: var(--acento); }
.portada__pie { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 28px; margin-top: clamp(24px, 4vw, 40px); }
.portada__texto { max-width: 560px; font-size: clamp(17px, 2vw, 20px); color: var(--apagado); }
.portada__texto p + p { margin-top: 1em; }
.portada__texto strong, .portada__texto b { color: var(--tinta); }

.escaparate__fotos { display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); gap: 16px; }
.escaparate__fotos img { width: 100%; height: 280px; object-fit: cover; border-radius: 24px; }
@media (max-width: 639px) {
    .escaparate__fotos { gap: 8px; }
    .escaparate__fotos img { height: 140px; border-radius: 16px; }
}
.cifras { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); column-gap: 16px; margin-top: 32px; border-top: 1px solid var(--rosa-borde); border-bottom: 1px solid var(--rosa-borde); }
.escaparate__fotos + .cifras { margin-top: 32px; }
.cifras div { padding: 26px 4px 24px; }
.cifras dt { font-size: clamp(26px, 4vw, 34px); line-height: 1.2; font-weight: 800; letter-spacing: -0.03em; }
.cifras dd { margin-top: 2px; font-size: 15px; color: var(--apagado); }

/* Cursos */
.cursos { padding-top: clamp(56px, 8vw, 96px); }
.cursos__cabecera { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 28px; }
.cursos__subtitulo { margin-top: 6px; font-size: 16px; color: var(--apagado); }
.filtros { display: flex; flex-wrap: wrap; gap: 8px; }
.filtro { min-height: 44px; padding: 0 18px; font: inherit; font-size: 14px; font-weight: 700; color: var(--tinta-2); background: #fff; border: 1.5px solid #e7d6de; border-radius: 999px; cursor: pointer; }
.filtro:hover { border-color: var(--tinta-2); }
.filtro[aria-pressed="true"] { color: #fff; background: var(--tinta); border-color: var(--tinta); }

.rejilla-cursos { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 330px), 1fr)); gap: 22px; }

.tarjeta { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--rosa-borde); border-radius: var(--radio); overflow: hidden; box-shadow: var(--sombra); }
.tarjeta__foto { position: relative; display: block; aspect-ratio: 87 / 50; background: var(--rosa-suave); }
.tarjeta__foto img { width: 100%; height: 100%; object-fit: cover; }
.tarjeta__modalidad { position: absolute; top: 14px; left: 14px; padding: 6px 12px; font-size: 12px; font-weight: 700; color: var(--tinta); background: #fff; border-radius: 999px; }
.tarjeta__cuerpo { flex: 1; display: flex; flex-direction: column; gap: 12px; padding: 22px 24px 24px; }
.tarjeta__titulo { font-size: 21px; line-height: 1.25; font-weight: 800; letter-spacing: -0.01em; }
.tarjeta__titulo a { text-decoration: none; }
.tarjeta__titulo a:hover { color: var(--acento); }
.tarjeta__texto { font-size: 15px; color: var(--apagado); display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.tarjeta__datos { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: auto; padding-top: 14px; border-top: 1px dashed #ebdce3; font-size: 14px; color: var(--tinta-2); }
.tarjeta__datos span { display: inline-flex; align-items: center; gap: 6px; }
.tarjeta__datos .icono { width: 16px; height: 16px; }
.tarjeta__precio { font-weight: 700; }
.tarjeta__boton { min-height: 48px; margin-top: auto; }
.tarjeta__datos + .tarjeta__boton { margin-top: 4px; }

.etiquetas { display: flex; flex-wrap: wrap; gap: 8px; padding: 0; list-style: none; }
.etiqueta { padding: 4px 10px; font-size: 12px; font-weight: 700; border-radius: 999px; }
.etiqueta--gris { color: var(--tinta-2); background: var(--gris-suave); }
.etiqueta--rosa { color: var(--acento-oscuro); background: var(--rosa-suave); }
.etiqueta--verde { color: var(--verde); background: var(--verde-suave); }
.etiqueta--azul { color: #1e40af; background: #eff6ff; }
.etiqueta--ambar { color: #92400e; background: #fffbeb; }

/* Contacto */
.contacto { padding-top: clamp(56px, 8vw, 96px); padding-bottom: clamp(56px, 8vw, 96px); }
.contacto__caja { display: flex; flex-wrap: wrap; gap: clamp(28px, 4vw, 48px); padding: clamp(28px, 5vw, 56px); background: var(--rosa-suave); border-radius: 34px; }
.contacto__intro { flex: 1 1 340px; min-width: 0; display: flex; flex-direction: column; gap: 16px; }
.contacto__intro p { font-size: 17px; color: var(--apagado); }
.contacto__intro .botones { margin-top: 6px; }
.contacto__datos { flex: 1.4 1 420px; min-width: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 12px; }
.contacto__datos div { padding: 18px 20px; background: #fff; border-radius: 20px; }
.contacto__datos dt { font-size: 13px; font-weight: 600; color: var(--apagado-2); }
.contacto__datos dd { margin-top: 4px; font-size: 16px; font-weight: 700; overflow-wrap: anywhere; }

/* Ficha del curso */
.curso { padding-top: clamp(24px, 4vw, 40px); }
.curso__volver { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; font-size: 14px; font-weight: 600; color: var(--tinta-2); text-decoration: none; }
.curso__volver:hover { color: var(--acento); }
.curso__volver .icono { width: 16px; height: 16px; }
.curso__cabecera { display: flex; flex-direction: column; gap: 16px; max-width: 900px; margin-top: 12px; }
.curso__cabecera .etiqueta { padding: 6px 12px; font-size: 13px; }
.curso__titulo { font-size: clamp(30px, 5vw, 50px); line-height: 1.08; font-weight: 800; letter-spacing: -0.03em; }
.curso__foto { margin-top: clamp(24px, 4vw, 36px); }
.curso__foto img { width: 100%; aspect-ratio: 16 / 7; object-fit: cover; border-radius: 28px; }

/* En el móvil el resumen (que va primero en el HTML) queda arriba; en pantallas anchas, a la derecha. */
.curso__columnas { display: flex; flex-direction: row-reverse; flex-wrap: wrap; align-items: flex-start; gap: clamp(28px, 4vw, 48px); margin-top: clamp(28px, 4vw, 44px); }
.resumen { flex: 1 1 320px; min-width: 0; display: flex; flex-direction: column; gap: 18px; padding: 26px; background: #fff; border: 1px solid var(--rosa-borde); border-radius: var(--radio); box-shadow: 0 8px 28px rgb(157 23 77 / 0.08); }
@media (min-width: 960px) { .resumen { position: sticky; top: 96px; } }
.resumen__precio { display: flex; flex-direction: column; font-size: 15px; color: var(--apagado); }
.resumen__precio span:first-child { font-size: 14px; color: var(--apagado-2); }
.resumen__precio strong { font-size: 40px; line-height: 1.1; font-weight: 800; letter-spacing: -0.03em; color: var(--tinta); }
.resumen__datos div { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-top: 1px solid var(--rosa-linea); font-size: 15px; }
.resumen__datos dt { color: var(--apagado); }
.resumen__datos dd { font-weight: 700; text-align: right; }
.resumen__botones { display: flex; flex-direction: column; gap: 10px; }
.resumen__nota { font-size: 13px; color: var(--apagado-2); text-align: center; }

.curso__contenido { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; gap: clamp(32px, 4vw, 44px); }
.curso__contenido h2 { margin-bottom: 14px; font-size: 24px; font-weight: 800; letter-spacing: -0.01em; }
.curso__descripcion { font-size: 17px; color: var(--texto); }
.curso__descripcion > * + * { margin-top: 1em; }
.curso__descripcion ul, .curso__descripcion ol { padding-left: 1.4em; }
.curso__descripcion a { color: var(--acento); }

.caracteristicas { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 150px), 1fr)); gap: 12px; }
.caracteristicas div { padding: 18px; background: var(--rosa-suave); border-radius: 20px; }
.caracteristicas dt { font-size: 13px; font-weight: 600; color: var(--apagado-2); }
.caracteristicas dd { margin-top: 4px; font-size: 20px; font-weight: 800; letter-spacing: -0.01em; }

.desglose { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr)); column-gap: 28px; }
.desglose div { display: flex; justify-content: space-between; gap: 12px; padding: 13px 0; border-bottom: 1px solid var(--rosa-linea); font-size: 15px; }
.desglose dt { color: var(--texto); }
.desglose dd { font-weight: 700; white-space: nowrap; }

.archivos { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); gap: 12px; padding: 0; list-style: none; }
.archivo { display: flex; align-items: center; gap: 14px; height: 100%; min-height: 64px; padding: 12px 16px; color: var(--tinta); border: 1.5px solid #ebdce3; border-radius: 18px; text-decoration: none; transition: border-color .15s; }
.archivo:hover { border-color: var(--acento); }
.archivo__icono { flex: none; display: grid; place-items: center; width: 40px; height: 40px; color: var(--acento-oscuro); background: var(--rosa-suave); border-radius: 12px; }
.archivo__texto { display: flex; flex-direction: column; line-height: 1.3; }
.archivo__texto strong { font-size: 15px; }
.archivo__texto span { font-size: 13px; color: var(--apagado-2); }

.otros { margin-top: clamp(56px, 8vw, 88px); }
.otros h2 { margin-bottom: 20px; font-size: clamp(24px, 3vw, 30px); font-weight: 800; letter-spacing: -0.02em; }
.otros__rejilla { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 18px; }
.otro { display: flex; flex-direction: column; overflow: hidden; color: var(--tinta); background: #fff; border: 1px solid var(--rosa-borde); border-radius: 22px; text-decoration: none; }
.otro img { width: 100%; aspect-ratio: 87 / 40; object-fit: cover; }
.otro__texto { display: flex; flex-direction: column; gap: 4px; padding: 16px 18px 18px; }
.otro__texto span { font-size: 13px; font-weight: 600; color: var(--apagado-2); }
.otro__texto strong { font-size: 17px; line-height: 1.3; }
.otro:hover strong { color: var(--acento); }

/* Páginas genéricas */
.pagina { padding-top: clamp(40px, 6vw, 72px); padding-bottom: 24px; }
.pagina__titulo { font-size: clamp(30px, 5vw, 44px); line-height: 1.1; font-weight: 800; letter-spacing: -0.03em; }
.pagina__contenido { margin-top: 24px; color: var(--texto); }
.pagina__contenido > * + * { margin-top: 1em; }
.pagina--centrada { text-align: center; }
.pagina--centrada p { margin-top: 1rem; color: var(--apagado); }
.vacio { padding: 3rem 0; text-align: center; color: var(--apagado); }

/* Pie */
.pie { border-top: 1px solid var(--rosa-linea); }
.pie__contenido { display: flex; flex-direction: column; gap: 18px; padding-top: 32px; padding-bottom: 40px; }
.pie__fila { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.pie__logo { font-weight: 800; text-decoration: none; }
.pie__logo img { height: 44px; width: auto; }
.pie__enlaces { display: flex; flex-wrap: wrap; align-items: center; gap: 20px; padding: 0; list-style: none; font-size: 14px; font-weight: 600; }
.pie__enlaces a { color: var(--tinta-2); text-decoration: none; }
.pie__enlaces a:hover { color: var(--acento); }
.pie__legal { max-width: 900px; font-size: 12px; color: var(--apagado-2); }
.pie__legal p + p { margin-top: .8em; }
.pie__copyright { font-size: 13px; color: var(--apagado-2); }
