/* ivanvazquez.dev · estilos del dominio principal (rediseño 2026-11-24)
   Origen: diseño aprobado por Iván el 2026-11-24 (propuestas/final-2026-11-24/styles.css, estilo «Mediterráneo»),
   con la paleta definitiva «Tinta crema + verde» horneada en los tokens de :root.
   Lo usan las páginas estáticas (Vite) y las renderizadas por funciones (blog y portada),
   siempre con /styles/af.css?v=<AF_CSS_V> (netlify/functions/_shared/site-chrome.mjs).
   Todo va con prefijo .af-. Tipografías autoalojadas en /fonts (sin Google Fonts).
   Contrastes calculados (WCAG AA): ver tests/web-rediseno.test.mjs. El amarillo solo como fondo de texto oscuro. */

/* Tipografías autoalojadas (OFL, ver /fonts/LICENCIAS-OFL.txt). Sin peticiones a Google Fonts.
   Fraunces solo en SemiBold (600): los titulares usan 600 y la cursiva la sintetiza el navegador.
   Source Sans 3 en 400 y 700 con sus cursivas; el 600 se resuelve con el 700. */
@font-face { font-family: "Fraunces"; font-style: normal; font-weight: 400 700; font-display: swap; src: url("/fonts/fraunces-600.woff2") format("woff2"); }
@font-face { font-family: "Source Sans 3"; font-style: normal; font-weight: 400 500; font-display: swap; src: url("/fonts/source-sans-3-400.woff2") format("woff2"); }
@font-face { font-family: "Source Sans 3"; font-style: italic; font-weight: 400 500; font-display: swap; src: url("/fonts/source-sans-3-400-italic.woff2") format("woff2"); }
@font-face { font-family: "Source Sans 3"; font-style: normal; font-weight: 600 800; font-display: swap; src: url("/fonts/source-sans-3-700.woff2") format("woff2"); }
@font-face { font-family: "Source Sans 3"; font-style: italic; font-weight: 600 800; font-display: swap; src: url("/fonts/source-sans-3-700-italic.woff2") format("woff2"); }

/* Respaldos con las medidas de las fuentes propias: mientras llegan, el texto parte las líneas igual y
   la página no salta al cambiarlas (CLS de /formaciones en escritorio). Solo fuentes del sistema;
   ninguna descarga. size-adjust = ancho medido en Chrome con el texto de la página. */
@font-face { font-family: "Fraunces respaldo"; font-weight: 400 700; src: local("Georgia Bold"), local("Georgia-Bold"), local("Gelasio Bold"); size-adjust: 93.24%; ascent-override: 104.89%; descent-override: 27.35%; line-gap-override: 0%; }
@font-face { font-family: "Fraunces respaldo 2"; font-weight: 400 700; src: local("Times New Roman Bold"), local("TimesNewRomanPS-BoldMT"), local("Liberation Serif Bold"); size-adjust: 111.39%; ascent-override: 87.80%; descent-override: 22.89%; line-gap-override: 0%; }
@font-face { font-family: "Source Sans respaldo"; font-weight: 400 500; src: local("Arial"), local("ArialMT"), local("Liberation Sans"); size-adjust: 91.73%; ascent-override: 109.02%; descent-override: 35.54%; line-gap-override: 0%; }
@font-face { font-family: "Source Sans respaldo"; font-weight: 600 800; src: local("Arial Bold"), local("Arial-BoldMT"), local("Liberation Sans Bold"); size-adjust: 90.39%; ascent-override: 110.63%; descent-override: 36.07%; line-gap-override: 0%; }

:root {
  --bg: #f6f1e7; --surface: #fcf9f2; --sand-2: #ebe2d0; --ink: #1c1a17; --muted: #5a554c; --rule: #dfd4bf;
  --olive: #2f6140; --olive-d: #1c1a17; --sea: #26231e; --sea-d: #12100d; --night: #0c0b09;
  --sun: #f2c230; --sun-l: #fae69a; --ring: #c2b59c;
  --pastel-1: #eee9d9; --pastel-2: #e3eddc; --pastel-3: #fbefc0; --pastel-4: #f2e2d6;
  --r: 22px; --shadow: 0 1px 0 rgba(90,70,30,.05), 0 18px 40px -26px rgba(90,70,30,.45);
  --f-head: "Fraunces", "Fraunces respaldo", "Fraunces respaldo 2", Georgia, "Times New Roman", serif;
  --f-body: "Source Sans 3", "Source Sans respaldo", system-ui, -apple-system, "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 84px; }
body.af { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--f-body); font-size: 18px; line-height: 1.62; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
.af img { max-width: 100%; height: auto; display: block; }
.af a { color: var(--sea); text-underline-offset: 3px; }
:where(.af) :is(h1, h2, h3) { margin: 0; font-family: var(--f-head); font-weight: 600; text-wrap: balance; font-variation-settings: "SOFT" 100; }
:where(.af) p { margin: 0; }
:where(.af) :is(ul, ol, dl) { margin: 0; padding: 0; list-style: none; }
.af :focus-visible { outline: 3px solid var(--sea); outline-offset: 3px; border-radius: 4px; }
.af p, .af li, .af dd { overflow-wrap: anywhere; }
.af-wrap { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 40px); }
.af-skip { position: absolute; left: 12px; top: -60px; z-index: 200; padding: 10px 14px; background: var(--ink); color: var(--bg) !important; border-radius: 6px; font-weight: 700; text-decoration: none; }
.af-skip:focus { top: 12px; }

/* Cabecera */
.af-top { position: sticky; top: 0; z-index: 50; background: rgba(246,241,231,.94); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--rule); }
.af-top-in { max-width: 1200px; margin: 0 auto; padding: 10px clamp(16px, 4vw, 40px); display: flex; align-items: center; gap: 18px; }
.af-brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink) !important; flex: none; }
.af-brand-mark { display: block; width: 40px; height: 40px; flex: none; }
.af-brand-txt { display: flex; flex-direction: column; line-height: 1.15; }
.af-brand-txt strong { font-family: var(--f-head); font-size: 18px; font-weight: 600; }
.af-brand-txt span { color: var(--olive-d); font-weight: 700; font-size: 12.5px; }
.af-nav { display: flex; gap: 2px; margin-left: auto; }
.af-nav a { padding: 8px 12px; border-radius: 999px; color: var(--ink); text-decoration: none; font-size: 15px; font-weight: 600; }
.af-nav a:hover, .af-nav a[aria-current="page"] { background: var(--sand-2); }
.af-top .af-btn { flex: none; }
@media (max-width: 960px) { .af-top .af-btn { margin-left: auto; } }
@media (max-width: 520px) { .af-brand-txt span { display: none; } .af-top-in { gap: 10px; } }
@media (max-width: 380px) { .af-brand-txt { display: none; } }

/* Botones en píldora (objetivo táctil ≥ 44 px) */
.af-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 12px 22px; border-radius: 999px; border: 2px solid var(--sea); background: var(--sea); color: #fff !important; font-weight: 700; font-size: 16.5px; line-height: 1.2; text-decoration: none; text-align: center; cursor: pointer; transition: transform .15s ease, background-color .15s ease; }
.af-btn:hover { background: var(--sea-d); border-color: var(--sea-d); transform: translateY(-1px); }
.af-btn-sm { min-height: 44px; padding: 8px 16px; font-size: 14.5px; }
.af-btn-ghost { background: transparent; color: var(--ink) !important; border-color: var(--ink); }
.af-btn-ghost:hover { background: var(--ink); border-color: var(--ink); color: var(--bg) !important; }
.af-btn-sun { background: var(--sun); border-color: var(--sun); color: var(--ink) !important; }
.af-btn-sun:hover { background: var(--sun-l); border-color: var(--sun-l); }
.af-btn-olive { background: var(--olive); border-color: var(--olive); }
.af-btn-olive:hover { background: var(--olive-d); border-color: var(--olive-d); }
.af-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

/* Etiquetas, números y marcas */
.af-eyebrow { display: inline-block; padding: 6px 14px; border-radius: 18px; background: var(--surface); border: 1px solid var(--rule); font-size: 14px; font-weight: 700; line-height: 1.4; color: var(--olive-d); }
.af-dot { display: inline-block; width: 8px; height: 8px; margin-right: 8px; border-radius: 50%; background: var(--olive); vertical-align: 1px; }
.af-num { display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--sun-l); color: var(--ink); font: 600 17px/1 var(--f-head); vertical-align: middle; }
.af-src { margin-top: 18px; font-size: 14px; line-height: 1.55; color: var(--muted); }
.af-src a { overflow-wrap: anywhere; }

/* Hero con sol y ola */
.af-hero { position: relative; overflow: hidden; padding: clamp(36px, 6vw, 88px) 0 clamp(88px, 11vw, 140px);
  background: radial-gradient(38% 52% at 94% 6%, rgba(242,194,48,.30), transparent 70%), radial-gradient(34% 46% at 0% 100%, rgba(47,97,64,.12), transparent 70%), var(--bg); }
.af-hero::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: clamp(40px, 6vw, 84px); pointer-events: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 80' preserveAspectRatio='none'%3E%3Cpath fill='%23fcf9f2' d='M0 48c120-26 240-38 360-30s240 40 360 40 240-34 360-42 240 8 360 22V80H0z'/%3E%3C/svg%3E") center bottom / 100% 100% no-repeat; }
.af-hero-in { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, .7fr); gap: clamp(28px, 5vw, 72px); align-items: center; }
.af-hero h1 { margin-top: 20px; font-size: clamp(36px, 5.2vw, 66px); line-height: 1.05; letter-spacing: -.02em; }
.af-hero h1 em { font-style: italic; color: var(--sea); background: linear-gradient(transparent 68%, rgba(242,194,48,.45) 68%); padding: 0 .06em; }
.af-lead { margin-top: 20px; font-size: clamp(18px, 1.4vw, 20px); color: var(--muted); max-width: 56ch; }
.af-lead strong { color: var(--ink); }
.af-facts { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px !important; }
.af-facts li { display: flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 18px; background: var(--surface); border: 1px solid var(--rule); font-size: 15px; line-height: 1.35; }
.af-facts svg { width: 18px; height: 18px; flex: none; fill: none; stroke: var(--olive); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.af-photo { position: relative; justify-self: center; width: min(100%, 380px); margin: 0; }
.af-photo::before { content: ""; position: absolute; z-index: 0; width: 44%; aspect-ratio: 1; right: -4%; top: -5%; border-radius: 50%; background: var(--sun); }
.af-photo::after { content: ""; position: absolute; z-index: 0; width: 30%; aspect-ratio: 1; left: -5%; bottom: 16%; border-radius: 50%; border: 2px dashed var(--olive); opacity: .6; }
.af-frame { position: relative; z-index: 1; aspect-ratio: 1; overflow: hidden; border-radius: 58% 42% 52% 48% / 48% 56% 44% 52%; box-shadow: var(--shadow); animation: af-blob 18s ease-in-out infinite alternate; }
.af-frame img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; }
@keyframes af-blob { to { border-radius: 44% 56% 46% 54% / 56% 44% 56% 44%; } }
.af-photo figcaption { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; margin-top: 14px; text-align: center; font-size: 15px; line-height: 1.4; color: var(--muted); }
.af-photo figcaption strong { font-family: var(--f-head); font-size: 20px; font-weight: 600; color: var(--ink); }
@media (max-width: 860px) { .af-hero-in { grid-template-columns: 1fr; } .af-photo { justify-self: start; max-width: 260px; margin-left: 8px; } }

/* Secciones */
.af-sec { padding: clamp(56px, 8vw, 110px) 0; }
.af-sec-alt { background: var(--surface); }
.af-sec-sand { background: var(--sand-2); }
.af-head { max-width: 780px; margin-bottom: clamp(26px, 4vw, 44px); }
.af-head .af-eyebrow { margin-left: 8px; vertical-align: middle; }
.af-head h2 { margin-top: 16px; font-size: clamp(30px, 4vw, 48px); line-height: 1.08; letter-spacing: -.015em; }
.af-intro { margin-top: 14px; font-size: 19px; color: var(--muted); }
.af-grid { display: grid; gap: clamp(14px, 2vw, 22px); }
.af-g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.af-g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 860px) { .af-g3 { grid-template-columns: 1fr; } }
@media (max-width: 720px) { .af-g2 { grid-template-columns: 1fr; } }
.af-card { padding: 26px; border-radius: var(--r); background: var(--surface); box-shadow: var(--shadow); }
.af-sec-alt .af-card { background: var(--bg); }
.af-card h3 { font-size: clamp(21px, 2vw, 25px); line-height: 1.2; }
.af-card p { margin-top: 10px; color: var(--muted); font-size: 16.5px; }
.af-p1 { background: var(--pastel-1) !important; } .af-p2 { background: var(--pastel-2) !important; }
.af-p3 { background: var(--pastel-3) !important; } .af-p4 { background: var(--pastel-4) !important; }
.af-checks li { position: relative; padding-left: 26px; margin-top: 10px; font-size: 16px; line-height: 1.5; }
.af-checks li::before { content: ""; position: absolute; left: 2px; top: .42em; width: 12px; height: 7px; border-left: 2.5px solid var(--olive); border-bottom: 2.5px solid var(--olive); transform: rotate(-45deg); }
.af-link { display: inline-block; margin-top: 16px; font-weight: 700; color: var(--sea); }

/* Curso estrella: bloque azul mar */
.af-star { display: grid; gap: clamp(20px, 3vw, 30px); padding: clamp(22px, 4vw, 48px); border-radius: var(--r); background: var(--sea); color: #fff; box-shadow: var(--shadow); }
.af-star a:not(.af-btn) { color: #fff; }
.af-star :focus-visible { outline-color: var(--sun-l); }
.af-star-tag { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; font-size: 14px; font-weight: 700; color: var(--sun-l); }
.af-badge { display: inline-block; padding: 5px 11px; border-radius: 999px; background: var(--sun); color: var(--ink); font-size: 12.5px; letter-spacing: .08em; text-transform: uppercase; }
.af-star h2, .af-star h3.af-star-t { margin-top: 12px; font-size: clamp(28px, 3.6vw, 44px); line-height: 1.06; color: #fff; }
.af-star-lead { margin-top: 14px; max-width: 70ch; font-size: clamp(17px, 1.3vw, 19px); color: #e4eff4; }
.af-meta { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.af-meta li { display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; border-radius: 16px; background: var(--sea-d); font-size: 15.5px; line-height: 1.4; font-weight: 600; }
.af-meta span { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--sun-l); }
.af-star-body { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: clamp(20px, 4vw, 48px); }
.af-sub { font-size: 12.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--sun-l); }
.af-temario { counter-reset: t; display: grid; gap: 12px; margin-top: 12px !important; }
.af-temario li { counter-increment: t; position: relative; padding-left: 42px; font-size: 16px; line-height: 1.5; }
.af-temario li::before { content: counter(t); position: absolute; left: 0; top: 0; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--sun); color: var(--ink); font-size: 14px; font-weight: 800; }
.af-star .af-checks li::before { border-color: var(--sun); }
.af-avisos { display: grid; gap: 8px; padding-top: 18px; border-top: 1px solid rgba(255,255,255,.35); }
.af-avisos li { position: relative; padding-left: 26px; font-size: 15px; line-height: 1.5; color: #e4eff4; }
.af-avisos li::before { content: "!"; position: absolute; left: 0; top: .2em; display: grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; background: var(--sun); color: var(--ink); font-size: 11px; font-weight: 800; line-height: 1; }
.af-avisos strong { color: #fff; }
@media (max-width: 900px) { .af-meta { grid-template-columns: repeat(2, minmax(0, 1fr)); } .af-star-body { grid-template-columns: 1fr; } }
@media (max-width: 420px) { .af-meta { grid-template-columns: 1fr; } }

/* Formatos 2 / 4 / 8 h */
.af-format { position: relative; display: flex; flex-direction: column; }
.af-hours { font: 600 clamp(46px, 5vw, 64px)/1 var(--f-head); color: var(--sea); letter-spacing: -.02em; }
.af-hours small { font-size: .4em; margin-left: 4px; color: var(--olive-d); }
.af-format h3 { margin-top: 8px; }
.af-format .af-checks { margin-top: 6px; }
.af-bar { display: flex; gap: 4px; margin-top: 16px !important; }
.af-bar li { flex: 1; height: 10px; border-radius: 99px; background: var(--rule); }
.af-bar li.on { background: var(--olive); }

/* FUNDAE en 5 pasos: diagrama con línea de unión */
.af-flow { position: relative; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 16px; counter-reset: paso; }
.af-flow::before { content: ""; position: absolute; left: 10%; right: 10%; top: 30px; height: 4px; border-radius: 4px; background: repeating-linear-gradient(90deg, var(--olive) 0 14px, transparent 14px 22px); }
.af-flow li { counter-increment: paso; position: relative; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 10px; }
.af-flow li::before { content: counter(paso); position: relative; z-index: 1; display: grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; background: var(--olive); color: #fff; font: 600 26px/1 var(--f-head); box-shadow: 0 0 0 6px var(--sand-2); }
.af-flow li:nth-child(even)::before { background: var(--sea); }
.af-flow li:last-child::before { background: var(--sun); color: var(--ink); }
.af-flow .af-who { display: inline-block; padding: 3px 10px; border-radius: 999px; background: var(--surface); border: 1px solid var(--rule); font-size: 12.5px; font-weight: 700; color: var(--olive-d); }
.af-flow h3 { font-size: 19px; line-height: 1.25; }
.af-flow p { font-size: 15.5px; color: var(--muted); }
@media (max-width: 900px) {
  .af-flow { grid-template-columns: 1fr; gap: 14px; }
  .af-flow::before { left: 30px; right: auto; top: 10px; bottom: 10px; width: 4px; height: auto; background: repeating-linear-gradient(180deg, var(--olive) 0 14px, transparent 14px 22px); }
  .af-flow li { display: grid; grid-template-columns: 64px minmax(0, 1fr); column-gap: 16px; text-align: left; align-items: start; }
  .af-flow li::before { grid-row: span 3; }
  .af-flow li > * { grid-column: 2; justify-self: start; }
}

/* Tarjeta del código SEPE */
.af-code { padding: clamp(22px, 3vw, 32px); border-radius: 28px; background: var(--sea); color: #fff; box-shadow: var(--shadow); }
.af-code-k { font-size: 13px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--sun-l); }
.af-code p.af-code-n { margin-top: 4px; font: 600 clamp(30px, 4vw, 42px)/1.1 var(--f-head); letter-spacing: .02em; font-variant-numeric: tabular-nums; }
.af-code p { margin-top: 12px; font-size: 15.5px; color: #e4eff4; }
.af-code a { color: #fff; font-weight: 700; overflow-wrap: anywhere; }
.af-code :focus-visible { outline-color: var(--sun-l); }

/* Bloque «tope de bonificación»: fórmula en cajas */
.af-formula { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 16px !important; }
.af-formula li { padding: 12px 16px; border-radius: 16px; background: var(--surface); border: 1px solid var(--rule); font-weight: 700; font-size: 16px; text-align: center; }
.af-formula li small { display: block; font-size: 12.5px; font-weight: 600; color: var(--muted); }
.af-formula .op { padding: 0; border: 0; background: none; font: 600 26px/1 var(--f-head); color: var(--olive-d); }
.af-formula .res { background: var(--olive); border-color: var(--olive); color: #fff; }
.af-formula .res small { color: #eef2e0; }

/* Tabla sencilla */
.af-table { width: 100%; border-collapse: collapse; font-size: 16px; }
.af-table caption { text-align: left; margin-bottom: 10px; font-size: 14.5px; color: var(--muted); }
.af-table th, .af-table td { padding: 12px 10px; border-bottom: 1px solid var(--rule); text-align: left; vertical-align: top; }
.af-table thead th { font-size: 12.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--olive-d); }
.af-table-wrap { overflow-x: auto; border-radius: 18px; background: var(--surface); padding: 6px 16px 10px; }

/* Zona: anillos + lista */
.af-zone { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(24px, 4vw, 56px); align-items: center; }
.af-map { position: relative; max-width: 340px; width: 100%; aspect-ratio: 1; justify-self: center; }
.af-map svg { width: 100%; height: 100%; }
.af-map circle { fill: none; stroke: var(--sea); stroke-width: 1.5; stroke-dasharray: 4 7; }
.af-map circle.c1 { fill: rgba(38,35,30,.06); }
.af-map circle.pin { fill: var(--olive); stroke: none; }
.af-zm { position: absolute; left: 50%; transform: translateX(-50%); padding: 4px 10px; border-radius: 999px; background: var(--surface); border: 1px solid var(--rule); font-size: 13px; font-weight: 700; white-space: nowrap; }
.af-zm-1 { top: 58%; background: var(--olive); border-color: var(--olive); color: #fff; }
.af-zm-2 { top: 20%; }
.af-zm-3 { top: 2%; }
.af-zones { display: grid; gap: 12px; }
.af-zones > div { padding: 14px 20px; border-radius: 18px; background: var(--surface); }
.af-zones dt { font-family: var(--f-head); font-size: 20px; font-weight: 600; color: var(--sea); }
.af-zones dd { margin: 2px 0 0; font-size: 16px; color: var(--muted); }
@media (max-width: 820px) { .af-zone { grid-template-columns: 1fr; } .af-map { max-width: 260px; } }

/* Por qué / testimonios */
.af-why li { display: flex; gap: 14px; align-items: flex-start; }
.af-why .af-num { flex: none; }
.af-why h3 { font-size: 21px; }
.af-why p { margin-top: 4px; color: var(--muted); font-size: 16.5px; }
.af-quotes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: clamp(24px, 4vw, 40px) !important; }
.af-quotes li { padding: 20px 22px; border-radius: 18px; background: var(--bg); border-left: 5px solid var(--sun); }
.af-quotes blockquote { margin: 0; font-family: var(--f-head); font-style: italic; font-size: 18px; line-height: 1.45; }
.af-quotes cite { display: block; margin-top: 10px; font-style: normal; font-size: 14px; font-weight: 700; color: var(--olive-d); }
@media (max-width: 900px) { .af-quotes { grid-template-columns: 1fr; } }

/* Riesgos del AI Act en pirámide */
.af-pyr { display: grid; gap: 8px; max-width: 760px; margin: 0 auto; }
.af-pyr li { margin: 0 auto; padding: 14px 18px; border-radius: 14px; text-align: center; font-size: 16px; line-height: 1.45; }
.af-pyr li strong { display: block; font-family: var(--f-head); font-size: 19px; font-weight: 600; }
.af-pyr li:nth-child(1) { width: 52%; background: #f3d3c8; }
.af-pyr li:nth-child(2) { width: 68%; background: var(--pastel-3); }
.af-pyr li:nth-child(3) { width: 84%; background: var(--pastel-2); }
.af-pyr li:nth-child(4) { width: 100%; background: var(--pastel-1); }
@media (max-width: 640px) { .af-pyr li { width: 100% !important; } }

/* ¿Proveedor o responsable del despliegue? */
.af-vs { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); gap: 16px; align-items: stretch; }
.af-vs .af-or { align-self: center; display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; background: var(--sun); font: 600 16px/1 var(--f-head); }
@media (max-width: 760px) { .af-vs { grid-template-columns: 1fr; } .af-vs .af-or { justify-self: center; } }

/* Línea de tiempo */
.af-time { position: relative; display: grid; gap: 14px; padding-left: 28px; }
.af-time::before { content: ""; position: absolute; left: 8px; top: 6px; bottom: 6px; width: 3px; border-radius: 3px; background: var(--olive); }
.af-time li { position: relative; padding: 14px 18px; border-radius: 16px; background: var(--surface); }
.af-time li::before { content: ""; position: absolute; left: -26px; top: 20px; width: 15px; height: 15px; border-radius: 50%; background: var(--sun); border: 3px solid var(--olive); }
.af-time time { font-weight: 800; color: var(--sea); }

/* Preguntas frecuentes */
.af-faq { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(24px, 4vw, 56px); align-items: start; }
@media (max-width: 860px) { .af-faq { grid-template-columns: 1fr; } }
.af-faq details { margin-bottom: 10px; padding: 0 22px; border-radius: 18px; background: var(--bg); }
.af-sec:not(.af-sec-alt) .af-faq details { background: var(--surface); }
.af-faq summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; gap: 16px; align-items: center; min-height: 44px; padding: 16px 0; font-family: var(--f-head); font-size: 19px; font-weight: 600; line-height: 1.3; }
.af-faq summary::-webkit-details-marker { display: none; }
.af-faq summary::after { content: "+"; flex: none; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--sun-l); font-size: 20px; font-weight: 400; transition: transform .2s; }
.af-faq details[open] summary::after { transform: rotate(45deg); }
.af-faq details p { padding: 0 0 18px; font-size: 16.5px; color: var(--muted); max-width: 65ch; }

/* CTA final azul mar con ola */
.af-cta { position: relative; padding: clamp(96px, 12vw, 150px) 0 clamp(56px, 8vw, 100px); background: var(--sea); color: #fff; }
.af-cta::before { content: ""; position: absolute; left: 0; right: 0; top: -1px; height: clamp(40px, 6vw, 84px); pointer-events: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 80' preserveAspectRatio='none'%3E%3Cpath fill='%23f6f1e7' d='M0 32c120 26 240 38 360 30s240-40 360-40 240 34 360 42 240-8 360-22V0H0z'/%3E%3C/svg%3E") center top / 100% 100% no-repeat; }
.af-cta.after-surface::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 80' preserveAspectRatio='none'%3E%3Cpath fill='%23fcf9f2' d='M0 32c120 26 240 38 360 30s240-40 360-40 240 34 360 42 240-8 360-22V0H0z'/%3E%3C/svg%3E"); }
.af-cta-in { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, .9fr); gap: clamp(24px, 4vw, 56px); align-items: center; }
.af-cta h2 { margin-top: 14px; font-size: clamp(32px, 4.4vw, 52px); line-height: 1.06; color: #fff; }
.af-cta .af-lead { color: #dbe9ef; }
.af-cta .af-eyebrow { background: rgba(255,255,255,.1); border-color: rgba(255,255,255,.3); color: var(--sun-l); }
.af-mini { counter-reset: m; display: grid; gap: 8px; margin-top: 22px !important; }
.af-mini li { counter-increment: m; display: flex; gap: 10px; font-size: 16.5px; color: #dbe9ef; }
.af-mini li::before { content: counter(m); flex: none; display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: var(--sun); color: var(--ink); font-size: 13px; font-weight: 800; }
.af-mini strong { color: #fff; }
.af-box { padding: clamp(22px, 3vw, 32px); border-radius: 28px; background: var(--surface); color: var(--ink); box-shadow: 0 30px 60px -30px rgba(0,0,0,.45); }
.af-box h3 { font-size: 22px; }
.af-box .af-btn { width: 100%; margin-top: 16px; }
.af-box p { margin-top: 12px; font-size: 15.5px; color: var(--muted); text-align: center; }
.af-box a:not(.af-btn) { color: var(--sea); font-weight: 700; }
.af-cta :focus-visible { outline-color: var(--sun-l); }
.af-box :focus-visible { outline-color: var(--sea); }
@media (max-width: 860px) { .af-cta-in { grid-template-columns: 1fr; } }

/* Migas de pan */
.af-crumbs { display: flex; flex-wrap: wrap; gap: 6px; font-size: 14.5px; color: var(--muted); }
.af-crumbs li + li::before { content: "›"; margin-right: 6px; color: var(--olive); }
.af-crumbs a { color: var(--sea); }

/* Pie */
.af-foot { background: var(--olive-d); color: #efe6d4; }
.af-foot-in { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 20px 40px; padding-top: 36px; padding-bottom: 40px; font-size: 15px; }
.af-foot strong { font-family: var(--f-head); font-size: 18px; font-weight: 600; color: #fff; }
.af-foot p + p { margin-top: 4px; }
.af-foot a { color: #efe6d4; }
.af-foot a:hover { color: #fff; }
.af-foot nav ul { display: grid; gap: 6px; }
.af-foot nav h2 { font-family: var(--f-body); font-size: 12.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--sun-l); margin-bottom: 8px; }
.af-foot :focus-visible { outline-color: var(--sun-l); }
.af-foot a { display: inline-block; min-height: 24px; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .af-frame { animation: none; }
  .af-btn { transition: none; }
}
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.af-mt { margin-top: clamp(28px, 4vw, 44px); }
.af-card > .af-num + h3 { margin-top: 12px; }

/* ===================================================================
   Navegación, bloques de portada y piezas compartidas
   =================================================================== */

/* Menú en móvil: debajo de 960 px el menú baja a una segunda fila, sin scroll horizontal. */
@media (max-width: 960px) {
  html { scroll-padding-top: 132px; }
  .af-top-in { flex-wrap: wrap; row-gap: 2px; padding-bottom: 6px; }
  .af-nav { order: 3; width: 100%; margin: 0 0 0 -8px; flex-wrap: wrap; }
  .af-nav a { display: inline-flex; align-items: center; min-height: 40px; padding: 6px 10px; font-size: 15px; }
}
@media (max-width: 400px) { .af-nav a { padding: 6px 8px; font-size: 14.5px; } }

/* Ola de la banda de contacto cuando la sección anterior es arena */
.af-cta.after-sand::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 80' preserveAspectRatio='none'%3E%3Cpath fill='%23ebe2d0' d='M0 32c120 26 240 38 360 30s240-40 360-40 240 34 360 42 240-8 360-22V0H0z'/%3E%3C/svg%3E"); }

/* Botón fantasma sobre el bloque azul mar */
.af-star .af-btn-ghost { color: #fff !important; border-color: rgba(255,255,255,.75); }
.af-star .af-btn-ghost:hover { background: #fff; border-color: #fff; color: var(--sea-d) !important; }
.af-star .af-actions { margin-top: 0; }

/* Servicios secundarios: tarjeta con etiqueta */
.af-svc { display: flex; flex-direction: column; }
.af-svc .af-tag { align-self: flex-start; margin-bottom: 12px; padding: 4px 11px; border-radius: 999px; background: var(--surface); font-size: 13px; font-weight: 700; color: var(--olive-d); }
.af-svc .af-link { margin-top: auto; padding-top: 16px; }

/* Accesos destacados (AI Act y Formaciones FUNDAE): la tarjeta entera es el enlace */
.af-door { position: relative; display: flex; flex-direction: column; gap: 12px; min-height: 100%; padding: clamp(24px, 3.4vw, 40px); border-radius: var(--r); color: var(--ink) !important; text-decoration: none; box-shadow: var(--shadow); overflow: hidden; transition: transform .15s ease; }
.af-door:hover { transform: translateY(-2px); }
.af-door::after { content: ""; position: absolute; right: -40px; bottom: -40px; width: 140px; aspect-ratio: 1; border-radius: 50%; background: rgba(255,255,255,.45); pointer-events: none; }
.af-door .af-eyebrow { align-self: flex-start; }
.af-door h3 { font-size: clamp(26px, 3vw, 36px); line-height: 1.08; }
.af-door p { color: var(--muted); font-size: 17px; max-width: 46ch; }
.af-door .af-go { margin-top: auto; padding-top: 8px; font-weight: 700; color: var(--sea); text-decoration: underline; text-underline-offset: 3px; }
.af-door:hover .af-go { color: var(--sea-d); }

/* Una línea de experiencia que enlaza a Sobre mí */
.af-exp { padding: clamp(36px, 5vw, 56px) 0; background: var(--surface); text-align: center; }
.af-exp p { max-width: 900px; margin: 0 auto; font-family: var(--f-head); font-size: clamp(21px, 2.3vw, 28px); line-height: 1.35; font-variation-settings: "SOFT" 100; }
.af-exp a { font-family: var(--f-body); font-size: .7em; font-weight: 700; white-space: nowrap; }

/* Cómo trabajo en 3 pasos: el diagrama de la academy con 3 columnas */
.af-flow.af-flow-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.af-flow.af-flow-3::before { left: 17%; right: 17%; }
.af-sec:not(.af-sec-sand) .af-flow li::before { box-shadow: 0 0 0 6px var(--bg); }
.af-sec-alt .af-flow li::before { box-shadow: 0 0 0 6px var(--surface) !important; }
@media (max-width: 900px) { .af-flow.af-flow-3 { grid-template-columns: 1fr; } }

/* Marquesina de marcas: dónde trabajé o me formé */
.af-marquee { position: relative; overflow: hidden; padding: 26px 0 22px; border-radius: var(--r); background: var(--bg); box-shadow: var(--shadow); }
.af-marquee-track { display: flex; width: max-content; animation: af-mq 42s linear infinite;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent); mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent); }
.af-logos { display: flex; align-items: flex-end; flex: none; gap: clamp(44px, 6vw, 90px); padding-left: clamp(44px, 6vw, 90px); }
.af-logos li { display: flex; flex-direction: column; align-items: center; gap: 10px; }
.af-logos img { width: auto; max-width: none; opacity: .86; }
.af-logos .l-telekom, .af-logos .l-aws { height: 30px; }
.af-logos .l-generalitat { height: 28px; }
.af-logos .l-googlecloud { height: 21px; }
.af-logos .l-freshly { height: 19px; }
.af-logos span { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); white-space: nowrap; }
@keyframes af-mq { to { transform: translateX(-50%); } }
.af-marquee:hover .af-marquee-track, .af-marquee:focus-within .af-marquee-track, .af-marquee.is-paused .af-marquee-track { animation-play-state: paused; }
.af-mq-bar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px 16px; margin-top: 14px; }
.af-mq-bar p { font-size: 15px; color: var(--muted); }
.af-mq-pause { min-height: 40px; padding: 6px 14px; border-radius: 999px; border: 1.5px solid var(--ink); background: transparent; color: var(--ink); font: 700 14px/1.2 var(--f-body); cursor: pointer; }
.af-mq-pause:hover { background: var(--ink); color: var(--bg); }
@media (prefers-reduced-motion: reduce) {
  .af-marquee-track { animation: none; width: auto; justify-content: center; -webkit-mask-image: none; mask-image: none; }
  .af-logos { flex-wrap: wrap; justify-content: center; row-gap: 22px; padding: 0 16px; }
  .af-logos[aria-hidden="true"], .af-mq-pause { display: none; }
}

/* Caja de contacto: datos visibles */
.af-box .af-contact { display: grid; gap: 6px; margin-top: 14px; font-size: 16px; text-align: center; }
.af-box .af-contact a { color: var(--sea); font-weight: 700; }

@media (prefers-reduced-motion: reduce) { .af-door { transition: none; } }

/* Fórmula y tabla del tope cuando caen en una sección de superficie */
.af-sec-alt .af-formula li:not(.op):not(.res), .af-sec-alt .af-table-wrap { background: var(--bg); }

/* Consultoría de 1 hora */
.af-price .af-code-n small { font-size: .45em; font-weight: 600; color: var(--sun-l); }
.af-consult { display: flex; flex-direction: column; }
.af-consult .af-tag { align-self: flex-start; margin-bottom: 12px; padding: 4px 11px; border-radius: 999px; background: var(--surface); font-size: 13px; font-weight: 700; color: var(--olive-d); }
.af-qa { display: grid; gap: 12px; margin-top: 14px !important; }
.af-qa dt { font-size: 12.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--olive-d); }
.af-qa dd { margin: 2px 0 0; font-size: 16.5px; line-height: 1.5; }
.af-qa dd.af-voz { font-family: var(--f-head); font-style: italic; font-size: 18px; }
.af-consult .af-note { margin-top: 14px; font-size: 15.5px; color: var(--muted); }
.af-buy { margin-top: auto; padding-top: 22px; }
.af-buy .af-btn { width: 100%; }
.af-flow.af-flow-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.af-flow.af-flow-4::before { left: 12%; right: 12%; }
@media (max-width: 900px) { .af-flow.af-flow-4 { grid-template-columns: 1fr; } }

/* Con 5 entradas de menú la cabecera no cabe en una fila por debajo de ~1120 px:
   el menú baja a una segunda fila y, en móvil, la cabecera deja de ser fija para no tapar media pantalla. */
@media (max-width: 1120px) and (min-width: 961px) {
  .af-top-in { flex-wrap: wrap; row-gap: 2px; padding-bottom: 6px; }
  .af-nav { order: 3; width: 100%; margin: 0 0 0 -8px; }
  .af-top .af-btn { margin-left: auto; }
  html { scroll-padding-top: 120px; }
}
@media (max-width: 960px) {
  .af-top { position: relative; }
  html { scroll-padding-top: 12px; }
}

/* Sobre mí: cita del hero */
.af-hero .af-lead + .af-lead { margin-top: 14px; }
.af-hero-quote { margin: 22px 0 0; padding-left: 16px; border-left: 3px solid var(--sun); font-family: var(--f-head); font-style: italic; font-size: clamp(18px, 1.5vw, 21px); line-height: 1.45; color: var(--ink); max-width: 52ch; }

/* LinkedIn en cabecera y pie */
.af-in { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 50%; color: var(--sea); border: 1.5px solid var(--rule); flex: none; }
.af-in:hover, .af-in:focus-visible { background: var(--sea); color: #fff; border-color: var(--sea); }
.af-in-foot { display: inline-flex; align-items: center; gap: 6px; vertical-align: middle; }
.af-in-foot svg { width: 16px; height: 16px; }

/* Pie: franja de garantías */
.af-trust { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; padding: 28px 0 24px; border-bottom: 1px solid rgba(239,230,212,.22); list-style: none; margin: 0; }
.af-trust li { display: flex; gap: 10px; align-items: flex-start; font-size: 13.5px; line-height: 1.35; color: #d9cfba; }
.af-trust svg { flex: none; color: var(--sun-l); margin-top: 1px; }
.af-trust span { display: grid; gap: 2px; }
.af-trust strong { font-family: var(--f-body); font-size: 14px; font-weight: 700; color: #fff; }
.af-trust a { min-height: 0; }
@media (max-width: 1000px) { .af-trust { grid-template-columns: repeat(2, 1fr); gap: 16px; } }
@media (max-width: 520px) { .af-trust { grid-template-columns: 1fr; } }

/* ===================================================================
   Barra de cookies, páginas legales, contacto y 404
   =================================================================== */

/* Barra de cookies (public/scripts/site.js) */
.cookie-bar { position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 80; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 20px; max-width: 760px; margin: 0 auto; padding: 16px 20px; border-radius: 20px; background: var(--surface); color: var(--ink); border: 1px solid var(--rule); box-shadow: 0 24px 50px -20px rgba(40,30,10,.5); font-size: 16px; line-height: 1.5; opacity: 0; transform: translateY(16px); transition: opacity .3s ease, transform .3s ease; }
.cookie-bar.visible { opacity: 1; transform: none; }
.cookie-bar p { flex: 1 1 320px; margin: 0; }
.cookie-bar a { color: var(--sea); font-weight: 700; }
.cookie-bar__acciones { display: flex; gap: 10px; flex-wrap: wrap; }
.cookie-bar :focus-visible { outline: 3px solid var(--sea); outline-offset: 3px; }
@media (max-width: 560px) { .cookie-bar { left: 10px; right: 10px; bottom: 10px; padding: 14px 16px; } .cookie-bar__acciones { width: 100%; } .cookie-bar__acciones .af-btn { flex: 1; } }
@media (prefers-reduced-motion: reduce) { .cookie-bar { transition: none; } }

/* Cabecera compacta para páginas interiores (legal, contacto, 404) */
.af-hero.af-hero-sm { padding-bottom: clamp(64px, 8vw, 104px); }
.af-hero-sm .af-hero-in { grid-template-columns: 1fr; }
.af-hero-sm h1 { font-size: clamp(34px, 4.6vw, 56px); }

/* Texto legal largo: índice + columna legible de ~70 caracteres */
.af-legal { display: grid; grid-template-columns: minmax(0, 260px) minmax(0, 70ch); gap: clamp(28px, 5vw, 72px); align-items: start; }
.af-toc { position: sticky; top: 100px; padding: 18px 20px; border-radius: 18px; background: var(--bg); }
.af-toc h2 { font-family: var(--f-body); font-size: 12.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--olive-d); margin-bottom: 10px; }
.af-toc ol { display: grid; gap: 4px; }
.af-toc a { display: block; padding: 4px 0; font-size: 15px; line-height: 1.35; color: var(--ink); text-decoration: none; }
.af-toc a:hover { color: var(--sea); text-decoration: underline; }
.af-prose { font-size: 17.5px; line-height: 1.7; }
.af-prose > * + * { margin-top: 14px; }
.af-prose h2 { margin-top: 40px !important; font-size: clamp(23px, 2.3vw, 28px); line-height: 1.2; scroll-margin-top: 100px; }
.af-prose ul { display: grid; gap: 8px; padding-left: 0; }
.af-prose ul li { position: relative; padding-left: 22px; }
.af-prose ul li::before { content: ""; position: absolute; left: 4px; top: .7em; width: 8px; height: 8px; border-radius: 50%; background: var(--olive); }
.af-prose code { padding: 1px 6px; border-radius: 6px; background: var(--sand-2); font-size: .9em; }
.af-prose .af-legal-details { display: grid; gap: 4px; padding: 18px 22px; border-radius: 18px; background: var(--bg); border-left: 5px solid var(--sun); }
.af-prose .af-legal-details p { margin: 0; }
.af-prose .meta { color: var(--muted); font-size: 15.5px; }
.af-legal-more { margin-top: 44px; padding-top: 24px; border-top: 1px solid var(--rule); }
.af-legal-more h2 { font-size: 20px; }
.af-legal-more ul { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 12px !important; }
@media (max-width: 900px) { .af-legal { grid-template-columns: minmax(0, 1fr); } .af-toc { position: static; } }

/* Formulario de contacto */
.af-contact-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: clamp(28px, 5vw, 64px); align-items: start; }
@media (max-width: 900px) { .af-contact-grid { grid-template-columns: minmax(0, 1fr); } }
.af-form { display: grid; gap: 20px; padding: clamp(22px, 3.4vw, 40px); border-radius: var(--r); background: var(--bg); box-shadow: var(--shadow); }
.af-form h2 { font-size: clamp(26px, 3vw, 34px); }
.af-form fieldset { margin: 0; padding: 0; border: 0; min-width: 0; }
.af-form legend, .af-field > label { display: block; margin-bottom: 8px; font-weight: 700; font-size: 16px; }
.af-field .opt { font-weight: 400; color: var(--muted); }
.af-field input, .af-field select, .af-field textarea { width: 100%; min-height: 48px; padding: 11px 14px; border: 1.5px solid #8a7f6a; border-radius: 14px; background: var(--surface); color: var(--ink); font: 400 17px/1.4 var(--f-body); }
.af-field textarea { min-height: 150px; resize: vertical; }
.af-field input:focus-visible, .af-field select:focus-visible, .af-field textarea:focus-visible { outline: 3px solid var(--sea); outline-offset: 2px; border-color: var(--sea); }
.af-field [aria-invalid="true"] { border-color: #a3341f; }
.af-field-error { min-height: 0; margin-top: 6px !important; font-size: 15px; font-weight: 600; color: #a3341f; }
.af-field-error:empty { display: none; }
.af-radios { display: flex; flex-wrap: wrap; gap: 10px; }
.af-radio { display: inline-flex; align-items: center; gap: 10px; min-height: 48px; padding: 10px 16px; border: 1.5px solid #8a7f6a; border-radius: 999px; background: var(--surface); font-weight: 600; cursor: pointer; }
.af-radio input { width: 18px; height: 18px; accent-color: var(--sea); margin: 0; }
.af-radio:has(input:checked) { border-color: var(--sea); background: var(--pastel-2); }
.af-radio:has(input:focus-visible) { outline: 3px solid var(--sea); outline-offset: 2px; }
.af-check { display: flex; gap: 12px; align-items: flex-start; font-size: 16px; line-height: 1.45; cursor: pointer; }
.af-check input { flex: none; width: 22px; height: 22px; margin: 1px 0 0; accent-color: var(--sea); }
.af-hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.af-form button[type="submit"] { justify-self: start; }
.af-form small { font-size: 14px; color: var(--muted); }
.af-form-error { padding: 12px 16px; border-radius: 14px; background: #f8ddd6; color: #6b1f10; font-weight: 600; }
.af-form-error:empty { display: none; }
.af-form-ok { display: flex; gap: 14px; align-items: flex-start; padding: clamp(22px, 3.4vw, 40px); border-radius: var(--r); background: var(--pastel-1); box-shadow: var(--shadow); font-size: 18px; }
.af-form-ok[hidden] { display: none; }
.af-form-ok .ico { display: grid; place-items: center; flex: none; width: 44px; height: 44px; border-radius: 50%; background: var(--olive); color: #fff; }
.af-form-ok .ico svg { width: 24px; height: 24px; }
.af-aside h2 { font-size: clamp(24px, 2.6vw, 30px); margin-top: 12px; }
.af-steps { display: grid; gap: 14px; margin-top: 20px !important; }
.af-steps li { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 14px; align-items: start; }
.af-steps h3 { font-size: 19px; line-height: 1.3; }
.af-steps p { margin-top: 2px !important; font-size: 16px; color: var(--muted); }
.af-info { display: grid; gap: 10px; margin-top: 26px !important; padding: 18px 20px; border-radius: 18px; background: var(--bg); font-size: 16.5px; }
.af-info li { display: flex; gap: 10px; align-items: center; }
.af-info svg { flex: none; width: 22px; height: 22px; fill: none; stroke: var(--olive); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.af-info a { font-weight: 700; }

/* 404 */
.af-404-num { font: 600 clamp(88px, 14vw, 180px)/.9 var(--f-head); color: var(--sea); letter-spacing: -.04em; }
.af-404-num span { color: var(--sun); }
/* Páginas interiores: menos aire arriba para que el contenido (formulario, texto legal) asome antes */
.af-hero.af-hero-sm { padding-top: clamp(24px, 3.5vw, 48px); padding-bottom: clamp(56px, 7vw, 92px); }
.af-hero-sm + .af-sec { padding-top: clamp(28px, 4vw, 56px); }
/* Los <button> no heredan la tipografía: formulario y barra de cookies con la fuente de la web */
.af button, .cookie-bar button { font-family: var(--f-body); }
.af-aside h2, .af-form h2 { line-height: 1.15; }
.af-form[hidden] { display: none; }

/* ===================================================================
   Blog (listado paginado y artículos)
   =================================================================== */
.af-h1-sub { font-size: .55em; color: var(--muted); font-weight: 500; }
.af-blog-h2 { margin: clamp(36px, 5vw, 56px) 0 20px; font-size: clamp(26px, 3vw, 34px); }
.af-sec .af-blog-h2:first-child { margin-top: 0; }

/* Tarjetas */
.af-post-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(16px, 2vw, 24px); }
@media (max-width: 980px) { .af-post-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .af-post-grid { grid-template-columns: minmax(0, 1fr); } }
.af-post-card > a { display: flex; flex-direction: column; height: 100%; border-radius: var(--r); overflow: hidden; background: var(--surface); box-shadow: var(--shadow); color: var(--ink) !important; text-decoration: none; transition: transform .15s ease; }
.af-sec-alt .af-post-card > a { background: var(--bg); }
.af-post-card > a:hover { transform: translateY(-2px); }
.af-post-card > a:hover .af-post-title { color: var(--sea); text-decoration: underline; text-underline-offset: 3px; }
.af-post-visual { aspect-ratio: 16 / 9; background: var(--sand-2); overflow: hidden; }
.af-post-visual img { width: 100%; height: 100%; object-fit: cover; }
.af-post-noimg { display: block; width: 100%; height: 100%; background: linear-gradient(180deg, var(--pastel-3), var(--sun-l)); }
.af-post-noimg svg { display: block; width: 100%; height: 100%; }
.af-post-body { display: flex; flex-direction: column; gap: 8px; padding: 18px 22px 24px; }
.af-post-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; font-size: 14.5px; font-weight: 600; color: var(--olive-d); }
.af-post-title { font-size: clamp(19px, 1.7vw, 22px); line-height: 1.25; }
.af-post-excerpt { font-size: 16px; line-height: 1.5; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.af-post-card-big > a { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); }
.af-post-card-big .af-post-visual { aspect-ratio: auto; min-height: 100%; }
.af-post-card-big .af-post-body { justify-content: center; padding: clamp(22px, 3.5vw, 44px); gap: 12px; }
.af-post-card-big .af-badge { align-self: flex-start; }
.af-post-card-big .af-post-title { font-size: clamp(26px, 3vw, 38px); line-height: 1.12; }
.af-post-card-big .af-post-excerpt { font-size: 17.5px; -webkit-line-clamp: 4; }
@media (max-width: 860px) { .af-post-card-big > a { grid-template-columns: minmax(0, 1fr); } .af-post-card-big .af-post-visual { aspect-ratio: 16 / 9; } }
@media (prefers-reduced-motion: reduce) { .af-post-card > a { transition: none; } }

/* Paginación */
.af-pager { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; margin-top: clamp(32px, 4vw, 48px); }
.af-pager ol { display: flex; gap: 6px; }
.af-pager ol a { display: grid; place-items: center; min-width: 44px; height: 44px; padding: 0 10px; border-radius: 999px; border: 1.5px solid var(--rule); background: var(--bg); color: var(--ink); font-weight: 700; text-decoration: none; }
.af-pager ol a:hover { border-color: var(--ink); }
.af-pager ol a[aria-current="page"] { background: var(--sea); border-color: var(--sea); color: #fff; }

/* Artículo */
.af-post-head h1 { margin-top: 18px; max-width: 24ch; font-size: clamp(32px, 4.4vw, 54px); line-height: 1.08; letter-spacing: -.015em; }
.af-post-head .af-post-meta { margin-top: 18px; font-size: 16px; }
.af-post-head .af-post-meta a { color: var(--sea); }
.af-post-ia { margin-top: 10px; font-size: 15px; color: var(--muted); }
.af-post-cover { max-width: 1040px; margin: 0 auto clamp(28px, 4vw, 44px); }
.af-post-cover img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--r); box-shadow: var(--shadow); }
.af-post-content { max-width: 70ch; margin: 0 auto; }
.af-post-content h2 { scroll-margin-top: 100px; }
.af-post-content h3 { margin-top: 28px !important; font-size: clamp(20px, 1.9vw, 23px); line-height: 1.25; scroll-margin-top: 100px; }
.af-post-content h4 { margin-top: 22px !important; font-family: var(--f-body); font-size: 18px; }
.af-post-content a { color: var(--sea); }
.af-post-content ol { list-style: decimal; padding-left: 1.5em; display: grid; gap: 8px; }
.af-post-content ol > li { padding-left: 4px; }
.af-post-content ol > li::marker { font-weight: 700; color: var(--olive-d); }
.af-post-content li > ul, .af-post-content li > ol { margin-top: 8px; }
.af-post-content li > p { margin: 0; }
.af-post-content ul.contains-task-list li::before { display: none; }
.af-post-content img { max-width: 100%; height: auto; margin: 8px auto; border-radius: 14px; }
.af-post-content hr { border: 0; border-top: 1px solid var(--rule); margin: 32px 0 !important; }
.af-post-content blockquote { margin: 20px 0; padding: 6px 0 6px 20px; border-left: 4px solid var(--sun); font-family: var(--f-head); font-style: italic; font-size: 19px; color: var(--ink); }
.af-post-content blockquote p { margin: 0; }
.af-post-content :not(pre) > code { padding: 1px 6px; border-radius: 6px; background: var(--sand-2); font-size: .88em; overflow-wrap: anywhere; }
.af-post-content pre { max-width: 100%; overflow-x: auto; padding: 18px 20px; border-radius: 16px; background: var(--night); color: #eef2f4; font-size: 14.5px; line-height: 1.55; }
.af-post-content pre code { background: none; padding: 0; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }
.af-post-content pre:focus-visible, .af-table-scroll:focus-visible { outline: 3px solid var(--sea); outline-offset: 2px; }
.af-table-scroll { max-width: 100%; overflow-x: auto; border-radius: 16px; background: var(--surface); border: 1px solid var(--rule); }
.af-table-scroll table { width: 100%; min-width: 520px; border-collapse: collapse; font-size: 15.5px; line-height: 1.45; }
.af-table-scroll th, .af-table-scroll td { padding: 10px 14px; border-bottom: 1px solid var(--rule); text-align: left; vertical-align: top; }
.af-table-scroll thead th { background: var(--sand-2); font-weight: 700; }
.af-table-scroll tr:last-child td { border-bottom: 0; }
.af-post-faq { margin-top: 36px; padding: clamp(20px, 3vw, 32px); border-radius: var(--r); background: var(--surface); }
.af-post-faq h2 { margin-top: 0 !important; }
.af-post-faq h3 { padding-top: 16px; border-top: 1px solid var(--rule); }
.af-post-faq h3:first-of-type { border-top: 0; padding-top: 0; }
.af-post-cta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 24px; max-width: 70ch; margin: clamp(40px, 5vw, 56px) auto 0; padding: clamp(22px, 3vw, 32px); border-radius: var(--r); background: var(--sea); color: #fff; }
.af-post-cta h2 { flex: 1 1 280px; font-size: clamp(22px, 2.4vw, 28px); line-height: 1.2; color: #fff; }
.af-post-cta :focus-visible { outline-color: var(--sun-l); }
.af-author { display: flex; gap: 16px; align-items: flex-start; max-width: 70ch; margin: 20px auto clamp(48px, 6vw, 80px); padding: 20px 22px; border-radius: 18px; background: var(--surface); border: 1px solid var(--rule); }
.af-author img { flex: none; width: 72px; height: 72px; border-radius: 50%; object-fit: cover; }
.af-author p { font-size: 16px; line-height: 1.55; color: var(--muted); }
.af-author .af-author-name { font-family: var(--f-head); font-size: 19px; font-weight: 600; color: var(--ink); }
.af-author a { color: var(--sea); font-weight: 700; }
.af-post-content ol > li::before { display: none; } .af-post-content ol > li { padding-left: 4px !important; }

/* Sobre mí: retrato circular */
.af-photo-circle .af-frame { aspect-ratio: 1; border-radius: 50%; animation: none; }
.af-photo-circle .af-frame img { object-position: 50% 50%; }

/* Consultoría: IVA incluido bajo el precio */
.af-price .af-iva { margin-top: 2px; font-weight: 700; font-size: 15px; letter-spacing: .04em; text-transform: uppercase; color: var(--sun-l); }

/* ===================================================================
   Piezas de producción (integración del 2026-11-24)
   =================================================================== */

/* Botón flotante de WhatsApp: abajo a la derecha, circular y en verde oliva */
.af a.af-wa { position: fixed; right: 20px; bottom: 20px; z-index: 60; display: inline-flex; align-items: center; justify-content: center; width: 58px; height: 58px; padding: 0; border-radius: 50%; background: var(--olive); color: #fff; text-decoration: none; box-shadow: 0 10px 26px -10px rgba(0,0,0,.55); transition: transform .15s ease, background-color .15s ease; }
.af a.af-wa:hover { background: var(--olive-d); color: #fff; transform: translateY(-2px); }
.af a.af-wa span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@media (max-width: 560px) { .af a.af-wa { right: 14px; bottom: 14px; width: 56px; height: 56px; } }
@media (prefers-reduced-motion: reduce) { .af a.af-wa { transition: none; } .af a.af-wa:hover { transform: none; } }

/* Chatbot (src/chat): burbuja abajo a la IZQUIERDA para no chocar con WhatsApp y colores de la web.
   Solo dentro de .af: business y academy conservan su estilo. */
.af .chat-bubble { left: 20px; right: auto; bottom: 20px; background: var(--sea); color: #fff; box-shadow: 0 10px 26px -10px rgba(0,0,0,.55); }
.af .chat-bubble:hover { box-shadow: 0 14px 30px -12px rgba(0,0,0,.6); }
.af .chat-bubble:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }
.af .chat-bubble .badge { background: var(--sun); border-color: var(--bg); }
.af .chat-bubble.active { background: var(--ink); color: #fff; }
.af .chat-panel { left: 20px; right: auto; bottom: 90px; background: var(--surface); color: var(--ink); border: 1px solid var(--rule); box-shadow: 0 24px 60px -20px rgba(40,30,10,.45); -webkit-backdrop-filter: none; backdrop-filter: none; font-family: var(--f-body); }
.af .chat-header { background: var(--sand-2); border-bottom-color: var(--rule); }
.af .chat-header-avatar { background: var(--sun); color: var(--ink); font-family: var(--f-head); }
.af .chat-header-info h3 { font-family: var(--f-head); font-size: 16px; color: var(--ink); }
.af .chat-header-info p { color: var(--muted); font-size: 12.5px; }
.af .chat-header-info .dot { background: var(--olive); }
.af .chat-close { background: var(--surface); border-color: var(--rule); color: var(--ink); }
.af .chat-close:hover { background: var(--bg); color: var(--ink); }
.af .chat-messages::-webkit-scrollbar-thumb { background: var(--ring); }
.af .chat-msg { font-size: 15px; }
.af .chat-msg.user { background: var(--sea); color: #fff; }
.af .chat-msg.assistant { background: var(--bg); color: var(--ink); border-color: var(--rule); }
.af .chat-msg.assistant a { color: var(--sea); }
.af .chat-msg.welcome { background: var(--pastel-1); border-color: var(--rule); color: var(--ink); }
.af .chat-typing { background: var(--bg); border-color: var(--rule); }
.af .chat-typing span { background: var(--muted); }
.af .chat-input-row { background: var(--bg); border-top-color: var(--rule); }
.af .chat-input { background: #fff; border-color: #8a7f6a; color: var(--ink); font-size: 16px; }
.af .chat-input:focus { border-color: var(--sea); background: #fff; outline: 2px solid var(--sea); outline-offset: 1px; }
.af .chat-input::placeholder { color: var(--muted); }
.af .chat-send { background: var(--sea); }
.af .chat-footer { background: var(--bg); color: var(--muted); font-size: 12px; }
.af .chat-footer a { color: var(--sea); }
.af .chat-error { background: #f8ddd6; border-color: #e0a090; color: #6b1f10; }
@media (max-width: 480px) {
  .af .chat-panel { left: 10px; right: 10px; bottom: 80px; }
  .af .chat-bubble { left: 14px; right: auto; bottom: 14px; }
}

/* Con la barra de cookies visible, WhatsApp y el chat suben por encima de ella */
html.con-cookie-bar .af a.af-wa, html.con-cookie-bar .af .chat-bubble { bottom: calc(var(--cookie-h, 0px) + 32px); }
/* En móvil, con la barra de cookies abierta, los dos botones flotantes taparían contenido y botones: se ocultan hasta que se decide. */
@media (max-width: 560px) { html.con-cookie-bar .af a.af-wa, html.con-cookie-bar .af .chat-bubble { visibility: hidden; } }
/* En móvil, el pie deja hueco a los dos botones flotantes para que no tapen sus enlaces */
@media (max-width: 720px) { .af-foot { padding-bottom: 84px; } }

/* «Configurar cookies»: botón con aspecto de enlace (pie y política de cookies) */
.af-linkbtn { display: inline-block; min-height: 24px; padding: 0; border: 0; background: none; color: inherit; font: inherit; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.af-foot .af-linkbtn { color: #efe6d4; }
.af-foot .af-linkbtn:hover { color: #fff; }
.af-foot .af-linkbtn:focus-visible { outline: 3px solid var(--sun-l); outline-offset: 3px; }

/* Turnstile real del formulario (se muestra solo si hay clave pública) */
.af-turnstile { min-height: 65px; }

/* Marquesina: botón de pausa (WCAG 2.2.2) */
.af-mq-bar { justify-content: flex-end; }
.af-mq-pause:focus-visible { outline: 3px solid var(--sea); outline-offset: 2px; }
.af-mq-pause[aria-pressed="true"] { background: var(--ink); color: var(--bg); }

/* Blog: categorías como enlaces y crédito de la foto */
.af-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px !important; }
.af-chips a { display: inline-flex; align-items: center; min-height: 40px; padding: 6px 14px; border-radius: 999px; border: 1.5px solid var(--rule); background: var(--surface); color: var(--ink); font-weight: 700; font-size: 15px; text-decoration: none; }
.af-chips a:hover { border-color: var(--ink); }
.af-chips a[aria-current="page"] { background: var(--sea); border-color: var(--sea); color: #fff; }
.af-post-credit { margin-top: 8px; font-size: 13.5px; color: var(--muted); text-align: right; }
.af-post-credit a { color: var(--muted); }
.af-empty { padding: clamp(24px, 4vw, 40px); border-radius: var(--r); background: var(--surface); text-align: center; }
.af-empty p + p { margin-top: 14px; }

/* Recurso: las 12 preguntas */
.af-q-list { display: grid; gap: 16px; }
.af-q { display: grid; grid-template-columns: 52px minmax(0, 1fr); gap: 10px 16px; padding: clamp(20px, 3vw, 28px); border-radius: var(--r); background: var(--surface); box-shadow: var(--shadow); }
.af-sec-alt .af-q { background: var(--bg); }
.af-q .af-num { grid-row: span 3; }
.af-q h3 { font-size: clamp(19px, 1.8vw, 22px); line-height: 1.3; }
.af-q-note { padding: 12px 16px; border-radius: 14px; background: var(--pastel-1); }
.af-q-note.af-q-signal { background: var(--pastel-3); }
.af-q-note small { display: block; margin-bottom: 2px; font-size: 12.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--olive-d); }
.af-q-note p { font-size: 16px; line-height: 1.5; color: var(--ink); }
@media (max-width: 560px) { .af-q { grid-template-columns: minmax(0, 1fr); } .af-q .af-num { grid-row: auto; } }

/* Tablas dentro del texto legal */
.af-prose .af-table-wrap { margin-top: 14px; background: var(--bg); }
.af-prose .af-table { font-size: 15.5px; }
.af-prose .af-table code { white-space: nowrap; }

/* Formulario: ayuda bajo un campo y primera capa de información de protección de datos */
.af-field-hint { margin-top: 6px !important; font-size: 15px; color: var(--muted); }
.af-form-legal { font-size: 14px; line-height: 1.5; color: var(--muted); }
.af-form-legal strong { color: var(--ink); }

/* Selector de idioma «ES · CA» (2026-11-26): discreto, junto al menú. Enlaza a la página equivalente. */
.af-lang { display: inline-flex; align-items: center; gap: 2px; flex: none; font-size: 14px; font-weight: 700; color: var(--muted); }
.af-lang a { display: inline-flex; align-items: center; justify-content: center; min-width: 32px; min-height: 32px; padding: 4px 6px; border-radius: 999px; color: var(--muted); text-decoration: none; letter-spacing: .02em; }
.af-lang a:hover { color: var(--ink); background: var(--sand-2); }
.af-lang a[aria-current="true"] { color: var(--ink); background: var(--sand-2); }
.af-post-lang { margin-top: 8px; font-weight: 600; }
