/* ═══════════════════════════════════════
   GUIDE PAGE — CSS
   Standalone documentation page
   ═══════════════════════════════════════ */

:root {
    --g-bg: #0d1117;
    --g-bg2: #161b22;
    --g-bg3: #1c2333;
    --g-surface: rgba(255, 255, 255, 0.04);
    --g-border: rgba(255, 255, 255, 0.08);
    --g-text: #e6edf3;
    --g-text2: #8b949e;
    --g-text3: #6e7681;
    --g-accent: #58a6ff;
    --g-accent2: #388bfd;
    --g-yellow: #f0b429;
    --g-green: #3fb950;
    --g-red: #f85149;
    --g-purple: #bc8cff;
    --g-orange: #f0883e;
    --g-cyan: #56d4dd;
    --g-sidebar-w: 260px;
    --g-radius: 16px;
    --g-radius-sm: 10px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 90px;
}

body.guide-body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--g-bg);
    color: var(--g-text);
    line-height: 1.7;
    min-height: 100vh;
    overflow-x: hidden;
}

/* ── SCROLLBAR ── */
body.guide-body::-webkit-scrollbar {
    width: 8px;
}

body.guide-body::-webkit-scrollbar-track {
    background: var(--g-bg);
}

body.guide-body::-webkit-scrollbar-thumb {
    background: var(--g-border);
    border-radius: 4px;
}

body.guide-body::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.15);
}

/* ── PROGRESS BAR ── */
.guide-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    z-index: 1000;
    background: linear-gradient(90deg, var(--g-accent), var(--g-purple), var(--g-cyan));
    transition: width 0.15s ease;
}

/* ── HERO ── */
.guide-hero {
    position: relative;
    padding: 100px 40px 80px;
    text-align: center;
    overflow: hidden;
    background: linear-gradient(135deg, #0d1117 0%, #161b22 40%, #1a1e2e 70%, #0d1117 100%);
}

.guide-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 600px 400px at 20% 50%, rgba(88, 166, 255, 0.12) 0%, transparent 70%),
        radial-gradient(ellipse 500px 350px at 80% 30%, rgba(188, 140, 255, 0.10) 0%, transparent 70%),
        radial-gradient(ellipse 400px 300px at 50% 80%, rgba(86, 212, 221, 0.08) 0%, transparent 70%);
    animation: heroGlow 8s ease-in-out infinite alternate;
}

@keyframes heroGlow {
    0% {
        opacity: 0.6;
        transform: scale(1);
    }

    100% {
        opacity: 1;
        transform: scale(1.05);
    }
}

.guide-hero-content {
    position: relative;
    z-index: 2;
    max-width: 700px;
    margin: 0 auto;
}

.guide-hero-badge {
    display: inline-block;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--g-accent);
    background: rgba(88, 166, 255, 0.1);
    border: 1px solid rgba(88, 166, 255, 0.2);
    margin-bottom: 24px;
}

.guide-hero h1 {
    font-size: clamp(32px, 5vw, 52px);
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 16px;
    background: linear-gradient(135deg, #fff 30%, var(--g-accent) 70%, var(--g-purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.guide-hero-sub {
    font-size: 18px;
    color: var(--g-text2);
    max-width: 500px;
    margin: 0 auto 32px;
}

/* Search Bar in Hero */
.guide-search-wrap {
    max-width: 480px;
    margin: 0 auto;
    position: relative;
}

.guide-search-wrap svg {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    fill: var(--g-text3);
    pointer-events: none;
}

.guide-search {
    width: 100%;
    padding: 14px 16px 14px 46px;
    border-radius: 14px;
    border: 1px solid var(--g-border);
    background: rgba(255, 255, 255, 0.05);
    color: var(--g-text);
    font-size: 15px;
    outline: none;
    backdrop-filter: blur(10px);
    transition: border-color 0.3s, box-shadow 0.3s;
}

.guide-search::placeholder {
    color: var(--g-text3);
}

.guide-search:focus {
    border-color: var(--g-accent);
    box-shadow: 0 0 0 3px rgba(88, 166, 255, 0.15);
}

.guide-search-hint {
    display: flex;
    align-items: center;
    gap: 6px;
    justify-content: center;
    margin-top: 12px;
    font-size: 12px;
    color: var(--g-text3);
}

.guide-kbd {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 2px 7px;
    border-radius: 5px;
    font-size: 11px;
    font-family: monospace;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: var(--g-text2);
}

/* ── LAYOUT ── */
.guide-layout {
    display: flex;
    max-width: 1200px;
    margin: 0 auto;
    min-height: 100vh;
}

/* ── SIDEBAR ── */
.guide-sidebar {
    position: sticky;
    top: 0;
    width: var(--g-sidebar-w);
    min-width: var(--g-sidebar-w);
    height: 100vh;
    padding: 24px 0;
    overflow-y: auto;
    border-right: 1px solid var(--g-border);
    background: var(--g-bg);
    z-index: 50;
}

.guide-sidebar::-webkit-scrollbar {
    width: 4px;
}

.guide-sidebar::-webkit-scrollbar-thumb {
    background: var(--g-border);
    border-radius: 2px;
}

.guide-sidebar-title {
    padding: 0 20px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--g-text3);
    margin-bottom: 12px;
}

.guide-nav {
    list-style: none;
}

.guide-nav li a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 20px;
    font-size: 14px;
    color: var(--g-text2);
    text-decoration: none;
    border-left: 3px solid transparent;
    transition: all 0.2s;
}

.guide-nav li a:hover {
    color: var(--g-text);
    background: rgba(255, 255, 255, 0.03);
}

.guide-nav li a.active {
    color: var(--g-accent);
    border-left-color: var(--g-accent);
    background: rgba(88, 166, 255, 0.06);
    font-weight: 600;
}

.guide-nav-icon {
    font-size: 16px;
    width: 22px;
    text-align: center;
    flex-shrink: 0;
}

/* Mobile burger */
.guide-burger {
    display: none;
    position: fixed;
    top: 16px;
    left: 16px;
    z-index: 200;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    border: 1px solid var(--g-border);
    background: rgba(13, 17, 23, 0.9);
    backdrop-filter: blur(10px);
    color: var(--g-text);
    font-size: 20px;
    cursor: pointer;
    align-items: center;
    justify-content: center;
}

.guide-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 40;
}

/* ── MAIN CONTENT ── */
.guide-main {
    flex: 1;
    padding: 40px 40px 80px;
    min-width: 0;
    overflow-x: hidden;
}

/* ── SECTIONS ── */
.guide-section {
    margin-bottom: 60px;
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.guide-section.visible {
    opacity: 1;
    transform: translateY(0);
}

.guide-section-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--g-border);
}

.guide-section-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    flex-shrink: 0;
    transition: transform 0.3s;
}

.guide-section-header:hover .guide-section-icon {
    transform: scale(1.1);
}

.guide-section-icon.yellow {
    background: rgba(240, 180, 41, 0.15);
}

.guide-section-icon.blue {
    background: rgba(88, 166, 255, 0.15);
}

.guide-section-icon.green {
    background: rgba(63, 185, 80, 0.15);
}

.guide-section-icon.red {
    background: rgba(248, 81, 73, 0.15);
}

.guide-section-icon.purple {
    background: rgba(188, 140, 255, 0.15);
}

.guide-section-icon.orange {
    background: rgba(240, 136, 62, 0.15);
}

.guide-section-icon.cyan {
    background: rgba(86, 212, 221, 0.15);
}

.guide-section-title {
    font-size: 24px;
    font-weight: 700;
}

.guide-section-desc {
    color: var(--g-text2);
    font-size: 15px;
    margin-bottom: 24px;
    line-height: 1.7;
}

/* ── FEATURE CARDS ── */
.guide-features {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 14px;
    margin-bottom: 24px;
}

.guide-feature-card {
    background: var(--g-surface);
    border: 1px solid var(--g-border);
    border-radius: var(--g-radius-sm);
    padding: 20px;
    transition: transform 0.2s, border-color 0.3s, box-shadow 0.3s;
    cursor: default;
}

.guide-feature-card:hover {
    transform: translateY(-3px);
    border-color: rgba(255, 255, 255, 0.12);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
}

.guide-feature-icon {
    font-size: 28px;
    margin-bottom: 10px;
    display: block;
}

.guide-feature-title {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 6px;
}

.guide-feature-text {
    font-size: 13px;
    color: var(--g-text2);
    line-height: 1.5;
}

/* ── ACCORDION ── */
.guide-accordion {
    margin-bottom: 10px;
    border: 1px solid var(--g-border);
    border-radius: var(--g-radius-sm);
    overflow: hidden;
    transition: border-color 0.3s;
}

.guide-accordion.open {
    border-color: rgba(88, 166, 255, 0.3);
}

.guide-accordion-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    cursor: pointer;
    font-size: 15px;
    font-weight: 600;
    color: var(--g-text);
    background: var(--g-surface);
    transition: background 0.2s;
    user-select: none;
    gap: 12px;
}

.guide-accordion-header:hover {
    background: rgba(255, 255, 255, 0.06);
}

.guide-accordion-arrow {
    width: 20px;
    height: 20px;
    fill: var(--g-text3);
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.guide-accordion.open .guide-accordion-arrow {
    transform: rotate(180deg);
}

.guide-accordion-body {
    max-height: 0;
    overflow: clip;
    transition: max-height 0.4s ease;
}

.guide-accordion-content {
    padding: 16px 20px 20px;
    font-size: 14px;
    color: var(--g-text2);
    line-height: 1.8;
    border-top: 1px solid var(--g-border);
}

.guide-accordion-content p {
    margin-bottom: 10px;
}

.guide-accordion-content p:last-child {
    margin-bottom: 0;
}

/* ── CALLOUT BOXES ── */
.guide-callout {
    display: flex;
    gap: 12px;
    padding: 16px 18px;
    border-radius: var(--g-radius-sm);
    margin: 16px 0;
    font-size: 14px;
    line-height: 1.6;
}

.guide-callout-icon {
    font-size: 20px;
    flex-shrink: 0;
    margin-top: 1px;
}

.guide-callout.tip {
    background: rgba(63, 185, 80, 0.08);
    border: 1px solid rgba(63, 185, 80, 0.2);
}

.guide-callout.warning {
    background: rgba(240, 136, 62, 0.08);
    border: 1px solid rgba(240, 136, 62, 0.2);
}

.guide-callout.info {
    background: rgba(88, 166, 255, 0.08);
    border: 1px solid rgba(88, 166, 255, 0.2);
}

.guide-callout.important {
    background: rgba(248, 81, 73, 0.08);
    border: 1px solid rgba(248, 81, 73, 0.2);
}

/* ── STEPS ── */
.guide-steps {
    counter-reset: step-counter;
    list-style: none;
    margin: 16px 0;
}

.guide-steps li {
    counter-increment: step-counter;
    display: flex;
    gap: 14px;
    margin-bottom: 14px;
    align-items: flex-start;
}

.guide-steps li::before {
    content: counter(step-counter);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--g-accent), var(--g-purple));
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    flex-shrink: 0;
    margin-top: 2px;
}

.guide-step-text {
    font-size: 14px;
    color: var(--g-text2);
    line-height: 1.6;
}

.guide-step-text strong {
    color: var(--g-text);
}

/* ── MINI TABLE ── */
.guide-table-wrap {
    overflow-x: auto;
    margin: 16px 0;
    border-radius: var(--g-radius-sm);
    border: 1px solid var(--g-border);
}

.guide-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.guide-table th {
    padding: 12px 16px;
    background: var(--g-bg3);
    color: var(--g-text);
    font-weight: 600;
    text-align: left;
    white-space: nowrap;
}

.guide-table td {
    padding: 10px 16px;
    border-top: 1px solid var(--g-border);
    color: var(--g-text2);
}

.guide-table tbody tr:hover {
    background: rgba(255, 255, 255, 0.02);
}

/* ── BACK TO TOP ── */
.guide-top-btn {
    position: fixed;
    bottom: 28px;
    right: 28px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 1px solid var(--g-border);
    background: rgba(13, 17, 23, 0.85);
    backdrop-filter: blur(10px);
    color: var(--g-text);
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.3s, transform 0.3s, background 0.2s;
    z-index: 100;
}

.guide-top-btn.show {
    opacity: 1;
    transform: translateY(0);
}

.guide-top-btn:hover {
    background: var(--g-accent);
    border-color: var(--g-accent);
}

/* ── NO RESULTS ── */
.guide-no-results {
    display: none;
    text-align: center;
    padding: 60px 20px;
    color: var(--g-text3);
    font-size: 16px;
}

.guide-no-results-icon {
    font-size: 48px;
    margin-bottom: 16px;
    display: block;
}

/* ── SEARCH HIGHLIGHT ── */
.guide-highlight {
    background: rgba(240, 180, 41, 0.25);
    border-radius: 3px;
    padding: 0 2px;
}

/* ── FOOTER ── */
.guide-footer {
    text-align: center;
    padding: 40px 20px 30px;
    border-top: 1px solid var(--g-border);
    color: var(--g-text3);
    font-size: 13px;
}

/* ── RESPONSIVE ── */
@media (max-width: 900px) {
    .guide-hero {
        padding: 80px 20px 60px;
    }

    .guide-hero-sub {
        font-size: 16px;
    }

    .guide-burger {
        display: flex;
    }

    .guide-sidebar {
        position: fixed;
        left: -280px;
        top: 0;
        width: 270px;
        min-width: 270px;
        height: 100vh;
        transition: left 0.3s ease;
        z-index: 100;
        border-right: 1px solid var(--g-border);
        background: var(--g-bg);
        padding-top: 70px;
    }

    .guide-sidebar.open {
        left: 0;
    }

    .guide-overlay.open {
        display: block;
    }

    .guide-main {
        padding: 30px 20px 60px;
    }

    .guide-features {
        grid-template-columns: 1fr;
    }

    .guide-section-header {
        gap: 10px;
    }

    .guide-section-icon {
        width: 40px;
        height: 40px;
        font-size: 20px;
        border-radius: 12px;
    }

    .guide-section-title {
        font-size: 20px;
    }
}

@media (max-width: 500px) {
    .guide-hero {
        padding: 70px 16px 50px;
    }

    .guide-hero h1 {
        font-size: 28px;
    }

    .guide-main {
        padding: 20px 12px 50px;
    }

    .guide-section {
        margin-bottom: 40px;
    }

    .guide-accordion-header {
        padding: 14px 16px;
        font-size: 14px;
    }

    .guide-accordion-content {
        padding: 14px 16px 16px;
    }
}

/* ── SCREENSHOTS ── */
.guide-screenshot-block {
    margin: 18px 0;
    text-align: center;
    overflow: hidden;
}

.guide-screenshot {
    width: 100%;
    max-width: 320px;
    height: auto;
    border-radius: 16px;
    border: 1px solid rgba(88, 166, 255, 0.15);
    box-shadow: 0 4px 30px rgba(88, 166, 255, 0.1), 0 0 60px rgba(88, 166, 255, 0.05);
    display: block;
    margin: 0 auto;
}

@media (max-width: 500px) {
    .guide-screenshot {
        max-width: 260px;
        border-radius: 12px;
    }
}

.guide-screenshot-caption {
    margin-top: 10px;
    font-size: 12px;
    color: var(--g-text3);
    font-style: italic;
}

/* ── NAV SUB-ITEMS ── */
.guide-nav li.guide-nav-sub a {
    padding-left: 48px;
    font-size: 13px;
    color: var(--g-text3);
}

.guide-nav li.guide-nav-sub a:hover {
    color: var(--g-text2);
}

.guide-nav li.guide-nav-sub a.active {
    color: var(--g-accent);
}

/* ── SECTION LINKS ── */
.guide-link {
    color: var(--g-accent);
    text-decoration: none;
    border-bottom: 1px dashed rgba(88, 166, 255, 0.3);
    transition: border-color 0.2s;
}

.guide-link:hover {
    border-bottom-color: var(--g-accent);
}