/* ========================================
   ページ案内（はてなアイコン + ポップオーバー）
   長いチュートリアル文は常時バナーにせず、ここに格納する
   ======================================== */

.page-title-with-help {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
    flex: 0 1 auto;
}

.page-title-with-help h2,
.page-title-with-help h3,
.page-title-with-help h4 {
    margin: 0;
}

.page-help {
    position: relative;
    display: inline-flex;
    flex-shrink: 0;
    vertical-align: middle;
}

.page-help-toggle {
    appearance: none;
    -webkit-appearance: none;
    width: 32px;
    height: 32px;
    min-width: 32px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: var(--unit-color, #80bfcb);
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: none;
}

.page-help-toggle:hover,
.page-help-toggle:focus,
.page-help-toggle:focus-visible,
.page-help-toggle[aria-expanded="true"] {
    background: color-mix(in srgb, var(--unit-color, #80bfcb) 14%, #fff);
    color: var(--unit-color, #80bfcb);
    outline: none;
    filter: none;
    transform: none;
    opacity: 1;
    box-shadow: none;
}

.page-help-toggle i {
    font-size: inherit;
    color: inherit;
    opacity: 1;
}

.page-help-panel {
    position: fixed;
    z-index: 1200;
    box-sizing: border-box;
    width: min(420px, calc(100vw - 16px));
    max-height: min(70vh, 480px);
    overflow: auto;
    padding: 14px 16px;
    background: #fff;
    border: 1px solid rgba(15, 23, 42, 0.08);
    border-radius: 12px;
    box-shadow:
        0 4px 6px -1px rgba(15, 23, 42, 0.08),
        0 12px 28px -4px rgba(15, 23, 42, 0.18);
    font-size: 14px;
    line-height: 1.65;
    color: #333;
    animation: page-help-in 0.14s ease-out;
}

@keyframes page-help-in {
    from {
        opacity: 0;
        transform: translateY(-4px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.page-help-panel[hidden] {
    display: none !important;
}

.page-help-panel p {
    margin: 0 0 10px;
}

.page-help-panel p:last-child {
    margin-bottom: 0;
}

.page-help-links {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 14px;
    margin-top: 4px;
}

.page-help-links a {
    font-size: 13px;
}

@media (max-width: 768px) {
    .page-help-toggle {
        width: 36px;
        height: 36px;
        min-width: 36px;
        font-size: 20px;
    }
}
