:root {
    --guide-accent: #7a9b37;
    --guide-accent-soft: rgb(122 155 55 / 12%);
}

.guide-main {
    min-width: 0;
}

.guide-hero {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(18rem, 0.9fr);
    min-height: clamp(26rem, 52vh, 34rem);
    border-bottom: 1px solid var(--line);
}

.guide-hero__copy {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    flex-direction: column;
    padding: clamp(2.5rem, 4.5vw, 4rem) var(--side);
}

.guide-back,
.guide-text-link,
.guide-official-link {
    color: #85858a;
    font-size: 0.86rem;
    font-weight: 500;
    text-decoration: none;
    transition: color 180ms ease;
}

.guide-back:hover,
.guide-text-link:hover,
.guide-official-link:hover {
    color: var(--ink);
}

.guide-label,
.guide-section__number,
.guide-sidebar nav > p,
.guide-meta dt {
    color: var(--guide-accent);
    font-family: "DM Mono", ui-monospace, monospace;
    font-size: clamp(0.65rem, 0.75vw, 0.75rem);
    font-weight: 500;
    letter-spacing: 0.055em;
    text-transform: uppercase;
}

.guide-label {
    margin: clamp(1.5rem, 3vw, 2.4rem) 0 0.85rem;
}

.guide-hero h1 {
    max-width: 47rem;
    margin: 0;
    font-size: clamp(3.25rem, 5.5vw, 6rem);
    font-weight: 600;
    letter-spacing: -0.075em;
    line-height: 0.92;
}

.guide-lede {
    max-width: 41rem;
    margin: clamp(1.15rem, 2vw, 1.6rem) 0 0;
    color: var(--muted);
    font-size: clamp(1.05rem, 1.45vw, 1.4rem);
    line-height: 1.5;
}

.guide-meta {
    display: flex;
    width: 100%;
    max-width: 42rem;
    gap: 0;
    margin: clamp(1.5rem, 2.5vw, 2rem) 0 0;
    border-block: 1px solid var(--line);
}

.guide-meta div {
    flex: 1;
    padding: 0.9rem 1rem;
    border-right: 1px solid var(--line);
}

.guide-meta div:first-child {
    padding-left: 0;
}

.guide-meta div:last-child {
    border-right: 0;
}

.guide-meta dt,
.guide-meta dd {
    margin: 0;
}

.guide-meta dt {
    color: #5f5f64;
}

.guide-meta dd {
    margin-top: 0.35rem;
    color: var(--ink);
    font-size: 0.85rem;
    font-weight: 600;
}

.guide-hero__visual {
    display: grid;
    min-width: 0;
    margin: 0;
    overflow: hidden;
    border-left: 1px solid var(--line);
    background: #101012;
    place-items: center;
}

.guide-hero__visual img {
    display: block;
    width: 100%;
    height: 100%;
    max-height: 34rem;
    object-fit: cover;
    object-position: center;
}

.guide-layout {
    display: grid;
    grid-template-columns: minmax(15rem, 0.42fr) minmax(0, 1.58fr);
}

.guide-sidebar {
    padding: clamp(2.5rem, 5vw, 4.5rem) var(--side);
    border-right: 1px solid var(--line);
}

.guide-sidebar nav {
    position: sticky;
    top: 2rem;
}

.guide-sidebar nav > p {
    margin: 0 0 1.25rem;
    color: #626267;
}

.guide-sidebar ol {
    display: grid;
    gap: 0.72rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.guide-sidebar a {
    color: #7d7d82;
    font-size: 0.88rem;
    text-decoration: none;
}

.guide-sidebar nav a:hover {
    color: var(--ink);
}

.guide-official-link {
    display: inline-flex;
    gap: 0.45rem;
    margin-top: 2.2rem;
}

.guide-content {
    min-width: 0;
}

.guide-section {
    padding: clamp(3.5rem, 7vw, 6.5rem) clamp(1.5rem, 7vw, 8rem);
    border-bottom: 1px solid var(--line);
    scroll-margin-top: 2rem;
}

.guide-section > * {
    max-width: 52rem;
}

.guide-section__number {
    margin: 0 0 1.25rem;
}

.guide-section h2 {
    margin: 0;
    color: var(--ink);
    font-size: clamp(2.15rem, 4vw, 4rem);
    font-weight: 600;
    letter-spacing: -0.06em;
    line-height: 0.98;
}

.guide-section > p:not(.guide-section__number),
.guide-callout p,
.guide-warning p {
    color: var(--muted);
    font-size: clamp(1rem, 1.25vw, 1.15rem);
    line-height: 1.7;
}

.guide-section > p:not(.guide-section__number) {
    margin: 1.35rem 0 0;
}

.guide-section a {
    color: var(--ink);
}

.guide-callout,
.guide-warning {
    margin-top: 2rem;
    padding: 1.25rem 1.35rem;
    border: 1px solid #303035;
    border-radius: 0.75rem;
    background: #101012;
}

.guide-callout strong,
.guide-warning strong {
    display: block;
    margin-bottom: 0.7rem;
    color: var(--ink);
    font-size: 1rem;
}

.guide-callout ul,
.guide-checklist {
    display: grid;
    gap: 0.62rem;
    margin: 0;
    padding-left: 1.2rem;
    color: var(--muted);
    line-height: 1.55;
}

.guide-callout--compact p,
.guide-warning p {
    margin: 0;
}

.guide-warning {
    border-color: rgb(122 155 55 / 35%);
    background: var(--guide-accent-soft);
}

.guide-link-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.65rem;
    margin-top: 1.5rem;
}

.guide-link-row a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 3.4rem;
    gap: 1rem;
    padding: 0.75rem 0.9rem;
    border: 1px solid var(--line);
    border-radius: 0.55rem;
    color: var(--ink);
    font-size: 0.88rem;
    text-decoration: none;
    transition: border-color 180ms ease, background 180ms ease;
}

.guide-link-row a:hover {
    border-color: #444449;
    background: #101012;
}

.guide-steps {
    display: grid;
    gap: 0;
    margin: 2rem 0 0;
    padding: 0;
    list-style: none;
}

.guide-steps li {
    display: grid;
    grid-template-columns: 2.5rem minmax(0, 1fr);
    gap: 1rem;
    padding: 1.15rem 0;
    border-bottom: 1px solid var(--line);
}

.guide-steps li:first-child {
    border-top: 1px solid var(--line);
}

.guide-steps li > span {
    color: #606065;
    font-family: "DM Mono", ui-monospace, monospace;
    font-size: 0.7rem;
}

.guide-steps strong {
    color: var(--ink);
    font-size: 1.02rem;
}

.guide-steps p {
    margin: 0.35rem 0 0;
    color: var(--muted);
    line-height: 1.55;
}

.guide-content code {
    font-family: "DM Mono", ui-monospace, monospace;
    font-size: 0.87em;
}

.guide-code {
    margin-top: 2rem;
    overflow: hidden;
    border: 1px solid #303035;
    border-radius: 0.75rem;
    background: #0d0d0f;
}

.guide-code > div {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.65rem 0.9rem;
    border-bottom: 1px solid #29292d;
    color: #747479;
    font-family: "DM Mono", ui-monospace, monospace;
    font-size: 0.68rem;
}

.guide-code button {
    padding: 0;
    border: 0;
    color: #8f8f94;
    background: transparent;
    font: inherit;
    cursor: pointer;
}

.guide-code button:hover {
    color: var(--ink);
}

.guide-code pre {
    margin: 0;
    overflow-x: auto;
    padding: 1.1rem;
    color: #c6c4ca;
    font-size: 0.84rem;
    line-height: 1.7;
}

.guide-text-link {
    display: inline-flex;
    margin-top: 1.5rem;
    color: #99989e;
}

.guide-troubleshooting {
    display: grid;
    gap: 0.5rem;
    margin-top: 2rem;
}

.guide-troubleshooting details {
    border: 1px solid var(--line);
    border-radius: 0.6rem;
    background: #0d0d0f;
}

.guide-troubleshooting summary {
    padding: 1rem 1.1rem;
    color: var(--ink);
    font-weight: 600;
    cursor: pointer;
}

.guide-troubleshooting p {
    margin: 0;
    padding: 0 1.1rem 1.1rem;
    color: var(--muted);
    line-height: 1.6;
}

.guide-checklist {
    margin-top: 2rem;
}

.guide-cta {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(16rem, 0.8fr);
    gap: 2rem;
    align-items: end;
    padding: clamp(3rem, 7vw, 6rem) var(--side);
    border-bottom: 1px solid var(--line);
    background: linear-gradient(120deg, rgb(122 155 55 / 16%), transparent 48%);
}

.guide-cta .guide-label {
    margin: 0 0 1rem;
}

.guide-cta h2 {
    max-width: 48rem;
    margin: 0;
    font-size: clamp(2.4rem, 5vw, 5rem);
    font-weight: 600;
    letter-spacing: -0.065em;
    line-height: 0.96;
}

.guide-cta > div:last-child {
    display: flex;
    gap: 0.65rem;
    justify-content: flex-end;
    flex-wrap: wrap;
}

.guide-cta > div:last-child a {
    display: inline-flex;
    min-height: 3rem;
    align-items: center;
    padding: 0.7rem 1rem;
    border: 1px solid #3a3a3f;
    border-radius: 0.55rem;
    color: var(--ink);
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
}

.guide-cta > div:last-child a:first-child {
    border-color: var(--ink);
    color: #09090a;
    background: var(--ink);
}

@media (max-width: 900px) {
    .guide-hero {
        grid-template-columns: 1fr;
    }

    .guide-hero__visual {
        max-height: 28rem;
        border-top: 1px solid var(--line);
        border-left: 0;
    }

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

    .guide-sidebar {
        border-right: 0;
        border-bottom: 1px solid var(--line);
    }

    .guide-sidebar nav {
        position: static;
    }

    .guide-sidebar ol {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

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

    .guide-cta > div:last-child {
        justify-content: flex-start;
    }
}

@media (max-width: 620px) {
    .guide-meta {
        display: grid;
        grid-template-columns: 1fr;
    }

    .guide-meta div,
    .guide-meta div:first-child {
        padding: 0.75rem 0;
        border-right: 0;
        border-bottom: 1px solid var(--line);
    }

    .guide-meta div:last-child {
        border-bottom: 0;
    }

    .guide-sidebar ol,
    .guide-link-row {
        grid-template-columns: 1fr;
    }

    .guide-section {
        padding-inline: var(--side);
    }

    .guide-cta > div:last-child {
        align-items: stretch;
        flex-direction: column;
    }

    .guide-cta > div:last-child a {
        justify-content: center;
    }
}

@media (prefers-reduced-motion: reduce) {
    .guide-back,
    .guide-text-link,
    .guide-official-link,
    .guide-link-row a {
        transition: none;
    }
}
