/*
 * KemisJewel refinement layer (loaded after home.css).
 *
 * Sharper, calmer and phone-first: tighter display type, hairline structure
 * instead of boxes and shadows, product photography doing the talking, and
 * a 16px phone gutter. Brand colours are unchanged (design-tokens.css).
 */

:root {
    --ink: #1d1d1b;
    --muted: #5d5a55;
    --line: rgba(29, 29, 27, .12);
    --colour-image-surface: #f1eee8;
    --gutter: clamp(16px, 4vw, 32px);
    --shell: min(var(--container-content), calc(100% - 2 * var(--gutter)));
}

body { color: var(--ink); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }

/* Display type: still the brand serif, with steadier spacing. */
h1, h2, h3 { letter-spacing: -.035em; }
h1 { font-size: clamp(38px, 5.4vw, 72px); line-height: 1; }
.section-heading h2, .story-copy h2, .newsletter h2 { font-size: clamp(32px, 3.6vw, 52px); letter-spacing: -.035em; line-height: 1.02; }
.eyebrow { margin-bottom: 10px; font-size: 11px; letter-spacing: .14em; }

.catalogue-shell, .account-shell { width: min(1500px, calc(100% - 2 * var(--gutter))); }
.account-shell { width: min(1180px, calc(100% - 2 * var(--gutter))); }

/* Header */
.announcement { min-height: 30px; padding: 6px 16px; font-size: 10px; letter-spacing: .16em; }
.header-inner { min-height: 68px; }
.wordmark { font-size: 24px; letter-spacing: -.04em; }
.wordmark__logo { width: 40px; height: 40px; }

/* Buttons: crisp edges, consistent heights */
.button { min-height: 46px; border-radius: 0; letter-spacing: .12em; }
.button--compact { min-height: 40px; }
.text-button { padding: 0; border: 0; background: none; color: var(--colour-teal-deep); font: inherit; font-size: 13px; font-weight: 700; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.text-button:hover { color: var(--ink); }

/* Product cards: photography first, no boxes */
.product-card { border: 0; background: transparent; box-shadow: none; }
.product-card:hover { border: 0; box-shadow: none; }
.product-card__image { background: var(--colour-image-surface); }
.product-card__image img { transition: transform .5s ease; }
.product-card__content { padding: 14px 2px 0; }
.product-card h3 { min-block-size: 0; margin-bottom: 6px; font-size: 15px; font-weight: 400; line-height: 1.35; }
.product-card h3 a { -webkit-line-clamp: 2; line-clamp: 2; }
.product-card__price { margin-bottom: 2px; font-size: 15px; }
.product-card__price .product-price__current { font-weight: 700; }
.product-card__availability { font-size: 12px; }
.product-card__actions { margin-top: 12px; }
.product-card__action { min-height: 40px; border-radius: 0; font-size: 10px; }
.catalogue-product-grid { gap: 36px 20px; }
.catalogue-product-grid .product-card__content { padding: 14px 2px 0; }

/* Homepage product sections: every card visible in a grid */
.home-products { padding: clamp(48px, 7vw, 96px) 0; }
.home-products + .home-products { padding-top: 0; }
.home-products--quiet { background: var(--colour-ivory); }
.home-products--quiet + .newsletter { margin-top: 0; }
.home-products__heading { display: flex; align-items: end; justify-content: space-between; gap: 16px 24px; margin-bottom: 28px; }
.home-products__heading h2 { margin: 0; font-size: clamp(30px, 3.4vw, 48px); letter-spacing: -.035em; line-height: 1.02; }
.home-products__intro { margin: 10px 0 0; color: var(--muted); }
.home-products__more { flex: 0 0 auto; margin-bottom: 6px; }
.home-products__grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 40px 24px; margin: 0; padding: 0; list-style: none; }
.home-products__grid > li { min-width: 0; }
.home-products__footer { display: none; margin: 32px 0 0; text-align: center; }

/* Gifts by price: one tidy row on every screen */
.gift-bands { grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); max-width: 900px; }
.gift-band { min-height: 150px; border-color: var(--line); }
.gift-band:hover, .gift-band:focus-visible { transform: none; }

/* Trust strip */
.reassurance-strip li { letter-spacing: .1em; }

/* Story and newsletter rhythm */
.section.story-section { padding: clamp(48px, 6vw, 88px) 0; }

/* Shop page */
.catalogue-page { padding-top: clamp(28px, 4vw, 64px); }
.catalogue-page__header { margin-bottom: 28px; }
.catalogue-page__header h1 { font-size: clamp(38px, 4.6vw, 64px); letter-spacing: -.04em; }

/* Account */
.account-layout { grid-template-columns: 220px minmax(0, 1fr); gap: clamp(28px, 4vw, 56px); }
.account-sidebar { top: 96px; padding: 0; color: var(--ink); background: transparent; box-shadow: none; }
.account-sidebar__identity { margin: 4px 0 18px; font-size: 24px; }
.account-navigation { border-top: 1px solid var(--line); }
.account-navigation a { min-height: 48px; border-bottom: 1px solid var(--line); color: var(--muted); font-size: 12px; letter-spacing: .1em; }
.account-navigation a:hover, .account-navigation a[aria-current="page"] { padding-left: 0; color: var(--ink); }
.account-navigation a[aria-current="page"]::before { width: 3px; height: 18px; margin-right: 12px; border-radius: 0; background: var(--colour-teal); }
.account-sidebar__sign-out { color: var(--colour-teal-deep); }
.account-sidebar__sign-out:hover { color: var(--ink); }
.account-panel__header { padding: 0 0 24px; margin-bottom: 28px; }
.account-panel__header h1 { margin-bottom: 8px; font-size: clamp(34px, 4vw, 52px); }
.account-section { margin-bottom: 40px; }
.account-section > h2, .account-section__heading h2 { margin: 0 0 16px; font-size: 26px; }
.account-section__heading { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; }
.account-help { color: var(--muted); font-size: 13px; }

.status-chip { display: inline-flex; min-height: 26px; align-items: center; padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; white-space: nowrap; }
.status-chip--progress { color: #6b4b10; background: var(--colour-warning-surface); }
.status-chip--done { color: var(--colour-success); background: var(--colour-success-surface); }
.status-chip--muted { color: var(--muted); background: var(--colour-surface-muted); }

.order-cards { display: grid; gap: 14px; }
.order-card { border: 1px solid var(--line); background: var(--colour-white); }
.order-card__link { display: block; padding: 18px 18px 16px; color: inherit; }
.order-card__link:hover .order-card__number { text-decoration: underline; text-underline-offset: 3px; }
.order-card__top { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.order-card__number { margin: 0 0 4px; font-family: var(--sans); font-size: 16px; font-weight: 700; letter-spacing: 0; }
.order-card__meta { margin: 0; color: var(--muted); font-size: 13px; }
.order-card__images { display: flex; gap: 8px; margin-top: 14px; }
.order-card__images img { width: 56px; height: 56px; object-fit: cover; background: var(--colour-image-surface); }
.order-card__tracking { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; padding: 12px 18px; border-top: 1px solid var(--line); background: var(--colour-ivory); font-size: 13px; }

.account-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin: 0; padding: 0; list-style: none; }
.account-tile { display: grid; gap: 4px; min-height: 84px; padding: 16px 18px; border: 1px solid var(--line); color: inherit; }
.account-tile:hover { border-color: var(--colour-teal); }
.account-tile span { overflow-wrap: anywhere; color: var(--muted); font-size: 13px; }

.account-filter { margin-bottom: 20px; border: 1px solid var(--line); }
.account-filter > summary { min-height: 48px; display: flex; align-items: center; padding: 0 16px; font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; cursor: pointer; }
.account-filter .account-form { border: 0; box-shadow: none; padding-top: 0; }

.order-overview { margin-bottom: 36px; padding: 20px; border: 1px solid var(--line); background: var(--colour-ivory); }
.order-overview__head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }
.order-overview__head p { margin: 0; color: var(--muted); font-size: 14px; }
.order-steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin: 22px 0 0; padding: 0; list-style: none; }
.order-steps__step { position: relative; display: grid; justify-items: start; gap: 4px; padding-top: 22px; color: var(--muted); font-size: 13px; }
.order-steps__step::before { position: absolute; top: 6px; right: 0; left: 0; height: 2px; background: var(--line); content: ""; }
.order-steps__step.is-done::before { background: var(--colour-teal); }
.order-steps__dot { position: absolute; top: 0; left: 0; width: 14px; height: 14px; border: 2px solid var(--line); border-radius: 50%; background: var(--colour-white); }
.order-steps__step.is-done .order-steps__dot { border-color: var(--colour-teal); background: var(--colour-teal); }
.order-steps__step.is-current .order-steps__label { color: var(--ink); font-weight: 700; }
.order-steps__when { font-size: 12px; }

.order-delivery__status { margin: -6px 0 14px; color: var(--muted); }
.parcel-card { margin-bottom: 12px; padding: 18px; border: 1px solid var(--line); }
.parcel-card h3 { margin: 0 0 4px; font-family: var(--sans); font-size: 16px; font-weight: 700; letter-spacing: 0; }
.parcel-card__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.parcel-card__head p { margin: 0; color: var(--muted); font-size: 13px; }
.parcel-card__number { margin: 14px 0 6px; font-size: 14px; }
.parcel-card__number strong { margin-left: 6px; letter-spacing: .04em; }
.parcel-card__items { margin: 0; padding-left: 18px; color: var(--muted); font-size: 13px; }

.order-items { margin: 0; padding: 0; border-top: 1px solid var(--line); list-style: none; }
.order-item { display: flex; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.order-item__image { width: 72px; height: 72px; flex: 0 0 auto; object-fit: cover; background: var(--colour-image-surface); }
.order-item__body { display: grid; flex: 1; align-content: start; gap: 4px; min-width: 0; }
.order-item__title { color: var(--ink); font-weight: 700; }
.order-item__meta { color: var(--muted); font-size: 13px; }
.order-item__actions { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 4px; }
.order-item__actions form { margin: 0; }
.order-totals { max-width: 360px; margin: 18px 0 0 auto; }
.order-totals > div { display: flex; justify-content: space-between; gap: 16px; padding: 6px 0; color: var(--muted); }
.order-totals dt, .order-totals dd { margin: 0; }
.order-totals__total { border-top: 1px solid var(--line); margin-top: 6px; padding-top: 12px !important; color: var(--ink) !important; font-size: 18px; font-weight: 700; }
.account-order__reorder { margin-top: 20px; text-align: right; }

/* Tracking pop-up */
.tracking-dialog { width: min(480px, calc(100% - 32px)); max-height: calc(100% - 32px); padding: 0; border: 0; color: var(--ink); background: var(--colour-white); box-shadow: 0 24px 64px rgba(0, 0, 0, .25); }
.tracking-dialog::backdrop { background: rgba(0, 40, 42, .55); }
.tracking-dialog__inner { padding: 22px 22px 24px; }
.tracking-dialog__header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.tracking-dialog__header h2 { margin: 0; font-size: 28px; }
.tracking-dialog__close { width: 44px; height: 44px; border: 0; background: none; color: var(--ink); font-size: 28px; line-height: 1; cursor: pointer; }
.tracking-dialog__service { margin: 4px 0 16px; color: var(--muted); }
.tracking-dialog__number { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 2px 12px; padding: 14px 16px; background: var(--colour-ivory); }
.tracking-dialog__number-label { grid-column: 1; color: var(--muted); font-size: 12px; }
.tracking-dialog__number strong { grid-column: 1; font-size: 18px; letter-spacing: .06em; }
.tracking-dialog__copy { grid-row: 1 / span 2; grid-column: 2; min-height: 40px; padding: 0 14px; border: 1px solid var(--colour-teal); background: var(--colour-white); color: var(--colour-teal-deep); font: inherit; font-size: 12px; font-weight: 700; cursor: pointer; }
.tracking-journey { margin: 22px 0; padding: 0; list-style: none; }
.tracking-journey__step { position: relative; display: grid; gap: 2px; padding: 0 0 18px 28px; }
.tracking-journey__step::before { position: absolute; top: 4px; left: 0; width: 12px; height: 12px; border: 2px solid var(--colour-teal); border-radius: 50%; background: var(--colour-white); content: ""; }
.tracking-journey__step::after { position: absolute; top: 18px; bottom: 0; left: 7px; width: 2px; background: var(--line); content: ""; }
.tracking-journey__step:last-child::after { display: none; }
.tracking-journey__step.is-done::before { background: var(--colour-teal); }
.tracking-journey__step--next::before { border-style: dashed; }
.tracking-journey__title { font-weight: 700; }
.tracking-journey__text { color: var(--muted); font-size: 13px; }
.tracking-dialog__live { width: 100%; letter-spacing: .06em; }
.tracking-dialog__help { margin: 10px 0 0; color: var(--muted); font-size: 12px; text-align: center; }

@media (max-width: 1120px) {
    .home-products__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .home-products__grid > li:nth-child(n+7) { display: none; }
}

@media (max-width: 900px) {
    .account-layout { grid-template-columns: 1fr; }
    .account-sidebar { position: static; display: block; padding: 0; }
    .account-sidebar__identity { display: none; }
    .account-navigation { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; margin: 0; border: 0; overflow: visible; }
    .account-navigation a, .account-navigation a:hover { min-width: 0; min-height: 44px; justify-content: center; padding: 0 4px; border: 1px solid var(--line); border-radius: 999px; font-size: 10px; letter-spacing: .06em; text-align: center; }
    .account-navigation a[aria-current="page"] { border-color: var(--colour-teal); color: var(--colour-white); background: var(--colour-teal); }
    .account-navigation a[aria-current="page"]::before { display: none; }
    .account-sidebar__sign-out { display: none; }
}

@media (max-width: 640px) {
    :root { --gutter: 16px; }
    body { font-size: 15px; }
    .announcement { font-size: 9px; letter-spacing: .12em; }
    .header-inner { min-height: 60px; }
    .wordmark { font-size: 21px; gap: 8px; }
    .wordmark__logo { width: 34px; height: 34px; }

    h1 { font-size: clamp(32px, 9vw, 40px); }
    .section { padding: 44px 0; }
    .section-heading { margin-bottom: 22px; }
    .section-heading h2, .story-copy h2, .newsletter h2 { font-size: clamp(28px, 8vw, 34px); }

    /* Banner text sits lower and smaller so the photo shows */
    .banner__slide { min-height: 480px; }
    .banner__headline { font-size: clamp(32px, 9.5vw, 40px); }
    .banner__text { font-size: 15px; }

    .reassurance-strip li { font-size: 9px; }

    .home-products { padding: 40px 0; }
    .home-products__heading { align-items: start; flex-direction: column; margin-bottom: 18px; }
    .home-products__heading h2 { font-size: clamp(28px, 8vw, 34px); }
    .home-products__heading .home-products__more { display: none; }
    .home-products__footer { display: block; }
    .home-products__footer .button { width: 100%; }
    .home-products__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 12px; }
    .home-products__grid > li:nth-child(n+7) { display: list-item; }

    .product-card h3 { font-size: 14px; }
    .product-card__price { font-size: 14px; }
    .product-card__badges { top: 6px; left: 6px; }
    .home-products .product-card__actions, .product-detail__related .product-card__actions { display: none; }
    .catalogue-product-grid { gap: 28px 12px; }
    .catalogue-product-grid .product-card__content { padding: 10px 2px 0; }
    .catalogue-product-grid .product-card__action { min-height: 40px; font-size: 9px; }

    /* Gifts: three small tiles on one row */
    .gifts-section .section-heading p:not(.eyebrow) { font-size: 14px; }
    .gift-bands { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
    .gift-band { min-height: 104px; gap: 4px; padding: 14px 6px; }
    .gift-band__label { font-size: 9px; letter-spacing: .12em; }
    .gift-band__price { font-size: 22px; letter-spacing: -.03em; }
    .gift-band__count { font-size: 11px; }

    .category-card__label { font-size: 17px; }

    .newsletter { min-height: 0; }
    .newsletter-content { padding: 44px 0; }

    .account-panel__header { padding-bottom: 16px; margin-bottom: 20px; }
    .account-panel__header h1 { font-size: 32px; }
    .account-tiles { grid-template-columns: 1fr; }
    .order-card__link { padding: 16px 14px 14px; }
    .order-card__top { flex-direction: column-reverse; gap: 8px; }
    .order-card__tracking { padding: 12px 14px; }
    .order-card__tracking .tracking-button { width: 100%; }
    .order-overview { padding: 16px; }
    .order-steps__label { font-size: 12px; }
    .parcel-card__head .tracking-button { width: 100%; }
    .order-totals { max-width: none; }
    .account-order__reorder { text-align: left; }
    .account-order__reorder .button { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
    .product-card__image img { transition: none; }
}

/* Shop toolbar: sorting applies straight away, so it can sit in one tidy row */
.catalogue-toolbar.is-enhanced .catalogue-toolbar__sort .button { display: none; }
@media (max-width: 640px) {
    .catalogue-page__header .eyebrow { display: none; }
    .catalogue-toolbar { display: flex; flex-direction: row; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
    .catalogue-toolbar__count { flex: 1; font-size: 13px; white-space: nowrap; }
    .catalogue-toolbar__sort { flex: 0 0 auto; display: flex; width: auto; flex-direction: row; align-items: center; justify-content: flex-end; gap: 8px; }
    .catalogue-toolbar__sort label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
    .catalogue-toolbar select { width: auto; min-width: 0; max-width: 190px; min-height: 44px; padding: 8px 32px 8px 12px; font-size: 14px; }
    .catalogue-toolbar:not(.is-enhanced) .catalogue-toolbar__sort .button { min-height: 44px; }
    .catalogue-category-nav a { font-size: 11px; }
}

/* Bag: checkout is the main action; quantities and prices never overlap */
.basket-summary__checkout { color: var(--colour-white); border-color: var(--colour-teal); background: var(--colour-teal); }
.basket-summary__checkout:hover { color: var(--colour-white); background: var(--colour-teal-deep); }
.basket-summary__update { color: var(--colour-teal-deep); border-color: var(--colour-teal); background: transparent; }
.basket-summary__update:hover { color: var(--colour-white); background: var(--colour-teal); }
@media (max-width: 640px) {
    .basket-line__purchase { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 14px 16px; align-items: end; }
    .basket-line__quantity { grid-column: 1 / -1; }
    .basket-line__prices { display: flex; gap: 20px; }
    .basket-line__remove { justify-self: end; }
}
.staff-preview-note { margin: 0 0 20px; padding: 12px 16px; border-left: 3px solid var(--colour-warning); color: #6b4b10; background: var(--colour-warning-surface); font-size: 14px; }

/* Option swatches: tidy row of photos/colours; long option names show once chosen */
.variant-swatches__list { gap: 10px; }
.variant-swatch { width: auto; min-width: 68px; padding: 6px; border-radius: 0; }
.variant-swatch--compact { min-width: 0; padding: 4px; border-radius: 50%; }
.variant-swatch--compact .variant-swatch__visual { width: 60px; height: 60px; }
.variant-swatch[aria-pressed="true"] { background: transparent; border-color: transparent; }
.variant-swatch[aria-pressed="true"] .variant-swatch__visual { box-shadow: inset 0 0 0 3px var(--colour-white), 0 0 0 2px var(--colour-teal); border-color: var(--colour-teal); }
.variant-swatch__label { max-width: 80px; font-size: 12px; }
.variant-swatches__chosen { margin-bottom: 12px; font-size: 14px; }
.variant-swatches__chosen strong { font-weight: 700; }

/* Mini bag: a dropdown under "Bag" on computers, a sheet from the bottom on phones */
.mobile-bag { display: none; }
.header-bag__count[hidden] { display: none; }
.mini-bag { position: absolute; top: 100%; right: max(var(--gutter), calc((100% - var(--container-content)) / 2)); z-index: 120; width: 380px; max-height: min(70vh, 620px); overflow-y: auto; border: 1px solid var(--line); color: var(--ink); background: var(--colour-white); box-shadow: 0 18px 48px rgba(0, 0, 0, .14); }
.mini-bag[hidden] { display: none; }
.mini-bag__content { padding: 18px 20px 20px; }
.mini-bag__header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.mini-bag__header h2 { margin: 0; font-size: 24px; }
.mini-bag__close { width: 40px; height: 40px; border: 0; background: none; color: var(--ink); font-size: 26px; line-height: 1; cursor: pointer; }
.mini-bag__messages { margin: 6px 0 10px; }
.mini-bag__message { margin: 0 0 6px; padding: 8px 12px; color: var(--colour-success); background: var(--colour-success-surface); font-size: 13px; }
.mini-bag__message--error, .mini-bag__message--warning { color: var(--colour-error); background: var(--colour-error-surface); }
.mini-bag__lines { margin: 0; padding: 0; list-style: none; }
.mini-bag__line { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.mini-bag__line img, .mini-bag__placeholder { width: 64px; height: 64px; flex: 0 0 auto; object-fit: cover; background: var(--colour-image-surface); }
.mini-bag__line-body { display: grid; align-content: start; gap: 2px; min-width: 0; font-size: 14px; }
.mini-bag__line-body a { overflow: hidden; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.mini-bag__option, .mini-bag__meta { color: var(--muted); font-size: 12px; }
.mini-bag__total { display: flex; justify-content: space-between; margin-top: 14px; font-size: 16px; }
.mini-bag__note { margin: 4px 0 14px; color: var(--colour-teal-deep); font-size: 12px; }
.mini-bag__actions { display: grid; gap: 8px; }
.mini-bag__empty { margin: 12px 0; color: var(--muted); }
.mini-bag__shop { width: 100%; }

@media (max-width: 640px) {
    .mobile-bag { display: inline-flex; min-height: 44px; align-items: center; gap: 6px; padding: 0 6px; font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
    .header-inner { grid-template-columns: 1fr auto auto; gap: 8px; }
}
.mini-bag.is-sheet { position: fixed; top: auto; right: 0; bottom: 0; left: 0; width: auto; max-height: 82vh; border: 0; border-top: 3px solid var(--colour-teal); box-shadow: 0 -16px 48px rgba(0, 0, 0, .22); }
@media (min-width: 641px) {
    .mini-bag.is-sheet { top: 0; left: auto; width: 400px; max-height: none; height: 100vh; border-top: 0; border-left: 1px solid var(--line); box-shadow: -16px 0 48px rgba(0, 0, 0, .18); }
}
.has-bag-sheet body::after { position: fixed; inset: 0; z-index: 110; background: rgba(0, 40, 42, .35); content: ""; }
.site-header { -webkit-backdrop-filter: none; backdrop-filter: none; background: rgba(250, 248, 243, .98); }
.has-bag-sheet .site-header { z-index: 130; }

/* Product page promises (delivery, returns, checkout) */
.product-detail__provisional { padding: 16px 0 0; border: 0; border-top: 1px solid var(--line); background: transparent; }
.product-promises { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; font-size: 14px; color: var(--muted); }
.product-promises li { position: relative; padding-left: 22px; }
.product-promises li::before { position: absolute; top: .45em; left: 2px; width: 8px; height: 8px; border-radius: 50%; background: var(--colour-gold); content: ""; }
.product-promises strong { color: var(--ink); }
.product-promises a { margin-left: 6px; color: var(--colour-teal-deep); text-decoration: underline; text-underline-offset: 3px; }

/* Share links on product pages */
.product-share {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 18px;
    margin-top: 22px;
}
.product-share__links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
}
.product-share__link {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    padding: 0 14px;
    border: 1px solid var(--line);
    background: transparent;
    color: inherit;
    font: inherit;
    font-size: 0.8125rem;
    text-decoration: none;
    cursor: pointer;
}
.product-share__link:hover,
.product-share__link:focus-visible {
    border-color: currentColor;
}
.product-share__status {
    flex-basis: 100%;
    min-height: 1.2em;
    margin: 0;
    font-size: 0.8125rem;
    color: var(--colour-teal-deep);
}
.product-share__status:empty {
    display: none;
}
.has-native-share .product-share__extra {
    display: none;
}

/* Bag as an icon, with its count as a small badge on the corner */
.header-bag { position: relative; }
.header-actions a.header-bag, .mobile-bag { min-width: 44px; min-height: 44px; justify-content: center; padding: 0 6px; }
.bag-icon { display: block; width: 22px; height: 22px; flex: none; }
.header-bag .header-bag__count { position: absolute; top: 4px; right: -2px; min-width: 17px; min-height: 17px; padding: 1px 4px; font-size: 10px; font-weight: 700; letter-spacing: 0; }
.header-actions a.header-bag::after { display: none; }
.header-actions a.header-bag::before { content: none; }
.header-actions a.header-bag[aria-current="page"] .bag-icon { color: var(--colour-teal-deep); }

/* Cookie choice: fixed to the bottom until the visitor decides */
.cookie-banner {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 140;
    padding: 18px var(--gutter) calc(18px + env(safe-area-inset-bottom));
    border-top: 3px solid var(--colour-teal);
    background: var(--colour-white, #fff);
    box-shadow: 0 -12px 40px rgba(0, 0, 0, .14);
}
.cookie-banner[hidden] { display: none; }
.cookie-banner__inner {
    display: flex;
    align-items: center;
    gap: 16px 32px;
    max-width: var(--container-content);
    margin: 0 auto;
}
.cookie-banner h2 { margin: 0 0 4px; font-size: 20px; letter-spacing: -.01em; }
.cookie-banner p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.5; }
.cookie-banner a { color: var(--colour-teal-deep); text-decoration: underline; text-underline-offset: 3px; }
.cookie-banner__actions { display: flex; flex: none; gap: 10px; }
.cookie-banner__actions .button { min-width: 120px; }
.footer-link-button {
    padding: 0;
    border: 0;
    background: none;
    color: inherit;
    font: inherit;
    text-align: left;
    cursor: pointer;
}
.footer-link-button:hover, .footer-link-button:focus-visible { text-decoration: underline; }
@media (max-width: 640px) {
    .cookie-banner__inner { flex-direction: column; align-items: stretch; }
    .cookie-banner__actions .button { flex: 1; min-width: 0; }
}

/* Back to top: appears after scrolling down, bottom right */
.back-to-top {
    position: fixed;
    right: max(16px, env(safe-area-inset-right));
    bottom: calc(16px + env(safe-area-inset-bottom) + var(--back-to-top-lift, 0px));
    z-index: 90;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 1px solid var(--colour-on-dark-border, rgba(255, 255, 255, .25));
    border-radius: 50%;
    color: var(--colour-white, #fff);
    background: var(--colour-teal-deep);
    box-shadow: 0 6px 18px rgba(0, 0, 0, .18);
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: opacity .2s ease, transform .2s ease, visibility .2s;
}
.back-to-top.is-visible { opacity: 1; visibility: visible; transform: none; }
.back-to-top:hover { background: var(--colour-teal); }
.back-to-top:focus-visible { outline: 3px solid var(--colour-gold); outline-offset: 3px; }
body.mobile-menu-is-open .back-to-top,
body:has(.cookie-banner:not([hidden])) .back-to-top { display: none; }
@media (prefers-reduced-motion: reduce) {
    .back-to-top { transition: none; transform: none; }
}

/* Announcement link and social links (Shop settings) */
.announcement a { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.announcement a:hover { text-decoration-thickness: 2px; }
.site-footer .footer-social { display: flex; flex-wrap: wrap; gap: 4px 18px; margin: 18px 0 0; padding: 0; list-style: none; }
.site-footer .footer-social li + li { margin-top: 0; }
.site-footer .footer-social a { display: inline-flex; min-height: 44px; align-items: center; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; }
