:root {
    --guide-accent: var(--medeed-blue, var(--dis-blue, #4299e1));
}

.page-guide-tools {
    box-sizing: border-box;
    position: fixed;
    bottom: 1rem;
    inset-inline-end: 1rem;
    z-index: 1040;
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    align-items: center;
    max-width: calc(100vw - 2rem);
    padding: 0.65rem;
    background: var(--tblr-bg-surface, #fff);
    border: 1px solid var(--tblr-border-color, #dce1e7);
    box-shadow: 0 0.2rem 1rem #0001;
}

.page-guide-feedback {
    font-size: 0.8rem;
    color: var(--tblr-secondary, #626976);
    max-width: 20rem;
}

.portal-body:has(.portal-footer) .page-guide-tools {
    bottom: 4.25rem;
}

.account-guide-sidebar {
    position: fixed;
    inset-inline-start: 1rem;
    top: 1rem;
    z-index: 1040;
    background: var(--tblr-bg-surface, #fff);
    border: 1px solid var(--tblr-border-color, #dce1e7);
    padding: 0.5rem;
}

.portal-body > .page.interessent-page {
    margin-left: var(--medeed-sidebar-width);
}

@media (max-width: 991.98px) {
    .portal-body > .page.interessent-page {
        margin-left: 0;
    }
}

.guide-shade {
    position: fixed;
    z-index: 1200;
    background: #11182799;
    pointer-events: auto;
}

.guide-outline {
    position: fixed;
    z-index: 1201;
    border: 3px solid var(--guide-accent);
    pointer-events: none;
    box-shadow: 0 0 0 3px #fff9;
}

.guide-dialog {
    box-sizing: border-box;
    position: fixed;
    z-index: 1202;
    width: min(26rem, calc(100vw - 2rem));
    max-height: calc(100dvh - 2rem);
    overflow: auto;
    padding: 1.25rem;
    background: var(--tblr-bg-surface, #fff);
    color: var(--tblr-body-color, #182433);
    border: 1px solid var(--tblr-border-color, #dce1e7);
    box-shadow: 0 0.6rem 2.5rem #0003;
    text-align: start;
    font: inherit;
}

.guide-dialog:focus {
    outline: 2px solid var(--guide-accent);
}

.guide-dialog h2 {
    font-size: 1.15rem;
    margin: 0.45rem 0 0.6rem;
}

.guide-dialog p {
    line-height: 1.65;
}

.guide-actions {
    display: flex;
    gap: 0.5rem;
    justify-content: space-between;
    flex-wrap: wrap;
    margin-top: 1rem;
}

.guide-counter {
    font-size: 0.8rem;
    color: var(--tblr-secondary, #626976);
}

.guide-article {
    max-width: 66rem;
    margin-inline: auto;
    padding-bottom: 5rem;
}

.guide-center {
    padding-bottom: 5rem;
}

.guide-article p {
    line-height: 1.85;
}

.guide-article section {
    scroll-margin-top: 5rem;
}

.guide-center[dir="rtl"] {
    text-align: right;
}

.guide-center input,
.guide-center select {
    min-width: 0;
}

.guide-topic .card {
    border-color: var(--tblr-border-color, #dce1e7);
}

.guide-dialog [disabled] {
    opacity: 0.55;
}

@media (max-width: 575.98px) {
    .account-guide-sidebar {
        position: relative;
        inset-inline-start: 0;
        top: 0;
        margin: 1rem;
        width: fit-content;
    }

    .page-guide-tools {
        bottom: 0.5rem;
        inset-inline-end: 0.5rem;
        padding: 0.45rem;
        gap: 0.35rem;
    }

    .portal-body:has(.portal-footer) .page-guide-tools {
        bottom: 6.5rem;
    }

    .page-guide-tools .btn {
        font-size: 0.75rem;
    }

    .guide-dialog {
        padding: 1rem;
    }
}

@media print {
    .page-guide-tools,
    .guide-dialog,
    .guide-shade,
    .guide-outline {
        display: none !important;
    }
}

@media (prefers-reduced-motion: reduce) {
    .guide-dialog,
    .guide-outline {
        transition: none;
    }
}
