/* ===== VARIABLES ===== */
:root {
    /* Colores principales */
    --primary-color: #006EB8;
    --primary-dark: #005A94;
    --primary-light: #4D9AD9;
    --secondary-color: #FF8C00;
    --secondary-dark: #E67E00;
    --secondary-light: #FFA333;
    
    /* Colores neutros */
    --dark: #1A2B3C;
    --dark-gray: #546677;
    --medium-gray: #8896A6;
    --light-gray: #CCD6E0;
    --lightest-gray: #F5F7F9;
    --white: #FFFFFF;
    
    /* Fuentes */
    --font-primary: 'Montserrat', sans-serif;
    --font-secondary: 'Poppins', sans-serif;
    
    /* Tamaños */
    --container-width: 1200px;
    --border-radius: 8px;
    --transition-speed: 0.3s;
}

/* ===== RESET Y BASE ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-primary);
    font-size: 16px;
    line-height: 1.6;
    color: var(--dark);
    background-color: var(--white);
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
}

a {
    text-decoration: none;
    color: var(--primary-color);
    transition: color var(--transition-speed) ease;
}

a:hover {
    color: var(--primary-dark);
}

ul {
    list-style: none;
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

section {
    padding: 100px 0;
}

/* ===== ENCABEZADOS ===== */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-primary);
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 20px;
}

h1 {
    font-size: 3.5rem;
}

h2 {
    font-size: 2.5rem;
}

h3 {
    font-size: 1.8rem;
}

h4 {
    font-size: 1.3rem;
}

/* ===== BOTONES ===== */
.btn {
    display: inline-block;
    padding: 12px 28px;
    font-size: 1rem;
    font-weight: 600;
    text-align: center;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all var(--transition-speed) ease;
    border: none;
    font-family: var(--font-primary);
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.9rem;
}

.btn-primary {
    background-color: var(--primary-color);
    color: var(--white);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    color: var(--white);
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: var(--white);
}

.btn-secondary:hover {
    background-color: var(--secondary-dark);
    color: var(--white);
}

.btn-outline {
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-outline:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

.btn-white {
    background-color: var(--white);
    color: var(--primary-color);
}

.btn-white:hover {
    background-color: var(--lightest-gray);
    color: var(--primary-dark);
}

.btn-full {
    width: 100%;
}

/* ===== SECCIONES GENERALES ===== */
.section-header {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 60px;
}

.section-header.light {
    color: var(--white);
}

.section-header.light h2 {
    color: var(--white);
}

.section-header p {
    font-size: 1.2rem;
    color: var(--dark-gray);
}

.section-header.light p {
    color: var(--lightest-gray);
}

/* ===== HEADER Y NAVEGACIÓN ===== */
header {
    position: relative;
    background: linear-gradient(135deg, var(--dark) 0%, var(--primary-dark) 100%);
    color: var(--white);
    padding: 0;
    overflow: hidden;
}

header::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 50%;
    height: 100%;
    background-image: url('images/header.jpg');
    background-size: cover;
    background-position: center;
    opacity: 0.1;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    position: relative;
    z-index: 100;
}

.logo img {
    height: 50px;
}

.menu {
    display: flex;
    gap: 30px;
}

.menu a {
    color: var(--white);
    font-weight: 500;
    position: relative;
    padding: 5px 0;
}

.menu a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--secondary-color);
    transition: width var(--transition-speed) ease;
}

.menu a:hover::after, .menu a.active::after {
    width: 100%;
}

.menu a.btn-contacto {
    background-color: var(--secondary-color);
    color: var(--white);
    padding: 8px 20px;
    border-radius: var(--border-radius);
}

.menu a.btn-contacto:hover {
    background-color: var(--secondary-dark);
}

.menu a.btn-contacto::after {
    display: none;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
}

.menu-toggle span {
    display: block;
    width: 30px;
    height: 3px;
    background-color: var(--white);
    transition: all var(--transition-speed) ease;
}

/* Hero Section */
.hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
    min-height: calc(100vh - 90px);
    padding: 60px 0;
}

.hero-content h1 {
    margin-bottom: 24px;
    font-size: 3.5rem;
    line-height: 1.2;
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 40px;
    color: var(--lightest-gray);
}

.hero-buttons {
    display: flex;
    gap: 20px;
}

.hero-image {
    position: relative;
    z-index: 10;
}

.hero-image img {
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    transform: perspective(1000px) rotateY(-10deg);
    transition: transform var(--transition-speed) ease;
}

.hero-image img:hover {
    transform: perspective(1000px) rotateY(0);
}

/* ===== CARACTERÍSTICAS ===== */
#caracteristicas {
    background-color: var(--lightest-gray);
    position: relative;
    overflow: hidden;
}

#caracteristicas::before {
    content: '';
    position: absolute;
    top: -150px;
    left: 0;
    width: 100%;
    height: 300px;
    background-color: var(--white);
    transform: skewY(-3deg);
    z-index: 0;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    position: relative;
    z-index: 10;
}

.feature-card {
    background-color: var(--white);
    padding: 30px;
    border-radius: var(--border-radius);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    transition: transform var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
}

.feature-icon {
    width: 80px;
    height: 80px;
    margin-bottom: 20px;
    border-radius: 50%;
    overflow: hidden;
}

.feature-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.feature-card h3 {
    color: var(--primary-dark);
    margin-bottom: 15px;
}

/* ===== SERVICIOS ===== */
#servicios {
    background-color: var(--white);
    position: relative;
}

.services-wrapper {
    display: flex;
    flex-direction: column;
    background-color: var(--white);
    border-radius: var(--border-radius);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.services-tabs {
    display: flex;
    background-color: var(--lightest-gray);
    border-bottom: 1px solid var(--light-gray);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.tab {
    padding: 16px 24px;
    font-weight: 600;
    color: var(--dark-gray);
    cursor: pointer;
    transition: all var(--transition-speed) ease;
    white-space: nowrap;
    border-bottom: 3px solid transparent;
}

.tab.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

.tab:hover:not(.active) {
    color: var(--primary-dark);
    background-color: rgba(204, 214, 224, 0.3);
}

.service-tab-content {
    display: none;
    padding: 40px;
}

.service-tab-content.active {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
}

.service-image img {
    border-radius: var(--border-radius);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: transform var(--transition-speed) ease;
}

.service-image img:hover {
    transform: scale(1.03);
}

.service-details h3 {
    color: var(--primary-dark);
    margin-bottom: 20px;
}

.service-details p {
    margin-bottom: 20px;
}

.service-details ul {
    margin-bottom: 30px;
    padding-left: 20px;
}

.service-details ul li {
    position: relative;
    padding-left: 25px;
    margin-bottom: 10px;
}

.service-details ul li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--secondary-color);
    font-weight: bold;
}

/* ===== PROCESO ===== */
#proceso {
    background-color: var(--lightest-gray);
    position: relative;
}

.process-timeline {
    position: relative;
}

.process-timeline::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 100%;
    background-color: var(--primary-light);
    opacity: 0.3;
}

.process-step {
    display: flex;
    align-items: center;
    margin-bottom: 80px;
    position: relative;
}

.process-step:last-child {
    margin-bottom: 0;
}

.process-step:nth-child(odd) {
    flex-direction: row-reverse;
}

.step-number {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    font-weight: bold;
    position: relative;
    z-index: 10;
    box-shadow: 0 10px 20px rgba(0, 110, 184, 0.3);
}

.step-content {
    width: calc(50% - 60px);
    background-color: var(--white);
    padding: 30px;
    border-radius: var(--border-radius);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    position: relative;
}

.step-content::before {
    content: '';
    position: absolute;
    top: 50%;
    width: 20px;
    height: 20px;
    background-color: var(--white);
    transform: rotate(45deg) translateY(-50%);
}

.process-step:nth-child(odd) .step-content::before {
    left: -10px;
}

.process-step:nth-child(even) .step-content::before {
    right: -10px;
}

.step-content h3 {
    color: var(--primary-dark);
    margin-bottom: 10px;
}

/* ===== EQUIPO ===== */
#equipo {
    background-color: var(--white);
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.team-member {
    background-color: var(--lightest-gray);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    transition: transform var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
}

.team-member:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
}

.member-photo {
    height: 300px;
    overflow: hidden;
}

.member-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-speed) ease;
}

.team-member:hover .member-photo img {
    transform: scale(1.05);
}

.team-member h3 {
    padding: 20px 20px 5px;
    margin-bottom: 0;
    color: var(--primary-dark);
}

.member-position {
    padding: 0 20px;
    color: var(--primary-color);
    font-weight: 600;
    margin-bottom: 10px;
}

.member-bio {
    padding: 0 20px 20px;
    font-size: 0.95rem;
}

/* ===== TESTIMONIOS ===== */
#testimonios {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: var(--white);
    position: relative;
    overflow: hidden;
}

#testimonios::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('images/test.jpg');
    background-size: cover;
    background-position: center;
    opacity: 0.1;
}

.testimonial-slider {
    position: relative;
    z-index: 10;
}

.testimonial-container {
    position: relative;
    min-height: 300px;
}

.testimonial {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-speed) ease;
}

.testimonial.active {
    opacity: 1;
    visibility: visible;
}

.testimonial-content {
    background-color: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 40px;
    border-radius: var(--border-radius);
    position: relative;
}

.quote-icon {
    position: absolute;
    top: 20px;
    left: 20px;
    font-size: 3rem;
    color: rgba(255, 255, 255, 0.2);
}

.testimonial-content p {
    margin-bottom: 30px;
    font-size: 1.1rem;
    position: relative;
    z-index: 10;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 15px;
}

.testimonial-author img {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--white);
}

.testimonial-author h4 {
    margin-bottom: 5px;
    font-size: 1.1rem;
}

.testimonial-author p {
    margin-bottom: 0;
    font-size: 0.9rem;
    opacity: 0.8;
}

.testimonial-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 40px;
}

.prev-testimonial, .next-testimonial {
    background-color: rgba(255, 255, 255, 0.2);
    color: var(--white);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: none;
    font-size: 1.2rem;
    transition: background-color var(--transition-speed) ease;
}

.prev-testimonial:hover, .next-testimonial:hover {
    background-color: rgba(255, 255, 255, 0.3);
}

.testimonial-dots {
    display: flex;
    gap: 10px;
    margin: 0 20px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.2);
    cursor: pointer;
    transition: background-color var(--transition-speed) ease;
}

.dot.active {
    background-color: var(--white);
}

.dot:hover:not(.active) {
    background-color: rgba(255, 255, 255, 0.4);
}

/* ===== CTA ===== */
#cta {
    background: linear-gradient(135deg, var(--secondary-color) 0%, var(--secondary-dark) 100%);
    color: var(--white);
    padding: 80px 0;
    text-align: center;
}

.cta-content {
    max-width: 800px;
    margin: 0 auto;
}

.cta-content h2 {
    margin-bottom: 20px;
}

.cta-content p {
    margin-bottom: 30px;
    font-size: 1.2rem;
}

/* ===== CONTACTO ===== */
#contacto {
    background-color: var(--white);
}

.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 20px;
    background-color: var(--lightest-gray);
    padding: 20px;
    border-radius: var(--border-radius);
    transition: transform var(--transition-speed) ease;
}

.info-item:hover {
    transform: translateX(5px);
}

.info-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
}

.info-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.info-item h3 {
    font-size: 1.2rem;
    margin-bottom: 5px;
    color: var(--primary-dark);
}

.info-item p {
    margin-bottom: 0;
}

.map-container {
    margin-top: 20px;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.contact-form {
    background-color: var(--lightest-gray);
    padding: 40px;
    border-radius: var(--border-radius);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}

.form-group input, 
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--light-gray);
    border-radius: var(--border-radius);
    font-family: var(--font-primary);
    font-size: 1rem;
    transition: border-color var(--transition-speed) ease;
}

.form-group input:focus, 
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
}

.checkbox-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.checkbox-group input {
    width: auto;
}

.checkbox-group label {
    margin-bottom: 0;
}

/* ===== FAQ ===== */
#faq {
    background-color: var(--lightest-gray);
}

.faq-container {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    background-color: var(--white);
    border-radius: var(--border-radius);
    margin-bottom: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.faq-question {
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
}

.faq-question h3 {
    margin-bottom: 0;
    font-size: 1.2rem;
    color: var(--primary-dark);
    flex: 1;
}

.faq-toggle {
    font-size: 1.5rem;
    color: var(--primary-color);
    font-weight: bold;
}

.faq-answer {
    padding: 0;
    max-height: 0;
    overflow: hidden;
    transition: all var(--transition-speed) ease;
}

.faq-answer p {
    padding: 0 20px 20px;
}

.faq-item.active .faq-toggle {
    transform: rotate(45deg);
}

.faq-item.active .faq-answer {
    max-height: 300px;
}

/* ===== NEWSLETTER ===== */
#newsletter {
    background-color: var(--white);
    padding: 80px 0;
}

.newsletter-content {
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--primary-color) 100%);
    padding: 50px;
    border-radius: var(--border-radius);
    display: flex;
    align-items: center;
    gap: 40px;
    color: var(--white);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.newsletter-text {
    flex: 1;
}

.newsletter-text h2 {
    margin-bottom: 15px;
}

.newsletter-text p {
    margin-bottom: 0;
}

.newsletter-form {
    flex: 1;
}

.form-row {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

.form-row input {
    flex: 1;
    padding: 14px;
    border: none;
    border-radius: var(--border-radius);
    font-size: 1rem;
}

.form-row input:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.3);
}

.form-privacy {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
}

.form-privacy input {
    margin: 0;
}

.form-privacy a {
    color: var(--white);
    text-decoration: underline;
}

/* ===== FOOTER ===== */
footer {
    background-color: var(--dark);
    color: var(--light-gray);
    padding: 80px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: 1.5fr 2fr;
    gap: 60px;
    margin-bottom: 40px;
}

.footer-logo img {
    height: 50px;
    margin-bottom: 20px;
}

.footer-logo p {
    font-size: 0.95rem;
    max-width: 300px;
}

.footer-links {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.footer-column h3 {
    color: var(--white);
    font-size: 1.2rem;
    margin-bottom: 20px;
}

.footer-column ul {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-column a {
    color: var(--light-gray);
    transition: color var(--transition-speed) ease;
}

.footer-column a:hover {
    color: var(--white);
}

.footer-bottom {
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
    font-size: 0.9rem;
}

/* ===== COOKIE CONSENT ===== */
.cookie-consent {
    position: fixed;
    bottom: 20px;
    left: 20px;
    background-color: var(--white);
    padding: 20px;
    border-radius: var(--border-radius);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    max-width: 400px;
    display: none;
}

.cookie-content p {
    margin-bottom: 15px;
    font-size: 0.95rem;
}

.cookie-buttons {
    display: flex;
    gap: 10px;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
    h1 {
        font-size: 3rem;
    }
    
    h2 {
        font-size: 2.2rem;
    }
    
    section {
        padding: 80px 0;
    }
    
    .hero {
        min-height: auto;
        padding: 60px 0;
    }
    
    .process-step {
        margin-bottom: 60px;
    }
    
    .newsletter-content {
        flex-direction: column;
        text-align: center;
        padding: 40px 30px;
    }
}

@media (max-width: 900px) {
    .menu-toggle {
        display: flex;
    }
    
    .menu {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        flex-direction: column;
        gap: 0;
        background-color: var(--dark);
        box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
        padding: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height var(--transition-speed) ease;
        z-index: 100;
    }
    
    .menu.active {
        max-height: 500px;
    }
    
    .menu li {
        width: 100%;
    }
    
    .menu a {
        display: block;
        padding: 15px 20px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .menu a::after {
        display: none;
    }
    
    .menu a.btn-contacto {
        margin: 15px 20px;
        text-align: center;
    }
    
    .hero {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .service-tab-content.active {
        grid-template-columns: 1fr;
    }
    
    .contact-wrapper {
        grid-template-columns: 1fr;
    }
    
    .process-timeline::before {
        left: 30px;
    }
    
    .process-step, .process-step:nth-child(odd) {
        flex-direction: row;
    }
    
    .step-content, .process-step:nth-child(odd) .step-content {
        width: calc(100% - 100px);
    }
    
    .step-content::before, .process-step:nth-child(odd) .step-content::before {
        left: -10px;
        right: auto;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .footer-links {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    h1 {
        font-size: 2.5rem;
    }
    
    h2 {
        font-size: 2rem;
    }
    
    section {
        padding: 60px 0;
    }
    
    .btn {
        padding: 10px 20px;
    }
    
    .section-header {
        margin-bottom: 40px;
    }
    
    .section-header p {
        font-size: 1.1rem;
    }
    
    .service-tab-content {
        padding: 20px;
    }
    
    .team-grid {
        grid-template-columns: 1fr;
    }
    
    .newsletter-content {
        padding: 30px 20px;
    }
    
    .form-row {
        flex-direction: column;
    }
    
    .footer-links {
        grid-template-columns: 1fr;
    }
    
    .footer-bottom {
        font-size: 0.8rem;
    }
    
    .cookie-consent {
        left: 10px;
        right: 10px;
        max-width: none;
    }
}