/* ==========================================================================
   Site-wide shell — Canonical header / Footer / Drawer
   Header SSOT: mockups/partials/canonical-header.html + pages/homepage
   Tokens: Forest & Espresso.
   ========================================================================== */

[x-cloak],
[hidden] {
  display: none !important;
}

/* ——— FTC strip (dismissible ~30 days via localStorage) ——— */
html.drc-ftc-dismissed .drc-ftc {
  display: none !important;
}

.drc-ftc {
  position: relative;
  border-bottom: 1px solid var(--stone);
  background: var(--cream);
}

.drc-ftc__desktop {
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
}

.drc-ftc__copy {
  margin: 0;
  flex: 1;
  min-width: 0;
  font-size: 13px;
  line-height: 1.35;
  color: var(--muted);
}

.drc-ftc__copy strong {
  color: var(--espresso);
  font-weight: 600;
}

.drc-ftc__mobile {
  display: flex;
  min-height: 48px;
  align-items: center;
  gap: 8px;
  padding: 0 max(16px, env(safe-area-inset-left)) 0 max(16px, env(safe-area-inset-right));
}

.drc-ftc__mobile p {
  margin: 0;
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 11px;
  color: var(--muted);
}

.drc-ftc__actions {
  display: flex;
  flex: none;
  align-items: center;
  gap: 4px;
}

.drc-ftc__learn,
.drc-ftc__dismiss {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  min-width: 48px;
  padding: 0 12px;
  border: 0;
  background: transparent;
  color: var(--forest);
  font: 700 12px/1 var(--font-ui);
  cursor: pointer;
}

.drc-ftc__learn {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.drc-ftc__dismiss {
  color: var(--muted);
  font-weight: 600;
  text-decoration: none;
}

.drc-ftc__dismiss:hover {
  color: var(--espresso);
}

.drc-ftc__hide-sm {
  display: none;
}

@media (min-width: 768px) {
  .drc-ftc__hide-sm {
    display: inline;
  }
}

@media (min-width: 640px) {
  .drc-ftc__desktop {
    display: flex;
  }
  .drc-ftc__mobile {
    display: none;
  }
}

/* ——— Canonical sticky header ——— */
.site-header {
  position: sticky;
  top: env(safe-area-inset-top, 0px);
  z-index: 60;
  background: var(--milk);
  box-shadow: 0 1px 0 var(--stone);
}

/* Products mega menu — SSOT: mockups/pages/homepage */
.mega-scrim {
  position: fixed;
  inset: 0;
  z-index: 55;
  background: color-mix(in srgb, var(--espresso) 28%, transparent);
}

.mega {
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  z-index: 61;
  background: var(--milk);
  box-shadow:
    0 1px 0 var(--stone),
    0 28px 40px -28px color-mix(in srgb, var(--espresso) 35%, transparent);
}

.mega-inner {
  display: grid;
  grid-template-columns: 224px minmax(0, 1fr) 248px;
  gap: 32px;
  padding: 24px 20px 28px 0;
  max-height: calc(100vh - var(--header-h, 68px) - 56px);
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-gutter: stable;
  --scroll-size: var(--scroll-size-sm, 8px);
}

.mega-rail {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.mega-rail-btn {
  display: block;
  width: 100%;
  position: relative;
  padding: 11px 14px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.mega-rail-btn strong {
  display: block;
  font: 600 14.5px / 1.3 var(--font-ui);
  color: var(--espresso);
}

.mega-rail-btn span {
  display: block;
  margin-top: 1px;
  font-size: 12.5px;
  color: var(--muted);
}

.mega-rail-btn:hover,
.mega-rail-btn[aria-current="true"] {
  background: var(--cream);
}

.mega-rail-btn[aria-current="true"]::before {
  content: "";
  position: absolute;
  left: 0;
  top: 10px;
  bottom: 10px;
  width: 3px;
  border-radius: 3px;
  background: var(--forest);
}

.mega-rail-btn[aria-current="true"] strong {
  color: var(--forest);
}

.mega-main {
  min-width: 0;
}

.mega-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 2px;
}

.mega-head h2 {
  margin: 0;
  font: 600 20px / 1.25 var(--font-ui);
  letter-spacing: -0.01em;
  color: var(--espresso);
}

.mega-head .text-link {
  font-size: 14px;
}

.mega-desc {
  margin: 0 0 18px;
  max-width: 60ch;
  font-size: 14px;
  color: var(--muted);
}

.mega-cols {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 18px 24px;
}

.mega-group h3 {
  margin: 0 0 4px;
  font: 600 14px / 1.3 var(--font-ui);
}

.mega-group h3 a {
  color: var(--forest);
  text-decoration: none;
}

.mega-group h3 a:hover {
  color: color-mix(in srgb, var(--forest) 88%, black);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.mega-group ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.mega-group li a {
  display: block;
  padding: 3px 0;
  font-size: 13.5px;
  line-height: 1.4;
  color: var(--muted);
  text-decoration: none;
}

.mega-group li a:hover {
  color: var(--espresso);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.mega-group li a.more {
  font-weight: 600;
  color: color-mix(in srgb, var(--forest) 88%, black);
}

.mega-needs {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--stone);
}

.mega-needs h3 {
  margin: 0 0 2px;
  font: 600 14px / 1.3 var(--font-ui);
  color: var(--espresso);
}

.mega-needs p {
  margin: 0 0 10px;
  font-size: 12.5px;
  color: var(--muted);
}

.mega-needs .pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.mega-needs .pill {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 14px;
  border: 1px solid color-mix(in srgb, var(--stone) 70%, var(--espresso));
  border-radius: 999px;
  background: var(--milk);
  color: var(--espresso);
  font: 500 13.5px / 1 var(--font-ui);
  text-decoration: none;
}

.mega-needs .pill:hover {
  background: var(--forest);
  border-color: var(--forest);
  color: var(--milk);
}

.mega-feature {
  align-self: start;
  position: relative;
  overflow: hidden;
  min-height: 220px;
  padding: 20px;
  border-radius: var(--r-panel, 16px);
  background: var(--cream);
}

.mega-feature .sil-bg {
  position: absolute;
  right: -8px;
  bottom: -18px;
  width: 112px;
  height: 126px;
  color: color-mix(in srgb, var(--forest) 14%, var(--stone, #dedcd3));
  pointer-events: none;
  transition: opacity 160ms var(--ease, ease), transform 220ms var(--ease, ease);
}

.mega-feature[data-sil='grinder'] .sil-bg,
.mega-feature[data-sil='kettle'] .sil-bg {
  right: 0;
}

.mega-feature .mf-tag {
  position: relative;
  margin: 0 0 8px;
  font: 600 12.5px / 1.3 var(--font-ui);
  color: var(--muted);
}

.mega-feature h3 {
  position: relative;
  margin: 0 0 8px;
  font: 600 19px / 1.25 var(--font-display);
  letter-spacing: -0.01em;
  color: var(--forest);
}

.mega-feature h3 a {
  color: inherit;
  text-decoration: none;
}

.mega-feature h3 a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.mega-feature p {
  position: relative;
  margin: 0 0 16px;
  max-width: 24ch;
  font-size: 13.5px;
  color: var(--muted);
}

.mega-feature .btn {
  position: relative;
}

.mega-foot {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--stone);
  font-size: 12.5px;
  color: var(--muted);
}

.mega-path {
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 12px;
}

@media (max-width: 1239.98px) {
  .mega,
  .mega-scrim {
    display: none !important;
  }
}

.site-header .nav-products .ic-sm {
  width: 12px;
  height: 12px;
  transition: transform 160ms var(--ease, ease);
}

.site-header .nav-products[aria-expanded="true"] .ic-sm {
  transform: rotate(180deg);
}

.site-header .header-inner {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 56px;
  padding-left: max(12px, env(safe-area-inset-left));
  padding-right: max(12px, env(safe-area-inset-right));
}

.site-header .brand {
  display: inline-flex;
  align-items: center;
  flex: none;
  text-decoration: none;
  border-radius: 6px;
}

.site-header .brand img {
  height: 32px;
  width: auto;
  display: block;
}

.drc-drawer__head .brand img {
  height: 30px;
  width: auto;
  display: block;
}

.site-header .nav-toggle {
  margin-left: -6px;
}

.site-header .nav-toggle + .brand {
  margin-right: auto;
}

.site-header .icon-btn {
  display: inline-grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 0;
  background: transparent;
  color: var(--espresso);
  border-radius: 8px;
  cursor: pointer;
  font-size: 22px;
  line-height: 1;
}

.site-header .primary-nav,
.site-header .search {
  display: none;
}

.site-header .header-actions {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

.site-header .seg {
  display: inline-flex;
  padding: 2px;
  border: 1px solid var(--stone);
  border-radius: 8px;
  background: var(--milk);
  gap: 2px;
}

.site-header .seg button {
  min-height: 34px;
  min-width: 40px;
  padding: 0 11px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  font: 600 13px/1 var(--font-ui);
  color: var(--muted);
  cursor: pointer;
}

.site-header .seg button[aria-pressed="true"] {
  background: var(--blue);
  color: var(--forest);
}

.site-header .cta-match {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 0 12px;
  border-radius: 999px;
  background: var(--forest);
  color: var(--milk);
  font: 600 12.5px/1 var(--font-ui);
  text-decoration: none;
}

.site-header .cta-match:active {
  transform: scale(0.98);
}

.site-header .nav-chevron {
  font-size: 11px;
  opacity: 0.7;
}

@media (max-width: 639.98px) {
  .site-header .seg button {
    min-height: 32px;
    min-width: 36px;
    padding: 0 8px;
    font-size: 12px;
  }
}

@media (min-width: 640px) {
  .site-header .cta-match {
    min-height: 40px;
    padding: 0 16px;
    font-size: 13.5px;
  }
  .site-header .brand img {
    height: 36px;
  }
}

@media (min-width: 1240px) {
  .site-header .header-inner {
    gap: 20px;
    height: var(--header-h, 68px);
  }

  .site-header .nav-toggle,
  .site-header .search-toggle {
    display: none;
  }

  .site-header .nav-toggle + .brand {
    margin-right: 4px;
  }

  .site-header .primary-nav {
    display: block;
  }

  .site-header .primary-nav ul {
    display: flex;
    margin: 0;
    padding: 0;
    list-style: none;
  }

  .site-header .nav-link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    min-height: 44px;
    padding: 0 12px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    font: 500 14.5px/1 var(--font-ui);
    color: var(--espresso);
    text-decoration: none;
    cursor: pointer;
  }

  .site-header .nav-link:hover {
    color: var(--forest);
    background: var(--cream);
  }

  .site-header .nav-link.is-current {
    color: var(--forest);
    background: var(--cream);
    font-weight: 600;
  }

  .site-header .search {
    display: block;
    position: relative;
    flex: 1 1 200px;
    min-width: 0;
    max-width: 400px;
    margin-left: auto;
    z-index: 2;
  }

  .site-header .search-submit {
    flex: none;
  }

  .site-header .search-cancel {
    display: none;
  }

  .site-header .sugg {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    width: min(540px, calc(100vw - 48px));
    max-height: min(70vh, 620px);
    overflow-y: auto;
    overscroll-behavior: contain;
    background: var(--milk);
    border-radius: 18px;
    box-shadow: var(--shadow-pop);
    padding: 10px;
    z-index: 70;
    border: 1px solid color-mix(in srgb, var(--stone) 70%, transparent);
  }

  .site-header .header-actions {
    margin-left: 0;
    gap: 12px;
  }

  .site-header .seg.seg-region {
    display: inline-flex;
  }

  .site-header .cta-match {
    display: inline-flex;
  }

  .site-header .brand img {
    height: 38px;
  }
}

.drc-icon-btn {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--espresso);
  cursor: pointer;
  text-decoration: none;
  position: relative;
}

/* ——— Drawer (SSOT: mockups/pages/homepage .drawer) ——— */
.drc-drawer {
  position: fixed;
  inset: 0;
  z-index: 100;
  visibility: hidden;
}

.drc-drawer.is-open {
  visibility: visible;
}

.drc-drawer__scrim {
  position: absolute;
  inset: 0;
  background: rgba(23, 35, 31, 0.4);
  opacity: 0;
  transition: opacity 0.25s;
}

.drc-drawer.is-open .drc-drawer__scrim {
  opacity: 1;
}

.drc-drawer__panel {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  display: flex;
  width: min(400px, 100%);
  flex-direction: column;
  background: var(--milk);
  transform: translateX(-100%);
  transition: transform 0.28s var(--ease);
  padding-top: env(safe-area-inset-top, 0px);
}

.drc-drawer.is-open .drc-drawer__panel {
  transform: none;
}

.drc-drawer__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 60px;
  padding: 8px 12px 8px 20px;
  box-shadow: 0 1px 0 var(--stone);
}

.drc-drawer__head .icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: var(--r-btn, 8px);
  background: transparent;
  color: var(--espresso);
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
}

.drc-drawer__head .icon-btn:hover {
  background: var(--cream);
}

.drc-drawer__head .icon-btn .ic {
  width: 24px;
  height: 24px;
  display: block;
  flex: none;
}

.drc-drawer__body {
  flex: 1;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 8px 0 16px;
}

.drc-drawer__foot {
  display: grid;
  gap: 14px;
  padding: 16px 20px calc(16px + env(safe-area-inset-bottom, 0px));
  box-shadow: 0 -1px 0 var(--stone);
  background: var(--milk);
}

.drawer-list a,
.drawer-list button.drawer-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  min-height: 52px;
  padding: 10px 20px;
  border: 0;
  border-bottom: 1px solid var(--stone);
  background: transparent;
  text-align: left;
  text-decoration: none;
  color: var(--espresso);
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
}

.drawer-list .drawer-row:hover,
.drawer-list a:hover {
  background: var(--cream);
}

.drawer-list > a.is-current {
  background: var(--cream);
  color: var(--forest);
  font-weight: 600;
}

.drawer-list .row-main {
  font-weight: 600;
  color: var(--espresso);
}

.drawer-list small {
  display: block;
  font-size: 13px;
  color: var(--muted);
  font-weight: 400;
}

.drawer-list .tag-usage {
  margin-left: 8px;
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--milk);
  box-shadow: inset 0 0 0 1px var(--stone);
  color: var(--muted);
  font: 500 11px/1.2 var(--font-ui);
}

.drawer-back {
  display: flex;
  align-items: center;
  gap: 4px;
  width: 100%;
  min-height: 48px;
  padding: 4px 16px 4px 12px;
  border: 0;
  background: transparent;
  color: var(--rust-deep);
  font: 600 14px/1 var(--font-ui);
  text-align: left;
  cursor: pointer;
}

.drawer-back .ic {
  width: 16px;
  height: 16px;
  flex: none;
}

.drawer-title {
  margin: 0;
  padding: 4px 20px 8px;
  font: 600 22px/1.25 var(--font-display);
  color: var(--espresso);
  letter-spacing: -0.01em;
}

.drawer-all {
  background: var(--cream);
}

.drawer-list.slide {
  animation: drc-drawer-slidein 0.22s var(--ease);
}

@keyframes drc-drawer-slidein {
  from {
    opacity: 0;
    transform: translateX(16px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.drawer-list .ic {
  width: 16px;
  height: 16px;
  flex: none;
  color: var(--muted);
}

.drawer-region {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 14px;
  color: var(--muted);
}

.drawer-region .seg {
  display: inline-flex;
  padding: 2px;
  border: 1px solid var(--stone);
  border-radius: 8px;
  gap: 2px;
  background: var(--milk);
}

.drawer-region .seg button {
  min-height: 36px;
  min-width: 0;
  padding: 0 12px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  font: 600 13px/1 var(--font-ui);
  color: var(--muted);
  cursor: pointer;
}

.drawer-region .seg button[aria-pressed="true"] {
  background: var(--blue);
  color: var(--forest);
}

@media (min-width: 1240px) {
  .drc-drawer {
    display: none;
  }
}

/* ——— Search field (shared) ——— */
.site-header .search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 42px;
  padding: 0 6px 0 12px;
  border: 1px solid var(--stone);
  border-radius: 12px;
  background: var(--milk);
  transition: border-color 0.15s, box-shadow 0.15s;
}

.site-header .search-box:hover {
  border-color: color-mix(in srgb, var(--stone) 50%, var(--espresso));
}

.site-header .search-box:focus-within {
  border-color: var(--forest);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--forest) 12%, transparent);
}

.site-header .search-ic {
  color: var(--muted);
  width: 18px;
  height: 18px;
  flex: none;
}

.site-header .search-input {
  flex: 1;
  min-width: 0;
  height: 100%;
  border: 0;
  background: transparent;
  outline: none;
  font: 400 15px/1 var(--font-ui);
  color: var(--espresso);
}

.site-header .search-input::placeholder {
  color: #7a817c;
}

.site-header .search-input::-webkit-search-cancel-button {
  display: none;
}

/* ——— Search suggestions + blur scrim ——— */
.drc-search-scrim {
  position: fixed;
  inset: 0;
  z-index: 90; /* above page, below elevated header (see body.is-search-open) */
  background: rgba(23, 35, 31, 0.42);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  animation: drc-fade-in 0.18s ease-out;
}

/* Search UI lives inside .site-header — lift the whole header above the scrim
   so the panel stays sharp while only the page behind is blurred. */
body.is-search-open .site-header {
  z-index: 100;
}

@keyframes drc-fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

.sugg-group + .sugg-group {
  margin-top: 6px;
  border-top: 1px solid var(--stone);
  padding-top: 6px;
}

.sugg-title {
  margin: 0;
  padding: 8px 12px 4px;
  font: 600 12.5px/1.3 var(--font-ui);
  color: var(--muted);
}

.sugg-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  min-height: 48px;
  border-radius: 10px;
  cursor: pointer;
  color: var(--espresso);
  text-decoration: none;
}

.sugg-item:hover,
.sugg-item.is-active {
  background: var(--cream);
}

.sugg-thumb {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: color-mix(in srgb, var(--cream) 70%, var(--blue) 30%);
  color: var(--forest);
  display: grid;
  place-items: center;
  flex: none;
}

.sugg-thumb .ic {
  width: 18px;
  height: 18px;
}

.sugg-main {
  min-width: 0;
  flex: 1;
}

.sugg-label {
  display: block;
  font-weight: 500;
  font-size: 14.5px;
  line-height: 1.3;
  color: var(--espresso);
}

.sugg-label mark {
  background: transparent;
  color: var(--espresso);
  font-weight: 700;
}

.sugg-sub {
  display: block;
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sugg-empty {
  padding: 20px 12px;
}

.sugg-empty strong {
  display: block;
  font-size: 16px;
  color: var(--espresso);
  margin-bottom: 4px;
}

.sugg-empty p {
  margin: 0;
  color: var(--muted);
  font-size: 14.5px;
}

.sugg-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 6px 12px 8px;
}

.sugg-chips .pill {
  border: 0;
  cursor: pointer;
  background: var(--cream);
  color: var(--espresso);
  box-shadow: inset 0 0 0 1px var(--stone);
}

.sugg-chips .pill:hover {
  background: var(--blue);
  color: var(--forest);
  box-shadow: none;
}

.site-header .search-clear {
  width: 32px;
  height: 32px;
  border: 0;
  background: transparent;
  border-radius: 6px;
  color: var(--muted);
  display: grid;
  place-items: center;
  cursor: pointer;
  flex: none;
}

.site-header .search-clear:hover {
  background: var(--cream);
  color: var(--espresso);
}

.site-header .search-cancel {
  border: 0;
  background: transparent;
  color: var(--forest);
  font: 600 14px/1 var(--font-ui);
  min-height: 44px;
  padding: 0 10px;
  border-radius: 8px;
  cursor: pointer;
}

/* Mobile / tablet: floating search card over blur */
@media (max-width: 1239.98px) {
  .site-header .search {
    display: none;
    position: fixed;
    z-index: 110;
    top: calc(12px + env(safe-area-inset-top, 0px));
    left: max(16px, env(safe-area-inset-left));
    right: max(16px, env(safe-area-inset-right));
    bottom: auto;
    width: auto;
    max-width: 560px;
    margin: 0 auto;
    max-height: min(82vh, 720px);
    padding: 14px;
    background: var(--milk);
    border: 1px solid color-mix(in srgb, var(--stone) 65%, transparent);
    border-radius: 20px;
    box-shadow: var(--shadow-pop);
    overflow: hidden;
    flex-direction: column;
    gap: 0;
  }

  .site-header .search.is-open {
    display: flex;
    animation: drc-search-pop 0.22s var(--ease);
  }

  @keyframes drc-search-pop {
    from {
      opacity: 0;
      transform: translateY(-10px) scale(0.98);
    }
    to {
      opacity: 1;
      transform: none;
    }
  }

  .site-header .search-box {
    flex: none;
    height: 48px;
    border-radius: 14px;
    background: var(--cream);
    border-color: color-mix(in srgb, var(--stone) 80%, var(--forest));
  }

  .site-header .search-box:focus-within {
    background: var(--milk);
  }

  .site-header .search-input {
    font-size: 16px;
  }

  .site-header .search-submit {
    display: none;
  }

  .site-header .search-clear {
    display: grid;
  }

  .site-header .search-cancel {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    padding: 0 12px;
    border-radius: 999px;
    background: var(--cream);
    color: var(--forest);
    font-weight: 600;
  }

  .site-header .search-cancel:hover {
    background: var(--blue);
  }

  .site-header .sugg {
    position: static;
    flex: 1;
    width: auto;
    min-height: 0;
    max-height: none;
    margin-top: 10px;
    padding: 4px 2px 2px;
    overflow-y: auto;
    overscroll-behavior: contain;
    box-shadow: none;
    border: 0;
    border-radius: 0;
    background: transparent;
  }
}

/* ——— Footer (SSOT: mockups/pages/homepage .site-footer) ——— */
.site-footer {
  background: var(--forest);
  color: #e3eae6;
  margin-top: 0;
  padding: 52px 0 calc(24px + env(safe-area-inset-bottom, 0px));
}

.site-footer :focus-visible {
  outline-color: #fff;
}

.site-footer a {
  color: #e3eae6;
  text-underline-offset: 3px;
}

.site-footer a:hover {
  color: #fff;
}

.footer-disclosure {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 16px 18px;
  background: rgba(255, 255, 255, 0.07);
  border-radius: 12px;
  margin-bottom: 44px;
  font-size: 14px;
  max-width: 78ch;
}

.footer-disclosure p {
  margin: 0;
  line-height: 1.45;
}

.footer-disclosure .ic {
  flex: none;
  margin-top: 2px;
  color: #b9cbc2;
  width: 18px;
  height: 18px;
}

.footer-grid {
  display: grid;
  gap: 36px 32px;
  grid-template-columns: 1fr 1fr;
}

.footer-brand {
  grid-column: 1 / -1;
  max-width: 380px;
}

.footer-brand .brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  border-radius: 6px;
  margin-bottom: 14px;
}

.footer-brand .brand img {
  height: 38px;
  width: auto;
  display: block;
}

.footer-brand > p {
  font-size: 14px;
  line-height: 1.5;
  color: #b9cbc2;
  margin: 0 0 18px;
}

.footer-grid h2 {
  font: 600 13px/1.3 var(--font-ui);
  letter-spacing: 0;
  color: #b9cbc2;
  margin: 0 0 8px;
}

.footer-grid ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-grid li a {
  display: inline-block;
  padding: 6px 0;
  font-size: 14.5px;
  text-decoration: none;
}

.footer-grid li a:hover {
  text-decoration: underline;
}

.footer-region {
  justify-content: flex-start;
  flex-wrap: wrap;
  color: #b9cbc2;
  margin-top: 0;
}

.site-footer .seg-on-dark {
  display: inline-flex;
  padding: 2px;
  border-radius: 8px;
  gap: 2px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.25);
}

.site-footer .seg-on-dark button {
  min-height: 34px;
  min-width: 0;
  padding: 0 11px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  font: 600 13px/1 var(--font-ui);
  color: #e3ded2;
  cursor: pointer;
}

.site-footer .seg-on-dark button[aria-pressed="true"] {
  background: #fff;
  color: var(--forest);
}

.site-footer .seg-on-dark button:not([aria-pressed="true"]):hover {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
}

.footer-newsletter {
  margin-top: 22px;
  padding: 18px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.footer-newsletter h2 {
  margin-bottom: 6px;
}

.footer-newsletter > p {
  margin: 0 0 14px;
  font-size: 13.5px;
  line-height: 1.45;
  color: #b9cbc2;
}

.footer-newsletter input[type="email"] {
  width: 100%;
  min-height: 48px;
  margin-bottom: 8px;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.1);
  font: 400 14px/1 var(--font-ui);
  color: #f4f7f5;
}

.footer-newsletter input[type="email"]::placeholder {
  color: #a9bdb3;
}

.footer-newsletter .btn-primary {
  background: var(--blue);
  color: var(--forest);
}

.footer-newsletter .btn-primary:hover {
  background: #fff;
  color: var(--forest);
}

.footer-base {
  margin-top: 44px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 24px;
  font-size: 13px;
  color: #a9bdb3;
}

.footer-base p {
  margin: 0;
}

.footer-base ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0 20px;
}

.footer-base a {
  display: inline-block;
  padding: 8px 0;
}

@media (min-width: 900px) {
  .footer-grid {
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 48px;
  }

  .footer-brand {
    grid-column: auto;
  }
}

/* ——— FTC disclosure sheet (mobile bottom sheet / desktop modal) ——— */
.drc-ftc-sheet {
  position: fixed;
  inset: 0;
  z-index: 85;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 0;
}

.drc-ftc-sheet[hidden] {
  display: none !important;
}

.drc-ftc-sheet__scrim {
  position: absolute;
  inset: 0;
  background: color-mix(in srgb, var(--espresso) 50%, transparent);
  backdrop-filter: blur(2px);
}

.drc-ftc-sheet__panel {
  position: relative;
  z-index: 1;
  width: min(100%, 28rem);
  margin: 0;
  border-radius: 16px 16px 0 0;
  padding: 12px 20px 20px;
  padding-bottom: max(20px, env(safe-area-inset-bottom));
  background: var(--milk);
  border: 1px solid var(--stone);
  border-bottom: 0;
  box-shadow: 0 -12px 40px color-mix(in srgb, var(--espresso) 22%, transparent);
  color: var(--espresso);
}

.drc-ftc-sheet__panel::before {
  content: "";
  display: block;
  width: 40px;
  height: 4px;
  margin: 0 auto 14px;
  border-radius: 999px;
  background: var(--stone);
}

.drc-ftc-sheet__title {
  margin: 0 0 8px;
  font: 600 18px/1.2 var(--font-display);
  color: var(--espresso);
}

.drc-ftc-sheet__copy {
  margin: 0 0 16px;
  font-size: 14px;
  line-height: 1.5;
  color: var(--muted);
}

.drc-ftc-sheet__copy p {
  margin: 0 0 10px;
}

.drc-ftc-sheet__copy p:last-child {
  margin-bottom: 0;
}

.drc-ftc-sheet__copy a {
  color: var(--forest);
  font-weight: 600;
}

.drc-ftc-sheet__copy code {
  font-size: 0.92em;
}

.drc-ftc-sheet__close {
  margin-top: 8px;
  width: 100%;
}

@media (min-width: 640px) {
  .drc-ftc-sheet {
    align-items: center;
    padding: 24px;
  }

  .drc-ftc-sheet__panel {
    border-radius: 16px;
    border-bottom: 1px solid var(--stone);
    padding-top: 20px;
    box-shadow: 0 16px 48px color-mix(in srgb, var(--espresso) 24%, transparent);
  }

  .drc-ftc-sheet__panel::before {
    display: none;
  }
}

body.drc-lock {
  overflow: hidden;
}

@media (prefers-reduced-motion: reduce) {
  .drc-drawer__panel {
    transition: none;
  }
}
