/* =========================================================
   v6: single-row header (transparent over the homepage hero until first scroll) + new footer
   ========================================================= */
:root { --bar-h: 36px; --header-h: 84px; }
.announce { height: var(--bar-h); }

/* ---------- header ---------- */
.hdr { position: sticky; top: 0; z-index: 60; color: var(--ink); background: rgba(248, 244, 237, .97); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line); transition: background .45s var(--ease), color .45s var(--ease), border-color .45s var(--ease), box-shadow .45s var(--ease); }
.hdr.is-scrolled { box-shadow: 0 10px 30px -22px rgba(14, 13, 11, .45); }
.hdr-inner { max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); height: 84px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 24px; transition: height .45s var(--ease); }
.hdr.is-scrolled .hdr-inner { height: 66px; }
.hdr-left { display: flex; align-items: center; height: 100%; }
.hdr-nav { display: flex; justify-content: flex-start; gap: 34px; height: 100%; }
.hdr .nav-item { height: 100%; }
.hdr .nav-link { color: inherit; height: 100%; font-size: .68rem; }
.hdr .nav-link .icon-xs { width: 10px; height: 10px; margin-left: 2px; }
.hdr .nav-link::after { bottom: 24px; }
.hdr.is-scrolled .nav-link::after { bottom: 18px; }
.hdr-logo { display: flex; align-items: center; gap: 14px; justify-self: center; }
.hdr-mark { height: 34px; width: auto; transition: height .45s var(--ease), filter .45s var(--ease); }
.hdr-word { height: 14px; width: auto; transition: height .45s var(--ease), filter .45s var(--ease); }
.hdr.is-scrolled .hdr-mark { height: 28px; }
.hdr.is-scrolled .hdr-word { height: 12px; }
.hdr-right { display: flex; justify-content: flex-end; align-items: center; gap: 2px; }
.hdr .icon-btn { color: inherit; }
.hdr .icon-btn:hover { color: var(--accent-text); }
.hdr-text-link { height: auto; padding: 8px 0; margin-right: 18px; }
.hdr-text-link::after { bottom: 2px !important; }
.hdr .mega { top: 100%; }

/* transparent state (homepage, before the first scroll) */
.home .hdr { position: fixed; left: 0; right: 0; top: var(--bar-h); }
.home .hdr.is-transparent { background: transparent; color: #fbf6ee; border-bottom-color: rgba(255, 255, 255, .2); backdrop-filter: none; -webkit-backdrop-filter: none; box-shadow: none; }
.hdr.is-transparent .hdr-mark, .hdr.is-transparent .hdr-word { filter: invert(1) brightness(1.2); }
.hdr.is-transparent .badge-count { background: #fbf6ee; color: var(--ink); }
.hdr.is-transparent .nav-link::after { background: #fbf6ee; }
.hdr.is-transparent .icon-btn:hover { color: #fff; opacity: .8; }

/* hero sits under the header: full viewport height, soft top shade so the white header stays legible */
.home .hero { height: clamp(620px, calc(100vh - var(--bar-h)), 1000px); }
.home .hero::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 210px; z-index: 2; pointer-events: none;
  background: linear-gradient(180deg, rgba(14, 13, 11, .62) 0%, rgba(14, 13, 11, .28) 55%, rgba(14, 13, 11, 0) 100%); }
.home .hero-text { padding-top: 84px; }

/* ---------- footer ---------- */
.ftr { background: #0b0a09; color: #b9af9f; padding-top: clamp(70px, 8vw, 110px); font-size: .86rem; }
.ftr a { transition: color .2s; }
.ftr a:hover { color: #f6efe4; }
.ftr-top { display: grid; grid-template-columns: 1.05fr 1.4fr; gap: clamp(40px, 7vw, 120px); padding-bottom: 64px; }
.ftr-mark { height: 46px; width: auto; }
.ftr-statement h2 { color: #f6efe4; font-size: clamp(2.2rem, 3.6vw, 3.4rem); line-height: 1.12; margin: 24px 0 14px; }
.ftr-statement h2 em { color: var(--accent-light); }
.ftr-statement p { color: #a99f91; max-width: 40ch; margin: 0; }
.ftr-form { display: grid; grid-template-columns: 1fr auto; max-width: 460px; margin-top: 26px; }
.ftr-form input { border: 0; border-bottom: 1px solid rgba(255, 255, 255, .35); background: transparent; color: #f6efe4; padding: 15px 2px; outline: none; min-width: 0; font-size: .92rem; }
.ftr-form input::placeholder { color: #857a6d; font-family: var(--serif); font-style: italic; }
.ftr-form input:focus { border-bottom-color: var(--accent-light); }
.ftr-form button { display: inline-flex; align-items: center; gap: 10px; border-bottom: 1px solid rgba(255, 255, 255, .35); color: #f6efe4; font-size: .66rem; letter-spacing: .24em; text-transform: uppercase; font-weight: 500; padding: 0 2px 0 16px; transition: color .2s, gap .3s var(--ease); }
.ftr-form button:hover { color: var(--accent-light); gap: 14px; }
.ftr-form .form-msg { grid-column: 1 / -1; margin-top: 12px; }
.ftr-form .form-msg.ok { color: #9fd3a9; }
.ftr-form .form-msg.err { color: #f2a59d; }
.ftr-cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; padding-top: 10px; }
.ftr h4 { font-family: var(--sans); font-size: .62rem; letter-spacing: .26em; text-transform: uppercase; color: var(--accent-light); font-weight: 500; margin: 0 0 22px; }
.ftr ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 11px; }
.ftr-muted { color: #857a6d; }
.ftr .socials { margin-top: 22px; }
.ftr .socials a { border-color: rgba(255, 255, 255, .2); color: #e9e1d4; }
.ftr .socials a:hover { background: var(--accent); border-color: var(--accent); color: #fff; }
.ftr-promise { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid rgba(255, 255, 255, .1); border-bottom: 1px solid rgba(255, 255, 255, .1); }
.ftr-promise li { display: flex; align-items: center; justify-content: center; gap: 12px; padding: 22px 16px; font-size: .74rem; letter-spacing: .06em; color: #cfc6b8; border-right: 1px solid rgba(255, 255, 255, .1); text-align: center; }
.ftr-promise li:last-child { border-right: 0; }
.ftr-promise .icon { color: var(--accent-light); width: 20px; height: 20px; stroke-width: 1.2; }
.ftr-wordmark { padding: clamp(44px, 6vw, 84px) 0 clamp(26px, 3vw, 44px); }
.ftr-wordmark img { width: 100%; height: auto; opacity: .94; }
.ftr-bottom { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 22px 0 30px; font-size: .64rem; letter-spacing: .16em; text-transform: uppercase; color: #857a6d; border-top: 1px solid rgba(255, 255, 255, .1); flex-wrap: wrap; }

/* ---------- responsive ---------- */
@media (max-width: 1024px) {
  :root { --header-h: 64px; }
  .hdr-inner, .hdr.is-scrolled .hdr-inner { height: 64px; }
  .hdr-nav, .hdr-text-link, .hdr .icon-label { display: none; }
  .hdr .menu-toggle { display: inline-flex; }
  .hdr-mark { height: 30px; }
  .hdr.is-scrolled .hdr-mark { height: 28px; }
  .home .hero-text { padding-top: 64px; }
  .ftr-top { grid-template-columns: 1fr; }
  .ftr-promise { grid-template-columns: 1fr 1fr; }
  .ftr-promise li:nth-child(2) { border-right: 0; }
  .ftr-promise li:nth-child(-n+2) { border-bottom: 1px solid rgba(255, 255, 255, .1); }
}
@media (max-width: 820px) {
  /* phones: the photo starts below the transparent header, so it never covers the product */
  .home .hero { height: auto; padding-top: 64px; }
  .home .hero::before { height: 64px; background: var(--night); }
  .home .hero-text { padding-top: 30px; }
}
@media (max-width: 640px) {
  .hdr-word { display: none; }
  .ftr-cols { grid-template-columns: 1fr 1fr; }
  .ftr-cols > div:last-child { grid-column: 1 / -1; }
  .ftr-promise li { justify-content: flex-start; text-align: left; font-size: .72rem; padding: 18px 12px; }
}

/* ---------- homepage promotion (managed in /admin) ---------- */
.promo-band { display: grid; grid-template-columns: 1.25fr 1fr; background: var(--night, #0e0d0b); color: #efe7da; }
.promo-media { position: relative; overflow: hidden; min-height: clamp(320px, 38vw, 560px); }
.promo-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.promo-body { display: flex; flex-direction: column; justify-content: center; align-items: flex-start; padding: clamp(48px, 6vw, 96px) clamp(24px, 5vw, 88px); }
.promo-body .eyebrow { color: var(--accent-light); }
.promo-body h2 { color: #f6efe4; font-size: clamp(2.2rem, 4vw, 3.6rem); line-height: 1.08; margin: 18px 0 16px; max-width: 16ch; }
.promo-body .lead-serif { color: #cfc6b8; margin: 0 0 30px; }
.promo-body .btn { background: #f6efe4; color: var(--ink); border-color: #f6efe4; }
.promo-body .btn:hover { background: transparent; color: #f6efe4; }
.promo-band--text { grid-template-columns: 1fr; text-align: center; }
.promo-band--text .promo-body { align-items: center; padding-top: clamp(60px, 7vw, 110px); padding-bottom: clamp(60px, 7vw, 110px); }
.promo-band--text h2 { max-width: 22ch; }
.promo-band--text .lead-serif { margin-left: auto; margin-right: auto; }
.tag-promo { background: var(--accent); color: #fff; }
@media (max-width: 820px) {
  .promo-band { grid-template-columns: 1fr; }
  .promo-media { min-height: 0; aspect-ratio: 16 / 10; }
}

/* ---------- out of stock ---------- */
.tag-soldout { background: #f3efe9; color: #6e655b; border: 1px solid #d9d2c7; }
.card-add.is-soldout, .card-add[disabled] { cursor: not-allowed; opacity: 1; color: #9a9184; border-color: #ddd6cb; background: transparent; }
.card-add.is-soldout:hover { background: transparent; color: #9a9184; }
.btn[disabled] { cursor: not-allowed; background: #cfc8bd; border-color: #cfc8bd; color: #fff; box-shadow: none; }
.pi-badge--soldout { background: #f3efe9; color: #6e655b; border: 1px solid #d9d2c7; }
.soldout-box { display: grid; grid-template-columns: 1fr auto; gap: 12px; align-items: center; margin: 6px 0 18px; }
.soldout-box .btn { width: 100%; }
.soldout-box p { grid-column: 1 / -1; grid-row: 2; margin: 0; font-size: .86rem; color: var(--ink-2); line-height: 1.6; }

/* ---------- popups (managed in /admin → Popups) ---------- */
.ozpop { position: fixed; inset: 0; z-index: 120; display: flex; align-items: center; justify-content: center; padding: 16px; opacity: 0; transition: opacity .3s var(--ease); }
.ozpop.is-open { opacity: 1; }
.ozpop[hidden] { display: none; }
.ozpop-backdrop { position: absolute; inset: 0; background: rgba(14, 13, 11, .62); backdrop-filter: blur(2px); -webkit-backdrop-filter: blur(2px); }
.ozpop-card { position: relative; background: var(--ivory); max-height: calc(100vh - 32px); max-height: calc(100dvh - 32px); overflow: auto; box-shadow: 0 30px 80px -20px rgba(0, 0, 0, .5); transform: translateY(14px) scale(.98); transition: transform .45s var(--ease-out, var(--ease)); }
.ozpop.is-open .ozpop-card { transform: none; }
.ozpop-close { position: absolute; top: 10px; right: 10px; z-index: 2; width: 38px; height: 38px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: rgba(248, 244, 237, .92); color: var(--ink); box-shadow: 0 2px 10px rgba(0, 0, 0, .12); transition: background .2s, transform .2s; }
.ozpop-close:hover { background: #fff; transform: rotate(90deg); }

/* banner: just the image */
.ozpop--banner .ozpop-card { width: min(560px, 100%); background: transparent; box-shadow: none; overflow: visible; }
.ozpop--banner .ozpop-card img { width: 100%; height: auto; max-height: calc(100dvh - 48px); object-fit: contain; display: block; box-shadow: 0 30px 80px -20px rgba(0, 0, 0, .55); }
.ozpop--banner .ozpop-close { top: -14px; right: -14px; }
.ozpop-banner-link { display: block; }

/* welcome: image beside the text */
.ozpop--welcome .ozpop-card { width: min(460px, 100%); display: grid; }
.ozpop--welcome.has-image .ozpop-card { width: min(820px, 100%); grid-template-columns: 1fr 1.1fr; }
.ozpop-media { position: relative; min-height: 100%; background: var(--parchment); }
.ozpop-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ozpop-body { padding: clamp(36px, 5vw, 56px) clamp(26px, 4vw, 48px); text-align: center; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.ozpop-mark { width: 34px; height: 34px; margin-bottom: 18px; }
.ozpop-body h2 { font-size: clamp(1.9rem, 3vw, 2.5rem); line-height: 1.12; margin: 0 0 12px; }
.ozpop-text { color: var(--ink-2); margin: 0 0 24px; max-width: 34ch; line-height: 1.6; }
.ozpop-form { width: 100%; display: grid; gap: 10px; }
.ozpop-form input[type=email] { width: 100%; height: 50px; border: 1px solid var(--line-2); background: #fff; padding: 0 16px; font-size: .95rem; outline: none; }
.ozpop-form input[type=email]:focus { border-color: var(--ink); }
.ozpop-form .btn, .ozpop-body > .btn { width: 100%; }
.ozpop-form .form-msg { font-size: .86rem; min-height: 0; }
.ozpop-form .form-msg:empty { display: none; }
.ozpop-dismiss { margin-top: 16px; font-size: .7rem; letter-spacing: .14em; text-transform: uppercase; color: var(--gray); text-decoration: underline; text-underline-offset: 4px; }
.ozpop-dismiss:hover { color: var(--ink); }
.ozpop-eyebrow { font-size: .66rem; letter-spacing: .26em; text-transform: uppercase; color: var(--accent-text, #6E655B); margin-bottom: 14px; }
.ozpop--offer h2 { font-size: clamp(2rem, 3.4vw, 2.7rem); }
.ozpop-big { display: block; font-size: clamp(3.6rem, 7vw, 5.2rem); line-height: 1; }
@media (max-width: 640px) {
  .ozpop--welcome.has-image .ozpop-card { grid-template-columns: 1fr; width: min(420px, 100%); }
  .ozpop-media { min-height: 0; aspect-ratio: 16 / 10; }
  .ozpop-media img { object-position: 50% 18%; }
  .ozpop--banner .ozpop-close { top: 8px; right: 8px; }
}
@media (prefers-reduced-motion: reduce) { .ozpop, .ozpop-card { transition: none; } }
