/* Rendu normalise d'une page d'aide : capture a gauche, legende numerotee a droite. */

/* Hauteur du splitter du composant Helppage.
   L'offset represente ce qui occupe la fenetre autour du splitter : bandeau, favoris,
   pied de page, barre de boutons. Il varie donc selon le contexte de rendu, d'ou la variable :
   310px dans l'application complete, une valeur bien plus faible dans l'onglet d'aide dedie,
   ou seuls la barre de boutons et le trait de separation sont au-dessus. */
.helppage-split {
    height: calc(100vh - var(--helppage-offset, 310px));
}

.helpshot {
    display: flex;
    gap: 24px;
    align-items: flex-start;
    flex-wrap: wrap;
}

.helpshot__img {
    position: relative;
    flex: 1 1 420px;
    min-width: 320px;
    line-height: 0;
}

.helpshot__img img {
    width: 100%;
    height: auto;
    border: 1px solid #ccc;
    border-radius: 6px;
    display: block;
}

.helpshot__legend {
    flex: 1 1 320px;
    min-width: 280px;
    margin: 0;
    padding: 0;
    list-style: none;
    counter-reset: helpshot;
    font-size: 15px;
    line-height: 1.45;
}

.helpshot__legend li {
    counter-increment: helpshot;
    position: relative;
    padding-left: 34px;
    margin-bottom: 12px;
}

.helpshot__legend li::before {
    content: counter(helpshot);
    position: absolute;
    left: 0;
    top: 0;
}

.helpshot__legend li::before,
.helpshot-pin {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #003366;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    line-height: 1;
}

.helpshot__legend li strong {
    display: block;
}

.helpshot__legend li span {
    color: #555;
}

/* Pastille posee sur la capture. Le decalage recentre la pastille sur le point clique. */
.helpshot-pin {
    position: absolute;
    transform: translate(-50%, -50%);
    box-shadow: 0 0 0 2px #fff;
    cursor: pointer;
    z-index: 2;
}

.helpshot-pin--selected {
    background: #c0392b;
    box-shadow: 0 0 0 2px #fff, 0 0 0 4px #c0392b;
}

/* Mode edition */

.helpshot-edit__drop {
    border: 2px dashed #b0b8c4;
    border-radius: 6px;
    padding: 28px 16px;
    text-align: center;
    color: #667;
    background: #f7f9fb;
    outline: none;
    cursor: text;
}

.helpshot-edit__drop:focus {
    border-color: #003366;
    background: #eef3f8;
}

.helpshot-edit__img {
    cursor: crosshair;
}

.helpshot-edit__hint {
    font-size: 13px;
    color: #667;
    margin: 6px 0 12px 0;
}

.helpshot-edit table {
    width: 100%;
    font-size: 14px;
    border-collapse: collapse;
}

/* Mode recadrage : calque de selection pose au-dessus de l'image */

.helpshot-crop-overlay {
    position: absolute;
    inset: 0;
    cursor: crosshair;
    /* Transparent : l'assombrissement vient de l'ombre inversee du rectangle, sinon la zone
       conservee serait grisee elle aussi, le calque la recouvrant. */
    background: transparent;
    z-index: 5;
    user-select: none;
}

.helpshot-crop-rect {
    position: absolute;
    border: 1px dashed #fff;
    /* La zone conservee est eclaircie par une ombre inversee : pas de second calque a gerer. */
    box-shadow: 0 0 0 9999px rgba(0, 0, 0, .45);
    background: transparent;
}

.helpshot-edit__crop-bar {
    display: flex;
    gap: 8px;
    align-items: center;
    margin: 8px 0;
}

.helpshot-edit__xy {
    width: 64px;
}

.helpshot-edit table td,
.helpshot-edit table th {
    padding: 4px 6px;
    border-bottom: 1px solid #e5e8ec;
    vertical-align: middle;
}

.helpshot-edit table th {
    text-align: left;
    font-weight: 600;
    color: #445;
}

.helpshot-edit__num {
    width: 34px;
}

.helpshot-edit__act {
    width: 110px;
    white-space: nowrap;
}
