:root {
  --ivory: #f5f1e8;
  --paper: #faf8f2;
  --sand: #ded4c5;
  --taupe: #aa8977;
  --taupe-dark: #967565;
  --terracotta: #a98573;
  --olive: #a8aa97;
  --ink: #403b35;
  --charcoal: #33342e;
  --line: rgba(64, 59, 53, 0.3);
  --white: #fffdfa;
  --shell: min(100% - 64px, 1380px);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: "Mulish", "Avenir Next", "Segoe UI", sans-serif;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
body.menu-open { overflow: hidden; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
button { color: inherit; }
img, video { display: block; max-width: 100%; }
h1, h2, h3, p { margin-top: 0; }
h1, h2, h3 { font-weight: 400; }

.shell { width: var(--shell); margin-inline: auto; }
.section { padding: 108px 0; }
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.skip-link {
  position: fixed;
  z-index: 1000;
  left: 16px;
  top: 16px;
  padding: 10px 14px;
  background: var(--white);
  transform: translateY(-160%);
  transition: transform 180ms ease;
}
.skip-link:focus { transform: translateY(0); }

.site-header {
  position: sticky;
  z-index: 100;
  top: 0;
  color: var(--ink);
  background: rgba(250, 248, 242, 0.95);
  border-bottom: 1px solid rgba(64, 59, 53, 0.08);
  backdrop-filter: blur(12px);
  transition: color 650ms var(--ease), background-color 650ms var(--ease), border-color 650ms var(--ease), box-shadow 650ms var(--ease), backdrop-filter 650ms var(--ease);
}
.site-header.is-scrolled {
  color: var(--ink);
  background: rgba(250, 248, 242, 0.94);
  border-color: rgba(64, 59, 53, 0.08);
  box-shadow: 0 8px 24px rgba(49, 43, 36, 0.035);
  backdrop-filter: blur(12px);
}
.header-inner {
  min-height: 60px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
}
.brand-logo { justify-self: start; width: 190px; }
.brand-logo img {
  width: 100%;
  height: auto;
  filter: none;
  transition: filter 400ms var(--ease);
}
.desktop-nav { display: flex; align-items: center; gap: clamp(24px, 3vw, 52px); }
.desktop-nav a { font-size: 15px; }
.header-actions { font-size: 13px; }
.desktop-nav a { position: relative; padding: 8px 0; }
.desktop-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 100%;
  bottom: 2px;
  height: 1px;
  background: currentColor;
  transition: right 300ms var(--ease);
}
.desktop-nav a:hover::after, .desktop-nav a:focus-visible::after { right: 0; }
.header-actions { justify-self: end; display: flex; align-items: center; gap: 4px; }
.icon-button, .arrow-button, .favorite-button {
  border: 0;
  background: transparent;
  display: inline-grid;
  place-items: center;
  cursor: pointer;
}
.icon-button { width: 42px; height: 42px; }
.icon-button svg { width: 19px; height: 19px; stroke-width: 1.35; }
.bag-button { width: auto; grid-auto-flow: column; gap: 7px; padding-inline: 10px 0; }
.bag-count { font-size: 12px; }
.mobile-menu-button { display: none; justify-self: start; }

.mobile-menu {
  position: fixed;
  z-index: 110;
  inset: 0;
  padding: 26px 24px 40px;
  background: var(--ivory);
  visibility: hidden;
  opacity: 0;
  transform: translateY(-18px);
  transition: opacity 350ms var(--ease), transform 350ms var(--ease), visibility 350ms;
}
.mobile-menu.is-open { visibility: visible; opacity: 1; transform: translateY(0); }
.mobile-menu-head { display: flex; justify-content: space-between; align-items: center; }
.mobile-menu-head img { width: 168px; }
.mobile-menu nav { display: grid; margin-top: 78px; border-top: 1px solid var(--line); }
.mobile-menu nav a { display: flex; align-items: center; justify-content: space-between; padding: 18px 0; font-size: 26px; border-bottom: 1px solid var(--line); }
.mobile-menu nav svg { width: 20px; }
.mobile-menu > p { position: absolute; bottom: 32px; color: rgba(64, 59, 53, 0.58); }

.eyebrow { margin-bottom: 28px; color: var(--terracotta); font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; }
.eyebrow span { margin-inline: 5px; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
  min-height: 52px;
  padding: 0 24px;
  border: 1px solid transparent;
  font-size: 13px;
  transition: background-color 250ms ease, color 250ms ease, border-color 250ms ease, transform 250ms ease;
}
.button svg { width: 18px; stroke-width: 1.4; }
.button:hover { transform: translateY(-2px); }
.product-card { position: relative; flex: 0 0 calc((100% - 66px) / 4); scroll-snap-align: start; }
.product-image { display: block; aspect-ratio: 0.75; overflow: hidden; background: #ebe6dd; }
.product-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 700ms var(--ease); }
.product-card:hover .product-image img { transform: scale(1.025); }
.favorite-button { position: absolute; top: 10px; right: 10px; width: 38px; height: 38px; color: var(--ink); background: rgba(250,248,242,.72); backdrop-filter: blur(8px); }
.favorite-button svg { width: 18px; stroke-width: 1.35; }
.favorite-button[aria-pressed="true"] svg { fill: currentColor; }
.product-card h3 { margin: 15px 42px 3px 0; font-size: 14px; }
.product-card p { margin: 0; font-size: 14px; }

.site-footer { color: rgba(255,253,250,.82); background: var(--charcoal); }
.footer-grid { display: grid; grid-template-columns: 1.1fr 1fr .9fr 1.2fr; gap: 60px; padding: 70px 0 54px; }
.footer-brand img { width: 190px; filter: invert(1) brightness(2); }
.footer-brand p { margin: 22px 0; font-size: 13px; }
.social-links { display: flex; align-items: center; gap: 16px; }
.social-links a { display: grid; place-items: center; width: 28px; height: 28px; font-size: 12px; font-weight: 600; }
.social-links svg { width: 19px; }
.footer-links { display: grid; grid-template-columns: 1fr 1fr; gap: 7px 24px; align-content: start; font-size: 13px; }
.footer-links a:hover, .footer-contact a:hover { color: var(--white); }
.footer-contact { display: grid; align-content: start; gap: 6px; font-size: 13px; font-style: normal; }
.footer-contact span { color: rgba(255,253,250,.48); }
.footer-contact a:nth-of-type(2) { margin-top: 16px; }
.footer-subscribe > p { margin-bottom: 15px; font-size: 13px; }
.footer-subscribe form { display: grid; grid-template-columns: 1fr 46px; border: 1px solid rgba(255,253,250,.4); }
.footer-subscribe input { min-width: 0; height: 46px; padding: 0 15px; color: var(--white); border: 0; outline: 0; background: transparent; }
.footer-subscribe input::placeholder { color: rgba(255,253,250,.55); }
.footer-subscribe button { border: 0; color: var(--white); background: transparent; cursor: pointer; }
.footer-subscribe button svg { width: 18px; }
.footer-subscribe small { display: block; margin-top: 12px; color: rgba(255,253,250,.45); font-size: 11px; }
.footer-bottom { display: grid; grid-template-columns: 1fr auto 1fr; gap: 30px; align-items: center; min-height: 74px; border-top: 1px solid rgba(255,253,250,.2); color: rgba(255,253,250,.46); font-size: 11px; }
.footer-bottom div { display: flex; gap: 24px; }
.footer-bottom > span:last-child { justify-self: end; }

.reveal { opacity: 0; transform: translateY(34px); transition: opacity 800ms var(--ease), transform 800ms var(--ease); }
.reveal.is-visible { opacity: 1; transform: translateY(0); }
.image-reveal { overflow: hidden; }
.image-reveal img { transform: scale(1.045); transition: transform 1300ms var(--ease); }
.image-reveal.is-visible img { transform: scale(1); }

:focus-visible { outline: 2px solid currentColor; outline-offset: 4px; }

@media (max-width: 1100px) {
  :root { --shell: min(100% - 48px, 1000px); }
  .desktop-nav { gap: 24px; }
  .brand-logo { width: 170px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 820px) {
  :root { --shell: min(100% - 40px, 720px); }
  .section { padding: 80px 0; }
  .header-inner { grid-template-columns: 44px 1fr auto; min-height: 60px; }
  .mobile-menu-button { display: inline-grid; }
  .brand-logo { justify-self: center; width: 166px; }
  .desktop-nav { display: none; }
  .footer-bottom { grid-template-columns: 1fr; padding: 24px 0; }
  .footer-bottom > span:last-child { justify-self: start; }
}

@media (max-width: 560px) {
  :root { --shell: calc(100% - 32px); }
  .section { padding: 66px 0; }
  .site-header .shell { width: calc(100% - 24px); }
  .header-actions .icon-button { width: 36px; }
  .bag-count { display: none; }
  .brand-logo { width: 144px; }
  .footer-grid { grid-template-columns: 1fr; gap: 40px; padding-top: 56px; }
  .footer-links { grid-template-columns: 1fr 1fr; }
  .footer-bottom div { flex-direction: column; gap: 8px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
  .reveal { opacity: 1; transform: none; }
  .image-reveal img { transform: none; }
}
