.rotivox-help-trigger {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.125rem;
    height: 1.125rem;
    padding: 0;
    border: none;
    background: transparent;
    color: #64748b;
    cursor: pointer;
    line-height: 1;
    vertical-align: middle;
    flex-shrink: 0;
    border-radius: 9999px;
    transition: color 0.15s ease, background-color 0.15s ease;
}

.rotivox-help-trigger:hover,
.rotivox-help-trigger:focus-visible {
    color: #2563eb;
    background-color: #eff6ff;
    outline: none;
}

.rotivox-help-trigger i {
    font-size: 0.875rem;
}

.rotivox-help-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    z-index: 10050;
}

.rotivox-help-panel {
    position: fixed;
    z-index: 10060;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 0.75rem;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.18);
    max-width: min(22rem, calc(100vw - 2rem));
    width: 100%;
    color: #0f172a;
}

.rotivox-help-panel.is-popover {
    width: min(22rem, calc(100vw - 2rem));
}

.rotivox-help-panel.is-dialog {
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    max-width: min(28rem, calc(100vw - 1.5rem));
    max-height: calc(100vh - 2rem);
    display: flex;
    flex-direction: column;
}

.rotivox-help-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.875rem 1rem 0.625rem;
    border-bottom: 1px solid #f1f5f9;
}

.rotivox-help-title {
    font-size: 0.95rem;
    font-weight: 600;
    margin: 0;
}

.rotivox-help-close {
    border: none;
    background: transparent;
    color: #64748b;
    cursor: pointer;
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 0.375rem;
}

.rotivox-help-close:hover,
.rotivox-help-close:focus-visible {
    color: #0f172a;
    background: #f1f5f9;
    outline: none;
}

.rotivox-help-body {
    padding: 0.75rem 1rem 1rem;
    overflow-y: auto;
}

.rotivox-help-short {
    font-size: 0.875rem;
    color: #334155;
    margin: 0 0 0.5rem;
}

.rotivox-help-section {
    margin-top: 0.625rem;
}

.rotivox-help-section-title {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #64748b;
    margin: 0 0 0.25rem;
}

.rotivox-help-section-text {
    font-size: 0.8125rem;
    color: #475569;
    margin: 0;
    white-space: pre-wrap;
}

.rotivox-help-warning {
    margin-top: 0.625rem;
    padding: 0.5rem 0.625rem;
    border-radius: 0.5rem;
    background: #fff7ed;
    border: 1px solid #fed7aa;
    color: #9a3412;
    font-size: 0.8125rem;
}

.rotivox-help-more-toggle {
    margin-top: 0.5rem;
    border: none;
    background: transparent;
    color: #2563eb;
    font-size: 0.8125rem;
    font-weight: 600;
    cursor: pointer;
    padding: 0;
}

.rotivox-help-more-toggle:hover,
.rotivox-help-more-toggle:focus-visible {
    text-decoration: underline;
    outline: none;
}

.rotivox-help-related {
    margin-top: 0.75rem;
    padding-top: 0.625rem;
    border-top: 1px solid #f1f5f9;
}

.rotivox-help-related-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.375rem;
    margin: 0.375rem 0 0;
    padding: 0;
    list-style: none;
}

.rotivox-help-related-list button {
    border: 1px solid #cbd5e1;
    background: #f8fafc;
    color: #334155;
    border-radius: 9999px;
    font-size: 0.75rem;
    padding: 0.125rem 0.5rem;
    cursor: pointer;
}

.rotivox-help-related-list button:hover,
.rotivox-help-related-list button:focus-visible {
    border-color: #93c5fd;
    color: #1d4ed8;
    outline: none;
}

.rotivox-help-missing-dev {
    border-color: #fca5a5;
    background: #fef2f2;
}

@media (max-width: 767px) {
    .rotivox-help-panel.is-popover {
        left: 50% !important;
        top: auto !important;
        bottom: 0;
        transform: translateX(-50%);
        width: 100%;
        max-width: 100%;
        border-bottom-left-radius: 0;
        border-bottom-right-radius: 0;
        max-height: 75vh;
        display: flex;
        flex-direction: column;
    }
}
