﻿/* =========================================================
   login.css - stile Login (responsive)
   Tema aggiornato: BLU InventoryOne
   ========================================================= */

:root {
    --font: "Segoe UI", Arial, sans-serif;
    --bg: #eef5ff;
    --card: #ffffff;
    --text: #1f2328;
    --muted: rgba(31, 35, 40, 0.65);
    /* tema blu InventoryOne */
    --primary: var(--inventory-blue, #1861b2);
    --primary-hover: var(--inventory-blue-hover, #0f4f9d);
    --focus: var(--inventory-blue, #1861b2);
    --focus-glow: var(--inventory-blue-focus-light, rgba(24, 97, 178, 0.32));
    --border: rgba(0, 0, 0, 0.10);
    --shadow: 0 12px 30px rgba(0, 0, 0, 0.10);
    --radius: 18px;
    --avatar-bg: #eef5ff;
    --avatar-border: rgba(24, 97, 178, 0.12);
    --txt-border: #cfdcf0;
}

/* =========================================================
   BASE
   ========================================================= */
html,
body {
    height: 100%;
}

    body.login-page {
        margin: 0;
        font-family: var(--font);
        background: var(--bg);
    }

/* =========================================================
   WRAPPER
   ========================================================= */
.login-bg {
    min-height: calc(100vh - 36px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 18px;
    box-sizing: border-box;
}

/* =========================================================
   CARD
   ========================================================= */
.login-card {
    width: 380px;
    max-width: 94vw;
    background: var(--card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 28px 24px 22px;
    text-align: center;
    position: relative;
}

/* =========================================================
   AVATAR
   ========================================================= */
.login-avatar {
    width: 92px;
    height: 92px;
    border-radius: 50%;
    background: var(--avatar-bg);
    border: 1px solid var(--avatar-border);
    margin: -58px auto 12px;
    box-shadow: 0 10px 18px rgba(0, 0, 0, 0.12);
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-avatar-img {
    width: 64px;
    height: 64px;
    display: block;
}

/* =========================================================
   TITLE
   ========================================================= */
.login-title {
    font-weight: 800;
    letter-spacing: 0.4px;
    color: var(--text);
    margin: 10px 0 18px;
}

/* =========================================================
   FIELDS
   ========================================================= */
.login-field {
    margin: 12px 0;
}

/* =========================================================
   BUTTON LOGIN
   ========================================================= */
.login-btn {
    width: 100%;
    height: 44px;
    border-radius: 20px;
    margin-top: 8px;
    font-weight: 700;
}

/* =========================================================
   ROW
   ========================================================= */
.login-row {
    margin-top: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    font-size: 13px;
    color: var(--muted);
}

.login-remember {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.login-link {
    text-decoration: none;
    color: var(--primary);
}

    .login-link:hover {
        text-decoration: underline;
        color: var(--primary-hover);
    }

/* =========================================================
   FORGOT DIALOG INTERNAL LAYOUT
   ========================================================= */
.forgot-wrap {
    padding: 6px 2px;
    text-align: left;
}

.forgot-title {
    font-weight: 700;
    margin-bottom: 6px;
    color: var(--text);
}

.forgot-text {
    margin-bottom: 14px;
    color: var(--muted);
}

.forgot-actions {
    display: flex;
    justify-content: flex-end;
    gap: 5px;
    margin-top: 12px;
}

.login-btn-small {
    min-width: 120px;
    height: 40px;
    border-radius: 20px;
}

.login-btn-secondary {
    background: rgba(0, 0, 0, 0.06);
}

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 420px) {
    .login-card {
        padding: 24px 18px 18px;
    }

    .login-avatar {
        width: 82px;
        height: 82px;
        margin-top: -52px;
    }

    .login-avatar-img {
        width: 56px;
        height: 56px;
    }

    .login-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .forgot-actions {
        flex-direction: column;
    }

    .login-btn-small {
        width: 100%;
    }
}

/* =========================================================
   CAMPO TESTO LOGIN
   Nota: resta locale alla login per mantenere il bordo
   leggermente personalizzato rispetto al globale
   ========================================================= */
.txt {
    width: 100%;
    box-sizing: border-box;
    border: 1px solid var(--txt-border);
    border-radius: 10px;
    padding: 10px 12px;
    font-size: 14px;
    outline: none;
    transition: border-color .15s ease, box-shadow .15s ease, background-color .15s ease;
    background: #fff;
    color: inherit;
}

    .txt:focus,
    .txt:focus-visible {
        border-color: var(--focus);
        box-shadow: 0 0 0 0.25rem var(--focus-glow);
    }
