/* ============================================================
   arCO2 — custom application styles
   Tutti gli stili "ls-*" del design Lineasoft sono raccolti qui.
   ============================================================ */

/* ------------------------------------------------------------
   Helpers generici
   ------------------------------------------------------------ */
.ls-hint { font-size: 12px; color: #6c757d; font-weight: 400; }
.ls-mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; color: #6c757d; }
.ls-dot {
    display: inline-block; width: 4px; height: 4px; border-radius: 50%;
    background: #adb5bd; margin: 0 8px; vertical-align: middle;
}

/* Asterisco sui label obbligatori (se non già definito altrove) */
.form-label.mandatory::after {
    content: " *";
    color: #dc3545;
    font-weight: 700;
}


/* ============================================================
   Form sections — banda grigia con bordo come "tab" della sezione.
   Sostituisce il vecchio <fieldset class="border ...">.
   ------------------------------------------------------------ */
.ls-section { margin-bottom: 48px; }
.ls-section:last-child { margin-bottom: 0; }

.ls-section-head {
    margin: 0 0 20px;
    padding: 12px 16px;
    background: #f1f1f1;
    border: 1px solid #dee2e6;
    border-radius: .375rem;
}

.ls-section-title {
    display: inline;
    font-size: 15px;
    font-weight: 600;
    color: #212529;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.ls-section-hint {
    display: block;
    margin-top: 4px;
    font-size: 12px;
    color: #6c757d;
    font-weight: 400;
    text-transform: none;
    letter-spacing: 0;
}


/* ============================================================
   Form tabs — navigatore sopra il form
   ------------------------------------------------------------ */
.ls-form-tabs { border-bottom: 1px solid #dee2e6; margin-bottom: 0; }
.ls-form-tabs .nav-link {
    font-size: 14px; font-weight: 500;
    color: #495057; border: 0;
    border-bottom: 2px solid transparent;
    border-radius: 0; padding: 10px 16px;
	background: transparent;
}
.ls-form-tabs .nav-link:hover { color: #188ae2; background: transparent; }
.ls-form-tabs .nav-link.active {
    color: #188ae2; 
	border-bottom-color: #188ae2; 
	background: transparent;
}






.ls-tab-count { color: #adb5bd; font-weight: 400; }

/* Card sotto i tabs: niente bordo top per non duplicare la regola dei tabs */
.ls-form-card { border: 1px solid #dee2e6; border-top: 0; box-shadow: 0 1px 2px rgba(0,0,0,.04); }


/* ============================================================
   Form mode badge (in header)
   ------------------------------------------------------------ */
.ls-form-mode-badge {
    display: inline-flex; align-items: center;
    font-size: 11px; font-weight: 600;
    padding: 3px 8px; border-radius: 50rem;
    text-transform: uppercase; letter-spacing: .04em;
}
.ls-form-mode-edit { background: #fff3cd; color: #664d03; }
.ls-form-mode-view { background: #e9ecef; color: #495057; }


/* ============================================================
   Form header (titolo + codice + città)
   ------------------------------------------------------------ */
.ls-form-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 1rem;
}
.ls-form-header-left { min-width: 0; }
.ls-form-header-meta {
    display: flex; align-items: center; flex-wrap: wrap;
    margin-top: 4px;
    color: #6c757d; font-size: 13px;
}
.ls-form-header-right { display: flex; gap: 8px; }


/* ============================================================
   DOSSIER DASHBOARD — flussi & moduli (precedentemente inline
   in dashboard.html, ora centralizzati qui).
   ------------------------------------------------------------ */

/* --- Summary card --- */
.ls-summary {
    border-left: 3px solid #dee2e6;
    padding: 2px 0 2px 12px;
}
.ls-summary-label {
    font-size: 11px; color: #6c757d;
    text-transform: uppercase; letter-spacing: .04em;
    font-weight: 600; margin-bottom: 2px;
}
.ls-summary-value { font-size: 14px; font-weight: 500; color: #212529; }

/* --- Flussi pills --- */
.ls-flussi-pills .nav-link {
    background: #fff;
    border: 1px solid #dee2e6;
    border-radius: .375rem;
    font-size: 14px; font-weight: 500;
    padding: 8px 14px; margin-right: 8px;
}
.ls-flussi-pills .nav-link.active { color: #fff !important; }
.ls-flusso-count {
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 12px; opacity: .85;
}

/* --- Flusso header --- */
.ls-flusso-head { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; }
.ls-flusso-icon {
    width: 36px; height: 36px; border-radius: 8px;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 16px;
}
.ls-flusso-title b { display: block; font-size: 15px; font-weight: 600; }
.ls-flusso-title span { font-size: 12px; color: #6c757d; }
.ls-flusso-bar {
    flex: 1; max-width: 280px; margin-left: auto;
    height: 6px; border-radius: 50rem;
    background: #f1f3f5; overflow: hidden;
}
.ls-flusso-bar-fill { height: 100%; transition: width .25s ease; }

/* --- Track moduli --- */
.ls-track {
    display: flex; align-items: stretch; gap: 0;
    overflow-x: auto; padding: 4px 2px 12px;
}
.ls-track-link {
    flex: 0 0 24px; height: 2px;
    background: #dee2e6; align-self: center; margin: 0 -1px;
}

/* --- Modulo node --- */
.ls-mod {
    flex: 0 0 168px;
    background: #fff;
    border: 1px solid #dee2e6;
    border-radius: .375rem;
    padding: 10px 12px;
    text-align: left;
    cursor: pointer;
    display: flex; flex-direction: column; gap: 8px;
    min-height: 96px;
    transition: transform .12s, border-color .12s, box-shadow .12s;
}
.ls-mod:hover { transform: translateY(-1px); border-color: #adb5bd; }
.ls-mod-head { display: flex; align-items: flex-start; gap: 8px; }
.ls-mod-num {
    flex: 0 0 24px; width: 24px; height: 24px; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 11px; font-weight: 600;
    background: #f1f3f5; color: #6c757d;
    border: 1px solid #dee2e6;
}
.ls-mod-label { font-size: 12px; line-height: 1.3; color: #212529; font-weight: 500; }
.ls-mod-foot { margin-top: auto; }
.ls-mod-locked { opacity: .55; }
.ls-mod-locked .ls-mod-num { background: #e9ecef; color: #adb5bd; }
.ls-mod-active { border-color: #0d6efd; box-shadow: 0 0 0 2px rgba(13,110,253,.10); }
.ls-mod-active .ls-mod-num { background: #0d6efd; color: #fff; border-color: #0d6efd; }
.ls-mod-done .ls-mod-label { color: #6c757d; }

/* --- Status pills --- */
.ls-status-pill {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 3px 10px; border-radius: 50rem;
    font-size: 12px; font-weight: 500;
}
.ls-status-pill::before {
    content: ""; width: 6px; height: 6px; border-radius: 50%;
    background: currentColor; opacity: .55;
}
.ls-status-active { background: #cfe2ff; color: #084298; }
.ls-status-done   { background: #d1e7dd; color: #0f5132; }
.ls-status-draft  { background: #f1f3f5; color: #6c757d; }
.ls-status-locked { background: #f1f3f5; color: #6c757d; }

/* --- Modulo detail meta --- */
.ls-mod-meta .ls-summary-label {
    font-size: 11px; color: #6c757d;
    text-transform: uppercase; letter-spacing: .04em;
    font-weight: 600; margin-bottom: 4px;
}
.ls-mod-meta .ls-summary-value { font-size: 14px; font-weight: 500; color: #212529; }
