/* ============================================================
   ADG MEDIA GROUP — Clean Brand Aesthetic 
   ============================================================ */

/* --- TOKENS & VARIABLES --- */
:root {
    --bg-body: #F6F6F6;
    --obsidian: #01222E;
    --petrol-blue: #02445B;
    --glacier: #6A96A6;
    --platino: #CECECD;
    --white: #ffffff;
    --naranja: #F97316;
    
    --text-main: #01222E;
    --text-mute: rgba(1, 34, 46, 0.7);
    
    --font-display: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    --font-body: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

/* --- RESET --- */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body, html { width: 100%; min-height: 100%; background: var(--bg-body); color: var(--text-main); font-family: var(--font-body); overflow-x: hidden; -webkit-font-smoothing: antialiased; }

/* --- SMOOTH SCROLL --- */
html.lenis { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto; }
.lenis.lenis-smooth [data-lenis-prevent] { overscroll-behavior: contain; }
.lenis.lenis-stopped { overflow: hidden; }

/* --- PRELOADER --- */
.preloader { position: fixed; inset: 0; background: var(--obsidian); z-index: 99999; display: flex; flex-direction: column; justify-content: center; align-items: center; }
.preloader-logo { height: 250px; opacity: 0; transform: translateY(30px); max-width: 80%; }
.preloader-logo img { height: 100%; object-fit: contain; }
.preloader-bar { width: 200px; height: 1px; background: var(--platino); margin-top: 40px; position: relative; overflow: hidden; }
.preloader-progress { position: absolute; left: 0; top: 0; bottom: 0; width: 0%; background: var(--petrol-blue); }
/* Failsafe puro-CSS: si el JS no llega a ejecutarse, el preloader se retira solo
   a los 4s para no dejar la web tapada (accesibilidad + LCP). Con JS, la clase
   .loading se elimina antes de ese umbral y esta regla nunca llega a disparar. */
@keyframes preloader-failsafe { to { opacity: 0; visibility: hidden; pointer-events: none; } }
body.loading .preloader { animation: preloader-failsafe 0.4s ease 4s forwards; }

/* --- CURSOR (REMOVED) --- */

/* --- UTILS --- */
.container { width: 90%; max-width: 1200px; margin: 0 auto; }
main { background-color: var(--bg-body); position: relative; z-index: 1; }

/* --- HEADER --- */
header.solid-nav { position: fixed; top: 0; left: 0; width: 100%; height: auto; display: flex; justify-content: space-between; align-items: center; padding: 5px 5%; background: var(--white); z-index: 1000; transition: transform 0.4s ease; box-shadow: 0 4px 25px rgba(0,0,0,0.05); }
header.solid-nav.hidden { transform: translateY(-100%); }
.logo-img { height: clamp(40px, 8vw, 65px); width: auto; flex-shrink: 0; object-fit: contain; transition: transform 0.8s cubic-bezier(0.34, 1.56, 0.64, 1); }
.menu-btn { font-family: var(--font-display); font-weight: 600; font-size: 0.95rem; letter-spacing: 0.5px; color: var(--obsidian); text-decoration: none; padding: 10px 0; transition: color 0.3s; }
.menu-btn:hover { color: var(--petrol-blue); }

/* --- FLOATING HAMBURGER MENU --- */
.floating-hamburger { position: absolute; top: 25px; right: 25px; display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 5px; width: 45px; height: 45px; background: rgba(255, 255, 255, 0.08); backdrop-filter: blur(12px); border: 1px solid rgba(255,255,255,0.15); border-radius: 50%; cursor: pointer; padding: 0; z-index: 10001; transition: transform 0.3s ease, background 0.3s ease; box-shadow: 0 5px 15px rgba(0,0,0,0.1); }
.floating-hamburger .bar { width: 22px; height: 2px; background-color: var(--white); border-radius: 10px; transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1); transform-origin: center; }
.floating-hamburger:hover { transform: scale(1.08); background: rgba(255, 255, 255, 0.15); }
.floating-hamburger.is-active .bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.floating-hamburger.is-active .bar:nth-child(2) { opacity: 0; }
.floating-hamburger.is-active .bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
.nav-overlay { 
    position: fixed; top: 0; right: 0; width: 100%; max-width: 240px; height: 100vh; height: 100dvh;
    background: rgba(5, 23, 31, 0.2); 
    backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
    z-index: 9999; opacity: 0; pointer-events: none; 
    transition: all 0.6s cubic-bezier(0.85, 0, 0.15, 1); 
    padding: 100px 25px 40px; 
    border-left: 1px solid rgba(255,255,255,0.08); 
    box-shadow: -10px 0 40px rgba(0,0,0,0.5); 
    transform: translateX(100%); display: flex; flex-direction: column; justify-content: flex-start; overflow: hidden; 
}
.nav-overlay::before { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at top right, rgba(144, 203, 201, 0.1), transparent 50%); pointer-events: none; }
@media (max-width: 768px) {
    .nav-overlay { max-width: 240px; padding: 100px 25px 40px; justify-content: flex-start; align-items: stretch; }
    .overlay-menu { text-align: left !important; }
}
.nav-overlay.open { opacity: 1; pointer-events: auto; transform: translateX(0); }
.overlay-menu { display: flex; flex-direction: column; text-align: left; gap: 0; width: 100%; position: relative; z-index: 2; margin-top: 15px; }
.overlay-link { font-family: var(--font-display); font-size: 1.15rem; font-weight: 400; color: var(--platino); text-decoration: none; padding: 15px 0; border-bottom: 1px solid rgba(255,255,255,0.05); transition: all 0.4s ease; opacity: 0; transform: translateX(30px); letter-spacing: 0.5px; display: flex; align-items: center; justify-content: space-between; }
.overlay-link::after { content: "\2192"; opacity: 0; transform: translateX(-15px); transition: all 0.4s ease; color: var(--glacier); font-size: 1.2rem; }
.nav-overlay.open .overlay-link { transform: translateX(0); opacity: 1; transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1); }
.nav-overlay.open .overlay-link:nth-child(1) { transition-delay: 0.1s; }
.nav-overlay.open .overlay-link:nth-child(2) { transition-delay: 0.15s; }
.nav-overlay.open .overlay-link:nth-child(3) { transition-delay: 0.2s; }
.nav-overlay.open .overlay-link:nth-child(4) { transition-delay: 0.25s; }
.nav-overlay.open .overlay-link:nth-child(5) { transition-delay: 0.3s; }
.overlay-link:hover { color: var(--white); padding-left: 10px; border-bottom-color: rgba(144, 203, 201, 0.3); }
.overlay-link:hover::after { opacity: 1; transform: translateX(0); }

.fundador-img { width:100%; aspect-ratio:3/4; object-fit:cover; border-radius:8px; box-shadow: 0 10px 30px rgba(0,0,0,0.1); transition: all 0.4s ease; }
.fundador-img:hover { transform: translateY(-5px) scale(1.02); }

/* --- DYNAMIC LOGO HERO --- */
.hero {
    min-height: 100vh;
    min-height: 100dvh;
    position: relative;
    overflow: hidden; 
    background-color: var(--obsidian);
    background-image: url("../img/abstract_hd_bg_opt.webp");
    background-size: cover;
    background-position: center bottom;
    background-repeat: no-repeat;
    image-rendering: auto;
    padding-top: clamp(80px, 12vh, 120px); 
    padding-bottom: 120px;
    display: flex; flex-direction: column; align-items: center; justify-content: center; 
}

/* Removed heroGlow animations to clean up ambient lighting */

.hero-bg-faded { 
    position: absolute; inset: 0; 
    /* Heavy obsidian wash natively transmuting the 10MB 3D background */
    background: linear-gradient(135deg, rgba(1, 34, 46, 0.9) 0%, rgba(3, 68, 91, 0.8) 100%);
    mix-blend-mode: multiply;
    z-index: 1; pointer-events: none; 
}

.header-visual-entry { animation: stunning-logo-entry 1.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards; transform-origin: left center; }
@keyframes stunning-logo-entry {
    0% { transform: scale(0.8) translateX(-30px); opacity: 0; filter: drop-shadow(0 0 20px rgba(29, 156, 216, 0.8)); }
    50% { filter: drop-shadow(0 0 10px rgba(29, 156, 216, 0.4)); }
    100% { transform: scale(1) translateX(0); opacity: 1; filter: drop-shadow(0 0 0 rgba(0,0,0,0)); }
}
.logo:hover .adg-circle { transform: rotate(360deg); }
.adg-circle {
    transition: transform 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
    transform-origin: 121px 153px;
}

@keyframes fadeUpContent {
    0% { opacity: 0; transform: translateY(25px); }
    100% { opacity: 1; transform: translateY(0); }
}

/* --- HERO TYPOGRAPHY --- */
.hero-title {
    font-family: var(--font-display);
    font-size: clamp(2rem, 4.5vw, 3.6rem);
    line-height: 1.15;
    margin-bottom: 20px;
    word-wrap: break-word;
    font-weight: 800;
}
.hero-title-line1 {
    color: var(--white);
    display: block;
    letter-spacing: -1px;
}
.hero-title-line2 {
    color: var(--glacier);
    display: block;
    letter-spacing: -1px;
    margin-top: 8px;
}
.text-outline-hero {
    color: var(--glacier);
    font-weight: 600;
}
.text-solid-hero {
    color: var(--white);
    font-weight: 800;
    text-shadow: 0 10px 30px rgba(0,0,0,0.4);
}
.hero-subtitle {
    font-family: var(--font-body);
    color: rgba(255,255,255,0.85);
    font-size: clamp(0.85rem, 1.1vw, 1.05rem);
    font-weight: 300;
    line-height: 1.65;
    max-width: 1000px;
    margin: 0 auto;
    text-shadow: 0 4px 15px rgba(0,0,0,0.5);
}
.hero-title-wrap { overflow: hidden; position:relative; z-index:2; }
.text-huge { font-family: var(--font-display); font-size: clamp(3rem, 5.5vw, 5rem); font-weight: 800; line-height: 1; letter-spacing: -2px; text-transform: uppercase; color: var(--obsidian); margin: 0; }
.highlight { color: var(--petrol-blue); }

.line-wrap { display: block; overflow: hidden; }
.hero-reveal { display: inline-block; opacity: 0; animation: fadeUpContent 1s cubic-bezier(0.2, 0.8, 0.2, 1) forwards; }

/* --- SECTION TITLES --- */
.section-title { font-family: var(--font-display); font-size: clamp(2rem, 4vw, 3rem); font-weight: 700; letter-spacing: -1px; margin-bottom: 15px; color: var(--obsidian); line-height: 1.2; }
.glow-line { width: 40px; height: 2px; background: var(--glacier); margin-top: 10px; }

/* --- INTRO / QUIÉNES SOMOS & DISCIPLINES --- */
.intro { padding: 100px 0; border-top: 1px solid var(--platino); background-color: var(--bg-body); }
.intro-grid { display: grid; grid-template-columns: 1fr; gap: 50px; }
@media (min-width: 992px) {
    .intro-grid { grid-template-columns: 1.2fr 1.8fr; gap: 80px; }
}

/* Sticky Column for Left Side on Desktop */
.intro-sticky-col { position: relative; }
@media (min-width: 992px) {
    .intro-sticky-col {
        position: sticky;
        top: 120px;
        align-self: start;
    }
}
.intro-logo {
    width: 200px;
    height: auto;
    max-width: 100%;
    object-fit: contain;
    display: block;
}
.intro-tagline {
    font-family: var(--font-display);
    font-size: clamp(1.35rem, 2.2vw, 1.85rem);
    font-weight: 800;
    color: var(--obsidian);
    line-height: 1.35;
    margin-top: 25px;
    letter-spacing: -0.5px;
    max-width: 440px;
}

.contact-btn { display: inline-block; margin-top: 30px; padding: 14px 30px; background: var(--petrol-blue); color: var(--white); font-weight: 600; text-transform: uppercase; letter-spacing: 1px; font-size: 0.85rem; transition: background 0.3s; text-decoration: none; border-radius: 4px; }
.contact-btn:hover { background: var(--obsidian); }

.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; margin-top: 50px; padding-top: 40px; border-top: 1px solid var(--platino); }
@media (min-width: 992px) {
    .stats-grid { grid-template-columns: 1fr; gap: 30px; margin-top: 50px; }
}
.stat-item { transition: transform 0.3s; display: flex; flex-direction: column; align-items: center; text-align: center; }
.stat-item:hover { transform: translateY(-5px); }
.stat-num { font-family: var(--font-display); font-size: clamp(1.5rem, 5vw, 3rem); font-weight: 700; color: var(--petrol-blue); line-height: 1; margin-bottom: 10px; }
.stat-desc { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 1px; color: var(--petrol-blue); font-weight: 600; }

/* Disciplines section styles */
.disciplines-list {
    margin-top: 50px;
}

.discipline-row {
    display: flex;
    flex-direction: column;
    padding: 35px 0 35px 0;
    position: relative;
    cursor: pointer;
    /* CRITICAL: No transition on .discipline-row itself to prevent GSAP ScrollTrigger conflicts in Firefox */
    transition: none !important;
}

.discipline-row-content {
    display: flex;
    gap: 30px;
    align-items: flex-start;
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
}

.discipline-number {
    font-family: var(--font-display);
    font-size: clamp(2rem, 3.5vw, 3.2rem);
    font-weight: 300;
    color: var(--glacier);
    opacity: 0.7;
    line-height: 0.9;
    min-width: 60px;
    transition: color 0.4s ease, transform 0.4s ease, opacity 0.4s ease;
}

.discipline-text {
    flex: 1;
}

.discipline-title {
    font-family: var(--font-display);
    font-size: clamp(1.2rem, 1.6vw, 1.45rem);
    font-weight: 700;
    color: var(--obsidian);
    margin: 0 0 10px 0;
    transition: color 0.4s ease;
}

.discipline-desc {
    font-size: clamp(0.9rem, 1.1vw, 1rem);
    color: var(--text-mute);
    line-height: 1.6;
    margin: 0;
    max-width: 680px;
}

.discipline-line {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 1px;
    background: rgba(1, 34, 46, 0.08);
    transform-origin: left;
    transition: background 0.4s ease, height 0.4s ease;
}

/* Hover States for Disciplines */
.discipline-row:hover .discipline-row-content {
    transform: translateX(15px);
}

.discipline-row:hover .discipline-number {
    color: var(--petrol-blue);
    transform: scale(1.05);
    opacity: 1;
}

.discipline-row:hover .discipline-title {
    color: var(--petrol-blue);
}

.discipline-row:hover .discipline-line {
    background: var(--petrol-blue);
    height: 2px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .discipline-row-content {
        gap: 15px;
    }
    .discipline-number {
        min-width: 45px;
    }
    .discipline-row:hover .discipline-row-content {
        transform: translateX(5px);
    }
}

/* --- ENFOQUE --- */
.enfoque { padding: 80px 0; border-top: 1px solid var(--platino); }
.enfoque-grid { display: grid; grid-template-columns: 1fr 1.5fr; gap: 60px; }
.enfoque-content p { font-size: 1.5rem; font-weight: 400; color: var(--text-mute); line-height: 1.5; margin-bottom: 25px; }
.enfoque-content p strong { color: var(--obsidian); font-weight: 600; }

/* --- COMPANIES CARDS & TECH DYNAMISM --- */
.fundadores-grid { grid-template-columns: 1fr 1fr; }
.fundadores-img-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin: 40px auto 0; align-items: stretch; max-width: 380px; }

.companies { padding: 40px 0 100px 0; border-top: 1px solid rgba(0,0,0,0.03); background-color: var(--bg-body); position: relative; overflow: visible; }

.tech-title { font-size: clamp(2rem, 4vw, 3.5rem); font-weight: 800; letter-spacing: -1.5px; line-height: 1.1; color: var(--obsidian); margin-bottom: 20px; }
.cards-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 35px;
    position: relative;
    z-index: 2;
    margin-top: 30px;
}
.company-card {
    grid-column: span 2;
    padding: 40px;
    background: #ffffff;
    border-radius: 24px;
    border: 1px solid var(--platino);
    box-shadow: 0 10px 30px rgba(1, 34, 46, 0.02);
    transition: all 0.5s cubic-bezier(0.25, 1, 0.5, 1);
    display: flex;
    flex-direction: column;
    text-decoration: none;
}
.company-card:hover {
    transform: translateY(-8px);
}
.company-card.card-neural:hover {
    border-color: rgba(0, 200, 100, 0.4);
    box-shadow: 0 25px 60px rgba(0, 200, 100, 0.12);
}
.company-card.card-adgravity:hover {
    border-color: rgba(10, 132, 209, 0.4);
    box-shadow: 0 25px 60px rgba(10, 132, 209, 0.12);
}
.company-card.card-v1mp:hover {
    border-color: rgba(168, 85, 247, 0.4);
    box-shadow: 0 25px 60px rgba(168, 85, 247, 0.12);
}
.company-card.card-naranja:hover {
    border-color: rgba(249, 115, 22, 0.4);
    box-shadow: 0 25px 60px rgba(249, 115, 22, 0.12);
}
.company-card.card-rubid:hover {
    border-color: rgba(225, 29, 72, 0.4);
    box-shadow: 0 25px 60px rgba(225, 29, 72, 0.12);
}
.company-card.card-naranja, .company-card.card-rubid {
    grid-column: span 3;
}
.company-badge {
    align-self: flex-start;
    font-family: var(--font-display);
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 6px 14px;
    border-radius: 50px;
    margin-bottom: 25px;
}
.badge-neural { background: rgba(0, 200, 100, 0.08); color: rgb(0, 125, 66); border: 1px solid rgba(0, 200, 100, 0.2); }
.badge-adgravity { background: rgba(10, 132, 209, 0.08); color: rgb(9, 98, 158); border: 1px solid rgba(10, 132, 209, 0.2); }
.badge-v1mp { background: rgba(168, 85, 247, 0.08); color: rgb(124, 52, 196); border: 1px solid rgba(168, 85, 247, 0.2); }
.badge-naranja { background: rgba(249, 115, 22, 0.08); color: rgb(176, 74, 8); border: 1px solid rgba(249, 115, 22, 0.2); }
.badge-rubid { background: rgba(225, 29, 72, 0.08); color: rgb(190, 18, 54); border: 1px solid rgba(225, 29, 72, 0.2); }

.logo-wrapper {
    height: 55px;
    display: flex;
    align-items: center;
    margin-bottom: 25px;
}
.company-logo-img {
    height: 50px;
    width: auto;
    max-width: 180px;
    object-fit: contain;
    display: block;
}
.company-desc {
    font-size: 1rem;
    color: var(--text-mute);
    margin-bottom: 25px;
    font-weight: 400;
    line-height: 1.5;
}
.card-link {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--petrol-blue);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: auto;
    transition: color 0.3s;
}
.card-link .arrow {
    transition: transform 0.3s ease;
}
.company-card:hover .card-link {
    color: var(--obsidian);
}
.company-card:hover .card-link .arrow {
    transform: translateX(5px);
}

@media (max-width: 1024px) {
    .cards-grid {
        grid-template-columns: repeat(6, 1fr);
        gap: 25px;
    }
    .company-card {
        grid-column: span 3;
    }
    .company-card.card-rubid {
        grid-column: span 6;
    }
}
@media (max-width: 768px) {
    .company-card {
        grid-column: span 6 !important;
    }
}

/* --- MARQUEE --- */
.marquee-section { padding: 40px 0; background: var(--obsidian); }
.marquee-inner { display: flex; white-space: nowrap; width: fit-content; align-items: center; }
.marquee-item { font-family: var(--font-display); font-size: 2.5rem; font-weight: 700; text-transform: uppercase; padding: 0 40px; color: var(--white); }
.text-outline { color: transparent; -webkit-text-stroke: 1px var(--glacier); }
.marquee-dot { color: var(--glacier); font-size: 1.5rem; }

/* --- NEWS (REDISEÑO EDITORIAL COMPACTO EN REJILLA A LA MITAD DE TAMAÑO) --- */
.news-section { padding: 80px 0 60px 0; border-top: 1px solid var(--platino); background-color: var(--bg-body); }
.news-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 24px; margin-top: 40px; }

.news-card { 
    display: flex; 
    flex-direction: column;
    text-decoration: none; 
    background: #ffffff; 
    border: 1px solid rgba(1, 34, 46, 0.05); 
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1), box-shadow 0.4s cubic-bezier(0.25, 1, 0.5, 1), border-color 0.4s ease; 
    border-radius: 12px; 
    overflow: hidden; 
    width: 100%;
    box-shadow: 0 4px 15px rgba(1, 34, 46, 0.01);
}

.news-card:hover { 
    transform: translateY(-6px); 
    box-shadow: 0 15px 30px rgba(10, 132, 209, 0.05), 0 1px 3px rgba(0,0,0,0.01); 
    border-color: rgba(10, 132, 209, 0.2); 
}

.news-img-box { 
    width: 100%; 
    height: 120px; 
    overflow: hidden; 
    position: relative;
    background: var(--obsidian);
}

/* Subtle dark overlay for premium image contrast */
.news-img-box::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, transparent 60%, rgba(1, 34, 46, 0.1));
    pointer-events: none;
}

.news-img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
    transition: transform 0.8s cubic-bezier(0.25, 1, 0.5, 1); 
}

.news-card:hover .news-img { 
    transform: scale(1.04) rotate(0.5deg); 
}

.news-content { 
    padding: 16px; 
    display: flex;
    flex-direction: column;
    height: calc(100% - 120px);
    justify-content: flex-start;
}

/* Elegant editorial tag */
.news-content::before {
    content: "ADG PRESS";
    font-family: var(--font-display);
    font-size: 0.62rem;
    font-weight: 700;
    color: var(--petrol-blue);
    letter-spacing: 1.2px;
    margin-bottom: 8px;
    text-transform: uppercase;
    display: block;
    transition: color 0.3s;
}

.news-card:hover .news-content::before {
    color: var(--petrol-blue);
}

.news-meta {
    font-size: 0.75rem;
    color: var(--petrol-blue);
    font-weight: 700;
    text-transform: uppercase; 
    margin-bottom: 10px; 
}

.news-title { 
    font-family: var(--font-display); 
    font-size: 0.82rem; 
    font-weight: 600; 
    color: var(--obsidian); 
    line-height: 1.4; 
    transition: color 0.3s ease; 
    margin: 0;
    letter-spacing: -0.1px;
}

.news-card:hover .news-title { 
    color: var(--petrol-blue); 
}

/* --- CONTACT (REDISEÑO HIGH-END) --- */
.contacto-section { 
    margin: 40px auto 100px; 
    background: #01161E; 
    padding: 80px 70px; 
    border-radius: 32px; 
    box-shadow: 0 30px 70px rgba(1, 34, 46, 0.4); 
    color: var(--white); 
    position: relative; 
    overflow: hidden; 
    border: 1px solid rgba(255, 255, 255, 0.05); 
}

/* Subtle glowing background lights for top-tier look */
.contacto-section::before { 
    content: ""; 
    position: absolute; 
    top: -30%; 
    left: -20%; 
    width: 80%; 
    height: 80%; 
    background: radial-gradient(circle, rgba(144, 203, 201, 0.15) 0%, transparent 70%); 
    pointer-events: none; 
    z-index: 1;
}

.contacto-section::after { 
    content: ""; 
    position: absolute; 
    bottom: -30%; 
    right: -20%; 
    width: 80%; 
    height: 80%; 
    background: radial-gradient(circle, rgba(10, 132, 209, 0.12) 0%, transparent 70%); 
    pointer-events: none; 
    z-index: 1;
}

.contact-grid { 
    display: grid; 
    grid-template-columns: 1.15fr 1fr; 
    gap: 70px; 
    align-items: flex-start; 
    position: relative; 
    z-index: 2; 
}

.contact-header { 
    margin-bottom: 50px; 
    position: relative;
    z-index: 2;
}

.contact-label { 
    color: var(--glacier); 
    font-family: var(--font-display);
    font-weight: 700; 
    font-size: 0.75rem; 
    letter-spacing: 2px; 
    text-transform: uppercase; 
    display: inline-block;
    margin-bottom: 12px;
}

.contact-title { 
    font-family: var(--font-display); 
    font-size: clamp(1.8rem, 4vw, 2.8rem); 
    font-weight: 800; 
    color: var(--white); 
    line-height: 1.15; 
    margin: 0 0 20px 0; 
    letter-spacing: -1px; 
}

.contact-desc { 
    color: rgba(255, 255, 255, 0.7); 
    font-size: 1.05rem; 
    line-height: 1.6; 
    margin-bottom: 0; 
    max-width: 600px; 
    font-weight: 400;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.contact-details { 
    display: flex; 
    flex-direction: column; 
    gap: 20px; 
}

.contact-form { 
    margin-top: 0; 
}

.cd-item { 
    display: flex; 
    align-items: center; 
    gap: 20px; 
    color: var(--white); 
    font-size: 0.95rem; 
    line-height: 1.5; 
    font-weight: 500; 
    padding: 20px 25px; 
    border-radius: 16px; 
    transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1); 
    border: 1px solid rgba(255, 255, 255, 0.04); 
    background: rgba(255, 255, 255, 0.01); 
    backdrop-filter: blur(10px); 
    margin-left: -20px;
}

.cd-item:hover { 
    background: rgba(255, 255, 255, 0.05); 
    border-color: rgba(144, 203, 201, 0.3); 
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.25), 0 0 0 1px rgba(144, 203, 201, 0.1); 
    transform: translateY(-4px); 
}

.cd-icon { 
    width: 24px; 
    height: 24px; 
    fill: none; 
    stroke: var(--glacier); 
    stroke-width: 1.8; 
    flex-shrink: 0; 
    transition: transform 0.4s ease;
}

.cd-item:hover .cd-icon {
    transform: scale(1.1);
}

.form-input, .form-textarea { 
    width: 100%; 
    padding: 18px 22px; 
    border: 1px solid rgba(255, 255, 255, 0.08); 
    background: rgba(255, 255, 255, 0.02); 
    font-family: var(--font-body); 
    font-size: 0.95rem; 
    color: var(--white); 
    margin-bottom: 22px; 
    outline: none; 
    transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1); 
    border-radius: 12px; 
}

.form-input::placeholder, .form-textarea::placeholder { 
    color: rgba(255, 255, 255, 0.4); 
}

.form-input:focus, .form-textarea:focus { 
    border-color: var(--glacier); 
    background: rgba(255, 255, 255, 0.06); 
    box-shadow: 0 0 25px rgba(144, 203, 201, 0.12), 0 0 0 1px rgba(144, 203, 201, 0.2); 
}

.form-textarea { 
    height: 140px; 
    resize: none; 
}

.submit-btn { 
    background: var(--glacier); 
    color: var(--obsidian); 
    border: none; 
    padding: 18px 30px; 
    font-family: var(--font-display); 
    font-size: 0.95rem; 
    font-weight: 700; 
    cursor: pointer; 
    border-radius: 12px; 
    transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1); 
    width: 100%; 
    margin-top: 15px; 
    text-transform: uppercase; 
    letter-spacing: 1px; 
    box-shadow: 0 10px 25px rgba(144, 203, 201, 0.2);
}

.submit-btn:hover { 
    background: var(--white); 
    transform: translateY(-3px); 
    box-shadow: 0 15px 30px rgba(255, 255, 255, 0.25); 
}

/* --- INTEGRATED MAP --- */
.map-wrapper {
    margin-top: 25px;
    margin-left: -20px;
    width: calc(100% + 20px);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.mapa-iframe {
    width: 100%;
    height: 220px;
    border: none;
    display: block;
}



/* --- FOOTER --- */
footer { padding: 40px 0 20px; background: var(--obsidian); color: var(--bg-body); }
.footer-label { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 1px; color: var(--glacier); border: 1px solid rgba(255,255,255,0.2); padding: 5px 15px; border-radius: 50px; }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; padding: 20px 0 0; border-top: 1px solid rgba(255,255,255,0.1); font-size: 0.85rem; color: rgba(255,255,255,0.6); margin-top: 20px; }
.fb-item.link { color: var(--white); text-transform: uppercase; font-weight: 600; cursor: pointer; }
.footer-icon { height: 25px; opacity: 1; }

/* cursor styles removed for mobile */

/* --- RESPONSIVE --- */
@media (max-width: 1024px) {
    .intro-grid, .enfoque-grid, .contact-grid, .fundadores-grid { grid-template-columns: 1fr; gap: 40px; }
    .stats-grid { gap: 10px; }
    .hero { text-align: center !important; align-items: center !important; padding-top: 140px; }
    .mapa-iframe { height: 250px; }
    .contacto-section { padding: 30px; }
    .contact-form { margin-top: 0; }
    .news-grid { grid-template-columns: repeat(2, 1fr); gap: 24px; }
    
    /* Contact layout alignment for collapsed grid (tablets) */
    .cd-item { margin-left: 0 !important; }
    .map-wrapper { margin-left: 0 !important; width: 100% !important; }
}
@media (max-width: 768px) {
    .br-desktop { display: none; }
    .news-grid { grid-template-columns: 1fr; gap: 20px; }
    .marquee-item { font-size: 2rem; }
    .footer-bottom { flex-direction: column; gap: 20px; text-align: center; }
    .hero-title-wrap { flex-direction: column !important; align-items: center; justify-content: center; gap: 5px !important; }
    .text-huge { font-size: clamp(1.8rem, 9vw, 3.5rem); line-height: 1.1; letter-spacing: -1px; }
    .news-header-flex { flex-direction: column; align-items: flex-start !important; gap: 10px; }
    .scroll-hint { margin-bottom: 20px !important; }
    .floating-hamburger { position: absolute; right: 15px; top: 15px; width: 44px; height: 44px; background: rgba(255, 255, 255, 0.08); }
    .floating-hamburger .bar { width: 18px; }
    p, h1, h2, h3, h4, h5, h6 { padding-right: 35px; }
    .hero-title, .hero-subtitle { padding-right: 0; }
    
    /* Mobile optimization for Hero Title */
    .hero-title { font-size: clamp(1.4rem, 5.5vw, 2.2rem) !important; line-height: 1.25 !important; }
    .hero-title-line2 { margin-top: 5px !important; }
    
    /* Contact mobile layout optimizations */
    .contacto-section { 
        padding: 40px 20px !important; 
        border-radius: 24px !important; 
        margin-top: 30px !important;
        margin-bottom: 60px !important;
    }
    .contact-title {
        font-size: 1.6rem !important;
    }
    .contact-desc {
        font-size: 0.95rem !important;
    }
    .cd-item {
        padding: 16px 20px !important;
        gap: 15px !important;
        border-radius: 12px !important;
        font-size: 0.88rem !important;
    }
    .form-input, .form-textarea {
        padding: 15px 18px !important;
        margin-bottom: 16px !important;
        font-size: 16px !important; /* 16px evita el auto-zoom de iOS al enfocar */
        border-radius: 10px !important;
    }
    .form-textarea {
        height: 110px !important;
    }
    .submit-btn {
        padding: 15px 24px !important;
        font-size: 0.9rem !important;
        margin-top: 10px !important;
        border-radius: 10px !important;
    }
}

/* --- OVERRIDES FOR LARGE SCREENS --- */
@media (min-width: 1440px) {
    .container { max-width: 1300px; }
    .hero-pills { gap: 25px !important; }
    .magnetic-btn { font-size: 1rem !important; padding: 18px 45px !important; }
}

@media (min-width: 1600px) {
    .container { max-width: 1450px; }
    .tilt-logo { max-width: 800px !important; }
    .hero-subtitle { margin-bottom: 40px !important; }
    .hero-pills { gap: 35px !important; }
    .magnetic-btn { font-size: 1.15rem !important; padding: 22px 55px !important; border-width: 1.5px !important; }
    
    .section-title { font-size: 3.5rem !important; }
    .stat-num { font-size: 4rem !important; }
    .stat-desc { font-size: 1rem !important; }
    .company-title { font-size: 2.4rem !important; }
    .company-desc { font-size: 1.15rem !important; line-height: 1.6; }
    .contact-title { font-size: 4rem !important; }
    .cd-item { font-size: 1.2rem !important; }
}

@media (min-width: 1920px) {
    .container { max-width: 1700px; }
    .tilt-logo { max-width: 950px !important; }
    .hero-subtitle { margin-bottom: 50px !important; }
    .hero-pills { gap: 45px !important; }
    .magnetic-btn { font-size: 1.35rem !important; padding: 28px 70px !important; border-width: 2px !important; }
    
    .section-title { font-size: 4.5rem !important; }
    .stat-num { font-size: 5rem !important; }
    .stat-desc { font-size: 1.1rem !important; }
    .company-title { font-size: 2.8rem !important; }
    .company-desc { font-size: 1.3rem !important; line-height: 1.7; }
    .contact-title { font-size: 5rem !important; }
    .cd-item { font-size: 1.4rem !important; }
    .news-title { font-size: 1.15rem !important; }
    
    .fundadores-left p { font-size: 1.5rem !important; line-height: 1.7 !important; }
    .fundadores-right p { font-size: 1.35rem !important; line-height: 1.8 !important; }
    .intro-right p:first-child { font-size: 2.2rem !important; }
    .intro-right p:nth-child(2) { font-size: 1.35rem !important; max-width: 700px !important; }
}

/* --- ECOSISTEMA 360 --- */
.ecosystem-section { overflow: hidden; background: transparent; }
.eco-grid { display: grid; grid-template-columns: 1fr 400px 1fr; gap: 30px; align-items: flex-start; position: relative; }

/* Columns & Cards */
.eco-col { display: flex; flex-direction: column; gap: 25px; z-index: 2; }
.eco-col-title { font-family: var(--font-display); font-size: 1.5rem; font-weight: 700; color: var(--obsidian); margin-bottom: 20px; }
.eco-card { background: var(--white); border: 1px solid var(--platino); border-radius: 16px; padding: 25px; display: flex; gap: 20px; transition: transform 0.4s ease, box-shadow 0.4s ease; position: relative; z-index: 2; box-shadow: 0 10px 30px rgba(0,0,0,0.02); }
.eco-card:hover { transform: translateY(-5px) scale(1.02); box-shadow: 0 15px 40px rgba(1, 34, 46, 0.08); border-color: var(--glacier); }

.eco-card-icon { flex-shrink: 0; width: 50px; height: 50px; background: rgba(106, 150, 166, 0.1); border-radius: 12px; display: flex; align-items: center; justify-content: center; }
.eco-card-icon svg { width: 28px; height: 28px; stroke: var(--petrol-blue); }

.eco-card-content h4 { font-family: var(--font-display); font-size: 1.15rem; font-weight: 700; color: var(--obsidian); margin-bottom: 8px; line-height: 1.3; }
.eco-card-content p { font-size: 0.95rem; color: var(--text-mute); line-height: 1.5; }

/* Badges */
.eco-badges { display: flex; flex-direction: column; gap: 10px; margin-top: 15px; }
.eco-badge { background: rgba(249, 115, 22, 0.1); border-left: 3px solid var(--naranja); padding: 10px 15px; border-radius: 0 8px 8px 0; font-size: 0.85rem; line-height: 1.4; }
.eco-badge-alt { background: rgba(2, 68, 91, 0.08); border-left-color: var(--petrol-blue); }
.badge-title { font-weight: 700; color: var(--obsidian); }
.badge-desc { color: var(--text-mute); }

/* Center Graphic (Core) */
.eco-center { position: relative; height: 500px; display: flex; justify-content: center; align-items: center; }
.eco-core-container { position: relative; width: 100%; height: 100%; display: flex; justify-content: center; align-items: center; }
.eco-core { position: relative; width: 200px; height: 200px; display: flex; justify-content: center; align-items: center; z-index: 3; }
.core-dot { width: 40px; height: 40px; background: var(--naranja); border-radius: 50%; box-shadow: 0 0 30px var(--naranja), inset 0 0 10px #fff; z-index: 4; animation: corePulse 2s infinite alternate; }
.core-ring { position: absolute; border-radius: 50%; border: 2px solid transparent; border-top-color: var(--petrol-blue); border-bottom-color: var(--glacier); opacity: 0.7; }
.core-ring-1 { width: 100%; height: 100%; animation: spin 12s linear infinite; }
.core-ring-2 { width: 75%; height: 75%; border-top-color: var(--naranja); border-bottom-color: transparent; animation: spinReverse 8s linear infinite; }
.core-ring-3 { width: 50%; height: 50%; border-left-color: var(--glacier); border-top-color: transparent; animation: spin 6s linear infinite; }

/* SVG Lines */
.eco-svg-lines { position: absolute; inset: -100px; width: calc(100% + 200px); height: calc(100% + 200px); z-index: 1; pointer-events: none; }
.eco-line { fill: none; stroke: var(--glacier); stroke-width: 2; stroke-dasharray: 1000; stroke-dashoffset: 1000; opacity: 0.4; transition: opacity 0.3s; }
.eco-core-container:hover .eco-line { opacity: 0.8; }

/* GSAP Reveal Utilities */
.reveal-eco { opacity: 0; visibility: hidden; }

/* Animations */
@keyframes corePulse {
    0% { transform: scale(1); box-shadow: 0 0 20px var(--naranja); }
    100% { transform: scale(1.2); box-shadow: 0 0 50px var(--naranja); }
}
@keyframes spin { 100% { transform: rotate(360deg); } }
@keyframes spinReverse { 100% { transform: rotate(-360deg); } }

/* Responsive Ecosistema */
@media (max-width: 1024px) {
    .eco-grid { grid-template-columns: 1fr; gap: 50px; }
    .eco-center { height: 300px; order: -1; }
    .eco-svg-lines { display: none; }
    .eco-col-title { text-align: center !important; }
}
/* Advanced SVG Core Styles */
.core-svg-graphic { width: 100%; height: 100%; z-index: 5; position: relative; overflow: visible; filter: drop-shadow(0 0 30px rgba(106, 150, 166, 0.2)); }
.svg-ring-outer, .svg-ring-middle, .svg-ring-inner, .svg-orb, .orbit-group-1, .orbit-group-2, .orbit-group-3 { transform-origin: center; transform-box: fill-box; }
.svg-ring-outer { animation: spinReverse 20s linear infinite; }
.svg-ring-middle { animation: spin 15s linear infinite; }
.svg-ring-inner { animation: spinReverse 25s linear infinite; }
.svg-orb { animation: pulseOrb 3s ease-in-out infinite alternate; }
.orbit-group-1 { animation: spin 8s linear infinite; }
.orbit-group-2 { animation: spinReverse 12s linear infinite; }
.orbit-group-3 { animation: spin 6s linear infinite; }

@keyframes pulseOrb {
    0% { transform: scale(0.9); filter: drop-shadow(0 0 10px var(--naranja)); }
    100% { transform: scale(1.15); filter: drop-shadow(0 0 25px var(--naranja)); }
}

/* ============================================================
   ACCESIBILIDAD (a11y)
   ============================================================ */

/* Etiquetas solo para lectores de pantalla */
.sr-only {
    position: absolute;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Foco visible por teclado (no afecta al puntero) */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
    outline: 3px solid var(--petrol-blue);
    outline-offset: 2px;
    border-radius: 4px;
}

/* Sobre fondos oscuros el foco usa glacier para mantener contraste */
.overlay-link:focus-visible,
.submit-btn:focus-visible,
.form-input:focus-visible,
.form-textarea:focus-visible,
.contacto-section a:focus-visible,
.floating-hamburger:focus-visible {
    outline-color: var(--glacier);
}

/* Área de toque cómoda en los enlaces legales del footer */
.fb-links a { display: inline-block; padding: 8px 4px; }

/* --- MOVIMIENTO REDUCIDO --- */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
    }
    /* El contenido que las animaciones revelan debe quedar visible siempre */
    .hero-content-wrap,
    .reveal-text,
    .hero-subtitle,
    .discipline-row,
    .overlay-link { opacity: 1 !important; }
}
