/* Shared navigation layout; the homepage keeps its dark engraving palette. */
html { scrollbar-gutter: stable; }

/* Keyboard navigation stays clear of the fixed header. */
body #content,
body #content :where(a, button, input, select, textarea, [tabindex]) {
    scroll-margin-top: calc(var(--ml-header-height, 76px) + var(--ml-header-offset, 0px) + 16px);
    scroll-margin-bottom: 20px;
}
body .ml-skip-link {
    position: fixed;
    top: calc(var(--ml-header-offset, 0px) + 8px);
    left: var(--ml-frame-gutter, 22px);
    z-index: 10025;
    display: flex;
    align-items: center;
    min-height: 44px;
    max-width: calc(100% - 28px);
    padding: 10px 18px;
    background: #c3a35f;
    color: #171512;
    font: 600 14px/1.5 'Instrument Sans', Arial, sans-serif;
    text-decoration: none;
    clip-path: inset(50%);
    opacity: 0;
    pointer-events: none;
}
body .ml-skip-link:focus {
    clip-path: none;
    opacity: 1;
    pointer-events: auto;
    outline: 2px solid #171512;
    outline-offset: 2px;
}

.ml-site-footer .ml-footer-policies {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0 clamp(16px, 2vw, 28px);
    min-width: 0;
    padding: 0;
    border: 0;
    grid-area: policies;
}
.ml-site-footer .ml-footer-policies a {
    display: flex;
    align-items: center;
    min-height: 44px;
    color: #d2cbc0;
    font-size: 13px;
    line-height: 1.5;
    text-decoration: none;
}
.ml-site-footer .ml-footer-policies a:hover { color: #fff; text-decoration: underline; text-underline-offset: 5px; }
.ml-site-footer .ml-footer-policies a:focus-visible { outline: 2px solid #c3a35f; outline-offset: 3px; }
body {
    --ml-control-radius: 2px;
    --ml-control-ink: #211b17;
    --ml-control-gold: #c3a35f;
    --ml-control-line: #dedad2;
    --ml-header-height: 76px;
    --ml-header-offset: 0px;
    --ml-frame-gutter: 22px;
}
body.admin-bar { --ml-header-offset: var(--wp-admin--admin-bar--height, 32px); }
body .ml-site-header.ml-brand-header {
    --ml-header-top: rgba(255,255,255,.88);
    --ml-header-solid: #fff;
    --ml-header-ink: #171512;
    --ml-header-line: #e4e1db;
    --ml-header-focus: #71531e;
    --ml-header-logo-filter: none;
}
/* Keep one toolbar offset across the transparent, scrolled and open states. */
body .ml-site-header.ml-brand-header,
body.home .ml-site-header.ml-brand-header,
body.home .ml-site-header.ml-brand-header:not(.is-scrolled):not(.is-menu-open) {
    height: var(--ml-header-height) !important;
    min-height: var(--ml-header-height) !important;
    top: var(--ml-header-offset) !important;
    z-index: 10020 !important;
}
body.home .ml-site-header.ml-brand-header {
    --ml-header-top: transparent;
    --ml-header-solid: #000;
    --ml-header-ink: #f5eee2;
    --ml-header-line: #292722;
    --ml-header-focus: #d4b778;
    --ml-header-logo-filter: brightness(0) invert(1);
}
body .ml-site-header.ml-brand-header,
body.home .ml-site-header.ml-brand-header:not(.is-scrolled):not(.is-menu-open) {
    background: var(--ml-header-top) !important;
    color: var(--ml-header-ink) !important;
    border-bottom: 1px solid transparent !important;
    box-shadow: none !important;
    backdrop-filter: blur(5px) !important;
    -webkit-backdrop-filter: blur(5px);
    transition: background-color 180ms ease, border-color 180ms ease;
}
body.home .ml-site-header.ml-brand-header:not(.is-scrolled):not(.is-menu-open) {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none;
}

body .ml-site-header.ml-brand-header.is-scrolled,
body .ml-site-header.ml-brand-header.is-menu-open {
    background: var(--ml-header-solid) !important;
    border-bottom-color: var(--ml-header-line) !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none;
}

body .ml-site-header.ml-brand-header .ml-logo img,
body .ml-site-header.ml-brand-header.is-scrolled .ml-logo img,
body .ml-site-header.ml-brand-header.is-menu-open .ml-logo img {
    filter: var(--ml-header-logo-filter) !important;
}

body .ml-site-header.ml-brand-header .ml-nav a,
body .ml-site-header.ml-brand-header.is-menu-open .ml-nav a,
body .ml-site-header.ml-brand-header .ml-cart-link,
body .ml-site-header.ml-brand-header .ml-menu-toggle {
    color: var(--ml-header-ink) !important;
    text-shadow: none !important;
}

body .ml-site-header.ml-brand-header .ml-header-inner,
body .ml-site-header.ml-brand-header.is-scrolled .ml-header-inner,
body .ml-site-header.ml-brand-header.is-menu-open .ml-header-inner {
    box-sizing: border-box !important;
    display: grid !important;
    grid-template-columns: minmax(0,1fr) auto 44px !important;
    align-items: center !important;
    gap: 28px !important;
    width: 100% !important;
    max-width: var(--ml-wrap,1180px) !important;
    height: var(--ml-header-height) !important;
    min-height: var(--ml-header-height) !important;
    padding: 8px var(--ml-frame-gutter) !important;
    margin-inline: auto !important;
}
body .ml-site-header.ml-brand-header .ml-logo {
    grid-area: 1 / 1 !important;
    min-width: 0 !important;
    width: fit-content !important;
    max-width: 100% !important;
    min-height: 44px;
    align-items: center !important;
}
body .ml-site-header.ml-brand-header .ml-header-inner .ml-logo img {
    width: clamp(180px,20vw,248px) !important;
    max-width: 100% !important;
    height: auto !important;
    max-height: 52px !important;
}
body .ml-site-header.ml-brand-header .ml-nav { grid-area: 1 / 2 !important; }
body .ml-site-header.ml-brand-header .ml-nav ul { gap: 24px !important; }
body .ml-site-header.ml-brand-header .ml-cart-link {
    grid-area: 1 / 3 !important;
    width: 44px !important;
    min-width: 44px !important;
    height: 44px !important;
    min-height: 44px !important;
    margin: 0 !important;
}
body .ml-site-header.ml-brand-header .ml-cart-icon { width: 30px !important; height: 30px !important; }

body .ml-site-header.ml-brand-header .ml-nav a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    font-size: 12px !important;
    font-weight: 600 !important;
    letter-spacing: .09em !important;
}

body .ml-site-header.ml-brand-header .ml-nav a[aria-current],
body .ml-site-header.ml-brand-header.is-menu-open .ml-nav a[aria-current] {
    color: var(--ml-header-focus) !important;
    text-decoration: underline !important;
    text-decoration-thickness: 1px !important;
    text-underline-offset: 7px;
}

body .ml-site-header.ml-brand-header .ml-menu-toggle,
body .ml-site-header.ml-brand-header.is-menu-open .ml-menu-toggle {
    background: transparent !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
}

body .ml-site-header.ml-brand-header a:focus-visible,
body .ml-site-header.ml-brand-header button:focus-visible {
    outline: 2px solid var(--ml-header-focus) !important;
    outline-offset: 4px;
}

body .ml-site-footer.ml-brand-footer {
    position: relative;
    isolation: isolate;
    overflow: clip;
    background: #000 !important;
    color: #b7b0a6;
    border-top: 1px solid #27241f;
}

body .ml-site-footer.ml-brand-footer::before {
    content: '';
    position: absolute;
    inset: auto calc(var(--ml-wood-width) * -.12) calc(var(--ml-wood-width) * -.58) auto;
    width: var(--ml-wood-width);
    aspect-ratio: 5881 / 5445;
    z-index: -1;
    pointer-events: none;
    background: var(--ml-wood-image) no-repeat center / 100% 100%;
    opacity: .08;
}

body .ml-site-footer.ml-brand-footer .ml-footer-grid {
    box-sizing: border-box;
    width: 100%;
    max-width: var(--ml-wrap,1180px) !important;
    margin-inline: auto;
    padding: 56px var(--ml-frame-gutter) 40px !important;
    grid-template-columns: 1.2fr 1fr 1fr;
    gap: 64px;
    border: 0;
    background: transparent;
}

body .ml-site-footer.ml-brand-footer .ml-footer-grid strong {
    color: #f5eee2;
    font: 400 22px/1.3 Georgia, 'Times New Roman', serif;
    margin-bottom: 16px;
}
body .ml-site-footer.ml-brand-footer .ml-footer-logo {
    display: flex;
    align-items: center;
    width: fit-content;
    max-width: 100%;
    min-height: 44px;
    margin-bottom: 22px;
}
body .ml-site-footer.ml-brand-footer .ml-footer-logo img {
    display: block;
    width: 224px;
    max-width: 100%;
    height: auto;
    filter: brightness(0) invert(1);
}
body .ml-site-footer.ml-brand-footer .ml-footer-brand p { max-width: 36ch; }

body .ml-site-footer.ml-brand-footer .ml-footer-grid p,
body .ml-site-footer.ml-brand-footer .ml-footer-grid a {
    color: #b7b0a6;
    font-size: 14px;
    line-height: 1.8;
}

body .ml-site-footer.ml-brand-footer .ml-footer-grid a:hover {
    color: #d4b778;
    text-decoration: underline;
    text-underline-offset: 4px;
}

body .ml-site-footer.ml-brand-footer a:focus-visible {
    outline: 2px solid #d4b778;
    outline-offset: 4px;
}

body .ml-site-footer.ml-brand-footer .ml-footer-bottom {
    background: transparent;
    border-top: 1px solid #27241f;
    color: #b7b0a6;
    font-size: 12px;
    padding-block: 14px;
}

body .ml-site-footer .ml-footer-bottom .ml-footer-meta {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr) auto;
    grid-template-areas: 'credit policies copyright';
    align-items: center;
    gap: 12px 28px;
}
body .ml-site-footer .ml-footer-bottom .ml-footer-meta::before { content: none; }
.ml-site-footer .ml-footer-credit {
    grid-area: credit;
    display: inline-flex;
    align-items: center;
    justify-content: flex-start;
    width: 52px;
    min-height: 44px;
    text-decoration: none;
}
.ml-site-footer .ml-footer-credit img {
    display: block;
    width: 52px;
    height: auto;
    opacity: .24;
    transition: opacity 180ms ease;
}
/* A quiet signature: reveal only on pointer intent, with a visible touch fallback. */
@media (hover: hover) and (pointer: fine) {
    .ml-site-footer .ml-footer-credit img {
        opacity: 0;
        clip-path: inset(0 100% 0 0);
        transform: translateY(3px);
        transition: opacity 180ms ease, clip-path 220ms ease, transform 220ms ease;
    }
    .ml-site-footer .ml-footer-credit:hover img {
        clip-path: inset(0);
        transform: translateY(0);
        transition: opacity 180ms ease, clip-path 420ms cubic-bezier(.22,1,.36,1), transform 420ms cubic-bezier(.22,1,.36,1);
    }
}
.ml-site-footer .ml-footer-credit:hover img { opacity: .92; }
.ml-site-footer .ml-footer-credit:focus-visible img {
    opacity: 1;
    clip-path: inset(0);
    transform: none;
    transition: none;
}
.ml-site-footer .ml-footer-copyright {
    grid-area: copyright;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    margin: 0;
    color: #b7b0a6;
    font-size: 12px;
    line-height: 1.6;
}
.ml-site-footer .ml-footer-age {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 28px;
    height: 28px;
    border: 1px solid rgba(255,244,212,.3);
    border-radius: 50%;
    color: #e8dfce;
    font-size: 10px;
    font-weight: 600;
}
@media (max-width: 1100px) {
    body .ml-site-footer .ml-footer-bottom .ml-footer-meta {
        grid-template-columns: 52px minmax(0, 1fr);
        grid-template-areas: 'policies policies' 'credit copyright';
        gap: 8px 24px;
    }
    .ml-site-footer .ml-footer-policies { justify-content: flex-start; }
}
@media (max-width: 600px) {
    .ml-site-footer .ml-footer-policies {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0 16px;
        padding-bottom: 6px;
    }
    body .ml-site-footer .ml-footer-bottom .ml-footer-meta { gap: 6px 16px; }
    .ml-site-footer .ml-footer-copyright { font-size: 11px; }
}
@media (prefers-reduced-motion: reduce) {
    .ml-site-footer .ml-footer-credit img,
    .ml-site-footer .ml-footer-credit:hover img {
        transition: none;
        transform: none;
        clip-path: none;
    }
}

@media (max-width: 980px) {
    html.ml-menu-open { overflow: hidden !important; }
    html.ml-menu-open body::before {
        content: '';
        position: fixed;
        inset: calc(var(--ml-header-offset) + var(--ml-header-height)) 0 0 !important;
        background: rgba(0,0,0,.45);
        backdrop-filter: none;
        pointer-events: auto;
        z-index: 10008;
    }
    body .ml-site-header.ml-brand-header .ml-header-inner,
    body .ml-site-header.ml-brand-header.is-scrolled .ml-header-inner,
    body .ml-site-header.ml-brand-header.is-menu-open .ml-header-inner {
        grid-template-columns: minmax(0,1fr) 44px 44px !important;
        gap: 12px !important;
        padding-inline: var(--ml-frame-gutter) !important;
    }
    body .ml-site-header.ml-brand-header .ml-header-inner .ml-logo img { width: 224px !important; }
    body .ml-site-header.ml-brand-header .ml-cart-link { grid-area: 1 / 2 !important; }
    body .ml-site-header.ml-brand-header .ml-menu-toggle {
        display: flex !important;
        grid-area: 1 / 3 !important;
        align-items: center !important;
        justify-content: center !important;
        width: 44px !important;
        min-width: 44px !important;
        height: 44px !important;
        min-height: 44px !important;
        margin: 0 !important;
        padding: 0 !important;
    }
    body .ml-site-header.ml-brand-header .ml-menu-toggle > span:first-child { display: none !important; }
    body .ml-site-header.ml-brand-header .ml-menu-toggle-lines {
        position: relative;
        display: block;
        width: 22px;
        height: 2px;
        background: transparent !important;
    }
    body .ml-site-header.ml-brand-header .ml-menu-toggle-lines::before,
    body .ml-site-header.ml-brand-header .ml-menu-toggle-lines::after {
        content: '';
        position: absolute;
        left: 0;
        width: 22px;
        height: 2px;
        background: currentColor;
        transition: transform 180ms ease;
    }
    body .ml-site-header.ml-brand-header .ml-menu-toggle-lines::before { top: -4px; }
    body .ml-site-header.ml-brand-header .ml-menu-toggle-lines::after { top: 4px; }
    body .ml-site-header.ml-brand-header.is-menu-open .ml-menu-toggle-lines::before { top: 0; transform: rotate(45deg); }
    body .ml-site-header.ml-brand-header.is-menu-open .ml-menu-toggle-lines::after { top: 0; transform: rotate(-45deg); }
    body .ml-site-header.ml-brand-header .ml-nav,
    body .ml-site-header.ml-brand-header.is-menu-open .ml-nav {
        box-sizing: border-box !important;
        display: block !important;
        position: fixed !important;
        inset: calc(var(--ml-header-offset) + var(--ml-header-height)) 0 auto !important;
        width: 100% !important;
        max-width: none !important;
        height: auto !important;
        min-height: 0 !important;
        max-height: calc(100svh - var(--ml-header-offset) - var(--ml-header-height)) !important;
        overflow-y: auto !important;
        overscroll-behavior: contain;
        padding: 16px 24px 28px !important;
        margin: 0 !important;
        background: var(--ml-header-solid) !important;
        color: var(--ml-header-ink) !important;
        border: 0 !important;
        border-block: 1px solid var(--ml-header-line) !important;
        border-radius: 0 !important;
        box-shadow: none !important;
        transform: none !important;
        transition: opacity 150ms ease !important;
    }
    body .ml-site-header.ml-brand-header:not(.is-menu-open) .ml-nav {
        opacity: 0 !important;
        visibility: hidden !important;
        pointer-events: none !important;
    }
    body .ml-site-header.ml-brand-header .ml-nav::before { display: none !important; }
    body .ml-site-header.ml-brand-header .ml-nav ul {
        display: block !important;
        width: 100%;
        max-width: 640px;
        margin-inline: auto !important;
        padding: 0 !important;
    }
    body .ml-site-header.ml-brand-header .ml-nav li { margin: 0 !important; }
    body .ml-site-header.ml-brand-header .ml-nav a,
    body .ml-site-header.ml-brand-header.is-menu-open .ml-nav a {
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        min-height: 60px !important;
        padding: 12px 0 !important;
        font: 400 26px/1.3 Georgia, 'Times New Roman', serif !important;
        letter-spacing: -.015em !important;
        text-transform: none !important;
        text-decoration: none !important;
        color: var(--ml-header-ink) !important;
        background: transparent !important;
        border: 0 !important;
        border-bottom: 1px solid var(--ml-header-line) !important;
        border-radius: 0 !important;
    }
    body .ml-site-header.ml-brand-header .ml-nav a::after {
        content: '→';
        position: static !important;
        width: auto !important;
        height: auto !important;
        background: none !important;
        color: var(--ml-header-focus);
        font: 400 18px/1 Arial,sans-serif;
        opacity: 1;
        transform: none !important;
    }
    body .ml-site-header.ml-brand-header .ml-nav li:last-child a { border-bottom: 0 !important; }
    body .ml-site-header.ml-brand-header .ml-nav a:hover,
    body .ml-site-header.ml-brand-header .ml-nav a:focus-visible { color: var(--ml-header-focus) !important; }
    body .ml-site-footer.ml-brand-footer .ml-footer-grid { gap: 32px; }
}

@media (max-width: 720px) {
    body { --ml-header-height: 60px; --ml-frame-gutter: 14px; }
    body .ml-site-header.ml-brand-header .ml-header-inner,
    body .ml-site-header.ml-brand-header.is-scrolled .ml-header-inner,
    body .ml-site-header.ml-brand-header.is-menu-open .ml-header-inner {
        padding: 8px var(--ml-frame-gutter) !important;
        gap: 8px !important;
    }
    body .ml-site-header.ml-brand-header .ml-header-inner .ml-logo img { width: 180px !important; max-height: 38px !important; }
    body .ml-site-header.ml-brand-header.is-menu-open .ml-nav a {
        min-height: 56px !important;
        font-size: 23px !important;
    }
    body .ml-site-footer.ml-brand-footer .ml-footer-grid {
        grid-template-columns: 1fr;
        padding: 38px var(--ml-frame-gutter) 32px !important;
        gap: 28px;
    }
    body .ml-site-footer.ml-brand-footer::before { background-position: center; opacity: .08; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    body .ml-cart-trolley, body .ml-cart-spark { animation: none !important; }
    body .ml-site-header.ml-brand-header,
    body.home .ml-site-header.ml-brand-header:not(.is-scrolled):not(.is-menu-open),
    body .ml-site-header.ml-brand-header .ml-nav,
    body .ml-site-header.ml-brand-header.is-menu-open .ml-nav,
    body .ml-site-header.ml-brand-header .ml-menu-toggle-lines::before,
    body .ml-site-header.ml-brand-header .ml-menu-toggle-lines::after { transition: none !important; }
}

/* Clipping horizontal overflow must not create a second scroll container for sticky navigation. */
@supports (overflow-x: clip) {
    @media (max-width: 980px) {
        html body {
            overflow-x: clip !important;
            overflow-y: visible !important;
        }
        /* Overlay scroll locking stays on html; body must not become a separate scroller. */
        html:is(.ml-menu-open, .ml-shop-filter-open, .ml-cart-drawer-open, .ml-age-gate-open, .ml-selection-drawer-open) body {
            overflow: clip visible !important;
        }
    }
}

/* Every surface crops the same engraving at the same responsive scale. */
body {
    --ml-scene-width: min(150vw, 1880px);
    --ml-wood-width: calc(var(--ml-scene-width) * .42388);
    --ml-wood-image: url('../artwork/wood-repeat-v2.svg');
}
body .ml-cart-drawer .ml-cart-drawer-head { overflow: hidden; }
@media (max-width: 980px) {
    body { --ml-scene-width: 1400px; }
    body .ml-site-header.ml-brand-header .ml-nav { isolation: isolate; }
    body .ml-site-header.ml-brand-header .ml-nav::before {
        content: '';
        display: block !important;
        position: absolute;
        inset: 0;
        background: var(--ml-wood-image) no-repeat right -40px center / var(--ml-wood-width) auto;
        filter: brightness(0);
        opacity: .045;
        pointer-events: none;
        z-index: -1;
    }
    body.home .ml-site-header.ml-brand-header .ml-nav::before { filter: none; opacity: .1; }
}
@media (max-width: 600px) {
    body { --ml-scene-width: 240vw; }
}

/* Shared brand profiles in the footer and contact page. */
body .ml-brand-social { display: flex; flex-wrap: wrap; gap: 8px 24px; margin-top: 16px; }
body .ml-brand-social a { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; color: #71531e; font: 400 14px/1.5 var(--ml-font-body, 'Instrument Sans', Arial, sans-serif); text-decoration: none; }
body .ml-brand-social svg { flex: 0 0 18px; }
body .ml-site-footer .ml-brand-social a { color: #c6b48f; }
body .ml-brand-social a:hover { text-decoration: underline; text-underline-offset: 5px; }
body .ml-brand-social a:focus-visible { outline: 2px solid currentColor; outline-offset: 4px; }
