:root {
  --bg: #f4f1eb;
  --surface: #ffffff;
  --surface-soft: #faf7f2;
  --ink: #23211d;
  --muted: #6f6a62;
  --line: #dfd7cb;
  --accent: #9f6b2f;
  --accent-strong: #7f4f16;
  --shadow: 0 14px 34px rgba(35, 33, 29, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Manrope", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.9), transparent 34%),
    linear-gradient(180deg, #f8f5ef 0%, #f0ece4 100%);
}

a {
  color: inherit;
}

button,
input {
  font: inherit;
}

.utility-bar {
  background: #1b1712;
  color: #f6efe4;
  font-size: 0.84rem;
}

.utility-bar__inner,
.site-header__inner,
.page-shell {
  width: min(1320px, calc(100% - 32px));
  margin: 0 auto;
}

.utility-bar__inner {
  min-height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(223, 215, 203, 0.9);
}

.site-header__inner {
  min-height: 86px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brandmark {
  font-family: "Source Serif 4", serif;
  font-size: 2.05rem;
  text-decoration: none;
}

.site-nav {
  display: flex;
  gap: 22px;
}

.site-nav a {
  text-decoration: none;
  color: var(--muted);
}

.header-tools {
  display: flex;
  align-items: center;
  gap: 14px;
}

.header-search,
.header-mini-cart {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  text-decoration: none;
}

.header-search {
  min-width: 190px;
  color: var(--muted);
}

.header-mini-cart {
  gap: 10px;
  font-weight: 700;
}

.header-mini-cart__label,
.eyebrow,
.product-card__meta span,
.detail-specs dt,
.stock-pill {
  font-size: 0.76rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.page-shell {
  padding: 26px 0 64px;
}

.archive-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 22px;
  margin-bottom: 24px;
}

.archive-hero__copy,
.product-card__excerpt,
.detail-intro,
.detail-panel p,
.detail-bullets,
.cart-empty,
.cart-item p,
.support-card p {
  color: var(--muted);
  line-height: 1.65;
}

.archive-hero > div,
.archive-hero__panel,
.sidebar-card,
.product-card,
.cart-sidebar,
.detail-card,
.detail-panel,
.support-card {
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  border-radius: 18px;
}

.archive-hero > div:first-child {
  padding: 30px 34px;
}

.archive-hero__panel {
  padding: 28px;
  display: grid;
  align-content: center;
  gap: 10px;
  background: linear-gradient(180deg, #fffaf4, #f5ecdf);
}

.archive-hero h1,
.shop-toolbar h2,
.detail-hero__copy h1 {
  margin: 8px 0 0;
  font-family: "Source Serif 4", serif;
  font-size: clamp(2.2rem, 4vw, 3.35rem);
  line-height: 1.02;
}

.archive-hero__panel strong {
  font-size: 2rem;
}

.archive-hero__panel span,
.archive-hero__panel small,
.breadcrumbs,
.toolbar-panel,
.site-nav a,
.detail-specs dd {
  color: var(--muted);
}

.breadcrumbs {
  margin: 0 0 18px;
  font-size: 0.95rem;
}

.store-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr) 320px;
  gap: 24px;
  align-items: start;
}

.sidebar-card,
.cart-sidebar,
.detail-card,
.detail-panel,
.support-card {
  padding: 22px;
}

.sidebar-card + .sidebar-card {
  margin-top: 18px;
}

.sidebar-card h2,
.cart-sidebar h2,
.detail-panel h2,
.support-card h2 {
  margin: 0 0 14px;
  font-size: 1.08rem;
}

.sidebar-list,
.sidebar-notes,
.detail-bullets {
  margin: 0;
  padding-left: 18px;
}

.sidebar-list li {
  display: flex;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}

.sidebar-list li:last-child {
  border-bottom: 0;
}

.shop-main,
.shop-sidebar,
.cart-sidebar {
  min-width: 0;
}

.shop-toolbar {
  margin-bottom: 18px;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
}

.toolbar-panel {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 999px;
}

.toolbar-sort {
  color: var(--ink);
  font-weight: 600;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.product-grid--related {
  margin-top: 16px;
}

.product-card {
  overflow: hidden;
  padding: 0;
}

.product-card__media,
.detail-hero__media {
  position: relative;
  display: block;
  min-height: 260px;
  padding: 22px;
  text-decoration: none;
  background:
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.9), transparent 32%),
    linear-gradient(160deg, #ecd9c3, #d9e5eb);
}

.product-card__brand,
.product-card__code {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.93);
  border: 1px solid rgba(35, 33, 29, 0.08);
}

.product-card__brand {
  min-height: 36px;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 0.82rem;
}

.product-stage {
  position: absolute;
  inset: 64px 26px 26px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 18px;
}

.product-stage--detail {
  inset: 90px 34px 34px;
  gap: 24px;
}

.product-pack,
.product-vial {
  position: relative;
  background: rgba(255, 255, 255, 0.94);
  box-shadow:
    0 16px 30px rgba(67, 46, 17, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.product-pack {
  width: 148px;
  min-height: 178px;
  padding: 18px 16px;
  border-radius: 18px;
  border: 1px solid rgba(67, 46, 17, 0.1);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.product-stage--detail .product-pack {
  width: 220px;
  min-height: 254px;
  padding: 24px 22px;
}

.product-pack__brand {
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.product-pack strong {
  font-size: 1.2rem;
  line-height: 1.1;
}

.product-pack small {
  color: var(--muted);
}

.product-stage--detail .product-pack strong {
  font-size: 1.55rem;
}

.product-vial {
  width: 70px;
  height: 154px;
  border-radius: 28px 28px 22px 22px;
  border: 1px solid rgba(67, 46, 17, 0.12);
  overflow: hidden;
}

.product-vial::before {
  content: "";
  position: absolute;
  top: 0;
  left: 14px;
  right: 14px;
  height: 26px;
  border-radius: 0 0 12px 12px;
  background: linear-gradient(180deg, #2f2b27, #6a6257);
}

.product-vial::after {
  content: "";
  position: absolute;
  left: 8px;
  right: 8px;
  bottom: 18px;
  height: 50px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(223, 187, 118, 0.75), rgba(159, 107, 47, 0.92));
}

.product-vial span {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 78px;
  text-align: center;
  font-family: "Source Serif 4", serif;
  font-size: 1rem;
  font-weight: 700;
}

.product-stage--detail .product-vial {
  width: 96px;
  height: 210px;
}

.product-stage--detail .product-vial span {
  bottom: 112px;
  font-size: 1.2rem;
}

.product-card__code {
  position: absolute;
  left: 22px;
  bottom: 22px;
  width: 96px;
  height: 96px;
  border-radius: 24px;
  font-family: "Source Serif 4", serif;
  font-size: 1.7rem;
  font-weight: 700;
}

.product-card__body {
  padding: 18px;
}

.product-card h3 {
  margin: 8px 0 0;
  font-size: 1.18rem;
}

.product-card__title {
  text-decoration: none;
}

.product-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.product-card__meta span,
.stock-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  background: var(--surface-soft);
  border: 1px solid var(--line);
  color: var(--muted);
}

.product-card__footer,
.buy-controls,
.cart-sidebar__status,
.cart-summary__row,
.cart-item,
.cart-item__controls,
.detail-hero,
.detail-content,
.support-strip {
  display: flex;
}

.product-card__footer {
  margin-top: 18px;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
}

.price-stack strong,
.detail-price {
  font-size: 1.55rem;
  font-weight: 800;
}

.buy-controls {
  align-items: center;
  gap: 10px;
}

.buy-controls--detail {
  margin-top: 18px;
}

.qty-picker {
  display: inline-flex;
  align-items: center;
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-soft);
}

.qty-button {
  width: 40px;
  height: 44px;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.qty-input {
  width: 48px;
  border: 0;
  background: transparent;
  text-align: center;
  outline: none;
}

.primary-button,
.cart-link {
  border: 0;
  cursor: pointer;
}

.primary-button {
  min-height: 46px;
  padding: 0 18px;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--accent), var(--accent-strong));
  color: #fff;
  font-weight: 700;
  box-shadow: 0 10px 20px rgba(127, 79, 22, 0.16);
}

.cart-link {
  padding: 0;
  color: var(--muted);
  text-decoration: underline;
  background: transparent;
}

.cart-sidebar {
  position: sticky;
  top: 116px;
}

.cart-sidebar__head {
  margin-bottom: 10px;
}

.cart-sidebar__status,
.cart-summary__row {
  justify-content: space-between;
  align-items: center;
}

.cart-items {
  display: grid;
  gap: 14px;
  margin: 20px 0;
}

.cart-item {
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.cart-item h3 {
  margin: 6px 0 0;
  font-size: 1rem;
}

.cart-item__controls {
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}

.cart-item__qty {
  min-width: 30px;
  text-align: center;
}

.cart-summary {
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.cart-checkout {
  width: 100%;
  margin-top: 16px;
}

.detail-card {
  padding: 28px;
}

.detail-hero {
  gap: 26px;
  align-items: stretch;
}

.detail-hero__media,
.detail-hero__copy {
  flex: 1;
}

.detail-hero__copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.detail-content {
  gap: 20px;
  margin-top: 24px;
}

.detail-content > * {
  flex: 1;
}

.detail-specs {
  margin: 0;
  display: grid;
  gap: 14px;
}

.detail-specs div {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 10px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.detail-specs div:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.related-products {
  margin-top: 24px;
}

.support-strip {
  gap: 18px;
  margin-top: 28px;
}

.support-card {
  flex: 1;
}

@media (max-width: 1180px) {
  .store-layout {
    grid-template-columns: 240px minmax(0, 1fr);
  }

  .cart-sidebar {
    grid-column: 1 / -1;
    position: static;
  }

  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .utility-bar__inner,
  .site-header__inner {
    flex-wrap: wrap;
    justify-content: center;
  }

  .archive-hero,
  .store-layout,
  .detail-hero,
  .detail-content,
  .support-strip {
    grid-template-columns: 1fr;
    flex-direction: column;
  }

  .shop-toolbar,
  .product-card__footer {
    flex-direction: column;
    align-items: stretch;
  }

  .toolbar-panel {
    justify-content: space-between;
  }

  .product-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .page-shell,
  .site-header__inner,
  .utility-bar__inner {
    width: min(100% - 20px, 1320px);
  }

  .header-tools {
    width: 100%;
    justify-content: space-between;
  }

  .header-search {
    min-width: 0;
    flex: 1;
  }

  .detail-card,
  .sidebar-card,
  .cart-sidebar,
  .detail-panel,
  .support-card,
  .archive-hero > div:first-child,
  .archive-hero__panel {
    padding: 18px;
  }

  .detail-specs div {
    grid-template-columns: 1fr;
    gap: 6px;
  }
}
