/* ============================================ */
/* VARIABLES Y CONFIGURACIÓN GENERAL            */
/* ============================================ */
:root {
    --primary-dark: #1a2a3a;
    --primary-medium: #2c3e50;
    --steel-gray: #4a5a6a;
    --accent: #e67e22;
    --accent-hover: #cf6d17;
    --white: #ffffff;
    --light-bg: #f4f6f8;
    --text-dark: #1a2a3a;
    --text-muted: #6c757d;
    --shadow: 0 4px 20px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 40px rgba(0,0,0,0.15);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Roboto', sans-serif;
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
}

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

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

/* ============================================ */
/* NAVBAR                                       */
/* ============================================ */
#mainNav {
    background: transparent;
    padding: 15px 0;
    transition: all 0.4s ease;
    z-index: 1050;
}

#mainNav.scrolled {
    background: rgba(26, 42, 58, 0.97);
    padding: 8px 0;
    box-shadow: 0 2px 20px rgba(0,0,0,0.3);
}

.logo-img {
    height: 45px;
    width: auto;
    border-radius: 4px;
    transition: var(--transition);
}

#mainNav.scrolled .logo-img {
    height: 38px;
}

.brand-text {
    font-weight: 700;
    font-size: 1.2rem;
    letter-spacing: 0.5px;
}

.contact-info-top a {
    font-size: 0.85rem;
    opacity: 0.9;
}

.contact-info-top a:hover {
    opacity: 1;
    color: var(--accent) !important;
}

.nav-link {
    font-weight: 500;
    font-size: 0.95rem;
    padding: 8px 16px !important;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 60%;
}

.nav-link:hover {
    color: var(--accent) !important;
}

/* ============================================ */
/* HERO SECTION                                 */
/* ============================================ */
.hero-section {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    background-image: url('Imagenes/hero.jpeg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(26, 42, 58, 0.88) 0%, rgba(44, 62, 80, 0.75) 100%);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-title {
    font-size: 3.2rem;
    font-weight: 900;
    color: var(--white);
    line-height: 1.15;
    margin-bottom: 1.2rem;
    text-transform: uppercase;
    letter-spacing: -0.5px;
}

.hero-subtitle {
    font-size: 1.25rem;
    font-weight: 300;
    color: rgba(255,255,255,0.85);
    line-height: 1.6;
    margin-bottom: 0;
}

.btn-cta {
    background: var(--accent);
    color: var(--white);
    border: none;
    padding: 14px 36px;
    font-weight: 700;
    font-size: 1.05rem;
    border-radius: 6px;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(230, 126, 34, 0.4);
}

.btn-cta:hover {
    background: var(--accent-hover);
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(230, 126, 34, 0.5);
}

/* ============================================ */
/* SECCIONES BASE                               */
/* ============================================ */
.text-justified {
    text-align: justify;
}

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

.section-dark {
    background: var(--primary-dark);
}

.section-accent {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-medium) 100%);
}

.section-badge {
    display: inline-block;
    background: var(--accent);
    color: var(--white);
    padding: 4px 16px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 1rem;
}

.section-badge.light {
    background: rgba(230, 126, 34, 0.2);
    border: 1px solid var(--accent);
}

.section-title {
    font-weight: 800;
    font-size: 2.2rem;
    margin-bottom: 1rem;
    color: var(--text-dark);
}

.section-dark .section-title,
.section-accent .section-title {
    color: var(--white);
}

/* ============================================ */
/* VALUE CARDS (NOSOTROS)                       */
/* ============================================ */
.value-card {
    background: var(--white);
    border-radius: 12px;
    box-shadow: var(--shadow);
    transition: var(--transition);
    border: 1px solid rgba(0,0,0,0.05);
}

.value-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.value-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 15px;
    background: linear-gradient(135deg, var(--accent), var(--accent-hover));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: var(--white);
}

.value-card h5 {
    font-weight: 700;
    font-size: 1rem;
    margin-bottom: 8px;
    color: var(--primary-dark);
}

/* ============================================ */
/* SERVICE CARDS                                */
/* ============================================ */
.service-card {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all 0.4s ease;
    border: 1px solid rgba(0,0,0,0.05);
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.service-img-wrapper {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.service-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

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

.service-img-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(26, 42, 58, 0.3), rgba(26, 42, 58, 0.7));
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.service-card:hover .service-img-overlay {
    opacity: 1;
}

.service-img-overlay i {
    font-size: 3rem;
    color: var(--white);
}

.service-body {
    padding: 24px;
}

.service-body h4 {
    font-weight: 700;
    font-size: 1.2rem;
    margin-bottom: 12px;
    color: var(--primary-dark);
}

.service-body p {
    color: var(--text-muted);
    font-size: 0.92rem;
    margin-bottom: 16px;
}

.service-features {
    list-style: none;
    padding: 0;
    margin: 0;
}

.service-features li {
    font-size: 0.85rem;
    color: var(--steel-gray);
    padding: 4px 0;
}

.service-features li i {
    color: var(--accent);
    margin-right: 8px;
    font-size: 0.75rem;
}

/* ============================================ */
/* GALLERY                                      */
/* ============================================ */
.gallery-item {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    cursor: pointer;
}

.gallery-item img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.gallery-item:hover img {
    transform: scale(1.1);
}

.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(26, 42, 58, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.4s ease;
}

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

.gallery-overlay span {
    color: var(--white);
    font-weight: 700;
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* ============================================ */
/* CLIENTS TABLE                                */
/* ============================================ */
.clients-table {
    background: var(--white);
    border-radius: 10px;
    overflow: hidden;
}

.clients-table thead {
    background: var(--primary-dark);
    color: var(--white);
}

.clients-table th {
    padding: 14px 20px;
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: none;
}

.clients-table td {
    padding: 14px 20px;
    font-size: 0.9rem;
    vertical-align: middle;
    border-color: #eee;
}

.clients-table tbody tr:hover {
    background: rgba(230, 126, 34, 0.05);
}

/* ============================================ */
/* ADVANTAGE CARDS                              */
/* ============================================ */
.advantage-card {
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 12px;
    padding: 30px 20px;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.advantage-card:hover {
    background: rgba(255,255,255,0.18);
    transform: translateY(-5px);
    border-color: var(--accent);
}

.advantage-icon {
    width: 70px;
    height: 70px;
    margin: 0 auto 20px;
    background: var(--accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: var(--white);
}

.advantage-card h5 {
    color: var(--white);
    font-weight: 700;
    font-size: 1.05rem;
    margin-bottom: 10px;
}

.advantage-card p {
    color: rgba(255,255,255,0.7);
    font-size: 0.9rem;
    margin-bottom: 0;
}

.commitment-badge {
    display: inline-block;
    padding: 20px 50px;
    border: 3px solid var(--accent);
    border-radius: 60px;
}

.commitment-number {
    display: block;
    font-size: 3rem;
    font-weight: 900;
    color: var(--accent);
    line-height: 1;
}

.commitment-text {
    display: block;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--white);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-top: 5px;
}

/* ============================================ */
/* TESTIMONIALS                                 */
/* ============================================ */
.testimonial-card {
    background: var(--white);
    border-radius: 12px;
    padding: 30px;
    box-shadow: var(--shadow);
    border: 1px solid rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

.testimonial-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.testimonial-quote {
    font-size: 2rem;
    color: var(--accent);
    margin-bottom: 15px;
    opacity: 0.6;
}

.testimonial-card p {
    font-style: italic;
    color: var(--steel-gray);
    font-size: 0.95rem;
    line-height: 1.7;
    margin-bottom: 20px;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 12px;
}

.author-avatar {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-medium));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1.2rem;
    flex-shrink: 0;
}

.testimonial-author strong {
    display: block;
    font-size: 0.95rem;
    color: var(--primary-dark);
}

.testimonial-author span {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* ============================================ */
/* CONTACT FORM                                 */
/* ============================================ */
.contact-form .form-control {
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.2);
    color: var(--white);
    padding: 12px 16px;
    border-radius: 8px;
    transition: var(--transition);
}

.contact-form .form-control:focus {
    background: rgba(255,255,255,0.12);
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(230, 126, 34, 0.2);
    color: var(--white);
}

.contact-form .form-control::placeholder {
    color: rgba(255,255,255,0.4);
}

.contact-form .form-label {
    color: rgba(255,255,255,0.85);
    font-weight: 500;
    font-size: 0.9rem;
}

.contact-form .invalid-feedback {
    color: #ff6b6b;
}

.contact-form .form-control.is-invalid {
    border-color: #ff6b6b;
}

/* ============================================ */
/* CONTACT INFO CARD                            */
/* ============================================ */
.contact-info-card {
    background: var(--white);
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.contact-info-card h4 {
    color: var(--primary-dark);
    font-weight: 700;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    gap: 15px;
}

.contact-item i {
    width: 40px;
    height: 40px;
    background: rgba(230, 126, 34, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
    font-size: 1rem;
    flex-shrink: 0;
    margin-top: 2px;
}

.contact-item strong {
    display: block;
    font-size: 0.9rem;
    color: var(--primary-dark);
}

.contact-item a {
    color: var(--steel-gray);
}

.contact-item a:hover {
    color: var(--accent);
}

.text-accent {
    color: var(--accent) !important;
}

/* ============================================ */
/* MAP                                          */
/* ============================================ */
.map-wrapper {
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.map-wrapper iframe {
    display: block;
    width: 100%;
    border-radius: 12px;
}

/* ============================================ */
/* FOOTER                                       */
/* ============================================ */
.footer-section {
    background: #0f1a26;
    border-top: 3px solid var(--accent);
}

.footer-logo {
    height: 40px;
    width: auto;
    border-radius: 4px;
}

.footer-section p,
.footer-section .small {
    color: rgba(255,255,255,0.7);
}

.footer-section p.text-muted {
    color: rgba(255,255,255,0.7) !important;
}

.footer-contact a {
    color: rgba(255,255,255,0.7);
}

.footer-contact a:hover {
    color: var(--accent);
}

.footer-contact i {
    color: var(--accent);
    width: 16px;
}

.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    color: var(--white);
    margin-left: 8px;
    font-size: 1rem;
    transition: var(--transition);
}

.social-links a:hover {
    background: var(--accent);
    color: var(--white);
    transform: translateY(-3px);
}

/* ============================================ */
/* ANIMACIONES (FADE-IN)                        */
/* ============================================ */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered animation delays for grid items */
.row .fade-in:nth-child(2) { transition-delay: 0.1s; }
.row .fade-in:nth-child(3) { transition-delay: 0.2s; }
.row .fade-in:nth-child(4) { transition-delay: 0.3s; }
.row .fade-in:nth-child(5) { transition-delay: 0.4s; }
.row .fade-in:nth-child(6) { transition-delay: 0.5s; }

/* ============================================ */
/* RESPONSIVE                                   */
/* ============================================ */

/* Tablets */
@media (max-width: 991.98px) {
    .hero-title {
        font-size: 2.4rem;
    }

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

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

    #mainNav .navbar-collapse {
        background: rgba(26, 42, 58, 0.98);
        padding: 20px;
        border-radius: 10px;
        margin-top: 10px;
    }

    .hero-section {
        background-attachment: scroll;
    }
}

/* Mobile */
@media (max-width: 767.98px) {
    .hero-title {
        font-size: 1.8rem;
    }

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

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

    .btn-cta {
        padding: 12px 28px;
        font-size: 0.95rem;
    }

    .service-img-wrapper {
        height: 160px;
    }

    .gallery-item img {
        height: 140px;
    }

    .commitment-badge {
        padding: 15px 30px;
    }

    .commitment-number {
        font-size: 2.2rem;
    }

    .commitment-text {
        font-size: 0.9rem;
    }

    .testimonial-card {
        padding: 20px;
    }

    .clients-table th,
    .clients-table td {
        padding: 10px 12px;
        font-size: 0.8rem;
    }
}

/* Small mobile */
@media (max-width: 575.98px) {
    .hero-title {
        font-size: 1.5rem;
    }

    .value-card {
        padding: 20px 10px !important;
    }

    .value-icon {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }

    .value-card h5 {
        font-size: 0.85rem;
    }
}