/* Jameel Traders storefront. Ink, bone and one vermilion accent. */

@font-face { font-family: 'Instrument Serif'; src: url('../fonts/instrument-serif-latin-400-normal.woff2') format('woff2'); font-display: swap; }
@font-face { font-family: 'Instrument Serif'; font-style: italic; src: url('../fonts/instrument-serif-latin-400-italic.woff2') format('woff2'); font-display: swap; }
@font-face { font-family: 'Instrument Sans'; font-weight: 400 700; src: url('../fonts/instrument-sans-latin-wght-normal.woff2') format('woff2'); font-display: swap; }

:root {
    --ink: #171513;
    --ink-2: #2A2622;
    --bone: #F3EEE4;
    --paper: #FBF8F2;
    --sand: #E4DCCB;
    --muted: #6E665B;
    --muted-on-ink: #A89F90;
    --accent: #C8401E;
    --accent-deep: #A83216;
    --line: rgba(23, 21, 19, .14);
    --line-on-ink: rgba(243, 238, 228, .16);
    --serif: 'Instrument Serif', Georgia, 'Times New Roman', serif;
    --sans: 'Instrument Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --gutter: clamp(1.125rem, 4vw, 3.5rem);
    --section: clamp(4rem, 9vw, 8rem);
    --header: 4.5rem;
}

/* Product label colours, one per department */
.tone-0 { --tile: #171513; --on-tile: #F3EEE4; }
.tone-1 { --tile: #5B1E1A; --on-tile: #F6E7D8; }
.tone-2 { --tile: #1E3A31; --on-tile: #EDE6D2; }
.tone-3 { --tile: #D9CDB6; --on-tile: #231E18; }
.tone-4 { --tile: #2C3942; --on-tile: #E9E6DD; }
.tone-5 { --tile: #C8401E; --on-tile: #FFF4E9; }
.tone-6 { --tile: #71492A; --on-tile: #F8EBDA; }
.tone-7 { --tile: #C6A152; --on-tile: #231A0C; }
.tone-8 { --tile: #3A2336; --on-tile: #F1E5E0; }
.tone-9 { --tile: #EDE5D5; --on-tile: #231E18; }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header) + 1rem); }
html:has(dialog[open]) { overflow: hidden; }
body {
    margin: 0;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    background: var(--paper);
    color: var(--ink);
    font: 400 1rem/1.55 var(--sans);
    -webkit-font-smoothing: antialiased;
    overflow-x: clip;
}
main { flex: 1; }
h1, h2, h3, p, ul, ol, dl, dd, fieldset, figure { margin: 0; padding: 0; }
ul, ol { list-style: none; }
fieldset { border: 0; min-width: 0; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; padding: 0; cursor: pointer; }
[hidden] { display: none !important; }
address { font-style: normal; }
h1, h2 { font-family: var(--serif); font-weight: 400; letter-spacing: -.012em; line-height: 1.02; }
h1 em, h2 em { font-style: italic; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.wrap { width: 100%; max-width: 1480px; margin-inline: auto; padding-inline: var(--gutter); }
.icon { width: 1.25em; height: 1.25em; flex: none; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip-link { position: absolute; left: 1rem; top: -4rem; z-index: 100; padding: .6rem 1rem; background: var(--ink); color: var(--bone); }
.skip-link:focus { top: .75rem; }
.eyebrow { font-size: .75rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; }

/* Buttons */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: .65rem;
    min-height: 3.25rem; padding: .75rem 1.6rem;
    border: 1px solid transparent; border-radius: 2px;
    font-weight: 600; font-size: .9375rem; white-space: nowrap;
    transition: background-color .2s, color .2s, border-color .2s;
}
.btn .icon { transition: transform .25s; }
.btn:hover .icon { transform: translateX(4px); }
.btn--block { width: 100%; }
.btn--accent { background: var(--accent); color: #fff; }
.btn--accent:hover { background: var(--accent-deep); }
.btn--dark { background: var(--ink); color: var(--bone); }
.btn--dark:hover { background: var(--ink-2); }
.btn--ghost { border-color: var(--line-on-ink); color: var(--bone); }
.btn--ghost:hover { border-color: var(--bone); }
.btn.is-busy { opacity: .6; cursor: progress; }
.link-arrow { display: inline-flex; align-items: center; gap: .5rem; font-weight: 600; font-size: .9375rem; white-space: nowrap; }
.link-arrow .icon { transition: transform .25s; }
.link-arrow:hover .icon { transform: translateX(4px); }

/* Logo */
.logo { display: inline-flex; align-items: center; gap: .7rem; }
.logo__mark { width: 2.5rem; height: 2.5rem; flex: none; }
.logo__word { font-family: var(--serif); font-size: 1.5rem; line-height: 1; letter-spacing: -.01em; white-space: nowrap; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 30; background: var(--paper); border-bottom: 1px solid var(--line); }
.site-header__bar { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 1.5rem; height: var(--header); }
.site-nav { display: flex; gap: 2.25rem; font-size: .9375rem; font-weight: 500; }
.site-nav a { position: relative; padding-block: .35rem; }
.site-nav a::after { content: ''; position: absolute; inset: auto 0 0; height: 1px; background: currentColor; transform: scaleX(0); transform-origin: left; transition: transform .25s; }
.site-nav a:hover::after, .site-nav a[aria-current]::after { transform: scaleX(1); }
.site-header__actions { display: flex; align-items: center; justify-content: flex-end; gap: 1.25rem; }
.header-search { position: relative; display: flex; align-items: center; gap: .5rem; width: min(15rem, 100%); padding-bottom: .3rem; border-bottom: 1px solid var(--line); color: var(--muted); transition: border-color .2s; }
.header-search:focus-within { border-color: var(--ink); color: var(--ink); }
.header-search input, .menu__search input, .shop__search input { flex: 1; min-width: 0; border: 0; outline: 0; background: none; color: var(--ink); }
input[type='search']::-webkit-search-cancel-button { display: none; }
.cart-button { display: inline-flex; align-items: center; gap: .45rem; min-height: 2.75rem; font-weight: 600; font-size: .9375rem; }
.cart-button__count { display: none; min-width: 1.4rem; height: 1.4rem; padding-inline: .35rem; place-items: center; border-radius: 1rem; background: var(--accent); color: #fff; font-size: .75rem; font-weight: 700; }
.cart-button__count.is-on { display: inline-grid; }
.menu-button, .icon-button { display: inline-grid; place-items: center; width: 2.75rem; height: 2.75rem; }
.menu-button { display: none; margin-right: -.6rem; }

/* Sheets: cart drawer and mobile menu */
.sheet {
    position: fixed; inset: 0 0 0 auto;
    width: min(28rem, 100vw); max-width: 100vw; height: 100dvh; max-height: 100dvh;
    margin: 0; padding: 0; border: 0;
    background: var(--paper); color: var(--ink);
    overflow: hidden;
}
.sheet[open] { display: flex; flex-direction: column; animation: sheet-in .32s cubic-bezier(.2, .8, .2, 1); }
.sheet::backdrop { background: rgba(23, 21, 19, .55); animation: fade-in .25s; }
@keyframes sheet-in { from { transform: translateX(100%); } }
@keyframes fade-in { from { opacity: 0; } }
.sheet__head { display: flex; align-items: center; justify-content: space-between; min-height: var(--header); padding-inline: 1.5rem; border-bottom: 1px solid var(--line); flex: none; }
.sheet__head h2 { font-size: 1.75rem; }
.sheet__head .icon-button { margin-right: -.6rem; }
.drawer__lines { flex: 1; overflow-y: auto; padding-inline: 1.5rem; }
.drawer__empty { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1.25rem; padding: 2rem; font-family: var(--serif); font-size: 1.75rem; }
.drawer__empty .btn { font-family: var(--sans); }
.drawer__foot { flex: none; display: grid; gap: 1rem; padding: 1.25rem 1.5rem calc(1.25rem + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); }
.drawer__foot .total-row { border: 0; padding: 0; }
.drawer__note { text-align: center; font-size: .8125rem; color: var(--muted); }
.menu { width: 100vw; background: var(--ink); color: var(--bone); }
.menu .sheet__head { border-color: var(--line-on-ink); }
.menu__links { display: grid; padding: 1.5rem; }
.menu__links a { padding-block: .6rem; font-family: var(--serif); font-size: clamp(2.75rem, 14vw, 4rem); line-height: 1.1; border-bottom: 1px solid var(--line-on-ink); }
.menu__search { position: relative; display: flex; align-items: center; gap: .6rem; margin: 1.25rem 1.5rem 0; padding: .85rem 1rem; background: var(--paper); color: var(--ink); }

/* Cart lines */
.line { display: flex; justify-content: space-between; gap: 1rem; padding-block: 1.1rem; border-bottom: 1px solid var(--line); }
.line:last-child { border-bottom: 0; }
.line__body { min-width: 0; }
.line__name { font-weight: 600; line-height: 1.3; }
.line__unit { margin-bottom: .6rem; font-size: .8125rem; color: var(--muted); }
.line__side { display: flex; flex-direction: column; align-items: flex-end; justify-content: space-between; flex: none; }
.line__remove { font-size: .8125rem; color: var(--muted); text-decoration: underline; text-underline-offset: 3px; min-height: 2rem; }
.line__remove:hover { color: var(--accent); }
.total-row { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; padding-block: 1rem; border-top: 1px solid var(--line); }
.total-row strong { font-family: var(--serif); font-size: 1.875rem; font-weight: 400; line-height: 1; white-space: nowrap; }

.stepper { display: inline-flex; align-items: center; height: 2.25rem; border: 1px solid var(--ink); border-radius: 2px; }
.stepper button { display: grid; place-items: center; width: 2.25rem; height: 100%; transition: background-color .15s, color .15s; }
.stepper button:hover { background: var(--ink); color: var(--bone); }
.stepper output { min-width: 1.75rem; text-align: center; font-weight: 600; font-size: .9375rem; font-variant-numeric: tabular-nums; }
.stepper .icon { width: 1rem; height: 1rem; }

/* Hero */
.hero { background: var(--ink); color: var(--bone); overflow: hidden; }
.hero__grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: clamp(2rem, 5vw, 5rem); align-items: center; min-height: min(46rem, calc(100dvh - var(--header) - 3.25rem)); }
.hero__copy { padding-block: clamp(3.5rem, 8vw, 6rem); }
.hero .eyebrow { color: var(--muted-on-ink); margin-bottom: 1.5rem; }
.hero h1 { font-size: clamp(3.25rem, 8.2vw, 7.75rem); line-height: .96; }
.hero h1 em { display: block; color: #F0795A; }
.hero__lead { max-width: 30rem; margin-top: 1.75rem; font-size: clamp(1.0625rem, 1.5vw, 1.25rem); line-height: 1.5; color: #D5CDBE; }
.hero__actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2.25rem; }
.hero__shelf { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; align-self: stretch; height: 0; min-height: 100%; overflow: hidden; -webkit-mask-image: linear-gradient(transparent, #000 10%, #000 90%, transparent); mask-image: linear-gradient(transparent, #000 10%, #000 90%, transparent); }
.hero__column { display: flex; flex-direction: column; gap: 1rem; animation: drift 70s linear infinite; }
.hero__column:nth-child(2) { animation-direction: reverse; }
.hero__column .art { flex: none; }
@keyframes drift { to { transform: translateY(calc(-50% - .5rem)); } }

.hero .art { background: #24201C; }
.hero .pack__shadow { fill: rgba(0, 0, 0, .4); }

/* Ticker */
.ticker { overflow: hidden; background: var(--accent); color: #fff; }
.ticker__track { display: flex; width: max-content; animation: slide 60s linear infinite; }
.ticker span { display: flex; align-items: center; height: 3.25rem; font-family: var(--serif); font-size: 1.375rem; white-space: nowrap; }
.ticker span::after { content: '/'; margin-inline: 1.75rem; opacity: .55; }
@keyframes slide { to { transform: translateX(-50%); } }

/* Sections */
.section { padding-block: var(--section); }
.section--tint { background: var(--bone); }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 1.5rem; margin-bottom: clamp(2rem, 4vw, 3.5rem); }
.section-head .eyebrow { margin-bottom: .75rem; color: var(--accent); }
.section-head h2 { font-size: clamp(2.5rem, 5.5vw, 4.75rem); }

/* Department index */
.depts { display: grid; grid-template-columns: 1fr 1fr; column-gap: clamp(2rem, 5vw, 5rem); border-top: 1px solid var(--ink); }
.depts li { border-bottom: 1px solid var(--line); }
.depts__row { position: relative; display: grid; grid-template-columns: 2.5rem 1fr auto 1.5rem; align-items: baseline; gap: .75rem; padding: 1.15rem .75rem 1.15rem 0; isolation: isolate; transition: color .2s, padding .25s; }
.depts__row::before { content: ''; position: absolute; inset: 0; z-index: -1; background: var(--tile); transform: scaleY(0); transform-origin: bottom; transition: transform .25s cubic-bezier(.2, .8, .2, 1); }
.depts__index { font-size: .8125rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.depts__name { font-family: var(--serif); font-size: clamp(1.625rem, 2.6vw, 2.375rem); line-height: 1.1; }
.depts__count { font-size: .875rem; color: var(--muted); }
.depts__row .icon { align-self: center; opacity: 0; transform: translateX(-6px); transition: opacity .2s, transform .25s; }
@media (hover: hover) {
    .depts__row:hover { color: var(--on-tile); padding-left: .85rem; }
    .depts__row:hover::before { transform: scaleY(1); }
    .depts__row:hover .depts__index, .depts__row:hover .depts__count { color: inherit; }
    .depts__row:hover .icon { opacity: 1; transform: none; }
}

/* Product art: a drawn pack on a soft tile, sized off the tile's own width */
.art { container-type: inline-size; position: relative; aspect-ratio: 1; overflow: hidden; border-radius: 2px; background: color-mix(in srgb, var(--tile) 10%, #F6F1E7); }
.art__photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; background: #fff; transition: transform .5s cubic-bezier(.2, .8, .2, 1); }
.pack { position: absolute; inset: 7%; transition: transform .4s cubic-bezier(.2, .8, .2, 1); }
.pack svg { display: block; width: 100%; height: 100%; }
.pack__body { fill: var(--tile); }
.pack__dark { fill: color-mix(in srgb, var(--tile) 74%, #000); }
.pack__metal { fill: #CFC7B7; }
.pack__fill { fill: color-mix(in srgb, var(--tile) 62%, #E8DFCB); }
.pack__wood { fill: #B4915F; }
.pack__produce-a { fill: #A5472F; }
.pack__produce-b { fill: #66763A; }
.pack__produce-c { fill: #C2922F; }
.pack__seam { fill: none; stroke: #8F7044; stroke-width: 2; }
.pack__shadow { fill: rgba(23, 21, 19, .13); }
.pack__label { position: absolute; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1.2cqi; padding: 1.2cqi; overflow: hidden; background: #FBF7EE; color: var(--ink); text-align: center; }
.pack__name { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; font-family: var(--serif); font-size: 5cqi; line-height: 1.06; overflow-wrap: anywhere; }
.pack__size { font-size: 2.9cqi; font-weight: 600; letter-spacing: .06em; white-space: nowrap; color: var(--muted); }

/* Product grid and card */
.grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(2rem, 3vw, 2.75rem) clamp(.875rem, 1.6vw, 1.5rem); }
.card { display: flex; flex-direction: column; min-width: 0; }
.card__media { display: block; }
.card:hover .pack { transform: translateY(-2.5%) scale(1.03); }
.card:hover .art__photo { transform: scale(1.04); }
.card--out .art { filter: grayscale(.7); opacity: .6; }
.card__dept { margin-top: .85rem; font-size: .75rem; color: var(--muted); }
.card__name { font-size: 1rem; font-weight: 600; line-height: 1.3; }
.card__media + .card__name { margin-top: .85rem; }
.card__name a:hover { color: var(--accent-deep); }
.card__row { display: flex; align-items: baseline; justify-content: space-between; gap: .5rem; margin-top: auto; padding-block: .5rem .6rem; }
.price { font-weight: 600; font-size: 1.0625rem; font-variant-numeric: tabular-nums; white-space: nowrap; }
.card__note { font-size: .75rem; line-height: 1.2; color: var(--accent-deep); white-space: nowrap; }
.card__out { font-size: .8125rem; color: var(--muted); }
.buy { display: flex; gap: .5rem; }
.buy > * { flex: 1 1 0; min-width: 0; }
.buy__add, .buy__now { min-height: 2.5rem; padding-inline: .5rem; border: 1px solid var(--ink); border-radius: 2px; font-size: .875rem; font-weight: 600; white-space: nowrap; transition: background-color .15s, color .15s, border-color .15s; }
.buy__add:hover { background: var(--ink); color: var(--bone); }
.buy__now { background: var(--ink); color: var(--bone); }
.buy__now:hover { border-color: var(--accent); background: var(--accent); color: #fff; }
.buy__stepper { justify-content: space-between; height: 2.5rem; background: var(--paper); color: var(--ink); }
.buy__stepper button { flex: none; width: 2rem; }
.buy__stepper output { min-width: 1.25rem; }

/* Product page */
.crumbs { display: flex; flex-wrap: wrap; gap: .25rem .5rem; padding-block: 1.25rem; font-size: .875rem; color: var(--muted); }
.crumbs a:hover { color: var(--ink); }
.crumbs [aria-current] { color: var(--ink); }
.pdp { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(2rem, 6vw, 6rem); align-items: start; padding-bottom: var(--section); }
.pdp__art { position: sticky; top: calc(var(--header) + 1.5rem); }
.pdp__info .eyebrow { margin-bottom: 1rem; color: var(--accent); }
.pdp__info h1 { font-size: clamp(2.75rem, 5vw, 4.5rem); }
.pdp__price { display: block; margin-top: 1.25rem; font-family: var(--serif); font-weight: 400; font-size: clamp(2rem, 3vw, 2.5rem); line-height: 1; }
.pdp__stock { margin-top: .85rem; font-size: .9375rem; font-weight: 600; color: #2F6B4F; }
.pdp__stock.is-low { color: var(--accent-deep); }
.pdp__stock.is-out { color: var(--muted); }
.pdp__description { margin-top: 1.25rem; max-width: 34rem; color: var(--muted); }
.pdp .buy, .pdp .card__out { margin-top: 1.75rem; }
.pdp .card__out { display: block; }
.buy--large { max-width: 30rem; gap: .75rem; }
.buy--large .buy__add, .buy--large .buy__now { min-height: 3.5rem; font-size: 1rem; }
.buy--large .buy__now { border-color: var(--accent); background: var(--accent); color: #fff; }
.buy--large .buy__now:hover { border-color: var(--accent-deep); background: var(--accent-deep); }
.buy--large .buy__stepper { height: 3.5rem; }
.buy--large .buy__stepper button { width: 3.25rem; }
.buy--large .buy__stepper output { font-size: 1.125rem; }
.pdp__facts { margin-top: 2.25rem; border-top: 1px solid var(--ink); }
.pdp__facts div { display: flex; justify-content: space-between; gap: 1rem; padding-block: .8rem; border-bottom: 1px solid var(--line); }
.pdp__facts dt { color: var(--muted); }
.pdp__facts dd { font-weight: 600; text-align: right; }

/* How it works */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1.5rem, 4vw, 4rem); }
.steps li { padding-top: 1.25rem; border-top: 1px solid var(--ink); }
.steps span { display: block; font-family: var(--serif); font-style: italic; font-size: clamp(3.5rem, 7vw, 6rem); line-height: 1; color: var(--accent); }
.steps h3 { margin-top: 1rem; font-size: 1.125rem; font-weight: 600; }
.steps p { margin-top: .35rem; max-width: 22rem; color: var(--muted); }

/* Banner */
.banner { background: var(--accent); color: #fff; }
.banner__inner { display: grid; grid-template-columns: 1.3fr 1fr; align-items: end; gap: 2rem clamp(2rem, 6vw, 6rem); padding-block: clamp(3.5rem, 7vw, 6rem); }
.banner h2 { font-size: clamp(3rem, 8vw, 7rem); line-height: .96; }
.banner p { margin-bottom: 1.5rem; font-size: 1.125rem; line-height: 1.45; }

/* Footer */
.site-footer { background: var(--ink); color: var(--bone); padding-top: clamp(3.5rem, 6vw, 5.5rem); overflow: hidden; }
.site-footer__grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 2.5rem; }
.site-footer__lead { max-width: 24rem; font-family: var(--serif); font-size: clamp(1.625rem, 2.6vw, 2.25rem); line-height: 1.15; }
.site-footer h2 { margin-bottom: .75rem; font: 600 .75rem/1.4 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--muted-on-ink); }
.site-footer__grid a, .site-footer__grid p:not(.site-footer__lead) { display: block; padding-block: .2rem; overflow-wrap: anywhere; }
.site-footer__grid a:hover { color: #F0795A; }
.site-footer__word { margin-top: clamp(2.5rem, 6vw, 5rem); font-family: var(--serif); font-size: 19vw; line-height: .85; letter-spacing: -.02em; white-space: nowrap; }
@media (min-width: 1480px) { .site-footer__word { font-size: 281px; } }
.site-footer__legal { display: flex; justify-content: space-between; gap: 1rem; padding-block: 1.5rem; margin-top: 1.5rem; border-top: 1px solid var(--line-on-ink); font-size: .8125rem; color: var(--muted-on-ink); }
.site-footer__legal a:hover { color: var(--bone); }

/* Inner page heading */
.page-head { background: var(--ink); color: var(--bone); padding-block: clamp(2.5rem, 6vw, 4.5rem); }
.page-head .eyebrow { margin-bottom: .75rem; color: var(--muted-on-ink); }
.page-head h1 { font-size: clamp(3rem, 8vw, 6.5rem); overflow-wrap: anywhere; }
.page-head em { color: #F0795A; }
.page-head--slim { padding-block: clamp(1.75rem, 4vw, 3rem); }
.page-head--slim h1 { font-size: clamp(2.5rem, 5vw, 4rem); }

/* Shop */
.shop { display: grid; grid-template-columns: 15rem minmax(0, 1fr); gap: clamp(2rem, 4vw, 4rem); padding-block: clamp(1.5rem, 4vw, 3rem) var(--section); }
.shop__depts { position: sticky; top: calc(var(--header) + 1.5rem); align-self: start; display: grid; }
.shop__depts a { display: flex; align-items: baseline; justify-content: space-between; gap: .75rem; padding-block: .6rem; border-bottom: 1px solid var(--line); font-size: .9375rem; transition: color .15s, padding .2s; }
.shop__depts a span { font-size: .8125rem; color: var(--muted); }
.shop__depts a:hover { padding-left: .35rem; color: var(--accent-deep); }
.shop__depts a[aria-current] { font-weight: 600; color: var(--accent-deep); }
.shop__tools { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; margin-bottom: 1.75rem; padding-bottom: .75rem; border-bottom: 1px solid var(--ink); }
.shop__search { position: relative; display: flex; align-items: center; gap: .6rem; flex: 1; min-width: 0; max-width: 26rem; }
.shop__sort { display: flex; align-items: center; gap: .5rem; flex: none; font-size: .875rem; }
.shop__sort span { color: var(--muted); }
.shop__sort select { border: 0; background: none; font-weight: 600; cursor: pointer; max-width: 11rem; }
.empty { display: grid; justify-items: center; gap: 1rem; padding-block: clamp(4rem, 10vw, 7rem); text-align: center; }
.empty h2 { font-size: clamp(2.25rem, 4vw, 3.25rem); }
.empty p { color: var(--muted); }

.pager { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-top: 3.5rem; padding-top: 1.25rem; border-top: 1px solid var(--ink); font-size: .9375rem; }
.pager__edge { font-weight: 600; min-height: 2.5rem; display: inline-flex; align-items: center; }
.pager__edge.is-off { color: var(--muted); opacity: .55; }
.pager__pages { display: flex; align-items: center; gap: .25rem; }
.pager__pages a, .pager__pages span { display: grid; place-items: center; min-width: 2.5rem; height: 2.5rem; }
.pager__pages a:hover { color: var(--accent-deep); }
.pager__pages a[aria-current] { background: var(--ink); color: var(--bone); }

/* Forms */
.field { display: grid; gap: .35rem; }
.field label { display: flex; justify-content: space-between; font-size: .875rem; font-weight: 600; }
.field label span { font-weight: 400; color: var(--muted); }
.field input, .field textarea { width: 100%; padding: .7rem 0; border: 0; border-bottom: 1px solid rgba(23, 21, 19, .4); border-radius: 0; background: transparent; font-size: 1.0625rem; outline: 0; transition: border-color .2s; resize: vertical; }
.field input::placeholder { color: #958B7C; }
.field input:focus, .field textarea:focus { border-color: var(--accent); box-shadow: 0 1px 0 var(--accent); }
.field.has-error input, .field.has-error textarea { border-color: var(--accent); }
.form, .checkout fieldset { display: grid; gap: 1.5rem; }
.form__two { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
.form__trap { position: absolute; left: -9999px; }
.form .btn { justify-self: start; }
.form-title { font-size: clamp(2rem, 3.5vw, 2.75rem); margin-bottom: 2rem; }

/* Contact */
.split { display: grid; grid-template-columns: 1fr 1fr; min-height: calc(100dvh - var(--header)); }
.split__dark { background: var(--ink); color: var(--bone); }
.split__inner { width: 100%; max-width: 40rem; margin-inline: auto; padding: clamp(3rem, 7vw, 6.5rem) var(--gutter); }
.split__dark .eyebrow { margin-bottom: 1.25rem; color: var(--muted-on-ink); }
.split h1 { font-size: clamp(3.25rem, 7vw, 6.25rem); line-height: .98; }
.split h1 em { display: block; color: #F0795A; }
.split__lead { max-width: 28rem; margin-top: 1.5rem; font-size: 1.125rem; color: #D5CDBE; }
.details { margin-top: 3rem; border-top: 1px solid var(--line-on-ink); }
.details div { display: grid; grid-template-columns: 5rem minmax(0, 1fr); gap: 1rem; padding-block: .9rem; border-bottom: 1px solid var(--line-on-ink); }
.details dt { color: var(--muted-on-ink); font-size: .875rem; }
.details dd { overflow-wrap: anywhere; }
.details a:hover { color: #F0795A; }
.sent__mark { display: grid; place-items: center; width: 3.5rem; height: 3.5rem; border-radius: 50%; background: var(--accent); color: #fff; }
.sent__mark .icon { width: 1.6rem; height: 1.6rem; }

/* Checkout */
.checkout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 27rem); gap: clamp(2rem, 6vw, 6rem); align-items: start; padding-block: clamp(2rem, 5vw, 3.5rem) var(--section); }
.checkout__form { display: grid; gap: 3rem; }
.checkout legend { display: flex; align-items: center; gap: .75rem; padding: 0; margin-bottom: 1.5rem; font-family: var(--serif); font-size: 2rem; line-height: 1.1; }
.checkout legend span { font-style: italic; color: var(--accent); }
.pay-option { display: flex; gap: 1rem; padding: 1.1rem 1.25rem; border: 1px solid var(--ink); border-radius: 2px; background: var(--bone); }
.pay-option p { font-size: .9375rem; color: var(--muted); }
.pay-option__tick { display: grid; place-items: center; width: 1.5rem; height: 1.5rem; flex: none; margin-top: .1rem; border-radius: 50%; background: var(--ink); color: var(--bone); }
.pay-option__tick .icon { width: .9rem; height: .9rem; }
.summary { position: sticky; top: calc(var(--header) + 1.5rem); display: grid; gap: 1rem; padding: clamp(1.25rem, 3vw, 2rem); background: var(--bone); }
.summary h2 { font-size: 2rem; }
.summary .lines { max-height: 22rem; overflow-y: auto; }
.summary .total-row { align-items: center; border-color: var(--ink); }

/* Order placed */
.confirmed { background: var(--ink); color: var(--bone); }
.confirmed__inner { padding-block: clamp(3.5rem, 8vw, 6.5rem); }
.confirmed .eyebrow { margin-top: 1.75rem; color: var(--muted-on-ink); }
.confirmed h1 { margin-top: .75rem; font-size: clamp(3.25rem, 9vw, 7.5rem); overflow-wrap: anywhere; }
.confirmed h1 em { color: #F0795A; }
.confirmed__lead { max-width: 34rem; margin-top: 1.25rem; font-size: 1.125rem; color: #D5CDBE; }
.receipt { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: clamp(2rem, 6vw, 6rem); padding-block: clamp(2.5rem, 6vw, 4.5rem) var(--section); }
.receipt h2 { margin-bottom: 1.25rem; font-size: 2rem; }
.receipt__lines li { display: flex; justify-content: space-between; gap: 1rem; padding-block: .75rem; border-top: 1px solid var(--line); }
.receipt__lines small { color: var(--muted); font-size: .875rem; }
.receipt .total-row { border-color: var(--ink); }
.receipt .total-row .price { font: inherit; }
.receipt address { margin-bottom: 2rem; font-size: 1.0625rem; line-height: 1.6; overflow-wrap: anywhere; }

/* Live search panel */
.suggest { position: absolute; top: calc(100% + .6rem); right: 0; z-index: 40; width: min(27rem, calc(100vw - 2rem)); max-height: min(30rem, calc(100dvh - 7rem)); overflow-y: auto; background: var(--paper); color: var(--ink); border: 1px solid var(--line); border-radius: 2px; box-shadow: 0 18px 40px rgba(23, 21, 19, .16); }
.shop__search .suggest { left: 0; right: auto; }
.menu__search .suggest { left: 0; right: 0; width: auto; max-height: calc(100dvh - 11rem); }
.suggest__item { display: flex; align-items: center; gap: .85rem; padding: .6rem .85rem; border-bottom: 1px solid var(--line); transition: background-color .12s; }
.suggest__item:hover, .suggest__item:focus { background: var(--bone); outline: 0; }
.suggest__art { width: 3.25rem; flex: none; }
.suggest__text { flex: 1; min-width: 0; }
.suggest__name { display: block; font-size: .9375rem; font-weight: 600; line-height: 1.25; }
.suggest__dept { display: block; font-size: .75rem; color: var(--muted); }
.suggest__price { flex: none; font-size: .9375rem; }
.suggest__out { flex: none; font-size: .8125rem; color: var(--muted); }
.suggest__all { display: flex; align-items: center; justify-content: center; gap: .5rem; padding: .8rem; font-size: .875rem; font-weight: 600; }
.suggest__all:hover, .suggest__all:focus { background: var(--ink); color: var(--bone); outline: 0; }
.suggest__empty { padding: 1.25rem; text-align: center; font-size: .9375rem; color: var(--muted); }

/* SweetAlert, in the store's own style */
.alert.swal2-popup { border-radius: 2px; color: var(--ink); font-family: var(--sans); }
.alert .swal2-title { font-family: var(--serif); font-size: 2rem; font-weight: 400; line-height: 1.1; }
.alert.swal2-toast .swal2-title { font-family: var(--sans); font-size: .9375rem; font-weight: 600; }
.alert .swal2-html-container { color: var(--muted); }
.alert__list { display: grid; gap: .35rem; text-align: left; }
.alert__list li { padding-left: 1rem; position: relative; }
.alert__list li::before { content: ''; position: absolute; left: 0; top: .65em; width: .35rem; height: 1px; background: var(--accent); }
.alert__actions { gap: .5rem; }
.btn--line { border-color: var(--ink); color: var(--ink); }
.swal2-container { z-index: 70; }

/* Tablet */
@media (max-width: 1100px) {
    .site-header__bar { grid-template-columns: auto 1fr; }
    .site-nav, .header-search { display: none; }
    .menu-button { display: inline-grid; }
    .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .shop { grid-template-columns: minmax(0, 1fr); gap: 1.25rem; }
    /* Departments become a swipeable row */
    .shop__depts { position: static; display: flex; gap: 1.5rem; margin-inline: calc(var(--gutter) * -1); padding-inline: var(--gutter); overflow-x: auto; border-bottom: 1px solid var(--line); scrollbar-width: none; }
    .shop__depts::-webkit-scrollbar { display: none; }
    .shop__depts a { flex: none; padding-block: .6rem; border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; }
    .shop__depts a:hover { padding-left: 0; }
    .shop__depts a[aria-current] { border-color: var(--accent); }
    .shop__depts a span { display: none; }
}

@media (max-width: 860px) {
    :root { --header: 4rem; }
    .hero__grid { grid-template-columns: minmax(0, 1fr); min-height: 0; gap: 0; }
    .hero__copy { padding-bottom: 2.5rem; }
    /* The drifting shelf turns sideways under the headline */
    .hero__shelf { display: flex; flex-direction: column; height: auto; min-height: 0; margin-inline: calc(var(--gutter) * -1); padding-bottom: 2.5rem; -webkit-mask-image: none; mask-image: none; }
    .hero__column { flex-direction: row; width: max-content; animation-name: slide; animation-duration: 90s; }
    .hero__column:nth-child(2) { display: none; }
    .hero__column .art { width: 10rem; }
    @keyframes slide { to { transform: translateX(-50%); } }
    .depts { grid-template-columns: minmax(0, 1fr); }
    .steps { grid-template-columns: minmax(0, 1fr); }
    .banner__inner { grid-template-columns: minmax(0, 1fr); }
    .site-footer__grid { grid-template-columns: 1fr 1fr; }
    .site-footer__lead { grid-column: 1 / -1; }
    .split, .receipt { grid-template-columns: minmax(0, 1fr); }
    .split { min-height: 0; }
    .checkout { grid-template-columns: minmax(0, 1fr); }
    .summary { position: static; }
    .pdp { grid-template-columns: minmax(0, 1fr); }
    .pdp__art { position: relative; top: 0; }
    .summary .lines { max-height: none; }
}

/* Phone */
@media (max-width: 640px) {
    .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .logo__mark { width: 2.25rem; height: 2.25rem; }
    .logo__word { font-size: 1.3125rem; }
    .cart-button__label { display: none; }
    .site-header__actions { gap: .5rem; }
    .section-head { align-items: flex-start; flex-direction: column; gap: 1rem; }
    .form__two { grid-template-columns: minmax(0, 1fr); }
    .shop__tools { flex-wrap: wrap; gap: .75rem; }
    .shop__search { flex-basis: 100%; max-width: none; }
    .shop__sort { width: 100%; justify-content: space-between; }
    .pager__pages a:not([aria-current]), .pager__pages span { display: none; }
    .sheet { width: 100vw; }
    .hero__actions .btn { flex: 1; }
    .grid .buy { flex-direction: column; }
    .grid .buy > * { flex: none; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; }
}
