﻿/* User Guide */

.guide-header .header-content {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 24px;
    padding: 14px 0;
}

.guide-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 20px;
}

    .guide-nav a {
        display: inline-flex;
        align-items: center;
        min-height: 44px;
        color: var(--app-text-secondary);
        font-size: 15px;
        font-weight: 600;
    }

        .guide-nav a:hover,
        .guide-nav a[aria-current="page"] {
            color: var(--app-primary);
        }

.guide-main {
    padding: 40px 0 64px;
}

.guide-content {
    max-width: 960px;
    margin: 0 auto;
    padding: 40px;
    background-color: var(--app-surface);
    border: 1px solid var(--app-border);
    border-radius: var(--radius-card);
    font-size: 16px;
}

    .guide-content h1,
    .guide-content h2,
    .guide-content h3 {
        color: var(--app-text-primary);
        font-weight: 700;
    }

    .guide-content h1 {
        margin: 0 0 16px;
        font-size: 32px;
        line-height: 1.2;
        letter-spacing: -0.015em;
    }

    .guide-content h2 {
        margin: 32px 0 10px;
        font-size: 21px;
        line-height: 1.3;
    }

    .guide-content h3 {
        margin: 24px 0 10px;
        font-size: 19px;
        line-height: normal;
    }

    .guide-content p {
        margin: 0 0 16px;
        color: var(--app-text-secondary);
        line-height: 1.65;
    }

    .guide-content ul,
    .guide-content ol {
        margin: 0 0 24px;
        padding-left: 24px;
        color: var(--app-text-secondary);
        line-height: 1.65;
    }

    .guide-content li + li {
        margin-top: 10px;
    }

.guide-link {
    color: var(--app-primary);
}

.guide-choice-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
    margin-top: 32px;
}

.guide-card {
    display: block;
    min-width: 0;
    padding: 28px;
    background-color: var(--app-background);
    border: 1px solid var(--app-border);
    border-radius: var(--radius-card);
}

    .guide-card h2 {
        margin: 0 0 12px;
    }

    .guide-card p:last-child {
        margin-bottom: 0;
    }

.guide-card-link {
    color: var(--app-text-primary);
}

    .guide-card-link:hover {
        background-color: #EEF3FF;
        border-color: var(--app-primary);
    }

.guide-card .guide-card-action {
    color: var(--app-primary);
    font-size: 15px;
    font-weight: 600;
}

.guide-status {
    font-weight: 600;
}

.guide-screenshot {
    margin: 24px 0;
}

    .guide-screenshot img {
        width: auto;
        max-width: 100%;
        height: auto;
        max-height: 420px;
        margin: 0 auto;
        border: 1px solid var(--app-border);
        border-radius: 16px;
    }

    .guide-screenshot figcaption {
        margin-top: 10px;
        color: var(--app-text-secondary);
        font-size: 13px;
        line-height: 1.5;
        text-align: center;
    }

.guide-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin-top: 32px;
}

.guide-page a,
.guide-page a:hover,
.guide-page a:focus-visible {
    text-decoration: none;
}

    .guide-page a:focus-visible,
    .guide-page button:focus-visible {
        outline: 3px solid var(--app-primary);
        outline-offset: 4px;
    }

.guide-page .footer-content,
.guide-page .footer-project,
.guide-page .footer-note {
    flex-wrap: wrap;
}

/* Enlarged screenshots */

.guide-page.guide-image-open {
    overflow: hidden;
}

.guide-page .guide-image-dialog {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    max-width: none;
    max-height: none;
    margin: 0;
    padding: 72px 16px 24px;
    border: 0;
    background: transparent;
    overflow: hidden;
    cursor: zoom-out;
}

    .guide-page .guide-image-dialog[open] {
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .guide-page .guide-image-dialog::backdrop {
        background: rgba(15, 23, 42, 0.88);
    }

.guide-page .guide-image-full {
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: calc(100vh - 96px);
    max-height: calc(100dvh - 96px);
    object-fit: contain;
    background: var(--app-surface);
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    cursor: default;
}

.guide-page .guide-image-close {
    position: fixed;
    top: 16px;
    right: 16px;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    padding: 0;
    border: 1px solid var(--app-border);
    border-radius: 50%;
    background: var(--app-surface);
    color: var(--app-text-primary);
    font-family: inherit;
    font-size: 32px;
    line-height: 1;
    cursor: pointer;
}

    .guide-page .guide-image-close:hover {
        background: #EEF3FF;
    }

@media (max-width: 900px) {
    .guide-content h1 {
        font-size: 28px;
    }
}

@media (max-width: 600px) {
    .guide-main {
        padding: 24px 0 40px;
    }

    .guide-content {
        padding: 24px 20px;
    }

        .guide-content h1 {
            font-size: 24px;
        }

    .guide-nav {
        width: 100%;
    }

    .guide-choice-grid {
        grid-template-columns: 1fr;
    }

    .guide-card {
        padding: 24px;
    }
}