/* ====================================
   BLUEREG CHILE SPA - ESTILOS GENERALES
   ==================================== */

:root {
    --azul-oscuro: #003B73;
    --azul-medio: #1E88E5;
    --celeste: #4FC3F7;
    --celeste-claro: #E3F2FD;
    --blanco: #FFFFFF;
    --gris-texto: #333333;
    --gris-claro: #666666;
    --gris-fondo: #F5F7FA;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: var(--azul-oscuro);
    line-height: 1.6;
    background-color: var(--blanco);
}

/* ====================================
   HEADER Y NAVEGACIÓN
   ==================================== */

header {
    position: relative;
    width: 100%;
    z-index: 1000;
    overflow: visible;
    border-bottom: 2px solid var(--blanco);
}

/* Video de fondo del header */
.header-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
}

/* Capa oscura semitransparente sobre el video */
header::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 59, 115, 0.70);
    z-index: 0;
}

.header-container {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 0.88rem 2rem;
    max-width: 1600px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.logo-container {
    margin-bottom: 0;
    flex-shrink: 0;
}

.logo-container img {
    max-height: 254px;
    width: auto;
    filter: brightness(0) invert(1) drop-shadow(0 2px 6px rgba(0, 0, 0, 0.4));
}

nav {
    width: auto;
}

.nav-menu {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    list-style: none;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.nav-menu li {
    position: relative;
}

.nav-menu a {
    color: var(--blanco);
    text-decoration: none;
    padding: 0.75rem 1.5rem;
    display: block;
    font-weight: 500;
    transition: all 0.3s ease;
    border-radius: 5px;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.nav-menu a:hover {
    background-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.nav-menu a.active {
    background-color: rgba(79, 195, 247, 0.35);
    color: var(--blanco);
}

/* Menú desplegable de Servicios */
.dropdown {
    position: relative;
}

.dropdown-toggle {
    cursor: pointer;
}

.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background-color: rgba(0, 59, 115, 0.92);
    min-width: 250px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    border-radius: 5px;
    margin-top: 0.5rem;
    list-style: none;
    z-index: 100;
    backdrop-filter: blur(8px);
}

.dropdown-menu li {
    border-bottom: 1px solid rgba(79, 195, 247, 0.2);
}

.dropdown-menu li:last-child {
    border-bottom: none;
}

.dropdown-menu a {
    color: var(--blanco);
    padding: 0.75rem 1.5rem;
    display: block;
    transition: all 0.3s ease;
    border-radius: 0;
    text-shadow: none;
}

.dropdown-menu a:hover {
    background-color: rgba(79, 195, 247, 0.25);
    transform: none;
    padding-left: 2rem;
}

.dropdown:hover .dropdown-menu {
    display: block;
}

/* Menú hamburguesa para móviles */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--blanco);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
    margin-top: 1rem;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

/* ====================================
   CONTENIDO PRINCIPAL
   ==================================== */

main {
    margin-top: 0;
    min-height: calc(100vh - 250px);
}

.container {
    max-width: 1600px;
    width: 92%;
    margin: 0 auto;
    padding: 2rem;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--azul-oscuro) 0%, var(--azul-medio) 100%);
    color: var(--blanco);
    text-align: center;
    padding: 3rem 2rem;
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.hero p {
    font-size: 1.2rem;
    max-width: 100%;
    margin: 0 auto;
    opacity: 0.95;
}

/* Sección introductoria Quiénes Somos */
.about-intro p {
    font-size: 1.25rem;
    line-height: 2;
    text-align: justify;
}

/* Sección de contenido */
.content-section {
    margin-bottom: 3rem;
    padding: 2rem;
    background-color: var(--blanco);
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
}

.content-section h2 {
    color: var(--azul-oscuro);
    font-size: 2rem;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: none;
    text-align: center;
}

.content-section h3 {
    color: var(--azul-medio);
    font-size: 1.5rem;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.content-section p {
    margin-bottom: 1rem;
    line-height: 1.8;
    color: var(--azul-oscuro);
}

.content-section ul {
    list-style-position: inside;
    margin-bottom: 1rem;
}

.content-section ul li {
    margin-bottom: 0.5rem;
    color: var(--azul-oscuro);
    padding-left: 1rem;
}

/* Grid de tarjetas */
.cards-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem;
    margin-top: 2rem;
    margin-bottom: 2rem;
}

.card {
    background-color: var(--blanco);
    flex: 0 1 calc(33.333% - 2rem);
    min-width: 280px;
    max-width: 400px;
    border-radius: 10px;
    padding: 2rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-top-color 0.3s ease;
    border-top: 4px solid transparent;
    text-align: center;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    border-top-color: var(--celeste);
}

.card h3 {
    color: var(--azul-oscuro);
    font-size: 1.4rem;
    margin-bottom: 1rem;
    margin-top: 0;
    min-height: 2.8em;
    display: flex;
    align-items: center;
    justify-content: center;
}

.card p {
    color: var(--azul-oscuro);
    line-height: 1.6;
    text-align: justify;
}

.social-cards .card p {
    text-align: center;
}

.card .icon {
    margin-bottom: 1rem;
    line-height: 1;
    text-align: center;
}

.card .icon svg {
    width: 44px;
    height: 44px;
    fill: var(--azul-medio);
}

/* Ícono inline en títulos de sección (servicios) */
.section-icon {
    display: inline-flex;
    vertical-align: middle;
    margin-right: 0.5rem;
}

.section-icon svg {
    width: 32px;
    height: 32px;
    fill: var(--azul-medio);
}

/* ====================================
   LLAMADO A LA ACCIÓN (CTA)
   ==================================== */

.cta-section {
    background: linear-gradient(135deg, var(--azul-oscuro) 0%, var(--azul-medio) 100%);
    color: var(--blanco);
    text-align: center;
    padding: 3rem 2rem;
    border-radius: 10px;
    margin: 3rem 0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.cta-section h2 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.cta-section p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    opacity: 0.95;
}

.btn {
    display: inline-block;
    padding: 1rem 2.5rem;
    background-color: var(--blanco);
    color: var(--azul-oscuro);
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    border: 2px solid var(--blanco);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.btn:hover {
    background-color: var(--azul-oscuro);
    color: var(--blanco);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.btn-secondary {
    background-color: transparent;
    color: var(--blanco);
    border: 2px solid var(--blanco);
}

.btn-secondary:hover {
    background-color: var(--blanco);
    color: var(--azul-oscuro);
}

/* ====================================
   LAYOUT CONTACTO (2 columnas)
   ==================================== */

.contact-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    padding: 3rem 0;
    align-items: start;
}

.contact-info-col h2,
.contact-form-col h2 {
    color: var(--azul-oscuro);
    margin-bottom: 1rem;
    text-align: left;
}

.contact-info-col > p {
    color: var(--azul-oscuro);
    font-size: 1.1rem;
    line-height: 1.7;
    margin-bottom: 2rem;
}

.contact-info-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding: 1rem;
    background-color: var(--celeste-claro);
    border-radius: 10px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.contact-info-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.contact-info-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    background-color: var(--blanco);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.contact-info-icon svg {
    width: 24px;
    height: 24px;
}

.contact-info-item h3 {
    color: var(--azul-oscuro);
    font-size: 1rem;
    margin-bottom: 0.25rem;
}

.contact-info-item p {
    color: var(--azul-oscuro);
    font-size: 0.95rem;
    margin: 0;
    line-height: 1.5;
}

.contact-info-item a {
    color: var(--azul-medio);
    text-decoration: none;
}

.contact-info-item a:hover {
    text-decoration: underline;
}

/* ====================================
   FORMULARIO DE CONTACTO
   ==================================== */

.contact-form-col .contact-form {
    max-width: 100%;
}

.contact-form {
    background-color: var(--blanco);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--azul-oscuro);
    font-weight: 600;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid var(--celeste-claro);
    border-radius: 5px;
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--celeste);
}

.form-group textarea {
    resize: vertical;
    min-height: 150px;
}

.checkbox-group {
    display: flex;
    align-items: flex-start;
    margin-bottom: 1.5rem;
}

.checkbox-group input[type="checkbox"] {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    min-width: 20px;
    min-height: 20px;
    border: 2px solid var(--azul-medio);
    border-radius: 4px;
    margin-right: 0.6rem;
    margin-top: 0.15rem;
    cursor: pointer;
    position: relative;
    background-color: var(--blanco);
}

.checkbox-group input[type="checkbox"]:checked {
    background-color: var(--azul-medio);
    border-color: var(--azul-medio);
}

.checkbox-group input[type="checkbox"]:checked::after {
    content: '✓';
    color: white;
    font-size: 14px;
    font-weight: bold;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.checkbox-group label {
    font-weight: normal;
    font-size: 0.9rem;
    color: var(--azul-oscuro);
}

.checkbox-group label a {
    color: var(--azul-medio);
    text-decoration: underline;
}

button[type="submit"] {
    width: 100%;
    padding: 1rem;
    background-color: var(--azul-medio);
    color: var(--blanco);
    border: none;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

button[type="submit"]:hover {
    background-color: var(--azul-oscuro);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

button[type="submit"]:disabled {
    background-color: var(--gris-claro);
    cursor: not-allowed;
    transform: none;
}

button[type="submit"]:disabled:hover {
    box-shadow: none;
}

/* Información Básica sobre Protección de Datos */
.data-protection-info {
    background-color: var(--blanco);
    border: none;
    border-radius: 12px;
    padding: 2rem 2.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 2px 15px rgba(0, 59, 115, 0.08);
}

.data-protection-info h4 {
    color: var(--azul-oscuro);
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 1.2rem;
    padding-bottom: 0.8rem;
    border-bottom: 2px solid var(--celeste);
}

.data-protection-table {
    width: 100%;
    border-collapse: collapse;
}

.data-protection-table tr {
    border-bottom: 1px solid var(--celeste-claro);
}

.data-protection-table tr:last-child {
    border-bottom: none;
}

.data-protection-table th,
.data-protection-table td {
    padding: 0.85rem 0.5rem;
    text-align: left;
    vertical-align: top;
    font-size: 0.92rem;
    line-height: 1.6;
}

.data-protection-table th {
    color: var(--celeste);
    font-weight: 600;
    width: 170px;
    white-space: nowrap;
    padding-right: 1.5rem;
    font-style: italic;
}

.data-protection-table td {
    color: var(--azul-oscuro);
}

.data-protection-table td a {
    color: var(--azul-medio);
    text-decoration: underline;
    font-weight: 500;
}

.data-protection-table td a:hover {
    color: var(--celeste);
}

@media (max-width: 600px) {
    .data-protection-info {
        padding: 1.5rem 1.2rem;
    }
    .data-protection-table th,
    .data-protection-table td {
        display: block;
        width: 100%;
        padding: 0.4rem 0.5rem;
    }
    .data-protection-table th {
        padding-bottom: 0;
    }
    .data-protection-table tr {
        padding: 0.5rem 0;
    }
}

.checkbox-newsletter label {
    font-size: 0.9rem;
    color: var(--azul-oscuro);
}

.privacy-hint {
    font-size: 0.85rem;
    color: var(--azul-medio);
    margin-bottom: 1rem;
    font-style: italic;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.privacy-hint a {
    color: var(--azul-medio);
    font-weight: 600;
    text-decoration: underline;
}

.privacy-hint.hidden {
    display: none;
}

.checkbox-group input[type="checkbox"]:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.checkbox-group input[type="checkbox"]:disabled + label {
    opacity: 0.6;
    cursor: not-allowed;
}

/* ====================================
   PÁGINA DE POLÍTICA DE PRIVACIDAD
   ==================================== */

.privacy-policy {
    background-color: var(--blanco);
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    padding: 3rem;
    margin-bottom: 2rem;
}

.privacy-header {
    text-align: center;
    margin-bottom: 2.5rem;
    padding-bottom: 2rem;
    border-bottom: 2px solid var(--celeste-claro);
}

.privacy-logo {
    max-width: 340px;
    width: 100%;
    height: auto;
    margin-bottom: 1.5rem;
}

.privacy-subtitle {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--azul-oscuro);
    margin-bottom: 0.5rem;
}

.privacy-update {
    font-size: 0.95rem;
    color: var(--azul-medio);
    font-style: italic;
}

.privacy-policy h2 {
    color: var(--azul-oscuro);
    font-size: 1.5rem;
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--celeste-claro);
}

.privacy-policy h3 {
    color: var(--azul-medio);
    font-size: 1.2rem;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

.privacy-policy p {
    text-align: justify;
    margin-bottom: 1rem;
    line-height: 1.8;
}

.privacy-policy a {
    color: var(--azul-medio);
    text-decoration: underline;
}

.privacy-policy a:hover {
    color: var(--azul-oscuro);
}

.privacy-list {
    margin-left: 2rem;
    margin-bottom: 1.5rem;
}

.privacy-list li {
    margin-bottom: 0.75rem;
    line-height: 1.7;
    text-align: justify;
}

.privacy-notice {
    background-color: var(--celeste-claro);
    border-left: 4px solid var(--azul-medio);
    padding: 1.5rem;
    border-radius: 0 8px 8px 0;
    margin: 1.5rem 0;
}

.privacy-notice p {
    margin-bottom: 0;
}

.privacy-commitment {
    background: linear-gradient(135deg, var(--azul-oscuro) 0%, var(--azul-medio) 100%);
    color: var(--blanco);
    padding: 2rem;
    border-radius: 10px;
    margin-top: 2.5rem;
    text-align: center;
}

.privacy-commitment h3 {
    color: var(--blanco);
    font-size: 1.3rem;
    margin-bottom: 1rem;
}

.privacy-commitment p {
    color: rgba(255, 255, 255, 0.9);
    text-align: center;
    margin-bottom: 0;
}

/* ====================================
   SECCIÓN DE NOTICIAS
   ==================================== */

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.news-card {
    background-color: var(--blanco);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.news-card-image {
    width: 100%;
    height: 200px;
    background: linear-gradient(135deg, var(--azul-medio) 0%, var(--celeste) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--blanco);
    font-size: 3rem;
    overflow: hidden;
}

.news-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.news-card:hover .news-card-image img {
    transform: scale(1.05);
}

.news-card-image svg {
    width: 64px;
    height: 64px;
    fill: var(--blanco);
}

.news-card-content {
    padding: 1.5rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.news-card-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.75rem;
    font-size: 0.85rem;
    color: var(--gris-claro);
}

.news-card-meta .author {
    color: var(--azul-medio);
    font-weight: 600;
}

.news-card-date {
    color: var(--celeste);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.news-card h3 {
    color: var(--azul-oscuro);
    font-size: 1.3rem;
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

.news-card h3 a {
    text-decoration: none;
    color: inherit;
    transition: color 0.2s;
}

.news-card h3 a:hover {
    color: var(--azul-medio);
}

.news-card p {
    color: var(--azul-oscuro);
    margin-bottom: 1rem;
    line-height: 1.6;
    flex: 1;
}

.news-card .btn {
    padding: 0.5rem 1.5rem;
    font-size: 0.9rem;
    align-self: flex-start;
}

/* Estado vacío noticias */
.news-empty {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--gris-claro);
}

.news-empty svg {
    margin-bottom: 1rem;
}

.news-empty h3 {
    color: var(--azul-oscuro);
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.news-empty p {
    max-width: 500px;
    margin: 0 auto;
    line-height: 1.6;
}

/* Paginación noticias */
.news-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    margin-top: 2.5rem;
    padding: 1rem 0;
}

.news-pagination button {
    width: 40px;
    height: 40px;
    border: 2px solid var(--celeste-claro);
    background: var(--blanco);
    color: var(--azul-oscuro);
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.news-pagination button:hover {
    background: var(--celeste-claro);
    border-color: var(--celeste);
}

.news-pagination button.active {
    background: var(--azul-medio);
    color: var(--blanco);
    border-color: var(--azul-medio);
}

.news-pagination button:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

/* ====================================
   PÁGINA DE POST INDIVIDUAL
   ==================================== */

.post-article {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 0;
}

.post-meta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    color: var(--azul-oscuro);
    font-size: 1.1rem;
    margin-bottom: 2rem;
    padding-bottom: 1.25rem;
    border-bottom: 2px solid var(--celeste-claro);
}

.post-meta .author {
    color: var(--azul-medio);
    font-weight: 600;
}

.post-main-image {
    max-width: 600px;
    margin: 0 auto 2rem;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.post-main-image img {
    width: 100%;
    max-height: 400px;
    object-fit: contain;
    display: block;
    background: var(--gris-fondo);
}

.post-body {
    font-size: 1.15rem;
    line-height: 1.8;
    color: var(--azul-oscuro);
}

.post-body h2 {
    color: var(--azul-oscuro);
    font-size: 1.8rem;
    margin: 2rem 0 1rem;
}

.post-body h3 {
    color: var(--azul-medio);
    font-size: 1.4rem;
    margin: 1.5rem 0 0.75rem;
}

.post-body p {
    margin-bottom: 1rem;
    text-align: justify;
    color: var(--azul-oscuro);
}

.post-body ul,
.post-body ol {
    margin-left: 2rem;
    margin-bottom: 1rem;
}

.post-body li {
    margin-bottom: 0.5rem;
    color: var(--azul-oscuro);
}

.post-body blockquote {
    border-left: 4px solid var(--celeste);
    background: var(--celeste-claro);
    padding: 1rem 1.5rem;
    margin: 1.5rem 0;
    border-radius: 0 8px 8px 0;
    font-style: italic;
    color: var(--azul-oscuro);
}

.post-body img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 1rem 0;
}

/* Galería de imágenes del post */
.post-gallery {
    margin: 2rem 0;
}

.post-gallery h3 {
    color: var(--azul-oscuro);
    font-size: 1.2rem;
    margin-bottom: 1rem;
}

.post-gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
}

.post-gallery-grid img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
}

.post-gallery-grid img:hover {
    transform: scale(1.03);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

/* Video embebido */
.post-video-wrapper {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    border-radius: 12px;
    margin: 2rem 0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.post-video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* Botón de descarga PDF */
.post-pdf-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--azul-medio);
    color: var(--blanco);
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: background 0.3s;
    margin: 1.5rem 0;
}

.post-pdf-btn:hover {
    background: var(--azul-oscuro);
}

.post-pdf-btn svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

/* Navegación del post (volver) */
.post-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 2px solid var(--celeste-claro);
}

.post-nav a {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--azul-medio);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s;
}

.post-nav a:hover {
    color: var(--azul-oscuro);
}

/* ====================================
   PARTNERS / CARTERA DE CLIENTES
   ==================================== */

.partners-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
    margin-top: 2rem;
    align-items: center;
}

.partners-grid .partner-logo {
    flex: 0 1 calc(25% - 1.5rem);
}

.partner-logo {
    background: var(--blanco);
    border-radius: 10px;
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    border: 1px solid var(--celeste-claro);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100px;
}

.partner-logo:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.12);
}

.partner-logo img {
    max-height: 65px;
    max-width: 160px;
    width: auto;
    height: auto;
    object-fit: contain;
    filter: grayscale(20%);
    transition: filter 0.3s ease;
}

.partner-logo:hover img {
    filter: grayscale(0%);
}

@media (max-width: 768px) {
    .partners-grid {
        gap: 1rem;
    }

    .partners-grid .partner-logo {
        flex: 0 1 calc(50% - 1rem);
    }

    .partner-logo {
        height: 80px;
        padding: 0.75rem 1rem;
    }

    .partner-logo img {
        max-height: 50px;
        max-width: 120px;
    }
}

/* ====================================
   ADMIN GEAR BUTTON
   ==================================== */

.admin-gear-btn {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 36px;
    height: 36px;
    background: transparent;
    border: none;
    cursor: pointer;
    opacity: 0.08;
    transition: opacity 0.3s;
    z-index: 50;
    padding: 0;
    text-decoration: none;
}

.admin-gear-btn:hover {
    opacity: 0.3;
}

.admin-gear-btn svg {
    width: 100%;
    height: 100%;
    fill: var(--azul-oscuro);
}

/* ====================================
   FOOTER
   ==================================== */

footer {
    background: linear-gradient(135deg, var(--azul-oscuro) 0%, var(--azul-medio) 100%);
    color: var(--blanco);
    padding: 3rem 2rem 1rem;
    margin-top: 4rem;
}

.footer-container {
    max-width: 1200px;
    width: 90%;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
    align-items: start;
    justify-items: center;
}

.footer-section h3 {
    color: var(--blanco);
    margin-bottom: 1rem;
    font-size: 1.4rem;
    text-transform: uppercase;
}

.footer-logo {
    text-align: center;
    padding-right: 0;
}

.footer-logo img {
    max-width: 261px;
    width: 100%;
    height: auto;
    margin-bottom: 1rem;
    filter: brightness(0) invert(1);
}

.footer-logo-secondary {
    max-width: 261px;
    width: 100%;
    height: auto;
    display: block;
}

/* Nuevo logo del directorio - PNG transparente con contenido blanco */
.footer-logo-directory {
    max-width: 180px;
    width: 100%;
    height: auto;
    display: block;
    cursor: pointer;
    transition: transform 0.3s ease;
    margin-bottom: 1rem;
}

.footer-logo-directory:hover {
    transform: scale(1.15);
}

.footer-contact p {
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    font-size: 1.1rem;
}

.footer-contact .footer-contact-icon {
    width: 16px;
    height: 16px;
    margin-right: 0.5rem;
    flex-shrink: 0;
}

.footer-contact .footer-contact-name {
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 0.15rem;
}

.footer-contact .footer-contact-title {
    font-size: 0.95rem;
    opacity: 0.85;
    margin-bottom: 0.75rem;
}

.footer-contact a {
    color: var(--blanco);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-contact a:hover {
    color: var(--celeste);
}

.footer-social {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.social-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    background-color: var(--azul-medio);
    color: var(--blanco);
    border-radius: 50%;
    text-decoration: none;
    font-size: 1.3rem;
    transition: all 0.3s ease;
}

.social-icon svg {
    width: 24px;
    height: 24px;
}

.social-icon:hover {
    background-color: var(--celeste);
    transform: translateY(-3px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.footer-links ul {
    list-style: none;
}

.footer-links ul li {
    margin-bottom: 0.5rem;
}

.footer-links ul li a {
    color: var(--blanco);
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-block;
    font-size: 1.1rem;
}

.footer-links ul li a:hover {
    color: var(--celeste);
    padding-left: 0.5rem;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    padding-top: 1.5rem;
    text-align: center;
    color: rgba(255, 255, 255, 0.85);
    font-size: 1rem;
}

/* ====================================
   RESPONSIVE - TABLET
   ==================================== */

@media (max-width: 768px) {
    .header-container {
        flex-direction: column;
        padding: 1rem;
    }

    .logo-container {
        margin-bottom: 0.5rem;
        display: flex;
        justify-content: center;
        width: 100%;
    }

    .logo-container img {
        max-height: 164px;
        max-width: 90%;
        width: auto;
        height: auto;
        object-fit: contain;
    }

    nav {
        width: 100%;
    }

    .nav-menu {
        display: none;
        flex-direction: column;
        width: 100%;
        background-color: rgba(0, 59, 115, 0.92);
        border-radius: 5px;
        margin-top: 1rem;
        border: 1px solid rgba(79, 195, 247, 0.3);
        backdrop-filter: blur(8px);
    }

    .nav-menu.active {
        display: flex;
    }

    .nav-menu li {
        width: 100%;
    }

    .nav-menu a {
        width: 100%;
        text-align: center;
    }

    .dropdown-menu {
        position: static;
        display: none;
        box-shadow: none;
        background-color: rgba(0, 40, 80, 0.85);
        margin-top: 0;
    }

    .dropdown.active .dropdown-menu {
        display: block;
    }

    .dropdown-menu a {
        color: var(--blanco);
        padding-left: 2rem;
    }

    .dropdown-menu a:hover {
        background-color: rgba(79, 195, 247, 0.3);
        color: var(--blanco);
    }

    .menu-toggle {
        display: block;
    }

    main {
        margin-top: 0;
    }

    .hero {
        min-height: auto;
        padding: 2.5rem 1.5rem;
    }

    .hero h1 {
        font-size: 1.8rem;
        line-height: 1.3;
    }

    .hero p {
        font-size: 0.95rem;
        line-height: 1.5;
        word-wrap: break-word;
        overflow-wrap: break-word;
    }

    .cards-grid {
        grid-template-columns: 1fr;
    }

    .contact-layout {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .footer-container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
        justify-items: center;
        width: 100%;
        padding: 0 1rem;
        box-sizing: border-box;
    }

    .footer-section {
        width: 100%;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .footer-section h3 {
        text-align: center;
        width: 100%;
    }

    /* Footer Logo - centrado mobile */
    .footer-logo {
        text-align: center;
        padding-right: 0;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .footer-logo img {
        max-width: 200px;
        margin-left: auto;
        margin-right: auto;
    }

    .footer-logo-secondary {
        max-width: 200px;
        margin: 0 auto;
        display: block;
    }

    /* Footer Contacto - centrado mobile */
    .footer-contact {
        align-items: center;
        text-align: center;
    }

    .footer-contact p {
        justify-content: center;
        text-align: center;
        width: 100%;
        flex-wrap: wrap;
    }

    .footer-contact .footer-contact-name,
    .footer-contact .footer-contact-title {
        text-align: center;
        width: 100%;
        display: block;
    }

    .footer-contact a {
        text-align: center;
    }

    /* Social icons - 2 filas de 3 en mobile */
    .footer-social {
        justify-content: center;
        flex-wrap: wrap;
        max-width: 200px;
        margin-left: auto;
        margin-right: auto;
        gap: 0.75rem;
    }

    .footer-social .social-icon {
        width: 42px;
        height: 42px;
    }

    /* Footer Links - centrado mobile */
    .footer-links {
        width: 100%;
        align-items: center;
    }

    .footer-links ul {
        display: flex;
        flex-direction: column;
        align-items: center;
        padding: 0;
    }

    .footer-links ul li {
        text-align: center;
    }

    .footer-links ul li a {
        text-align: center;
    }

    .footer-bottom {
        text-align: center;
        padding: 1rem;
    }
}

/* ====================================
   RESPONSIVE - MÓVIL
   ==================================== */

@media (max-width: 480px) {
    .container {
        padding: 1rem;
    }

    .hero {
        padding: 1.5rem 1rem;
        min-height: auto;
    }

    .hero h1 {
        font-size: 1.4rem;
        line-height: 1.3;
    }

    .hero p {
        font-size: 0.85rem;
        line-height: 1.5;
    }

    .logo-container img {
        max-height: 137px;
        max-width: 85%;
    }

    .footer-logo img {
        max-width: 160px;
    }

    .footer-logo-secondary {
        max-width: 160px;
    }

    .footer-social {
        max-width: 170px;
        gap: 0.6rem;
    }

    .footer-social .social-icon {
        width: 38px;
        height: 38px;
        font-size: 1.1rem;
    }

    .footer-social .social-icon svg {
        width: 20px;
        height: 20px;
    }

    .footer-contact p {
        font-size: 0.95rem;
    }

    .footer-bottom p {
        font-size: 0.85rem;
    }

    .content-section {
        padding: 1.5rem;
    }

    .content-section h2 {
        font-size: 1.5rem;
    }

    .cta-section {
        padding: 2rem 1rem;
    }

    .cta-section h2 {
        font-size: 1.5rem;
    }

    .btn {
        padding: 0.75rem 1.5rem;
        font-size: 1rem;
    }

    .news-grid {
        grid-template-columns: 1fr;
    }

    .contact-form {
        padding: 1.5rem;
    }

    main {
        margin-top: 0;
    }
}

/* ====================================
   ANIMACIONES Y UTILIDADES
   ==================================== */

.fade-in {
    animation: fadeIn 0.6s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.text-center {
    text-align: center;
}

.mt-2 {
    margin-top: 2rem;
}

.mb-2 {
    margin-bottom: 2rem;
}

/* ====================================
   SECCIÓN DE SERVICIOS
   ==================================== */

.service-section {
    scroll-margin-top: 200px;
    padding: 2rem;
    background-color: var(--blanco);
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    margin-bottom: 2rem;
    border-top: 4px solid transparent;
    transition: border-top-color 0.3s ease, box-shadow 0.3s ease;
}

.service-section:hover {
    border-top-color: var(--celeste);
}

.service-section:target {
    animation: highlight 1.5s ease;
}

@keyframes highlight {
    0%, 100% {
        background-color: var(--blanco);
    }
    50% {
        background-color: var(--celeste-claro);
    }
}

.service-section h2 {
    color: var(--azul-oscuro);
    font-size: 2rem;
    margin-bottom: 1rem;
    text-align: center;
}

.service-section h3 {
    color: var(--azul-medio);
    font-size: 1.3rem;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    text-align: center;
}

.service-section p {
    text-align: justify;
}

.service-section ul {
    margin-left: 2rem;
    margin-bottom: 1rem;
}

.service-section ul li {
    margin-bottom: 0.5rem;
    color: var(--azul-oscuro);
    text-align: justify;
}

/* ====================================
   NEWSLETTER SUBSCRIPTION SECTION
   ==================================== */

.newsletter-section {
    background-color: var(--blanco);
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    margin: 3rem 0;
    overflow: hidden;
}

.newsletter-header {
    background: linear-gradient(135deg, var(--azul-oscuro) 0%, var(--azul-medio) 100%);
    color: var(--blanco);
    text-align: center;
    padding: 2.5rem 2rem 2rem;
}

.newsletter-icon {
    width: 64px;
    height: 64px;
    background-color: var(--blanco);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.newsletter-header h2 {
    font-size: 1.8rem;
    margin-bottom: 0.75rem;
}

.newsletter-header p {
    font-size: 1.05rem;
    opacity: 0.95;
    max-width: 600px;
    margin: 0 auto;
}

.newsletter-section .newsletter-form {
    padding: 2rem;
    max-width: 500px;
    margin: 0 auto;
}

.newsletter-section .form-group {
    margin-bottom: 1.5rem;
}

.newsletter-section .form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--azul-oscuro);
    font-weight: 600;
}

.newsletter-section .form-group input {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid var(--celeste-claro);
    border-radius: 5px;
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.3s ease;
}

.newsletter-section .form-group input:focus {
    outline: none;
    border-color: var(--celeste);
}

.newsletter-section button[type="submit"] {
    width: 100%;
    padding: 1rem;
    background-color: var(--azul-medio);
    color: var(--blanco);
    border: none;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: inherit;
}

.newsletter-section button[type="submit"]:hover {
    background-color: var(--azul-oscuro);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.newsletter-section button[type="submit"]:disabled {
    background-color: var(--gris-claro);
    cursor: not-allowed;
    transform: none;
}

.newsletter-privacy {
    font-size: 0.85rem;
    color: var(--gris-claro);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    line-height: 1.5;
}

.newsletter-privacy a {
    color: var(--azul-medio);
    text-decoration: underline;
    font-weight: 600;
}

.newsletter-privacy a:hover {
    color: var(--azul-oscuro);
}

.newsletter-message {
    margin-top: 1rem;
    padding: 0.85rem 1.25rem;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 500;
    text-align: center;
}

.newsletter-message.success {
    background: #E8F5E9;
    border: 1px solid #A5D6A7;
    color: #2E7D32;
}

.newsletter-message.error {
    background: #FFEBEE;
    border: 1px solid #EF9A9A;
    color: #C62828;
}

@media (max-width: 768px) {
    .newsletter-header {
        padding: 2rem 1.25rem 1.5rem;
    }

    .newsletter-header h2 {
        font-size: 1.4rem;
    }

    .newsletter-section .newsletter-form {
        padding: 1.5rem;
    }
}
