/**
 * Holdenim measurement guide.
 * Final editorial/support layout, scoped to /guide/.
 */

body.hdn-guide-page {
    --hdn-guide-bg: var(--hdn-site-canvas-bg, #f4efe5);
    --hdn-guide-surface: #fffaf1;
    --hdn-guide-ink: var(--hdn-color-indigo, #0f172a);
    --hdn-guide-gold: var(--hdn-color-gold, #b08d57);
    --hdn-guide-line: rgba(15, 23, 42, 0.15);
    --hdn-guide-muted: rgba(15, 23, 42, 0.72);
    background:
        radial-gradient(circle at 88% 6%, rgba(176, 141, 87, 0.16), transparent 34vw),
        var(--hdn-guide-bg);
}

body.hdn-guide-page :where(.content-container.site-container, .content-area, .entry-content-wrap),
body.hdn-guide-page :where(#primary, .site-main) {
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

.hdn-guide-measurements-page {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 0 0 var(--hdn-story-footer-air, 5rem);
    background:
        linear-gradient(180deg, rgba(176, 141, 87, 0.08), transparent 420px),
        var(--hdn-guide-bg);
    color: var(--hdn-guide-ink);
    overflow-x: clip;
}

.hdn-guide-hero {
    display: grid;
    grid-template-columns: minmax(0, 0.95fr) minmax(320px, 0.7fr);
    gap: clamp(1rem, 5vw, 5rem);
    align-items: stretch;
    min-height: clamp(520px, 72svh, 760px);
    padding: clamp(4rem, 8vw, 7rem) 0 clamp(2.8rem, 5vw, 4.8rem);
}

.hdn-guide-hero__copy {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    min-width: 0;
}

.hdn-guide-hero h1 {
    max-width: 12ch;
    margin: 0;
    color: var(--hdn-guide-ink);
    font-family: var(--global-heading-font-family, Georgia, serif);
    font-size: clamp(3.2rem, 8.2vw, 8rem);
    line-height: 0.94;
    letter-spacing: -0.055em;
}

.hdn-guide-hero p:not(.hdn-story-eyebrow) {
    max-width: 62ch;
    margin: clamp(1rem, 1.8vw, 1.35rem) 0 0;
    color: rgba(15, 23, 42, 0.78);
    font-size: clamp(1rem, 1.12vw, 1.18rem);
    line-height: 1.78;
}

.hdn-guide-hero__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: clamp(1.25rem, 2.5vw, 2rem);
}

.hdn-guide-hero__visual {
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto;
    min-width: 0;
    border: 1px solid var(--hdn-guide-line);
    background: var(--hdn-guide-surface);
}

.hdn-guide-hero__media {
    min-height: 0;
    margin: 0;
    background: #e9dfcf;
    overflow: hidden;
}

.hdn-guide-hero__media :is(img, video) {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 360px;
    object-fit: cover;
}

.hdn-guide-hero__stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1px;
    border-top: 1px solid var(--hdn-guide-line);
    background: var(--hdn-guide-line);
}

.hdn-guide-hero__stats span {
    display: grid;
    gap: 0.18rem;
    padding: 0.95rem;
    background: var(--hdn-guide-surface);
    color: var(--hdn-guide-muted);
    font-size: 0.78rem;
    line-height: 1.35;
}

.hdn-guide-hero__stats strong {
    color: var(--hdn-guide-ink);
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.15em;
    text-transform: uppercase;
}

.hdn-guide-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0.92rem 1.25rem;
    border: 1px solid var(--hdn-guide-ink);
    border-radius: 0 !important;
    background: transparent;
    color: var(--hdn-guide-ink);
    cursor: pointer;
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.16em;
    line-height: 1;
    text-decoration: none;
    text-transform: uppercase;
    transition: transform 0.2s ease, background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.hdn-guide-btn-primary {
    border-color: var(--hdn-guide-gold);
    background: var(--hdn-guide-gold);
    color: var(--hdn-guide-ink);
}

.hdn-guide-btn-ghost {
    background: transparent;
}

.hdn-guide-btn:hover,
.hdn-guide-btn:focus-visible {
    border-color: var(--hdn-guide-ink);
    background: var(--hdn-guide-ink);
    color: var(--hdn-color-ivory, #f6f2ea);
    outline: 2px solid var(--hdn-guide-gold);
    outline-offset: 3px;
    transform: translateY(-2px);
}

.hdn-guide-prep {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1px;
    border: 1px solid var(--hdn-guide-line);
    background: var(--hdn-guide-line);
}

.hdn-guide-prep article {
    min-width: 0;
    padding: clamp(1.1rem, 2.4vw, 1.8rem);
    background: var(--hdn-guide-surface);
}

.hdn-guide-prep span,
.hdn-guide-index-panel__title {
    color: var(--hdn-guide-gold);
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.hdn-guide-prep h2 {
    max-width: 12ch;
    margin: clamp(1rem, 2vw, 1.6rem) 0 0;
    color: var(--hdn-guide-ink);
    font-family: var(--global-heading-font-family, Georgia, serif);
    font-size: clamp(1.55rem, 2.6vw, 2.6rem);
    line-height: 1.02;
    letter-spacing: -0.04em;
}

.hdn-guide-prep p {
    margin: 1rem 0 0;
    color: var(--hdn-guide-muted);
    line-height: 1.7;
}

.hdn-guide-shell {
    margin-top: var(--hdn-story-gap, clamp(2.5rem, 6vw, 6rem));
    border: 1px solid var(--hdn-guide-line);
    background: var(--hdn-guide-surface);
}

.hdn-guide-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: clamp(1rem, 4vw, 4rem);
    align-items: end;
    padding: clamp(1.2rem, 3vw, 2.6rem);
    border-bottom: 1px solid var(--hdn-guide-line);
}

.hdn-guide-head h2 {
    max-width: 13ch;
    margin: 0;
    color: var(--hdn-guide-ink);
    font-family: var(--global-heading-font-family, Georgia, serif);
    font-size: clamp(2rem, 4.8vw, 5rem);
    line-height: 0.98;
    letter-spacing: -0.05em;
}

.hdn-guide-head p:not(.hdn-story-eyebrow) {
    max-width: 66ch;
    margin: 1rem 0 0;
    color: var(--hdn-guide-muted);
    line-height: 1.76;
}

.hdn-guide-stepcount {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0.78rem 1rem;
    border: 1px solid var(--hdn-guide-line);
    background: rgba(246, 242, 234, 0.68);
    color: var(--hdn-guide-ink);
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    white-space: nowrap;
}

.hdn-guide-progress {
    height: 4px;
    background: rgba(15, 23, 42, 0.12);
}

.hdn-guide-progress-bar {
    width: 0;
    height: 100%;
    background: linear-gradient(90deg, var(--hdn-guide-gold), var(--hdn-guide-ink));
    transition: width 0.26s ease;
}

.hdn-guide-layout {
    display: grid;
    grid-template-columns: minmax(240px, 0.32fr) minmax(0, 1fr);
    min-height: 620px;
}

.hdn-guide-index-panel {
    min-width: 0;
    padding: clamp(1rem, 2.4vw, 1.5rem);
    border-right: 1px solid var(--hdn-guide-line);
    background: var(--hdn-guide-ink);
    color: var(--hdn-color-ivory, #f6f2ea);
}

.hdn-guide-index-panel__title {
    margin: 0 0 1rem;
}

.hdn-guide-index {
    display: grid;
    gap: 0;
    margin: 0;
    padding: 0;
    list-style: none;
}

.hdn-guide-index button {
    display: grid;
    grid-template-columns: 2.25rem minmax(0, 1fr);
    gap: 0.8rem;
    align-items: start;
    width: 100%;
    padding: 0.85rem 0;
    border: 0;
    border-top: 1px solid rgba(246, 242, 234, 0.14);
    background: transparent;
    color: rgba(246, 242, 234, 0.72);
    cursor: pointer;
    text-align: left;
}

.hdn-guide-index button span {
    color: var(--hdn-guide-gold);
    font-size: 0.7rem;
    font-weight: 900;
    letter-spacing: 0.12em;
}

.hdn-guide-index button strong {
    color: inherit;
    font-size: 0.88rem;
    line-height: 1.35;
}

.hdn-guide-index button:hover,
.hdn-guide-index button:focus-visible,
.hdn-guide-index button.is-active {
    color: #ffffff;
    outline: 0;
}

.hdn-guide-index button:focus-visible strong {
    text-decoration: underline;
    text-underline-offset: 0.22em;
}

.hdn-guide-card {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(300px, 0.9fr);
    min-width: 0;
    background: var(--hdn-guide-surface);
}

.hdn-guide-media {
    position: relative;
    min-width: 0;
    min-height: 620px;
    background: #e9dfcf;
    overflow: hidden;
}

.hdn-guide-media::after {
    content: "";
    position: absolute;
    inset: auto 0 0;
    height: 42%;
    background: linear-gradient(180deg, transparent, rgba(15, 23, 42, 0.2));
    pointer-events: none;
}

.hdn-guide-media :is(img, video) {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hdn-guide-media video {
    background: var(--hdn-guide-ink);
}

.hdn-guide-media.is-video::after {
    display: none;
}

.hdn-guide-body {
    display: flex;
    flex-direction: column;
    min-width: 0;
    padding: clamp(1.2rem, 3vw, 2.6rem);
    border-left: 1px solid var(--hdn-guide-line);
}

.hdn-guide-body h3 {
    max-width: 12ch;
    margin: 0;
    color: var(--hdn-guide-ink);
    font-family: var(--global-heading-font-family, Georgia, serif);
    font-size: clamp(2rem, 3.6vw, 4rem);
    line-height: 0.98;
    letter-spacing: -0.045em;
}

#hdnGuideText {
    margin: clamp(1rem, 2vw, 1.4rem) 0 0;
    color: var(--hdn-guide-muted);
    font-size: clamp(1rem, 1.08vw, 1.14rem);
    line-height: 1.78;
}

.hdn-guide-tips {
    display: grid;
    gap: 0.7rem;
    margin: clamp(1.2rem, 2.4vw, 1.8rem) 0 0;
    padding: 0;
    list-style: none;
}

.hdn-guide-tips li {
    position: relative;
    padding-left: 1.15rem;
    color: rgba(15, 23, 42, 0.82);
    line-height: 1.62;
}

.hdn-guide-tips li::before {
    content: "";
    position: absolute;
    top: 0.72em;
    left: 0;
    width: 0.42rem;
    height: 1px;
    background: var(--hdn-guide-gold);
}

.hdn-guide-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: auto;
    padding-top: clamp(2rem, 5vw, 4rem);
}

.hdn-guide-controls .hdn-guide-btn {
    min-width: 150px;
}

.hdn-guide-controls .hdn-guide-btn:disabled,
.hdn-guide-controls .hdn-guide-btn[disabled] {
    border-color: rgba(15, 23, 42, 0.14);
    background: rgba(15, 23, 42, 0.05);
    color: rgba(15, 23, 42, 0.35);
    cursor: not-allowed;
    transform: none;
}

.hdn-guide-hint {
    margin: 0.9rem 0 0;
    color: rgba(15, 23, 42, 0.52);
    font-size: 0.82rem;
    line-height: 1.5;
}

.hdn-guide-bottom-cta {
    margin-top: var(--hdn-story-gap, clamp(2.5rem, 6vw, 6rem));
}

@media (max-width: 1180px) {
    .hdn-guide-hero,
    .hdn-guide-layout,
    .hdn-guide-card {
        grid-template-columns: 1fr;
    }

    .hdn-guide-hero {
        min-height: auto;
    }

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

    .hdn-guide-index {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0 1rem;
    }

    .hdn-guide-body {
        border-left: 0;
        border-top: 1px solid var(--hdn-guide-line);
    }

    .hdn-guide-media {
        min-height: clamp(320px, 56vw, 560px);
    }
}

@media (max-width: 860px) {
    .hdn-guide-prep,
    .hdn-guide-hero__stats {
        grid-template-columns: 1fr;
    }

    .hdn-guide-head {
        grid-template-columns: 1fr;
        align-items: start;
    }

    .hdn-guide-stepcount {
        justify-self: start;
    }
}

@media (max-width: 640px) {
    .hdn-guide-hero {
        padding-top: clamp(3rem, 12vw, 4.6rem);
    }

    .hdn-guide-hero__media :is(img, video) {
        min-height: 280px;
    }

    .hdn-guide-hero__actions,
    .hdn-guide-btn,
    .hdn-guide-controls .hdn-guide-btn {
        width: 100%;
    }

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

    .hdn-guide-card {
        display: block;
    }

    .hdn-guide-media {
        min-height: 320px;
    }

    .hdn-guide-controls {
        flex-direction: column;
    }
}

@media (prefers-reduced-motion: reduce) {
    .hdn-guide-btn,
    .hdn-guide-progress-bar {
        transition-duration: 0.01ms !important;
    }
}
