/* ═══════════════════════════════════════════════
   ECOS — Gallery page
   ═══════════════════════════════════════════════ */

/* ── Hero ─────────────────────────────────────── */
.gallery-hero {
    position: relative;
    min-height: 70vh;
    display: flex;
    align-items: flex-end;
    padding: 0 24px 70px;
    overflow: hidden;
    background: linear-gradient(135deg, var(--ecos-blue, #06177E) 0%, var(--ecos-blue-dark, #05165E) 100%);
}
.gallery-hero-overlay {
    position: absolute; inset: 0;
    background: radial-gradient(circle at 75% 30%, rgba(250,192,24,.14), transparent 55%);
}
.gallery-hero-content { position: relative; z-index: 1; max-width: 640px; }
.gh-badge {
    display: inline-block; background: var(--ecos-yellow, #FAC018); color: var(--ecos-blue, #06177E);
    font-family: var(--font-title, 'Novecento Sans Wide', sans-serif); font-size: 12px; font-weight: 700;
    letter-spacing: .08em; text-transform: uppercase; padding: 7px 16px; border-radius: 999px; margin-bottom: 20px;
}
.gallery-hero-content h1 {
    font-family: var(--font-title, 'Novecento Sans Wide', sans-serif); font-size: clamp(34px, 5vw, 58px);
    line-height: 1.05; color: #fff; text-transform: uppercase; margin: 0 0 18px;
}
.gallery-hero-content h1 em { font-style: normal; color: var(--ecos-yellow, #FAC018); }
.gallery-hero-content p { color: rgba(255,255,255,.85); font-size: 15.5px; line-height: 1.6; margin: 0; max-width: 480px; }
.gh-scroll {
    position: absolute; bottom: 24px; left: 50%; transform: translateX(-50%);
    display: flex; flex-direction: column; align-items: center; gap: 8px;
    color: rgba(255,255,255,.7); font-size: 11px; text-transform: uppercase; letter-spacing: .08em;
}
.gh-scroll-line { width: 1px; height: 34px; background: rgba(255,255,255,.4); position: relative; overflow: hidden; }
.gh-scroll-line::after {
    content: ''; position: absolute; top: -100%; left: 0; width: 100%; height: 100%;
    background: var(--ecos-yellow, #FAC018); animation: ghScroll 1.8s ease-in-out infinite;
}
@keyframes ghScroll { 0% { top: -100%; } 100% { top: 100%; } }

/* ── Stats ────────────────────────────────────── */
.gh-stats {
    display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 28px;
    padding: 34px 24px; background: #F7F5F0;
}
.gh-stat { text-align: center; }
.gh-stat strong {
    display: block; font-family: var(--font-title, 'Novecento Sans Wide', sans-serif); font-size: 26px;
    color: var(--ecos-blue, #06177E); font-weight: 800;
}
.gh-stat span { font-size: 12px; color: #55597a; }
.gh-stat-div { width: 1px; height: 32px; background: #d8dbe8; }
@media (max-width: 640px) { .gh-stat-div { display: none; } }

/* ── Filtros ──────────────────────────────────── */
.gh-filter-wrap { text-align: center; max-width: 680px; margin: 70px auto 40px; padding: 0 24px; }
.section-badge {
    display: inline-block; background: var(--ecos-yellow, #FAC018); color: var(--ecos-blue, #06177E);
    font-family: var(--font-title, 'Novecento Sans Wide', sans-serif); font-size: 12px; font-weight: 700;
    letter-spacing: .08em; text-transform: uppercase; padding: 6px 16px; border-radius: 999px; margin-bottom: 16px;
}
.gh-filter-wrap h2 {
    font-family: var(--font-title, 'Novecento Sans Wide', sans-serif); font-size: clamp(26px, 3.4vw, 38px);
    color: var(--ecos-blue, #06177E); text-transform: uppercase; margin: 0 0 12px;
}
.gh-filter-wrap h2 em { font-style: italic; color: var(--ecos-red, #D72327); }
.gh-filter-wrap > p { font-size: 14px; color: #55597a; line-height: 1.6; margin: 0 0 30px; }
.gh-filters { display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; }
.gh-filter-btn {
    display: inline-flex; align-items: center; gap: 8px; background: #fff; border: 1.5px solid #e2e4ee;
    border-radius: 999px; padding: 9px 18px; font-family: var(--font-title, 'Novecento Sans Wide', sans-serif);
    font-weight: 700; font-size: 12.5px; color: #444868; cursor: pointer; transition: all .15s ease;
}
.gh-filter-btn:hover { border-color: var(--ecos-blue, #06177E); }
.gh-filter-btn.active { background: var(--ecos-blue, #06177E); border-color: var(--ecos-blue, #06177E); color: #fff; }
.gh-count {
    background: rgba(0,0,0,.08); border-radius: 999px; padding: 1px 8px; font-size: 11px;
}
.gh-filter-btn.active .gh-count { background: rgba(255,255,255,.2); }

/* ── Grid (masonry simple con spans) ────────────── */
.gh-grid-section { padding: 0 24px 80px; }
.gh-grid-wrap { max-width: 1240px; margin: 0 auto; }
.gh-grid {
    display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: 200px; gap: 14px;
}
.gh-item {
    position: relative; border-radius: 14px; overflow: hidden; cursor: pointer;
    grid-column: span 1; grid-row: span 1;
}
.gh-item.big { grid-column: span 2; grid-row: span 2; }
.gh-item.tall { grid-row: span 2; }
.gh-item.wide { grid-column: span 2; }
.gh-item img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s ease; }
.gh-item:hover img { transform: scale(1.06); }
.gh-overlay {
    position: absolute; inset: 0; background: linear-gradient(180deg, transparent 40%, rgba(6,23,126,.85) 100%);
    display: flex; flex-direction: column; justify-content: space-between; padding: 14px; opacity: 0; transition: opacity .25s ease;
}
.gh-item:hover .gh-overlay { opacity: 1; }
.gh-tag {
    align-self: flex-start; background: var(--ecos-yellow, #FAC018); color: var(--ecos-blue, #06177E);
    font-family: var(--font-title, 'Novecento Sans Wide', sans-serif); font-size: 10px; font-weight: 800;
    text-transform: uppercase; letter-spacing: .05em; padding: 4px 10px; border-radius: 999px;
}
.gh-zoom {
    position: absolute; top: 14px; right: 14px; width: 32px; height: 32px; border-radius: 50%;
    background: rgba(255,255,255,.9); color: var(--ecos-blue, #06177E); display: flex; align-items: center; justify-content: center;
}
.gh-zoom svg { width: 15px; height: 15px; }
.gh-caption h4 {
    font-family: var(--font-title, 'Novecento Sans Wide', sans-serif); font-size: 14px; color: #fff;
    text-transform: uppercase; margin: 0 0 2px;
}
.gh-caption p { font-size: 11.5px; color: rgba(255,255,255,.8); margin: 0; }
@media (max-width: 900px) {
    .gh-grid { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 170px; }
    .gh-item.big { grid-column: span 2; grid-row: span 1; }
    .gh-item.wide { grid-column: span 2; }
}
@media (max-width: 520px) {
    .gh-grid { grid-template-columns: 1fr; }
    .gh-item.big, .gh-item.wide, .gh-item.tall { grid-column: span 1; grid-row: span 1; }
}

/* ── Video section ────────────────────────────── */
.gh-video-section { padding: 20px 24px 90px; background: #F7F5F0; }
.gh-video-inner {
    max-width: 1180px; margin: 0 auto; display: grid; grid-template-columns: 1fr 1fr;
    gap: 40px; align-items: center;
}
.gh-video-text h2 {
    font-family: var(--font-title, 'Novecento Sans Wide', sans-serif); font-size: clamp(26px, 3.4vw, 38px);
    color: var(--ecos-blue, #06177E); text-transform: uppercase; margin: 0 0 16px; line-height: 1.1;
}
.gh-video-text h2 em { font-style: normal; color: var(--ecos-red, #D72327); }
.gh-video-text p { font-size: 14px; color: #55597a; line-height: 1.65; margin: 0 0 24px; }
.gh-video-link {
    display: inline-flex; align-items: center; gap: 8px; font-family: var(--font-title, 'Novecento Sans Wide', sans-serif);
    font-weight: 700; font-size: 13px; color: var(--ecos-blue, #06177E); text-decoration: none;
}
.gh-video-link:hover { text-decoration: underline; }
.gh-video-embed { position: relative; border-radius: 18px; overflow: hidden; aspect-ratio: 16/10; background: #000; }
.gh-video-embed iframe { width: 100%; height: 100%; border: 0; display: block; }
.gh-video-thumb { position: relative; width: 100%; height: 100%; cursor: pointer; }
.gh-video-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gh-video-grad { position: absolute; inset: 0; background: linear-gradient(0deg, rgba(6,23,126,.55), transparent 55%); }
.gh-play-btn {
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    width: 66px; height: 66px; border-radius: 50%; background: var(--ecos-yellow, #FAC018);
    display: flex; align-items: center; justify-content: center; box-shadow: 0 10px 30px rgba(0,0,0,.3);
    transition: transform .15s ease;
}
.gh-video-thumb:hover .gh-play-btn { transform: translate(-50%, -50%) scale(1.08); }
.gh-play-btn svg { width: 24px; height: 24px; fill: var(--ecos-blue, #06177E); margin-left: 3px; }
@media (max-width: 860px) { .gh-video-inner { grid-template-columns: 1fr; } }

/* ── CTA final ────────────────────────────────── */
.gh-cta {
    padding: 90px 24px; background: linear-gradient(135deg, var(--ecos-blue, #06177E), var(--ecos-blue-dark, #05165E));
    text-align: center;
}
.gh-cta-inner { max-width: 640px; margin: 0 auto; }
.gh-cta-badge {
    display: inline-block; background: rgba(250,192,24,.18); border: 1px solid var(--ecos-yellow, #FAC018);
    color: var(--ecos-yellow, #FAC018); font-family: var(--font-title, 'Novecento Sans Wide', sans-serif);
    font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
    padding: 6px 16px; border-radius: 999px; margin-bottom: 18px;
}
.gh-cta h2 {
    font-family: var(--font-title, 'Novecento Sans Wide', sans-serif); font-size: clamp(26px, 3.6vw, 40px);
    color: #fff; text-transform: uppercase; margin: 0 0 16px; line-height: 1.15;
}
.gh-cta h2 em { font-style: normal; color: var(--ecos-yellow, #FAC018); }
.gh-cta p { color: rgba(255,255,255,.82); font-size: 14.5px; line-height: 1.6; margin: 0 0 30px; }
.gh-cta-btns { display: flex; justify-content: center; gap: 14px; flex-wrap: wrap; }
.gh-cta-primary, .gh-cta-secondary {
    display: inline-flex; align-items: center; font-family: var(--font-title, 'Novecento Sans Wide', sans-serif);
    font-weight: 700; font-size: 13.5px; padding: 13px 26px; border-radius: 999px; text-decoration: none;
    transition: transform .15s ease;
}
.gh-cta-primary:hover, .gh-cta-secondary:hover { transform: translateY(-2px); }
.gh-cta-primary { background: var(--ecos-yellow, #FAC018); color: var(--ecos-blue, #06177E); }
.gh-cta-secondary { background: rgba(255,255,255,.08); color: #fff; border: 1.5px solid rgba(255,255,255,.5); }

/* ── Lightbox ─────────────────────────────────── */
.lb-overlay {
    position: fixed; inset: 0; background: rgba(5,8,30,.95); z-index: 3000;
    display: none; align-items: center; justify-content: center; opacity: 0; transition: opacity .2s ease;
}
.lb-overlay.open { display: flex; opacity: 1; }
.lb-close {
    position: absolute; top: 22px; right: 22px; width: 42px; height: 42px; border-radius: 50%;
    background: rgba(255,255,255,.1); border: none; color: #fff; display: flex; align-items: center; justify-content: center;
    cursor: pointer; z-index: 2;
}
.lb-close:hover { background: rgba(255,255,255,.2); }
.lb-close svg { width: 18px; height: 18px; }
.lb-counter {
    position: absolute; top: 26px; left: 26px; color: rgba(255,255,255,.75);
    font-family: var(--font-title, 'Novecento Sans Wide', sans-serif); font-size: 13px; letter-spacing: .05em;
}
.lb-arrow {
    position: absolute; top: 50%; transform: translateY(-50%); width: 48px; height: 48px; border-radius: 50%;
    background: rgba(255,255,255,.1); border: none; color: #fff; display: flex; align-items: center; justify-content: center;
    cursor: pointer; z-index: 2;
}
.lb-arrow:hover { background: rgba(255,255,255,.2); }
.lb-arrow svg { width: 20px; height: 20px; }
#lbPrev { left: 20px; }
#lbNext { right: 20px; }
.lb-inner { max-width: 900px; width: 90%; display: flex; flex-direction: column; align-items: center; gap: 16px; }
.lb-img-wrap { width: 100%; max-height: 62vh; display: flex; align-items: center; justify-content: center; }
.lb-img-wrap img { max-width: 100%; max-height: 62vh; border-radius: 12px; display: block; transition: opacity .15s ease; }
.lb-caption { text-align: center; }
.lb-caption h4 { font-family: var(--font-title, 'Novecento Sans Wide', sans-serif); color: #fff; font-size: 16px; text-transform: uppercase; margin: 0 0 4px; }
.lb-caption p { color: rgba(255,255,255,.7); font-size: 13px; margin: 0; }
.lb-thumbs { display: flex; gap: 8px; overflow-x: auto; max-width: 100%; padding-bottom: 4px; }
.lb-thumb {
    flex: 0 0 60px; height: 44px; border-radius: 8px; overflow: hidden; cursor: pointer;
    opacity: .45; transition: opacity .15s ease; border: 2px solid transparent;
}
.lb-thumb.active { opacity: 1; border-color: var(--ecos-yellow, #FAC018); }
.lb-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
@media (max-width: 640px) {
    .lb-arrow { width: 38px; height: 38px; }
    #lbPrev { left: 8px; } #lbNext { right: 8px; }
}