/** Local help popup and scrolling menu button. Author: Rolf-Peter Blümlein. Version: 1.4.19. */

.coloring-app .paint-help-toggle {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    padding: 6px;
    border: 1px solid #181713;
    border-radius: .4rem;
    background: #cdaa8e;
    color: #181713;
    cursor: pointer;
}

.coloring-app .paint-help-toggle[hidden] { display: none; }
/* Normal flow, not a separate title bar: this button scrolls out with the tools. */
.coloring-app .paint-tools > .paint-help-toggle { margin: 0 0 .5rem auto; }
.coloring-app .paint-help-toggle:hover { background: #181713; color: #fff; }
.coloring-app .paint-help-toggle:focus-visible,
.coloring-app .paint-help-close:focus-visible { outline: 2px solid #d7aa84; outline-offset: 2px; }

/* Native top-layer help stays outside the toolbar's inverse page-zoom transform;
   it is never appended to or installed inside the site's template. */
.coloring-app .paint-help-dialog {
    box-sizing: border-box;
    width: min(42rem, calc(100vw - 2rem));
    max-width: calc(100vw - 2rem);
    max-height: calc(100vh - 2rem);
    max-height: calc(100dvh - 2rem);
    margin: auto;
    padding: 0;
    border: 1px solid #181713;
    border-radius: .75rem;
    background: #fff;
    color: #172033;
    font: inherit;
    line-height: 1.5;
    overflow: auto;
    overscroll-behavior: contain;
}

.coloring-app .paint-help-dialog::backdrop { background: rgb(0 0 0 / 38%); }
.coloring-app .paint-help-header {
    position: sticky;
    top: 0;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.25rem;
    background: #fff;
    border-bottom: 1px solid #d7aa84;
}
.coloring-app .paint-help-header h2 { margin: 0; font-size: 1.25rem; }
.coloring-app .paint-help-close {
    flex: 0 0 auto;
    min-height: 40px;
    padding: .35rem .65rem;
    border: 1px solid #181713;
    border-radius: .4rem;
    background: #cdaa8e;
    color: #181713;
    font: inherit;
    cursor: pointer;
}
.coloring-app .paint-help-content { padding: .5rem 1.25rem 1.25rem; }
.coloring-app .paint-help-content h3 { margin: .75rem 0 .5rem; font-size: 1.05rem; }
.coloring-app .paint-help-content p { margin: .5rem 0 .75rem; }
@media (pointer: coarse) {
    .coloring-app .paint-help-toggle { width: 44px; height: 44px; }
}
