/* --- BOTONES DE DESCARGA MODERNOS --- */
.dwn-btns-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.2rem;
    margin-top: 1.5rem;
    margin-bottom: 3.5rem;
}
.dwn-btn-modern {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.7em;
    font-family: var(--font-mono);
    font-size: 1.05rem;
    font-weight: 700;
    border: 1.5px solid #7FE5B8;
    color: #3bbf6a;
    background: rgba(127, 229, 184, 0.12);
    border-radius: 1.2em;
    padding: 0.4em 1.1em;
    transition: background 0.18s, color 0.18s, border 0.18s;
    text-decoration: none;
    box-shadow: none;
    margin-bottom: 0.5rem;
}
.dwn-btn-modern:hover {
    background: #7FE5B8;
    color: #0a3d1e;
    border-color: #3bbf6a;
}

.dwn-btn-modern.is-striked-red {
    position: relative;
}

.dwn-btn-modern.is-striked-red::after {
    content: "";
    position: absolute;
    left: 0.45em;
    right: 0.45em;
    top: 50%;
    height: 2px;
    background: #ff3b3b;
    transform: rotate(-7deg);
    pointer-events: none;
}
/* --- BOTONES DE DESCARGA --- */
.dwn-btns-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.2rem;
    margin-top: 1.5rem;
    margin-bottom: 4.5rem;
}
.dwn-btn {
    border-color: #7FE5B8;
    border: 2px solid var(--btn-color);
    color: #3bbf6a;
    background: rgba(127, 229, 184, 0.10);
    font-family: var(--font-mono);
    font-size: 1rem;
    font-weight: 600;
    border-radius: 1.2em;
    padding: 0.6em 1.5em;
    transition: background 0.2s, color 0.2s, border 0.2s;
}
.dwn-btn:hover {
    background: #7FE5B8;
    color: #0a3d1e;
    border-color: #3bbf6a;
}
/* --- TAGS INFORMATIVES --- */
.info-tags-container {
    display: flex;
    justify-content: center;
    gap: 1.2rem;
    margin-top: 2rem;
}

.info-tag {
    position: relative;
    display: inline-block;
    background: rgba(127, 229, 184, 0.12);
    color: #3bbf6a;
    border: 1.5px solid #7FE5B8;
    border-radius: 1.2em;
    padding: 0.4em 1.1em;
    font-size: 1.05rem;
    font-family: var(--font-mono);
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
    margin-bottom: 0.5rem;
}
.info-tag:hover {
    background: #7FE5B8;
    color: #0a3d1e;
}
.info-tag::after {
    content: attr(data-tooltip);
    visibility: hidden;
    opacity: 0;
    width: 260px;
    background: #222;
    color: #7FE5B8;
    text-align: center;
    border-radius: 0.7em;
    padding: 0.7em 1em;
    position: absolute;
    left: 50%;
    bottom: 130%;
    transform: translateX(-50%);
    z-index: 10;
    font-size: 0.98rem;
    font-family: var(--font-mono);
    font-weight: 500;
    box-shadow: 0 4px 18px rgba(127,229,184,0.13);
    transition: opacity 0.25s;
    pointer-events: none;
}
.info-tag:hover::after {
    visibility: visible;
    opacity: 1;
}
/* --- 1. RESET Y VARIABLES (ESTILO SWISS/BRUTALIST) --- */
:root {
    --bg-color: #080808;
    --line-color: #333; /* Color de las líneas de la rejilla */
    --text-main: #ffffff;
    --text-dim: #888888;
    --accent: #ffffff;
    --btn-color: #7FE5B8; /* Verde claro para botones */
    --font-main: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
    --font-heading: 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
    --font-mono: 'Courier New', Courier, monospace;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 5.25rem; /* header (4rem) + aire */
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    font-family: var(--font-main);
    overflow-x: hidden;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
}

/* --- 2. FONDO PARALLAX (CANVAS) --- */
#canvas-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    z-index: -1;
    opacity: 0.4; /* Sutil, detrás del contenido */
    pointer-events: none;
}

/* --- 3. ESTRUCTURA DE REJILLA (GRID BORDERS) --- */
.wrapper {
    width: 100%;
    max-width: 1400px; /* Ancho máximo estilo editorial */
    margin: 0 auto;
    border-left: 1px solid var(--line-color);
    border-right: 1px solid var(--line-color);
    border-top: 3px solid var(--btn-color);
    border-bottom: 2px solid var(--line-color);
    background: transparent;
}

.border-bottom {
    border-bottom: 1px solid var(--line-color);
}

.border-right {
    border-right: 1px solid var(--line-color);
}

/* --- 4. HEADER Y NAV --- */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    position: sticky;
    top: 0;
    background: rgba(8, 8, 8, 0.95);
    z-index: 100;
    border-bottom: 1px solid var(--line-color);
    backdrop-filter: blur(10px);
    height: 4rem;
}

/* Ajuste extra para anclas principales con header sticky */
#manifest,
#dwn,
#install,
#cta ,
#plantar-sensor {scroll-margin-top: 0.75rem;}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.lang-selector {
    margin-left: 1.25rem;
    display: flex;
    align-items: center;
}

.lang-dropdown {
    position: relative;
}

.lang-trigger {
    --lang-accent: var(--btn-color);
    background: rgba(127, 229, 184, 0.10);
    color: var(--text-main);
    border: 1.5px solid rgba(127, 229, 184, 0.55);
    border-left: 4px solid var(--lang-accent);
    border-radius: 0.75rem;
    padding: 0.45rem 2.2rem 0.45rem 0.75rem;
    font-family: var(--font-mono);
    font-weight: 800;
    font-size: 0.9rem;
    letter-spacing: 0.06em;
    cursor: pointer;
    outline: none;
    transition: background 0.18s, border-color 0.18s, box-shadow 0.18s;
    position: relative;
}

.lang-trigger::after {
    content: "";
    position: absolute;
    right: 0.75rem;
    top: 50%;
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 6px solid var(--text-main);
    transform: translateY(-35%);
    opacity: 0.9;
}

.lang-trigger:hover {
    background: rgba(127, 229, 184, 0.16);
    border-color: rgba(127, 229, 184, 0.75);
}

.lang-trigger:focus-visible {
    box-shadow: 0 0 0 3px rgba(127, 229, 184, 0.22);
    border-color: var(--btn-color);
}

.lang-menu {
    position: absolute;
    right: 0;
    top: calc(100% + 0.5rem);
    min-width: 12.5rem;
    padding: 0.35rem;
    border-radius: 0.9rem;
    border: 1px solid rgba(127, 229, 184, 0.35);
    background: rgba(8, 8, 8, 0.96);
    backdrop-filter: blur(10px);
    box-shadow: 0 10px 35px rgba(0, 0, 0, 0.45);
    display: none;
    z-index: 200;
}

.lang-dropdown.is-open .lang-menu {
    display: block;
}

.lang-option {
    width: 100%;
    text-align: left;
    background: transparent;
    border: 0;
    border-radius: 0.65rem;
    padding: 0.6rem 0.7rem;
    color: #ccc;
    font-family: var(--font-mono);
    font-weight: 700;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
}

.lang-option:hover,
.lang-option:focus-visible {
    background: rgba(127, 229, 184, 0.14);
    color: var(--text-main);
    outline: none;
}

.lang-option.is-selected {
    background: rgba(127, 229, 184, 0.18);
    color: var(--text-main);
}

.lang-trigger[data-lang="ca"] { --lang-accent: #F4D03F; }
.lang-trigger[data-lang="es"] { --lang-accent: #f43f3f; }
.lang-trigger[data-lang="en"] { --lang-accent: #7f8cff; }

.logo {
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 1rem;
    letter-spacing: -0.01em;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-transform: none;
}

nav {
    display: flex;
    gap: 2.5rem;
    align-items: center;
}

nav a {
    color: var(--text-main);
    text-decoration: none;
    font-family: var(--font-heading);
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.01em;
    transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    padding: 0.35rem 0.7rem;
    border-radius: 999px;
    overflow: hidden;
    z-index: 0;
}

nav a:hover {
    opacity: 0.7;
}

nav a::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(180deg, rgba(127, 229, 184, 0.24) 0%, rgba(127, 229, 184, 0.08) 100%);
    opacity: 0;
    transform: translateY(-2px);
    transition: opacity 0.22s ease, transform 0.22s ease;
    z-index: -1;
}

nav a.nav-link-active {
    opacity: 1;
    color: #ffffff;
}

nav a.nav-link-active::before {
    opacity: 1;
    transform: translateY(0);
}

/* --- 5. COMPONENTE MARQUEE (TEXTO QUE CORRE) --- */
.marquee-container {
    overflow: hidden;
    white-space: nowrap;
    padding: 1rem 0;
    background: transparent;
    border-bottom: 1px solid var(--line-color);
}

.marquee-content {
    display: inline-block;
    animation: marquee 20s linear infinite;
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: var(--accent);
}

@keyframes marquee {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* --- 6. TIPOGRAFÍA HERO --- */
.hero-section {
    padding: 2rem 2rem;
    position: relative;    text-align: center;}

h1 {
    font-size: clamp(3.5rem, 10vw, 7rem);
    line-height: 0.9;
    font-weight: 800; /* Más bold y fuerte */
    letter-spacing: -0.04em;
    margin-bottom: 1.5rem;
    text-align: center;
}

h1 .text-accent {
    color: var(--btn-color);
}

.hero-meta {
    font-family: var(--font-mono);
    color: var(--text-dim);
    margin-bottom: 1rem;
    display: block;
    text-align: center;
}

/* --- 7. LAYOUT DE COLUMNAS (GRID) --- */
.grid-row {
    display: grid;
    border-color: #88888850;
    border-radius: 2rem;
    grid-template-columns: 1fr 1fr; /* 50% - 50% */
}

.sticky-col {
    position: sticky;
    top: 81px; /* Altura del header approx */
    height: fit-content;
    padding: 2rem 2rem;
}

.scroll-col {
    padding: 2rem 2rem;
    border-left: 2px solid var(--btn-color);
}

h2 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    font-weight: 500;
}

p {
    font-size: 1.1rem;
    line-height: 1.5;
    margin-bottom: 2rem;
    max-width: 90%;
    color: #ccc;
}

/* --- 7.5 LISTAS Y SUBLISTAS --- */
ul {
    list-style: none;
    margin-left: 2rem;
    margin-bottom: 1.5rem;
}

ul > li {
    margin-bottom: 0.1rem;
    color: #ccc;
    line-height: 1.4;
}

/* Viñetas en sub-listas anidadas */
ul ul {
    list-style: disc;
    margin-left: 1rem;
}

ul ul li {
    margin-bottom: 0.3rem;
    margin-left: 1rem;
    color: #ccc;
    line-height: 1.4;
}

ul ul {
    list-style: circle;
    margin-top: 0.1rem;
    margin-left: 2rem;
}

ul ul li {
    margin-bottom: 0.05rem;
}

/* --- 8. BOTONES E INTERACCIONES --- */
.btn-container {
    margin-top: 2rem;
    text-align: center;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    border: 2px solid var(--btn-color);
    color: var(--btn-color);
    text-decoration: none;
    font-family: 'IBM Plex Mono', 'Courier New', monospace;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    background: transparent;
    border-radius: 0.5rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

/* Efecto Hover: Fondo verde más vivo con transición suave */
.btn:hover {
    background: rgba(127, 229, 184, 0.25);
    border-color: var(--btn-color);
    color: var(--btn-color);
}

/* --- 9. BLOQUE INFO STYLE INTELLIGENT ECONOMICS --- */
.info-block {
    margin: 4rem auto;
    padding: 0 3rem;
    max-width: 100%;
    width: 100%;
}

.info-block-content {
    border: 2px solid var(--btn-color);
    border-radius: 1.5rem;
    padding: 3rem;
    background: transparent;
}

.info-block-header {
    margin-bottom: 2rem;
}

.info-block-header h2 {
    font-size: 2.5rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin: 0;
}

.info-block-body {
    display: grid;
    grid-template-columns: 4fr 1.1fr;
    gap: 0rem;
    align-items: center;
}

.info-block-text {
    flex: 1;
}

.info-block-image {
    flex-shrink: 0;
}

.info-block-video {
    height: 100%;
    width: 110%;
    max-width: 110%;
    justify-self: end;
    align-self: stretch;
    flex-shrink: 0;
    border: 3px solid rgba(127, 229, 184, 0.35);
    border-radius: 1.2rem;
    padding: 0rem;
    background: rgba(7, 16, 23, 0.75);
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.25);
}
.info-block-subtitle {
    font-size: 1.25rem;
    color: var(--btn-color);
    font-weight: 600;
    margin-bottom: 1.5rem;
    line-height: 1.5;
    text-align: center;
}

.info-block-description {
    font-size: 1rem;
    line-height: 1.7;
    color: #ccc;
    margin: 0;
    text-align: justify;
}

/* --- 9.5 INSTALACIÓN (PASOS + VÍDEOS) --- */
.install-body {
    display: grid;
    grid-template-columns: 1fr 0.72fr;
    gap: 2rem;
    align-items: stretch;
    margin-top: 1.25rem;
}

#install-title,
#maleta-title {
    display: block;
    width: fit-content;
    margin: 0 auto 1.6rem;
    text-align: center;
}

.install-steps {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.install-steps h2 {
    margin-bottom: 1rem;
}

.install-steps-list {
    margin-left: 1.25rem;
    margin-bottom: 0.6rem;
    list-style: none;
}

.install-steps-list li {
    margin-bottom: 0.42rem;
    color: #ccc;
    line-height: 1.35;
}

.install-steps-list.maleta-bullets {
    list-style: disc;
    margin-left: 1.4rem;
}

.install-steps-list.maleta-bullets li {
    padding-left: 0;
}

.install-steps-list.maleta-bullets li::marker {
    color: var(--btn-color);
}

.install-note {
    margin: 0.25rem 0 0;
    color: rgba(255, 255, 255, 0.78);
    font-size: 0.94rem;
    line-height: 1.35;
    max-width: 100%;
}

#maleta-note {
    font-style: italic;
}

.video-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.maleta-single-media {
    display: block;
}

.maleta-single-media .video-card {
    height: 100%;
}

.maleta-single-media .video-embed {
    aspect-ratio: 16 / 9;
}

.video-card {
    min-width: 0;
    border: 1px solid rgba(127, 229, 184, 0.35);
    border-radius: 1rem;
    padding: 0.6rem;
    background: rgba(7, 16, 23, 0.75);
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.25);
}

.video-embed {
    position: relative;
    aspect-ratio: 16 / 9;
    border-radius: 1.1rem;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.04);
}

.video-embed iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.video-link {
    position: absolute;
    inset: 0;
    display: block;
}

.video-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.video-play {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 2.3rem;
    height: 2.3rem;
    border-radius: 999px;
    display: grid;
    place-items: center;
    background: rgba(0, 0, 0, 0.72);
    color: #ffffff;
    font-size: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.25);
    transition: transform 0.15s ease, background 0.15s ease;
}

.video-link:hover .video-play {
    transform: translate(-50%, -50%) scale(1.05);
    background: rgba(0, 0, 0, 0.82);
}

.video-caption {
    margin-top: 0.55rem;
    font-family: var(--font-main);
    font-size: 0.92rem;
    color: rgba(255, 255, 255, 0.78);
}

.dwn-section {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 1.5rem 2rem;
}

/* --- 10. CTA SECTION --- */
.cta-section {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 1.5rem 2rem;
}

.cta-button {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border-radius: 2rem;
    background: transparent;
    text-decoration: none;
    font-weight: 700;
    font-size: 2.5rem;
    letter-spacing: 0.05em;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    background: linear-gradient(180deg, var(--btn-color) 0%, #ffffff 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    box-shadow: 0 10px 30px rgba(127, 229, 184, 0.3);
}

.cta-button:hover {
    opacity: 0.8;
    transform: translateY(-2px);
    box-shadow: 0 15px 40px rgba(127, 229, 184, 0.4);
}

/* --- 11. FOOTER BIG --- */
.footer-big {
    margin-top: 3rem;
    padding: 0rem 1rem;
    text-align: left;
}

.institutional-footer {
    padding: 0.75rem 1rem 2rem;
    /*background: linear-gradient(to top, rgba(127, 229, 184, 0.3), #000000 120%);*/
}

.footer-title {
    font-size: clamp(2rem, 5vw, 4rem);
    line-height: 1;
    margin-bottom: 2rem;
}

.institutional-logos {
    margin: 2.5rem 13rem;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0rem;
}

.institutional-logo-cell {
    width: 100%;
    min-width: 0;
    display: flex;
    justify-content: center;
    align-items: center;
}

.institutional-logo-pair {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 2.4rem;
    flex-wrap: wrap;
}

.institutional-logo-cell img {
    width: auto;
    height: auto;
    max-height: 80px;
    max-width: 100%;
    object-fit: contain;
    filter: brightness(0.98);
}

.institutional-logo-cell-top { height: 140;}
.institutional-logo-cell-bottom { grid-column: 1 / -1; min-height: 120px; }
.institutional-logo-cell-top img { height: 120px;}
.institutional-logo-cell-bottom img {height: 120px;}
.logo-diba { height: 92px !important; }



/* MOBILE FIXES */
@media (max-width: 768px) {
    .grid-row { grid-template-columns: 1fr; }
    .scroll-col { border-left: none; border-top: 1px solid var(--line-color); }
    .sticky-col { position: relative; top: 0; padding: 2rem; }
    header { padding: 1rem; }
    nav { display: none; } /* Simplificado para el ejemplo */
    .info-block-content {
        box-sizing: border-box;
        word-break: break-word;
        overflow-wrap: break-word;
        padding: 1.2rem 0.5rem;
        border-radius: 1rem;
        max-width: 100vw;
    }
    .info-block-description {
        font-size: 0.95rem;
        padding: 0.2rem;
        margin: 0;
        word-break: break-word;
        overflow-wrap: break-word;
        text-align: left;
    }
    .info-block-image img {
        max-width: 95vw;
        min-width: 0;
        width: 100%;
        height: auto;
        border-radius: 0.8rem;
        display: block;
        margin: 0 auto;
        box-sizing: border-box;
    }
    .info-block-image {
        max-width: 95vw;
        margin: 0 auto;
    }
    
    .info-block {
        margin: 2rem 1rem;
    }
    
    .info-block-content {
        padding: 2rem 1.5rem;
    }
    
    .info-block-header h2 {
        font-size: 1.75rem;
    }
    
    .info-block-subtitle {
        font-size: 1rem;
    }
    
    .info-block-body {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .info-block-video {
        width: 100%;
        max-width: 100%;
    }
    
    .info-block-image {
        max-width: 300px;
        margin: 0 auto;
    }

    .install-body {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    #install-title {
        margin-bottom: 1rem;
    }

    .video-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.75rem;
    }

    .institutional-logos {
        margin: 2rem 0 0;
        gap: 0.85rem;
        grid-template-columns: 1fr;
        grid-template-rows: repeat(3, auto);
    }

    .institutional-logo-cell,
    .institutional-logo-cell-bottom {
        grid-column: auto;
        min-height: 110px;
        padding: 0.9rem 1rem;
    }

    .institutional-logo-cell-top img {
        max-height: 90px;
        max-width: 90%;
    }

    .institutional-logo-cell-bottom img {
        max-height: 80px;
        max-width: 90%;
    }

    .institutional-logo-pair {
        gap: 1.4rem;
    }

    .logo-diba {
        height: 74px !important;
    }
}
