@import url('https://fonts.googleapis.com/css2?family=Rajdhani:wght@300;500;700&family=Exo+2:wght@200;400;700;900&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    overflow: hidden;
    background: #000;
    font-family: 'Exo 2', sans-serif;
}

#scene-container {
    width: 100vw;
    height: 100vh;
    position: relative;
    transition: none;
}

/* Efecto TV ULTRA REALISTA */
#scene-container.off {
    animation: tvShutdown 0.8s cubic-bezier(0.36, 0, 0.66, -0.56) forwards;
}

@keyframes tvShutdown {
    0% {
        transform: scale(1, 1);
        filter: brightness(1) contrast(1) saturate(1);
        opacity: 1;
    }

    10% {
        filter: brightness(1.8) contrast(1.3) saturate(1.2);
    }

    25% {
        transform: scale(1, 1);
        filter: brightness(2.5) contrast(2) saturate(0.5);
    }

    35% {
        transform: scale(1, 0.03);
        filter: brightness(3) contrast(3) saturate(0);
    }

    50% {
        transform: scale(0.8, 0.015);
        filter: brightness(2) contrast(2) saturate(0);
        opacity: 0.8;
    }

    60% {
        transform: scale(0.3, 0.004);
        filter: brightness(1) contrast(1) saturate(0);
        opacity: 0.4;
    }

    75% {
        transform: scale(0.1, 0.001);
        filter: brightness(0.5) contrast(0.5) saturate(0);
        opacity: 0.15;
    }

    85% {
        transform: scale(0.05, 0.0005);
        filter: brightness(0.2) contrast(0) saturate(0);
        opacity: 0.05;
    }

    100% {
        transform: scale(0, 0);
        filter: brightness(0) contrast(0) saturate(0);
        opacity: 0;
    }
}

/* Flash blanco al apagar */
.tv-flash {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: white;
    pointer-events: none;
    z-index: 9999;
    opacity: 0;
}

.tv-flash.active {
    animation: flashEffect 0.8s ease-out forwards;
}

@keyframes flashEffect {
    0% {
        opacity: 0;
    }

    8% {
        opacity: 0.7;
    }

    15% {
        opacity: 0;
    }

    100% {
        opacity: 0;
    }
}

/* Líneas de escaneo TV */
.scanlines {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(0deg,
            rgba(0, 0, 0, 0.05) 0px,
            rgba(0, 0, 0, 0.05) 1px,
            transparent 1px,
            transparent 2px);
    pointer-events: none;
    z-index: 80;
    opacity: 0.3;
}

.content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 100;
    text-align: center;
    pointer-events: auto;
}

.logo-wrapper {
    position: relative;
    margin-bottom: 50px;
    perspective: 1000px;
}

.logo-container {
    position: relative;
    animation: logoFloat 6s ease-in-out infinite;
    transform-style: preserve-3d;
}

.logo-container img {
    width: 200px;
    height: 200px;
    animation: logoSpin 20s linear infinite, logoPulse 3s ease-in-out infinite;
    filter: drop-shadow(0 0 30px rgba(0, 200, 255, 0.8)) drop-shadow(0 0 60px rgba(0, 200, 255, 0.5));
}

@keyframes logoFloat {

    0%,
    100% {
        transform: translateY(0px) rotateX(0deg);
    }

    25% {
        transform: translateY(-20px) rotateX(-10deg);
    }

    50% {
        transform: translateY(0px) rotateX(0deg);
    }

    75% {
        transform: translateY(-15px) rotateX(10deg);
    }
}

@keyframes logoSpin {
    from {
        transform: rotateZ(0deg);
    }

    to {
        transform: rotateZ(360deg);
    }
}

@keyframes logoPulse {

    0%,
    100% {
        transform: scale(1);
        filter: drop-shadow(0 0 30px rgba(0, 200, 255, 0.8));
    }

    50% {
        transform: scale(1.1);
        filter: drop-shadow(0 0 50px rgba(0, 255, 200, 1));
    }
}

.orbit-ring {
    position: absolute;
    top: 50%;
    left: 50%;
    border: 2px solid rgba(0, 200, 255, 0.3);
    border-radius: 50%;
    transform: translate(-50%, -50%);
}

.orbit-ring:nth-child(1) {
    width: 240px;
    height: 240px;
    animation: orbitRotate 8s linear infinite;
}

.orbit-ring:nth-child(2) {
    width: 280px;
    height: 280px;
    animation: orbitRotate 12s linear infinite reverse;
    border-color: rgba(0, 255, 200, 0.3);
}

.orbit-ring:nth-child(3) {
    width: 320px;
    height: 320px;
    animation: orbitRotate 16s linear infinite;
    border-color: rgba(100, 200, 255, 0.3);
}

@keyframes orbitRotate {
    from {
        transform: translate(-50%, -50%) rotate(0deg);
    }

    to {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

.title {
    color: #00d4ff;
    font-size: 3rem;
    margin-bottom: 10px;
    text-shadow: 0 0 20px rgba(0, 212, 255, 0.8);
    animation: glowPulse 2s ease-in-out infinite;
}

@keyframes glowPulse {

    0%,
    100% {
        text-shadow: 0 0 10px rgba(0, 212, 255, 0.5);
    }

    50% {
        text-shadow: 0 0 30px rgba(0, 212, 255, 1);
    }
}

.subtitle {
    color: #00ffaa;
    font-size: 1.5rem;
    margin-bottom: 30px;
    text-shadow: 0 0 15px rgba(0, 255, 170, 0.6);
}

.cta-button {
    padding: 15px 40px;
    background: linear-gradient(135deg, #00d4ff, #00ffaa);
    border: none;
    border-radius: 50px;
    color: #000;
    font-size: 1.2rem;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 0 30px rgba(0, 212, 255, 0.6);
    transition: all 0.3s ease;
}

.cta-button:hover {
    transform: scale(1.05);
    box-shadow: 0 0 50px rgba(0, 255, 170, 0.8);
}
/* Robot 3D con Spline */
#custom-robot {
    width: 400px;
    height: 500px;
    position: relative;
    opacity: 0;
    transform: scale(0.2) rotate(-720deg);
    transition: all 1.2s cubic-bezier(.68, -0.55, .27, 1.55);
}
#robot-spline-placeholder {
    width: 100%;
    height: 100%;
    border-radius: 20px;
    overflow: hidden;
    background: rgba(0, 20, 40, 0.3);
}

spline-viewer {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
}

/* Recuadro de diálogo */
.dialog-box {
    position: absolute;
    bottom: -100px;
    left: 50%;
    transform: translateX(-50%);
    width: 400px;
    min-height: 80px;
    background: linear-gradient(135deg, rgba(44, 46, 94, 0.95) 0%, rgba(26, 28, 62, 0.95) 100%);
    border: 3px solid #00d4ff;
    border-radius: 20px;
    padding: 20px 25px;
    box-shadow: 0 10px 40px rgba(0, 212, 255, 0.5);
    animation: dialogAppear 0.5s ease-out;
}

@keyframes dialogAppear {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

.dialog-box::before {
    content: '';
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 15px solid transparent;
    border-right: 15px solid transparent;
    border-bottom: 20px solid #00d4ff;
}

.dialog-text {
    color: #00d4ff;
    font-size: 1.3rem;
    font-family: 'Exo 2', sans-serif;
    font-weight: 400;
    text-align: center;
    line-height: 1.6;
    animation: textGlow 2s ease-in-out infinite;
}

@keyframes textGlow {

    0%,
    100% {
        text-shadow: 0 0 10px rgba(0, 212, 255, 0.5);
    }

    50% {
        text-shadow: 0 0 20px rgba(0, 255, 170, 0.8);
    }
}

/* Indicador de escritura */
.typing-indicator {
    display: inline-block;
    animation: blink 1s ease-in-out infinite;
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

/* Estilos de la puerta de alda.html */
.container {
    width: 100vw;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.door-container {
    position: relative;
    width: 100vw;
    height: 100vh;
    display: flex;
    flex-direction: column;
}

.door-section {
    position: relative;
    width: 100%;
    height: 50vh;
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.15) 0%, transparent 30%),
        linear-gradient(180deg, #1e3a5f 0%, #2d5a8c 30%, #3a6a9f 50%, #2d5a8c 70%, #1e3a5f 100%);
    transition: transform 2s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    overflow: hidden;
    box-shadow:
        inset 20px 0 40px rgba(0, 0, 0, 0.3),
        inset -20px 0 40px rgba(0, 0, 0, 0.3),
        inset 0 20px 60px rgba(255, 255, 255, 0.1);
}

.door-top {
    border-bottom: 3px solid #0a1929;
}

.door-bottom {
    border-top: 3px solid #0a1929;
}

/* Textura metálica */
.door-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        repeating-linear-gradient(90deg,
            transparent 0px,
            rgba(255, 255, 255, 0.03) 1px,
            transparent 2px,
            rgba(255, 255, 255, 0.01) 3px,
            transparent 4px),
        repeating-linear-gradient(0deg,
            transparent 0px,
            rgba(0, 0, 0, 0.04) 1px,
            transparent 2px,
            rgba(0, 0, 0, 0.02) 3px,
            transparent 4px),
        radial-gradient(ellipse at 20% 30%, rgba(255, 255, 255, 0.15), transparent 40%),
        radial-gradient(ellipse at 80% 70%, rgba(255, 255, 255, 0.1), transparent 40%);
    pointer-events: none;
}

.door-section::after {
    content: '';
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg,
            rgba(0, 0, 0, 0.3) 0%,
            transparent 5%,
            transparent 95%,
            rgba(0, 0, 0, 0.3) 100%);
    pointer-events: none;
}

/* Panel metálico con relieve */
.metal-panel {
    position: absolute;
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        linear-gradient(225deg, rgba(0, 0, 0, 0.2) 0%, transparent 50%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow:
        inset 2px 2px 10px rgba(255, 255, 255, 0.1),
        inset -2px -2px 10px rgba(0, 0, 0, 0.3);
}

.panel-1 {
    top: 15%;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    height: 35%;
}

.panel-2 {
    top: 55%;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    height: 30%;
}

/* Diseño geométrico lateral */
.side-design {
    position: absolute;
    top: 50%;
    width: 250px;
    height: 400px;
    transform: translateY(-50%);
    pointer-events: none;
}

.side-design.left {
    left: 8vw;
}

.side-design.right {
    right: 8vw;
}

.arrow-shape {
    position: absolute;
    width: 0;
    height: 0;
    border-top: 100px solid transparent;
    border-bottom: 100px solid transparent;
}

.arrow-shape.left {
    border-right: 130px solid #0d2642;
    left: 0;
}

.arrow-shape.right {
    border-left: 130px solid #0d2642;
    right: 0;
}

.arrow-shape.left.second {
    left: 80px;
    opacity: 0.7;
}

.arrow-shape.right.second {
    right: 80px;
    opacity: 0.7;
}

/* Tornillos decorativos */
.bolts-column {
    position: absolute;
    display: flex;
    flex-direction: column;
    gap: 8vh;
    top: 50%;
    transform: translateY(-50%);
}

.bolts-column.left {
    left: 3vw;
}

.bolts-column.right {
    right: 3vw;
}

.bolt {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 35%, #5a8ab7, #2d4f6f, #1a2f45);
    border: 2px solid #0d1f2f;
    box-shadow:
        inset 0 2px 5px rgba(0, 0, 0, 0.6),
        inset 0 -1px 3px rgba(255, 255, 255, 0.2),
        0 2px 4px rgba(0, 0, 0, 0.5);
    position: relative;
}

.bolt::before {
    content: '';
    position: absolute;
    width: 6px;
    height: 1px;
    background: rgba(0, 0, 0, 0.6);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(45deg);
    box-shadow: 0 0 2px rgba(0, 0, 0, 0.8);
}

.bolt::after {
    content: '';
    position: absolute;
    width: 6px;
    height: 1px;
    background: rgba(0, 0, 0, 0.6);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-45deg);
    box-shadow: 0 0 2px rgba(0, 0, 0, 0.8);
}

.center-container {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    align-items: center;
    gap: 20px;
    transition: opacity 0.5s ease;
}

.hide-center {
    opacity: 0;
}

.horizontal-line {
    position: relative;
    width: 150px;
    height: 3px;
    background: linear-gradient(90deg, transparent, #0a1929, transparent);
}

.line-left {
    justify-content: flex-end;
}

.line-right {
    justify-content: flex-start;
}

.line-segment {
    position: absolute;
    height: 3px;
    background: #64c8ff;
    box-shadow: 0 0 10px #00d4ff;
    transition: opacity 0.3s ease;
}

.line-segment.segment-1 {
    width: 50px;
    left: 0;
}

.line-segment.segment-2 {
    width: 70px;
    left: 60px;
}

.line-segment.segment-3 {
    width: 40px;
    left: 140px;
}

.line-right .line-segment {
    left: auto;
    right: 0;
}

.line-right .line-segment.segment-1 {
    width: 50px;
    right: 0;
}

.line-right .line-segment.segment-2 {
    width: 70px;
    right: 60px;
}

.line-right .line-segment.segment-3 {
    width: 40px;
    right: 140px;
}

.hide-lines {
    opacity: 0;
}

.door-container.spinning .door-section {
    transform: rotate(360deg);
}

.door-container.opening .door-top {
    transform: translateY(-100vh);
}

.door-container.opening .door-bottom {
    transform: translateY(100vh);
}

.door-container.electric-active .horizontal-line .line-segment {
    animation: electricGlow 0.5s alternate infinite;
}

@keyframes electricGlow {
    0% {
        box-shadow: 0 0 10px #00d4ff;
    }

    100% {
        box-shadow: 0 0 20px #00ffaa;
    }
}

.welcome-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #00d4ff;
    text-align: center;
    opacity: 0;
    transition: opacity 1s ease;
}

.door-container.opening .welcome-content {
    opacity: 1;
}

#electricCanvas {
    position: absolute;
    top: 0;
    left: 0;
    pointer-events: none;
}
#scene-container canvas {
    pointer-events: none !important;
    z-index: 1;
}
#door-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: linear-gradient(135deg, #0a1929 0%, #1a2332 100%);
    z-index: 10001;
    justify-content: center;
    align-items: center;
    pointer-events: auto !important;
}

#electricCanvas {
    position: absolute;
    top: 0;
    left: 0;
    pointer-events: none !important;
    z-index: 10002;
}

.door-container {
    pointer-events: auto !important;
    z-index: 10003;
}

.form-wrapper {
    pointer-events: auto !important;
}

.employee-card {
    pointer-events: auto !important;
}

.card-field input,
.card-button,
.card-link {
    pointer-events: auto !important;
}

.employee-card {
    width: 300px;
    height: 450px;
    background: linear-gradient(135deg, #1e3a5f 0%, #2d5a8c 50%, #3a6a9f 100%);
    border-radius: 20px;
    padding: 20px;
    box-shadow:
        inset 0 0 20px rgba(255, 255, 255, 0.1),
        0 10px 40px rgba(0, 0, 0, 0.6),
        0 0 30px rgba(74, 123, 167, 0.3);
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    color: #64c8ff;
    font-family: 'Arial', sans-serif;
    transition: all 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.employee-card.hide-card {
    transform: translateY(-100vh) scale(0.1);
    opacity: 0;
}

.employee-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        repeating-linear-gradient(90deg,
            transparent 0px,
            rgba(255, 255, 255, 0.03) 1px,
            transparent 2px);
    pointer-events: none;
}

.card-photo {
    width: 100px;
    height: 120px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid #64c8ff;
    border-radius: 10px;
    margin: 0 auto 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    font-size: 14px;
    color: #a0d4ff;
}

.card-barcode {
    height: 40px;
    background: repeating-linear-gradient(90deg, #000 0px, #000 2px, #fff 2px, #fff 4px);
    border-radius: 5px;
    opacity: 0.8;
    margin-top: 20px;
}

.card-header {
    text-align: center;
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-shadow: 0 0 10px rgba(100, 200, 255, 0.5);
}

.card-field {
    margin-bottom: 15px;
}

.card-field label {
    display: block;
    font-size: 14px;
    margin-bottom: 5px;
    color: #a0d4ff;
}

.card-field input {
    width: 100%;
    padding: 10px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid #64c8ff;
    border-radius: 5px;
    color: #fff;
    font-size: 16px;
    box-shadow: inset 0 0 10px rgba(100, 200, 255, 0.2);
}

.card-field input:focus {
    outline: none;
    border-color: #00ffaa;
    box-shadow: 0 0 15px rgba(0, 255, 170, 0.5);
}

.card-actions {
    display: flex;
    justify-content: space-between;
    margin-top: 10px;
}

.card-button {
    padding: 10px 20px;
    background: linear-gradient(135deg, #00d4ff, #00ffaa);
    border: none;
    border-radius: 5px;
    color: #000;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.4);
}

.card-button:hover {
    transform: scale(1.05);
    box-shadow: 0 0 30px rgba(0, 255, 170, 0.6);
}

.card-link {
    color: #00ffaa;
    text-decoration: none;
    font-size: 14px;
    margin-top: 10px;
    display: block;
    text-align: center;
}

.card-link:hover {
    text-decoration: underline;
}

#error-message {
    color: #ff00aa;
    text-align: center;
    margin-top: 10px;
    font-size: 14px;
    text-shadow: 0 0 10px rgba(255, 0, 170, 0.5);
    display: none;
}

.scanning {
    animation: scanEffect 1s linear forwards;
}

@keyframes scanEffect {
    0% {
        filter: brightness(1) hue-rotate(0deg);
        box-shadow: 0 0 20px rgba(0, 212, 255, 0.4);
    }

    50% {
        filter: brightness(2) hue-rotate(180deg);
        box-shadow: 0 0 50px rgba(0, 255, 170, 1);
    }

    100% {
        filter: brightness(1) hue-rotate(360deg);
        box-shadow: 0 0 20px rgba(0, 212, 255, 0.4);
    }
}

.center-container .form-wrapper {
    position: relative;
    z-index: 101;
    cursor: default;
    transition: transform 0.3s ease;
}

.security-panel {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 320px;
    height: 480px;
    background: linear-gradient(135deg, #0a1929 0%, #1a2332 100%);
    border: 3px solid #00d4ff;
    border-radius: 20px;
    box-shadow: 0 0 60px rgba(0, 212, 255, 0.8);
    opacity: 0;
    transition: opacity 0.6s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    z-index: 102;
}

.security-panel.active {
    opacity: 1;
}

.security-scan-line {
    position: absolute;
    width: 100%;
    height: 4px;
    background: #00ffaa;
    box-shadow: 0 0 20px #00ffaa;
    animation: scanLine 2s linear infinite;
}

@keyframes scanLine {
    0% {
        top: 0;
    }

    100% {
        top: 100%;
    }
}

.security-status {
    color: #00d4ff;
    font-size: 2rem;
    text-align: center;
    margin-bottom: 20px;
    text-shadow: 0 0 20px #00d4ff;
}

.security-ok {
    color: #00ffaa !important;
    text-shadow: 0 0 20px #00ffaa !important;
}

.security-error {
    color: #ff00aa !important;
    text-shadow: 0 0 20px #ff00aa !important;
}
/* Permitir interacción con elementos HTML */
#scene-container canvas {
    pointer-events: none;
}

/* Asegurar que el contenido sea interactivo */
.content {
    pointer-events: auto;
}

/* Asegurar que el overlay de la puerta sea interactivo */
#door-overlay {
    pointer-events: auto;
}

/* El canvas de electricidad no debe bloquear interacciones */
#electricCanvas {
    pointer-events: none;
}



/* SOLUCIÓN DEFINITIVA PARA INTERACCIÓN DEL FORMULARIO */

/* Asegurar que el contenedor de Three.js NO bloquee */
#scene-container {
    pointer-events: none !important;
}

#scene-container canvas {
    pointer-events: none !important;
    z-index: 1 !important;
}

/* El overlay de la puerta debe estar encima */
#door-overlay {
    pointer-events: auto !important;
    z-index: 10001 !important;
}

/* Canvas de electricidad no debe bloquear */
#electricCanvas {
    pointer-events: none !important;
    z-index: 10002 !important;
}

/* Contenedor de puerta interactivo */
.door-container {
    pointer-events: none !important;
}

/* Form wrapper completamente interactivo */
.form-wrapper {
    pointer-events: auto !important;
    z-index: 10003 !important;
    position: relative !important;
}

/* Tarjetas de empleado completamente interactivas */
.employee-card {
    pointer-events: auto !important;
    z-index: 10004 !important;
    position: relative !important;
}

/* Todos los elementos del formulario interactivos */
.employee-card * {
    pointer-events: auto !important;
}

.card-field input {
    pointer-events: auto !important;
    cursor: text !important;
    z-index: 10005 !important;
    position: relative !important;
}

.card-button {
    pointer-events: auto !important;
    cursor: pointer !important;
    z-index: 10005 !important;
    position: relative !important;
}

.card-link {
    pointer-events: auto !important;
    cursor: pointer !important;
    z-index: 10005 !important;
    position: relative !important;
}

/* Asegurar que los forms sean interactivos */
#loginForm,
#registerForm {
    pointer-events: auto !important;
    z-index: 10005 !important;
}

/* Center container no debe bloquear el formulario */
.center-container {
    pointer-events: none !important;
}

.center-container .form-wrapper {
    pointer-events: auto !important;
}

/* Panel de seguridad interactivo cuando esté activo */
.security-panel {
    pointer-events: none !important;
}

.security-panel.active {
    pointer-events: auto !important;
    z-index: 10006 !important;
}


/* SOLUCIÓN DEFINITIVA PARA INTERACCIÓN DEL FORMULARIO */

/* Asegurar que el contenedor de Three.js NO bloquee */
#scene-container {
    pointer-events: none !important;
}

#scene-container canvas {
    pointer-events: none !important;
    z-index: 1 !important;
}

/* El overlay de la puerta debe estar encima */
#door-overlay {
    pointer-events: auto !important;
    z-index: 10001 !important;
}

/* Canvas de electricidad no debe bloquear */
#electricCanvas {
    pointer-events: none !important;
    z-index: 10002 !important;
}

/* Contenedor de puerta interactivo */
.door-container {
    pointer-events: none !important;
}

/* Form wrapper completamente interactivo */
.form-wrapper {
    pointer-events: auto !important;
    z-index: 10003 !important;
    position: relative !important;
}

/* Tarjetas de empleado completamente interactivas */
.employee-card {
    pointer-events: auto !important;
    z-index: 10004 !important;
    position: relative !important;
}

/* Todos los elementos del formulario interactivos */
.employee-card * {
    pointer-events: auto !important;
}

.card-field input {
    pointer-events: auto !important;
    cursor: text !important;
    z-index: 10005 !important;
    position: relative !important;
}

.card-button {
    pointer-events: auto !important;
    cursor: pointer !important;
    z-index: 10005 !important;
    position: relative !important;
}

.card-link {
    pointer-events: auto !important;
    cursor: pointer !important;
    z-index: 10005 !important;
    position: relative !important;
}

/* Asegurar que los forms sean interactivos */
#loginForm,
#registerForm {
    pointer-events: auto !important;
    z-index: 10005 !important;
}

/* Center container no debe bloquear el formulario */
.center-container {
    pointer-events: none !important;
}

.center-container .form-wrapper {
    pointer-events: auto !important;
}

/* Panel de seguridad interactivo cuando esté activo */
.security-panel {
    pointer-events: none !important;
}

.security-panel.active {
    pointer-events: auto !important;
    z-index: 10006 !important;
}

/* Asegurar animación de apertura de puerta */
.door-container.opening .door-top {
    transform: translateY(-100vh) !important;
    transition: transform 2s cubic-bezier(0.68, -0.55, 0.265, 1.55) !important;
}

.door-container.opening .door-bottom {
    transform: translateY(100vh) !important;
    transition: transform 2s cubic-bezier(0.68, -0.55, 0.265, 1.55) !important;
}

.door-container.opening .welcome-content {
    opacity: 1 !important;
    transition: opacity 1s ease 1s !important;
}