/* ==========================================================================
   PUNTO AMÉRICA — Consultoría Logística
   Rediseño premium · 2024
   Design system: editorial light · aurora gradients · glassmorphism
   ========================================================================== */

/* ---------- Design Tokens ---------- */
:root {
    /* Acento de la marca: cambiar SOLO este bloque para cambiar la paleta */
    --accent: #e11d38;
    --accent-rgb: 225, 29, 56;
    --accent-deep: #b3122a;
    --accent-mid: #ff5e3a;
    --accent-end: #ff9a3d;
    --accent-warm: #ff7a3d;
    --accent-warm-rgb: 255, 122, 61;
    --accent-soft: #ff9a7a;          /* acento claro sobre fondos oscuros */
    --accent-soft-rgb: 255, 154, 122;
    --accent-pale: #ffd9c2;
    --accent-chip: #ffc9ae;
    --accent-alt: #b224ef;
    --accent-alt-rgb: 178, 36, 239;
    --on-accent: #ffffff;            /* texto sobre fondos de acento */

    /* Brand */
    --brand-red: var(--accent);
    --brand-red-deep: var(--accent-deep);
    --brand-blue: #1e3fd0;
    --brand-blue-deep: #0a2a5e;
    --warm: var(--accent-warm);

    /* Neutrals / surfaces */
    --bg: #f5f6fb;
    --bg-2: #eceff8;
    --surface: #ffffff;
    --surface-2: #fbfcff;
    --ink: #0a1020;
    --ink-2: #3b475f;
    --ink-3: #6a778f;
    --line: rgba(10, 16, 32, 0.08);
    --line-strong: rgba(10, 16, 32, 0.14);
    --white: #ffffff;

    /* Dark bands */
    --navy: #071634;
    --navy-2: #0a1f47;

    /* Gradients */
    --grad-accent: linear-gradient(120deg, var(--accent) 0%, var(--accent-mid) 55%, var(--accent-end) 100%);
    --grad-cool: linear-gradient(120deg, #1e3fd0 0%, #38bdf8 100%);
    --grad-mix: linear-gradient(120deg, var(--accent) 0%, var(--accent-alt) 100%);
    --grad-text: linear-gradient(100deg, #ffffff 0%, var(--accent-pale) 60%, var(--accent-soft) 100%);

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(10, 16, 32, 0.04), 0 4px 12px rgba(10, 16, 32, 0.05);
    --shadow-md: 0 10px 30px rgba(10, 16, 32, 0.08), 0 2px 8px rgba(10, 16, 32, 0.05);
    --shadow-lg: 0 30px 60px -20px rgba(10, 16, 32, 0.28), 0 12px 24px -12px rgba(10, 16, 32, 0.16);
    --shadow-accent: 0 18px 40px -14px rgba(var(--accent-rgb), 0.5);

    /* Type */
    --font-main: 'Inter', system-ui, -apple-system, sans-serif;
    --font-display: 'Sora', 'Inter', sans-serif;
    --font-mono: 'JetBrains Mono', ui-monospace, monospace;

    /* Layout */
    --container-width: 1220px;
    --radius: 22px;
    --radius-sm: 14px;
    --radius-lg: 30px;
    --ease: cubic-bezier(0.22, 1, 0.36, 1);
    --transition: all 0.35s var(--ease);
}

/* ---------- Reset ---------- */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 90px;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-main);
    color: var(--ink);
    line-height: 1.65;
    background-color: var(--bg);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

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

::selection {
    background: var(--brand-red);
    color: #fff;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 11px;
}

::-webkit-scrollbar-track {
    background: var(--bg-2);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(var(--brand-red), var(--warm));
    border-radius: 10px;
    border: 3px solid var(--bg-2);
}

/* ---------- Global grain overlay ---------- */
body::after {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 9998;
    opacity: 0.035;
    mix-blend-mode: multiply;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---------- Scroll progress bar ---------- */
.progress-bar {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    width: 0%;
    background: var(--grad-accent);
    z-index: 1200;
    transition: width 0.1s linear;
    box-shadow: 0 0 12px rgba(var(--accent-rgb), 0.6);
}

/* ---------- Container & utilities ---------- */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 26px;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-mono);
    font-size: 0.74rem;
    font-weight: 500;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--brand-red);
    margin-bottom: 20px;
}

.eyebrow::before {
    content: "";
    width: 26px;
    height: 1.5px;
    background: var(--brand-red);
    display: inline-block;
}

.eyebrow.center {
    justify-content: center;
}

/* ---------- Buttons ---------- */
.btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 15px 32px;
    border-radius: 100px;
    font-family: var(--font-main);
    font-weight: 600;
    font-size: 0.98rem;
    letter-spacing: 0.01em;
    cursor: pointer;
    border: none;
    transition: var(--transition);
    will-change: transform;
    overflow: hidden;
    white-space: nowrap;
}

.btn i {
    transition: transform 0.35s var(--ease);
}

.btn:hover i {
    transform: translateX(4px);
}

.btn-primary {
    background: var(--grad-accent);
    background-size: 160% 160%;
    color: #fff;
    box-shadow: var(--shadow-accent);
}

.btn-primary:hover {
    box-shadow: 0 22px 50px -12px rgba(var(--accent-rgb), 0.62);
    transform: translateY(-3px);
    background-position: 100% 0;
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.06);
    color: #fff;
    border: 1.5px solid rgba(255, 255, 255, 0.35);
    backdrop-filter: blur(6px);
}

.btn-secondary:hover {
    background: #fff;
    color: var(--navy);
    border-color: #fff;
    transform: translateY(-3px);
}

.btn-ghost {
    background: var(--surface);
    color: var(--ink);
    border: 1.5px solid var(--line-strong);
    box-shadow: var(--shadow-sm);
}

.btn-ghost:hover {
    border-color: var(--brand-red);
    color: var(--brand-red);
    transform: translateY(-3px);
}

/* ---------- Header / Nav ---------- */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1100;
    padding: 20px 0;
    transition: padding 0.4s var(--ease), background 0.4s var(--ease);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 12px;
    padding-bottom: 12px;
    border-radius: 100px;
    transition: var(--transition);
}

.header.scrolled {
    padding: 12px 0;
}

.header.scrolled .container {
    background: rgba(255, 255, 255, 0.72);
    backdrop-filter: blur(18px) saturate(180%);
    -webkit-backdrop-filter: blur(18px) saturate(180%);
    box-shadow: var(--shadow-md);
    border: 1px solid rgba(255, 255, 255, 0.6);
    padding-left: 22px;
    padding-right: 14px;
}

.logo {
    display: flex;
    align-items: center;
    z-index: 1101;
}

.logo img {
    height: 50px;
    width: auto;
    transition: filter 0.45s var(--ease), height 0.35s var(--ease), opacity 0.35s var(--ease);
    /* Sobre el hero oscuro la cabecera es transparente: el logo se muestra en
       blanco para que el azul de la marca no se pierda contra la foto. */
    filter: brightness(0) invert(1) drop-shadow(0 2px 10px rgba(0, 0, 0, 0.45));
}

/* Al hacer scroll la barra se vuelve blanca: el logo recupera su color de marca */
.header.scrolled .logo img {
    filter: none;
}

.nav {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-list {
    display: flex;
    align-items: center;
    gap: 4px;
    background: rgba(255, 255, 255, 0.55);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    padding: 6px;
    border-radius: 100px;
    border: 1px solid rgba(255, 255, 255, 0.6);
    box-shadow: var(--shadow-sm);
}

.nav-link {
    position: relative;
    font-weight: 500;
    font-size: 0.94rem;
    color: var(--ink-2);
    padding: 9px 18px;
    border-radius: 100px;
    transition: var(--transition);
}

.nav-link:not(.btn-primary):hover,
.nav-link.active {
    color: var(--ink);
    background: rgba(10, 16, 32, 0.05);
}

.nav-link.btn-primary {
    color: #fff;
    padding: 11px 24px;
    margin-left: 4px;
    font-weight: 600;
}

@media (max-width: 1080px) and (min-width: 769px) {
    .nav-link {
        white-space: nowrap;
        font-size: 0.86rem;
        padding: 8px 11px;
    }

    .nav-link.btn-primary {
        padding: 10px 16px;
    }

    .logo img {
        height: 42px;
    }
}

.nav-link.btn-primary:hover {
    color: #fff;
    background: var(--grad-accent);
}

.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 10px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid var(--line);
    z-index: 1101;
}

.bar {
    display: block;
    width: 24px;
    height: 2.5px;
    border-radius: 3px;
    background-color: var(--ink);
    transition: var(--transition);
}

/* ==========================================================================
   HERO
   ========================================================================== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 160px 0 90px;
    background: radial-gradient(120% 120% at 50% 0%, #0a2350 0%, #071634 55%, #040d22 100%);
    color: #fff;
    overflow: hidden;
    isolation: isolate;
}

/* Background video */
.hero-video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: -3;
    pointer-events: none;
}

.hero-video-overlay {
    position: absolute;
    inset: 0;
    z-index: -2;
    pointer-events: none;
    background:
        radial-gradient(120% 90% at 50% 42%, rgba(4, 13, 34, 0.25) 0%, rgba(4, 13, 34, 0.62) 70%, rgba(4, 13, 34, 0.8) 100%),
        linear-gradient(180deg, rgba(4, 13, 34, 0.45) 0%, rgba(4, 13, 34, 0.35) 45%, rgba(4, 13, 34, 0.85) 100%);
}

/* Foto de fondo del hero (aguas bravas) */
/* El contenedor recibe el paralaje (JS) y la imagen el Ken Burns (CSS),
   así ambos movimientos se combinan sin pisarse el mismo 'transform'. */
.hero-photo-wrap {
    position: absolute;
    /* margen extra para que el paralaje nunca descubra los bordes */
    inset: -2.5% -2%;
    z-index: -3;
    overflow: hidden;
    pointer-events: none;
    will-change: transform;
}

.hero-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 46%;
    transform-origin: 55% 60%;
    animation: heroKenBurns 30s ease-in-out infinite alternate;
    will-change: transform;
}

@keyframes heroKenBurns {
    from {
        transform: scale(1.03) translate3d(-0.8%, 0.5%, 0);
    }

    to {
        transform: scale(1.09) translate3d(1%, -0.6%, 0);
    }
}

.hero-has-photo .hero-aurora,
.hero-has-photo .hero-grid {
    display: none;
}

/* Velo reforzado: la espuma blanca exige más contraste para el texto */
.hero-has-photo .hero-video-overlay {
    background:
        /* sombra muy localizada tras el texto: el resto de la foto queda luminosa */
        radial-gradient(42% 30% at 50% 42%, rgba(4, 13, 34, 0.4) 0%, rgba(4, 13, 34, 0.18) 58%, rgba(4, 13, 34, 0) 100%),
        /* solo arriba (cabecera) y abajo (transición con la siguiente sección) */
        linear-gradient(180deg, rgba(4, 13, 34, 0.32) 0%, rgba(4, 13, 34, 0) 20%, rgba(4, 13, 34, 0) 74%, rgba(4, 13, 34, 0.5) 100%);
}

/* drop-shadow se calcula sobre las letras ya pintadas, así que también protege
   el texto con degradado sin ensuciarlo (a diferencia de text-shadow) */
.hero-has-photo .hero-title {
    text-shadow: none;
    filter: drop-shadow(0 2px 16px rgba(4, 13, 34, 0.9)) drop-shadow(0 1px 3px rgba(4, 13, 34, 0.7));
}

.hero-has-photo .hero-subtitle,
.hero-has-photo .eyebrow {
    text-shadow: 0 1px 3px rgba(4, 13, 34, 0.85), 0 2px 20px rgba(4, 13, 34, 0.9), 0 0 40px rgba(4, 13, 34, 0.5);
}

.hero-has-photo .hero-subtitle {
    color: #fff;
    font-weight: 500;
    /* panel de cristal: el subtítulo es texto fino y sobre la espuma blanca
       la sombra sola no basta para leerlo */
    padding: 16px 26px;
    border-radius: 18px;
    background: rgba(7, 22, 52, 0.5);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    text-shadow: none;
}

@media (max-width: 600px) {
    .hero-has-photo .hero-subtitle {
        padding: 14px 16px;
        border-radius: 16px;
    }
}

.hero-has-photo .hero-stats {
    background: rgba(7, 22, 52, 0.42);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

/* Sobre una foto luminosa, los elementos transparentes necesitan fondo propio */
.hero-has-photo .btn-secondary {
    background: rgba(7, 22, 52, 0.48);
    border-color: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.hero-has-photo .btn-secondary:hover {
    background: #fff;
    color: var(--navy);
}

.hero-has-photo .eyebrow {
    padding: 8px 16px;
    border-radius: 100px;
    background: rgba(7, 22, 52, 0.46);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: var(--accent-chip);
    text-shadow: none;
}

.hero-has-photo .eyebrow::before {
    background: var(--accent-chip);
}

/* En móvil el texto ocupa casi todo el hero y el encuadre cae sobre la espuma:
   velo más uniforme para mantener la lectura */
@media (max-width: 768px) {
    /* Velo ligero: el texto ya lleva paneles de cristal y sombra propios,
       así la foto conserva su color */
    .hero-has-photo .hero-video-overlay {
        background: linear-gradient(180deg, rgba(4, 13, 34, 0.45) 0%, rgba(4, 13, 34, 0.08) 22%, rgba(4, 13, 34, 0.08) 72%, rgba(4, 13, 34, 0.5) 100%);
    }

    /* En vertical solo se ve ~1/4 del ancho de la foto: encuadre sobre la
       tripulación (tercio izquierdo) en vez de la espuma del centro */
    .hero-has-photo .hero-photo {
        object-position: 24% 50%;
        transform-origin: 30% 65%;
    }
}

/* When a video is present, the animated blobs/grid act only as fallback */
.hero-has-video .hero-aurora,
.hero-has-video .hero-grid {
    display: none;
}

/* Aurora blobs */
.hero-aurora {
    position: absolute;
    inset: 0;
    z-index: -2;
    overflow: hidden;
}

.blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(70px);
    opacity: 0.55;
    will-change: transform;
}

.blob-1 {
    width: 620px;
    height: 620px;
    top: -180px;
    left: -120px;
    background: radial-gradient(circle, var(--accent), transparent 70%);
    animation: float1 18s ease-in-out infinite;
}

.blob-2 {
    width: 560px;
    height: 560px;
    bottom: -200px;
    right: -100px;
    background: radial-gradient(circle, #1e6fd0, transparent 70%);
    animation: float2 22s ease-in-out infinite;
}

.blob-3 {
    width: 440px;
    height: 440px;
    top: 30%;
    right: 20%;
    background: radial-gradient(circle, var(--accent-alt), transparent 70%);
    opacity: 0.35;
    animation: float3 26s ease-in-out infinite;
}

@keyframes float1 {

    0%,
    100% {
        transform: translate(0, 0) scale(1);
    }

    50% {
        transform: translate(80px, 60px) scale(1.15);
    }
}

@keyframes float2 {

    0%,
    100% {
        transform: translate(0, 0) scale(1);
    }

    50% {
        transform: translate(-70px, -50px) scale(1.1);
    }
}

@keyframes float3 {

    0%,
    100% {
        transform: translate(0, 0) scale(1);
    }

    50% {
        transform: translate(-50px, 40px) scale(1.2);
    }
}

/* Grid + route overlay */
.hero-grid {
    position: absolute;
    inset: 0;
    z-index: -1;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
    background-size: 64px 64px;
    mask-image: radial-gradient(120% 90% at 50% 30%, #000 0%, transparent 75%);
    -webkit-mask-image: radial-gradient(120% 90% at 50% 30%, #000 0%, transparent 75%);
}

.hero-content {
    position: relative;
    max-width: 940px;
    margin: 0 auto;
    text-align: center;
    z-index: 2;
}

.hero .eyebrow {
    color: var(--accent-soft);
    justify-content: center;
}

.hero .eyebrow::before {
    background: var(--accent-soft);
}

.hero-title {
    font-family: var(--font-display);
    font-size: clamp(2.6rem, 6.2vw, 5rem);
    font-weight: 800;
    line-height: 1.04;
    letter-spacing: -0.03em;
    margin-bottom: 26px;
}

.hero-title .grad {
    background: var(--grad-text);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}

.hero-subtitle {
    font-size: clamp(1.05rem, 2vw, 1.28rem);
    max-width: 660px;
    margin: 0 auto 42px;
    color: rgba(255, 255, 255, 0.78);
    line-height: 1.6;
}

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 64px;
}

/* Hero stat strip */
.hero-stats {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 14px 36px;
    padding: 26px 34px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--radius);
    backdrop-filter: blur(12px);
    max-width: 780px;
    margin: 0 auto;
}

.hero-stat {
    text-align: center;
    flex: 1;
    min-width: 120px;
}

.hero-stat .num {
    font-family: var(--font-display);
    font-size: 1.9rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    background: var(--grad-text);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-stat .label {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.6);
    letter-spacing: 0.02em;
    margin-top: 4px;
}

.hero-stat + .hero-stat {
    border-left: 1px solid rgba(255, 255, 255, 0.12);
    padding-left: 24px;
}

/* Scroll cue */
.scroll-cue {
    position: absolute;
    bottom: 26px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    font-size: 0.7rem;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.5);
    z-index: 2;
}

.scroll-cue .mouse {
    width: 22px;
    height: 36px;
    border: 1.5px solid rgba(255, 255, 255, 0.4);
    border-radius: 12px;
    position: relative;
}

.scroll-cue .mouse::after {
    content: "";
    position: absolute;
    top: 7px;
    left: 50%;
    transform: translateX(-50%);
    width: 3px;
    height: 7px;
    border-radius: 3px;
    background: #fff;
    animation: wheel 1.6s ease-in-out infinite;
}

@keyframes wheel {

    0%,
    100% {
        opacity: 0;
        transform: translate(-50%, 0);
    }

    40% {
        opacity: 1;
        transform: translate(-50%, 8px);
    }
}

/* ---------- Marquee ---------- */
.marquee {
    background: var(--navy);
    color: #fff;
    padding: 20px 0;
    overflow: hidden;
    position: relative;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.marquee-track {
    display: flex;
    gap: 60px;
    width: max-content;
    animation: scrollX 32s linear infinite;
}

.marquee:hover .marquee-track {
    animation-play-state: paused;
}

.marquee-item {
    display: inline-flex;
    align-items: center;
    gap: 16px;
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 1.15rem;
    letter-spacing: 0.01em;
    color: rgba(255, 255, 255, 0.85);
    white-space: nowrap;
}

.marquee-item i {
    color: var(--warm);
    font-size: 0.9rem;
}

@keyframes scrollX {
    to {
        transform: translateX(-50%);
    }
}

/* ==========================================================================
   SECTIONS
   ========================================================================== */
.section {
    position: relative;
    padding: 110px 0;
}

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

.section-head.left {
    margin-left: 0;
    text-align: left;
}

.section-title {
    font-family: var(--font-display);
    font-size: clamp(2rem, 4vw, 3.1rem);
    font-weight: 800;
    line-height: 1.08;
    letter-spacing: -0.025em;
    color: var(--ink);
}

.section-title .accent {
    background: var(--grad-accent);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--ink-3);
    margin-top: 16px;
    line-height: 1.6;
}

/* ---------- Services (áreas) ---------- */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 26px;
}

.service-card {
    position: relative;
    background: var(--surface);
    padding: 38px 34px;
    border-radius: var(--radius);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
    text-align: left;
    overflow: hidden;
    transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease), border-color 0.4s var(--ease);
}

/* spotlight follows cursor */
.service-card::before {
    content: "";
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.4s ease;
    background: radial-gradient(340px circle at var(--mx, 50%) var(--my, 0%), rgba(var(--accent-rgb), 0.09), transparent 60%);
    pointer-events: none;
}

/* gradient top accent line */
.service-card::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--grad-accent);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.45s var(--ease);
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: transparent;
}

.service-card:hover::before {
    opacity: 1;
}

.service-card:hover::after {
    transform: scaleX(1);
}

.service-card .icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 62px;
    height: 62px;
    border-radius: 18px;
    font-size: 1.6rem;
    color: var(--brand-red);
    background: linear-gradient(135deg, rgba(var(--accent-rgb), 0.12), rgba(var(--accent-warm-rgb), 0.12));
    margin-bottom: 24px;
    transition: var(--transition);
}

.service-card:hover .icon {
    background: var(--grad-accent);
    color: #fff;
    transform: rotate(-6deg) scale(1.05);
    box-shadow: var(--shadow-accent);
}

.service-card h3 {
    font-family: var(--font-display);
    font-size: 1.32rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    margin-bottom: 8px;
    color: var(--ink);
}

.service-card .card-lead {
    font-size: 0.95rem;
    color: var(--ink-3);
    margin-bottom: 18px;
}

.service-list {
    display: flex;
    flex-direction: column;
    gap: 11px;
    margin-top: 4px;
}

.service-list li {
    position: relative;
    padding-left: 26px;
    font-size: 0.92rem;
    color: var(--ink-2);
    line-height: 1.5;
}

.service-list li::before {
    content: "\f058";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    position: absolute;
    left: 0;
    top: 1px;
    color: var(--brand-red);
    font-size: 0.85rem;
    opacity: 0.85;
}

/* ---------- Capabilities chips ---------- */
.capabilities {
    margin-top: 70px;
    text-align: center;
}

.cap-label {
    font-family: var(--font-mono);
    font-size: 0.74rem;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--ink-3);
    margin-bottom: 24px;
}

.chip-cloud {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    max-width: 900px;
    margin: 0 auto;
}

.chip {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 11px 20px;
    border-radius: 100px;
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--ink-2);
    transition: var(--transition);
    cursor: default;
}

.chip i {
    color: var(--brand-red);
    font-size: 0.85rem;
}

.chip:hover {
    transform: translateY(-4px);
    border-color: var(--brand-red);
    color: var(--ink);
    box-shadow: var(--shadow-md);
}

/* ---------- About ---------- */
.about {
    background: linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 100%);
}

.about-content {
    display: grid;
    grid-template-columns: 1.05fr 0.95fr;
    gap: 64px;
    align-items: center;
}

.about-text p {
    margin-bottom: 18px;
    font-size: 1.06rem;
    color: var(--ink-2);
    line-height: 1.75;
}

.about-sub {
    font-family: var(--font-display);
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--ink);
    margin: 28px 0 14px;
}

.about-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 8px;
}

.about-list li {
    position: relative;
    padding-left: 30px;
    font-size: 0.98rem;
    color: var(--ink-2);
}

.about-list li::before {
    content: "\f105";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    position: absolute;
    left: 6px;
    top: 0;
    color: var(--brand-red);
}

.about-visual {
    position: relative;
}

.about-image-wrap {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.about-image-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    aspect-ratio: 4 / 5;
    transition: transform 0.8s var(--ease);
}

.about-image-wrap:hover img {
    transform: scale(1.06);
}

.about-image-wrap::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 40%, rgba(7, 22, 52, 0.35) 100%);
}

/* Floating badge */
.exp-badge {
    position: absolute;
    bottom: -26px;
    left: -26px;
    background: var(--grad-accent);
    color: #fff;
    padding: 22px 28px;
    border-radius: var(--radius);
    box-shadow: var(--shadow-accent);
    z-index: 2;
}

.exp-badge .big {
    font-family: var(--font-display);
    font-size: 2.6rem;
    font-weight: 800;
    line-height: 1;
}

.exp-badge .small {
    font-size: 0.82rem;
    opacity: 0.92;
    margin-top: 4px;
    max-width: 130px;
}

.about-visual .deco-ring {
    position: absolute;
    top: -34px;
    right: -34px;
    width: 120px;
    height: 120px;
    border: 2px dashed rgba(var(--accent-rgb), 0.4);
    border-radius: 50%;
    z-index: -1;
    animation: spin 24s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ---------- Market stats band (dark) ---------- */
.stats-band {
    position: relative;
    background: radial-gradient(120% 140% at 80% 0%, #0a2350 0%, #071634 55%, #040d22 100%);
    color: #fff;
    overflow: hidden;
    isolation: isolate;
}

.stats-band .hero-grid {
    opacity: 0.6;
}

.stats-band .blob {
    opacity: 0.32;
}

.stats-band .section-title {
    color: #fff;
}

.stats-band .section-subtitle {
    color: rgba(255, 255, 255, 0.7);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 22px;
    position: relative;
    z-index: 2;
}

.stat-card {
    text-align: center;
    padding: 40px 26px;
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.045);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(8px);
    transition: var(--transition);
}

.stat-card:hover {
    transform: translateY(-8px);
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(var(--accent-soft-rgb), 0.4);
}

.stat-card .stat-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border-radius: 16px;
    background: var(--grad-accent);
    font-size: 1.4rem;
    color: #fff;
    margin-bottom: 20px;
    box-shadow: var(--shadow-accent);
}

.stat-card .stat-num {
    font-family: var(--font-display);
    font-size: 2.5rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1;
    background: var(--grad-text);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.stat-card .stat-label {
    font-size: 0.92rem;
    color: rgba(255, 255, 255, 0.72);
    margin-top: 12px;
    line-height: 1.4;
}

/* ---------- Why choose us ---------- */
.why-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 22px;
    counter-reset: why;
}

.why-item {
    position: relative;
    background: var(--surface);
    padding: 36px 32px 32px;
    border-radius: var(--radius);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    overflow: hidden;
}

.why-item::before {
    counter-increment: why;
    content: "0" counter(why);
    position: absolute;
    top: 22px;
    right: 28px;
    font-family: var(--font-display);
    font-size: 3.2rem;
    font-weight: 800;
    line-height: 1;
    color: transparent;
    -webkit-text-stroke: 1.5px rgba(var(--accent-rgb), 0.18);
    transition: var(--transition);
}

.why-item:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: transparent;
}

.why-item:hover::before {
    -webkit-text-stroke: 1.5px rgba(var(--accent-rgb), 0.5);
}

.why-item .why-icon {
    font-size: 1.5rem;
    color: var(--brand-red);
    margin-bottom: 18px;
}

.why-item h3 {
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--ink);
}

.why-item p {
    font-size: 0.96rem;
    color: var(--ink-3);
    line-height: 1.6;
}

/* ---------- Team ---------- */
.team {
    background: linear-gradient(180deg, var(--bg-2) 0%, var(--bg) 100%);
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 22px;
}

.team-card {
    text-align: center;
    padding: 40px 24px 34px;
    background: var(--surface);
    border-radius: var(--radius);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.team-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.avatar {
    width: 78px;
    height: 78px;
    margin: 0 auto 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-size: 1.55rem;
    font-weight: 700;
    color: #fff;
    background: var(--grad-cool);
    box-shadow: 0 12px 26px -10px rgba(30, 63, 208, 0.6);
    position: relative;
}

.team-card:nth-child(even) .avatar {
    background: var(--grad-accent);
    box-shadow: var(--shadow-accent);
}

.team-card h3 {
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--ink);
    margin-bottom: 4px;
}

.team-card p {
    font-size: 0.9rem;
    color: var(--ink-3);
}

/* ---------- Contact ---------- */
.contact {
    position: relative;
    background: radial-gradient(120% 130% at 20% 0%, #0a2350 0%, #071634 55%, #040d22 100%);
    color: #fff;
    overflow: hidden;
    isolation: isolate;
}

.contact .section-title {
    color: #fff;
}

.contact .section-subtitle {
    color: rgba(255, 255, 255, 0.72);
}

.contact-wrapper {
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    gap: 56px;
    max-width: 1040px;
    margin: 0 auto;
    align-items: stretch;
    position: relative;
    z-index: 2;
}

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

.contact-info-lead {
    font-size: 1.05rem;
    color: rgba(255, 255, 255, 0.75);
    margin-bottom: 8px;
    line-height: 1.6;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 20px 22px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: var(--transition);
}

.info-item:hover {
    background: rgba(255, 255, 255, 0.09);
    transform: translateX(6px);
}

.info-item .ico {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    flex-shrink: 0;
    border-radius: 12px;
    background: var(--grad-accent);
    font-size: 1.1rem;
    color: #fff;
}

.info-item .info-label {
    font-size: 0.74rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.5);
}

.info-item .info-value {
    font-size: 1rem;
    color: #fff;
    line-height: 1.4;
}

/* Form */
.contact-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
    padding: 40px;
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.055);
    border: 1px solid rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(14px);
    box-shadow: var(--shadow-lg);
}

.field {
    position: relative;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 16px 18px;
    border-radius: var(--radius-sm);
    border: 1.5px solid rgba(255, 255, 255, 0.16);
    background: rgba(255, 255, 255, 0.04);
    color: #fff;
    font-family: var(--font-main);
    font-size: 0.98rem;
    transition: var(--transition);
    resize: vertical;
}

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

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--warm);
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 4px rgba(var(--accent-warm-rgb), 0.15);
}

.privacy-check {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    color: rgba(255, 255, 255, 0.78);
    font-size: 0.84rem;
    line-height: 1.5;
}

.privacy-check input {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    accent-color: var(--brand-red);
    flex-shrink: 0;
    cursor: pointer;
}

.privacy-check a {
    color: var(--accent-soft);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.contact-form .btn {
    justify-content: center;
    margin-top: 4px;
}

#formMessage {
    margin-top: 6px;
    font-weight: 600;
    font-size: 0.94rem;
    text-align: center;
    min-height: 1em;
}

/* ---------- Footer ---------- */
.footer {
    background: #04091a;
    color: #cbd3e6;
    padding: 76px 0 32px;
    position: relative;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.7fr 1fr 1fr 1fr;
    gap: 44px;
}

@media (max-width: 940px) {
    .footer-grid {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    }
}

.footer-logo {
    height: 46px;
    width: auto;
    margin-bottom: 22px;
    filter: brightness(0) invert(1);
    opacity: 0.95;
}

.footer-col p {
    color: #8b97b3;
    line-height: 1.7;
    font-size: 0.96rem;
    max-width: 340px;
}

.footer-col h4 {
    font-family: var(--font-display);
    color: #fff;
    margin-bottom: 22px;
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.16em;
}

.footer-col .foot-line {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #8b97b3;
    margin-bottom: 14px;
    font-size: 0.95rem;
}

.footer-col .foot-line i {
    color: var(--warm);
    width: 16px;
}

.footer-col ul li {
    margin-bottom: 12px;
}

.footer-col ul li a {
    color: #8b97b3;
    font-size: 0.95rem;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.footer-col ul li a:hover {
    color: #fff;
    transform: translateX(4px);
}

.footer-socials {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.footer-socials a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.06);
    color: #cbd3e6;
    transition: var(--transition);
}

.footer-socials a:hover {
    background: var(--grad-accent);
    color: #fff;
    transform: translateY(-4px);
}

.footer-bottom {
    margin-top: 56px;
    padding-top: 26px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px;
    color: #6b779a;
    font-size: 0.88rem;
}

.footer-bottom .credit a {
    color: #8b97b3;
    transition: var(--transition);
}

.footer-bottom .credit a:hover {
    color: #fff;
}

/* ---------- Cookie banner (RGPD) ---------- */
.cookie-banner {
    position: fixed;
    bottom: 22px;
    left: 50%;
    transform: translate(-50%, 200%);
    width: min(94%, 860px);
    background: rgba(7, 22, 52, 0.94);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    color: #fff;
    padding: 24px 28px;
    z-index: 2000;
    border-radius: var(--radius);
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: var(--shadow-lg);
    transition: transform 0.6s var(--ease);
}

.cookie-banner.show {
    transform: translate(-50%, 0);
}

.cookie-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 26px;
    flex-wrap: wrap;
}

.cookie-text {
    flex: 1;
    min-width: 260px;
}

.cookie-text h3 {
    font-family: var(--font-display);
    font-size: 1.05rem;
    font-weight: 700;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.cookie-text h3 i {
    color: var(--warm);
}

.cookie-text p {
    margin: 0;
    font-size: 0.86rem;
    color: rgba(255, 255, 255, 0.82);
    line-height: 1.55;
}

.cookie-text a {
    color: var(--warm);
    text-decoration: underline;
}

.cookie-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
}

.cookie-actions .btn {
    padding: 11px 22px;
    font-size: 0.88rem;
}

.cookie-actions .btn-ghost {
    background: rgba(255, 255, 255, 0.06);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.28);
}

.cookie-actions .btn-ghost:hover {
    background: #fff;
    color: var(--navy);
    border-color: #fff;
}

/* Preferences modal */
.cookie-modal {
    position: fixed;
    inset: 0;
    z-index: 2100;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(4, 9, 26, 0.7);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}

.cookie-modal.show {
    display: flex;
}

.cookie-modal-box {
    width: min(100%, 560px);
    max-height: 90vh;
    overflow-y: auto;
    background: var(--surface);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    padding: 32px;
    animation: cookiePop 0.4s var(--ease);
}

@keyframes cookiePop {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.98);
    }
}

.cookie-modal-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}

.cookie-modal-head h3 {
    font-family: var(--font-display);
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--ink);
}

.cookie-modal-close {
    background: none;
    border: none;
    font-size: 1.8rem;
    line-height: 1;
    color: var(--ink-3);
    cursor: pointer;
    transition: var(--transition);
}

.cookie-modal-close:hover {
    color: var(--brand-red);
    transform: rotate(90deg);
}

.cookie-modal-intro {
    font-size: 0.92rem;
    color: var(--ink-3);
    line-height: 1.6;
    margin-bottom: 22px;
}

.cookie-cat {
    padding: 18px 0;
    border-top: 1px solid var(--line);
}

.cookie-cat-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.cookie-cat h4 {
    font-family: var(--font-display);
    font-size: 1.02rem;
    font-weight: 700;
    color: var(--ink);
    margin-bottom: 4px;
}

.cookie-cat p {
    font-size: 0.86rem;
    color: var(--ink-3);
    line-height: 1.5;
    margin: 0;
}

.cookie-badge {
    flex-shrink: 0;
    font-family: var(--font-mono);
    font-size: 0.68rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--brand-red);
    background: rgba(var(--accent-rgb), 0.08);
    padding: 6px 12px;
    border-radius: 100px;
}

/* Toggle switch */
.cookie-switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 27px;
    flex-shrink: 0;
}

.cookie-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.cookie-slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background: #cbd2e0;
    border-radius: 100px;
    transition: 0.3s;
}

.cookie-slider::before {
    content: "";
    position: absolute;
    height: 21px;
    width: 21px;
    left: 3px;
    bottom: 3px;
    background: #fff;
    border-radius: 50%;
    transition: 0.3s;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.cookie-switch input:checked + .cookie-slider {
    background: var(--grad-accent);
}

.cookie-switch input:checked + .cookie-slider::before {
    transform: translateX(21px);
}

.cookie-modal-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 26px;
    padding-top: 22px;
    border-top: 1px solid var(--line);
    flex-wrap: wrap;
}

@media (max-width: 560px) {
    .cookie-actions {
        width: 100%;
    }

    .cookie-actions .btn {
        flex: 1;
    }

    .cookie-modal-actions {
        justify-content: stretch;
    }

    .cookie-modal-actions .btn {
        flex: 1;
    }
}

/* ---------- Back to top ---------- */
.to-top {
    position: fixed;
    bottom: 26px;
    right: 26px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--grad-accent);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    box-shadow: var(--shadow-accent);
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px) scale(0.8);
    transition: var(--transition);
    z-index: 1050;
    border: none;
}

.to-top.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.to-top:hover {
    transform: translateY(-4px) scale(1.06);
}

/* ---------- Scroll reveal ---------- */
.reveal {
    opacity: 0;
    transform: translateY(38px);
    transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
    will-change: opacity, transform;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

.reveal[data-delay="1"] {
    transition-delay: 0.08s;
}

.reveal[data-delay="2"] {
    transition-delay: 0.16s;
}

.reveal[data-delay="3"] {
    transition-delay: 0.24s;
}

.reveal[data-delay="4"] {
    transition-delay: 0.32s;
}

/* ---------- Legal pages ---------- */
.legal-page {
    background: var(--bg);
}

.legal-hero {
    position: relative;
    padding: 170px 0 70px;
    background: radial-gradient(120% 130% at 50% 0%, #0a2350 0%, #071634 55%, #040d22 100%);
    color: #fff;
    overflow: hidden;
    isolation: isolate;
    text-align: center;
}

.legal-title {
    font-family: var(--font-display);
    font-size: clamp(2.2rem, 5vw, 3.4rem);
    font-weight: 800;
    letter-spacing: -0.025em;
    position: relative;
    z-index: 2;
}

.legal-section {
    padding-top: 60px;
}

.legal-card {
    max-width: 840px;
    margin: -90px auto 0;
    position: relative;
    z-index: 5;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    padding: 50px;
}

.legal-content h3 {
    font-family: var(--font-display);
    color: var(--ink);
    margin-top: 32px;
    margin-bottom: 14px;
    font-size: 1.25rem;
    padding-left: 16px;
    border-left: 3px solid var(--brand-red);
}

.legal-content p {
    margin-bottom: 15px;
    line-height: 1.85;
    color: var(--ink-2);
}

@media (max-width: 600px) {
    .legal-card {
        padding: 30px 22px;
    }
}

/* ==========================================================================
   NUEVOS COMPONENTES — arquitectura socio operativo
   ========================================================================== */

/* ---------- Statement / motto band ---------- */
.statement {
    position: relative;
    background: radial-gradient(120% 130% at 50% 0%, #0a2350 0%, #071634 55%, #040d22 100%);
    color: #fff;
    overflow: hidden;
    isolation: isolate;
    text-align: center;
}

.statement .container {
    position: relative;
    z-index: 2;
    max-width: 960px;
}

.statement .lead {
    font-size: clamp(1.05rem, 2vw, 1.25rem);
    color: rgba(255, 255, 255, 0.78);
    line-height: 1.7;
    max-width: 760px;
    margin: 0 auto 40px;
}

.statement-motto {
    font-family: var(--font-display);
    font-size: clamp(1.7rem, 4vw, 2.9rem);
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.02em;
    margin-bottom: 18px;
}

.statement-motto .accent {
    background: var(--grad-text);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.statement-tag {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--accent-soft);
    padding: 10px 22px;
    border: 1px solid rgba(var(--accent-soft-rgb), 0.35);
    border-radius: 100px;
    background: rgba(var(--accent-soft-rgb), 0.06);
}

/* ---------- Profile cards (líneas de negocio) ---------- */
.profile-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 22px;
}

.profile-card {
    position: relative;
    display: flex;
    flex-direction: column;
    padding: 34px 30px;
    border-radius: var(--radius);
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    text-align: left;
    transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease), border-color 0.4s var(--ease);
}

.profile-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(360px circle at var(--mx, 50%) var(--my, 0%), rgba(var(--accent-rgb), 0.08), transparent 60%);
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.profile-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: transparent;
}

.profile-card:hover::after {
    opacity: 1;
}

.profile-num {
    font-family: var(--font-display);
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    color: var(--brand-red);
    margin-bottom: 18px;
}

.profile-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    border-radius: 18px;
    font-size: 1.5rem;
    color: var(--brand-red);
    background: linear-gradient(135deg, rgba(var(--accent-rgb), 0.12), rgba(var(--accent-warm-rgb), 0.12));
    margin-bottom: 22px;
    transition: var(--transition);
}

.profile-card:hover .profile-icon {
    background: var(--grad-accent);
    color: #fff;
    transform: rotate(-6deg) scale(1.05);
    box-shadow: var(--shadow-accent);
}

.profile-card h3 {
    font-family: var(--font-display);
    font-size: 1.32rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    margin-bottom: 10px;
    color: var(--ink);
}

.profile-card p {
    font-size: 0.97rem;
    color: var(--ink-3);
    line-height: 1.6;
    margin-bottom: 22px;
}

.profile-link {
    margin-top: auto;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    font-size: 0.92rem;
    color: var(--brand-red);
    transition: gap 0.3s var(--ease);
}

.profile-card:hover .profile-link {
    gap: 14px;
}

/* ---------- Process / stepper (llave en mano) ---------- */
.process {
    position: relative;
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 18px;
    counter-reset: step;
}

/* connecting timeline line (desktop) */
.process::before {
    content: "";
    position: absolute;
    top: 55px;
    left: 9%;
    right: 9%;
    height: 2px;
    background: repeating-linear-gradient(90deg, rgba(var(--accent-rgb), 0.35) 0 7px, transparent 7px 15px);
    z-index: 0;
}

.step {
    position: relative;
    z-index: 1;
    padding: 30px 24px;
    border-radius: var(--radius);
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.step:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-md);
    border-color: var(--brand-red);
}

.step-num {
    counter-increment: step;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    border-radius: 14px;
    background: var(--grad-accent);
    color: #fff;
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 1.1rem;
    margin-bottom: 18px;
    box-shadow: var(--shadow-accent);
}

.step-num::before {
    content: "0" counter(step);
}

.step h4 {
    font-family: var(--font-display);
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--ink);
    line-height: 1.3;
}

/* ---------- Help items (empresas establecidas) ---------- */
.help-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 22px;
}

.help-item {
    position: relative;
    padding: 32px 30px 30px 34px;
    border-radius: var(--radius);
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.help-item::before {
    content: "";
    position: absolute;
    top: 24px;
    left: 0;
    width: 4px;
    height: 40px;
    border-radius: 0 4px 4px 0;
    background: var(--grad-accent);
    transition: height 0.4s var(--ease);
}

.help-item:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
}

.help-item:hover::before {
    height: calc(100% - 48px);
}

.help-item h4 {
    font-family: var(--font-display);
    font-size: 1.12rem;
    font-weight: 700;
    color: var(--ink);
    margin-bottom: 10px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.help-item h4 i {
    color: var(--brand-red);
    font-size: 1rem;
    margin-top: 4px;
}

.help-item p {
    font-size: 0.96rem;
    color: var(--ink-3);
    line-height: 1.6;
}

/* ---------- Dark feature list (logística) ---------- */
.logistics {
    position: relative;
    background: radial-gradient(120% 140% at 15% 0%, #0a2350 0%, #071634 55%, #040d22 100%);
    color: #fff;
    overflow: hidden;
    isolation: isolate;
}

.logistics .section-title {
    color: #fff;
}

.logistics .section-subtitle {
    color: rgba(255, 255, 255, 0.72);
}

.dark-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 22px;
    position: relative;
    z-index: 2;
}

.dark-card {
    padding: 34px 30px;
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.045);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(8px);
    transition: var(--transition);
}

.dark-card:hover {
    transform: translateY(-6px);
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(var(--accent-soft-rgb), 0.4);
}

.dark-card .dc-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 54px;
    height: 54px;
    border-radius: 15px;
    background: var(--grad-accent);
    font-size: 1.3rem;
    color: #fff;
    margin-bottom: 20px;
    box-shadow: var(--shadow-accent);
}

.dark-card h4 {
    font-family: var(--font-display);
    font-size: 1.12rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 10px;
}

.dark-card p {
    font-size: 0.94rem;
    color: rgba(255, 255, 255, 0.68);
    line-height: 1.6;
}

/* ---------- Sub-service groups (within service card) ---------- */
.subgroup {
    margin-top: 20px;
    padding-top: 18px;
    border-top: 1px dashed var(--line-strong);
}

.subgroup-title {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--brand-red);
    margin-bottom: 12px;
}

/* ---------- Franchise pillars ---------- */
.pillar-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
}

.pillar {
    padding: 36px 32px;
    border-radius: var(--radius);
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.pillar:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: transparent;
}

.pillar .p-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 58px;
    border-radius: 17px;
    font-size: 1.4rem;
    color: #fff;
    background: var(--grad-cool);
    margin-bottom: 20px;
    box-shadow: 0 12px 26px -10px rgba(30, 63, 208, 0.55);
}

.pillar:nth-child(2) .p-icon {
    background: var(--grad-accent);
    box-shadow: var(--shadow-accent);
}

.pillar:nth-child(3) .p-icon {
    background: var(--grad-mix);
    box-shadow: 0 12px 26px -10px rgba(var(--accent-alt-rgb), 0.5);
}

.pillar h3 {
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--ink);
    margin-bottom: 8px;
}

.pillar .p-lead {
    font-size: 0.94rem;
    color: var(--ink-3);
    margin-bottom: 16px;
}

/* ---------- Value checklist ---------- */
.value-wrap {
    display: grid;
    grid-template-columns: 0.85fr 1.15fr;
    gap: 60px;
    align-items: center;
}

.value-checklist {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.value-checklist li {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 18px 24px;
    border-radius: var(--radius-sm);
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
    font-size: 1.02rem;
    font-weight: 600;
    color: var(--ink);
    transition: var(--transition);
}

.value-checklist li:hover {
    transform: translateX(8px);
    border-color: var(--brand-red);
    box-shadow: var(--shadow-md);
}

.value-checklist li i {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    flex-shrink: 0;
    border-radius: 50%;
    background: var(--grad-accent);
    color: #fff;
    font-size: 0.85rem;
    box-shadow: var(--shadow-accent);
}

/* ==========================================================================
   MULTIPÁGINA — hub, páginas de servicio y contacto
   ========================================================================== */

/* ---------- Nav dropdown (Servicios) ---------- */
.nav-item {
    position: relative;
}

.has-dropdown > .nav-link i.caret {
    font-size: 0.7rem;
    margin-left: 4px;
    transition: transform 0.3s var(--ease);
}

.nav-dropdown {
    position: absolute;
    top: calc(100% + 14px);
    left: 50%;
    transform: translateX(-50%) translateY(8px);
    min-width: 280px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(18px) saturate(180%);
    -webkit-backdrop-filter: blur(18px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: 18px;
    box-shadow: var(--shadow-lg);
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 20;
}

/* Puente invisible sobre el hueco: impide que el menú se cierre al bajar el cursor */
.nav-dropdown::before {
    content: "";
    position: absolute;
    top: -18px;
    left: 0;
    right: 0;
    height: 18px;
}

@media (min-width: 769px) {

    .nav-item:hover .nav-dropdown,
    .nav-item:focus-within .nav-dropdown {
        opacity: 1;
        visibility: visible;
        transform: translateX(-50%) translateY(0);
    }

    .nav-item:hover .caret {
        transform: rotate(180deg);
    }
}

.nav-dropdown a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 14px;
    border-radius: 12px;
    font-size: 0.92rem;
    font-weight: 500;
    color: var(--ink-2);
    transition: var(--transition);
}

.nav-dropdown a i {
    color: var(--brand-red);
    width: 18px;
    text-align: center;
    font-size: 0.9rem;
}

.nav-dropdown a:hover {
    background: rgba(var(--accent-rgb), 0.07);
    color: var(--ink);
}

.nav-dropdown .dd-sep {
    height: 1px;
    background: var(--line);
    margin: 6px 8px;
}

.nav-dropdown a.dd-hub {
    font-weight: 700;
    color: var(--brand-red);
}

/* ---------- Page hero (interior pages) ---------- */
.page-hero {
    position: relative;
    padding: 170px 0 90px;
    background: radial-gradient(120% 130% at 50% 0%, #0a2350 0%, #071634 55%, #040d22 100%);
    color: #fff;
    overflow: hidden;
    isolation: isolate;
    text-align: center;
}

.page-hero .container {
    position: relative;
    z-index: 2;
    max-width: 860px;
}

.breadcrumb {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.55);
    margin-bottom: 24px;
}

.breadcrumb a {
    color: rgba(255, 255, 255, 0.7);
    transition: var(--transition);
}

.breadcrumb a:hover {
    color: var(--accent-soft);
}

.breadcrumb .sep {
    color: rgba(255, 255, 255, 0.3);
}

.breadcrumb .current {
    color: var(--accent-soft);
}

.page-hero-title {
    font-family: var(--font-display);
    font-size: clamp(2.2rem, 5vw, 3.6rem);
    font-weight: 800;
    line-height: 1.06;
    letter-spacing: -0.025em;
    margin-bottom: 22px;
}

.page-hero-title .accent {
    background: var(--grad-text);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.page-hero-sub {
    font-size: clamp(1.02rem, 2vw, 1.2rem);
    color: rgba(255, 255, 255, 0.78);
    line-height: 1.65;
    max-width: 640px;
    margin: 0 auto 34px;
}

.page-hero .hero-buttons {
    margin-bottom: 0;
}

/* ---------- Hub service cards (large) ---------- */
.hub-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
}

.hub-card {
    position: relative;
    display: flex;
    gap: 24px;
    padding: 36px;
    border-radius: var(--radius);
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease), border-color 0.4s var(--ease);
}

.hub-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(400px circle at var(--mx, 50%) var(--my, 0%), rgba(var(--accent-rgb), 0.07), transparent 60%);
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.hub-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: transparent;
}

.hub-card:hover::after {
    opacity: 1;
}

.hub-card .hub-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    flex-shrink: 0;
    border-radius: 18px;
    font-size: 1.6rem;
    color: var(--brand-red);
    background: linear-gradient(135deg, rgba(var(--accent-rgb), 0.12), rgba(var(--accent-warm-rgb), 0.12));
    transition: var(--transition);
}

.hub-card:hover .hub-icon {
    background: var(--grad-accent);
    color: #fff;
    box-shadow: var(--shadow-accent);
    transform: rotate(-6deg) scale(1.05);
}

.hub-card .hub-num {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    letter-spacing: 0.14em;
    color: var(--brand-red);
    display: block;
    margin-bottom: 8px;
}

.hub-card h3 {
    font-family: var(--font-display);
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    color: var(--ink);
    margin-bottom: 8px;
}

.hub-card p {
    font-size: 0.96rem;
    color: var(--ink-3);
    line-height: 1.6;
    margin-bottom: 16px;
}

.hub-card .hub-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    font-size: 0.92rem;
    color: var(--brand-red);
    transition: gap 0.3s var(--ease);
}

.hub-card:hover .hub-link {
    gap: 14px;
}

/* ---------- Detail page layout (service subpages) ---------- */
.detail-layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 50px;
    align-items: start;
}

.detail-main > h2 {
    font-family: var(--font-display);
    font-size: 1.7rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--ink);
    margin: 0 0 8px;
}

.detail-main > p.lead-text {
    font-size: 1.1rem;
    color: var(--ink-2);
    line-height: 1.75;
    margin-bottom: 34px;
}

.detail-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 20px;
}

.detail-list li {
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 20px 22px;
    border-radius: var(--radius-sm);
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
    font-size: 0.97rem;
    color: var(--ink);
    line-height: 1.5;
    transition: var(--transition);
}

.detail-list li:hover {
    transform: translateY(-4px);
    border-color: var(--brand-red);
    box-shadow: var(--shadow-md);
}

.detail-list li i {
    color: var(--brand-red);
    margin-top: 3px;
    font-size: 0.9rem;
}

.detail-block {
    margin-bottom: 34px;
}

.detail-block h3 {
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--ink);
    margin-bottom: 16px;
    padding-left: 14px;
    border-left: 3px solid var(--brand-red);
}

/* Sidebar */
.detail-aside {
    position: sticky;
    top: 100px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.aside-card {
    padding: 30px 26px;
    border-radius: var(--radius);
    background: linear-gradient(135deg, #071634, #0a2350);
    color: #fff;
    box-shadow: var(--shadow-lg);
}

.aside-card h4 {
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.aside-card p {
    font-size: 0.92rem;
    color: rgba(255, 255, 255, 0.72);
    line-height: 1.6;
    margin-bottom: 18px;
}

.aside-nav {
    padding: 22px;
    border-radius: var(--radius);
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
}

.aside-nav .an-title {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--ink-3);
    margin-bottom: 14px;
}

.aside-nav a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 10px;
    font-size: 0.9rem;
    color: var(--ink-2);
    transition: var(--transition);
}

.aside-nav a i {
    color: var(--brand-red);
    font-size: 0.8rem;
}

.aside-nav a:hover {
    background: rgba(var(--accent-rgb), 0.06);
    color: var(--ink);
}

.aside-nav a.active {
    background: rgba(var(--accent-rgb), 0.08);
    color: var(--brand-red);
    font-weight: 600;
}

/* ---------- CTA band ---------- */
.cta-band {
    position: relative;
    background: radial-gradient(120% 130% at 80% 0%, #0a2350 0%, #071634 55%, #040d22 100%);
    color: #fff;
    overflow: hidden;
    isolation: isolate;
    text-align: center;
}

.cta-band .container {
    position: relative;
    z-index: 2;
    max-width: 760px;
}

.cta-band h2 {
    font-family: var(--font-display);
    font-size: clamp(1.9rem, 4vw, 2.8rem);
    font-weight: 800;
    letter-spacing: -0.025em;
    margin-bottom: 16px;
}

.cta-band h2 .accent {
    background: var(--grad-text);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.cta-band p {
    font-size: 1.08rem;
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.6;
    margin-bottom: 32px;
}


/* ==========================================================================
   FILOSOFÍA — "Elegir el rumbo" (aguas bravas)
   ========================================================================== */
.rumbo-quote {
    margin-top: 30px;
    padding: 22px 26px;
    border-left: 3px solid var(--brand-red);
    background: var(--surface);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    box-shadow: var(--shadow-sm);
    font-family: var(--font-display);
    font-size: 1.06rem;
    font-weight: 600;
    color: var(--ink);
    line-height: 1.5;
    position: relative;
}

.rumbo-quote i {
    color: var(--brand-red);
    opacity: 0.35;
    margin-right: 10px;
}

/* Comillas de cierre: mismo estilo, separación al lado contrario */
.rumbo-quote i.fa-quote-right {
    margin-right: 0;
    margin-left: 10px;
}

/* Cita centrada (variante de la sección Filosofía) */
.rumbo-quote-center {
    max-width: 560px;
    margin: 30px auto 0;
    text-align: center;
    border-left: none;
    border-top: 3px solid var(--brand-red);
    border-radius: 0 0 var(--radius-sm) var(--radius-sm);
}

/* Marco de la fotografía */
.rumbo-visual {
    position: relative;
}

.rumbo-frame {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.rumbo-frame img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    aspect-ratio: 6 / 7;
    transition: transform 0.9s var(--ease);
}

.rumbo-frame:hover img {
    transform: scale(1.05);
}

.rumbo-frame::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 45%, rgba(7, 22, 52, 0.45) 100%);
    pointer-events: none;
}

.rumbo-badge {
    position: absolute;
    right: -22px;
    bottom: -22px;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 18px 24px;
    border-radius: var(--radius);
    background: var(--grad-accent);
    color: #fff;
    box-shadow: var(--shadow-accent);
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.98rem;
    max-width: 260px;
    line-height: 1.35;
}

.rumbo-badge i {
    font-size: 1.4rem;
    opacity: 0.9;
}

/* Los 4 pilares */
.principles {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin-top: 70px;
    padding-top: 44px;
    border-top: 1px solid var(--line);
}

.principle {
    position: relative;
    text-align: center;
    padding: 0 24px;
}

.principle + .principle::before {
    content: "";
    position: absolute;
    left: 0;
    top: 4px;
    bottom: 4px;
    width: 1px;
    background: var(--line);
}

.principle-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 54px;
    height: 54px;
    border-radius: 16px;
    font-size: 1.35rem;
    color: var(--brand-red);
    background: linear-gradient(135deg, rgba(var(--accent-rgb), 0.12), rgba(var(--accent-warm-rgb), 0.12));
    margin-bottom: 16px;
    transition: var(--transition);
}

.principle:hover .principle-icon {
    background: var(--grad-accent);
    color: #fff;
    transform: translateY(-4px) rotate(-6deg);
    box-shadow: var(--shadow-accent);
}

.principle h4 {
    font-family: var(--font-display);
    font-size: 0.92rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--ink);
    margin-bottom: 9px;
}

.principle p {
    font-size: 0.92rem;
    color: var(--ink-3);
    line-height: 1.55;
}

@media (max-width: 940px) {
    .rumbo-visual {
        max-width: 460px;
        margin: 0 auto;
    }

    .rumbo-badge {
        right: 0;
    }
}

@media (max-width: 860px) {
    .principles {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        row-gap: 38px;
    }

    .principle:nth-child(odd)::before {
        display: none;
    }
}

@media (max-width: 520px) {
    .principles {
        grid-template-columns: 1fr;
    }

    .principle::before {
        display: none !important;
    }
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 1080px) {
    .profile-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 940px) {
    .value-wrap {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .hub-grid {
        grid-template-columns: 1fr;
    }

    .detail-layout {
        grid-template-columns: 1fr;
        gap: 36px;
    }

    .detail-aside {
        position: static;
    }

    .process {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .process::before {
        display: none;
    }

    .about-content {
        grid-template-columns: 1fr;
        gap: 70px;
    }

    .about-visual {
        max-width: 440px;
        margin: 0 auto;
    }

    .contact-wrapper {
        grid-template-columns: 1fr;
        gap: 34px;
    }
}

@media (max-width: 768px) {
    .section {
        padding: 80px 0;
    }

    .nav-list {
        position: fixed;
        flex-direction: column;
        top: 84px;
        right: 16px;
        left: 16px;
        width: auto;
        padding: 16px;
        gap: 6px;
        border-radius: var(--radius);
        background: rgba(255, 255, 255, 0.92);
        backdrop-filter: blur(20px);
        box-shadow: var(--shadow-lg);
        transform: translateY(-14px) scale(0.98);
        opacity: 0;
        visibility: hidden;
        transition: var(--transition);
    }

    /* Menú cerrado: ningún elemento interior puede recibir clics */
    .nav-list {
        pointer-events: none;
    }

    .nav-list.active {
        transform: translateY(0) scale(1);
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }

    .nav-link {
        width: 100%;
        text-align: center;
        padding: 13px;
    }

    .nav-link.btn-primary {
        margin-left: 0;
        margin-top: 4px;
    }

    /* Dropdown becomes inline accordion on mobile */
    .nav-item {
        width: 100%;
    }

    .nav-dropdown {
        position: static;
        transform: none;
        opacity: 1;
        /* 'inherit' evita que el submenú quede clicable con el menú cerrado */
        visibility: inherit;
        min-width: 0;
        width: 100%;
        box-shadow: none;
        border: none;
        background: rgba(var(--accent-rgb), 0.04);
        padding: 6px;
        margin-top: 4px;
    }

    .nav-dropdown a {
        justify-content: center;
    }

    .has-dropdown > .nav-link .caret {
        display: none;
    }

    .detail-list {
        grid-template-columns: 1fr;
    }

    .hamburger {
        display: flex;
    }

    .hamburger.active .bar:nth-child(1) {
        transform: translateY(7.5px) rotate(45deg);
    }

    .hamburger.active .bar:nth-child(2) {
        opacity: 0;
    }

    .hamburger.active .bar:nth-child(3) {
        transform: translateY(-7.5px) rotate(-45deg);
    }

    .hero {
        padding: 140px 0 80px;
    }

    .hero-stat + .hero-stat {
        border-left: none;
        padding-left: 0;
    }

    .hero-stats {
        gap: 24px;
        padding: 24px;
    }

    .section-head {
        margin-bottom: 48px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .exp-badge {
        left: 0;
        bottom: -20px;
    }
}

@media (max-width: 600px) {
    .profile-grid {
        grid-template-columns: 1fr;
    }

    .process {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 18px;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: stretch;
    }

    .hero-buttons .btn {
        justify-content: center;
    }

    .contact-form {
        padding: 26px 20px;
    }
}

/* ==========================================================================
   AJUSTES FINOS PARA MÓVIL
   ========================================================================== */
@media (max-width: 768px) {

    /* Cabeceras de página interiores: menos aire muerto en pantallas pequeñas */
    .page-hero {
        padding: 132px 0 62px;
    }

    .page-hero-sub {
        margin-bottom: 26px;
    }

    /* Migas de pan compactas (las rutas largas ocupaban dos líneas) */
    .breadcrumb {
        font-size: 0.72rem;
        letter-spacing: 0.04em;
        gap: 4px 8px;
        margin-bottom: 16px;
    }

    /* Área táctil cómoda en las migas y en los enlaces del pie */
    .breadcrumb a {
        display: inline-block;
        padding: 6px 2px;
    }

    .footer-col ul li {
        margin-bottom: 2px;
    }

    .footer-col ul li a {
        padding: 10px 0;
    }

    .footer-socials a {
        width: 46px;
        height: 46px;
    }

    /* La tarjeta del hub apila icono y texto */
    .hub-card {
        flex-direction: column;
        gap: 18px;
        padding: 30px 24px;
    }

    /* Menos relleno en tarjetas para ganar ancho de lectura */
    .service-card,
    .profile-card {
        padding: 30px 24px;
    }

    .help-item {
        padding: 28px 22px 26px 26px;
    }

    .pillar,
    .dark-card {
        padding: 30px 24px;
    }

    .step {
        padding: 22px 13px;
    }

    .stat-card {
        padding: 32px 22px;
    }

    .detail-main > h2 {
        font-size: 1.45rem;
    }

    .aside-card,
    .aside-nav {
        padding: 26px 22px;
    }

    .contact-form {
        padding: 30px 22px;
    }

    .info-item {
        padding: 18px;
        gap: 14px;
    }
}

@media (max-width: 480px) {
    .page-hero {
        padding: 120px 0 52px;
    }


    .breadcrumb {
        font-size: 0.7rem;
    }

    .service-card,
    .profile-card,
    .pillar,
    .dark-card,
    .hub-card {
        padding: 26px 20px;
    }

    .detail-list li {
        padding: 16px 18px;
        font-size: 0.94rem;
    }

    .value-checklist li {
        padding: 15px 18px;
        font-size: 0.96rem;
        gap: 13px;
    }

    .rumbo-quote {
        padding: 18px 20px;
        font-size: 1rem;
    }
}

@media (max-width: 600px) {

    /* Palabras largas ("Acompañamiento", "Internacionalización") no deben
       forzar el ancho de columna ni desbordar la tarjeta */
    .step h4,
    .principle h4,
    .service-card h3,
    .profile-card h3,
    .hub-card h3,
    .pillar h3,
    .dark-card h4,
    .help-item h4 {
        overflow-wrap: break-word;
    }

    .step h4 {
        font-size: 0.9rem;
        line-height: 1.35;
    }
}

/* Texto sobre superficies de acento (permite acentos claros, p. ej. dorado) */
.btn-primary,
.nav-link.btn-primary,
.nav-link.btn-primary:hover,
.step-num,
.exp-badge,
.rumbo-badge,
.value-checklist li i,
.to-top,
.stat-card .stat-icon,
.dark-card .dc-icon,
.info-item .ico {
    color: var(--on-accent);
}

/* ==========================================================================
   REJILLAS EQUILIBRADAS: sin tarjetas huérfanas en ningún ancho
   ========================================================================== */

/* --- Rejillas de 5 tarjetas (servicios, logística, FAQ, empresas establecidas):
       la última fila queda centrada --- */
@media (min-width: 1025px) {
.services-grid:has(> :nth-child(5):last-child),
.help-grid:has(> :nth-child(5):last-child) {
        grid-template-columns: repeat(6, minmax(0, 1fr));
    }

.services-grid:has(> :nth-child(5):last-child) > *,
.help-grid:has(> :nth-child(5):last-child) > * {
        grid-column: span 2;
    }

.services-grid:has(> :nth-child(5):last-child) > :nth-child(4),
.help-grid:has(> :nth-child(5):last-child) > :nth-child(4) {
        grid-column: 2 / span 2;
    }
}

@media (min-width: 601px) and (max-width: 1024px) {
.services-grid:has(> :nth-child(5):last-child),
.help-grid:has(> :nth-child(5):last-child) {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

.services-grid:has(> :nth-child(5):last-child) > *,
.help-grid:has(> :nth-child(5):last-child) > * {
        grid-column: span 2;
    }

.services-grid:has(> :nth-child(5):last-child) > :nth-child(5),
.help-grid:has(> :nth-child(5):last-child) > :nth-child(5) {
        grid-column: 2 / span 2;
    }
}

@media (max-width: 600px) {
.services-grid:has(> :nth-child(5):last-child),
.help-grid:has(> :nth-child(5):last-child) {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* --- Equipo (5 personas): 5 en fila / 3+2 / 2+2+1, siempre centrado --- */
@media (min-width: 1100px) {
    .team-grid:has(> :nth-child(5):last-child) {
        grid-template-columns: repeat(5, minmax(0, 1fr));
    }
}

@media (min-width: 601px) and (max-width: 1099px) {
    .team-grid:has(> :nth-child(5):last-child) {
        grid-template-columns: repeat(6, minmax(0, 1fr));
    }

    .team-grid:has(> :nth-child(5):last-child) > * {
        grid-column: span 2;
    }

    .team-grid:has(> :nth-child(5):last-child) > :nth-child(4) {
        grid-column: 2 / span 2;
    }
}

@media (max-width: 600px) {
    .team-grid:has(> :nth-child(5):last-child) {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 14px;
    }

    .team-grid:has(> :nth-child(5):last-child) > * {
        grid-column: span 2;
    }

    .team-grid:has(> :nth-child(5):last-child) > :nth-child(5) {
        grid-column: 2 / span 2;
    }

    .team-card {
        padding: 28px 14px 24px;
    }

    .team-card h3 {
        font-size: 1.02rem;
    }
}

/* --- Estadísticas (4): 4 en fila / 2x2 / 1 columna --- */
.stats-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

@media (max-width: 1023px) {
    .stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 520px) {
    .stats-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* --- Pilares de franquicias (3): 3 en fila / 2+1 centrado / 1 columna --- */
.pillar-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

@media (min-width: 601px) and (max-width: 940px) {
    .pillar-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .pillar-grid > * {
        grid-column: span 2;
    }

    .pillar-grid > :nth-child(3) {
        grid-column: 2 / span 2;
    }
}

@media (max-width: 600px) {
    .pillar-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* --- Proceso de implantación (6 pasos): 6 en fila solo cuando caben los
       títulos; por debajo 3+3 y en móvil 2+2+2 --- */
.process {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.process::before {
    display: none;
}

.step h4 {
    overflow-wrap: break-word;
}

@media (min-width: 1200px) {
    .process {
        grid-template-columns: repeat(6, minmax(0, 1fr));
        gap: 16px;
    }

    .process::before {
        display: block;
    }

    .step {
        padding: 28px 18px;
    }

    .step h4 {
        font-size: 0.92rem;
        line-height: 1.35;
    }
}

@media (max-width: 600px) {
    .process {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* Enlaces de contacto (teléfono / correo) en el pie y en la página de contacto */
.footer-col .foot-line a,
.info-item .info-value a {
    color: inherit;
    transition: color 0.25s var(--ease);
}

.footer-col .foot-line a:hover {
    color: #fff;
}

.info-item .info-value a:hover {
    color: var(--accent-soft);
}

/* Textos con cadenas largas sin espacios (emails, URLs) en pantallas estrechas */
.info-item .info-value,
.footer-col .foot-line,
.legal-content p,
.help-item p {
    overflow-wrap: anywhere;
}

/* ---------- Casos de éxito ---------- */
.logo-wall {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 18px;
}

.logo-tile {
    flex: 0 1 calc((100% - 3 * 18px) / 4);
    display: block;
    aspect-ratio: 2 / 1;
    border-radius: var(--radius);
    background: #fff;
    border: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease);
}

.logo-tile img,
.case-logo img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.logo-tile:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
}

@media (hover: hover) {
    .logo-tile img {
        filter: grayscale(1) contrast(1.05);
        opacity: 0.75;
        transition: filter 0.4s ease, opacity 0.4s ease;
    }

    .logo-tile:hover img {
        filter: none;
        opacity: 1;
    }
}

.section-cta {
    margin-top: 48px;
    text-align: center;
}

.case-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 28px;
}

.case-card {
    position: relative;
    flex: 0 1 calc((100% - 2 * 28px) / 3);
    min-width: 0;
    display: flex;
    flex-direction: column;
    padding: 28px;
    border-radius: var(--radius);
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    scroll-margin-top: 110px;
    transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease);
}

.case-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(400px circle at var(--mx, 50%) var(--my, 0%), rgba(var(--accent-rgb), 0.07), transparent 60%);
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.case-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.case-card:hover::after,
.case-card:target::after {
    opacity: 1;
}

.case-card:target {
    border-color: rgba(var(--accent-rgb), 0.45);
}

.case-logo {
    aspect-ratio: 2 / 1;
    margin-bottom: 22px;
    border-radius: calc(var(--radius) - 6px);
    background: #fff;
    border: 1px solid var(--line);
    overflow: hidden;
}

.case-sector {
    font-family: "JetBrains Mono", monospace;
    font-size: 0.72rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--accent);
}

.case-card h3 {
    margin: 8px 0 10px;
    font-size: 1.25rem;
}

.case-card p {
    color: var(--ink-2);
    line-height: 1.65;
    margin: 0 0 10px;
}

.case-card .case-who {
    color: var(--ink);
    font-weight: 600;
}

.case-tags {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: auto 0 0;
    padding: 12px 0 0;
}

.case-tags li {
    padding: 5px 12px;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--accent-deep);
    background: rgba(var(--accent-rgb), 0.08);
}

@media (max-width: 1024px) {
    .case-card {
        flex-basis: calc((100% - 28px) / 2);
    }
}

@media (max-width: 640px) {
    .case-card {
        flex-basis: 100%;
        padding: 22px;
    }

    .case-logo {
        aspect-ratio: 3 / 1;
    }

    .logo-wall {
        gap: 12px;
    }

    .logo-tile {
        flex-basis: calc((100% - 12px) / 2);
    }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.15s !important;
        scroll-behavior: auto !important;
    }

    .reveal {
        opacity: 1;
        transform: none;
    }

    /* Sin movimiento: se sustituye el vídeo por el fotograma estático */
    .hero-video {
        display: none;
    }

    .hero-photo {
        animation: none;
        transform: none;
    }

    .hero-photo-wrap {
        transform: none !important;
    }
}
