:root {
  --color-primary: #5fc2d1;    /* soft turquoise, sampled from the sticker */
  /* Darkened from the original #3fa3b3 sample — that shade only hit ~2.9:1
     contrast for white button text and body links on cream, below WCAG AA's
     4.5:1 for normal text. Same hue, just darker enough to read reliably. */
  --color-primary-dark: #226672;
  --color-text: #12303a;       /* near-black navy */
  --color-bg: #fffdf9;         /* warm white/cream */
  /* Darkened from the original #e8795a sample for the same reason — white
     text on it was ~2.9:1. */
  --color-accent: #c9421c;     /* warm accent for seasonal promos */
  --color-card-border: #e3ddd2;
  --font-heading: "Montserrat", "Arial Narrow", sans-serif;
  --font-body: "Quicksand", "Verdana", sans-serif;
  --radius: 14px;
}

* { box-sizing: border-box; }

/* [hidden] loses to any class rule that sets `display` (e.g. .btn) at equal
   specificity, since ours is declared later — force it to actually hide. */
[hidden] { display: none !important; }

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  line-height: 1.55;
}

a { color: var(--color-primary-dark); }

h1, h2, h3, .brand {
  font-family: var(--font-heading);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: var(--color-text);
  color: white;
  padding: 0.6rem 1rem;
  border-radius: 0 0 8px 0;
  font-weight: 600;
}
.skip-link:focus { left: 0; }

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid var(--color-accent);
  outline-offset: 2px;
}

/* Header / nav */
header.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.75rem 1.25rem;
  background: var(--color-primary);
  color: var(--color-text);
  position: sticky;
  top: 0;
  z-index: 10;
}

header.site-header .brand-group { display: flex; align-items: center; gap: 0.75rem; text-decoration: none; color: inherit; }
header.site-header img.logo { height: 44px; width: 44px; }
header.site-header .brand { font-size: 0.95rem; }

nav.site-nav { display: flex; align-items: center; gap: 1rem; font-size: 0.85rem; font-weight: 600; }
nav.site-nav a { color: var(--color-text); text-decoration: none; }
nav.site-nav a:hover { text-decoration: underline; }
nav.site-nav a.cart-link { display: flex; align-items: center; gap: 0.3rem; }

main { max-width: 1040px; margin: 0 auto; padding: 1.5rem 1.25rem 3rem; }

/* Hero */
.hero {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.5rem;
  background: linear-gradient(135deg, var(--color-primary) 0%, #a7dfe6 100%);
  border-radius: var(--radius);
  padding: 2rem;
  margin-bottom: 2.5rem;
}
.hero .hero-copy { flex: 1 1 320px; }
.hero .seasonal-badge {
  display: inline-block;
  background: var(--color-accent);
  color: white;
  font-family: var(--font-heading);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  padding: 0.3rem 0.7rem;
  border-radius: 999px;
  margin-bottom: 0.75rem;
}
.hero h1 { font-size: 1.9rem; margin: 0 0 0.5rem; }
.hero p { margin: 0 0 1.25rem; max-width: 42ch; }

.btn {
  display: inline-block;
  font-family: var(--font-heading);
  letter-spacing: 0.05em;
  font-size: 0.85rem;
  text-transform: uppercase;
  padding: 0.8rem 1.6rem;
  border-radius: 999px;
  border: none;
  background: var(--color-text);
  color: white;
  cursor: pointer;
  text-decoration: none;
}
.btn:hover { background: var(--color-primary-dark); }
.btn.btn-secondary { background: transparent; color: var(--color-text); border: 2px solid var(--color-text); }
.btn:disabled { background: #bbb; cursor: not-allowed; }

section { margin-bottom: 3rem; }
section > h2 { font-size: 1.1rem; margin-bottom: 1rem; }

/* Product grid / cards */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.25rem;
}

.product-card {
  display: block;
  border: 1px solid var(--color-card-border);
  border-radius: var(--radius);
  padding: 1rem;
  background: white;
  text-decoration: none;
  color: inherit;
}
.product-card:hover { border-color: var(--color-primary-dark); }
.product-card .thumb {
  aspect-ratio: 1 / 1;
  background: var(--color-primary);
  border-radius: 10px;
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-family: var(--font-heading);
  font-size: 0.75rem;
  text-align: center;
  padding: 0.5rem;
  overflow: hidden;
}
.product-card .thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.product-card h3 { margin: 0 0 0.25rem; font-size: 0.95rem; letter-spacing: 0.02em; text-transform: none; font-family: var(--font-body); font-weight: 600; }
.product-card .price { font-weight: 700; }
.badge-seasonal { display: inline-block; background: var(--color-accent); color: white; font-size: 0.65rem; padding: 0.15rem 0.5rem; border-radius: 999px; margin-left: 0.4rem; vertical-align: middle; }

.allergen-note { font-size: 0.85rem; color: #555; }
.stock-status { font-size: 0.85rem; font-weight: 600; }
.stock-status.in-stock { color: #2b7a3f; }
.stock-status.out-of-stock { color: #a33; }

/* Forms */
form.site-form { max-width: 480px; }
form.site-form label { display: block; font-weight: 600; margin: 0.75rem 0 0.25rem; font-size: 0.9rem; }
form.site-form input, form.site-form textarea {
  width: 100%;
  padding: 0.6rem 0.75rem;
  border: 1px solid var(--color-card-border);
  border-radius: 8px;
  font-family: inherit;
  font-size: 0.95rem;
}
form.site-form .form-status { margin-top: 0.75rem; font-size: 0.9rem; }
form.site-form .form-status.success { color: #2b7a3f; }
form.site-form .form-status.error { color: #a33; }
.honeypot { position: absolute; left: -9999px; }

/* FAQ */
details.faq-item { border-bottom: 1px solid var(--color-card-border); padding: 0.75rem 0; }
details.faq-item summary { font-weight: 600; cursor: pointer; }
details.faq-item p { margin: 0.5rem 0 0; }

/* Product detail page */
.product-detail { display: flex; flex-wrap: wrap; gap: 2rem; }
.product-detail .gallery { flex: 1 1 320px; }
.product-detail .gallery .main-image {
  aspect-ratio: 1 / 1;
  background: var(--color-primary);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-family: var(--font-heading);
  text-align: center;
  padding: 1rem;
  overflow: hidden;
}
.product-detail .gallery .main-image img { width: 100%; height: 100%; object-fit: cover; display: block; }
.product-detail .gallery .thumb-strip { display: flex; gap: 0.5rem; margin-top: 0.5rem; flex-wrap: wrap; }
.product-detail .gallery .thumb-strip button {
  padding: 0; border: 2px solid transparent; border-radius: 8px; overflow: hidden;
  width: 64px; height: 64px; cursor: pointer; background: none;
}
.product-detail .gallery .thumb-strip button.active { border-color: var(--color-primary-dark); }
.product-detail .gallery .thumb-strip img { width: 100%; height: 100%; object-fit: cover; display: block; }
.product-detail .info { flex: 1 1 320px; }
.product-detail .price { font-size: 1.4rem; font-weight: 700; margin: 0.5rem 0; }
.variant-select { margin: 1rem 0; }
.variant-select select { padding: 0.5rem; border-radius: 8px; border: 1px solid var(--color-card-border); }
.qty-controls { display: flex; align-items: center; gap: 0.5rem; margin: 1rem 0; }
.qty-controls input { width: 4rem; text-align: center; padding: 0.4rem; border-radius: 8px; border: 1px solid var(--color-card-border); }

/* Cart page */
table.cart-table { width: 100%; border-collapse: collapse; margin-bottom: 1.5rem; }
table.cart-table th, table.cart-table td { text-align: left; padding: 0.6rem 0.5rem; border-bottom: 1px solid var(--color-card-border); }
table.cart-table input[type="number"] { width: 3.5rem; padding: 0.3rem; }
.cart-totals { max-width: 320px; margin-left: auto; }
.cart-totals div { display: flex; justify-content: space-between; padding: 0.25rem 0; }
.cart-totals .grand-total { font-weight: 700; font-size: 1.1rem; border-top: 1px solid var(--color-card-border); margin-top: 0.5rem; padding-top: 0.5rem; }

footer {
  padding: 1.5rem 1.25rem;
  font-size: 0.8rem;
  color: #555;
  border-top: 1px solid #eee;
}
footer .disclosure { max-width: 60ch; }

@media (max-width: 600px) {
  header.site-header { flex-wrap: wrap; }
  .hero { padding: 1.25rem; }
}
