﻿* {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    height: 100%;
    font-family: system-ui,-apple-system,Segoe UI,Roboto,Arial,sans-serif;
    background: radial-gradient(circle at top, rgba(59,130,246,0.18), transparent 35%), linear-gradient(180deg,#0f172a 0%,#111827 100%);
    color: #e5e7eb;
}

body {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

/* LOGIN PANEL */

.login-card {
    width: 100%;
    max-width: 700px;
    background: rgba(17,24,39,0.85);
    border: 1px solid rgba(148,163,184,0.2);
    border-radius: 24px;
    padding: 40px;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: 0 30px 90px rgba(0,0,0,0.45), inset 0 1px 0 rgba(255,255,255,0.04);
}

/* HEADER */

.login-header {
    text-align: center;
    margin-bottom: 35px;
}

.login-title {
    margin: 0;
    font-size: 34px;
    font-weight: 700;
    color: #f8fafc;
}

.login-subtitle {
    margin-top: 8px;
    font-size: 17px;
    color: #94a3b8;
}

/* INPUT GRID */

.form-row {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.form-group {
    flex: 1;
    min-width: 220px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/* LABEL */

label {
    font-size: 15px;
    font-weight: 600;
    color: #cbd5e1;
}

/* INPUT */

input {
    height: 60px;
    padding: 0 18px;
    border-radius: 14px;
    border: 1px solid rgba(148,163,184,0.18);
    background: rgba(30,41,59,0.95);
    color: #f8fafc;
    font-size: 18px;
    outline: none;
    transition: border-color .2s, box-shadow .2s;
}

    input::placeholder {
        color: #64748b;
    }

    input:focus {
        border-color: rgba(96,165,250,0.9);
        box-shadow: 0 0 0 4px rgba(59,130,246,0.18);
    }

/* 2FA container */

#totpContainer {
    margin-bottom: 20px;
}

    #totpContainer[hidden] {
        display: none !important;
    }

/* BUTTON */

button {
    width: 100%;
    margin-top:20px;
    height: 64px;
    border: none;
    border-radius: 14px;
    background: linear-gradient(135deg,#2563eb,#3b82f6);
    color: white;
    font-size: 20px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 18px 40px rgba(37,99,235,0.3);
    transition: transform .15s, box-shadow .15s;
}

    button:hover {
        transform: translateY(-1px);
        box-shadow: 0 22px 48px rgba(37,99,235,0.35);
    }

    button:active {
        transform: translateY(0);
    }

/* FOOTER */

.login-footer {
    margin-top: 18px;
    text-align: center;
    font-size: 14px;
    color: #64748b;
}

.login-error {
    background: rgba(220,38,38,0.18);
    border: 1px solid rgba(239,68,68,0.6);
    color: #fecaca;
    padding: 14px 16px;
    border-radius: 12px;
    font-size: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
    animation: errorFade 0.25s ease;
}

    .login-error::before {
        content: "⚠";
        font-size: 16px;
    }

    .login-error.hidden {
        display: none;
    }
@keyframes errorFade {

    from {
        opacity: 0;
        transform: translateY(-6px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}
/* ---------- MOBILE ---------- */

@media (max-width: 600px) {

    body {
        padding: 12px;
    }

    .login-card {
        padding: 24px;
        border-radius: 18px;
    }

    .login-title {
        font-size: 26px;
    }

    .login-subtitle {
        font-size: 15px;
    }

    .form-row {
        flex-direction: column;
        gap: 16px;
    }

    input {
        height: 52px;
        font-size: 16px;
    }

    button {
        height: 56px;
        margin-top:5px;
        font-size: 18px;
    }
}
