/* =========================================================
   usagazebos — Vault Green design tokens + global styles
   ========================================================= */

@font-face {
  font-family: 'Space Grotesk';
  src: url('../fonts/space-grotesk-variable.woff2') format('woff2-variations'),
       url('../fonts/space-grotesk-variable.woff2') format('woff2');
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Manrope';
  src: url('../fonts/manrope-variable.woff2') format('woff2-variations'),
       url('../fonts/manrope-variable.woff2') format('woff2');
  font-weight: 400 800;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #F6F5EE;
  --surface: #FFFFFF;
  --ink: #15241C;
  --ink-soft: #4B5C53;
  --accent: #0F6B4F;
  --accent-hover: #0C5A41;
  --accent-ink: #FFFFFF;
  --support: #E2A33D;
  --support-ink: #15241C;
  --border: rgba(21, 36, 28, 0.12);
  --border-strong: rgba(21, 36, 28, 0.22);

  --font-display: 'Space Grotesk', sans-serif;
  --font-body: 'Manrope', sans-serif;

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-pill: 999px;

  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 20px;
  --space-lg: 48px;
  --space-xl: 96px;

  --container: 1280px;
  --container-narrow: 760px;
}

/* ---- Reset (neutralize UA defaults via :where() so real specificity wins) ---- */
:where(*, *::before, *::after) { box-sizing: border-box; }
:where(html) { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
:where(body, h1, h2, h3, h4, h5, h6, p, figure, blockquote, dl, dd, ul, ol) { margin: 0; }
:where(ul, ol) { padding: 0; list-style: none; }
:where(img, picture, svg, video) { display: block; max-width: 100%; }
:where(a) { color: inherit; text-decoration: none; }
:where(button, input, select, textarea) { font: inherit; color: inherit; }
:where(button) { background: none; border: none; cursor: pointer; padding: 0; }
:where(blockquote, figure) { margin: 0; border: 0; padding: 0; }

@media (prefers-reduced-motion: reduce) {
  :where(html) { scroll-behavior: auto; }
  :where(*, *::before, *::after) { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}

/* ---- Base ---- */
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.01em;
  color: var(--ink);
}

h1 { font-size: clamp(2.25rem, 1.6rem + 2.6vw, 3.75rem); }
h2 { font-size: clamp(1.75rem, 1.4rem + 1.6vw, 2.75rem); }
h3 { font-size: clamp(1.25rem, 1.1rem + 0.7vw, 1.6rem); }

p { max-width: 65ch; }
p.no-measure { max-width: none; }

a { transition: color 150ms ease; }

.container {
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--space-md);
}

.container--narrow {
  max-width: var(--container-narrow);
}

.screen-reader-text {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
}
.skip-link:focus {
  position: fixed;
  top: var(--space-sm);
  left: var(--space-sm);
  width: auto; height: auto;
  clip: auto;
  background: var(--ink);
  color: #fff;
  padding: var(--space-sm) var(--space-md);
  border-radius: var(--radius-sm);
  z-index: 1000;
}

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
  padding: 0.85em 1.6em;
  border-radius: var(--radius-sm);
  background: var(--accent);
  color: var(--accent-ink);
  border: 1px solid var(--accent);
  transition: background-color 150ms ease, border-color 150ms ease, transform 120ms ease;
}
.btn:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.btn:active { transform: translateY(1px); }
.btn--ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--border-strong);
}
.btn--ghost:hover { background: var(--surface); border-color: var(--accent); color: var(--accent); }
.btn--on-dark { border-color: rgba(255,255,255,0.35); }

/* ---- Badges (support amber — signal use only) ---- */
.badge {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.35em 0.85em;
  border-radius: var(--radius-pill);
  background: var(--support);
  color: var(--support-ink);
}

/* ---- Header ---- */
.site-header {
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  padding-block: var(--space-sm);
  min-height: 72px;
}
.site-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--ink);
  letter-spacing: -0.01em;
}
.site-logo__mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.site-logo__icon {
  display: block;
  width: 36px;
  height: 36px;
}
.site-nav { flex: 1; display: flex; justify-content: center; }
.site-nav__list {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
  white-space: nowrap;
}
.site-nav__list a {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--ink-soft);
}
.site-nav__list a:hover { color: var(--accent); }

.site-header__actions { display: flex; align-items: center; gap: var(--space-md); }
.site-header__cart { position: relative; display: inline-flex; color: var(--ink); }
.site-header__cart-count {
  position: absolute;
  top: -8px; right: -10px;
  background: var(--accent);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 700;
  min-width: 17px; height: 17px;
  border-radius: var(--radius-pill);
  display: flex; align-items: center; justify-content: center;
  padding-inline: 3px;
}
.site-nav__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
}
.site-nav__toggle span { width: 20px; height: 2px; background: var(--ink); border-radius: 2px; }
.site-nav-mobile { display: none; }

@media (max-width: 900px) {
  .site-nav { display: none; }
  .site-nav__toggle { display: flex; }
  .site-nav-mobile {
    display: none;
    border-top: 1px solid var(--border);
    background: var(--bg);
  }
  .site-nav-mobile.is-open { display: block; }
  .site-nav-mobile__list { display: flex; flex-direction: column; padding: var(--space-md); gap: var(--space-md); }
  .site-nav-mobile__list a { font-weight: 600; }
}

/* ---- Footer ---- */
.site-footer { background: var(--ink); color: rgba(255,255,255,0.82); margin-top: var(--space-xl); }
.site-footer__trust {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-md);
  padding-block: var(--space-md);
  border-bottom: 1px solid rgba(255,255,255,0.12);
}
.trust-item {
  display: flex;
  align-items: center;
  gap: 0.6em;
  font-size: 0.85rem;
  font-weight: 600;
  color: rgba(255,255,255,0.9);
}
.trust-item svg { flex-shrink: 0; color: var(--support); }

.site-footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: var(--space-lg);
  padding-block: var(--space-xl) var(--space-lg);
}
.footer-col__title {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.55);
  margin-bottom: var(--space-md);
}
.footer-col ul { display: flex; flex-direction: column; gap: 0.75em; }
.footer-col a { font-size: 0.92rem; color: rgba(255,255,255,0.82); }
.footer-col a:hover { color: var(--support); }
.footer-col--brand .site-logo { color: #fff; margin-bottom: var(--space-sm); }
.footer-tagline { font-size: 0.9rem; color: rgba(255,255,255,0.65); margin-bottom: var(--space-md); }
.footer-address { font-style: normal; font-size: 0.88rem; line-height: 1.7; color: rgba(255,255,255,0.7); }
.footer-address a { color: rgba(255,255,255,0.85); }

.site-footer__bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  padding-block: var(--space-md);
  border-top: 1px solid rgba(255,255,255,0.12);
  font-size: 0.82rem;
  color: rgba(255,255,255,0.55);
  flex-wrap: wrap;
}
.site-footer__legal-links { display: flex; gap: var(--space-md); }
.site-footer__legal-links a { color: rgba(255,255,255,0.55); }
.site-footer__legal-links a:hover { color: var(--support); }

@media (max-width: 900px) {
  .site-footer__trust { grid-template-columns: repeat(2, 1fr); }
  .site-footer__grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .site-footer__grid { grid-template-columns: 1fr; }
}

/* ---- Generic content / legal pages ---- */
.site-main { padding-block: var(--space-xl) var(--space-lg); }
.entry--page .entry__title { margin-bottom: var(--space-lg); }
.entry__content--prose { font-size: 1.02rem; color: var(--ink-soft); }
.entry__content--prose h2 {
  margin-top: var(--space-xl);
  margin-bottom: var(--space-md);
  font-size: 1.5rem;
}
.entry__content--prose h3 { margin-top: var(--space-lg); margin-bottom: var(--space-sm); font-size: 1.15rem; }
.entry__content--prose p { margin-bottom: var(--space-md); color: var(--ink-soft); }
.entry__content--prose ul { margin-bottom: var(--space-md); padding-left: 1.2em; list-style: disc; }
.entry__content--prose li { margin-bottom: 0.5em; color: var(--ink-soft); }
.entry__content--prose a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
.entry__content--prose strong { color: var(--ink); }

/* ---- Scroll reveal (degrades to visible without JS; honors prefers-reduced-motion) ---- */
.js-ready .reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 500ms ease, transform 500ms ease;
}
.js-ready .reveal--visible {
  opacity: 1;
  transform: none;
}
@media (prefers-reduced-motion: reduce) {
  .js-ready .reveal { opacity: 1; transform: none; transition: none; }
}

/* ---- Section heading pattern ---- */
.section { padding-block: var(--space-xl) 0; }
.section__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
  flex-wrap: wrap;
}
.section__head p { color: var(--ink-soft); margin-top: 0.4em; }
.section__link { font-weight: 700; color: var(--accent); white-space: nowrap; }
.section__link:hover { color: var(--accent-hover); }

/* ---- Product card (shared: homepage grid + shop archive) ---- */
.product-card {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: border-color 150ms ease, transform 150ms ease;
}
.product-card:hover { border-color: var(--border-strong); transform: translateY(-3px); }
.product-card__media {
  position: relative;
  aspect-ratio: 1 / 1;
  background: var(--bg);
  overflow: hidden;
}
.product-card__media img { width: 100%; height: 100%; object-fit: cover; }
.product-card__badge { position: absolute; top: 12px; left: 12px; }
.product-card__body { padding: var(--space-md); display: flex; flex-direction: column; gap: 0.4em; flex: 1; }
.product-card__cat { font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: var(--ink-soft); }
.product-card__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.98rem;
  line-height: 1.3;
  color: var(--ink);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.product-card__footer {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
  padding-top: 0.4em;
}
.product-card__price { font-family: var(--font-display); font-weight: 700; font-size: 1.05rem; color: var(--ink); }
.product-card__cart {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px; height: 38px;
  border-radius: var(--radius-sm);
  background: var(--accent);
  color: #fff;
  flex-shrink: 0;
}
.product-card__cart:hover { background: var(--accent-hover); }

.product-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-md);
}
@media (max-width: 1100px) { .product-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 780px) { .product-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .product-grid { grid-template-columns: 1fr; } }
/* ---- Product card: link portion now separate from the buy-now footer ---- */
.product-card__link { display: flex; flex-direction: column; flex: 1; color: inherit; }
.product-card__footer {
  padding: 0.4em var(--space-md) var(--space-md);
}
.product-card__cart {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px; height: 38px;
  border-radius: var(--radius-sm);
  background: var(--accent);
  color: #fff;
  flex-shrink: 0;
}
.product-card__cart:hover { background: var(--accent-hover); }
.buy-now-button { width: 100%; text-align: center; }
.product-card__rating { margin-top: 2px; }
.product-card__rating .star-rating { color: var(--support); font-size: 0.78rem; }
