/*
Theme Name: COASING
Theme URI: https://coasingsas.com
Author: COASING S.A.S.
Description: Tema corporativo profesional para COASING - Consultoría y Asesoría en Ingenierías. Diseño elegante y moderno con la identidad de marca, sección destacada de cursos y capacitaciones, héroe con fotografía, estadísticas animadas y plantillas completas.
Version: 2.0.0
Requires at least: 6.0
Requires PHP: 7.4
License: GNU General Public License v2 or later
Text Domain: coasing
*/

/* =================== Sistema de diseño =================== */
:root {
    --ink: #0e1116;
    --ink-2: #1a1f27;
    --text: #454c59;
    --muted: #5f6875; /* AA: 5.7:1 sobre blanco (antes #7c8494, 3.8:1) */
    --red: #e2231a;
    --red-dark: #bb1810;
    --orange: #f58220;
    --yellow: #ffc400;
    --paper: #ffffff;
    --bg: #f5f6f8;
    --line: #e7e9ee;
    --radius: 16px;
    --radius-sm: 10px;
    --shadow-sm: 0 1px 2px rgba(14, 17, 22, .06), 0 2px 8px rgba(14, 17, 22, .05);
    --shadow-md: 0 2px 6px rgba(14, 17, 22, .07), 0 14px 38px rgba(14, 17, 22, .13);
    --shadow-red: 0 8px 22px rgba(226, 35, 26, .32);
    --font: "Plus Jakarta Sans", "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
    --wrap: 1200px;
    --ease: cubic-bezier(.2, .7, .2, 1);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    font-family: var(--font);
    font-size: 16.5px;
    line-height: 1.75;
    color: var(--text);
    background: var(--paper);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; }
a { color: var(--red); text-decoration: none; transition: color .2s var(--ease); }
a:hover { color: var(--red-dark); }
h1, h2, h3, h4, h5, h6 {
    color: var(--ink);
    line-height: 1.18;
    font-weight: 800;
    letter-spacing: -.025em;
    margin: 1.7em 0 .55em;
}
h1 { font-size: 2.4rem; margin-top: 0; }
h2 { font-size: 1.75rem; }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1.2em; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 28px; }

/* Franja de marca */
.brand-stripe {
    height: 4px;
    background: linear-gradient(90deg, var(--ink) 0 25%, var(--red) 25% 50%, var(--orange) 50% 75%, var(--yellow) 75% 100%);
}

/* Kicker: rótulo pequeño sobre títulos */
.kicker {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: .74rem;
    font-weight: 800;
    letter-spacing: .22em;
    text-transform: uppercase;
    color: var(--red-dark); /* AA sobre fondos claros */
}
.kicker::before {
    content: "";
    width: 26px;
    height: 3px;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--red), var(--orange));
}

/* Animación de aparición (solo si hay JavaScript) */
html.js .reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
html.js .reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
    html.js .reveal { opacity: 1; transform: none; transition: none; }
}

/* =================== Barra superior =================== */
.topbar {
    background: var(--ink);
    color: #aab1bd;
    font-size: .78rem;
    font-weight: 600;
}
.topbar-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 38px; }
.topbar a { color: #dfe3e9; }
.topbar a:hover { color: var(--yellow); }
.topbar .tb-note { letter-spacing: .04em; }
@media (max-width: 700px) { .topbar .tb-note { display: none; } .topbar-inner { justify-content: center; } }

/* =================== Cabecera =================== */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, .92);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid transparent;
    transition: box-shadow .3s var(--ease), border-color .3s;
}
.site-header.is-scrolled { box-shadow: var(--shadow-md); border-color: var(--line); }
.header-inner { display: flex; align-items: center; gap: 26px; min-height: 82px; }
.site-branding { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.site-branding img { max-height: 54px; width: auto; }
.site-title { font-size: 1.5rem; font-weight: 900; color: var(--ink); letter-spacing: .01em; }
.site-title:hover { color: var(--red); }

/* Navegación */
.main-nav { margin-left: auto; }
.main-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 2px; align-items: center; }
.main-nav li { position: relative; }
.main-nav a {
    display: block;
    padding: 10px 13px;
    font-size: .8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .07em;
    color: var(--ink-2);
    border-radius: 9px;
    transition: color .2s, background .2s;
}
.main-nav a:hover,
.main-nav .current-menu-item > a,
.main-nav .current-menu-ancestor > a { color: var(--red); background: #fbeeed; }

/* Ítem "Cursos" resaltado en el menú */
.main-nav .menu-cursos > a {
    background: linear-gradient(115deg, var(--orange), var(--yellow));
    color: var(--ink) !important;
    border-radius: 999px;
    padding: 10px 20px;
    margin-left: 8px;
    box-shadow: 0 5px 16px rgba(245, 130, 32, .35);
}
.main-nav .menu-cursos > a:hover { filter: brightness(1.06); transform: translateY(-1px); }
.main-nav .menu-whatsapp > a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #25d366;
    color: #fff !important;
    border-radius: 999px;
    padding: 10px 18px;
    margin-left: 8px;
    box-shadow: 0 5px 16px rgba(37, 211, 102, .35);
}
.main-nav .menu-whatsapp > a::before {
    content: "";
    width: 14px; height: 14px;
    background: currentColor;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M17.5 14.4c-.3-.1-1.7-.9-2-1-.3-.1-.5-.1-.7.1-.2.3-.8 1-.9 1.2-.2.2-.3.2-.6.1-.3-.1-1.3-.5-2.4-1.5-.9-.8-1.5-1.8-1.7-2.1-.2-.3 0-.5.1-.6.1-.1.3-.3.4-.5.1-.1.2-.3.3-.4.1-.2 0-.4 0-.5C10 9 9.4 7.6 9.2 7c-.2-.5-.4-.5-.6-.5h-.5c-.2 0-.5.1-.7.3-.2.3-1 1-1 2.3s1 2.7 1.1 2.9c.1.2 2 3.1 4.9 4.3.7.3 1.2.5 1.6.6.7.2 1.3.2 1.8.1.5-.1 1.7-.7 1.9-1.3.2-.7.2-1.2.2-1.3-.1-.1-.3-.2-.6-.3z'/%3E%3Cpath d='M12 2C6.5 2 2 6.5 2 12c0 1.9.5 3.7 1.5 5.3L2 22l4.8-1.5c1.5.8 3.3 1.3 5.2 1.3 5.5 0 10-4.5 10-10S17.5 2 12 2zm0 18c-1.7 0-3.3-.5-4.7-1.3l-.3-.2-3.2 1 1-3.1-.2-.3C3.8 14.7 3.3 13.4 3.3 12c0-4.8 3.9-8.7 8.7-8.7s8.7 3.9 8.7 8.7-3.9 8.7-8.7 8.7z'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M17.5 14.4c-.3-.1-1.7-.9-2-1-.3-.1-.5-.1-.7.1-.2.3-.8 1-.9 1.2-.2.2-.3.2-.6.1-.3-.1-1.3-.5-2.4-1.5-.9-.8-1.5-1.8-1.7-2.1-.2-.3 0-.5.1-.6.1-.1.3-.3.4-.5.1-.1.2-.3.3-.4.1-.2 0-.4 0-.5C10 9 9.4 7.6 9.2 7c-.2-.5-.4-.5-.6-.5h-.5c-.2 0-.5.1-.7.3-.2.3-1 1-1 2.3s1 2.7 1.1 2.9c.1.2 2 3.1 4.9 4.3.7.3 1.2.5 1.6.6.7.2 1.3.2 1.8.1.5-.1 1.7-.7 1.9-1.3.2-.7.2-1.2.2-1.3-.1-.1-.3-.2-.6-.3z'/%3E%3Cpath d='M12 2C6.5 2 2 6.5 2 12c0 1.9.5 3.7 1.5 5.3L2 22l4.8-1.5c1.5.8 3.3 1.3 5.2 1.3 5.5 0 10-4.5 10-10S17.5 2 12 2zm0 18c-1.7 0-3.3-.5-4.7-1.3l-.3-.2-3.2 1 1-3.1-.2-.3C3.8 14.7 3.3 13.4 3.3 12c0-4.8 3.9-8.7 8.7-8.7s8.7 3.9 8.7 8.7-3.9 8.7-8.7 8.7z'/%3E%3C/svg%3E") center / contain no-repeat;
}
.main-nav .menu-whatsapp > a:hover { background: #1eb958; filter: none; transform: translateY(-1px); }

/* Submenús */
.main-nav .sub-menu {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    min-width: 270px;
    background: var(--paper);
    border-radius: 14px;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--line);
    border-top: 3px solid var(--red);
    padding: 8px;
    display: none;
    flex-direction: column;
    z-index: 60;
}
.main-nav li:hover > .sub-menu,
.main-nav li:focus-within > .sub-menu { display: flex; }
.main-nav .sub-menu::before { content: ""; position: absolute; top: -12px; left: 0; right: 0; height: 12px; }
.main-nav .sub-menu a { text-transform: none; letter-spacing: 0; font-size: .89rem; font-weight: 600; padding: 9px 13px; }
.main-nav .sub-menu .sub-menu { top: 0; left: 100%; border-top: 1px solid var(--line); border-left: 3px solid var(--orange); }
.menu-item-has-children > a::after { content: " ▾"; font-size: .68em; opacity: .5; }

/* Menú móvil */
.nav-toggle {
    display: none;
    margin-left: auto;
    background: none;
    border: 2px solid var(--line);
    border-radius: 10px;
    padding: 7px 12px;
    font-size: 1.15rem;
    cursor: pointer;
    color: var(--ink);
}
@media (max-width: 1020px) {
    .nav-toggle { display: block; }
    .main-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--paper);
        box-shadow: var(--shadow-md);
        padding: 14px 22px 24px;
        max-height: calc(100vh - 120px);
        overflow: auto;
        border-top: 1px solid var(--line);
    }
    .main-nav.is-open { display: block; }
    .main-nav ul { flex-direction: column; align-items: stretch; gap: 0; }
    .main-nav .menu-cursos > a,
    .main-nav .menu-whatsapp > a { 
        margin: 10px 0 0; 
        justify-content: center; 
        width: 100%;       
        display: flex; 
    }
    .main-nav .sub-menu {
        position: static;
        display: none;
        box-shadow: none;
        border: none;
        border-left: 3px solid var(--line);
        border-radius: 0;
        margin-left: 12px;
        padding: 0 0 0 4px;
    }
    .main-nav li.is-open > .sub-menu { display: flex; }
}

/* =================== Héroe =================== */
.hero {
    position: relative;
    background:
        radial-gradient(820px 420px at 88% -10%, rgba(245, 130, 32, .16), transparent 60%),
        radial-gradient(700px 420px at -8% 110%, rgba(226, 35, 26, .14), transparent 60%),
        linear-gradient(150deg, #0e1116 0%, #171c24 55%, #1d1a14 100%);
    color: #fff;
    overflow: hidden;
}
.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px);
    background-size: 44px 44px;
    mask-image: radial-gradient(720px 480px at 30% 40%, #000 30%, transparent 75%);
}
.hero-grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1.05fr .95fr;
    gap: 56px;
    align-items: center;
    padding: 84px 0 92px;
}
@media (max-width: 980px) { .hero-grid { grid-template-columns: 1fr; padding: 60px 0 68px; } }
.hero .kicker { color: var(--yellow); }
.hero .kicker::before { background: linear-gradient(90deg, var(--yellow), var(--orange)); }
.hero h1 {
    color: #fff;
    font-size: clamp(2.1rem, 4.6vw, 3.3rem);
    font-weight: 800;
    margin: 18px 0 20px;
}
.hero h1 .hl {
    background: linear-gradient(100deg, var(--yellow), var(--orange) 60%, var(--red));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
.hero-sub { color: #b9c0cb; font-size: 1.12rem; max-width: 540px; margin-bottom: 32px; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 34px; }
.hero-trust { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.hero-trust .label { font-size: .72rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: #8b93a1; margin-right: 6px; }
.hero-trust .chip {
    font-size: .74rem;
    font-weight: 800;
    color: #e8ebef;
    border: 1px solid rgba(255, 255, 255, .18);
    background: rgba(255, 255, 255, .05);
    padding: 5px 13px;
    border-radius: 999px;
    letter-spacing: .04em;
}

/* Imagen del héroe */
.hero-media { position: relative; }
.hero-media .frame {
    position: relative;
    border-radius: 22px;
    overflow: hidden;
    box-shadow: 0 30px 70px rgba(0, 0, 0, .5);
    aspect-ratio: 1000 / 667;
}
.hero-media .frame::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(200deg, transparent 55%, rgba(14, 17, 22, .55));
}

.hero-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
@media (max-width: 980px) { .hero-media .frame { aspect-ratio: 1000 / 667; } }
.hero-media .accent {
    position: absolute;
    width: 120px;
    height: 120px;
    border-radius: 26px;
    z-index: -1;
}
.hero-media .accent.a1 { top: -22px; right: -22px; background: linear-gradient(135deg, var(--orange), var(--yellow)); opacity: .9; }
.hero-media .accent.a2 { bottom: -22px; left: -22px; background: linear-gradient(135deg, var(--red), var(--orange)); opacity: .85; }
.hero-badge {
    position: absolute;
    left: 26px;
    bottom: 26px;
    z-index: 2;
    background: rgba(255, 255, 255, .96);
    color: var(--ink);
    border-radius: 14px;
    padding: 14px 20px;
    box-shadow: var(--shadow-md);
    display: flex;
    align-items: center;
    gap: 12px;
}
.hero-badge .dot {
    width: 42px; height: 42px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--red), var(--orange));
    display: grid;
    place-items: center;
    color: #fff;
    flex-shrink: 0;
}
.hero-badge strong { display: block; font-size: .95rem; line-height: 1.25; }
.hero-badge span { font-size: .76rem; color: var(--muted); font-weight: 600; }

/* =================== Botones =================== */
.btn, .button, .wp-block-button__link,
.entry-content .button, .entry-content .wp-block-button__link {
    display: inline-block;
    background: linear-gradient(120deg, var(--red), #f04a1e);
    color: #fff !important;
    padding: 14px 32px;
    border-radius: 999px;
    font-weight: 800;
    font-size: .92rem;
    letter-spacing: .01em;
    border: none;
    cursor: pointer;
    box-shadow: var(--shadow-red);
    transition: transform .2s var(--ease), box-shadow .2s, filter .2s;
}
.btn:hover, .button:hover, .wp-block-button__link:hover { filter: brightness(1.08); transform: translateY(-2px); box-shadow: 0 12px 28px rgba(226, 35, 26, .4); }
.btn-outline { background: transparent; border: 2px solid rgba(255, 255, 255, .5); box-shadow: none; color: #fff !important; }
.btn-outline:hover { background: rgba(255, 255, 255, .1); filter: none; }
.btn-outline.dark { border-color: var(--line); color: var(--ink) !important; }
.btn-outline.dark:hover { background: var(--bg); }
.btn-dark { background: var(--ink); box-shadow: 0 8px 22px rgba(14, 17, 22, .3); }
.wa-btn { background: #0e7a43; box-shadow: 0 8px 22px rgba(14, 122, 67, .35); display: inline-flex; align-items: center; gap: 9px; } /* AA: 5.5:1 con texto blanco (antes #25d366, 2:1) */
.wa-btn:hover { background: #0b6236; }

/* =================== Banda de estadísticas =================== */
.stats-band { background: var(--paper); border-bottom: 1px solid var(--line); }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); }
@media (max-width: 860px) { .stats-grid { grid-template-columns: repeat(2, 1fr); } }
.stat {
    text-align: center;
    padding: 34px 18px;
    border-left: 1px solid var(--line);
}
.stat:first-child { border-left: none; }
@media (max-width: 860px) { .stat:nth-child(3) { border-left: none; } .stat { padding: 26px 14px; } }
.stat .num {
    font-size: 2.3rem;
    font-weight: 800;
    letter-spacing: -.03em;
    color: var(--ink);
    line-height: 1.1;
}
.stat .num em { font-style: normal; color: var(--red); }
.stat .lbl { font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .12em; color: var(--muted); margin-top: 6px; }

/* =================== Secciones =================== */
.section { padding: 88px 0; }
.section-alt { background: var(--bg); }
.section-head { max-width: 660px; margin: 0 0 48px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head.center .kicker { justify-content: center; }
.section-head h2 { font-size: clamp(1.7rem, 3vw, 2.25rem); margin: 14px 0 10px; }
.section-head p { color: var(--muted); margin: 0; }

/* =================== Tarjetas de servicio =================== */
.card-grid { display: flex; flex-wrap: wrap; gap: 28px; justify-content: center; }
.card-grid > * { flex: 0 1 calc(33.333% - 19px); }
.card-grid--featured { display: grid; grid-template-columns: repeat(2, 1fr); }
@media (max-width: 980px) { .card-grid > * { flex: 0 1 calc(50% - 14px); } }
@media (max-width: 640px) { .card-grid > * { flex: 0 1 100%; } .card-grid--featured { grid-template-columns: 1fr; } }
.card {
    background: var(--paper);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--line);
    display: flex;
    flex-direction: column;
    transition: transform .25s var(--ease), box-shadow .25s;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }
.card-media { display: block; aspect-ratio: 16/10; overflow: hidden; background: linear-gradient(135deg, #171c24, #2c333f); position: relative; }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.card:hover .card-media img { transform: scale(1.06); }
.card-body { padding: 24px 26px 28px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.card-badge {
    align-self: flex-start;
    font-size: .66rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .1em;
    color: var(--red-dark); /* AA: 5.7:1 sobre #fbeeed */
    background: #fbeeed;
    padding: 4px 12px;
    border-radius: 999px;
}
.card h3 { margin: 0; font-size: 1.1rem; line-height: 1.35; }
.card h3 a { color: var(--ink); }
.card h3 a:hover { color: var(--red); }
.card p { margin: 0; font-size: .9rem; color: var(--muted); flex: 1; }
.card-more { font-size: .82rem; font-weight: 800; color: var(--red); letter-spacing: .02em; }
.card-more::after { content: " →"; transition: margin .2s; }
.card:hover .card-more::after { margin-left: 4px; }

/* Tarjetas de línea de servicio */
.cat-card {
    position: relative;
    background: var(--paper);
    border-radius: var(--radius);
    padding: 34px 30px 30px;
    border: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
    transition: transform .25s var(--ease), box-shadow .25s;
    display: block;
    overflow: hidden;
}
.cat-card::before {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 4px;
    background: var(--accent, var(--red));
}
.cat-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }
.cat-icon {
    width: 54px; height: 54px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    margin-bottom: 18px;
    color: #fff;
    background: var(--accent, var(--red));
    box-shadow: 0 8px 18px color-mix(in srgb, var(--accent, var(--red)) 40%, transparent);
}
.cat-icon svg { width: 26px; height: 26px; }
.cat-card h3 { margin: 0 0 8px; font-size: 1.14rem; }
.cat-card p { margin: 0 0 14px; font-size: .89rem; color: var(--muted); }
.cat-card .count { font-size: .76rem; font-weight: 800; color: var(--ink); text-transform: uppercase; letter-spacing: .08em; }
.cat-card .count::after { content: " →"; color: var(--red); }

/* =================== Sección Quiénes somos =================== */
.about-grid { display: grid; grid-template-columns: .95fr 1.05fr; gap: 56px; align-items: center; }
@media (max-width: 900px) { .about-grid { grid-template-columns: 1fr; gap: 36px; } }
.about-media { position: relative; }
.about-media img { display: block; width: 100%; height: auto; max-height: 480px; object-fit: contain; border-radius: var(--radius); box-shadow: var(--shadow-md); background: var(--bg); }
.about-badge {
    position: absolute;
    right: -18px; bottom: -18px;
    background: var(--ink);
    color: #fff;
    border-radius: 16px;
    padding: 18px 22px;
    box-shadow: var(--shadow-md);
    text-align: center;
    border: 4px solid var(--paper);
}
.about-badge strong { display: block; font-size: 1.8rem; font-weight: 800; background: linear-gradient(100deg, var(--yellow), var(--orange)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.about-badge span { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: #c6ccd5; }
.about-list { list-style: none; margin: 22px 0 30px; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.about-list li { position: relative; padding-left: 30px; font-weight: 600; color: var(--ink-2); font-size: .96rem; }
.about-list li::before {
    content: "";
    position: absolute; left: 0; top: 2px;
    width: 20px; height: 20px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--red), var(--orange));
}
.about-list li::after {
    content: "";
    position: absolute; left: 6px; top: 7px;
    width: 8px; height: 4px;
    border-left: 2px solid #fff; border-bottom: 2px solid #fff;
    transform: rotate(-45deg);
}

/* =================== Misión / Visión (tarjetas) =================== */
.value-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
@media (max-width: 720px) { .value-grid { grid-template-columns: 1fr; } }
.value-card {
    background: linear-gradient(150deg, #0e1116, #1a2029);
    color: #fff;
    border-radius: var(--radius);
    padding: 32px 30px;
}
.value-card .vc-icon {
    width: 48px; height: 48px;
    border-radius: 12px;
    display: grid; place-items: center;
    background: linear-gradient(135deg, var(--red), var(--orange));
    margin-bottom: 16px;
}
.value-card h3 { color: #fff; margin: 0 0 10px; font-size: 1.2rem; }
.value-card p { color: #b9c0cb; font-size: .92rem; margin: 0; }

.courses-cta-light {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 28px 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
    background: var(--bg);
}
.courses-cta-light strong { display: block; font-size: 1.05rem; color: var(--ink); }
.courses-cta-light span { color: var(--muted); font-size: .9rem; }

/* =================== Galería "Nuestra Experiencia" =================== */
.exp-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
@media (max-width: 980px) { .exp-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .exp-grid { grid-template-columns: 1fr; } }
.exp-card {
    position: relative;
    margin: 0;
    aspect-ratio: 4/5;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}
.exp-card img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s var(--ease); }
.exp-card:hover img { transform: scale(1.08); }
.exp-card figcaption {
    position: absolute;
    left: 0; right: 0; bottom: 0;
    padding: 16px 16px 14px;
    background: linear-gradient(0deg, rgba(14, 17, 22, .92), transparent 85%);
    color: #fff;
    font-size: .85rem;
    font-weight: 700;
    line-height: 1.35;
}

/* Estado vacío (secciones sin entradas todavía) */
.empty-state {
    text-align: center;
    max-width: 480px;
    margin: 0 auto;
    padding: 56px 32px;
    border: 1px dashed var(--line);
    border-radius: var(--radius);
    background: var(--bg);
}
.empty-state .es-icon {
    width: 60px; height: 60px;
    margin: 0 auto 20px;
    border-radius: 50%;
    display: grid; place-items: center;
    background: linear-gradient(135deg, var(--red), var(--orange));
    color: #fff;
}
.empty-state h3 { margin: 0 0 10px; font-size: 1.2rem; }
.empty-state p { color: var(--muted); font-size: .92rem; margin: 0 0 24px; }

/* =================== Equipo (tarjetas de colaboradores) =================== */
.team-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 26px; }
@media (max-width: 980px) { .team-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .team-grid { grid-template-columns: 1fr; max-width: 320px; margin: 0 auto; } }
.team-card {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: transform .25s var(--ease), box-shadow .25s;
}
.team-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }
.team-photo { aspect-ratio: 1/1; overflow: hidden; background: linear-gradient(135deg, #171c24, #2c333f); }
.team-photo img { width: 100%; height: 100%; object-fit: cover; object-position: top center; transition: transform .4s var(--ease); }
.team-card:hover .team-photo img { transform: scale(1.05); }
.team-body { padding: 18px 20px 22px; border-top: 3px solid var(--red); }
.team-body h3 { margin: 0 0 6px; font-size: 1rem; line-height: 1.3; }
.team-body p { margin: 0; font-size: .8rem; color: var(--muted); line-height: 1.55; }

/* =================== Catálogo de cursos, agrupado por área =================== */
.courses-catalog-page { padding-top: 76px; }
.catalog-group { margin-bottom: 64px; }
.catalog-group:last-of-type { margin-bottom: 0; }
.catalog-group-head {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 28px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--line);
}
.catalog-group-head .cg-icon {
    width: 42px; height: 42px;
    flex-shrink: 0;
    border-radius: 12px;
    display: grid; place-items: center;
    background: color-mix(in srgb, var(--accent) 16%, transparent);
    color: var(--accent);
}
.catalog-group-head h2 { margin: 0; font-size: 1.25rem; color: var(--ink); }
.catalog-group-head .cg-count {
    margin-left: auto;
    font-size: .76rem;
    font-weight: 800;
    color: var(--accent);
    background: color-mix(in srgb, var(--accent) 16%, transparent);
    padding: 5px 13px;
    border-radius: 999px;
}

/* =================== Página de Contacto =================== */
.contact-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 32px; align-items: start; }
@media (max-width: 900px) { .contact-grid { grid-template-columns: 1fr; } }
.contact-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 560px) { .contact-cards { grid-template-columns: 1fr; } }
.contact-card {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 22px;
    box-shadow: var(--shadow-sm);
    transition: transform .2s var(--ease), box-shadow .2s, border-color .2s;
}
.contact-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: transparent; }
.contact-card .cc-icon {
    width: 44px; height: 44px;
    flex-shrink: 0;
    border-radius: 12px;
    display: grid;
    place-items: center;
    background: var(--bg);
    color: var(--red);
}
.contact-card.wa .cc-icon { background: #e9fbf1; color: #1eb958; }
.contact-card strong { display: block; font-size: .92rem; color: var(--ink); margin-bottom: 3px; }
.contact-card span { font-size: .85rem; color: var(--muted); word-break: break-word; }
.contact-panel {
    background: linear-gradient(150deg, #0e1116, #1a2029);
    color: #fff;
    border-radius: var(--radius);
    padding: 40px 34px;
}
.contact-panel .kicker { color: var(--yellow); }
.contact-panel .kicker::before { background: linear-gradient(90deg, var(--yellow), var(--orange)); }
.contact-panel h2 { color: #fff; font-size: 1.5rem; margin: 14px 0 12px; }
.contact-panel p { color: #b9c0cb; font-size: .94rem; margin-bottom: 26px; }
.contact-social { display: flex; align-items: center; gap: 12px; margin-top: 26px; }
.contact-social span { font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: #8b93a1; }
.contact-social a { width: 36px; height: 36px; border-radius: 50%; background: rgba(255,255,255,.08); display: grid; place-items: center; color: #fff; }
.contact-social a:hover { background: var(--red); }

/* =================== Sección CURSOS (portada: fondo oscuro) =================== */
.courses {
    position: relative;
    background:
        radial-gradient(700px 380px at 105% 0%, rgba(255, 196, 0, .12), transparent 60%),
        radial-gradient(600px 380px at -5% 100%, rgba(226, 35, 26, .12), transparent 60%),
        linear-gradient(150deg, #0e1116, #191d16 70%, #1d1a10);
    color: #fff;
    padding: 92px 0;
    overflow: hidden;
}
.courses .kicker { color: var(--yellow); }
.courses .kicker::before { background: linear-gradient(90deg, var(--yellow), var(--orange)); }
.courses .section-head h2 { color: #fff; }
.courses .section-head p { color: #a7aeba; }
.courses-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; flex-wrap: wrap; margin-bottom: 48px; }
.courses-head .section-head { margin: 0; }
.course-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
@media (max-width: 980px) { .course-grid { grid-template-columns: 1fr; } }
.course-card {
    position: relative;
    background: rgba(255, 255, 255, .045);
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: var(--radius);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform .3s var(--ease), border-color .3s, background .3s, box-shadow .3s;
    backdrop-filter: blur(4px);
}
.course-card:hover { transform: translateY(-8px); border-color: rgba(255, 196, 0, .5); background: rgba(255, 255, 255, .07); box-shadow: 0 20px 44px rgba(0, 0, 0, .4); }
.course-media { position: relative; display: block; aspect-ratio: 16/10; overflow: hidden; }
.curso-cover { display: block; width: 100%; height: 100%; transform: scale(1.01); transition: transform .5s var(--ease); }
.course-card:hover .curso-cover { transform: scale(1.07); }
.course-flag {
    position: absolute;
    top: 14px; right: 14px;
    z-index: 2;
    background: rgba(14, 17, 22, .55);
    backdrop-filter: blur(6px);
    border: 1px solid rgba(255, 255, 255, .25);
    color: #fff;
    font-size: .65rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .1em;
    padding: 6px 13px;
    border-radius: 999px;
}
.course-body { padding: 22px 24px 26px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.course-body h3 { margin: 0; font-size: 1.08rem; line-height: 1.35; color: #fff; }
.course-card:hover .course-body h3 { color: var(--yellow); }
.course-body p { margin: 0; font-size: .87rem; color: #a7aeba; flex: 1; }
.course-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-top: 4px;
    padding-top: 14px;
    border-top: 1px solid rgba(255, 255, 255, .1);
    color: #25d366;
}
.course-meta .course-cta-link { font-size: .78rem; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; }
.course-meta svg { flex-shrink: 0; transition: transform .25s var(--ease); }
.course-card:hover .course-meta svg { transform: translateX(4px); }
.courses-cta {
    margin-top: 52px;
    border: 1px dashed rgba(255, 255, 255, .25);
    border-radius: var(--radius);
    padding: 30px 36px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 22px;
    flex-wrap: wrap;
    background: rgba(255, 255, 255, .03);
}
.courses-cta p { margin: 0; }
.courses-cta strong { font-size: 1.15rem; color: #fff; display: block; }
.courses-cta span { color: #a7aeba; font-size: .92rem; }

/* =================== Catálogo completo de cursos (página propia: fondo blanco) =================== */
.courses-catalog-page {
    background: var(--paper);
    color: var(--text);
}
.courses-catalog-page .kicker { color: var(--red); }
.courses-catalog-page .kicker::before { background: linear-gradient(90deg, var(--red), var(--orange)); }
.courses-catalog-page .section-head h2,
.courses-catalog-page .courses-cta strong { color: var(--ink); }
.courses-catalog-page .section-head p,
.courses-catalog-page .courses-cta span { color: var(--muted); }
.courses-catalog-page .course-card {
    background: var(--paper);
    border-color: var(--line);
    backdrop-filter: none;
    box-shadow: var(--shadow-sm);
}
.courses-catalog-page .course-card:hover {
    border-color: transparent;
    background: var(--paper);
    box-shadow: var(--shadow-md);
}
.courses-catalog-page .course-body h3 { color: var(--ink); }
.courses-catalog-page .course-card:hover .course-body h3 { color: var(--red); }
.courses-catalog-page .course-body p { color: var(--muted); }
.courses-catalog-page .course-meta { border-top-color: var(--line); color: #1eb958; }
.courses-catalog-page .courses-cta { border-color: var(--line); background: var(--bg); }

/* =================== Cabecera de página =================== */
.page-hero {
    background:
        radial-gradient(560px 300px at 92% -20%, rgba(245, 130, 32, .18), transparent 60%),
        linear-gradient(150deg, #0e1116, #1a2029);
    color: #fff;
    padding: 62px 0;
    position: relative;
    overflow: hidden;
}
.page-hero .wrap { position: relative; z-index: 1; }
.page-hero h1 { color: #fff; margin: 0; font-size: clamp(1.6rem, 3.4vw, 2.4rem); }
.page-hero .crumbs { font-size: .8rem; font-weight: 600; color: #8b93a1; margin-bottom: 12px; letter-spacing: .02em; }
.page-hero .crumbs a { color: #c6ccd5; }
.page-hero .crumbs a:hover { color: var(--yellow); }
.page-hero .desc { color: #b9c0cb; max-width: 740px; margin: 14px 0 0; }

/* =================== Contenido =================== */
.content-area { padding: 64px 0 88px; }
.entry-content { max-width: 800px; margin: 0 auto; }
.entry-content h1 { font-size: 1.8rem; }
.entry-content h2 { position: relative; padding-bottom: 12px; }
.entry-content h2::after {
    content: "";
    position: absolute;
    left: 0; bottom: 0;
    width: 44px; height: 3px;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--red), var(--orange));
}
.entry-content img { border-radius: var(--radius); }
.entry-content figure { margin: 2.2em auto; text-align: center; }
.entry-content figcaption { font-size: .84rem; color: var(--muted); margin-top: 10px; }
.entry-content ul { padding-left: 1.3em; }
.entry-content ul li { margin-bottom: .5em; }
.entry-content ul li::marker { color: var(--red); }
.entry-content blockquote {
    margin: 2.2em 0;
    padding: 22px 30px;
    background: var(--bg);
    border-left: 4px solid var(--orange);
    border-radius: 0 var(--radius) var(--radius) 0;
    font-style: italic;
}
.entry-content blockquote cite { display: block; margin-top: 10px; font-style: normal; font-weight: 700; color: var(--ink); }
.entry-content hr {
    border: none; height: 3px; width: 90px;
    margin: 2.6em 0; border-radius: 2px;
    background: linear-gradient(90deg, var(--red), var(--orange), var(--yellow));
}
.entry-content table { width: 100%; border-collapse: collapse; margin: 1.8em 0; font-size: .95rem; }
.entry-content th, .entry-content td { border: 1px solid var(--line); padding: 11px 15px; text-align: left; }
.entry-content th { background: var(--bg); color: var(--ink); }
.entry-content iframe { max-width: 100%; border-radius: var(--radius); }

.entry-thumb { max-width: 800px; margin: 0 auto 40px; }
.entry-thumb img { width: 100%; border-radius: var(--radius); box-shadow: var(--shadow-md); }
.entry-thumb .curso-cover { display: block; width: 100%; height: 320px; border-radius: var(--radius); box-shadow: var(--shadow-md); }
.entry-thumb-equipo { max-width: 320px; }
.entry-thumb-equipo img { aspect-ratio: 1/1; object-fit: cover; }

.entry-meta { font-size: .8rem; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; font-weight: 700; }
.entry-meta a { color: var(--orange); }
.tag-list { max-width: 800px; margin: 44px auto 0; display: flex; flex-wrap: wrap; gap: 8px; }
.tag-list a {
    font-size: .76rem;
    font-weight: 700;
    background: var(--bg);
    border: 1px solid var(--line);
    color: var(--text);
    padding: 6px 15px;
    border-radius: 999px;
    transition: all .2s;
}
.tag-list a:hover { border-color: var(--red); color: var(--red); background: #fbeeed; }

/* =================== Banda CTA =================== */
.cta-band {
    position: relative;
    background: linear-gradient(115deg, var(--red-dark), var(--red) 45%, var(--orange));
    color: #fff;
    text-align: center;
    padding: 76px 0;
    overflow: hidden;
}
.cta-band::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: linear-gradient(rgba(255,255,255,.05) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.05) 1px, transparent 1px);
    background-size: 40px 40px;
}
.cta-band .wrap { position: relative; }
.cta-band h2 { color: #fff; margin: 0 0 12px; font-size: clamp(1.6rem, 3vw, 2.1rem); }
.cta-band p { margin: 0 auto 30px; max-width: 560px; color: rgba(255, 255, 255, .92); }
.cta-band .btn { background: #fff; color: var(--red) !important; box-shadow: 0 10px 26px rgba(0, 0, 0, .25); }
.cta-band .btn:hover { background: var(--ink); color: #fff !important; }

/* =================== Paginación =================== */
.pagination { display: flex; gap: 8px; justify-content: center; margin-top: 52px; }
.pagination .page-numbers {
    padding: 10px 17px;
    border-radius: 12px;
    border: 1px solid var(--line);
    font-weight: 700;
    font-size: .88rem;
    color: var(--ink);
    transition: all .2s;
}
.pagination .page-numbers.current, .pagination .page-numbers:hover { background: var(--red); color: #fff; border-color: var(--red); }

/* =================== Pie de página =================== */
.site-footer { background: var(--ink); color: #9aa1ad; }
.footer-grid { display: grid; grid-template-columns: 2.2fr 1fr 1fr; gap: 48px; padding: 70px 0 52px; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr; gap: 32px; } }
.footer-grid h4 { color: #fff; font-size: .78rem; text-transform: uppercase; letter-spacing: .16em; margin: 0 0 18px; }
.footer-brand { font-size: 1.45rem; font-weight: 900; color: #fff; letter-spacing: .01em; margin-bottom: 12px; }
.footer-brand span { color: var(--red); }
.footer-grid p { font-size: .9rem; margin: 0 0 8px; line-height: 1.7; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; }
.footer-grid li { margin-bottom: 10px; }
.footer-grid a { color: #9aa1ad; font-size: .9rem; transition: color .2s, padding .2s; }
.footer-grid a:hover { color: var(--yellow); padding-left: 3px; }
.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, .08);
    padding: 22px 0;
    font-size: .8rem;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
}
.footer-bottom a { color: #9aa1ad; }

/* =================== Utilidades =================== */
/* Elementos semánticos: neutralizan los estilos por defecto del navegador
   para que ul/li/address rindan idéntico a los div/span que sustituyen. */
ul.stats-grid { list-style: none; margin: 0; padding: 0; }
.hero-trust-list { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; list-style: none; margin: 0; padding: 0; }
.topbar address, .site-footer address { font-style: normal; }
.topbar address { display: inline; }
.footer-grid nav { display: block; }

.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px, 1px, 1px, 1px); }
.skip-link:focus {
    position: fixed !important;
    top: 8px;
    left: 8px;
    z-index: 1000;
    width: auto;
    height: auto;
    clip: auto;
    padding: 12px 20px;
    background: var(--ink);
    color: #fff;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-md);
    text-decoration: none;
    font-weight: 700;
}
.aligncenter { display: block; margin: 0 auto; }
.alignleft { float: left; margin: 0 26px 18px 0; }
.alignright { float: right; margin: 0 0 18px 26px; }
@media (max-width: 640px) { .alignleft, .alignright { float: none; margin: 18px 0; } }
.error-404 { text-align: center; padding: 100px 24px; }
.error-404 h1 {
    font-size: 6rem; margin: 0;
    background: linear-gradient(120deg, var(--red), var(--orange), var(--yellow));
    -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
