/* =============================================================
   EduBás — Estilos principales
   Paleta: blanco puro, grises neutros, negro elegante
   Tipografía: Inter (sans) + Playfair Display (serif decorativa)
   ============================================================= */

/* ── Google Fonts se cargan en header.php ─────────────────── */

/* ── Variables CSS ─────────────────────────────────────────── */
:root {
    /* Colores */
    --white:        #ffffff;
    --off-white:    #fafafa;
    --light-gray:   #f4f4f4;
    --mid-gray:     #e8e8e8;
    --border:       #e0e0e0;
    --text-dark:    #0f0f0f;
    --text-body:    #2c2c2c;
    --text-muted:   #888888;
    --text-subtle:  #b0b0b0;
    --accent:       #111111;
    --accent-hover: #000000;
    --tag-bg:       #f0f0f0;

    /* Tipografía */
    --font-sans:    'Inter', system-ui, -apple-system, sans-serif;
    --font-serif:   'Playfair Display', Georgia, 'Times New Roman', serif;

    /* Espaciado */
    --space-xs:  .25rem;
    --space-sm:  .5rem;
    --space-md:  1rem;
    --space-lg:  1.5rem;
    --space-xl:  2rem;
    --space-2xl: 3rem;
    --space-3xl: 4rem;

    /* Sombras */
    --shadow-sm:  0 1px 3px rgba(0,0,0,.06), 0 1px 2px rgba(0,0,0,.04);
    --shadow-md:  0 4px 16px rgba(0,0,0,.08), 0 2px 4px rgba(0,0,0,.04);
    --shadow-lg:  0 16px 40px rgba(0,0,0,.12), 0 8px 16px rgba(0,0,0,.06);
    --shadow-xl:  0 32px 64px rgba(0,0,0,.16);

    /* Bordes */
    --radius-sm:  4px;
    --radius:     8px;
    --radius-md:  12px;
    --radius-lg:  16px;
    --radius-xl:  24px;

    /* Transiciones */
    --t-fast:   0.15s ease;
    --t-normal: 0.25s ease;
    --t-slow:   0.4s ease;

    /* Layout */
    --max-width:    1200px;
    --content-width: 720px;
    --header-h:     64px;
}

/* ── Reset & Base ────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
    scroll-behavior: smooth;
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
    overflow-x: hidden;
    max-width: 100vw;
}

body {
    font-family: var(--font-sans);
    color: var(--text-body);
    max-width: 100vw;
    background: var(--white);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

img, video {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
    transition: color var(--t-fast), opacity var(--t-fast);
}
a:hover { opacity: .75; }

ul, ol { list-style: none; }

button { cursor: pointer; font-family: inherit; border: none; background: transparent; }

input, textarea, select {
    font-family: inherit;
    font-size: 1rem;
}

/* Skip link accesibilidad */
.skip-link {
    position: absolute;
    top: -100%;
    left: 1rem;
    background: var(--accent);
    color: #fff;
    padding: .5rem 1rem;
    border-radius: var(--radius-sm);
    z-index: 9999;
    font-size: .875rem;
    transition: top var(--t-fast);
}
.skip-link:focus { top: 1rem; }

/* ── Contenedor ─────────────────────────────────────────── */
.container {
    width: 100%;
    max-width: var(--max-width);
    margin-inline: auto;
    padding-inline: 1.25rem;
}

@media (min-width: 768px) {
    .container { padding-inline: 2rem; }
}

/* ── Header / Navegación ────────────────────────────────── */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    height: var(--header-h);
    background: rgba(255,255,255,.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    transition: box-shadow var(--t-normal);
}
.site-header.scrolled { box-shadow: var(--shadow-sm); }

.header__inner {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

/* Logo */
.header__logo {
    display: flex;
    align-items: center;
    gap: .5rem;
    font-weight: 600;
    letter-spacing: -.02em;
    color: var(--text-dark);
    flex-shrink: 0;
    opacity: 1;
    min-width: 0;
}
.header__logo:hover { opacity: .8; }

.header__logo-img {
    display: block;
    height: 75px;
    width: auto;
    max-width: 190px;
    object-fit: contain;
}

@media (max-width: 640px) {
    .header__logo-img {
        height: 55px;
        max-width: 140px;
    }
}

.logo__icon {
    font-size: 1.4rem;
    color: var(--text-dark);
    display: inline-block;
    transition: transform var(--t-normal);
}
.header__logo:hover .logo__icon { transform: rotate(45deg); }

.logo__text {
    font-size: .95rem;
    font-weight: 600;
    line-height: 1.2;
    max-width: 180px;
}

/* Navegación desktop */
.site-nav { display: none; }

@media (min-width: 900px) {
    .site-nav { display: block; }
}

.nav__list {
    display: flex;
    align-items: center;
    gap: .25rem;
}

.nav__link {
    padding: .4rem .75rem;
    border-radius: var(--radius-sm);
    font-size: .875rem;
    font-weight: 500;
    color: var(--text-muted);
    transition: color var(--t-fast), background var(--t-fast);
    white-space: nowrap;
}
.nav__link:hover,
.nav__link--active {
    color: var(--text-dark);
    opacity: 1;
    background: var(--light-gray);
}
.nav__link--active {
    font-weight: 600;
    background: var(--mid-gray);
}

/* Hamburguesa */
.nav-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: var(--radius-sm);
    color: var(--text-dark);
    transition: background var(--t-fast);
}
.nav-toggle:hover { background: var(--light-gray); }

@media (min-width: 900px) {
    .nav-toggle { display: none; }
}

.hamburger,
.hamburger::before,
.hamburger::after {
    display: block;
    width: 20px;
    height: 2px;
    background: var(--text-dark);
    border-radius: 2px;
    transition: transform var(--t-normal), opacity var(--t-fast);
}
.hamburger { position: relative; }
.hamburger::before,
.hamburger::after {
    content: '';
    position: absolute;
    left: 0;
}
.hamburger::before { top: -6px; }
.hamburger::after  { top: 6px; }

/* Estado abierto */
.nav-toggle[aria-expanded="true"] .hamburger { background: transparent; }
.nav-toggle[aria-expanded="true"] .hamburger::before { transform: rotate(45deg) translate(4px, 4px); }
.nav-toggle[aria-expanded="true"] .hamburger::after  { transform: rotate(-45deg) translate(4px, -4px); }

/* Menú móvil */
.mobile-nav {
    position: fixed;
    top: var(--header-h);
    right: 0;
    left: auto;
    width: min(320px, 90vw);
    max-width: 100%;
    height: calc(100vh - var(--header-h));
    background: var(--white);
    border-left: 1px solid var(--border);
    padding: 1.5rem;
    transform: translateX(100%);
    transition: transform var(--t-normal), visibility 0s linear var(--t-normal);
    visibility: hidden;
    pointer-events: none;
    z-index: 99;
    overflow-y: auto;
}
.mobile-nav.open {
    transform: translateX(0);
    visibility: visible;
    pointer-events: auto;
}

.mobile-nav__list { display: flex; flex-direction: column; gap: .25rem; }
.mobile-nav__link {
    display: block;
    padding: .75rem 1rem;
    border-radius: var(--radius);
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-body);
    transition: background var(--t-fast), color var(--t-fast);
}
.mobile-nav__link:hover {
    background: var(--light-gray);
    color: var(--text-dark);
    opacity: 1;
}

/* Overlay */
.nav-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.3);
    z-index: 98;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity var(--t-normal), visibility 0s linear var(--t-normal);
}
.nav-overlay.open {
    opacity: 1;
    visibility: visible;
    pointer-events: all;
}

/* Barra de progreso de lectura */
.reading-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    width: 0%;
    background: var(--text-dark);
    z-index: 200;
    transition: width .1s linear;
}

/* ── Página de Inicio — Blog Grid ────────────────────────── */
.page-hero {
    padding: var(--space-3xl) 0 var(--space-xl);
    text-align: center;
}

.page-hero__title {
    font-family: var(--font-serif);
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 700;
    color: var(--text-dark);
    letter-spacing: -.03em;
    line-height: 1.15;
    margin-bottom: var(--space-md);
}

.page-hero__sub {
    font-size: 1.05rem;
    color: var(--text-muted);
    max-width: 520px;
    margin-inline: auto;
}

/* Sección de posts */
.posts-section {
    padding: var(--space-xl) 0 var(--space-3xl);
}

/* Grid responsivo: 1 → 2 → 3 columnas */
.posts-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 640px) {
    .posts-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 1024px) {
    .posts-grid { grid-template-columns: repeat(3, 1fr); }
}

/* Tarjeta de post */
.post-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: transform var(--t-normal), box-shadow var(--t-normal), border-color var(--t-normal);
    display: flex;
    flex-direction: column;
}
.post-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: var(--mid-gray);
}

.post-card__img-wrap {
    position: relative;
    aspect-ratio: 16/10;
    overflow: hidden;
    background: var(--light-gray);
}

.post-card__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--t-slow);
}
.post-card:hover .post-card__img { transform: scale(1.04); }

.post-card__placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    background: var(--light-gray);
    color: var(--text-subtle);
}

.post-card__body {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    flex: 1;
    gap: .5rem;
}

.post-card__date {
    font-size: .75rem;
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: .06em;
}

.post-card__title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-dark);
    line-height: 1.4;
    letter-spacing: -.01em;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.post-card:hover .post-card__title { color: var(--accent); }

.post-card__excerpt {
    font-size: .875rem;
    color: var(--text-muted);
    line-height: 1.6;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.post-card__link {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    margin-top: .5rem;
    font-size: .8rem;
    font-weight: 600;
    color: var(--text-dark);
    letter-spacing: .02em;
    transition: gap var(--t-fast), opacity var(--t-fast);
}
.post-card__link:hover { gap: .6rem; opacity: .7; }
.post-card__link::after { content: '→'; }

/* ── Paginación ──────────────────────────────────────────── */
.pagination {
    padding: var(--space-xl) 0;
}

.pagination__list {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: .4rem;
}

.pagination__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 38px;
    height: 38px;
    padding: 0 .75rem;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: .875rem;
    font-weight: 500;
    color: var(--text-body);
    background: var(--white);
    transition: background var(--t-fast), border-color var(--t-fast), color var(--t-fast);
}
.pagination__btn:hover {
    background: var(--light-gray);
    border-color: var(--mid-gray);
    opacity: 1;
}
.pagination__btn--active {
    background: var(--text-dark);
    color: #fff;
    border-color: var(--text-dark);
}
.pagination__ellipsis {
    color: var(--text-muted);
    padding: 0 .25rem;
    font-size: .875rem;
}

/* ── Detalle de Post ─────────────────────────────────────── */
.post-hero {
    width: 100%;
    max-height: 440px;
    border-radius: var(--radius-lg);
    overflow: hidden;
    position: relative;
    box-shadow: var(--shadow-lg);
}
.post-hero__img {
    width: 100%;
    height: 440px;
    object-fit: cover;
}

.post-article {
    max-width: var(--content-width);
    margin-inline: auto;
    padding: var(--space-2xl) var(--space-md);
}

.post-article__meta {
    font-size: .8rem;
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: .06em;
    margin-bottom: var(--space-md);
}

.post-article__title {
    font-family: var(--font-serif);
    font-size: clamp(1.75rem, 4vw, 2.75rem);
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1.2;
    letter-spacing: -.025em;
    margin-bottom: var(--space-xl);
}

/* Contenido del artículo */
.post-content {
    font-size: 1.0625rem;
    line-height: 1.8;
    color: var(--text-body);
}

.post-content h1,
.post-content h2,
.post-content h3,
.post-content h4 {
    font-family: var(--font-serif);
    color: var(--text-dark);
    margin-top: 2em;
    margin-bottom: .75em;
    line-height: 1.3;
}
.post-content h2 { font-size: 1.5rem; }
.post-content h3 { font-size: 1.25rem; }
.post-content h4 { font-size: 1.1rem; }

.post-content p { margin-bottom: 1.5em; }

.post-content a {
    color: var(--text-dark);
    text-decoration: underline;
    text-underline-offset: 3px;
}
.post-content a:hover { opacity: .65; }

.post-content blockquote {
    border-left: 3px solid var(--text-dark);
    padding: .75rem 1.5rem;
    margin: 2em 0;
    font-style: italic;
    font-family: var(--font-serif);
    font-size: 1.15rem;
    color: var(--text-muted);
    background: var(--off-white);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.post-content ul,
.post-content ol {
    margin: 1em 0 1.5em 1.5em;
}
.post-content ul { list-style: disc; }
.post-content ol { list-style: decimal; }
.post-content li { margin-bottom: .4em; }

.post-content img {
    max-width: 100%;
    border-radius: var(--radius);
    margin: 2em auto;
    box-shadow: var(--shadow-md);
}
/* Alineación de imágenes */
.post-content img.align-left  { float: left; margin-right: 1.5em; margin-bottom: 1em; }
.post-content img.align-right { float: right; margin-left: 1.5em; margin-bottom: 1em; }
.post-content img.align-center { display: block; margin: 2em auto; }

.post-content figure {
    margin: 2em 0;
    text-align: center;
}
.post-content figcaption {
    font-size: .825rem;
    color: var(--text-muted);
    margin-top: .5rem;
    font-style: italic;
}

.post-content hr {
    border: none;
    border-top: 1px solid var(--border);
    margin: 2.5em 0;
}

/* Posts relacionados */
.related-posts {
    border-top: 1px solid var(--border);
    padding: var(--space-2xl) 0 var(--space-3xl);
}

.related-posts__title {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: var(--space-xl);
}

.related-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.25rem;
}
@media (min-width: 640px) { .related-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px)  { .related-grid { grid-template-columns: repeat(4, 1fr); } }

/* ── Galerías ────────────────────────────────────────────── */
.gallery-section { padding: var(--space-2xl) 0 var(--space-3xl); }

.gallery-filters {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
    margin-bottom: var(--space-xl);
}

.filter-btn {
    padding: .4rem .875rem;
    border: 1px solid var(--border);
    border-radius: 999px;
    font-size: .8rem;
    font-weight: 500;
    color: var(--text-muted);
    background: var(--white);
    cursor: pointer;
    transition: all var(--t-fast);
}
.filter-btn:hover,
.filter-btn--active {
    background: var(--text-dark);
    color: #fff;
    border-color: var(--text-dark);
}

.gallery-category { margin-bottom: var(--space-2xl); }

.gallery-category__title {
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 1rem;
    padding-bottom: .75rem;
    border-bottom: 1px solid var(--border);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: .75rem;
}
@media (min-width: 640px) { .gallery-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 900px)  { .gallery-grid { grid-template-columns: repeat(4, 1fr); } }
@media (min-width: 1100px) { .gallery-grid { grid-template-columns: repeat(5, 1fr); } }

.gallery-item {
    position: relative;
    aspect-ratio: 1/1;
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--light-gray);
    cursor: pointer;
}

.gallery-item__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--t-slow);
}
.gallery-item:hover .gallery-item__img { transform: scale(1.08); }

.gallery-item__overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,.5);
    display: flex;
    align-items: flex-end;
    padding: .75rem;
    opacity: 0;
    transition: opacity var(--t-normal);
}
.gallery-item:hover .gallery-item__overlay { opacity: 1; }

.gallery-item__title {
    font-size: .8rem;
    font-weight: 500;
    color: #fff;
    line-height: 1.3;
}

/* ── Lightbox ────────────────────────────────────────────── */
.lightbox {
    position: fixed;
    inset: 0;
    z-index: 1000;
    background: rgba(0,0,0,.92);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--t-normal);
}
.lightbox.open {
    opacity: 1;
    pointer-events: all;
}

.lightbox__inner {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .75rem;
}

.lightbox__img {
    max-width: 90vw;
    max-height: 80vh;
    object-fit: contain;
    border-radius: var(--radius);
    box-shadow: var(--shadow-xl);
    transition: opacity var(--t-fast);
}

.lightbox__caption {
    color: rgba(255,255,255,.75);
    font-size: .875rem;
    text-align: center;
    max-width: 600px;
}

.lightbox__close {
    position: fixed;
    top: 1rem;
    right: 1rem;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255,255,255,.15);
    color: #fff;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background var(--t-fast);
}
.lightbox__close:hover { background: rgba(255,255,255,.25); opacity: 1; }

.lightbox__nav {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255,255,255,.15);
    color: #fff;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background var(--t-fast);
}
.lightbox__nav:hover { background: rgba(255,255,255,.28); opacity: 1; }
.lightbox__nav--prev { left: 1rem; }
.lightbox__nav--next { right: 1rem; }

.lightbox__counter {
    position: fixed;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255,255,255,.6);
    font-size: .8rem;
    letter-spacing: .05em;
}

/* ── Vídeos ──────────────────────────────────────────────── */
.video-section { padding: var(--space-2xl) 0 var(--space-3xl); }

.video-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}
@media (min-width: 640px) { .video-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .video-grid { grid-template-columns: repeat(3, 1fr); } }

.video-card {
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid var(--border);
    cursor: pointer;
    transition: transform var(--t-normal), box-shadow var(--t-normal);
    background: var(--white);
}
.video-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.video-card__thumb {
    position: relative;
    aspect-ratio: 16/9;
    overflow: hidden;
    background: var(--light-gray);
}

.video-card__thumb-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--t-slow);
}
.video-card:hover .video-card__thumb-img { transform: scale(1.04); }

.video-card__play {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,.35);
    transition: background var(--t-fast);
}
.video-card:hover .video-card__play { background: rgba(0,0,0,.5); }

.play-btn {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: rgba(255,255,255,.9);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform var(--t-fast), background var(--t-fast);
}
.video-card:hover .play-btn {
    transform: scale(1.1);
    background: #fff;
}
.play-btn svg { fill: var(--text-dark); margin-left: 3px; }

.video-card__body { padding: 1rem 1.25rem 1.25rem; }

.video-card__title {
    font-size: .9rem;
    font-weight: 600;
    color: var(--text-dark);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Modal de vídeo */
.video-modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    background: rgba(0,0,0,.9);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--t-normal);
}
.video-modal.open { opacity: 1; pointer-events: all; }

.video-modal__inner {
    position: relative;
    width: 100%;
    max-width: 800px;
}

.video-modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: .75rem;
    gap: 1rem;
}

.video-modal__title {
    color: #fff;
    font-size: .95rem;
    font-weight: 500;
    flex: 1;
}

.video-modal__yt-link {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    padding: .4rem .875rem;
    border: 1px solid rgba(255,255,255,.3);
    border-radius: 999px;
    color: #fff;
    font-size: .8rem;
    font-weight: 500;
    transition: background var(--t-fast);
    white-space: nowrap;
    opacity: 1;
}
.video-modal__yt-link:hover { background: rgba(255,255,255,.15); opacity: 1; }

.video-modal__close {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255,255,255,.15);
    color: #fff;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background var(--t-fast);
    flex-shrink: 0;
}
.video-modal__close:hover { background: rgba(255,255,255,.28); opacity: 1; }

.video-modal__frame {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 */
    height: 0;
    background: #000;
    border-radius: var(--radius);
    overflow: hidden;
}
.video-modal__frame iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* ── Blogs externos ──────────────────────────────────────── */
.blogs-section { padding: var(--space-2xl) 0 var(--space-3xl); }

.blogs-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.25rem;
}
@media (min-width: 640px) { .blogs-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px)  { .blogs-grid { grid-template-columns: repeat(3, 1fr); } }

.blog-card {
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform var(--t-normal), box-shadow var(--t-normal);
    background: var(--white);
}
.blog-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.blog-card__img-wrap {
    aspect-ratio: 16/9;
    overflow: hidden;
    background: var(--light-gray);
}
.blog-card__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--t-slow);
}
.blog-card:hover .blog-card__img { transform: scale(1.04); }

.blog-card__placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: var(--text-subtle);
}

.blog-card__body {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: .5rem;
    flex: 1;
}

.blog-card__title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-dark);
    line-height: 1.4;
}

.blog-card__desc {
    font-size: .875rem;
    color: var(--text-muted);
    line-height: 1.6;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.blog-card__link {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    font-size: .8rem;
    font-weight: 600;
    color: var(--text-dark);
    margin-top: .25rem;
    transition: gap var(--t-fast);
}
.blog-card__link:hover { gap: .55rem; opacity: .7; }
.blog-card__link::after { content: '↗'; }

/* ── Sobre mí ────────────────────────────────────────────── */
.about-section { padding: var(--space-3xl) 0; }

.about-hero {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-2xl);
    align-items: center;
    margin-bottom: var(--space-3xl);
}
@media (min-width: 768px) {
    .about-hero { grid-template-columns: 1fr 1fr; }
}

.about-photo {
    aspect-ratio: 4/5;
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: var(--light-gray);
    box-shadow: var(--shadow-lg);
}
.about-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.about-photo__placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 5rem;
    color: var(--text-subtle);
}

.about-bio__label {
    font-size: .7rem;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: var(--space-md);
}

.about-bio__title {
    font-family: var(--font-serif);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1.2;
    letter-spacing: -.025em;
    margin-bottom: var(--space-lg);
}

.about-bio__text {
    font-size: 1rem;
    color: var(--text-body);
    line-height: 1.8;
}
.about-bio__text p { margin-bottom: 1em; }
.about-bio__text a {
    color: var(--text-dark);
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* Línea de tiempo */
.about-timeline { margin-bottom: var(--space-3xl); }

.section-label {
    font-size: .7rem;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: var(--space-xl);
    padding-bottom: var(--space-md);
    border-bottom: 1px solid var(--border);
}

.timeline {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.timeline-item {
    display: grid;
    grid-template-columns: 80px 1fr;
    gap: 1.5rem;
    padding: 1.25rem 0;
    border-bottom: 1px solid var(--border);
    align-items: start;
}
.timeline-item:last-child { border-bottom: none; }

.timeline-item__year {
    font-size: .85rem;
    font-weight: 700;
    color: var(--text-muted);
    padding-top: .15rem;
}

.timeline-item__title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: .25rem;
}

.timeline-item__desc {
    font-size: .875rem;
    color: var(--text-muted);
    line-height: 1.6;
}

/* Premios / Exposiciones */
.awards-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}
@media (min-width: 640px) { .awards-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px)  { .awards-grid { grid-template-columns: repeat(3, 1fr); } }

.award-card {
    padding: 1.25rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    transition: box-shadow var(--t-fast), transform var(--t-fast);
}
.award-card:hover {
    box-shadow: var(--shadow-sm);
    transform: translateY(-2px);
}
.award-card__icon { font-size: 1.5rem; margin-bottom: .5rem; }
.award-card__title { font-size: .9rem; font-weight: 600; color: var(--text-dark); margin-bottom: .25rem; }
.award-card__desc  { font-size: .8rem; color: var(--text-muted); line-height: 1.5; }

/* ── Footer ──────────────────────────────────────────────── */
.site-footer {
    border-top: 1px solid var(--border);
    background: var(--off-white);
}

.footer__inner {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: var(--space-xl) var(--space-md);
}

.footer__social {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.social-link {
    width: 52px;
    height: 52px;
    border: 1px solid var(--border);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-dark);
    background: var(--white);
    box-shadow: var(--shadow-sm);
    transition: all var(--t-fast);
}
.social-link:hover {
    background: var(--text-dark);
    color: #fff;
    border-color: var(--text-dark);
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
    opacity: 1;
}
.social-link--setup {
    width: auto;
    height: 42px;
    border-radius: var(--radius-sm);
    padding: 0 1rem;
    font-size: .85rem;
    font-weight: 500;
}

.footer__copy {
    border-top: 1px solid var(--border);
    padding-block: 1rem;
}
.footer__copy p {
    font-size: .8rem;
    color: var(--text-muted);
    text-align: center;
}

/* ── Estado vacío ─────────────────────────────────────────── */
.empty-state {
    text-align: center;
    padding: var(--space-3xl) var(--space-md);
}
.empty-state__icon { font-size: 3rem; margin-bottom: var(--space-md); }
.empty-state__title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: var(--space-sm);
}
.empty-state__text { font-size: .9rem; color: var(--text-muted); }

/* ── Utilidades ─────────────────────────────────────────── */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
}

.text-center { text-align: center; }
.mt-sm { margin-top: var(--space-sm); }
.mt-md { margin-top: var(--space-md); }
.mt-lg { margin-top: var(--space-lg); }
.mt-xl { margin-top: var(--space-xl); }

/* ── Banner Panorámico de Inicio ──────────────────────────── */
.home-banner-section {
    padding-top: var(--space-xl);
    padding-bottom: var(--space-md);
}

.home-banner-slider {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: #0f0f0f;
    min-height: 320px;
    box-shadow: var(--shadow-lg);
}

.home-banner-item {
    position: relative;
    display: none;
    width: 100%;
    min-height: 340px;
    max-height: 480px;
    aspect-ratio: 21/9;
}
.home-banner-item.active {
    display: flex;
    align-items: center;
}

.home-banner__img-wrap {
    position: absolute;
    inset: 0;
    z-index: 1;
}

.home-banner__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.home-banner__content {
    position: relative;
    z-index: 2;
    margin: var(--space-xl);
    padding: 1.25rem 1.75rem;
    max-width: 600px;
    color: #ffffff;
    background: rgba(0, 0, 0, 0.28);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    border-radius: var(--radius-md);
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.home-banner__title {
    font-family: var(--font-serif);
    font-size: clamp(1.4rem, 3vw, 2.4rem);
    font-weight: 700;
    line-height: 1.2;
    color: #ffffff;
    margin-bottom: var(--space-sm);
    text-shadow: 0 1px 6px rgba(0,0,0,0.6);
}

.home-banner__sub {
    font-size: clamp(.9rem, 1.3vw, 1.05rem);
    color: rgba(255, 255, 255, 0.95);
    line-height: 1.55;
    margin-bottom: var(--space-md);
    text-shadow: 0 1px 5px rgba(0,0,0,0.6);
}

.home-banner__btn {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    padding: .65rem 1.4rem;
    background: #ffffff;
    color: #0f0f0f;
    border-radius: var(--radius);
    font-size: .875rem;
    font-weight: 600;
    transition: transform var(--t-fast), background var(--t-fast), box-shadow var(--t-fast);
    box-shadow: 0 4px 14px rgba(0,0,0,.2);
}
.home-banner__btn:hover {
    background: #f0f0f0;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,.3);
    opacity: 1;
}

.home-banner-dots {
    display: flex;
    justify-content: center;
    gap: .5rem;
    margin-top: 1rem;
}

.banner-dot {
    width: 24px;
    height: 4px;
    border-radius: 2px;
    background: var(--border);
    border: none;
    cursor: pointer;
    transition: background var(--t-fast), width var(--t-fast);
}
.banner-dot.active {
    background: var(--text-dark);
    width: 36px;
}

