/* ── Cargo Collective custom fonts ── */
@font-face {
    font-family: 'bianzhidai-Base';
    font-weight: normal;
    font-style: normal;
    src: url('../fonts/bianzhidai-Base.woff') format('woff');
}

@font-face {
    font-family: 'Ibarra';
    font-weight: 100 900;
    font-style: normal;
    src: url('../fonts/IbarraRealNova-VariableFont_wght.ttf') format('truetype');
}

@font-face {
    font-family: 'Typefesse';
    font-weight: normal;
    font-style: normal;
    src: url('../fonts/Typefesse_Claire-Obscure.otf') format('opentype');
}

@font-face {
    font-family: 'Typefesse Pleine';
    font-weight: normal;
    font-style: normal;
    src: url('/Despliegue/assets/fonts/Typefesse_Pleine.otf') format('opentype');
}

@font-face {
    font-family: 'Selavy';
    font-weight: normal;
    font-style: normal;
    src: url('/assets/cloned/docenciauniversitaria-contraacademia/fonts/Selavy-4b667eee32.woff2') format('woff2');
}

@font-face {
    font-family: 'Salami';
    font-weight: normal;
    font-style: normal;
    src: url('../fonts/SALAM3__.TTF') format('truetype');
}

:root {
    --studio-bottom-safe-space-config: calc(10px + 15vh);
}

body {
    margin: 0;
    padding: 0;
    background-color: #050505;
    font-family: 'Space Mono', monospace;
    overflow: hidden;
    scrollbar-gutter: stable both-edges;
    color: white;
}

/* --- MEJORAS: Directrices de Interfaz y Tipografía Global --- */
* {
    text-transform: lowercase !important;
    hyphens: none !important;
    -webkit-hyphens: none !important;
    -moz-hyphens: none !important;
    -ms-hyphens: none !important;
    word-break: keep-all !important;
    overflow-wrap: normal !important; /* Para evitar saltos forzados de palabras largas */
}

/* Excepciones para mantener mayúsculas en los grandes títulos/fondos según lo solicitado */
.team-bubbles-label,
.team-bubbles-label-base,
.team-bubbles-label-holo,
.studio-fixed-label,
.studio-fixed-label-base,
.studio-fixed-label-holo {
    text-transform: uppercase !important;
}

html {
    font-size: 14px; /* Reducción general del tamaño de fuente (el predeterminado del navegador es 16px) */
}

html {
    scrollbar-gutter: stable both-edges;
}

body.is-section-scroll {
    overflow-x: hidden;
    overflow-y: auto;
}

body.is-window-scroll-content {
    min-height: 0;
}

.grain-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 90;
    opacity: 0.05;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opactiy='1'/%3E%3C/svg%3E");
}

#webgl-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 1;
    outline: none;
}

.ui-layer {
    position: fixed;
    inset: 0;
    z-index: 1000;
    pointer-events: none;
    width: 100vw;
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.home-page-label {
    position: fixed;
    top: 5vh;
    left: 50%;
    transform: translateX(-50%);
    font-size: 1rem;
    font-family: 'Space Mono', monospace;
    font-style: normal;
    letter-spacing: 0.1em;
    text-transform: lowercase !important;
    color: rgba(255, 255, 255, 0.4);
    text-shadow: none;
    pointer-events: none;
    user-select: none;
    white-space: nowrap;
    z-index: 999;
    transition: opacity 0.5s ease;
}

#gallery-section.is-active .home-page-label {
    opacity: 1;
}

#gallery-section.is-content-scroll .home-page-label,
#gallery-section.is-window-active .home-page-label {
    opacity: 0;
}

body.is-section-scroll #gallery-section .home-page-label {
    opacity: 0;
}

.ui-layer * {
    pointer-events: none;
}

#homeUI.is-inactive {
    opacity: 0;
    transition: opacity 0.4s ease;
}

#homeUI.is-active {
    opacity: 1;
    transition: opacity 0.4s ease;
}

#homeUI.is-inactive .subtitle,
#homeUI.is-inactive .kinetic-char,
#homeUI.is-inactive .scroll-hint {
    pointer-events: none !important;
}

#homeUI.is-active .subtitle,
#homeUI.is-active .kinetic-char {
    pointer-events: auto !important;
}

.subtitle {
    position: fixed;
    left: 50%;
    transform: translateX(-50%);
    top: var(--subtitle-top, 80vh);
    margin-top: 0;
    white-space: nowrap;
    font-size: 3rem;
    letter-spacing: 0;
    color: #ff00de;
    text-transform: lowercase;
    font-family: 'bianzhidai-Base', sans-serif;
    font-style: italic;
    text-shadow: 0 0 10px rgba(255, 0, 222, 0.5);

    display: inline-block;
    transition: opacity 0.5s ease;
    z-index: 200;
    pointer-events: auto !important;
    cursor: default;
    user-select: none;
}

#homeUI > .subtitle {
    left: 50vw;
}

.kinetic-char {
    position: relative;
    display: inline-block;
    transition: color 0.1s;
    pointer-events: auto;
}

.kinetic-char-base {
    display: inline-block;
}

.kinetic-char-fx {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    color: #ff00de;
    text-shadow: 0 0 10px #ff00de, 0 0 20px #ffffff;
    transition: opacity 0.08s linear;
}

.kinetic-char-inverted-punctuation .kinetic-char-base,
.kinetic-char-inverted-punctuation .kinetic-char-fx {
    transform: rotate(180deg);
}

.kinetic-char.is-scrambling .kinetic-char-base,
.kinetic-char.is-hovering .kinetic-char-base {
    visibility: hidden;
}

.kinetic-char.is-scrambling .kinetic-char-fx,
.kinetic-char.is-hovering .kinetic-char-fx {
    opacity: 1;
}

.kinetic-char:hover {
    color: #ff00de;
    text-shadow: 0 0 10px #ff00de, 0 0 20px #ffffff;
}

.scroll-hint {
    position: fixed;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 10px;
    letter-spacing: 2px;
    opacity: 0.5;
    animation: blink 2s infinite;
}

@keyframes blink {
    0%, 100% { opacity: 0.2; }
    50% { opacity: 0.8; }
}
