html {
    height: 100%;
}

body {
    margin: 0;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    color: #e0e2ed; /* Чуть более мягкий белый */
    align-items: center;
    background: radial-gradient(circle at top, #252538 0%, #13131a 100%); /* Красивый глубокий градиент */
    font-family: "DejaVu Sans Mono", monospace;
    -webkit-font-smoothing: antialiased;
}

/* Автозаполнение полей */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
input:-webkit-autofill:active {
    -webkit-background-clip: text;
    -webkit-text-fill-color: #ffffff !important;
    transition: background-color 5000s ease-in-out 0s;
    box-shadow: inset 0 0 20px 20px #1a1a28; 
    caret-color: #ffffff;
}

@media (max-width: 480px) {
    body {
        align-items: flex-start;
        padding: 0;
    }
}

/* Контейнер (Карточка) */
.home-container {
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 440px; /* Немного расширил для баланса */
    padding: 35px;
    background: rgba(42, 42, 60, 0.6); /* Полупрозрачный фон */
    backdrop-filter: blur(12px); /* Эффект матового стекла */
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.06); /* Едва заметная тонкая неоновая рамка */
    border-radius: 16px; /* Более современные скругления */
    box-sizing: border-box;
    margin: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.35); /* Мягкая глубокая тень */
}

@media (max-width: 480px) {
    .home-container {
        max-width: 100%;
        border: none;
        min-height: 100vh;
        justify-content: center;
        margin: 0;
        border-radius: 0;
        background: #1a1a26; /* На мобилках лучше глухой фон */
    }
}

@media (max-width: 320px) {
    .home-container {
        padding: 25px 20px;
    }
    
    h1 {
        font-size: 1.4rem;
    }
    
    .logo {
        width: 110px;
    }
}

/* Сетка меню */
@media (max-width: 320px) {
    .menu-grid {
        grid-template-columns: 1fr !important;
    }
    .menu-grid a {
        grid-column: span 1 !important;
    }
}

/* Заголовки */
h1, h2 {
    width: 100%;
    color: #ffffff;
    margin: 0 0 24px 0;
    text-align: center;
    text-transform: uppercase;
    word-wrap: break-word;
    font-size: 1.6rem;
    letter-spacing: 1px; /* Стильный разряд букв */
    text-shadow: 0 2px 10px rgba(255, 255, 255, 0.1);
}

.logo + h1 {
    margin-top: 0;
}

.logo {
    width: 140px;
    max-width: 100%;
    height: auto;
    margin: 0 auto 24px auto;
    display: block;
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.3)); /* Тень под логотипом */
}

.footer {
    margin-top: 24px;
    text-align: center;
    font-size: 0.75rem;
    opacity: 0.4;
    color: #ffffff;
    word-wrap: break-word;
    letter-spacing: 0.5px;
}

/* Поля ввода (Inputs) */
input {
    width: 100%;
    padding: 14px 16px;
    margin-bottom: 18px;
    background-color: rgba(26, 26, 40, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px; /* Скругление инпутов */
    color: #fff;
    font-family: inherit;
    box-sizing: border-box;
    font-size: 15px;
    transition: all 0.2s ease-in-out;
}

input:focus {
    outline: none;
    border-color: #8a5cd1; /* Фиолетовый фокус */
    box-shadow: 0 0 0 3px rgba(138, 92, 209, 0.2); /* Аккуратное свечение при вводе */
    background-color: #1a1a28;
}

/* Главная кнопка */
button, .btn-enter {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #6e4594 0%, #513075 100%); /* Градиент вместо глухого цвета */
    color: #ffffff;
    border: none; /* Убрал топорную серую рамку */
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
    text-transform: uppercase;
    text-decoration: none;
    display: block;
    text-align: center;
    box-sizing: border-box;
    font-size: 15px;
    letter-spacing: 0.5px;
    transition: all 0.25s ease;
    box-shadow: 0 4px 15px rgba(110, 69, 148, 0.3); /* Фиолетовая тень */
}

button:hover, .btn-enter:hover {
    background: linear-gradient(135deg, #8253ae 0%, #5f398a 100%);
    box-shadow: 0 6px 20px rgba(110, 69, 148, 0.5); /* Усиление свечения при наведении */
    transform: translateY(-1px); /* Легкий интерактивный подъем */
}

button:active, .btn-enter:active {
    transform: translateY(1px);
}

/* Ссылки (Регистрация и т.д.) */
.reg-link {
    margin-top: 22px;
    color: #b38fdd;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: bold;
    text-align: center;
    word-wrap: break-word;
    padding: 5px 10px;
    display: inline-block;
    align-self: center;
    transition: color 0.2s;
}

.reg-link:hover {
    color: #d1bbf2;
    text-shadow: 0 0 8px rgba(179, 143, 221, 0.4);
}

/* Кнопки плиточного меню (Админка) */
.btn-menu {
    padding: 16px 12px;
    background-color: #1c1c2d;
    color: #a5a6c4; /* Приглушенный текст по дефолту */
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    text-decoration: none;
    text-align: center;
    font-size: 13px;
    font-weight: bold;
    text-transform: uppercase;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 3px 6px rgba(0,0,0,0.1);
}

.btn-menu:hover {
    background-color: #25253b;
    border-color: #6e4594;
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(110, 69, 148, 0.2);
    transform: translateY(-1px);
}

/* Особая кнопка ADMIN */
.admin-btn {
    border-color: rgba(255, 204, 0, 0.3);
    color: #ffcc00;
}

.admin-btn:hover {
    background: #ffcc00 !important;
    color: #000000 !important;
    border-color: #ffcc00 !important;
    box-shadow: 0 4px 15px rgba(255, 204, 0, 0.4) !important;
}