/* ========================================
   VARIABLES - Estilo Corporativo Lifesafe
======================================== */
:root {
    --primary-color: #1c4c9e;
    --primary-light: #34d399;
    --primary-dark: #163c7e;
    --primary-gradient: linear-gradient(135deg, #2563c4 0%, #1c4c9e 100%);
    --secondary-color: #1f2937;
    --text-color: #374151;
    --text-light: #6b7280;
    --background: #ffffff;
    --background-alt: #f9fafb;
    --background-dark: #111827;
    --border-color: #e5e7eb;
    --error-color: #ef4444;
    --success-color: #1c4c9e;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --radius-sm: 8px;
    --radius: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
}

/* ========================================
   RESET
======================================== */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 16px;
    line-height: 1.7;
    color: var(--text-color);
    background-color: var(--background);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

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

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

/* ========================================
   UTILITIES
======================================== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

@media (min-width: 1400px) {
    .container {
        max-width: 1320px;
    }
}

.section {
    padding: 100px 0;
}

@media (max-width: 992px) {
    .section {
        padding: 70px 0;
    }
}

.section-title {
    font-size: 2.5rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 70px;
    color: var(--secondary-color);
    letter-spacing: -0.02em;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 70px;
    height: 4px;
    background: var(--primary-gradient);
    border-radius: 2px;
}

@media (max-width: 768px) {
    .section-title {
        font-size: 1.875rem;
        margin-bottom: 50px;
    }
}

.btn {
    display: inline-block;
    padding: 16px 36px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: var(--radius);
    transition: var(--transition);
    text-align: center;
    letter-spacing: 0.02em;
    cursor: pointer;
}

.btn-primary {
    background: var(--primary-gradient);
    color: #ffffff;
    box-shadow: 0 4px 14px rgba(28, 76, 158, 0.4);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(28, 76, 158, 0.5);
}

.btn-primary:active {
    transform: translateY(-1px);
}

.btn-full {
    width: 100%;
}

/* Botón outline secundario */
.btn-outline {
    background: transparent;
    color: #ffffff;
    border: 2px solid rgba(255, 255, 255, 0.4);
}

.btn-outline:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: #ffffff;
    transform: translateY(-3px);
}

/* Grid 2 columnas para divisiones — centrado */
.services-grid.services-grid-2 {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 480px));
    justify-content: center;
    gap: 32px;
}

@media (max-width: 900px) {
    .services-grid.services-grid-2 {
        grid-template-columns: minmax(0, 480px);
    }
}


/* Cards tipo lista para servicios */
.service-card-list {
    display: flex;
    flex-direction: column;
    padding: 0;
}

.service-card-header {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 22px 28px 14px;
    border-bottom: 1px solid var(--border-color);
}

.service-icon {
    font-size: 2.5rem;
    line-height: 1;
    flex-shrink: 0;
}

.service-card-list h3 {
    padding: 0;
    font-size: 1.25rem;
}

.service-body {
    padding: 14px 28px;
    flex: 1;
    text-align: left;
}

.service-intro {
    font-weight: 600;
    color: var(--secondary-color);
    font-size: 0.9rem;
    margin-bottom: 4px;
    padding: 0;
    text-align: left;
}

.service-list {
    list-style: none;
    margin-top: 0;
    margin-bottom: 6px;
    padding-left: 0;
    display: grid;
    gap: 5px;
}

.service-list li {
    padding-left: 22px;
    position: relative;
    color: var(--text-light);
    font-size: 0.9375rem;
    line-height: 1.4;
}

.service-list li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 4px;
    width: 14px;
    height: 14px;
    background-color: var(--primary-color);
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='currentColor'%3E%3Cpath fill-rule='evenodd' d='M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z' clip-rule='evenodd'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='currentColor'%3E%3Cpath fill-rule='evenodd' d='M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z' clip-rule='evenodd'/%3E%3C/svg%3E");
    -webkit-mask-size: contain;
    mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
}

.service-card-list .btn-cotizar {
    margin: 0 28px 28px;
    text-align: center;
    display: block;
    width: calc(100% - 56px);
}

/* Hover en card lista */
.service-card-list:hover .service-list li,
.service-card-list:hover .service-intro {
    color: rgba(255,255,255,0.85);
}

.service-card-list:hover .service-list li::before {
    background-color: rgba(255,255,255,0.9);
}

/* contact-form styles defined below in CONTACT section */

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.fade-in {
    animation: fadeInUp 0.8s ease forwards;
}

.fade-in-slow {
    animation: fadeIn 1s ease forwards;
}

/* ========================================
   HEADER PROFESIONAL
======================================== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: var(--shadow-sm);
    z-index: 1000;
    transition: var(--transition);
    border-bottom: 1px solid transparent;
}

.header.scrolled {
    box-shadow: var(--shadow-md);
    background: #ffffff;
    border-bottom-color: var(--border-color);
}

.navbar {
    padding: 14px 0;
    transition: var(--transition);
}

.header.scrolled .navbar {
    padding: 10px 0;
}

.navbar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 40px;
}

.logo {
    text-decoration: none;
    display: flex;
    align-items: center;
    flex-shrink: 0;
    transition: var(--transition);
}

.logo:hover {
    opacity: 0.88;
}

.nav-logo-img {
    height: 70px;
    width: auto;
    display: block;
    object-fit: contain;
    mix-blend-mode: multiply;
}

.nav-menu {
    display: flex;
    gap: 28px;
    align-items: center;
}

/* Separar el botón del resto del menú */
.nav-menu li:last-child {
    margin-left: 8px;
}

.nav-menu a {
    font-weight: 500;
    font-size: 0.95rem;
    color: var(--secondary-color);
    transition: var(--transition);
    position: relative;
    padding: 8px 0;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-gradient);
    transition: var(--transition);
    border-radius: 2px;
}

.nav-menu a:hover::after,
.nav-menu a.active::after {
    width: 100%;
}

.nav-menu a:hover {
    color: var(--primary-color);
}

/* Botón CTA en header */
.btn-header {
    background: var(--primary-gradient);
    color: #ffffff !important;
    padding: 12px 44px !important;
    border-radius: var(--radius);
    font-weight: 600;
    box-shadow: 0 4px 14px rgba(28, 76, 158, 0.3);
    transition: var(--transition);
    white-space: nowrap;
    letter-spacing: 0.02em;
    display: inline-block;
}

.btn-header::after {
    display: none !important;
}

.btn-header:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(28, 76, 158, 0.4);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 6px;
    padding: 5px;
}

.hamburger {
    display: block;
    width: 24px;
    height: 2px;
    background-color: var(--secondary-color);
    border-radius: 2px;
    transition: var(--transition);
    position: relative;
}

.hamburger::before,
.hamburger::after {
    content: '';
    position: absolute;
    left: 0;
    width: 24px;
    height: 2px;
    background-color: var(--secondary-color);
    border-radius: 2px;
    transition: var(--transition);
}

.hamburger::before {
    transform: translateY(-7px);
}

.hamburger::after {
    transform: translateY(7px);
}

.nav-toggle.active .hamburger {
    background-color: transparent;
}

.nav-toggle.active .hamburger::before {
    transform: rotate(45deg);
}

.nav-toggle.active .hamburger::after {
    transform: rotate(-45deg);
}

/* ========================================
   HERO CORPORATIVO
======================================== */
.hero {
    position: relative;
    height: 100vh;
    min-height: 750px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
}

/* ── SLIDESHOW FONDO ── */
.hero-slides {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.hero-slide {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1.4s ease;
    animation: kenburns 10s ease-in-out infinite alternate;
}

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

@keyframes kenburns {
    from { transform: scale(1);    transform-origin: center center; }
    to   { transform: scale(1.06); transform-origin: 55% 45%; }
}

.hero-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(135deg, rgba(28, 76, 158, 0.88) 0%, rgba(17, 24, 39, 0.85) 50%, rgba(17, 24, 39, 0.75) 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    color: #ffffff;
    max-width: 900px;
    padding: 0 20px;
}

.hero h1 {
    font-size: 4rem;
    font-weight: 800;
    margin-bottom: 24px;
    line-height: 1.15;
    letter-spacing: -0.03em;
    text-shadow: 0 2px 30px rgba(0, 0, 0, 0.4);
    animation: fadeInUp 1s ease forwards;
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 45px;
    opacity: 0.95;
    font-weight: 300;
    line-height: 1.7;
    max-width: 75%;
    margin-left: auto;
    margin-right: auto;
    animation: fadeInUp 1s ease 0.2s forwards;
    animation-fill-mode: both;
}

.hero-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    animation: fadeInUp 1s ease 0.4s forwards;
    animation-fill-mode: both;
}

.hero .btn {
    min-width: 180px;
}

@media (max-width: 992px) {
    .hero h1 {
        font-size: 3rem;
    }
}

@media (max-width: 768px) {
    .hero {
        min-height: 650px;
    }

    .hero h1 {
        font-size: 2.25rem;
    }

    .hero-subtitle {
        font-size: 1.0625rem;
        max-width: 100%;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
}

/* ========================================
   SECCIÓN CONFIANZA (MÉTRICAS)
======================================== */
.trust-section {
    background: var(--background);
    padding: 60px 0;
    border-bottom: 1px solid var(--border-color);
}

.trust-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
    text-align: center;
}

.trust-item {
    padding: 20px;
}

.trust-number {
    font-size: 3rem;
    font-weight: 800;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: block;
    margin-bottom: 8px;
}

.trust-label {
    color: var(--text-light);
    font-size: 0.9375rem;
    font-weight: 500;
}

@media (max-width: 992px) {
    .trust-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .trust-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    .trust-number {
        font-size: 2.25rem;
    }
}

/* ========================================
   ABOUT
======================================== */
.about {
    background-color: var(--background);
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.about-text h2 {
    font-size: 2.25rem;
    font-weight: 700;
    color: var(--secondary-color);
    margin-bottom: 24px;
    letter-spacing: -0.02em;
}

.about-text p {
    margin-bottom: 18px;
    color: var(--text-light);
    font-size: 1.0625rem;
    line-height: 1.8;
}

.about-features {
    margin-top: 32px;
    display: grid;
    gap: 14px;
}

.about-features li {
    padding: 14px 20px 14px 45px;
    position: relative;
    color: var(--text-color);
    background: var(--background-alt);
    border-radius: var(--radius);
    font-weight: 500;
    transition: var(--transition);
}

.about-features li:hover {
    background: #eff4fd;
    transform: translateX(5px);
}

.about-features li::before {
    content: '✓';
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 24px;
    background: var(--primary-gradient);
    color: #ffffff;
    border-radius: 50%;
    font-weight: 700;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.about-image {
    position: relative;
}

.about-image img {
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    width: 100%;
    height: 500px;
    object-fit: cover;
    transition: var(--transition);
}

.about-image::before {
    content: '';
    position: absolute;
    top: -20px;
    right: -20px;
    width: 100%;
    height: 100%;
    background: var(--primary-gradient);
    border-radius: var(--radius-lg);
    z-index: -1;
    opacity: 0.1;
}

@media (max-width: 992px) {
    .about-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .about-text {
        order: 1;
    }

    .about-image {
        order: 0; /* imagen primero */
    }

    .about-image img {
        height: 360px;
    }

    .about-image::before {
        display: none; /* quitar decoración que puede salir del viewport */
    }
}

/* ========================================
   SERVICES - CARDS CORPORATIVAS
======================================== */
.services {
    background: linear-gradient(180deg, var(--background-alt) 0%, #eff4fd 100%);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
}

.service-card {
    background-color: var(--background);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    position: relative;
    top: 0;
    border: 1px solid var(--border-color);
    cursor: pointer;
}

.service-card:hover,
.service-card.selected {
    transform: translateY(-10px);
    box-shadow: var(--shadow-xl);
    background: var(--primary-dark);
}

.service-card.selected h3,
.service-card.selected p {
    color: #ffffff;
}

.service-card:hover h3,
.service-card:hover p {
    color: #ffffff;
}

/* Botón Cotizar en cards */
.btn-cotizar {
    display: inline-block;
    margin: 0 24px 24px;
    padding: 12px 28px;
    background: var(--primary-gradient);
    color: #ffffff;
    font-weight: 600;
    font-size: 0.9375rem;
    border-radius: var(--radius);
    transition: var(--transition);
    box-shadow: 0 4px 14px rgba(28, 76, 158, 0.3);
}

.btn-cotizar:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(28, 76, 158, 0.4);
}

.service-card.selected .btn-cotizar,
.service-card:hover .btn-cotizar {
    background: #ffffff;
    color: var(--primary-dark);
}

.service-card img {
    width: 100%;
    height: 240px;
    object-fit: cover;
    transition: var(--transition);
}

.service-card:hover img {
    transform: scale(1.08);
}

.service-card h3 {
    font-size: 1.375rem;
    font-weight: 700;
    color: var(--secondary-color);
    padding: 24px 24px 12px;
    letter-spacing: -0.01em;
}

.service-card p {
    padding: 0 24px 28px;
    color: var(--text-light);
    line-height: 1.75;
}

@media (max-width: 992px) {
    .services-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
}

@media (max-width: 600px) {
    .service-card-header {
        padding: 20px 20px 16px;
        gap: 12px;
    }
    .service-icon {
        font-size: 2rem;
    }
    .service-body {
        padding: 16px 20px;
    }
    .service-card-list .btn-cotizar {
        margin: 0 20px 20px;
        width: calc(100% - 40px);
    }
}

/* ========================================
   GALLERY — MOSAICO COLLAGE
======================================== */
.gallery {
    background: var(--background-alt);
    padding-bottom: 70px;
}

.gallery-subtitle {
    text-align: center;
    color: var(--text-light);
    font-size: 1.0625rem;
    margin-top: -50px;
    margin-bottom: 40px;
    line-height: 1.7;
}

/* ── TABS ── */
.gallery-tabs {
    display: flex;
    justify-content: center;
    margin-bottom: 40px;
    gap: 12px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.gallery-tab {
    flex: 1;
    padding: 14px 24px;
    border: 2px solid var(--border-color);
    border-radius: 50px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 600;
    font-family: inherit;
    background: #fff;
    color: var(--text-light);
    transition: all 0.25s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    letter-spacing: 0.01em;
}

.gallery-tab:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    background: #eff4fd;
}

.gallery-tab.active {
    background: var(--primary-gradient);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 4px 20px rgba(28,76,158,0.35);
}

/* ── MOSAICO CUADRADO TIPO PINTEREST ── */
.gallery-mosaic {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: 220px;
    gap: 8px;
}

.gm-item {
    position: relative;
    overflow: hidden;
    cursor: zoom-in;
    border-radius: 8px;
    background: #d1d5db;
}

.gm-item img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    transition: transform 0.45s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    border-radius: 8px;
}

.gm-item:hover img {
    transform: scale(1.06);
}

/* ── OVERLAY ZOOM + CAPTION ── */
.gm-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(28, 76, 158, 0.85) 0%,
        rgba(28, 76, 158, 0.2) 40%,
        transparent 70%
    );
    opacity: 0;
    transition: opacity 0.35s ease;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-end;
    padding: 20px 18px;
    pointer-events: none;
}

.gm-item:hover .gm-overlay {
    opacity: 1;
}

.gm-caption {
    color: #fff;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    transform: translateY(6px);
    transition: transform 0.35s ease;
}

.gm-item:hover .gm-caption {
    transform: translateY(0);
}

/* ── ICONO LUPA en hover ── */

/* Variedad de tamaños tipo Pinterest */
.gm-item:nth-child(1)  { grid-row: span 2; }
.gm-item:nth-child(6)  { grid-row: span 2; }
.gm-item:nth-child(11) { grid-column: span 2; }
.gm-item:nth-child(16) { grid-row: span 2; }
.gm-item:nth-child(21) { grid-column: span 2; }
.gm-cta {
    cursor: pointer;
    min-height: 180px;
}

.gm-cta img {
    filter: brightness(0.3) saturate(0.5);
    transition: filter 0.4s ease, transform 0.5s ease;
}

.gm-cta:hover img {
    filter: brightness(0.2) saturate(0.3);
    transform: scale(1.04);
}

.gm-cta-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    pointer-events: none;
}

.gm-cta-count {
    font-size: 3rem;
    font-weight: 800;
    color: #fff;
    line-height: 1;
    letter-spacing: -0.03em;
    text-shadow: 0 2px 20px rgba(0,0,0,0.3);
}

.gm-cta-label {
    font-size: 0.75rem;
    font-weight: 700;
    color: rgba(255,255,255,0.8);
    text-transform: uppercase;
    letter-spacing: 0.15em;
}

/* ── NOTA ── */
.gallery-note {
    text-align: center;
    color: var(--text-light);
    font-size: 0.9375rem;
    margin-top: 32px;
    font-style: italic;
}

/* ── LIGHTBOX ── */
.gallery-lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.96);
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    padding: 20px;
}

.gallery-lightbox.active {
    opacity: 1;
    visibility: visible;
}

.gallery-lightbox-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    min-width: 0;
    flex: 1;
    max-width: calc(100vw - 160px);
}

.gallery-lightbox-content img {
    max-width: 100%;
    max-height: 84vh;
    object-fit: contain;
    border-radius: var(--radius);
    box-shadow: 0 40px 100px rgba(0,0,0,0.8);
    display: block;
    transition: opacity 0.2s ease;
}

.gallery-lightbox-caption {
    color: rgba(255,255,255,0.55);
    font-size: 0.75rem;
    font-weight: 500;
    text-align: center;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.gallery-lightbox-close {
    position: absolute;
    top: 20px;
    right: 24px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.15);
    color: #fff;
    font-size: 1.4rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.7;
    transition: opacity 0.2s ease, background 0.2s ease, transform 0.3s ease;
    z-index: 2;
}

.gallery-lightbox-close:hover {
    opacity: 1;
    background: rgba(255,255,255,0.15);
    transform: rotate(90deg);
}

.gallery-lightbox-nav {
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 50%;
    width: 52px;
    height: 52px;
    color: #fff;
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
    flex-shrink: 0;
}

.gallery-lightbox-nav:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
    transform: scale(1.1);
}

.gallery-lightbox-nav:disabled {
    opacity: 0.1;
    cursor: not-allowed;
    pointer-events: none;
}

/* ── RESPONSIVE ── */
@media (max-width: 1024px) {
    .gallery-mosaic {
        grid-template-columns: repeat(3, 1fr);
        grid-auto-rows: 180px;
        gap: 6px;
    }
}

@media (max-width: 640px) {
    .gallery-mosaic {
        grid-template-columns: repeat(2, 1fr);
        grid-auto-rows: 140px;
        gap: 5px;
    }
    .gm-item {
        border-radius: 5px;
    }
    .gm-item:nth-child(11),
    .gm-item:nth-child(21) { grid-column: span 1; }
    .gallery-lightbox {
        gap: 10px;
        padding: 12px 8px;
    }
    .gallery-lightbox-content {
        max-width: calc(100vw - 110px);
    }
    .gallery-lightbox-content img {
        max-height: 76vh;
    }
    .gallery-lightbox-nav {
        width: 42px;
        height: 42px;
        font-size: 1rem;
    }
    .gm-cta-count {
        font-size: 2.2rem;
    }
}


/* ========================================
   CLIENTS
======================================== */
.clients {
    background-color: var(--background);
    position: relative;
    overflow: hidden;
}

.clients::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--border-color), transparent);
}

.clients-single-image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.clients-single-image img {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.clients-single-image img:hover {
    box-shadow: var(--shadow-xl);
    transform: translateY(-5px);
}

/* ========================================
   CONTACT & LOCATION
======================================== */
.contact-location {
    background-color: var(--background);
    position: relative;
}

.contact-location::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--border-color), transparent);
}

.contact-location-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: stretch;
}

.contact-wrapper,
.location-wrapper {
    height: 100%;
}

.contact-form {
    background-color: var(--background);
    padding: 48px 40px;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--border-color);
}

.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--secondary-color);
    font-size: 0.9375rem;
    letter-spacing: 0.01em;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 16px 18px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius);
    transition: var(--transition);
    background-color: var(--background);
    font-size: 1rem;
    color: var(--text-color);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: #9ca3af;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(28, 76, 158, 0.1);
}

.form-group input.error,
.form-group textarea.error {
    border-color: var(--error-color);
    background-color: #fef2f2;
}

.form-group textarea {
    resize: vertical;
    min-height: 140px;
}

.error-message {
    display: block;
    color: var(--error-color);
    font-size: 0.8125rem;
    margin-top: 8px;
    font-weight: 500;
    min-height: 20px;
}

.success-message {
    display: none;
    background: linear-gradient(135deg, #deeaf8 0%, #a7f3d0 100%);
    color: #065f46;
    padding: 18px 24px;
    border-radius: var(--radius);
    text-align: center;
    margin-top: 24px;
    font-weight: 600;
    border: 1px solid #6ee7b7;
    animation: fadeInUp 0.5s ease;
}

.success-message.show {
    display: block;
}

@media (max-width: 768px) {
    .contact-form {
        padding: 32px 24px;
    }
}

/* ========================================
   LOCATION
======================================== */
.location-wrapper {
    display: flex;
    height: 100%;
}

.map-container {
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-color);
    width: 100%;
    height: 100%;
    min-height: 500px;
}

.map-container iframe {
    width: 100%;
    height: 100%;
}

/* ========================================
   FOOTER PROFESIONAL
======================================== */
.footer {
    background: var(--background-dark);
    color: #ffffff;
    padding: 70px 0 30px;
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr;
    gap: 60px;
    margin-bottom: 50px;
}

.footer-column h4 {
    font-size: 1.125rem;
    font-weight: 700;
    margin-bottom: 20px;
    color: #ffffff;
    letter-spacing: -0.01em;
}

.footer-desc {
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.8;
    font-size: 0.9375rem;
}

.footer-links,
.footer-contact {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    transition: var(--transition);
    font-size: 0.9375rem;
}

.footer-links a:hover {
    color: var(--primary-color);
    padding-left: 5px;
}

.footer-contact li {
    color: rgba(255, 255, 255, 0.7);
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.9375rem;
    transition: var(--transition);
}

.footer-contact li:hover {
    color: #ffffff;
}

.footer-contact svg {
    flex-shrink: 0;
    color: var(--primary-color);
}

.footer-bottom {
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.875rem;
    transition: var(--transition);
}

.footer-signature {
    margin-top: 12px;
    font-size: 0.8125rem;
    color: rgba(255, 255, 255, 0.4);
}

.footer-signature strong {
    color: var(--primary-color);
}

@media (max-width: 992px) {
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 32px;
        text-align: center;
    }

    .footer-contact li {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .footer {
        padding: 50px 0 24px;
    }
    .footer-grid {
        gap: 24px;
    }
}

/* ========================================
   BOTONES FLOTANTES
======================================== */
.floating-buttons {
    position: fixed;
    bottom: 30px;
    right: 30px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 999;
}

.floating-btn {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
    cursor: pointer;
}

.floating-whatsapp {
    background: #25D366;
    color: #ffffff;
}

.floating-whatsapp:hover {
    background: #128C7E;
    transform: scale(1.1);
    box-shadow: 0 8px 25px rgba(37, 211, 102, 0.4);
}

.floating-to-top {
    background: var(--secondary-color);
    color: #ffffff;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
}

.floating-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.floating-to-top:hover {
    background: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(28, 76, 158, 0.4);
}

@media (max-width: 768px) {
    .floating-buttons {
        bottom: 20px;
        right: 20px;
    }

    .floating-btn {
        width: 50px;
        height: 50px;
    }
}

/* ========================================
   RESPONSIVE
======================================== */
@media (max-width: 992px) {
    .section-title {
        font-size: 2rem;
    }

    .hero h1 {
        font-size: 2.75rem;
    }

    .contact-location-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .map-container {
        min-height: 380px;
    }
}

@media (max-width: 768px) {
    .nav-toggle {
        display: flex;
    }

    .nav-menu {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: linear-gradient(180deg, #ffffff 0%, #f9fafb 100%);
        flex-direction: column;
        padding: 24px;
        gap: 8px;
        box-shadow: var(--shadow-lg);
        transform: translateY(-10px);
        opacity: 0;
        visibility: hidden;
        transition: var(--transition);
    }

    .nav-menu.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }

    .nav-menu a {
        padding: 14px 0;
        border-bottom: 1px solid var(--border-color);
    }

    /* Botón Contáctanos en menú móvil — resetear estilos de lista */
    .nav-menu li:last-child a.btn-header {
        padding: 14px 32px !important;
        border-bottom: none;
        margin-top: 8px;
        display: block;
        text-align: center;
        border-radius: var(--radius);
    }

    .nav-menu a::after {
        display: none;
    }

    .hero {
        min-height: 600px;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .section {
        padding: 70px 0;
    }

    .section-title {
        font-size: 1.75rem;
        margin-bottom: 40px;
    }

    .about-content {
        gap: 40px;
    }

    .about-text h2 {
        font-size: 1.75rem;
    }

    .contact-form {
        padding: 32px 24px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }

    .hero h1 {
        font-size: 1.75rem;
    }

    .btn {
        padding: 14px 28px;
        font-size: 0.9375rem;
    }

    .section-title {
        font-size: 1.5rem;
    }

    .about-features li {
        padding: 12px 16px 12px 40px;
        font-size: 0.9375rem;
    }
}
