/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #e0e0e0;
    transition: all 3s ease-in-out;
}

body.transition-to-infinite {
    background: linear-gradient(135deg, #b8860b 0%, #cd853f 50%, #deb887 100%);
    color: #333;
}

.container {
    width: 100%;
    max-width: 800px;
    padding: 2rem;
}

.redirect-content {
    background: rgba(20, 20, 40, 0.9);
    border: 1px solid rgba(102, 126, 234, 0.3);
    border-radius: 20px;
    padding: 3rem;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    text-align: center;
    backdrop-filter: blur(15px);
    transition: all 3s ease-in-out;
}

.redirect-content.transition-to-infinite {
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(184, 134, 11, 0.3);
    box-shadow: 0 20px 40px rgba(184, 134, 11, 0.15);
}

/* Logo section */
.logo-section {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 2rem;
    gap: 2rem;
}

.old-logo, .new-logo {
    flex: 1;
    opacity: 1;
    transition: all 0.8s ease-in-out;
}

.logo-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.logo-badge {
    width: 100px;
    height: 100px;
    object-fit: contain;
    border-radius: 15px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
}

.logo-text {
    max-width: 180px;
    height: auto;
    object-fit: contain;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.1));
}

.logo-badge:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.2);
}

.old-logo.fade-out {
    opacity: 0.3;
    transform: scale(0.9);
}

.new-logo {
    opacity: 0.3;
    transform: scale(0.9);
}

.new-logo.fade-in {
    opacity: 1;
    transform: scale(1.1);
}

/* Arrow transition */
.arrow-transition {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 1rem;
}

.arrow {
    width: 60px;
    height: 6px;
    background: linear-gradient(90deg, #667eea, #764ba2);
    position: relative;
    border-radius: 3px;
    opacity: 0.5;
    transition: all 0.8s ease-in-out;
}

.arrow::after {
    content: '';
    position: absolute;
    right: -10px;
    top: 50%;
    transform: translateY(-50%);
    width: 0;
    height: 0;
    border-left: 15px solid #764ba2;
    border-top: 8px solid transparent;
    border-bottom: 8px solid transparent;
}

.arrow-transition.animate .arrow {
    opacity: 1;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

/* Message section */
.message {
    margin: 2rem 0;
}

.message h1 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #e0e0e0;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #667eea, #a8edea);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 20px rgba(102, 126, 234, 0.3);
    transition: all 2s ease-in-out;
}

.message h1.transition-to-infinite {
    color: #333;
    background: linear-gradient(135deg, #b8860b, #cd853f);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: none;
}

.message p {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: #b0b0c0;
    line-height: 1.6;
    transition: color 2s ease-in-out;
}

.message p.transition-to-infinite {
    color: #666;
}

.message p strong {
    color: #a8edea;
    font-weight: 600;
    transition: color 2s ease-in-out;
}

.message p strong.transition-to-infinite {
    color: #b8860b;
}

#countdown {
    font-weight: bold;
    color: #667eea;
    font-size: 1.3em;
}

/* Redirect button */
.redirect-btn {
    display: inline-block;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    text-decoration: none;
    padding: 1rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1.1rem;
    margin-top: 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.3);
}

.redirect-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

.redirect-btn.transition-to-infinite {
    background: linear-gradient(135deg, #b8860b, #cd853f);
    box-shadow: 0 5px 15px rgba(184, 134, 11, 0.3);
}

.redirect-btn.transition-to-infinite:hover {
    box-shadow: 0 8px 25px rgba(184, 134, 11, 0.4);
}

/* Progress bar */
.progress-bar {
    width: 100%;
    height: 6px;
    background: rgba(102, 126, 234, 0.2);
    border-radius: 3px;
    margin-top: 2rem;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #667eea, #764ba2);
    width: 0%;
    transition: width 1s linear;
    border-radius: 3px;
}

/* Responsive design */
@media (max-width: 768px) {
    .redirect-content {
        padding: 2rem;
    }
    
    .logo-section {
        flex-direction: column;
        gap: 1.5rem;
    }
    
    .arrow-transition {
        transform: rotate(90deg);
        margin: 1rem 0;
    }
    
    .logo-badge {
        width: 80px;
        height: 80px;
    }
    
    .logo-text {
        max-width: 140px;
    }
    
    .message h1 {
        font-size: 2rem;
    }
    
    .message p {
        font-size: 1.1rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 1rem;
    }
    
    .redirect-content {
        padding: 1.5rem;
    }
    
    .message h1 {
        font-size: 1.8rem;
    }
    
    .logo-badge {
        width: 70px;
        height: 70px;
    }
    
    .logo-text {
        max-width: 120px;
    }
}