/* =============================================================================
   LIS Refertazione — Pagina di accesso (19/11/2026)
   -----------------------------------------------------------------------------
   Stessa impaginazione della pagina di accesso di EndlessMed (stile «Editoriale»
   del 18/11/2026: riquadro a sinistra con le immagini in dissolvenza, modulo a
   destra con titolo grande e campi sottolineati), con i COLORI DEL LIS: il
   riquadro è verde acqua scuro e le immagini sono filtrate in verde acqua.
   Markup in dashboard.js (renderLogin), carosello in dist/login-visual.js.
   Tutto è sotto .lg-page / .lg-modale: il resto del LIS non è toccato.
   Sotto i 900 px il riquadro sparisce e il marchio passa sopra il modulo.
   ============================================================================= */

@font-face { font-family: 'Plus Jakarta Sans'; font-style: normal; font-weight: 400; font-display: swap; src: url('/assets/vendor/plus-jakarta-sans/plus-jakarta-sans-latin-ext-400-normal.woff2') format('woff2'); unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: 'Plus Jakarta Sans'; font-style: normal; font-weight: 400; font-display: swap; src: url('/assets/vendor/plus-jakarta-sans/plus-jakarta-sans-latin-400-normal.woff2') format('woff2'); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: 'Plus Jakarta Sans'; font-style: normal; font-weight: 500; font-display: swap; src: url('/assets/vendor/plus-jakarta-sans/plus-jakarta-sans-latin-ext-500-normal.woff2') format('woff2'); unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: 'Plus Jakarta Sans'; font-style: normal; font-weight: 500; font-display: swap; src: url('/assets/vendor/plus-jakarta-sans/plus-jakarta-sans-latin-500-normal.woff2') format('woff2'); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: 'Plus Jakarta Sans'; font-style: normal; font-weight: 600; font-display: swap; src: url('/assets/vendor/plus-jakarta-sans/plus-jakarta-sans-latin-ext-600-normal.woff2') format('woff2'); unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: 'Plus Jakarta Sans'; font-style: normal; font-weight: 600; font-display: swap; src: url('/assets/vendor/plus-jakarta-sans/plus-jakarta-sans-latin-600-normal.woff2') format('woff2'); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: 'Plus Jakarta Sans'; font-style: normal; font-weight: 700; font-display: swap; src: url('/assets/vendor/plus-jakarta-sans/plus-jakarta-sans-latin-ext-700-normal.woff2') format('woff2'); unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: 'Plus Jakarta Sans'; font-style: normal; font-weight: 700; font-display: swap; src: url('/assets/vendor/plus-jakarta-sans/plus-jakarta-sans-latin-700-normal.woff2') format('woff2'); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: 'Plus Jakarta Sans'; font-style: normal; font-weight: 800; font-display: swap; src: url('/assets/vendor/plus-jakarta-sans/plus-jakarta-sans-latin-ext-800-normal.woff2') format('woff2'); unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: 'Plus Jakarta Sans'; font-style: normal; font-weight: 800; font-display: swap; src: url('/assets/vendor/plus-jakarta-sans/plus-jakarta-sans-latin-800-normal.woff2') format('woff2'); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }

.lg-page, .lg-modale {
    --lg-ink:     #10302d;   /* testo (verde acqua quasi nero, come il blu notte di EM) */
    --lg-ink-2:   #2f4a47;
    --lg-soft:    #557370;
    --lg-muted:   #6b8582;
    --lg-line:    #cfdedc;
    --lg-teal:    #0f766e;   /* primario del LIS */
    --lg-scuro:   #134e4a;   /* fondo del riquadro e del pulsante */
    --lg-filtro:  #0d9488;   /* filtro delle immagini */
    font-family: 'Plus Jakarta Sans', 'Poppins', 'Inter', ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
    color: var(--lg-ink);
    -webkit-font-smoothing: antialiased;
}
.lg-page *, .lg-page *::before, .lg-page *::after,
.lg-modale *, .lg-modale *::before, .lg-modale *::after { box-sizing: border-box; }

.lg-page {
    position: fixed;
    inset: 0;
    overflow-y: auto;
    background: #ffffff;
    display: flex;
    flex-wrap: wrap;
    font-size: 16px;
}
.lg-page a { color: var(--lg-ink); }
.lg-page a:hover { color: var(--lg-teal); }

/* ── Riquadro con le immagini ───────────────────────────────────────────── */
.lg-visual {
    position: relative;
    overflow: hidden;
    flex: 1 1 520px;
    min-width: 0;
    min-height: calc(100vh - 32px);
    margin: 16px;
    border-radius: 32px;
    background: var(--lg-scuro);
    color: #ffffff;
    padding: 56px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 40px;
}
.lg-slides { position: absolute; inset: 0; filter: grayscale(1) contrast(1.08); }
.lg-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transform: scale(1.06);
    transition: opacity 1.4s ease, transform 7s linear;
}
.lg-slide.is-on { opacity: 1; transform: scale(1); }
.lg-slide img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 50% 30%;
}
.lg-filtro { position: absolute; inset: 0; background: var(--lg-filtro); mix-blend-mode: multiply; }
.lg-velo   { position: absolute; inset: 0; background: rgba(4, 32, 30, 0.42); }

.lg-visual__brand, .lg-visual__testo { position: relative; }

.lg-brand { display: flex; align-items: center; gap: 12px; }
.lg-brand__mark {
    width: 44px; height: 44px;
    border-radius: 13px;
    background: #ffffff;
    color: var(--lg-teal);
    display: grid;
    place-items: center;
    flex-shrink: 0;
}
.lg-brand__mark svg { width: 24px; height: 24px; }
.lg-brand__text { display: flex; flex-direction: column; }
.lg-brand__text strong { font-size: 18px; font-weight: 800; }
.lg-brand__text small  { font-size: 12px; color: #c4e4e0; }

.lg-visual__testo { display: flex; flex-direction: column; gap: 24px; }
.lg-visual__titolo {
    margin: 0;
    font-size: 52px;
    line-height: 1.04;
    font-weight: 800;
    letter-spacing: -0.03em;
    max-width: 600px;
    color: #ffffff;
}
.lg-didascalia {
    min-height: 64px;
    display: flex;
    flex-direction: column;
    gap: 3px;
    transition: opacity .6s ease, transform .6s ease;
}
.lg-didascalia.is-off { opacity: 0; transform: translateY(8px); }
.lg-didascalia__area {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #93d3cb;
}
.lg-didascalia__nome { font-size: 19px; font-weight: 800; }
.lg-didascalia__sub  { font-size: 14px; color: #c4e4e0; }

/* ── Colonna del modulo ─────────────────────────────────────────────────── */
.lg-main {
    flex: 1 1 560px;
    min-width: 0;
    padding: 56px 72px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    gap: 48px;
}
.lg-main > .lg-footer { width: 100%; max-width: 420px; }
.lg-main__top {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    min-height: 44px;
}
.lg-main__top .lg-brand { visibility: hidden; }   /* serve solo sotto i 900 px */
.lg-main__top .lg-brand__mark { background: var(--lg-scuro); color: #7fd8cd; }
.lg-main__top .lg-brand__text strong { color: var(--lg-ink); }
.lg-main__top .lg-brand__text small  { color: var(--lg-soft); }

.lg-form {
    width: 100%;
    max-width: 420px;
    display: flex;
    flex-direction: column;
    gap: 26px;
}
.lg-intro { display: flex; flex-direction: column; gap: 12px; }
.lg-eyebrow {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--lg-teal);
}
.lg-titolo {
    margin: 0;
    font-size: 64px;
    line-height: 1;
    font-weight: 800;
    letter-spacing: -0.035em;
    color: var(--lg-ink);
}
.lg-sub { margin: 0; font-size: calc(16px*var(--fs,1)); line-height: 1.5; color: var(--lg-soft); }

.lg-campo {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: calc(13px*var(--fs,1));
    font-weight: 600;
    color: var(--lg-soft);
}
.lg-campo__wrap { position: relative; display: block; }
.lg-page .lg-input, .lg-modale .lg-input {
    width: 100%;
    height: 48px;
    border: 0;
    border-bottom: 2px solid var(--lg-line);
    border-radius: 0;
    background: transparent;
    padding: 0;
    font: inherit;
    font-size: calc(18px*var(--fs,1));
    font-weight: 600;
    color: var(--lg-ink);
    box-shadow: none;
    outline: none;
    transition: border-color .2s;
}
.lg-input::placeholder { color: #9fb6b3; font-weight: 500; }
.lg-page .lg-input:focus, .lg-modale .lg-input:focus { outline: none; border-bottom-color: var(--lg-teal); box-shadow: none; }
.lg-input:disabled { opacity: .6; }
.lg-input--pwd { padding-right: 48px !important; }
.lg-input:-webkit-autofill,
.lg-input:-webkit-autofill:hover,
.lg-input:-webkit-autofill:focus {
    -webkit-text-fill-color: var(--lg-ink);
    -webkit-box-shadow: 0 0 0 1000px #ffffff inset;
    transition: background-color 9999s;
}

.lg-occhio {
    position: absolute;
    right: 0;
    top: 2px;
    width: 44px;
    height: 44px;
    border: 0;
    background: transparent;
    color: var(--lg-soft);
    display: grid;
    place-items: center;
    cursor: pointer;
    border-radius: 10px;
    padding: 0;
}
.lg-occhio svg { width: 20px; height: 20px; }
.lg-occhio svg[hidden] { display: none; }
.lg-occhio:hover { color: var(--lg-ink); }
.lg-occhio:focus-visible { outline: 2px solid var(--lg-teal); outline-offset: -2px; }

.lg-opzioni {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    font-size: calc(14px*var(--fs,1));
}
.lg-opzioni label {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--lg-ink-2);
    min-height: 44px;
    cursor: pointer;
}
.lg-opzioni input[type="checkbox"] { width: 18px; height: 18px; accent-color: var(--lg-teal); margin: 0; }
.lg-opzioni a { font-weight: 600; text-decoration: none; }

.lg-azioni { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.lg-btn {
    position: relative;
    height: 56px;
    padding: 0 36px;
    border: 0;
    border-radius: 999px;
    background: var(--lg-scuro);
    color: #ffffff;
    font: inherit;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: transform .15s, box-shadow .18s, background .18s;
}
.lg-btn svg { width: 18px; height: 18px; }
.lg-btn:hover { background: var(--lg-teal); box-shadow: 0 8px 22px rgba(19, 78, 74, 0.25); transform: translateY(-1px); }
.lg-btn:active { transform: translateY(0); }
.lg-btn:focus-visible { outline: 2px solid var(--lg-teal); outline-offset: 3px; }
.lg-btn:disabled { opacity: 0.6; cursor: default; transform: none; box-shadow: none; }
/* attesa durante l'accesso (auth.js mette .loading) */
.lg-btn .lg-btn__spinner { display: none; }
.lg-btn.loading .lg-btn__testo { visibility: hidden; }
.lg-btn.loading .lg-btn__spinner {
    display: block;
    position: absolute;
    width: 20px; height: 20px;
    border: 2.5px solid rgba(255, 255, 255, .35);
    border-top-color: #ffffff;
    border-radius: 50%;
    animation: lg-gira .7s linear infinite;
}
@keyframes lg-gira { to { transform: rotate(360deg); } }
.lg-btn--chiaro { background: #eef5f4; color: var(--lg-ink); }
.lg-btn--chiaro:hover { background: #e0eeec; color: var(--lg-ink); box-shadow: none; }

/* ── Avvisi (lo stato visibile lo decide auth.js con .visible) ──────────── */
.lg-page .lg-avviso {
    display: none;
    align-items: flex-start;
    gap: 10px;
    border-radius: 14px;
    padding: 14px 16px;
    margin: 0;
    font-size: calc(14px*var(--fs,1));
    line-height: 1.5;
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #b91c1c;
    font-weight: 500;
}
.lg-page .lg-avviso.visible { display: flex; }
.lg-avviso svg { flex-shrink: 0; width: 18px; height: 18px; margin-top: 2px; }

.lg-footer { margin: 0; font-size: 12px; color: var(--lg-muted); }

/* ── Recupera password (finestra sopra la pagina) ───────────────────────── */
.lg-modale {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(8, 36, 34, 0.45);
    align-items: center;
    justify-content: center;
    padding: 16px;
}
.lg-modale__box {
    width: 100%;
    max-width: 440px;
    background: #ffffff;
    border-radius: 28px;
    padding: 32px;
    box-shadow: 0 24px 60px rgba(8, 36, 34, 0.28);
    display: flex;
    flex-direction: column;
    gap: 18px;
}
.lg-modale__titolo { margin: 0; font-size: 30px; line-height: 1.05; font-weight: 800; letter-spacing: -0.03em; color: var(--lg-ink); }
.lg-modale__testo { margin: 0; font-size: calc(15px*var(--fs,1)); line-height: 1.5; color: var(--lg-soft); }
.lg-modale form { display: flex; flex-direction: column; gap: 14px; }
.lg-modale .lg-azioni { justify-content: flex-end; gap: 10px; }
.lg-modale .lg-btn { height: 46px; padding: 0 24px; font-size: 15px; }
#forgot-msg { font-size: calc(13px*var(--fs,1)); }

/* ── Schermi stretti ────────────────────────────────────────────────────── */
@media (max-width: 1180px) {
    .lg-main { padding: 48px 48px; }
    .lg-visual__titolo { font-size: 44px; }
}
@media (max-width: 900px) {
    .lg-visual { display: none; }
    .lg-main { min-height: 100vh; padding: 28px 20px 32px; }
    .lg-main__top .lg-brand { visibility: visible; }
    .lg-titolo { font-size: 48px; }
}
@media (prefers-reduced-motion: reduce) {
    .lg-slide, .lg-didascalia, .lg-btn { transition: none; transform: none; }
}
