/* ===== TECH TRANSITION OVERLAY ===== */
.tech-transition-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, 
        rgba(0, 0, 0, 0.95) 0%, 
        rgba(26, 41, 66, 0.98) 50%, 
        rgba(0, 0, 0, 0.95) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* ===== MATRIX RAIN BACKGROUND ===== */
.matrix-rain {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    opacity: 0.3;
    z-index: 1;
}

#matrix-canvas {
    width: 100%;
    height: 100%;
}

/* ===== SCANNING LINES ===== */
.scan-lines {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2;
    pointer-events: none;
}

.scan-line {
    position: absolute;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(0, 212, 255, 0.8), 
        transparent);
    box-shadow: 0 0 10px rgba(0, 212, 255, 0.6);
}

.scan-1 {
    top: 20%;
    animation: scanMove 3s linear infinite;
}

.scan-2 {
    top: 50%;
    animation: scanMove 4s linear infinite reverse;
}

.scan-3 {
    top: 80%;
    animation: scanMove 5s linear infinite;
}

@keyframes scanMove {
    0%, 100% {
        transform: translateY(-200px);
        opacity: 0;
    }
    10%, 90% {
        opacity: 1;
    }
    50% {
        transform: translateY(200px);
    }
}

/* ===== CENTRAL TECH HUB ===== */
.tech-hub {
    position: relative;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: var(--space-8);
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
}

/* ===== GLITCH EFFECTS ===== */
.glitch-container {
    position: relative;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.glitch-logo {
    position: relative;
    margin-bottom: var(--space-4);
    display: flex;
    justify-content: center;
    align-items: center;
}

.logo-main,
.logo-glitch-1,
.logo-glitch-2 {
    height: 120px;
    width: auto;
    filter: drop-shadow(0 0 20px rgba(0, 212, 255, 0.8));
    display: block;
}

.logo-main {
    position: relative;
    z-index: 3;
}

.logo-glitch-1,
.logo-glitch-2 {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0;
    z-index: 1;
}

.logo-main {
    animation: glitchMain 2s infinite;
}

.logo-glitch-1 {
    animation: glitch1 2s infinite;
    filter: drop-shadow(0 0 20px rgba(255, 0, 100, 0.6));
}

.logo-glitch-2 {
    animation: glitch2 2s infinite;
    filter: drop-shadow(0 0 20px rgba(0, 255, 100, 0.6));
}

@keyframes glitchMain {
    0%, 90%, 100% {
        transform: translateX(0);
    }
    92%, 98% {
        transform: translateX(0) translateY(-2px);
    }
}

@keyframes glitch1 {
    0%, 90%, 100% {
        opacity: 0;
        transform: translateX(-50%);
    }
    92% {
        opacity: 0.8;
        transform: translateX(-52%) skew(-2deg);
    }
    94% {
        opacity: 0;
        transform: translateX(-50%);
    }
}

@keyframes glitch2 {
    0%, 90%, 100% {
        opacity: 0;
        transform: translateX(-50%);
    }
    96% {
        opacity: 0.6;
        transform: translateX(-48%) skew(2deg);
    }
    98% {
        opacity: 0;
        transform: translateX(-50%);
    }
}

/* ===== GLITCH TEXT ===== */
.glitch-text {
    position: relative;
    font-size: var(--fs-2xl);
    font-weight: var(--fw-extrabold);
    letter-spacing: 0.1em;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.text-main,
.text-glitch-1,
.text-glitch-2 {
    display: block;
    text-align: center;
    width: 100%;
}

.text-glitch-1,
.text-glitch-2 {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    opacity: 0;
}

.text-main {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: textGlitchMain 2s infinite;
}

.text-glitch-1 {
    color: #ff0066;
    animation: textGlitch1 2s infinite;
}

.text-glitch-2 {
    color: #00ff66;
    animation: textGlitch2 2s infinite;
}

@keyframes textGlitchMain {
    0%, 90%, 100% {
        transform: translateX(0);
    }
    92%, 98% {
        transform: translateX(-1px);
    }
}

@keyframes textGlitch1 {
    0%, 90%, 100% {
        opacity: 0;
        transform: translateX(0);
    }
    92% {
        opacity: 0.7;
        transform: translateX(-2px) skew(-1deg);
    }
    94% {
        opacity: 0;
        transform: translateX(0);
    }
}

@keyframes textGlitch2 {
    0%, 90%, 100% {
        opacity: 0;
        transform: translateX(0);
    }
    96% {
        opacity: 0.5;
        transform: translateX(2px) skew(1deg);
    }
    98% {
        opacity: 0;
        transform: translateX(0);
    }
}

/* ===== TECH ELEMENTS ===== */
.tech-elements {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-6);
}

/* ===== LOADING ORBIT ===== */
.loading-orbit {
    position: relative;
    width: 150px;
    height: 150px;
}

.orbit-ring {
    position: absolute;
    border: 2px solid transparent;
    border-radius: 50%;
    border-top-color: rgba(0, 212, 255, 0.8);
}

.ring-1 {
    width: 150px;
    height: 150px;
    top: 0;
    left: 0;
    animation: orbitSpin 2s linear infinite;
}

.ring-2 {
    width: 120px;
    height: 120px;
    top: 15px;
    left: 15px;
    border-top-color: rgba(90, 228, 255, 0.6);
    animation: orbitSpin 3s linear infinite reverse;
}

.ring-3 {
    width: 90px;
    height: 90px;
    top: 30px;
    left: 30px;
    border-top-color: rgba(0, 102, 204, 0.4);
    animation: orbitSpin 4s linear infinite;
}

.orbit-core {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 20px;
    height: 20px;
    background: var(--gradient-primary);
    border-radius: 50%;
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.8);
    animation: coreGlow 2s ease-in-out infinite alternate;
}

@keyframes orbitSpin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

@keyframes coreGlow {
    from {
        box-shadow: 0 0 20px rgba(0, 212, 255, 0.8);
        transform: translate(-50%, -50%) scale(1);
    }
    to {
        box-shadow: 0 0 40px rgba(0, 212, 255, 1);
        transform: translate(-50%, -50%) scale(1.2);
    }
}

/* ===== CODE STREAM ===== */
.code-stream {
    font-family: 'Courier New', monospace;
    font-size: var(--fs-sm);
    color: rgba(0, 212, 255, 0.8);
    text-align: center;
    line-height: 1.8;
}

.code-line {
    opacity: 0;
    transform: translateY(10px);
    animation: codeAppear 0.8s ease-out forwards;
}

.code-line:nth-child(1) {
    animation-delay: 0.2s;
}

.code-line:nth-child(2) {
    animation-delay: 0.6s;
}

.code-line:nth-child(3) {
    animation-delay: 1s;
}

@keyframes codeAppear {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== TECH STATS ===== */
.tech-stats {
    display: flex;
    gap: var(--space-8);
    margin-top: var(--space-4);
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-2);
}

.stat-label {
    font-size: var(--fs-xs);
    color: rgba(255, 255, 255, 0.6);
    font-weight: var(--fw-medium);
    letter-spacing: 0.1em;
}

.stat-value {
    font-size: var(--fs-sm);
    color: var(--primary-cyan);
    font-weight: var(--fw-semibold);
    text-shadow: 0 0 10px rgba(0, 212, 255, 0.5);
    animation: statBlink 2s ease-in-out infinite;
}

@keyframes statBlink {
    0%, 80%, 100% {
        opacity: 1;
    }
    90% {
        opacity: 0.5;
    }
}

/* ===== PARTICLE SYSTEM ===== */
.tech-particles {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 3;
    pointer-events: none;
}

#particles-canvas {
    width: 100%;
    height: 100%;
    opacity: 0.6;
}

/* ===== PROGRESS HUD ===== */
.progress-hud {
    position: absolute;
    bottom: var(--space-8);
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-3);
    z-index: 10;
}

.hud-bar {
    width: 300px;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-full);
    overflow: hidden;
    border: 1px solid rgba(0, 212, 255, 0.3);
}

.hud-fill {
    height: 100%;
    background: var(--gradient-primary);
    width: 0%;
    transition: width 1.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 0 10px rgba(0, 212, 255, 0.8);
    position: relative;
}

.hud-fill::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 10px;
    height: 100%;
    background: rgba(255, 255, 255, 0.6);
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.8);
    filter: blur(2px);
}

.hud-text {
    font-size: var(--fs-xs);
    color: rgba(255, 255, 255, 0.8);
    font-weight: var(--fw-medium);
    letter-spacing: 0.2em;
    text-align: center;
    font-family: 'Courier New', monospace;
    animation: hudTextPulse 2s ease-in-out infinite;
}

@keyframes hudTextPulse {
    0%, 100% {
        opacity: 0.8;
    }
    50% {
        opacity: 1;
        text-shadow: 0 0 10px rgba(0, 212, 255, 0.5);
    }
}

/* ===== RESPONSIVE TECH TRANSITION ===== */
@media (max-width: 768px) {
    .tech-hub {
        gap: var(--space-6);
        padding: var(--space-4);
        max-width: 90%;
    }
    
    .glitch-container {
        width: 100%;
        max-width: 300px;
        margin: 0 auto;
    }
    
    .glitch-logo {
        width: 100%;
        justify-content: center;
    }
    
    .logo-main,
    .logo-glitch-1,
    .logo-glitch-2 {
        height: 80px;
        margin: 0 auto;
    }
    
    .glitch-text {
        font-size: var(--fs-lg);
        width: 100%;
        text-align: center;
    }
    
    .loading-orbit {
        width: 100px;
        height: 100px;
    }
    
    .ring-1 {
        width: 100px;
        height: 100px;
    }
    
    .ring-2 {
        width: 80px;
        height: 80px;
        top: 10px;
        left: 10px;
    }
    
    .ring-3 {
        width: 60px;
        height: 60px;
        top: 20px;
        left: 20px;
    }
    
    .tech-stats {
        gap: var(--space-4);
    }
    
    .code-stream {
        font-size: var(--fs-xs);
    }
    
    .hud-bar {
        width: 250px;
    }
}

@media (max-width: 480px) {
    .tech-hub {
        max-width: 95%;
        gap: var(--space-4);
    }
    
    .glitch-container {
        max-width: 280px;
    }
    
    .logo-main,
    .logo-glitch-1,
    .logo-glitch-2 {
        height: 70px;
    }
    
    .glitch-text {
        font-size: var(--fs-base);
        letter-spacing: 0.05em;
    }
}

/* ===== ACCESSIBILITY ===== */
@media (prefers-reduced-motion: reduce) {
    .scan-line,
    .logo-main,
    .logo-glitch-1,
    .logo-glitch-2,
    .text-main,
    .text-glitch-1,
    .text-glitch-2,
    .orbit-ring,
    .orbit-core,
    .stat-value,
    .hud-text {
        animation: none !important;
    }
    
    .hud-fill {
        transition: width 0.4s ease !important;
    }
} 