/* Variables y Reset */
:root {
    --primary-color: #04328d;
    --secondary-color: #ffffff;
    --accent-color: #0056b3;
    --text-dark: #333333;
    --text-light: #666666;
    --gradient: linear-gradient(135deg, #04328d 0%, #0056b3 100%);
    --gradient-purple: linear-gradient(135deg, #667eea 0%, #2e4b89 100%);
    --gradient-orange: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --gradient-green: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    --shadow: 0 10px 30px rgba(4, 50, 141, 0.1);
    --shadow-hover: 0 15px 40px rgba(4, 50, 141, 0.2);
    --border-radius: 12px;
    --border-radius-large: 20px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    overflow-x: hidden;
    background: #fafbfc;
    width: 100vw;
}

/* Header Responsivo */
.header {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 1);
    backdrop-filter: blur(20px);
    z-index: 1000;
    transition: var(--transition);
    box-shadow: var(--shadow);
}

.header.scrolled {
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 5px 20px rgba(4, 50, 141, 0.15);
}

.nav-container {
    max-width: 1400px;
    width: 100%;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-container img {
    width: 300px;
    height: fit-content;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 1.5rem;
}

.nav-link {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 500;
    transition: var(--transition);
    position: relative;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: 1rem;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-color);
    background: rgba(4, 50, 141, 0.05);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--gradient);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 80%;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--primary-color);
    padding: 0.5rem;
    border-radius: 8px;
    transition: var(--transition);
}

.menu-toggle:hover {
    background: rgba(4, 50, 141, 0.1);
}

/* Main Content Responsivo */
main {
    margin-top: 80px;
    overflow: hidden;
}

/* Hero Responsivo */
.hero {
    background: url('../img/fondo-servicios-hamilton-segura.webp');
    background-position: center;
    background-size: cover;
    color: var(--secondary-color);
    padding: 4rem 1rem;
    position: relative;
    overflow: hidden;
    height: 600px;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #1a1a1a;
    opacity: 0.7;
}

.hero-content {
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    align-items: center;
}

.hero-text {
    flex: 1;
    min-width: 300px;
}

.hero-visual {
    flex: 1;
    min-width: 300px;
}

.hero-text h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.hero-text .subtitle {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    opacity: 0.9;
    font-weight: 600;
}

.hero-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin: 2rem 0;
}

.stat-item {
    text-align: center;
    min-width: 120px;
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    display: block;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.85rem;
    opacity: 0.8;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.floating-cards {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.floating-card {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    padding: 1.5rem;
    border-radius: var(--border-radius);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.floating-card h4 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.floating-card p {
    font-size: 0.95rem;
    opacity: 0.9;
}

/* Services Responsivo */
.services-section {
    padding: 4rem 1rem;
    background: var(--secondary-color);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.section-header {
    text-align: center;
    margin-bottom: 2rem;
}

.section-title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 1rem;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: var(--gradient);
    border-radius: 2px;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--text-light);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

.services-masonry {
    display: grid;
    grid-template-columns: repeat(2, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.service-card {
    background: var(--secondary-color);
    border-radius: var(--border-radius-large);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-hover);
}

.service-header {
    padding: 1.5rem;
    background: var(--gradient);
    color: var(--secondary-color);
    position: relative;
}

.service-header.purple {
    background: var(--gradient-purple);
}

.service-header.orange {
    background: var(--gradient-orange);
}

.service-header.green {
    background: var(--gradient-green);
}

.service-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    display: block;
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.service-card .service-subtitle {
    opacity: 0.9;
    font-size: 1rem;
}

.service-content {
    padding: 1.5rem;
}

.service-content p {
    color: var(--text-light);
    line-height: 1.7;
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
}

.service-features {
    list-style: none;
}

.service-features li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
    color: var(--text-dark);
    font-size: 0.95rem;
}

.service-features li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--success-color);
    font-weight: bold;
}

/* Timeline Responsivo */
.experience-section {
    padding: 4rem 1rem;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    position: relative;
}

.timeline {
    position: relative;
    margin-top: 2rem;
    padding-left: 30px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: var(--gradient);
}

.timeline-item {
    position: relative;
    margin: 2.5rem 0;
    padding-left: 30px;
}

.timeline-dot {
    position: absolute;
    left: -9px;
    top: 5px;
    width: 20px;
    height: 20px;
    background: var(--gradient);
    border-radius: 50%;
    border: 4px solid var(--secondary-color);
    z-index: 2;
}

.timeline-content {
    background: var(--secondary-color);
    padding: 1.5rem;
    border-radius: var(--border-radius-large);
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.timeline-content:hover {
    transform: scale(1.02);
    box-shadow: var(--shadow-hover);
}

.timeline-year {
    background: var(--gradient);
    color: var(--secondary-color);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: 600;
    display: inline-block;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.timeline-content h4 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    font-size: 1.2rem;
}

.timeline-content .station {
    color: var(--accent-color);
    font-weight: 500;
    margin-bottom: 1rem;
    font-size: 1rem;
}

/* Current Program Responsivo */
.services-section.fade-in {
    background: var(--gradient-purple);
    color: white;
    padding: 4rem 1rem;
}

.section-header .section-title {
    color: var(--primary-color);
}

.section-title-servicios {
    font-size: 2rem;
    color: var(--secondary-color);
}

.section-subtitle-servicios {
    color: var(--secondary-color);
}

.section-header .section-subtitle {
    color: var(--text-dark);
}

.program-highlight {
    background: rgba(255, 255, 255, 0.1);
    padding: 2rem;
    border-radius: var(--border-radius-large);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    max-width: 800px;
    margin: 0 auto;
}

.program-highlight img {
    width: 100%;
    height: fit-content;
    border-radius: 12px;
    display: flex;
    align-self: center;
    justify-self: center;
}

.program-highlight h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.program-highlight p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    opacity: 0.9;
    text-align: center;
}

.program-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.program-details>div {
    text-align: center;
}

.program-details h4 {
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

/* CTA Responsivo */
.cta-section {
    background: var(--primary-color);
    color: var(--secondary-color);
    padding: 4rem 1rem;
    position: relative;
    overflow: hidden;
}

.cta-content {
    max-width: 1000px;
    margin: 0 auto;
    text-align: center;
    position: relative;
    z-index: 2;
}

.cta-content h2 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
}

.cta-content p {
    font-size: 1.1rem;
    margin-bottom: 3rem;
    opacity: 0.9;
}

.cta-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.cta-item {
    background: rgba(255, 255, 255, 0.1);
    padding: 1.5rem;
    border-radius: var(--border-radius);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: var(--transition);
}

.cta-item:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-5px);
}

.cta-icon {
    font-size: 2rem;
    margin-bottom: 1rem;
    display: block;
}

.cta-item h4 {
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.btn {
    padding: 1rem 1.8rem;
    border: none;
    border-radius: var(--border-radius);
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: var(--transition);
    cursor: pointer;
    font-size: 1rem;
    margin: 0.5rem;
}

.btn-primary {
    background: var(--secondary-color);
    color: var(--primary-color);
    box-shadow: 0 4px 15px rgba(255, 255, 255, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 255, 255, 0.4);
}

.btn-secondary {
    background: transparent;
    color: var(--secondary-color);
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--secondary-color);
}

/* Footer Responsivo */
.footer {
    background: #1a1a1a;
    color: var(--secondary-color);
    padding: 3rem 1rem 1rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3 {
    margin-bottom: 1.2rem;
    font-size: 1.2rem;
    color: var(--secondary-color);
}

.footer-section p,
.footer-section a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    line-height: 1.8;
    transition: var(--transition);
    font-size: 0.95rem;
}

.footer-section a:hover {
    color: var(--secondary-color);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 1.5rem;
    margin-top: 2rem;
    text-align: center;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
}

.footer-section>ul {
    font-size: 0.9rem;
    padding: 0px 15px;
    list-style-position: inside;
}

.footer-section>ul>li {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 0.5rem;
}

.footer-content>img {
    width: 200px;
    height: auto;
    border-radius: 12px;
    margin: 0 auto;
}

/* Animaciones */
@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.1);
    }
}

.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease-out;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive Design */
/* Tablet */
@media (max-width: 1024px) {
    body {
        width: 100vw;
    }

    main {
        width: 100vw;
    }

    .header {
        width: 100%;
    }

    .nav-menu {
        gap: 1rem;
    }

    .nav-link {
        padding: 0.5rem 0.8rem;
        font-size: 0.95rem;
    }

    .hero-text h1 {
        font-size: 2.2rem;
    }

    .hero-text .subtitle {
        font-size: 1.1rem;
        font-weight: 500;
    }

    .section-title {
        font-size: 1.8rem;
    }
}

/* Móvil */
@media (max-width: 768px) {
    body {
        width: 100vw;
    }

    main {
        width: 100vw;
    }

    .header {
        width: 100%;
    }

    .nav-container {
        padding: 0.8rem 1rem;
    }

    .nav-menu {
        position: fixed;
        top: 80px;
        left: 0;
        width: 100%;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(20px);
        flex-direction: column;
        padding: 2rem;
        box-shadow: var(--shadow);
        transform: translateY(-150%);
        transition: transform 0.4s ease;
        z-index: 999;
    }

    .nav-menu.active {
        transform: translateY(0);
    }

    .menu-toggle {
        display: block;
    }

    .hero {
        height: auto;
    }

    .hero-stats {
        justify-content: center;
    }

    .hero-text h1 {
        text-align: center;
    }

    .hero-text .subtitle {
        text-align: center;
    }

    .timeline::before {
        left: 15px;
    }

    .timeline-item {
        padding-left: 45px;
    }

    .timeline-dot {
        left: 11px;
    }

    .program-details {
        grid-template-columns: 1fr;
    }

    .cta-grid {
        grid-template-columns: 1fr;
    }

    .footer-content {
        text-align: center;
    }

    .footer-section ul {
        list-style: none;
        padding: 0;
    }
}

/* Pequeños móviles */
@media (max-width: 480px) {
    body {
        width: 100vw;
    }

    main {
        width: 100vw;
    }

    .header {
        width: 100%;
    }

    .nav-container {
        width: 100%;
    }

    .nav-container img {
        width: 300px;
    }

    .hero-text h1 {
        font-size: 2rem;
    }

    .hero-text .subtitle {
        font-size: 1.1rem;
    }

    .btn {
        width: 100%;
        justify-content: center;
    }

    .services-masonry {
        grid-template-columns: 1fr;
    }

    .whatsapp-float {
        width: 50px;
        height: 50px;
    }

    .whatsapp-icon {
        width: 24px;
        height: 24px;
    }
}