.herdr-guide {
    --guide-page: #eff3ef;
    --guide-paper: #fff;
    --guide-ink: #182b24;
    --guide-muted: #475e51;
    --guide-green: #175940;
    --guide-line: #d2ded6;
    min-height: 100vh;
    padding: clamp(14px, 3vw, 38px) clamp(12px, 4vw, 55px) 42px;
    background: var(--guide-page);
    color: var(--guide-ink);
    font-size: 16px;
    line-height: 1.65;
    overflow-wrap: anywhere;
    word-break: keep-all;
}
.herdr-guide [hidden] { display: none !important; }
.herdr-guide :focus-visible { outline: 2px solid var(--guide-green); outline-offset: 3px; }
.herdr-top, .herdr-layout { max-width: 78rem; margin-inline: auto; }
.herdr-top { display: flex; justify-content: space-between; align-items: end; flex-wrap: wrap; gap: 12px; padding-bottom: 17px; }
.herdr-top h1 { font-size: clamp(1.65rem, 4vw, 2.55rem); font-weight: 850; line-height: 1.18; letter-spacing: -.028em; margin: 5px 0; }
.herdr-top a:not(.herdr-button), .herdr-links a, .herdr-figure figcaption a { color: var(--guide-green); font-weight: 700; }
.herdr-top p { color: var(--guide-muted); font-size: .9rem; margin: 0; }
.herdr-layout { display: grid; grid-template-columns: minmax(12rem, 15rem) minmax(0, 1fr); gap: 17px; align-items: start; }
.herdr-index { position: sticky; top: 12px; }
.herdr-index details { border: 1px solid var(--guide-line); border-radius: 13px; background: var(--guide-paper); }
.herdr-index summary { padding: 11px 14px; cursor: pointer; font-weight: 800; }
.herdr-index summary span { float: right; color: var(--guide-muted); font-size: .89rem; }
.herdr-index nav { padding: 0 8px 10px; max-height: calc(100dvh - 78px); overflow: auto; }
.herdr-group h2 { padding: 8px 7px 3px; margin: 0; color: var(--guide-muted); font-size: .82rem; font-weight: 800; }
.herdr-group ol { list-style: none; margin: 0; padding: 0; }
.herdr-group a { display: flex; gap: 9px; align-items: baseline; padding: 5px 7px; border-radius: 7px; color: var(--guide-ink); line-height: 1.45; font-size: .905rem; }
.herdr-group a span { flex: 0 0 2ch; white-space: nowrap; color: var(--guide-muted); font-size: .78rem; font-variant-numeric: tabular-nums; }
.herdr-group a:hover, .herdr-group a[aria-current="page"] { background: #e0ede5; color: var(--guide-green); }
.herdr-group a[aria-current="page"] { font-weight: 800; }
.herdr-reading { min-width: 0; }
.herdr-page-nav {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 8px;
    padding: 8px 0;
    position: sticky;
    top: 0;
    z-index: 2;
    background: var(--guide-page);
    touch-action: pan-y pinch-zoom;
}
.herdr-page-nav span { text-align: center; color: var(--guide-muted); font-size: .95rem; font-variant-numeric: tabular-nums; font-weight: 750; }
.herdr-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 7px 13px;
    border: 1px solid var(--guide-line);
    border-radius: 8px;
    background: var(--guide-paper);
    color: var(--guide-green);
    font-size: .9rem;
    font-weight: 760;
    line-height: 1.2;
    cursor: pointer;
    text-align: center;
}
.herdr-button:hover { background: #e4efe7; }
.herdr-page-nav .herdr-next { background: var(--guide-green); color: #fff; border-color: var(--guide-green); }
.herdr-page-nav .herdr-next:hover { background: #1d6c4f; }
.herdr-button[aria-disabled="true"] { color: var(--guide-muted); background: #e2e9e3; border-color: var(--guide-line); cursor: default; }
.herdr-secondary { background: #f5f8f5; }
.herdr-chapter { background: var(--guide-paper); border: 1px solid var(--guide-line); border-radius: 14px; padding: clamp(13px, 3vw, 27px); touch-action: pan-y pinch-zoom; }
.herdr-chapter-title h2 { font-size: clamp(1.4rem, 3vw, 2rem); font-weight: 850; line-height: 1.2; letter-spacing: -.02em; margin: 0 0 7px; }
.herdr-chapter-title p { color: var(--guide-muted); margin: 0 0 16px; }
.herdr-figure { margin: 0 0 17px; }
.herdr-screen-link { display: block; }
.herdr-figure img { display: block; max-width: 100%; width: auto; max-height: 365px; height: auto; margin-inline: auto; border-radius: 9px; }
.herdr-screen-link { padding: 3px; background: #1e1e2e; border-radius: 10px; }
.herdr-figure figcaption { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; font-size: .88rem; color: var(--guide-muted); padding: 7px 2px 0; }
.herdr-figure figcaption a { min-height: 44px; display: inline-flex; align-items: center; white-space: nowrap; text-decoration: underline; text-underline-offset: 3px; }
.herdr-overview { margin-top: 2px; border-top: 1px solid var(--guide-line); }
.herdr-overview summary, .herdr-notes summary { cursor: pointer; font-weight: 760; color: var(--guide-green); padding: 8px 0; }
.herdr-overview img { margin-top: 7px; max-height: none; }
.herdr-flow { list-style: none; margin: 0 0 18px; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.herdr-flow li { background: #e7f1e9; border: 1px solid var(--guide-line); border-radius: 8px; padding: 8px 11px; font-weight: 750; font-size: .94rem; }
.herdr-flow li + li::before { content: "→"; margin-right: 8px; color: var(--guide-green); }
.herdr-how { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
.herdr-how:has(.herdr-materials) { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.herdr-how h3 { font-size: 1.12rem; font-weight: 850; margin: 3px 0 9px; }
.herdr-steps { list-style: none; counter-reset: herdr-step; padding: 0; margin: 0; }
.herdr-steps li { position: relative; counter-increment: herdr-step; padding: 0 0 13px 37px; }
.herdr-steps li::before { content: counter(herdr-step); position: absolute; inset: 0 auto auto 0; min-width: 26px; text-align: center; background: #e6efe8; color: var(--guide-green); border-radius: 5px; font-weight: 780; font-variant-numeric: tabular-nums; }
.herdr-steps p, .herdr-result p { margin: 2px 0 0; color: var(--guide-muted); }
.herdr-result { background: #e7f2e8; border-radius: 9px; padding: 10px 12px; }
.herdr-result strong { color: var(--guide-green); }
.herdr-materials { scroll-margin-top: 66px; }
.herdr-prompt-jump { margin-bottom: 15px; }
.herdr-clipboard { border: 1px solid var(--guide-line); border-radius: 10px; padding: 9px 10px; margin-bottom: 8px; }
.herdr-clip-header, .herdr-edit-controls { display: flex; flex-wrap: wrap; gap: 8px; justify-content: space-between; align-items: center; }
.herdr-clipboard p { color: var(--guide-muted); margin: 4px 0 7px; font-size: .87rem; }
.herdr-clipboard pre { overflow: auto; white-space: pre-wrap; word-break: normal; overflow-wrap: anywhere; margin: 0; background: #1f302b; color: #ecf6ef; border-radius: 6px; padding: 10px; font: .88rem/1.55 ui-monospace, Menlo, monospace; }
.herdr-clipboard pre code { color: inherit; font: inherit; }
.herdr-clipboard textarea { display: block; width: 100%; min-height: 110px; resize: vertical; border: 1px solid var(--guide-line); color: var(--guide-ink); background: #f5f8f5; border-radius: 6px; padding: 9px; font: inherit; }
.herdr-edit-controls { margin-top: 6px; color: var(--guide-muted); font-size: .84rem; }
.herdr-clipboard .herdr-clip-status:empty { margin: 0; }
.herdr-notes { margin-top: 12px; border-top: 1px solid var(--guide-line); }
.herdr-notes ul { padding-left: 20px; margin: 0 0 9px; }
.herdr-links { margin-top: 13px; display: flex; flex-wrap: wrap; gap: 7px 14px; font-size: .89rem; }
.herdr-links a { text-decoration: underline; text-underline-offset: 3px; }
.herdr-chapter[data-enter="next"] { animation: herdr-slide-next .19s ease-out; }
.herdr-chapter[data-enter="previous"] { animation: herdr-slide-previous .19s ease-out; }
@keyframes herdr-slide-next { from { transform: translateX(12px); opacity: .72; } }
@keyframes herdr-slide-previous { from { transform: translateX(-12px); opacity: .72; } }
@media (max-width: 880px) {
    .herdr-layout { grid-template-columns: minmax(0, 1fr); gap: 4px; }
    .herdr-index { position: static; }
    .herdr-index nav { max-height: 52vh; }
    .herdr-group a { min-height: 39px; }
}
@media (max-width: 650px) {
    .herdr-how:has(.herdr-materials) { grid-template-columns: minmax(0, 1fr); }
    .herdr-top { padding-bottom: 8px; }
    .herdr-figure img { max-height: none; }
    .herdr-group a { min-height: 44px; align-items: center; }
}
@media (prefers-reduced-motion: reduce) {
    .herdr-chapter[data-enter] { animation: none; }
}

.herdr-begin {
    --guide-page: #f1eff6;
    --guide-ink: #211c34;
    --guide-line: #dcd5e8;
    --guide-green: #4b2b7e;
    --guide-muted: #554567;
    padding-inline: clamp(15px, 5vw, 54px);
}
.herdr-begin .herdr-top, .herdr-begin .herdr-reading {
    max-width: 44rem;
    margin-inline: auto;
}
.herdr-begin .herdr-top { padding-bottom: 12px; }
.herdr-begin .herdr-top h1 { font-size: 1.15rem; margin-block: 6px 0; letter-spacing: 0; }
.herdr-begin .herdr-top p { font-size: 1rem; }
.herdr-start-step { padding: clamp(18px, 4vw, 30px); }
.herdr-start-step h2 { font-size: clamp(1.65rem, 5vw, 2.3rem); letter-spacing: -.03em; font-weight: 850; line-height: 1.2; margin: 0 0 9px; }
.herdr-start-action { margin: 0 0 15px; font-size: 1.04rem; line-height: 1.55; color: var(--guide-ink); }
.herdr-launcher { background: #f1eaf9; border: 1px solid var(--guide-line); padding: 23px 15px; border-radius: 11px; text-align: center; }
.herdr-shortcut { display: flex; justify-content: center; align-items: center; gap: 9px; }
.herdr-launcher kbd { display: inline-block; padding: 5px 12px; border: 1px solid #bba9cd; border-bottom-width: 3px; border-radius: 7px; background: #fff; color: var(--guide-ink); font: 700 1.16rem/1.45 ui-monospace, Menlo, monospace; }
.herdr-search-demo { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin: 14px auto 0; max-width: 21rem; background: #fff; border: 1px solid #bba9cd; padding: 7px 11px; border-radius: 8px; font-size: 1.16rem; font-weight: 800; }
.herdr-search-demo kbd { font-size: .9rem; }
.herdr-start-command { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 7px; margin: 0 0 12px; align-items: center; }
.herdr-start-command pre { margin: 0; background: #242038; border-radius: 7px; color: #f0faf1; padding: 12px; font: .95rem/1.54 ui-monospace, Menlo, monospace; white-space: pre-wrap; overflow-wrap: anywhere; }
.herdr-start-command code { color: inherit; font: inherit; }
.herdr-start-command [role="status"] { grid-column: 1 / -1; font-size: .87rem; margin: 0; color: var(--guide-muted); }
.herdr-start-command [role="status"]:empty { display: none; }
.herdr-start-image { margin: 0; }
.herdr-start-image img { display: block; max-width: 100%; width: auto; height: auto; max-height: 225px; margin-inline: auto; border-radius: 7px; }
.herdr-start-result { margin: 11px 0 0; color: var(--guide-muted); }
.herdr-start-result a { color: var(--guide-green); text-decoration: underline; text-underline-offset: 3px; }
.herdr-start-prompt { padding: 0; border: 0; }
.herdr-start-prompt textarea { background: #f8f5fc; min-height: 96px; }
.herdr-start-prompt .herdr-edit-controls { justify-content: flex-start; }
.herdr-start-pagination { padding: 12px 0; position: sticky; top: auto; bottom: 0; grid-template-columns: auto 1fr auto; }
.herdr-start-pagination .herdr-next { justify-self: end; }
.herdr-start-pagination .herdr-next:hover { background: #3d2366; }
.herdr-top-tools { display: flex; flex-wrap: wrap; gap: 7px; }
.herdr-compare-detail { border: 1px solid var(--guide-line); border-radius: 9px; margin-bottom: 8px; padding: 0 12px; }
.herdr-compare-detail summary { cursor: pointer; color: var(--guide-green); font-weight: 800; padding: 10px 0; }
.herdr-compare-detail img { display: block; max-width: 100%; width: 100%; height: auto; margin-bottom: 10px; border-radius: 7px; }
