/* =====================================================
   ???????? ????? ? ?????? ??????????????
   ???????: app.css.bak-20260801-000457, ?????? 3237?3720
   ===================================================== */

body > .auth-content,
.auth-content {
    position: relative !important;
    isolation: isolate !important;
    overflow: hidden !important;
    min-height: 100vh !important;
    padding: 32px 20px !important;

    background-color: #070b16 !important;
    background-image:
        radial-gradient(
            circle at 15% 15%,
            rgba(37, 99, 235, 0.32) 0,
            rgba(37, 99, 235, 0.12) 22%,
            transparent 43%
        ),
        radial-gradient(
            circle at 87% 20%,
            rgba(124, 58, 237, 0.27) 0,
            rgba(124, 58, 237, 0.10) 23%,
            transparent 43%
        ),
        radial-gradient(
            circle at 52% 105%,
            rgba(14, 165, 233, 0.20) 0,
            transparent 44%
        ),
        linear-gradient(
            135deg,
            #050816 0%,
            #0b1224 48%,
            #080d1a 100%
        ) !important;
}

/* Тонкая современная сетка */
body > .auth-content::before,
.auth-content::before {
    content: "" !important;
    position: absolute !important;
    inset: 0 !important;
    z-index: -2 !important;
    pointer-events: none !important;

    background-image:
        linear-gradient(
            rgba(255, 255, 255, 0.035) 1px,
            transparent 1px
        ),
        linear-gradient(
            90deg,
            rgba(255, 255, 255, 0.035) 1px,
            transparent 1px
        ) !important;

    background-size: 48px 48px !important;
    mask-image: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.8),
        transparent 92%
    );
    -webkit-mask-image: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.8),
        transparent 92%
    );
}

/* Дополнительное мягкое свечение около формы */
body > .auth-content::after,
.auth-content::after {
    content: "" !important;
    position: absolute !important;
    z-index: -1 !important;
    pointer-events: none !important;

    width: 620px !important;
    height: 620px !important;
    left: 50% !important;
    top: 50% !important;
    transform: translate(-50%, -50%) !important;

    border-radius: 50% !important;
    background: rgba(37, 99, 235, 0.10) !important;
    filter: blur(110px) !important;
}

/* Стеклянная карточка входа */
.auth-content .login-card {
    position: relative !important;
    z-index: 2 !important;

    width: min(430px, 100%) !important;
    padding: 32px !important;

    background:
        linear-gradient(
            145deg,
            rgba(23, 32, 51, 0.88),
            rgba(12, 19, 34, 0.82)
        ) !important;

    border: 1px solid rgba(148, 163, 184, 0.18) !important;
    border-radius: 18px !important;

    box-shadow:
        0 35px 90px rgba(0, 0, 0, 0.48),
        0 0 0 1px rgba(255, 255, 255, 0.025) inset,
        0 12px 35px rgba(37, 99, 235, 0.08) !important;

    backdrop-filter: blur(22px) saturate(135%) !important;
    -webkit-backdrop-filter: blur(22px) saturate(135%) !important;
}

/* Заголовок */
.auth-content .login-card h1 {
    margin-bottom: 24px !important;
    font-size: 30px !important;
    letter-spacing: -0.035em !important;
}

/* Поля */
.auth-content .login-card input[type="text"],
.auth-content .login-card input[type="password"] {
    min-height: 46px !important;
    background: rgba(30, 41, 59, 0.78) !important;
    border: 1px solid rgba(148, 163, 184, 0.25) !important;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease !important;
}

.auth-content .login-card input[type="text"]:focus,
.auth-content .login-card input[type="password"]:focus {
    outline: none !important;
    background: rgba(30, 41, 59, 0.95) !important;
    border-color: #3b82f6 !important;
    box-shadow:
        0 0 0 4px rgba(59, 130, 246, 0.16) !important;
}

/* Кнопка */
.auth-content .login-card button[type="submit"] {
    min-height: 44px !important;
    border-radius: 9px !important;
    background:
        linear-gradient(
            135deg,
            #2563eb,
            #3b82f6
        ) !important;

    border-color: rgba(96, 165, 250, 0.5) !important;

    box-shadow:
        0 10px 28px rgba(37, 99, 235, 0.25) !important;

    transition:
        transform 0.18s ease,
        box-shadow 0.18s ease,
        filter 0.18s ease !important;
}

.auth-content .login-card button[type="submit"]:hover {
    transform: translateY(-1px) !important;
    filter: brightness(1.08) !important;
    box-shadow:
        0 14px 34px rgba(37, 99, 235, 0.34) !important;
}

/* Мобильная версия */
@media (max-width: 600px) {
    .auth-content {
        padding: 20px 14px !important;
    }

    .auth-content .login-card {
        padding: 25px 20px !important;
        border-radius: 15px !important;
    }
}


/* =====================================================
   AURUM private — логотип страницы входа
   ===================================================== */

.auth-content .auth-brand {
    position: absolute !important;
    z-index: 3 !important;

    top: clamp(42px, 8vh, 90px) !important;
    left: 50% !important;
    transform: translateX(-50%) !important;

    display: flex !important;
    align-items: baseline !important;
    justify-content: center !important;
    gap: 12px !important;

    width: max-content !important;
    max-width: calc(100vw - 32px) !important;

    text-align: center !important;
    user-select: none !important;
}

.auth-content .auth-brand::before {
    content: "" !important;
    position: absolute !important;
    z-index: -1 !important;

    width: 160% !important;
    height: 180% !important;
    left: 50% !important;
    top: 50% !important;
    transform: translate(-50%, -50%) !important;

    background: radial-gradient(
        circle,
        rgba(59, 130, 246, 0.22) 0%,
        rgba(124, 58, 237, 0.10) 42%,
        transparent 72%
    ) !important;

    filter: blur(24px) !important;
    pointer-events: none !important;
}

.auth-content .auth-brand-main {
    font-family:
        Inter,
        "Segoe UI",
        Arial,
        sans-serif !important;

    font-size: clamp(42px, 5.2vw, 76px) !important;
    font-weight: 800 !important;
    line-height: 1 !important;
    letter-spacing: 0.14em !important;

    color: #f8fafc !important;

    text-shadow:
        0 0 20px rgba(96, 165, 250, 0.25),
        0 8px 30px rgba(0, 0, 0, 0.35) !important;
}

.auth-content .auth-brand-private {
    font-family:
        Georgia,
        "Times New Roman",
        serif !important;

    font-size: clamp(20px, 2vw, 31px) !important;
    font-weight: 500 !important;
    font-style: italic !important;
    line-height: 1 !important;
    letter-spacing: 0.04em !important;

    background: linear-gradient(
        135deg,
        #93c5fd 0%,
        #c4b5fd 52%,
        #e9d5ff 100%
    ) !important;

    -webkit-background-clip: text !important;
    background-clip: text !important;
    color: transparent !important;

    text-shadow:
        0 0 18px rgba(167, 139, 250, 0.20) !important;
}

@media (max-width: 600px) {
    .auth-content .auth-brand {
        top: 34px !important;
        gap: 7px !important;
        flex-direction: column !important;
        align-items: center !important;
    }

    .auth-content .auth-brand-main {
        font-size: 38px !important;
        letter-spacing: 0.10em !important;
    }

    .auth-content .auth-brand-private {
        font-size: 19px !important;
        margin-top: -2px !important;
    }
}


/* =====================================================
   GitHub-style сообщение об ошибке авторизации
   ===================================================== */

.auth-content .alert,
.auth-content .flash,
.auth-content .flash-message{
    position: static !important;

    width: min(430px,100%) !important;

    margin:0 auto 18px auto !important;

    border-radius:10px !important;

    display:block !important;

    text-align:left !important;

    padding:14px 16px !important;

    box-sizing:border-box !important;
}

.auth-content .login-card{
    margin-top:0 !important;
}

.auth-content{
    display:flex !important;
    flex-direction:column !important;
    justify-content:center !important;
    align-items:center !important;
    gap:18px !important;
}


/* =====================================================
   AURUM private — светлая тема страницы входа
   ===================================================== */

html[data-theme="light"] .auth-content {
    background-color: #f4f7fb !important;
    background-image:
        radial-gradient(
            circle at 15% 15%,
            rgba(59, 130, 246, 0.16) 0,
            rgba(59, 130, 246, 0.07) 24%,
            transparent 45%
        ),
        radial-gradient(
            circle at 88% 18%,
            rgba(124, 58, 237, 0.13) 0,
            rgba(124, 58, 237, 0.05) 26%,
            transparent 46%
        ),
        radial-gradient(
            circle at 50% 105%,
            rgba(14, 165, 233, 0.12) 0,
            transparent 44%
        ),
        linear-gradient(
            135deg,
            #f8fafc 0%,
            #eef4ff 48%,
            #f7f3ff 100%
        ) !important;
}

html[data-theme="light"] .auth-content::before {
    background-image:
        linear-gradient(
            rgba(15, 23, 42, 0.045) 1px,
            transparent 1px
        ),
        linear-gradient(
            90deg,
            rgba(15, 23, 42, 0.045) 1px,
            transparent 1px
        ) !important;
}

html[data-theme="light"] .auth-content::after {
    background: rgba(59, 130, 246, 0.10) !important;
}

/* Логотип */
html[data-theme="light"] .auth-brand-main {
    color: #0f172a !important;

    text-shadow:
        0 0 20px rgba(59, 130, 246, 0.12),
        0 6px 20px rgba(15, 23, 42, 0.08) !important;
}

html[data-theme="light"] .auth-brand-private {
    background: linear-gradient(
        135deg,
        #2563eb 0%,
        #7c3aed 55%,
        #9333ea 100%
    ) !important;

    -webkit-background-clip: text !important;
    background-clip: text !important;
    color: transparent !important;

    text-shadow:
        0 0 16px rgba(124, 58, 237, 0.10) !important;
}

/* Карточка входа */
html[data-theme="light"] .auth-content .login-card {
    background:
        linear-gradient(
            145deg,
            rgba(255, 255, 255, 0.94),
            rgba(248, 250, 252, 0.90)
        ) !important;

    border: 1px solid rgba(148, 163, 184, 0.35) !important;

    box-shadow:
        0 30px 80px rgba(15, 23, 42, 0.14),
        0 0 0 1px rgba(255, 255, 255, 0.65) inset,
        0 10px 28px rgba(37, 99, 235, 0.08) !important;

    color: #0f172a !important;
}

html[data-theme="light"] .auth-content .login-card h1,
html[data-theme="light"] .auth-content .login-card label,
html[data-theme="light"] .auth-content .login-card .checkbox,
html[data-theme="light"] .auth-content .login-card .checkbox span {
    color: #0f172a !important;
    -webkit-text-fill-color: #0f172a !important;
}

/* Поля ввода */
html[data-theme="light"] .auth-content .login-card input[type="text"],
html[data-theme="light"] .auth-content .login-card input[type="password"] {
    background: rgba(255, 255, 255, 0.92) !important;
    border: 1px solid #cbd5e1 !important;
    color: #0f172a !important;
    -webkit-text-fill-color: #0f172a !important;
}

html[data-theme="light"] .auth-content .login-card input[type="text"]:focus,
html[data-theme="light"] .auth-content .login-card input[type="password"]:focus {
    background: #ffffff !important;
    border-color: #2563eb !important;

    box-shadow:
        0 0 0 4px rgba(37, 99, 235, 0.13) !important;
}

/* Чекбокс */
html[data-theme="light"] .auth-content .login-card input[type="checkbox"] {
    accent-color: #2563eb !important;
}

/* GitHub-style ошибка */
html[data-theme="light"] .auth-content .alert.danger,
html[data-theme="light"] .auth-content .alert.error,
html[data-theme="light"] .auth-content .flash.danger,
html[data-theme="light"] .auth-content .flash.error {
    background: #ffebe9 !important;
    color: #82071e !important;
    border: 1px solid #ff8182 !important;

    box-shadow:
        0 8px 24px rgba(130, 7, 30, 0.08) !important;

    -webkit-text-fill-color: #82071e !important;
}

html[data-theme="light"] .auth-content .alert.danger *,
html[data-theme="light"] .auth-content .alert.error *,
html[data-theme="light"] .auth-content .flash.danger *,
html[data-theme="light"] .auth-content .flash.error * {
    color: #82071e !important;
    -webkit-text-fill-color: #82071e !important;
}

/* =====================================================
   AURUM private — логотип боковой панели
   ===================================================== */

/* ===== LOGIN ALERT TEXT FIX ===== */

.auth-content .alert,
.auth-content .flash,
.auth-content .flash-message {
    color: #7f1d1d !important;
    font-weight: 700 !important;
}

.auth-content .alert *,
.auth-content .flash *,
.auth-content .flash-message * {
    color: inherit !important;
}

.auth-content .alert.danger,
.auth-content .alert.error,
.auth-content .flash.danger,
.auth-content .flash.error {
    color: #7f1d1d !important;
    background: #fee2e2 !important;
    border: 1px solid #fca5a5 !important;
}

html[data-theme="dark"] .auth-content .alert.danger,
html[data-theme="dark"] .auth-content .alert.error,
html[data-theme="dark"] .auth-content .flash.danger,
html[data-theme="dark"] .auth-content .flash.error {
    color: #7f1d1d !important;
    background: #fee2e2 !important;
    border-color: #fca5a5 !important;
}

/* ===== END LOGIN ALERT TEXT FIX ===== */

/* ===== LOGIN TEXT VISIBILITY FIX ===== */

html[data-theme="dark"] .auth-content .login-card,
html[data-theme="dark"] .auth-content .login-card h1,
html[data-theme="dark"] .auth-content .login-card h2,
html[data-theme="dark"] .auth-content .login-card label,
html[data-theme="dark"] .auth-content .login-card .checkbox,
html[data-theme="dark"] .auth-content .login-card .checkbox span {
    color: #f8fafc !important;
}

html[data-theme="dark"] .auth-content .login-card input[type="text"],
html[data-theme="dark"] .auth-content .login-card input[type="password"] {
    color: #f8fafc !important;
    background: #1e293b !important;
    border-color: #3b4a63 !important;
    caret-color: #f8fafc !important;
}

html[data-theme="dark"] .auth-content .login-card input::placeholder {
    color: #94a3b8 !important;
    opacity: 1 !important;
}

html[data-theme="dark"] .auth-content .login-card input[type="checkbox"] {
    accent-color: #2563eb !important;
}

/* ? ??????, ???? data-theme ?? ?????????? */
.auth-content .login-card h1,
.auth-content .login-card h2,
.auth-content .login-card label,
.auth-content .login-card .checkbox,
.auth-content .login-card .checkbox span {
    color: #f8fafc;
}

/* ===== END LOGIN TEXT VISIBILITY FIX ===== */
