/* Centro Aiuto (Pages/Help). Componenti Metronic 7, qui solo gli aggiustamenti. */

/* Hero con illustrazione a destra (stesso schema delle card della home) */
.help-hero {
    background-position: right 2rem center;
    background-size: auto 85%;
}

.help-hero-text {
    max-width: 60%;
}

/* Filtro area: pulsanti con lo stile dei nav-pills */
.help-hero .nav-link {
    border: 0;
    background-color: transparent;
    cursor: pointer;
}

.help-hero .nav-link[data-help-area="educativo"].active {
    background-color: #b4cc04;
    color: #fff;
}

.help-hero .nav-link[data-help-area="assistenza"].active {
    background-color: #F64E60;
    color: #fff;
}

.help-label-education {
    background-color: rgba(180, 204, 4, 0.15) !important;
    color: #8a9c03 !important;
}

/* Card argomento */
.help-category-card {
    transition: box-shadow 0.15s ease, transform 0.15s ease;
}

.help-category-card:hover,
.help-category-card:focus {
    box-shadow: 0 0.5rem 1.5rem rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
    text-decoration: none;
}

/* Ricerca nell'header della pagina, a destra del titolo */
.help-header-search {
    width: min(440px, calc(100vw - 50px));
}

.help-header-search .input-group-solid .form-control,
.help-header-search .input-group-solid .input-group-text {
    background-color: #fff;
}

/* Indice laterale fisso durante lo scroll (solo desktop; su mobile sta sopra le domande) */
@media (min-width: 992px) {
    .help-toc {
        position: sticky;
        top: 100px;
    }
}

/* Le sezioni lasciano spazio all'header fisso quando ci si arriva da un'ancora */
.help-category,
.help-article,
.help-answer [id] {
    scroll-margin-top: 100px;
}

/* Titolo della domanda: e' un <button>, va azzerato lo stile del browser */
.help-article-toggle {
    width: 100%;
    background: none;
    border: 0;
    padding-left: 0;
    padding-right: 0;
    text-align: left;
    cursor: pointer;
}

.help-article-heading {
    font-size: inherit;
    font-weight: inherit;
}

.help-article-toggle:focus {
    outline: none;
}

.help-article-toggle:focus-visible {
    outline: 2px solid #3699FF;
    outline-offset: 2px;
    border-radius: 0.42rem;
}

.help-article-title {
    font-size: 1.15rem;
}

.help-article-title mark {
    padding: 0 0.1em;
    background-color: #FFF4DE;
    color: inherit;
}

/* Contenuto Markdown */
.help-answer h2 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-top: 1.75rem;
    margin-bottom: 0.75rem;
}

.help-answer h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
}

.help-answer blockquote {
    margin: 1.25rem 0;
    padding: 0.75rem 1.25rem;
    border-left: 4px solid #3699FF;
    background-color: #F3F6F9;
    border-radius: 0.42rem;
}

.help-answer blockquote p:last-child {
    margin-bottom: 0;
}

.help-answer table {
    width: 100%;
    margin-bottom: 1rem;
}

.help-answer th,
.help-answer td {
    padding: 0.5rem 0.75rem;
    border: 1px solid #EBEDF3;
}

.help-answer li {
    margin-bottom: 0.35rem;
}

.help-answer li > p {
    margin-bottom: 0.5rem;
}

/* Screenshot: larghezza massima dal Markdown ({width=...}), mai oltre la colonna; clic per ingrandire */
.help-image {
    display: block;
    height: auto;
    max-width: 100%;
    cursor: zoom-in;
}

.help-image:focus-visible {
    outline: 2px solid #3699FF;
    outline-offset: 2px;
}

.help-empty-illustration {
    width: 180px;
    max-width: 50%;
}

.help-search-status:empty {
    display: none;
}

#help-image-modal-img {
    max-height: 80vh;
}

@media (max-width: 991.98px) {
    .help-hero {
        background-image: none !important;
    }

    .help-hero-text {
        max-width: 100%;
    }

    .help-answer {
        padding-left: 0 !important;
    }
}
