/* =========================================================
   Lo On Shing — habillage de l'authentification
   Écran de connexion, définition d'accès, bandeaux de session.
   ========================================================= */

/* ---------- bandeaux ---------- */
.auth-open-note {
    max-width: 1100px;
    margin: 1.6rem auto 0;
    padding: 0.9rem 1.2rem;
    border: 1px solid #f0c48a;
    border-left: 4px solid var(--brand-orange, #e67e22);
    border-radius: 6px;
    background: #fff7ef;
    color: #6b4a22;
    font-size: 0.9rem;
    line-height: 1.55;
}
.auth-open-note code {
    background: rgba(13, 68, 148, 0.07);
    padding: 0.05rem 0.3rem;
    border-radius: 3px;
    font-size: 0.86em;
}

.auth-session-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.5rem 1.2rem;
    background: var(--brand-primary-darker, #092f66);
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.84rem;
}
.auth-session-bar strong { color: #fff; }

/* ---------- écran de connexion ---------- */
body.auth-locked { overflow: hidden; }
.auth-screen {
    position: fixed;
    inset: 0;
    z-index: 4000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    background:
        linear-gradient(rgba(9, 47, 102, 0.93), rgba(9, 47, 102, 0.95)),
        url('../images/company-formation-asia-foreign-direct-investment.webp') center/cover;
}

.auth-card {
    width: 100%;
    max-width: 440px;
    background: #fff;
    border-radius: 10px;
    border-top: 4px solid var(--brand-orange, #e67e22);
    box-shadow: 0 24px 60px rgba(5, 25, 55, 0.35);
    padding: 2rem 2.1rem 2.2rem;
}
.auth-card.auth-flat {
    max-width: 620px;
    margin: 0 auto;
    box-shadow: 0 12px 30px rgba(9, 47, 102, 0.10);
}
.auth-card h2 {
    margin: 0 0 0.4rem;
    font-family: var(--font-display, Georgia, serif);
    color: var(--brand-primary-darker, #092f66);
    font-size: 1.5rem;
}
.auth-card h3 {
    margin: 1.6rem 0 0.6rem;
    font-size: 0.94rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--brand-primary-dark, #0d4494);
}
.auth-sub {
    margin: 0 0 1.2rem;
    font-size: 0.9rem;
    line-height: 1.6;
    color: var(--text-muted, #5b6675);
}
.auth-card label {
    display: block;
    margin: 0.9rem 0 0.3rem;
    font-size: 0.84rem;
    font-weight: 700;
    color: var(--brand-primary-darker, #092f66);
}
.auth-card input[type="email"],
.auth-card input[type="password"],
.auth-card input[type="text"] {
    width: 100%;
    padding: 0.7rem 0.85rem;
    border: 1px solid var(--bg-border, #d8dee7);
    border-radius: 6px;
    font-size: 0.95rem;
    font-family: inherit;
}
.auth-card input:focus {
    outline: none;
    border-color: var(--brand-primary, #1a55a8);
    box-shadow: 0 0 0 3px rgba(26, 85, 168, 0.15);
}
.auth-card .btn { width: 100%; margin-top: 1.3rem; }

.auth-link {
    display: inline-block;
    margin-top: 0.8rem;
    padding: 0;
    background: none;
    border: 0;
    color: var(--brand-primary, #1a55a8);
    font: inherit;
    font-size: 0.86rem;
    text-decoration: underline;
    cursor: pointer;
}
.auth-check {
    display: flex !important;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1rem !important;
    font-weight: 400 !important;
    font-size: 0.86rem !important;
    color: var(--text-muted, #5b6675) !important;
}
.auth-error {
    margin: 0.9rem 0 0;
    padding: 0.6rem 0.8rem;
    border-radius: 5px;
    background: #fdecea;
    border-left: 3px solid #c0392b;
    color: #8c2d22;
    font-size: 0.85rem;
}
.auth-demo {
    margin: 0.8rem 0 0;
    padding: 0.6rem 0.8rem;
    border-radius: 5px;
    background: #f4f8fd;
    border-left: 3px solid var(--brand-primary, #1a55a8);
    font-size: 0.82rem;
    color: #45536a;
}
.auth-demo b { font-size: 1.05rem; letter-spacing: 0.14em; color: #092f66; }
.auth-hint { font-size: 0.82rem; color: var(--text-muted, #5b6675); margin: 0.5rem 0 0; }

/* ---------- définition d'accès ---------- */
.auth-count {
    display: inline-block;
    margin-bottom: 1rem;
    padding: 0.35rem 0.8rem;
    border-radius: 999px;
    background: #fff7ef;
    border: 1px solid #f0c48a;
    font-size: 0.82rem;
    color: #8a5a1c;
}
.auth-count b { color: #c75e0a; }

.auth-rules {
    margin: 0.6rem 0 0;
    padding-left: 1.1rem;
    font-size: 0.83rem;
    color: #8c5a52;
}
.auth-rules.is-ok { color: #1e7a4c; list-style: none; padding-left: 0; }
.auth-rules li { margin-bottom: 0.2rem; }

.auth-choice { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.auth-opt {
    padding: 0.55rem 0.95rem;
    border: 1px solid var(--bg-border, #d8dee7);
    border-radius: 999px;
    background: #fff;
    font: inherit;
    font-size: 0.86rem;
    cursor: pointer;
    transition: all 0.15s ease;
}
.auth-opt:hover { border-color: var(--brand-primary, #1a55a8); }
.auth-opt.is-on {
    background: var(--brand-primary-dark, #0d4494);
    border-color: var(--brand-primary-dark, #0d4494);
    color: #fff;
    font-weight: 700;
}
.auth-factor { margin-top: 1rem; }
.auth-secret {
    margin: 0.6rem 0;
    padding: 0.8rem 1rem;
    border-radius: 6px;
    background: #f4f8fd;
    border: 1px dashed #b7cbe6;
    font-family: "Courier New", monospace;
    font-size: 1.02rem;
    letter-spacing: 0.12em;
    color: #092f66;
    word-break: break-all;
}

/* ---------- état d'invitation dans la console ---------- */
.ag-inv {
    display: inline-block;
    padding: 0.15rem 0.55rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.03em;
}
.ag-inv.pending { background: #fff3e0; color: #9a5b12; }
.ag-inv.used    { background: #e6f5ec; color: #1e7a4c; }
.ag-inv.expired { background: #fdecea; color: #99332a; }
.ag-inv.none    { background: #eef1f5; color: #64748b; }

@media (max-width: 560px) {
    .auth-card { padding: 1.5rem 1.3rem 1.7rem; }
}
