/* ════════════════════════════════════════════════════════════════
   MEDEXPERTHUB — FULL-VIEWPORT MEDICAL AI HERO
   Paleta original de la marca (Navy #0f0f23 + Índigo/Violeta/Lavanda #6366f1/#8b5cf6/#a78bfa + Cian #38bdf8).
   Médicos originales fusionando conocimiento clínico e IA a través de sus dedos.
   Microchip bio-procesador de IA y cruz médica holográfica con ritmo vital.
   Sin etiquetas invasivas que tapen la imagen. Vista limpia, clara y de alto impacto.
   Cero pie de página en landing, pantalla completa estricta (100vh / 100dvh).
   ════════════════════════════════════════════════════════════════ */

:root {
    --bg-dark: #0f0f23;
    --brand-indigo: #6366f1;
    --brand-violet: #8b5cf6;
    --brand-lavender: #a78bfa;
    --brand-cyan: #38bdf8;
    --brand-glow: rgba(99, 102, 241, 0.4);
    --font-display: 'Fraunces', Georgia, 'Times New Roman', serif;
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

    /* Medidas adaptativas del hero (se recalculan por breakpoint) */
    --hero-nav-h: 80px;          /* alto real de .navbar-premium + holgura */
    --hero-photo-max-h: 84vh;    /* tope de la foto de los médicos */
    --hero-scene-max-h: 640px;   /* tope del escenario 3D */
    --hero-ecg-h: clamp(50px, 6vw, 85px);      /* banda de la línea ECG */
    --hero-ecg-gap: clamp(0.75rem, 2vh, 1.75rem); /* aire entre el contenido y el ECG */
}

/* ─────────────────────────────────────────────────────────────
   PANTALLA COMPLETA ESTRICTA SIN SCROLL (DESKTOP)
   ───────────────────────────────────────────────────────────── */
body.full-viewport-page {
    height: 100vh !important;
    height: 100dvh !important;
    overflow: hidden !important;
    overflow-x: hidden !important;
    margin: 0;
    padding: 0;
    background-color: var(--bg-dark);
}

body.full-viewport-page main {
    height: 100vh;
    height: 100dvh;
    padding-top: var(--hero-nav-h);
    box-sizing: border-box;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

/* Supresión total de pies de página en el index full-viewport */
body.full-viewport-page footer,
body.full-viewport-page footer.footer,
body.full-viewport-page .footer-premium {
    display: none !important;
}

/* Contenedor principal centrado */
.cockpit-hero-wrapper {
    width: 100%;
    max-width: 1480px;
    height: 100%;
    margin: 0 auto;
    padding: clamp(0.75rem, 1.6vh, 1.25rem) clamp(1rem, 2.6vw, 2.5rem);
    /* La línea ECG vive pegada al fondo: se le reserva su banda para que el
       texto y la foto no acaben encima de ella. */
    padding-bottom: calc(var(--hero-ecg-h) + var(--hero-ecg-gap));
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr);
    gap: clamp(1.5rem, 3.2vw, 3.5rem);
    align-items: center;
    box-sizing: border-box;
    position: relative;
    z-index: 2;
}

/* Línea ECG animada que recorre la base de la pantalla */
.cockpit-hero-wrapper .hero-ecg {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: var(--hero-ecg-h);
    z-index: 0;
    pointer-events: none;
    opacity: 0.55;
    mask-image: linear-gradient(90deg, transparent 0%, #000 12%, #000 88%, transparent 100%);
    -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 12%, #000 88%, transparent 100%);
}

.cockpit-hero-wrapper .ecg-trace {
    fill: none;
    stroke: var(--brand-cyan);
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 2200;
    stroke-dashoffset: 2200;
    animation: ecgSweep 5s linear infinite;
    filter: drop-shadow(0 0 5px rgba(56, 189, 248, 0.8)) drop-shadow(0 0 12px rgba(99, 102, 241, 0.4));
}

@keyframes ecgSweep {
    0%   { stroke-dashoffset: 2200; }
    55%  { stroke-dashoffset: 0; }
    100% { stroke-dashoffset: -2200; }
}

/* ─────────────────────────────────────────────────────────────
   COLUMNA IZQUIERDA: PALETA Y TIPOGRAFÍA ORIGINAL DE LA MARCA
   ───────────────────────────────────────────────────────────── */
.hero-text-panel {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: clamp(0.6rem, 1.4vh, 1.05rem);
    min-width: 0;
    z-index: 10;
}

.hero-pill-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.32rem 0.85rem;
    border-radius: 9999px;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(167, 139, 250, 0.35);
    font-size: 0.76rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    color: #c7d2fe;
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.2);
    width: fit-content;
    backdrop-filter: blur(12px);
}

.hero-pill-badge .pulse-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #a78bfa;
    box-shadow: 0 0 8px #a78bfa;
    animation: livePulseDot 2s infinite ease-in-out;
}

@keyframes livePulseDot {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.4); opacity: 0.4; }
}

.hero-title-group {
    margin: 0;
}

.hero-title-main {
    font-size: clamp(2.1rem, 3.2vw, 3.2rem);
    font-weight: 800;
    line-height: 1.06;
    letter-spacing: -0.03em;
    margin: 0;
}

.hero-title-main .highlight {
    background: linear-gradient(135deg, #ffffff 25%, #a78bfa 75%, #818cf8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: block;
}

.hero-title-subhead {
    font-family: var(--font-display);
    font-size: clamp(1.1rem, 1.45vw, 1.45rem);
    font-weight: 500;
    color: #e2e8f0;
    margin-top: 0.25rem;
    display: block;
    letter-spacing: -0.01em;
}

.hero-lead-paragraph {
    font-size: clamp(0.85rem, 0.95vw, 0.96rem);
    line-height: 1.58;
    color: #cbd5e1;
    margin: 0;
    max-width: 580px;
    text-align: justify;
    text-justify: inter-word;
}

.hero-lead-paragraph strong {
    color: #ffffff;
    font-weight: 600;
}

/* Destacado de recursos clínicos de referencia.
   Va separado del párrafo de apertura: pegado se leía como un solo bloque. */
.hero-clinical-sources {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-top: clamp(0.65rem, 1.9vh, 1.35rem);
    padding-top: clamp(0.65rem, 1.9vh, 1.35rem);
    border-top: 1px solid rgba(167, 139, 250, 0.16);
    width: 100%;
    max-width: 620px;
}

.hero-clinical-sources .sources-label {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.72rem;
    font-weight: 700;
    color: #a5b4fc;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.hero-clinical-sources .sources-label i {
    color: var(--brand-cyan);
    font-size: 0.8rem;
}

.hero-clinical-sources .sources-pills-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.source-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.22rem 0.6rem 0.22rem 0.3rem;
    font-size: 0.74rem;
    font-weight: 600;
    border-radius: 8px;
    background: rgba(15, 23, 42, 0.75);
    border: 1px solid rgba(167, 139, 250, 0.22);
    color: #e2e8f0;
    backdrop-filter: blur(10px);
    transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
    cursor: default;
    user-select: none;
}

.source-logo-img {
    width: 18px;
    height: 18px;
    border-radius: 4px;
    object-fit: cover;
    display: block;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
    flex-shrink: 0;
}

.source-pill:hover {
    transform: translateY(-2px);
}

.source-pill.pill-uptodate:hover {
    border-color: #38bdf8;
    box-shadow: 0 4px 14px rgba(56, 189, 248, 0.35);
    color: #f0f9ff;
}

.source-pill.pill-dynamed:hover {
    border-color: #3b82f6;
    box-shadow: 0 4px 14px rgba(59, 130, 246, 0.35);
    color: #eff6ff;
}

.source-pill.pill-sanford:hover {
    border-color: #f87171;
    box-shadow: 0 4px 14px rgba(248, 113, 113, 0.35);
    color: #fff1f2;
}

.source-pill.pill-clinicalkey:hover {
    border-color: #f97316;
    box-shadow: 0 4px 14px rgba(249, 115, 22, 0.35);
    color: #fff7ed;
}

.source-pill.pill-mcgrawhill:hover {
    border-color: #ef4444;
    box-shadow: 0 4px 14px rgba(239, 68, 68, 0.35);
    color: #fef2f2;
}

.source-pill.pill-bestpractice:hover {
    border-color: #06b6d4;
    box-shadow: 0 4px 14px rgba(6, 182, 212, 0.35);
    color: #ecfeff;
}

.source-pill.pill-lexicomp:hover {
    border-color: #a855f7;
    box-shadow: 0 4px 14px rgba(168, 85, 247, 0.35);
    color: #faf5ff;
}

.source-pill.pill-pubmed:hover {
    border-color: #60a5fa;
    box-shadow: 0 4px 14px rgba(96, 165, 250, 0.35);
    color: #eff6ff;
}

.source-pill.pill-ovidsp:hover {
    border-color: #818cf8;
    box-shadow: 0 4px 14px rgba(129, 140, 248, 0.35);
    color: #e0e7ff;
}

.source-pill.pill-europepmc:hover {
    border-color: #38bdf8;
    box-shadow: 0 4px 14px rgba(56, 189, 248, 0.35);
    color: #f0f9ff;
}

/* Botones de acción oficiales */
.hero-btn-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
    margin-top: 0.15rem;
}

.btn-hero-primary {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.74rem 1.55rem;
    border-radius: 12px;
    background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
    color: #ffffff;
    font-size: 0.92rem;
    font-weight: 700;
    text-decoration: none;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 10px 25px -5px rgba(79, 70, 229, 0.5), 0 0 20px rgba(99, 102, 241, 0.3);
    transition: all 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-hero-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 30px -5px rgba(79, 70, 229, 0.7), 0 0 30px rgba(99, 102, 241, 0.5);
    color: #ffffff;
}

.btn-hero-secondary {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.82rem 1.6rem;
    border-radius: 12px;
    background: rgba(15, 15, 35, 0.65);
    color: #e2e8f0;
    font-size: 0.95rem;
    font-weight: 600;
    text-decoration: none;
    border: 1px solid rgba(167, 139, 250, 0.25);
    backdrop-filter: blur(14px);
    transition: all 0.28s ease;
}

.btn-hero-secondary:hover {
    background: rgba(30, 27, 75, 0.8);
    border-color: rgba(167, 139, 250, 0.5);
    color: #c7d2fe;
    transform: translateY(-2px);
}

/* Distintivos de confianza */
.hero-trust-row {
    display: flex;
    flex-wrap: wrap;
    gap: 1.25rem;
    list-style: none;
    padding: 0;
    margin: 0.25rem 0 0;
}

.hero-trust-row li {
    font-size: 0.8rem;
    color: #94a3b8;
    display: flex;
    align-items: center;
    gap: 0.45rem;
    font-weight: 500;
}

.hero-trust-row li i {
    color: #a78bfa;
}

/* ─────────────────────────────────────────────────────────────
   COLUMNA DERECHA: ESCENARIO 3D INTERACTIVO
   MÉDICOS FUSIONANDO CONOCIMIENTO CLÍNICO E INTELIGENCIA ARTIFICIAL
   SIN ETIQUETAS QUE TAPEN LA IMAGEN
   ───────────────────────────────────────────────────────────── */
.hero-scene-3d {
    position: relative;
    width: 100%;
    height: 100%;
    min-width: 0;
    max-height: var(--hero-scene-max-h);
    display: flex;
    align-items: flex-end;
    justify-content: center;
}

/* Canvas Three.js de partículas bio-fotónicas */
.webgl-canvas-container {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
}

.webgl-canvas-container canvas {
    width: 100%;
    height: 100%;
    display: block;
}

/* Resplandor ambiental de fondo */
.scene-glow-original {
    position: absolute;
    width: 90%;
    height: 90%;
    bottom: 5%;
    border-radius: 50%;
    background: radial-gradient(circle at center, rgba(99, 102, 241, 0.22) 0%, rgba(139, 92, 246, 0.1) 45%, transparent 72%);
    filter: blur(45px);
    z-index: 1;
    pointer-events: none;
}

/* Contenedor del equipo con paralaje 3D interactivo */
.team-hologram-composition {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 680px;
    height: 100%;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    transform-style: preserve-3d;
    transition: transform 0.15s ease-out;
    cursor: default;
}

/* Imagen de los médicos (FONDO TRANSPARENTE, SIN BORDES) */
.team-ai-touch-photo {
    max-height: var(--hero-photo-max-h);
    max-width: 100%;
    height: auto;
    width: auto;
    object-fit: contain;
    position: relative;
    z-index: 2;
    filter: drop-shadow(0 20px 45px rgba(5, 5, 18, 0.9));
    -webkit-mask-image: linear-gradient(180deg, #000 0%, #000 82%, rgba(0,0,0,0.4) 93%, transparent 100%);
    mask-image: linear-gradient(180deg, #000 0%, #000 82%, rgba(0,0,0,0.4) 93%, transparent 100%);
    user-select: none;
    -webkit-user-drag: none;
    display: block;
}

/* Contenedor del equipo con capas de párpados y pestañeo alineado al subpíxel */
.team-photo-wrap {
    position: relative;
    display: inline-flex;
    align-items: flex-end;
    justify-content: center;
    max-height: var(--hero-photo-max-h);
    max-width: 100%;
    z-index: 2;
}

.team-photo-wrap picture {
    display: contents;
}

/* Capas de pestañeo de los médicos */
.team-photo-wrap .hero-doctor-blink {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    opacity: 0;
    pointer-events: none;
    z-index: 3;
    will-change: opacity;
    -webkit-mask-image: linear-gradient(180deg, #000 0%, #000 82%, rgba(0,0,0,0.4) 93%, transparent 100%);
    mask-image: linear-gradient(180deg, #000 0%, #000 82%, rgba(0,0,0,0.4) 93%, transparent 100%);
}

.team-photo-wrap.female-blink-half .hero-blink-female-half {
    opacity: 1 !important;
}

.team-photo-wrap.female-blink-closed .hero-blink-female-closed {
    opacity: 1 !important;
}

.team-photo-wrap.male-blink-quarter .hero-blink-male-quarter {
    opacity: 1 !important;
}

.team-photo-wrap.male-blink-half .hero-blink-male-half {
    opacity: 1 !important;
}

.team-photo-wrap.male-blink-closed .hero-blink-male-closed {
    opacity: 1 !important;
}

/* Resplandor dinámico detrás del microchip de IA */
.central-ai-orb-glow {
    position: absolute;
    top: 51.5%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 140px;
    height: 140px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(56, 189, 248, 0.4) 0%, rgba(99, 102, 241, 0.18) 50%, transparent 72%);
    filter: blur(20px);
    z-index: 1;
    pointer-events: none;
    animation: orbEnergyPulse 3.5s ease-in-out infinite alternate;
}

@keyframes orbEnergyPulse {
    0%   { transform: translate(-50%, -50%) scale(0.9); opacity: 0.7; }
    100% { transform: translate(-50%, -50%) scale(1.18); opacity: 1; }
}

/* ─────────────────────────────────────────────────────────────
   RESPONSIVO — de un móvil de 320 px a un monitor ultrapanorámico
   Tres piezas sostienen todo lo de abajo:
     1. --hero-nav-h: el navbar es FIJO, así que nada del hero puede
        quedar debajo de él (a 360 px el badge llegó a top:-49 px).
     2. El modo «una sola pantalla» (100dvh sin scroll) sólo se
        mantiene mientras el hero CABE; si no cabe, se devuelve el
        desplazamiento en vez de recortar el contenido.
     3. Topes de la foto por variable, para que nunca empuje al texto
        fuera de la pantalla.
   ───────────────────────────────────────────────────────────── */

/* ═══ Monitores grandes (≥1600 px) ═══ */
@media (min-width: 1600px) {
    :root {
        --hero-scene-max-h: 720px;
    }
    .cockpit-hero-wrapper {
        max-width: 1620px;
    }
}

/* ═══ Laptops (1081-1400 px): misma pantalla única, más compacta ═══ */
@media (min-width: 1081px) and (max-width: 1400px) {
    :root {
        --hero-scene-max-h: 560px;
    }
    .cockpit-hero-wrapper {
        gap: 2.25rem;
    }
}

/* ═══ Pantallas bajas (laptop 13"/14" de 768-800 px de alto) ═══ */
@media (min-width: 1081px) and (max-height: 860px) {
    :root {
        --hero-photo-max-h: 74vh;
        --hero-scene-max-h: 520px;
        --hero-ecg-h: clamp(44px, 5vw, 62px);
    }
    .hero-text-panel {
        gap: 0.7rem;
    }
    .hero-title-main {
        font-size: clamp(1.8rem, 2.6vw, 2.6rem);
    }
    .hero-lead-paragraph {
        font-size: 0.86rem;
        line-height: 1.5;
    }
    .hero-clinical-sources .sources-label {
        font-size: 0.68rem;
    }
    .source-pill {
        font-size: 0.7rem;
    }
}

/* ═══ Pantallas MUY bajas en escritorio: el hero ya no cabe ═══
   Antes se recortaba en silencio; ahora la página se desplaza. */
@media (min-width: 1081px) and (max-height: 700px) {
    :root {
        --hero-ecg-h: 46px;
        --hero-ecg-gap: 0.75rem;
    }
    body.full-viewport-page {
        height: auto !important;
        min-height: 100dvh !important;
        overflow: visible !important;
        overflow-x: hidden !important;
    }
    body.full-viewport-page main {
        height: auto;
        min-height: 100dvh;
        overflow: visible;
        padding-bottom: 2rem;
    }
    .cockpit-hero-wrapper {
        height: auto;
    }
    :root {
        --hero-photo-max-h: 62vh;
    }
}

/* ═══ Tablets y móviles (≤1080 px): una columna con scroll natural ═══ */
@media (max-width: 1080px) {
    :root {
        --hero-photo-max-h: 46vh;
        --hero-scene-max-h: 460px;
    }

    /* landing.css deja el index en 100dvh + overflow:hidden y eso
       RECORTABA el hero (en 390x844 el contenido mide 947 px). */
    body.full-viewport-page,
    body.index-landing.no-scroll-page,
    body.index-landing.no-scroll-page > main,
    body.full-viewport-page main {
        height: auto !important;
        max-height: none !important;
        overflow: visible !important;
        overflow-x: hidden !important;
    }
    body.full-viewport-page {
        min-height: 100dvh !important;
    }
    body.full-viewport-page main {
        display: block;
        padding-top: var(--hero-nav-h);
        padding-bottom: 1.5rem;
    }

    .cockpit-hero-wrapper {
        grid-template-columns: minmax(0, 1fr);
        gap: 1.75rem;
        height: auto;
        max-width: 820px;
        padding: 1.25rem 1.25rem 2rem;
    }

    .hero-text-panel {
        text-align: center;
        align-items: center;
    }
    .hero-lead-paragraph {
        text-align: center;
        max-width: 620px;
    }
    .hero-btn-row,
    .hero-trust-row,
    .sources-pills-row {
        justify-content: center;
    }
    /* landing.css (hero antiguo) les impone width:100% y flex:1 1 0, y el
       rótulo salía partido o recortado dentro del botón */
    body.index-landing .hero-btn-row .btn-hero-primary,
    body.index-landing .hero-btn-row .btn-hero-secondary {
        width: auto;
        flex: 0 1 auto;
        white-space: nowrap;
        padding: 0.7rem 1.4rem;
        font-size: 0.9rem;
        gap: 0.55rem;
    }
    body.index-landing .hero-btn-row .btn-hero-primary i,
    body.index-landing .hero-btn-row .btn-hero-secondary i {
        font-size: 0.95rem;
    }
    .hero-clinical-sources {
        align-items: center;
        margin-left: auto;
        margin-right: auto;
    }

    .hero-scene-3d {
        height: auto;
    }
    .team-hologram-composition {
        height: auto;
        max-width: 520px;
    }
    .central-ai-orb-glow {
        width: 150px;
        height: 150px;
    }
    .cockpit-hero-wrapper .hero-ecg {
        height: 46px;
        opacity: 0.4;
    }
    :root {
        --hero-ecg-h: 46px;
    }
}

/* Entre 993 y 1100 px el menú completo se parte en dos líneas (~93 px) */
@media (min-width: 993px) and (max-width: 1100px) {
    :root {
        --hero-nav-h: 104px;
    }
}

/* El navbar colapsa a hamburguesa por debajo de 992 px y mide ~50 px */
@media (max-width: 992px) {
    :root {
        --hero-nav-h: 64px;
    }
}

/* ═══ Tablet vertical y móviles grandes (≤768 px) ═══ */
@media (max-width: 768px) {
    :root {
        --hero-photo-max-h: 42vh;
        --hero-scene-max-h: 380px;
    }
    .cockpit-hero-wrapper {
        gap: 1.4rem;
        padding: 1rem 1rem 1.75rem;
    }
    .hero-title-main {
        font-size: clamp(1.9rem, 7.5vw, 2.6rem);
    }
    .hero-title-subhead {
        font-size: clamp(1rem, 3.8vw, 1.25rem);
    }
    .hero-pill-badge {
        font-size: 0.7rem;
        padding: 0.3rem 0.7rem;
        line-height: 1.35;
    }
    .hero-lead-paragraph {
        font-size: 0.9rem;
    }
    .team-hologram-composition {
        max-width: 420px;
    }
}

/* ═══ Móviles (≤640 px) ═══ */
@media (max-width: 640px) {
    .hero-btn-row {
        flex-direction: column;
        width: 100%;
    }
    body.index-landing .hero-btn-row .btn-hero-primary,
    body.index-landing .hero-btn-row .btn-hero-secondary {
        width: 100%;
        flex: 0 0 auto;
        justify-content: center;
    }
    .hero-trust-row {
        gap: 0.5rem 1rem;
    }
    .hero-trust-row li {
        font-size: 0.75rem;
    }
    .hero-clinical-sources .sources-label {
        font-size: 0.66rem;
        line-height: 1.35;
        text-align: center;
    }
    .source-pill {
        font-size: 0.7rem;
        padding: 0.2rem 0.5rem 0.2rem 0.25rem;
    }
    .source-logo-img {
        width: 16px;
        height: 16px;
    }
}

/* ═══ Móviles pequeños (≤380 px: iPhone SE, Galaxy mini) ═══ */
@media (max-width: 380px) {
    :root {
        --hero-photo-max-h: 38vh;
    }
    .cockpit-hero-wrapper {
        padding: 0.85rem 0.85rem 1.5rem;
    }
    .hero-title-main {
        font-size: 1.75rem;
    }
    .hero-lead-paragraph {
        font-size: 0.84rem;
    }
    .source-pill {
        font-size: 0.66rem;
    }
}

/* ═══ Móvil y tablet en horizontal (pantalla baja y ancha) ═══ */
@media (max-width: 1080px) and (max-height: 560px) and (orientation: landscape) {
    :root {
        --hero-nav-h: 58px;
        --hero-photo-max-h: 72vh;
        --hero-scene-max-h: 320px;
    }
    .cockpit-hero-wrapper {
        grid-template-columns: minmax(0, 1fr) minmax(0, 0.85fr);
        gap: 1.25rem;
        max-width: 1080px;
    }
    .hero-text-panel {
        text-align: left;
        align-items: flex-start;
    }
    .hero-lead-paragraph {
        text-align: left;
    }
    .hero-btn-row,
    .hero-trust-row,
    .sources-pills-row {
        justify-content: flex-start;
    }
    .hero-clinical-sources {
        align-items: flex-start;
    }
    .hero-btn-row {
        flex-direction: row;
        width: auto;
    }
    body.index-landing .hero-btn-row .btn-hero-primary,
    body.index-landing .hero-btn-row .btn-hero-secondary {
        width: auto;
        flex: 0 1 auto;
    }
}

/* ═══ Pantallas táctiles: sin estados de hover pegados ═══ */
@media (hover: none) {
    .source-pill:hover,
    .btn-hero-primary:hover,
    .btn-hero-secondary:hover {
        transform: none;
    }
}

/* ═══ Movimiento reducido ═══ */
@media (prefers-reduced-motion: reduce) {
    .cockpit-hero-wrapper .ecg-trace,
    .hero-pill-badge .pulse-dot,
    .central-ai-orb-glow {
        animation: none !important;
    }
    .source-pill,
    .btn-hero-primary,
    .btn-hero-secondary {
        transition: none;
    }
}
