* { margin: 0; padding: 0; box-sizing: border-box; }
body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    background: #0a0505;
    color: #fff;
    min-height: 100vh;
    overflow-x: hidden;
}

/* ЗАСТАВКА */
#splash {
    position: fixed; inset: 0;
    background: radial-gradient(circle at center, #1a0505 0%, #000 100%);
    display: flex; align-items: center; justify-content: center;
    z-index: 9999;
    transition: opacity 0.8s ease;
}
.splash-logo {
    width: 600px; max-width: 90vw;
    animation: splashAppear 1s ease-out, floatGlow 2.5s ease-in-out infinite alternate;
}
@keyframes splashAppear { from { transform: scale(0.8); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@keyframes floatGlow {
    from { filter: drop-shadow(0 0 10px rgba(255, 50, 50, 0.2)); transform: translateY(0px); }
    to { filter: drop-shadow(0 0 35px rgba(255, 20, 20, 0.6)); transform: translateY(-5px); }
}

/* ВЕРХНЯЯ ПАНЕЛЬ */
.header-bar {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: 70px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 30px;
    background: rgba(15, 5, 5, 0.65);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 60, 60, 0.15);
    z-index: 100;
}

/* ТЕКСТ MAD KREQ С КРАСНЫМ ГРАДИЕНТОМ */
.header-brand {
    font-size: 22px;
    font-weight: 800;
    letter-spacing: 2px;
    background: linear-gradient(135deg, #ff4d4d, #b30000);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 0 10px rgba(255, 0, 0, 0.4));
}

/* КОНТЕЙНЕР КНОПОК */
.auth-nav {
    display: flex;
    gap: 12px;
}

/* КНОПКИ В КРАСНОМ СТИЛЕ */
.auth-tab {
    position: relative;
    padding: 10px 26px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 60, 60, 0.2);
    color: #c98b8b;
    font-size: 14px;
    font-weight: 600;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: inherit;
    overflow: hidden;
}
.auth-tab::before {
    content: '';
    position: absolute;
    top: 0; left: -100%;
    width: 100%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 100, 100, 0.2), transparent);
    transition: left 0.5s ease;
}
.auth-tab:hover::before { left: 100%; }
.auth-tab:hover:not(.active) {
    background: rgba(255, 50, 50, 0.1);
    color: #fff;
    border-color: rgba(255, 80, 80, 0.4);
}
.auth-tab.active {
    background: linear-gradient(135deg, #e60000, #8b0000);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 4px 25px rgba(230, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

/* ОСНОВНОЙ КОНТЕНТ */
#main-content {
    min-height: 100vh;
    display: flex; align-items: center; justify-content: center;
    padding: 100px 20px 20px;
    position: relative;
    background: #0a0505;
    overflow: hidden;
}
.hidden { display: none !important; }

/* КРАСНЫЕ ФОНОВЫЕ СФЕРЫ */
.bg-blobs { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
.blob {
    position: absolute; border-radius: 50%;
    filter: blur(120px); opacity: 0.45;
    animation: floatBlob 12s ease-in-out infinite;
}
.blob-1 { width: 500px; height: 500px; background: #cc0000; top: -150px; left: -150px; }
.blob-2 { width: 450px; height: 450px; background: #ff4500; bottom: -150px; right: -150px; animation-delay: -4s; }
.blob-3 { width: 350px; height: 350px; background: #8b0000; top: 40%; left: 70%; animation-delay: -8s; }
@keyframes floatBlob {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(40px, -40px) scale(1.1); }
}

/* ЦЕНТРАЛЬНЫЙ БОКС */
.auth-wrapper {
    position: relative; z-index: 2;
    width: 100%; max-width: 420px;
}
.auth-card {
    background: rgba(22, 12, 12, 0.7);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 1px solid rgba(255, 60, 60, 0.15);
    border-radius: 28px;
    padding: 40px 32px;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.05);
    animation: cardAppear 0.8s ease-out;
}
@keyframes cardAppear {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.auth-form { display: flex; flex-direction: column; gap: 14px; }
.input-group { position: relative; }
.input-group input {
    width: 100%; padding: 16px 18px;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 60, 60, 0.15);
    border-radius: 14px;
    color: #fff; font-size: 15px; font-family: inherit;
    transition: 0.3s;
}
.input-group input::placeholder { color: #7a5050; }
.input-group input:focus {
    outline: none;
    border-color: #ff3c3c;
    background: rgba(0, 0, 0, 0.6);
    box-shadow: 0 0 0 4px rgba(255, 50, 50, 0.15), 0 0 20px rgba(255, 50, 50, 0.25);
}

/* ГЛАВНАЯ КНОПКА ВХОДА / РЕГИСТРАЦИИ */
.btn-glow {
    width: 100%; padding: 16px;
    background: linear-gradient(135deg, #ff3c3c, #a80000);
    border: none; border-radius: 14px;
    color: #fff; font-size: 15px; font-weight: 700;
    letter-spacing: 0.5px; cursor: pointer;
    margin-top: 10px;
    box-shadow: 0 10px 30px rgba(255, 30, 30, 0.4), 0 0 0 1px rgba(255, 255, 255, 0.1) inset;
    transition: all 0.3s ease;
    font-family: inherit;
    position: relative; overflow: hidden;
}
.btn-glow::before {
    content: ''; position: absolute; top: 0; left: -100%;
    width: 100%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: 0.6s;
}
.btn-glow:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 45px rgba(255, 30, 30, 0.65), 0 0 0 1px rgba(255, 255, 255, 0.2) inset;
}
.btn-glow:hover::before { left: 100%; }
.btn-glow:active { transform: translateY(0); }
.btn-glow span { position: relative; z-index: 1; }

.msg { margin-top: 14px; font-size: 13px; text-align: center; min-height: 18px; }
.msg.error { color: #ff6b6b; }
.msg.success { color: #51cf66; }

/* МОБИЛЬНАЯ АДАПТАЦИЯ */
@media (max-width: 600px) {
    .header-bar { padding: 0 15px; height: 60px; }
    .header-brand { font-size: 18px; }
    .auth-tab { padding: 8px 16px; font-size: 12px; }
    .auth-card { padding: 30px 20px; border-radius: 20px; }
}