/* ===== GOOGLE FONTS (Sans-Serif) ===== */
@import url('https://fonts.googleapis.com/css2?family=Open+Sans:ital,wght@0,300;0,400;0,500;0,600;0,700;1,300;1,400;1,500;1,600;1,700&display=swap');

/* ===== RESET & BASE ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #1a5490;
    --secondary-color: #8b0000;
    --accent-color: #c99a3e;
    --text-color: #2c3e50;
    --text-muted: #666666;
    --text-light: #888888;
    --light-bg: #f5f5f5;
    --white: #ffffff;
    --border-color: #ddd;
    --shadow: 0 2px 10px rgba(0,0,0,0.1);
    --transition: all 0.3s ease;
    
    /* Tipografía Sans-Serif General */
    --font-sans: 'Open Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --font-family-base: var(--font-sans);
}

html {
    scroll-behavior: smooth;
    font-size: 14px;
}

body {
    font-family: var(--font-sans);
    font-feature-settings: "cv02", "cv03", "cv04", "cv11";
    line-height: 1.5;
    color: var(--text-color);
    background-color: var(--white);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ===== ESTILO GENERAL PARA TODOS LOS PÁRRAFOS (SANS-SERIF & JUSTIFICADO) ===== */
p,
.paragraph,
.text-sans,
.content-wrapper p,
.content-column p,
.page-content p,
article p,
main p,
section p,
div > p {
    font-family: var(--font-sans) !important;
    font-size: 1rem;
    line-height: 1.6;
    color: #374151;
    margin-bottom: 0.75rem;
    text-align: justify;
    text-justify: inter-word;
    text-rendering: optimizeLegibility;
}

/* Evitar margen inferior en el último párrafo dentro de contenedores */
p:last-child,
.content-wrapper p:last-child,
.card-body p:last-child {
    margin-bottom: 0;
}

/* Párrafos destacados o introductorios */
p.lead,
.lead-paragraph {
    font-family: var(--font-sans) !important;
    font-size: 1.13rem;
    line-height: 1.5;
    font-weight: 400;
    color: #1f2937;
    text-align: justify;
    text-justify: inter-word;
}

/* Elementos de formulario y botones heredan sans-serif */
button,
input,
optgroup,
select,
textarea {
    font-family: var(--font-sans);
}

/* ===== ESTILOS GENERALES DE CONTENIDO ===== */
.content-section {
    padding: 4px 0 40px 0;
}

.content-wrapper {
    background: var(--white);
    padding: 35px;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    font-family: var(--font-sans);
}

.content-wrapper h1,
.content-wrapper h2,
.content-wrapper h3,
.content-wrapper h4,
.content-wrapper h5,
.content-wrapper h6 {
    font-family: var(--font-sans);
    color: var(--primary-color);
    margin-top: 1.8rem;
    margin-bottom: 0.85rem;
    font-weight: 600;
    line-height: 1.35;
}

.content-wrapper h1:first-child,
.content-wrapper h2:first-child {
    margin-top: 0;
}

.content-wrapper ul,
.content-wrapper ol {
    margin: 0 0 0.65rem 1.5rem;
    font-family: var(--font-sans);
    color: #374151;
    line-height: 1.5;
}

.content-wrapper li {
    margin-bottom: 0.25rem;
    font-family: var(--font-sans);
}

.content-wrapper blockquote {
    border-left: 4px solid var(--primary-color);
    padding: 15px 20px;
    margin: 25px 0;
    background: #f8fafc;
    border-radius: 0 8px 8px 0;
    font-style: italic;
    color: #4b5563;
    font-family: var(--font-sans);
}

/* Contenido de Noticias y Artículos */
.news-content,
.article-content,
.entry-content {
    font-family: var(--font-sans);
    line-height: 1.5;
    color: #374151;
}

.news-content p,
.article-content p,
.entry-content p {
    font-family: var(--font-sans) !important;
    font-size: 1.05rem;
    line-height: 1.6;
    color: #374151;
    margin-bottom: 0.75rem;
    text-align: justify;
    text-justify: inter-word;
}

.news-content h2,
.news-content h3,
.news-content h4,
.article-content h2,
.article-content h3,
.article-content h4 {
    font-family: var(--font-sans);
    color: var(--primary-color);
    margin-top: 1.8rem;
    margin-bottom: 0.85rem;
    font-weight: 600;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 12px;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

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

ul {
    list-style: none;
}

/* ===== HEADER ===== */
.header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: var(--white);
    box-shadow: var(--shadow);
}

.header-top {
    background: var(--primary-color);
    color: var(--white);
    height: 36px;
    padding: 0;
    font-size: 14px;
    display: flex;
    align-items: center;
}

.header-top .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 12px;
}

.donate-button {
    flex-shrink: 0;
    margin-left: auto;
    display: flex;
    align-items: center;
    height: 36px;
}

.donate-button .btn-donate {
    background: #ff6b6b;
    color: white;
    padding: 6px 14px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 28px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.12);
}

.donate-button .btn-donate:hover {
    background: #ee5a6f;
    transform: translateY(-1px);
}

.donate-button .btn-donate i {
    font-size: 12px;
}

.social-links {
    display: flex;
    align-items: center;
    gap: 12px;
}

.social-links span {
    margin-right: 5px;
}

.social-links a {
    color: var(--white);
    font-size: 16px;
    padding: 4px 6px;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.social-links a:hover {
    background: rgba(255,255,255,0.2);
}

/* ===== MAIN HEADER & LOGO ===== */
.header-main {
    padding: 6px 0;
    border-bottom: 1px solid var(--border-color);
    background: var(--white);
}

.header-main .container {
    display: block;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 12px;
}

.header-main-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

/* Restricción estricta de medidas para el logo */
.logo {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.logo a {
    display: inline-flex;
    align-items: center;
}

.logo-img,
.logo img,
.header-main-inner .logo img {
    height: 56px !important;
    max-height: 56px !important;
    max-width: 220px !important;
    width: auto !important;
    object-fit: contain;
    display: block;
}

/* ===== MAIN NAVIGATION ===== */
.main-nav {
    min-width: 0;
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: visible !important;
}

.nav-menu {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    list-style: none;
    margin: 0 auto;
    padding: 0;
    overflow: visible !important;
}

.nav-item {
    position: relative;
    flex: 0 0 auto;
    list-style: none;
}

.nav-item > a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 8px 10px;
    font-size: 0.92rem;
    font-weight: 600;
    color: var(--text-color);
    border-radius: 6px;
    white-space: nowrap;
    transition: all 0.2s ease;
    border-bottom: none;
    text-decoration: none;
    cursor: pointer;
}

.nav-item > a:hover,
.nav-item > a:focus,
.nav-item.active > a {
    color: var(--primary-color);
    background: rgba(26, 84, 144, 0.08);
}

.nav-item.has-dropdown > a::after {
    content: '▾';
    display: inline-block;
    font-size: 0.9em;
    margin-left: 4px;
    transition: transform 0.25s ease;
    line-height: 1;
}

.nav-item:hover > a::after,
.nav-item.active > a::after,
.nav-item.has-dropdown:focus-within > a::after {
    transform: rotate(180deg);
}

/* ===== DROPDOWN MENU ===== */
.dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    background: #ffffff;
    min-width: 240px;
    padding: 6px 0;
    margin-top: 0;
    border-radius: 8px;
    border: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.15);
    opacity: 0;
    visibility: hidden;
    transform: translateY(6px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
    z-index: 1500;
    list-style: none;
    pointer-events: none;
}

/* Puente invisible que conecta el botón con el submenú para evitar que se cierre al mover el mouse */
.dropdown::before {
    content: '';
    position: absolute;
    top: -16px;
    left: 0;
    right: 0;
    height: 16px;
    background: transparent;
    display: block;
}

.nav-item:hover > .dropdown,
.nav-item:focus-within > .dropdown,
.nav-item.active > .dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.dropdown li {
    list-style: none;
    margin: 0;
    padding: 0;
}

.dropdown li a {
    display: block;
    padding: 10px 18px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-color);
    border-bottom: 1px solid #f2f4f7;
    transition: background 0.2s ease, color 0.2s ease, padding-left 0.2s ease;
    white-space: nowrap;
    text-decoration: none;
}

.dropdown li:last-child a {
    border-bottom: none;
}

.dropdown li a:hover,
.dropdown li a:focus {
    background: #f0f6ff;
    color: var(--primary-color);
    padding-left: 22px;
}

@media (max-width: 900px) {
    .logo-img,
    .logo img,
    .header-main-inner .logo img {
        height: 42px !important;
        max-height: 42px !important;
        max-width: 160px !important;
    }
}

@media (max-width: 480px) {
    .logo-img,
    .logo img,
    .header-main-inner .logo img {
        height: 36px !important;
        max-height: 36px !important;
        max-width: 130px !important;
    }
}

/* ===== HEADER ACTIONS ===== */
.header-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.btn {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 5px;
    font-weight: 500;
    cursor: pointer;
    border: none;
    transition: var(--transition);
    font-size: 14px;
}

.btn-donar {
    background: var(--secondary-color);
    color: var(--white);
}

.btn-donar:hover {
    background: #6b0000;
}

.btn-primary {
    background: var(--primary-color);
    color: var(--white);
}

.btn-primary:hover {
    background: #0f3a6b;
}

.btn-secondary {
    background: var(--white);
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background: var(--primary-color);
    color: var(--white);
}

.search-toggle,
.mobile-menu-toggle {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: var(--text-color);
    padding: 5px;
}

.search-toggle:hover,
.mobile-menu-toggle:hover {
    color: var(--primary-color);
}

.mobile-menu-toggle {
    display: none;
}

/* ===== SEARCH POPUP ===== */
.search-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.9);
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
}

.search-popup.active {
    display: flex;
}

.search-form {
    position: relative;
    width: 90%;
    max-width: 600px;
}

.search-form input {
    width: 100%;
    padding: 20px 60px 20px 20px;
    font-size: 18px;
    border: none;
    border-radius: 5px;
}

.search-form button {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--primary-color);
    color: var(--white);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
}

.search-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: var(--white);
    color: var(--text-color);
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 24px;
}

/* ===== HERO CAROUSEL ===== */
.hero-carousel {
    position: relative;
    width: 100%;
    max-width: 100%;
    padding: 0;
    aspect-ratio: 16 / 8;
    max-height: 520px;
    overflow: hidden;
    background: #111;
}

.carousel-slides {
    height: 100%;
    position: relative;
}

.carousel-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease;
    background: #1a1a1a;
}

.carousel-slide.active {
    opacity: 1;
}

.carousel-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
}

.carousel-prev,
.carousel-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.85);
    border: none;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 18px;
    color: var(--text-color);
    z-index: 10;
}

.carousel-prev {
    left: 12px;
}

.carousel-next {
    right: 12px;
}

.carousel-prev:hover,
.carousel-next:hover {
    background: var(--white);
    color: var(--primary-color);
}

/* ===== SECTIONS ===== */
section {
    padding: 16px 0;
}

.welcome-section {
    background: var(--white);
    text-align: center;
    padding: 20px 0;
    box-sizing: border-box;
}

.welcome-section h1 {
    font-size: 2.2em;
    color: var(--primary-color);
    margin-bottom: 8px;
    line-height: 1.1;
}

.welcome-section p {
    font-size: 1.1em;
    max-width: 800px;
    margin: 0 auto;
    color: #666;
}

/* ===== NEWS GRID (Más Novedades) ===== */
.news-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(220px, 1fr));
    gap: 18px;
    align-items: start;
    justify-content: center;
    max-width: 980px;
    margin: 0 auto;
}

.news-card {
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 6px rgba(0,0,0,0.06);
    display: flex;
    flex-direction: column;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
    width: 100%;
    max-width: 320px;
}

.news-card:hover { 
    transform: translateY(-4px); 
    box-shadow: 0 8px 20px rgba(0,0,0,0.08); 
}

.news-card img { 
    width: 100%; 
    height: 160px; 
    object-fit: cover; 
    display: block; 
}

.news-card .card-body { 
    padding: 12px; 
    display: flex; 
    flex-direction: column; 
    gap: 8px; 
}

.news-card h4 { 
    margin: 0; 
    font-size: 1rem; 
    color: var(--primary-color); 
    line-height: 1.2; 
}

.news-card p { 
    margin: 0; 
    color: #666; 
    font-size: 0.92rem; 
    flex: 1; 
    text-align: justify;
    text-justify: inter-word;
}

.news-card .meta { 
    font-size: 0.82rem; 
    color: #999; 
}

.news-card a { 
    color: inherit; 
    text-decoration: none; 
    display: block; 
    height: 100%; 
}

@media (max-width: 1000px) {
    .news-grid { grid-template-columns: repeat(2, minmax(220px, 1fr)); }
}

@media (max-width: 680px) {
    .news-grid { grid-template-columns: 1fr; }
    .news-card img { height: 180px; }
    .news-card { max-width: none; }
}

/* 2 Columns Layout for Donar page */
.donate-layout {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: 30px;
    align-items: start;
}

.donate-layout h1,
.donate-layout h2,
.donate-layout h3,
.donate-layout h4,
.donate-column-text h1,
.donate-column-text h2,
.donate-column-text h3,
.donate-column-text h4,
.donate-column-methods h2,
.donate-card-title {
    font-family: var(--font-sans);
    color: var(--primary-color);
    font-weight: 600;
    line-height: 1.35;
}

.donate-column-text h1:first-child,
.donate-column-text h2:first-child,
.content-wrapper h1:first-child,
.content-wrapper h2:first-child {
    margin-top: 0;
}

.donate-column-text {
    display: flex;
    flex-direction: column;
}

.donate-column-text p,
.donate-page-text p {
    text-align: justify;
    text-justify: inter-word;
    line-height: 1.8;
    color: #374151;
    margin-bottom: 16px;
    font-size: 1.03rem;
}

/* Enhanced Donation Methods Cards */
.donate-column-methods {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.donate-column-methods h2 {
    margin: 0 0 6px 0;
    color: var(--primary-color);
    font-size: 1.6rem;
    font-weight: 600;
}

.donate-method-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 24px 26px;
    box-shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.05), 0 2px 6px -1px rgba(15, 23, 42, 0.02);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    position: relative;
    overflow: hidden;
}

.donate-method-card:hover {
    box-shadow: 0 8px 26px -2px rgba(15, 23, 42, 0.08);
}

.donate-method-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), #3b82f6);
}

.donate-method-card.yape-theme::before {
    background: linear-gradient(90deg, #74226c, #a21caf);
}

/* ===== ESTILO PARA TÍTULOS 3 (H3) SIN LÍNEA INFERIOR ===== */
h3,
.content-wrapper h3,
.donate-layout h3,
.donate-column-text h3,
.donate-page-text h3,
.donate-card-title,
.donate-card-header h3 {
    font-family: var(--font-sans);
    color: var(--primary-color);
    font-weight: 600;
    font-size: 1.25rem;
    line-height: 1.35;
    margin-top: 1.2rem;
    margin-bottom: 0.65rem;
    border-bottom: none !important;
    padding-bottom: 0 !important;
    text-decoration: none !important;
}

h3::after,
.content-wrapper h3::after,
.donate-layout h3::after,
.donate-card-title::after {
    display: none !important;
    content: none !important;
}

.donate-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 14px;
    padding-bottom: 0;
    border-bottom: none !important;
}

.donate-card-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    font-size: 1.18rem;
    font-weight: 600;
    color: var(--primary-color);
    border-bottom: none !important;
}

.donate-card-title i {
    color: var(--primary-color);
    font-size: 1.25rem;
}

.yape-theme .donate-card-title {
    color: #74226c;
}

.yape-theme .donate-card-title i {
    color: #74226c;
}

.donate-card-badge {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 4px 10px;
    border-radius: 20px;
    background: #f1f5f9;
    color: #475569;
}

/* Bank Account Detail Box */
.bank-data-box {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 16px;
    margin-bottom: 16px;
}

.bank-data-box pre {
    margin: 0;
    font-family: inherit;
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.7;
    color: #1e293b;
    white-space: pre-wrap;
    word-break: break-word;
    text-align: center;
}

.btn-copy-bank {
    background: #ffffff;
    border: 1.5px solid #cbd5e1;
    color: #334155;
    font-weight: 600;
    font-size: 0.92rem;
    padding: 10px 22px;
    border-radius: 8px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s ease;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.btn-copy-bank:hover {
    background: #f1f5f9;
    border-color: #94a3b8;
    color: #0f172a;
    transform: translateY(-1px);
}

.btn-copy-bank:active {
    transform: translateY(0);
}

/* Yape Pill & QR Frame */
.yape-phone-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #fdf4ff;
    border: 1.5px solid #f0abfc;
    color: #701a75;
    padding: 8px 20px;
    border-radius: 30px;
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 14px;
    letter-spacing: 0.5px;
}

.yape-qr-wrap {
    display: inline-block;
    padding: 6px;
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    box-shadow: 0 4px 14px -2px rgba(116, 34, 108, 0.08);
    transition: transform 0.25s ease;
}

.yape-qr-wrap:hover {
    transform: scale(1.04);
}

.yape-qr-wrap img {
    max-width: 125px;
    height: auto;
    border-radius: 6px;
    display: block;
    margin: 0 auto;
}

.yape-instruction {
    font-size: 0.82rem;
    color: #64748b;
    margin-top: 8px;
    margin-bottom: 0;
}

/* WhatsApp CTA Card */
.whatsapp-cta-card {
    background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
    border: 1px solid #bbf7d0;
    border-radius: 14px;
    padding: 20px 22px;
    text-align: center;
}

.whatsapp-cta-card p {
    color: #166534;
    font-size: 0.95rem;
    font-weight: 500;
    margin-bottom: 14px;
    line-height: 1.45;
}

.btn-whatsapp-modern {
    background: #25D366;
    color: #ffffff !important;
    font-weight: 700;
    font-size: 1rem;
    padding: 12px 26px;
    border-radius: 30px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    text-decoration: none;
    box-shadow: 0 4px 14px rgba(37, 211, 102, 0.35);
    transition: all 0.25s ease;
}

.btn-whatsapp-modern:hover {
    background: #1eb956;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.45);
}

.donate-layout pre { white-space: pre-wrap; word-break: break-word; }
.donate-layout img { max-width: 100%; height: auto; display: block; }

@media (max-width: 968px) {
    .donate-layout {
        grid-template-columns: 1fr;
        gap: 32px;
    }
}

@media (max-width: 760px) {
    .donate-layout .btn, .donate-layout .btn-primary, .donate-layout .btn-whatsapp, .btn-whatsapp-modern, .btn-copy-bank { width: 100%; display: inline-flex; justify-content: center; text-align: center; }
    .donate-layout img { max-width: 220px; margin: 0 auto; }
}

.donate-layout img[alt*="QR"] { max-width: 100%; height: auto; }

.mass-schedule-section {
    background: var(--light-bg);
    padding: 30px 0;
}

.schedule-card {
    background: var(--white);
    padding: 36px 32px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    max-width: 1040px;
    margin: 0 auto;
    text-align: center;
}

.schedule-card h2 {
    color: var(--primary-color);
    font-size: 1.85em;
    font-weight: 700;
    margin-bottom: 28px;
    letter-spacing: 0.5px;
}

.schedule-two-columns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 28px;
    text-align: left;
    margin-bottom: 28px;
}

.schedule-col {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 22px 24px;
    display: flex;
    flex-direction: column;
}

.schedule-col h3,
.schedule-col h4 {
    color: var(--primary-color) !important;
    font-size: 1.2rem !important;
    font-weight: 700 !important;
    margin-top: 0 !important;
    margin-bottom: 14px !important;
    padding-bottom: 8px !important;
    border-bottom: 2px solid rgba(26, 84, 144, 0.15) !important;
    letter-spacing: 0.2px;
}

.schedule-col ul {
    list-style: none !important;
    margin: 0 0 12px 0 !important;
    padding: 0 !important;
}

.schedule-col li {
    padding: 9px 0 !important;
    border-bottom: 1px dashed #e2e8f0 !important;
    font-size: 0.95rem !important;
    line-height: 1.5 !important;
    color: #334155 !important;
}

.schedule-col li:last-child {
    border-bottom: none !important;
}

.schedule-col p {
    margin: 8px 0 !important;
    font-size: 0.92rem !important;
    color: #475569 !important;
    line-height: 1.5 !important;
}

.schedule-card-footer {
    text-align: center;
    margin-top: 10px;
}

/* Fallback compatibilidad una sola columna */
.schedule-content ul {
    text-align: left;
    margin-bottom: 20px;
}

.schedule-content li {
    padding: 10px 0;
    border-bottom: 1px solid var(--border-color);
}

.schedule-content li:last-child {
    border-bottom: none;
}

.schedule-content p {
    margin: 10px 0;
}

@media (max-width: 768px) {
    .schedule-two-columns {
        grid-template-columns: 1fr;
        gap: 18px;
    }
    
    .schedule-card {
        padding: 24px 16px;
    }
    
    .schedule-card h2 {
        font-size: 1.5em;
    }
}

.pilgrimage-section {
    background: var(--white);
}

.pilgrimage-card {
    background: linear-gradient(135deg, var(--primary-color), #0f3a6b);
    color: var(--white);
    padding: 60px 40px;
    border-radius: 10px;
    text-align: center;
    box-shadow: var(--shadow);
}

.pilgrimage-card h2 {
    font-size: 2em;
    margin-bottom: 20px;
}

.pilgrimage-card img {
    max-width: 200px;
    margin: 0 auto 30px;
}

.pilgrimage-card .btn {
    background: var(--white);
    color: var(--primary-color);
}

.pilgrimage-card .btn:hover {
    background: var(--light-bg);
}

.news-section {
    background: var(--light-bg);
}

.news-section h2 {
    text-align: center;
    font-size: 2em;
    color: var(--primary-color);
    margin-bottom: 40px;
}

.news-carousel {
    position: relative;
    overflow: hidden;
    margin-bottom: 30px;
}

.news-carousel-track {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

.news-card h3 {
    padding: 20px 20px 10px;
    font-size: 1.2em;
    color: var(--primary-color);
}

.news-card h3 a {
    color: inherit;
}

.news-card h3 a:hover {
    text-decoration: underline;
}

.btn-link {
    display: inline-block;
    padding: 10px 20px;
    color: var(--primary-color);
    font-weight: 500;
    border-bottom: 2px solid var(--primary-color);
    margin: 0 20px 20px;
}

.btn-link:hover {
    background: var(--primary-color);
    color: var(--white);
}

.virtual-tour-section {
    background: var(--white);
}

.tour-card {
    background: linear-gradient(135deg, #8b0000, #6b0000);
    color: var(--white);
    padding: 60px 40px;
    border-radius: 10px;
    text-align: center;
    box-shadow: var(--shadow);
    max-width: 800px;
    margin: 0 auto;
}

.tour-card h2 {
    font-size: 2em;
    margin-bottom: 20px;
}

.tour-card p {
    font-size: 1.1em;
    margin-bottom: 30px;
}

.tour-card .btn {
    background: var(--white);
    color: var(--secondary-color);
}

.tour-card .btn:hover {
    background: var(--light-bg);
}

/* ===== FOOTER ===== */
.footer {
    background: #524e4e;
    color: var(--white);
    padding: 60px 0 30px;
}

.footer-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 40px;
    margin-bottom: 40px;
    align-items: flex-start;
}

.footer-col {
    flex: 1 1 220px;
    min-width: 220px;
    max-width: 280px;
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    padding-top: 20px;
    border-top: 1px solid #333;
    color: #999;
    font-size: 0.9em;
}

.footer-col h3 {
    font-size: 1.2em;
    margin-bottom: 20px;
    color: var(--white);
}

.footer-logo {
    max-width: 150px;
    filter: brightness(0) invert(1);
}

.footer-col p {
    margin-bottom: 10px;
    color: #ccc;
}

.footer-col a {
    color: #ccc;
}

.footer-col a:hover {
    color: var(--white);
    text-decoration: underline;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: #ccc;
}

.footer-links a:hover {
    color: var(--white);
}

.footer-bottom a {
    color: #ccc;
}

.footer-bottom a:hover {
    color: var(--white);
}

/* ===== RESPONSIVE HEADER & MENU ===== */
@media (max-width: 768px) {
    .header-top {
        height: 36px;
        padding: 0;
    }
    .header-top .container {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 8px;
    }

    .mobile-menu-toggle {
        display: block;
        z-index: 1100;
    }

    .mobile-menu-text {
        display: inline-block;
        margin-left: 8px;
        font-weight: 700;
    }

    .main-nav {
        position: fixed;
        top: 0;
        left: 0;
        width: 80%;
        max-width: 320px;
        height: 100vh;
        background: var(--white);
        box-shadow: 2px 0 20px rgba(0,0,0,0.25);
        transition: transform 0.3s ease, opacity 0.3s ease;
        transform: translateX(-100%);
        opacity: 0;
        visibility: hidden;
        display: block !important;
        padding: 20px 20px 40px;
        overflow-y: auto;
        z-index: 1050;
        pointer-events: none;
    }
    
    .main-nav.active {
        transform: translateX(0);
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }
    
    .nav-menu {
        flex-direction: column;
    }
    
    .nav-item {
        width: 100%;
    }
    
    .nav-item > a {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 15px 0;
        border-bottom: 1px solid var(--border-color);
        width: 100%;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    
    .nav-item.has-dropdown > a::after {
        content: '▼';
        display: inline-block;
        font-size: 0.8rem;
        margin-left: 10px;
        transition: transform 0.3s ease;
    }
    
    .nav-item.active > a::after {
        transform: rotate(180deg);
    }
    
    .dropdown {
        position: static !important;
        opacity: 1 !important;
        visibility: visible !important;
        transform: none !important;
        box-shadow: none !important;
        border: none !important;
        border-left: 2px solid var(--primary-color) !important;
        margin-left: 14px !important;
        margin-top: 4px !important;
        padding: 4px 0 !important;
        background: transparent !important;
        border-radius: 0 !important;
        display: none !important;
        pointer-events: auto !important;
        min-width: 0 !important;
    }
    
    .nav-item.active > .dropdown {
        display: block !important;
    }
    
    .dropdown li a {
        padding: 12px 0;
        border-bottom: none;
        font-size: 0.95em;
    }
    
    .mobile-menu-toggle:hover,
    .mobile-menu-toggle:focus {
        color: var(--primary-color);
        outline: none;
    }

    .main-nav a:focus,
    .mobile-menu-toggle:focus {
        outline: 2px solid var(--primary-color);
        outline-offset: 3px;
    }
    
    .hero-carousel {
        aspect-ratio: 16 / 9;
        max-height: 300px;
    }
    
    .welcome-section h1 {
        font-size: 1.8em;
    }

    .schedule-card,
    .pilgrimage-card,
    .tour-card {
        padding: 30px 20px;
    }
    
    .news-carousel-track {
        grid-template-columns: 1fr;
    }
    
    .footer-grid {
        flex-direction: column;
        gap: 30px;
    }
    .footer-col {
        max-width: none;
        min-width: 0;
        width: 100%;
    }
    .footer-bottom {
        justify-content: center;
        text-align: center;
    }
}

@media (max-width: 1024px) and (min-width: 769px) {
    .nav-menu {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .nav-item > a {
        padding: 10px 10px;
        font-size: 14px;
    }
    .footer-grid {
        flex-direction: row;
        justify-content: space-between;
        gap: 30px;
    }
}

/* ===== UTILITIES ===== */
.text-center {
    text-align: center;
}

.mt-20 {
    margin-top: 20px;
}

.mb-20 {
    margin-bottom: 20px;
}

/* ===== CONTENT + GALLERY TWO COLUMNS ===== */
.content-gallery-wrapper {
    background: var(--white);
    padding: 12px 0 50px;
}

.content-gallery-grid {
    display: grid;
    grid-template-columns: minmax(320px, 1.6fr) minmax(280px, 1fr);
    gap: 60px;
    align-items: start;
}

.content-column {
    padding-right: 20px;
    min-width: 0;
}

.content-wrapper {
    color: var(--text-color);
    line-height: 1.25;
    overflow-wrap: break-word;
    word-break: break-word;
}

.content-wrapper h1,
.content-wrapper h2,
.content-wrapper h3,
.content-wrapper h4 {
    color: var(--primary-color) !important;
    font-weight: 700 !important;
    line-height: 1.3;
    margin: 22px 0 10px;
    padding-bottom: 10px;
    border-bottom: 3px solid var(--accent-color);
}

.content-wrapper h1 { font-size: 2em !important; }
.content-wrapper h2 { font-size: 1.75em !important; }
.content-wrapper h3 { font-size: 1.4em !important; font-weight: 600 !important; }
.content-wrapper h4 { font-size: 1.15em !important; font-weight: 600 !important; }

.content-wrapper p {
    margin-bottom: 12px;
    font-size: 1.05em;
    color: #555;
    line-height: 1.6;
    text-align: justify;
    text-justify: inter-word;
}

.content-wrapper ul,
.content-wrapper ol {
    margin: 8px 0;
    padding-left: 30px;
}

.content-wrapper li {
    margin-bottom: 5px;
}

.gallery-column {
    position: sticky;
    top: 100px;
    align-self: start;
    min-width: 0;
    z-index: 20;
}

.gallery-carousel {
    position: relative;
    width: 100%;
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.1), 0 4px 12px rgba(0, 0, 0, 0.04);
    border: 1px solid rgba(0, 0, 0, 0.06);
    overflow: hidden;
    transition: box-shadow 0.35s ease;
    user-select: none;
}

.gallery-carousel:hover {
    box-shadow: 0 16px 40px -8px rgba(0, 0, 0, 0.15), 0 6px 16px rgba(0, 0, 0, 0.06);
}

/* Floating Badges Header (Ocultos) */
.gallery-carousel-badges,
.gallery-badge-counter,
.gallery-badge-zoom {
    display: none !important;
}

/* Viewport & Track */
.gallery-carousel-viewport {
    position: relative;
    width: 100%;
    overflow: hidden;
    background: #f5f5f5; /* Blanco humo / whitesmoke */
    border-radius: 12px;
}

.gallery-carousel-track {
    display: flex;
    transition: transform 0.45s cubic-bezier(0.25, 1, 0.5, 1);
    min-height: 0;
    width: 100%;
    will-change: transform;
    background: #f5f5f5;
}

.gallery-slide {
    flex: 0 0 100%;
    min-width: 100%;
    position: relative;
    display: flex;
    flex-direction: column;
    background: #f5f5f5;
    cursor: default;
    overflow: hidden;
}

/* Whitesmoke Gallery Frame */
.gallery-media-wrapper {
    position: relative;
    width: 100%;
    height: 420px;
    max-height: 420px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f5f5f5;
}

.gallery-bg-blur {
    display: none !important;
}

.gallery-slide img,
.gallery-main-img {
    position: relative;
    z-index: 2;
    width: 100%;
    height: 420px;
    max-height: 420px;
    object-fit: contain;
    object-position: center;
    display: block;
    margin: 0 auto;
    border: none;
    border-radius: 0;
    background: #f5f5f5;
    filter: none;
}

.gallery-slide:hover img {
    transform: none;
}

/* Navigation Buttons (Ocultos por solicitud) */
.gallery-nav {
    display: none !important;
}

/* Caption (Debajo de cada foto de forma limpia y compacta) */
.gallery-caption {
    position: relative;
    background: #ffffff;
    padding: 8px 14px 10px;
    border-top: 1px solid #f1f5f9;
    text-align: center;
    width: 100%;
    box-sizing: border-box;
}

.gallery-caption h4 {
    color: var(--primary-color, #781d28) !important;
    font-size: 0.95rem !important;
    font-weight: 600 !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
    line-height: 1.35 !important;
    text-transform: none !important;
    letter-spacing: 0.2px;
}

.gallery-caption p {
    color: #64748b !important;
    font-size: 0.82rem !important;
    margin: 3px 0 0 !important;
    padding: 0 !important;
    line-height: 1.35 !important;
    text-align: center !important;
    text-transform: none !important;
}

.gallery-caption:empty {
    display: none !important;
}

/* Thumbnail Strip */
.gallery-thumbnails-wrap {
    display: flex;
    gap: 6px;
    padding: 8px 12px;
    background: #f8fafc;
    border-top: 1px solid #eef2f6;
    overflow-x: auto;
    scrollbar-width: thin;
    scrollbar-color: #cbd5e1 transparent;
}

.gallery-thumbnails-wrap::-webkit-scrollbar {
    height: 4px;
}

.gallery-thumbnails-wrap::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

.gallery-thumb-item {
    flex: 0 0 54px;
    height: 38px;
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
    opacity: 0.55;
    border: 2px solid transparent;
    transition: all 0.25s ease;
    background: #e2e8f0;
    padding: 0;
}

.gallery-thumb-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.gallery-thumb-item:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

.gallery-thumb-item.active {
    opacity: 1;
    border-color: var(--accent-color, #c28d3a);
    box-shadow: 0 2px 8px rgba(194, 141, 58, 0.4);
    transform: translateY(-2px) scale(1.04);
}

/* Dots (Ocultos) */
.gallery-dots {
    display: none !important;
}

/* Responsive para dos columnas */
@media (max-width: 968px) {
    .content-gallery-grid {
        grid-template-columns: 1fr;
        gap: 35px;
    }
    
    .content-column {
        padding-right: 0;
    }
    
    .gallery-column {
        position: static;
        width: 100%;
    }
    
    .gallery-media-wrapper,
    .gallery-slide img,
    .gallery-main-img {
        height: 360px;
        max-height: 360px;
    }
}

@media (max-width: 768px) {
    .content-gallery-wrapper {
        padding: 10px 0 35px;
    }
    
    .content-gallery-grid {
        gap: 30px;
    }
    
    .content-wrapper h2 {
        font-size: 1.8em;
    }
    
    .content-wrapper h3 {
        font-size: 1.4em;
    }
    
    .content-wrapper p {
        font-size: 1em;
    }
}

@media (max-width: 480px) {
    .content-gallery-wrapper {
        padding: 8px 0 25px;
    }
    
    .content-gallery-grid {
        gap: 25px;
    }
    
    .content-wrapper h2 {
        font-size: 1.5em;
    }
    
    .content-wrapper h3 {
        font-size: 1.2em;
    }
    
    .gallery-media-wrapper,
    .gallery-slide img,
    .gallery-main-img {
        height: 250px;
        max-height: 250px;
    }
    
    .gallery-nav {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
}

/* ===== PAGE HEADER BANNER (MISMAS MEDIDAS PARA TODAS LAS PÁGINAS) ===== */
.page-header {
    position: relative;
    background: linear-gradient(135deg, var(--primary-color) 0%, #0d3b66 100%);
    padding: 60px 0;
    min-height: 170px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    border-bottom: 3px solid var(--primary-color);
    overflow: hidden;
    margin-bottom: 20px;
}

.page-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../images/header-banners/banner.webp');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0.35;
    z-index: 0;
}

.page-header .container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
    text-align: center;
}

.page-header h1 {
    font-family: var(--font-sans);
    color: #ffffff !important;
    font-size: 2.2rem;
    font-weight: 700;
    margin: 0 auto;
    line-height: 1.25;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.45);
    letter-spacing: 0.02em;
    text-align: center;
}

.page-header p,
.page-header .lead {
    color: rgba(255, 255, 255, 0.95);
    font-size: 1.05rem;
    margin: 10px auto 0;
    max-width: 750px;
    text-align: center;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.35);
}

@media (max-width: 768px) {
    .page-header {
        padding: 40px 0;
        min-height: 130px;
        margin-bottom: 15px;
    }
    .page-header h1 {
        font-size: 1.65rem;
    }
    .page-header p,
    .page-header .lead {
        font-size: 0.95rem;
    }
}

/* ===== LEGACY GALLERY GRID COMPATIBILITY (IF NEEDED) ===== */
.gallery-section {
    background: var(--white);
    padding: 40px 0;
}

.section-title {
    text-align: center;
    font-size: 2em;
    color: var(--primary-color);
    margin-bottom: 30px;
}

/* ===== LIGHTBOX (ULTRA-MODERN) ===== */
.gallery-lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(8, 12, 20, 0.96);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    z-index: 99999;
    flex-direction: column;
    justify-content: space-between;
    opacity: 0;
    transition: opacity 0.3s cubic-bezier(0.25, 1, 0.5, 1);
    box-sizing: border-box;
}

.gallery-lightbox * {
    box-sizing: border-box;
}

.gallery-lightbox.active {
    display: flex;
    opacity: 1;
}

/* Lightbox Header Bar */
.lightbox-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    z-index: 10;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.7) 0%, transparent 100%);
}

.lightbox-counter-badge {
    color: #e2e8f0;
    font-size: 0.88rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    background: rgba(255, 255, 255, 0.12);
    padding: 6px 14px;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    display: flex;
    align-items: center;
    gap: 8px;
}

.lightbox-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.lightbox-btn {
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #ffffff;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.25s ease;
}

.lightbox-btn:hover {
    background: rgba(255, 255, 255, 0.28);
    transform: scale(1.08);
    color: var(--accent-color, #c28d3a);
}

.lightbox-btn.lightbox-close {
    font-size: 1.15rem;
    background: rgba(239, 68, 68, 0.25);
    border-color: rgba(239, 68, 68, 0.4);
}

.lightbox-btn.lightbox-close:hover {
    background: rgba(239, 68, 68, 0.85);
    color: #ffffff;
}

/* Main Lightbox Stage */
.lightbox-stage {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 10px 70px;
    min-height: 0;
}

.lightbox-img-wrapper {
    position: relative;
    max-width: 90vw;
    max-height: calc(85vh - 150px);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1);
}

.lightbox-img {
    max-width: 100%;
    max-height: calc(85vh - 150px);
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.65);
    user-select: none;
    transition: transform 0.3s ease, opacity 0.25s ease;
    cursor: zoom-in;
}

.lightbox-img.zoomed {
    transform: scale(1.6);
    cursor: grab;
}

/* Lightbox Nav Arrows */
.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #ffffff;
    font-size: 1.25rem;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 15;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.25s ease;
}

.lightbox-nav:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-50%) scale(1.1);
    color: var(--accent-color, #c28d3a);
}

.lightbox-prev { left: 20px; }
.lightbox-next { right: 20px; }

/* Lightbox Footer */
.lightbox-footer {
    padding: 12px 24px 18px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.85) 0%, transparent 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    z-index: 10;
}

.lightbox-caption-text {
    text-align: center;
    max-width: 800px;
}

.lightbox-caption-title {
    color: #ffffff;
    font-size: 1.15rem;
    font-weight: 600;
    margin: 0 0 4px;
    text-transform: lowercase;
    letter-spacing: 0.2px;
}

.lightbox-caption-desc {
    color: #94a3b8;
    font-size: 0.88rem;
    margin: 0;
    line-height: 1.4;
    text-transform: lowercase;
}

.lightbox-thumbs {
    display: flex;
    gap: 8px;
    max-width: 90vw;
    overflow-x: auto;
    padding: 4px 0;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}

.lightbox-thumbs::-webkit-scrollbar {
    height: 4px;
}

.lightbox-thumbs::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
}

.lightbox-thumb {
    flex: 0 0 54px;
    height: 38px;
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
    opacity: 0.45;
    border: 2px solid transparent;
    transition: all 0.2s ease;
}

.lightbox-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.lightbox-thumb:hover {
    opacity: 0.85;
}

.lightbox-thumb.active {
    opacity: 1;
    border-color: var(--accent-color, #c28d3a);
    transform: scale(1.08);
}

@media (max-width: 768px) {
    .lightbox-stage {
        padding: 10px 16px;
    }
    
    .lightbox-nav {
        width: 40px;
        height: 40px;
        font-size: 1.05rem;
    }
    
    .lightbox-prev { left: 8px; }
    .lightbox-next { right: 8px; }
    .lightbox-header { padding: 12px 16px; }
    .lightbox-footer { padding: 10px 16px 14px; }
    .lightbox-caption-title { font-size: 1rem; }
    .lightbox-caption-desc { font-size: 0.82rem; }
}

@media (max-width: 480px) {
    .lightbox-btn {
        width: 36px;
        height: 36px;
        font-size: 0.9rem;
    }
}

/* ===== TIENDA ===== */
.tienda-section { 
    padding: 40px 0 60px; 
    background: #f8f9fb; 
}

.tienda-subtitle { 
    color: #556; 
    font-size: 1.05rem; 
    margin-bottom: 32px; 
}

.products {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 28px;
    margin-top: 8px;
}

.product-card {
    border: 1px solid #e8ecf2;
    border-radius: 14px;
    background: #fff;
    display: flex;
    flex-direction: column;
    gap: 0;
    align-items: stretch;
    text-align: center;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(11,61,102,0.07);
    transition: transform .2s ease, box-shadow .2s ease;
}

.product-card:hover { 
    transform: translateY(-5px); 
    box-shadow: 0 14px 36px rgba(11,61,102,0.13); 
}

.product-image {
    width: 100%;
    aspect-ratio: 4/3;
    overflow: hidden;
    background: #f0f2f5;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .35s ease;
}

.product-card:hover .product-image img { 
    transform: scale(1.05); 
}

.product-card h3 {
    font-size: 1rem;
    font-weight: 600;
    color: #0f1724;
    margin: 14px 16px 4px;
    line-height: 1.35;
}

.product-price {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-color);
    margin: 2px 16px 6px;
    letter-spacing: .01em;
}

.product-desc {
    color: #666;
    font-size: .9rem;
    padding: 0 16px;
    flex: 1;
    line-height: 1.5;
    text-align: justify;
    text-justify: inter-word;
}

.product-card-actions {
    display: flex;
    gap: 8px;
    padding: 14px 16px 18px;
    justify-content: center;
}

.product-card-actions .btn { 
    font-size: .88rem; 
    padding: 9px 16px; 
    border-radius: 8px; 
}

.btn-whatsapp {
    background: linear-gradient(135deg, #25D366, #128C7E);
    color: #fff;
    border: none;
    font-weight: 600;
}

.btn-whatsapp:hover { 
    opacity: .92; 
    color: #fff; 
}

/* Modal de producto */
.product-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.65);
    z-index: 9999;
    padding: 20px;
    backdrop-filter: blur(3px);
}

.product-modal.active { 
    display: flex; 
}

.product-modal .modal-content {
    background: #fff;
    border-radius: 16px;
    max-width: 860px;
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    overflow: hidden;
    box-shadow: 0 24px 64px rgba(0,0,0,0.25);
    position: relative;
}

.product-modal .modal-image { 
    background: #f0f2f5; 
}

.product-modal .modal-image img { 
    width: 100%; 
    height: 420px; 
    object-fit: cover; 
    display: block; 
}

.product-modal .modal-body { 
    padding: 32px 28px; 
    display: flex; 
    flex-direction: column; 
    justify-content: center; 
    gap: 12px; 
}

.product-modal .modal-body h2 { 
    margin: 0 0 4px; 
    font-size: 1.4rem; 
    color: #0f1724; 
}

.product-modal .modal-body .product-price { 
    font-size: 1.5rem; 
    margin: 0; 
}

.product-modal .modal-body #modalDesc { 
    color: #555; 
    font-size: .95rem; 
    line-height: 1.6; 
}

.product-modal .modal-actions { 
    display: flex; 
    gap: 10px; 
    margin-top: 16px; 
    flex-wrap: wrap; 
}

.product-modal .close-modal {
    position: absolute;
    right: 14px; 
    top: 12px;
    background: rgba(0,0,0,0.08);
    border: none;
    width: 32px; 
    height: 32px;
    border-radius: 50%;
    font-size: 18px;
    cursor: pointer;
    color: #333;
    display: flex; 
    align-items: center; 
    justify-content: center;
    transition: background .15s;
}

.product-modal .close-modal:hover { 
    background: rgba(0,0,0,0.18); 
}

@media (max-width: 700px) {
    .product-modal .modal-content { grid-template-columns: 1fr; }
    .product-modal .modal-image img { height: 200px; }
    .product-modal .modal-body { padding: 20px; }
    .products { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 16px; }
}

.tienda-container .product-grid { 
    min-height: 40vh; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
}

.tienda-container .products { 
    width: 100%; 
}
