/* ==========================================================================
   HYDROS INGENIERÍA S.A.S. - HOJA DE ESTILOS PRINCIPAL (style.css)
   ========================================================================== */

:root {
    --primary-dark: #0B192C;
    --primary-navy: #1E3E62;
    --accent-cyan: #00A3A6;
    --accent-teal: #00B4D8;
    --accent-hover: #00818A;
    --bg-light: #F8FAFC;
    --text-dark: #1E293B;
    --text-muted: #64748B;
    --white: #FFFFFF;
    --card-shadow: 0 10px 30px rgba(11, 25, 44, 0.08);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
    overflow-x: hidden;
}

body {
    font-family: 'Open Sans', sans-serif;
    color: var(--text-dark);
    background-color: var(--bg-light);
    line-height: 1.6;
    overflow-x: hidden;
    width: 100%;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    color: var(--primary-dark);
    word-break: break-word;
}

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

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

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* BOTONES */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 28px;
    border-radius: 50px;
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    text-align: center;
    white-space: nowrap;
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent-cyan), var(--accent-teal));
    color: var(--white);
    box-shadow: 0 4px 15px rgba(0, 163, 166, 0.3);
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--accent-hover), var(--accent-cyan));
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 163, 166, 0.4);
}

.btn-outline {
    background: transparent;
    color: var(--white);
    border: 2px solid var(--accent-cyan);
}

.btn-outline:hover {
    background: var(--accent-cyan);
    color: var(--white);
    transform: translateY(-2px);
}

.btn-submit, .btn-card-contact {
    width: 100%;
    margin-top: 15px;
}

/* HEADER & NAVBAR RESPONSIVO */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: rgba(11, 25, 44, 0.96);
    backdrop-filter: blur(10px);
    z-index: 1000;
    box-shadow: 0 2px 20px rgba(0,0,0,0.15);
    transition: var(--transition);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 20px;
}

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

.logo-img-real {
    height: 46px;
    max-width: 220px;
    width: auto;
    object-fit: contain;
    display: block;
}

.logo-symbol-svg {
    width: 40px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.logo-text .title {
    font-family: 'Montserrat', sans-serif;
    font-weight: 800;
    font-size: 1.25rem;
    letter-spacing: 1.5px;
    color: var(--white);
    line-height: 1;
}

.logo-text .subtitle {
    font-size: 0.6rem;
    letter-spacing: 2.5px;
    color: var(--accent-teal);
    font-weight: 700;
    margin-top: 3px;
}

.mobile-toggle {
    display: none;
    background: transparent;
    border: none;
    color: var(--white);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 5px;
    z-index: 1001;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 25px;
    list-style: none;
}

.nav-link {
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.9rem;
    font-weight: 500;
    position: relative;
    padding: 5px 0;
}

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

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-teal);
    transition: var(--transition);
}

.nav-link:hover::after {
    width: 100%;
}

/* HERO SECTION CON TU IMAGEN REAL FONDO.jpg */
.hero {
    position: relative;
    background: linear-gradient(135deg, rgba(11, 25, 44, 0.88), rgba(30, 62, 98, 0.82)), 
                url('../IMAGES/FONDO.jpg') center/cover no-repeat;
    padding: 160px 0 100px;
    color: var(--white);
    min-height: 80vh;
    display: flex;
    align-items: center;
}

.hero-content {
    max-width: 800px;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(0, 163, 166, 0.15);
    border: 1px solid rgba(0, 163, 166, 0.4);
    color: var(--accent-teal);
    padding: 6px 16px;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 25px;
}

.hero h1 {
    font-size: clamp(2rem, 5vw, 3rem);
    line-height: 1.25;
    color: var(--white);
    margin-bottom: 20px;
}

.hero h1 span {
    color: var(--accent-teal);
}

.hero p {
    font-size: clamp(1rem, 2vw, 1.15rem);
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 35px;
    max-width: 700px;
}

.hero-buttons {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

/* SECCIONES Y ENCABEZADOS */
section {
    padding: 80px 0;
}

.section-header {
    text-align: center;
    max-width: 720px;
    margin: 0 auto 50px;
}

.section-tag {
    color: var(--accent-cyan);
    font-weight: 700;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 10px;
    display: block;
}

.section-title {
    font-size: clamp(1.8rem, 4vw, 2.3rem);
    margin-bottom: 15px;
    line-height: 1.3;
}

.section-desc {
    color: var(--text-muted);
    font-size: 1rem;
}

/* NOSOTROS / EMPRESA */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
}

.about-card {
    background: var(--white);
    padding: 35px;
    border-radius: 16px;
    box-shadow: var(--card-shadow);
    border-left: 5px solid var(--accent-cyan);
}

.about-card p {
    margin-bottom: 15px;
    color: #334155;
    font-size: 1.05rem;
    text-align: justify;
}

.about-card p:last-child {
    margin-bottom: 0;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.stat-box {
    background: var(--white);
    padding: 22px;
    border-radius: 12px;
    text-align: center;
    box-shadow: var(--card-shadow);
    border: 1px solid #E2E8F0;
}

.stat-number {
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--accent-cyan);
    font-family: 'Montserrat', sans-serif;
}

.stat-label {
    font-size: 0.85rem;
    color: var(--text-muted);
    font-weight: 600;
    margin-top: 5px;
}

/* EQUIPO DIRECTIVO */
.team-bg {
    background: #F1F5F9;
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 35px;
}

.team-card {
    background: var(--white);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--card-shadow);
    transition: var(--transition);
    border: 1px solid #E2E8F0;
    display: flex;
    flex-direction: column;
}

.team-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(11, 25, 44, 0.12);
}

.team-header {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-navy));
    padding: 35px 20px 25px;
    text-align: center;
    color: var(--white);
}

.avatar-real-frame {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    border: 4px solid var(--accent-teal);
    margin: 0 auto 18px;
    overflow: hidden;
    background: #0B192C;
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
    flex-shrink: 0;
}

.avatar-real-frame img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
}

.team-header h3 {
    color: var(--white);
    font-size: 1.2rem;
    margin-bottom: 5px;
    letter-spacing: 0.5px;
    line-height: 1.3;
}

.team-role {
    color: var(--accent-teal);
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.team-body {
    padding: 30px 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.degree-list {
    list-style: none;
    margin-bottom: 20px;
}

.degree-list li {
    position: relative;
    padding-left: 24px;
    margin-bottom: 12px;
    font-size: 0.9rem;
    color: #334155;
    line-height: 1.5;
}

.degree-list li i {
    position: absolute;
    left: 0;
    top: 3px;
    color: var(--accent-cyan);
    font-size: 0.85rem;
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag {
    background: #E0F2FE;
    color: #0369A1;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 5px 12px;
    border-radius: 20px;
}

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

.service-card {
    background: var(--white);
    border-radius: 16px;
    padding: 30px 25px;
    box-shadow: var(--card-shadow);
    border: 1px solid #E2E8F0;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.service-card:hover {
    transform: translateY(-5px);
    border-color: var(--accent-cyan);
}

.service-icon {
    width: 58px;
    height: 58px;
    background: rgba(0, 163, 166, 0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-cyan);
    font-size: 1.5rem;
    margin-bottom: 20px;
}

.service-card h3 {
    font-size: 1.1rem;
    margin-bottom: 12px;
    line-height: 1.35;
}

.service-card p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 20px;
    flex-grow: 1;
}

.deliverables-box {
    background: #F8FAFC;
    border-radius: 10px;
    padding: 14px;
    border-left: 3px solid var(--accent-teal);
}

.deliverables-title {
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--primary-dark);
    text-transform: uppercase;
    margin-bottom: 5px;
}

.deliverables-text {
    font-size: 0.82rem;
    color: #475569;
}

/* CLIENTES */
.clients-bg {
    background: var(--primary-dark);
    color: var(--white);
}

.clients-bg .section-title {
    color: var(--white);
}

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

.client-item {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 22px 15px;
    border-radius: 12px;
    text-align: center;
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    transition: var(--transition);
}

.client-item:hover {
    background: rgba(0, 163, 166, 0.15);
    border-color: var(--accent-cyan);
    color: var(--white);
}

.client-item i {
    color: var(--accent-teal);
}

/* CONTACTO */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.contact-info-card {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-navy));
    border-radius: 20px;
    padding: 35px;
    color: var(--white);
}

.contact-info-card h3 {
    color: var(--white);
    font-size: 1.5rem;
    margin-bottom: 12px;
}

.contact-subtext {
    color: rgba(255,255,255,0.8);
    margin-bottom: 30px;
    font-size: 0.95rem;
}

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

.contact-icon-box {
    width: 44px;
    height: 44px;
    background: rgba(0, 163, 166, 0.2);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-teal);
    font-size: 1.2rem;
    flex-shrink: 0;
}

.contact-detail h4 {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.78rem;
    text-transform: uppercase;
    margin-bottom: 3px;
}

.contact-detail p {
    font-size: 0.98rem;
    color: var(--white);
    font-weight: 600;
    word-break: break-word;
}

.form-card {
    background: var(--white);
    padding: 35px;
    border-radius: 20px;
    box-shadow: var(--card-shadow);
    border: 1px solid #E2E8F0;
}

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

.form-group label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--primary-dark);
    margin-bottom: 6px;
}

.form-control {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #CBD5E1;
    border-radius: 8px;
    font-family: inherit;
    font-size: 0.95rem;
    transition: var(--transition);
}

.form-control:focus {
    outline: none;
    border-color: var(--accent-cyan);
    box-shadow: 0 0 0 3px rgba(0, 163, 166, 0.15);
}

textarea.form-control {
    resize: vertical;
    min-height: 110px;
}

/* FOOTER & WHATSAPP FLOTANTE */
footer {
    background: #070F1E;
    color: rgba(255, 255, 255, 0.6);
    padding: 35px 0;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 0.85rem;
}

.footer-sub {
    margin-top: 5px;
    font-size: 0.75rem;
    color: rgba(255,255,255,0.4);
}

.whatsapp-float {
    position: fixed;
    bottom: 25px;
    right: 25px;
    width: 58px;
    height: 58px;
    background: #25D366;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    box-shadow: 0 5px 20px rgba(37, 211, 102, 0.4);
    z-index: 999;
    transition: var(--transition);
}

.whatsapp-float:hover {
    transform: scale(1.1);
}

/* BOTÓN FLOTANTE Y MODAL DEL CHATBOT IA */
.ai-float-trigger {
    position: fixed;
    bottom: 95px;
    right: 25px;
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-navy));
    color: var(--accent-teal);
    padding: 12px 20px;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 8px 25px rgba(11, 25, 44, 0.35);
    z-index: 998;
    border: 2px solid var(--accent-cyan);
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
}

.ai-float-trigger:hover {
    transform: scale(1.05);
    color: var(--white);
}

.ai-modal-widget {
    display: none;
    position: fixed;
    bottom: 25px;
    right: 25px;
    width: 380px;
    max-width: calc(100vw - 30px);
    height: 540px;
    max-height: calc(100vh - 50px);
    background: var(--white);
    border-radius: 20px;
    box-shadow: 0 20px 50px rgba(11, 25, 44, 0.3);
    border: 1px solid #CBD5E1;
    z-index: 1002;
    flex-direction: column;
    overflow: hidden;
    animation: slideUp 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.ai-modal-widget.active {
    display: flex;
}

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

.ai-widget-header {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-navy));
    padding: 16px 20px;
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.ai-widget-header-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.ai-avatar-mini {
    width: 38px;
    height: 38px;
    background: linear-gradient(135deg, var(--accent-cyan), var(--accent-teal));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: var(--white);
}

.ai-widget-header h4 {
    color: var(--white);
    font-size: 1rem;
    margin: 0;
    line-height: 1.2;
}

.ai-widget-header .status {
    font-size: 0.72rem;
    color: #4ADE80;
    font-weight: 600;
}

.ai-widget-close {
    background: transparent;
    border: none;
    color: rgba(255,255,255,0.8);
    font-size: 1.4rem;
    cursor: pointer;
    padding: 5px;
    transition: var(--transition);
}

.ai-widget-close:hover {
    color: var(--white);
    transform: scale(1.1);
}

.ai-widget-body {
    padding: 16px;
    flex-grow: 1;
    overflow-y: auto;
    background: #F8FAFC;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.widget-msg {
    display: flex;
    flex-direction: column;
    max-width: 90%;
}

.widget-msg.bot {
    align-self: flex-start;
}

.widget-msg.user {
    align-self: flex-end;
}

.widget-msg-content {
    background: var(--white);
    padding: 12px 15px;
    border-radius: 14px;
    border-top-left-radius: 2px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    font-size: 0.88rem;
    color: var(--text-dark);
    border: 1px solid #E2E8F0;
    line-height: 1.5;
}

.widget-msg.user .widget-msg-content {
    background: var(--primary-navy);
    color: var(--white);
    border-top-left-radius: 14px;
    border-top-right-radius: 2px;
    border: none;
}

.widget-recommendation {
    margin-top: 10px;
    background: #F0FDF4;
    border: 1px solid #86EFAC;
    border-radius: 10px;
    padding: 10px 12px;
    font-size: 0.82rem;
}

.widget-engineer-card {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top:;
    align-items: center;
    gap: 10px;
    margin-top: 8px;
    background: var(--white);
    padding: 8px 10px;
    border-radius: 8px;
    border: 1px solid #BBF7D0;
}

.widget-engineer-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
    border: 2px solid var(--accent-cyan);
}

.widget-engineer-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ai-widget-quick {
    padding: 10px 15px;
    background: var(--white);
    border-top: 1px solid #E2E8F0;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.btn-widget-chip {
    background: #F1F5F9;
    border: 1px solid #CBD5E1;
    color: #334155;
    padding: 4px 10px;
    border-radius: 15px;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.btn-widget-chip:hover {
    background: var(--accent-cyan);
    color: var(--white);
    border-color: var(--accent-cyan);
}

.ai-widget-input {
    padding: 12px 15px;
    background: var(--white);
    border-top: 1px solid #E2E8F0;
    display: flex;
    gap: 8px;
}

.ai-widget-input input {
    flex-grow: 1;
    padding: 10px 14px;
    border: 1px solid #CBD5E1;
    border-radius: 30px;
    font-family: inherit;
    font-size: 0.85rem;
}

.ai-widget-input input:focus {
    outline: none;
    border-color: var(--accent-cyan);
}

/* MEDIA QUERIES RESPONSIVAS */
@media (max-width: 992px) {
    section { padding: 60px 0; }
    .about-grid, .team-grid, .contact-grid { grid-template-columns: 1fr; gap: 30px; }
    .services-grid, .clients-grid { grid-template-columns: repeat(2, 1fr); gap: 20px; }
    .hero { padding: 130px 0 80px; }
}

@media (max-width: 768px) {
    .desktop-cta { display: none; }
    .mobile-toggle { display: block; }
    .nav-menu {
        position: fixed; top: 0; right: -100%; width: 80%; max-width: 320px; height: 100vh;
        background: var(--primary-dark); flex-direction: column; justify-content: center;
        gap: 22px; padding: 40px 25px; box-shadow: -5px 0 25px rgba(0,0,0,0.5);
        transition: right 0.4s ease; z-index: 1000;
    }
    .nav-menu.active { right: 0; }
    .hero-buttons { flex-direction: column; width: 100%; }
    .hero-buttons .btn { width: 100%; }
    .services-grid, .clients-grid { grid-template-columns: 1fr; }
    .ai-float-text { display: none; }
    .ai-float-trigger { padding: 12px; border-radius: 50%; bottom: 95px; right: 25px; width: 58px; height: 58px; justify-content: center; }
    .ai-modal-widget { right: 15px; bottom: 15px; width: calc(100vw - 30px); }
}

@media (max-width: 480px) {
    .stats-grid { grid-template-columns: 1fr; }
    .logo-text .title { font-size: 1.1rem; }
    .logo-text .subtitle { font-size: 0.55rem; }
}