/* =========================================================
   Divine Foods, LLC. — Design System
   Palette drawn from the brand's own stamped seal:
   espresso brown + peach cream, warmed with cranberry
   (red velvet) and caramel. Background is always white.
   ========================================================= */

:root {
  /* ---- Color tokens ---- */
  --df-white:      #FFFFFF;
  --df-espresso:   #481A03; /* primary text / brand ink, matches the seal */
  --df-espresso-2: #5C2408; /* hover state for espresso surfaces */
  --df-cocoa:      #733B1A; /* secondary brown */
  --df-cranberry:  #8C3737; /* accent — red velvet, used sparingly */
  --df-cranberry-2:#753030;
  --df-peach:      #FEDFB9; /* soft warm surface */
  --df-cream:      #F2D1B3; /* deeper tint for borders / hovers */
  --df-caramel:    #BF9B7A; /* muted brown for captions & rules */
  --df-near-black: #401303; /* deepest brown — footer */
  --df-ink-soft:   #6B4A34; /* body copy on white, softer than full espresso */

  /* Warm elevated-surface tints, mixed from the existing peach/white —
     no new brand colors, just a cozier resting state for cards than flat white. */
  --df-card-surface:       color-mix(in srgb, var(--df-peach) 10%, var(--df-white));
  --df-card-surface-hover: color-mix(in srgb, var(--df-peach) 20%, var(--df-white));

  /* ---- Type ---- */
  --font-display: "Fraunces", "Iowan Old Style", "Palatino Linotype", serif;
  --font-script:  "Caveat", cursive;
  --font-body:    "Nunito Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  /* ---- Shadow / radius ---- */
  --shadow-soft: 0 18px 40px -18px rgba(72, 26, 3, 0.35);
  --shadow-card: 0 10px 24px -12px rgba(72, 26, 3, 0.28);
  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 10px;

  --container-w: 1200px;
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}
body {
  margin: 0;
  background: var(--df-white);
  color: var(--df-ink-soft);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img, video { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
button { font: inherit; }
h1, h2, h3, h4 { margin: 0; color: var(--df-espresso); font-weight: 600; }
p { margin: 0 0 1rem; }
p:last-child { margin-bottom: 0; }

/* ---- Focus visibility (global baseline; components may refine below) ---- */
a:focus-visible,
button:focus-visible,
summary:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid var(--df-cranberry);
  outline-offset: 3px;
  border-radius: 4px;
}

.font-display { font-family: var(--font-display); }
.font-script { font-family: var(--font-script); }

/* ---- Type scale ---- */
h1, .h1 { font-family: var(--font-display); font-size: clamp(2.4rem, 4.6vw, 4.1rem); line-height: 1.03; letter-spacing: -0.01em; font-weight: 600; }
h2, .h2 { font-family: var(--font-display); font-size: clamp(1.9rem, 3.2vw, 2.7rem); line-height: 1.08; letter-spacing: -0.005em; font-weight: 600; }
h3, .h3 { font-family: var(--font-display); font-size: 1.35rem; line-height: 1.2; font-weight: 600; }
.lede { font-size: 1.18rem; line-height: 1.6; color: var(--df-cocoa); }
.eyebrow {
  font-family: var(--font-script);
  font-size: 1.5rem;
  color: var(--df-cranberry);
  display: inline-block;
  transform: rotate(-2deg);
  margin: 0 0 0.15rem;
  line-height: 1;
}
.small { font-size: 0.9rem; }
.text-caramel { color: var(--df-caramel); }
.text-cocoa { color: var(--df-cocoa); }
.text-espresso { color: var(--df-espresso); }
.text-peach { color: var(--df-peach); }
.text-cream { color: var(--df-cream); }

/* ---- Layout ---- */
.container { width: 100%; max-width: var(--container-w); margin: 0 auto; padding: 0 24px; }
.section { padding: 96px 0; }
.section-sm { padding: 56px 0; }
.section-tight-top { padding-top: 0; }
.bg-peach { background: var(--df-peach); }
.bg-cream { background: var(--df-cream); }
.bg-espresso { background: var(--df-espresso); }
.bg-near-black { background: var(--df-near-black); }
.bg-white { background: var(--df-white); }

.grid { display: grid; gap: 32px; }
.g2 { grid-template-columns: repeat(2, 1fr); }
.g3 { grid-template-columns: repeat(3, 1fr); }
.g4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 900px) {
  .g3, .g4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .g2, .g3, .g4 { grid-template-columns: 1fr; }
}

.contact-grid { grid-template-columns: 0.85fr 1.15fr; gap: 56px; }
@media (max-width: 860px) {
  .contact-grid { grid-template-columns: 1fr; gap: 40px; }
}

.flex { display: flex; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-3 { gap: 0.75rem; }
.gap-4 { gap: 1.25rem; }
.text-center { text-align: center; }
.mx-auto { margin-left: auto; margin-right: auto; }

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.95rem 1.9rem;
  border-radius: 999px;
  font-weight: 800;
  font-size: 0.98rem;
  letter-spacing: 0.01em;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.18s ease, background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
  min-height: 44px;
}
.btn:hover { transform: translateY(-2px); }
.btn:focus-visible { outline: 3px solid var(--df-cranberry); outline-offset: 3px; }
.btn-primary { background: var(--df-espresso); color: var(--df-peach); }
.btn-primary:hover { background: var(--df-espresso-2); color: var(--df-peach); }
.btn-outline { border-color: var(--df-espresso); color: var(--df-espresso); background: transparent; }
.btn-outline:hover { background: var(--df-espresso); color: var(--df-peach); }
.btn-outline-light { border-color: var(--df-peach); color: var(--df-peach); background: transparent; }
.btn-outline-light:hover { background: var(--df-peach); color: var(--df-espresso); }
.btn-lg { padding: 1.1rem 2.3rem; font-size: 1.05rem; }
.btn-block { width: 100%; justify-content: center; }

/* ---- Nav ---- */
/* Nav styles now live in css/header.css, loaded alongside js/header.js
   which injects the <nav> markup — see that file to configure the header. */

/* ---- Stamp / seal badge (signature element) ---- */
.stamp {
  width: 152px;
  height: 152px;
  border-radius: 50%;
  background: var(--df-espresso);
  color: var(--df-peach);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.92rem;
  line-height: 1.25;
  box-shadow: var(--shadow-soft);
  border: 3px dashed rgba(254, 223, 185, 0.55);
  flex-shrink: 0;
}
.stamp span { display: block; }
.stamp-rotate { transform: rotate(-9deg); }
.stamp-lg { width: 190px; height: 190px; font-size: 1.05rem; }

/* ---- Hero ---- */
.hero {
  position: relative;
  min-height: 88vh;
  display: flex;
  align-items: flex-end;
  background-size: cover;
  background-position: center;
}
.hero::before {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(64,19,3,0.15) 0%, rgba(64,19,3,0.55) 62%, rgba(64,19,3,0.86) 100%);
}
.hero-inner {
  position: relative;
  z-index: 2;
  width: 100%;
  padding: 64px 0 130px;
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border: 1.5px solid var(--df-peach);
  color: var(--df-peach);
  background: rgba(64, 19, 3, 0.55);
  border-radius: 999px;
  padding: 0.4rem 1rem;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 1.3rem;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
}
.hero h1 { color: var(--df-white); max-width: 15ch; text-shadow: 0 2px 12px rgba(0, 0, 0, 0.35); }
.hero .lede { color: var(--df-peach); max-width: 46ch; margin: 1.2rem 0 2rem; text-shadow: 0 1px 6px rgba(0, 0, 0, 0.3); }
.hero-stamp-wrap {
  position: absolute;
  right: 6%;
  bottom: -70px;
  z-index: 5;
}
@media (max-width: 900px) {
  .hero { min-height: 78vh; }
  .hero-stamp-wrap { right: 50%; transform: translateX(50%); bottom: -56px; }
  .hero-stamp-wrap .stamp { width: 118px; height: 118px; font-size: 0.78rem; }
}

/* ---- Page header (subpages) ---- */
.page-header { padding: 76px 0 56px; border-bottom: 1px solid var(--df-cream); }
.page-header .eyebrow { margin-bottom: 0.4rem; }
.page-header h1 { max-width: 22ch; }
.page-header .lede { margin-top: 1rem; max-width: 52ch; }
.page-header-row { display: flex; justify-content: space-between; align-items: flex-end; gap: 2rem; flex-wrap: wrap; }

/* ---- Story / split sections ---- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; gap: 36px; } }
.split img { border-radius: var(--radius-lg); box-shadow: var(--shadow-card); width: 100%; object-fit: cover; }
.split-media { position: relative; }

/* ---- Menu / flavor rail (circular stamp photos) ---- */
.flavor-rail {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}
@media (max-width: 900px) { .flavor-rail { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .flavor-rail { grid-template-columns: 1fr 1fr; gap: 18px; } }
.flavor-card { text-align: center; }
.flavor-photo {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  overflow: hidden;
  border: 3px dashed var(--df-caramel);
  padding: 8px;
  margin-bottom: 1rem;
  background: var(--df-white);
  box-shadow: 0 0 0 0 rgba(72, 26, 3, 0);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.flavor-photo img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.flavor-card:hover .flavor-photo,
.flavor-card:focus-within .flavor-photo {
  transform: translateY(-6px);
  box-shadow: var(--shadow-soft);
}
.flavor-card h3 { font-size: 1.08rem; margin-bottom: 0.25rem; }
.flavor-card p { font-size: 0.92rem; }

/* ---- Promise strip ---- */
.promise-strip { background: var(--df-peach); }
.promise-row { display: grid; grid-template-columns: repeat(3, 1fr); }
@media (max-width: 760px) { .promise-row { grid-template-columns: 1fr; } }
.promise-item {
  padding: 44px 40px;
  border-right: 1px solid rgba(72, 26, 3, 0.18);
  text-align: center;
}
.promise-row .promise-item:last-child { border-right: none; }
@media (max-width: 760px) {
  .promise-item { border-right: none; border-bottom: 1px solid rgba(72, 26, 3, 0.18); }
  .promise-row .promise-item:last-child { border-bottom: none; }
}
.promise-icon {
  width: 56px; height: 56px;
  border-radius: 50%;
  background: var(--df-espresso);
  color: var(--df-peach);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 1rem;
  font-size: 1.25rem;
}
.promise-item h3 { font-size: 1.15rem; margin-bottom: 0.4rem; }
.promise-item p { color: var(--df-cocoa); font-size: 0.95rem; }

/* ---- Product / menu cards ---- */
.category-block { margin-bottom: 64px; }
.category-block:last-child { margin-bottom: 0; }
.category-head { display: flex; align-items: baseline; gap: 1rem; margin-bottom: 2rem; flex-wrap: wrap; }
.category-head h2 { font-size: 1.6rem; }
.category-head .category-note { color: var(--df-cocoa); font-size: 0.95rem; }
.product-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
@media (max-width: 900px) { .product-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .product-grid { grid-template-columns: 1fr; } }
.product-card {
  background: var(--df-white);
  border: 1px solid var(--df-cream);
  border-radius: var(--radius-md);
  padding: 20px;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}
.product-card:hover { box-shadow: var(--shadow-card); transform: translateY(-3px); }
.product-photo {
  aspect-ratio: 4 / 3;
  border-radius: var(--radius-sm);
  overflow: hidden;
  margin-bottom: 1rem;
  background: var(--df-cream);
}
.product-photo img { width: 100%; height: 100%; object-fit: cover; }
.product-card h3 { font-size: 1.12rem; margin-bottom: 0.3rem; }
.product-desc { font-size: 0.93rem; margin-bottom: 0.75rem; }
.price-tag {
  display: inline-block;
  background: var(--df-peach);
  color: var(--df-espresso);
  font-weight: 800;
  font-size: 0.85rem;
  padding: 0.3rem 0.8rem;
  border-radius: 999px;
}
.allergen-note { font-size: 0.83rem; color: var(--df-cocoa); margin-top: 0.7rem; display: flex; gap: 0.4rem; align-items: flex-start; }
.allergen-note i { margin-top: 0.15rem; color: var(--df-cranberry); }
.diet-note i { color: var(--df-cocoa); }

/* ---- Testimonials ---- */
.testimonial-card {
  background: var(--df-card-surface);
  border: 1px solid var(--df-cream);
  border-radius: var(--radius-md);
  padding: 2rem;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
  text-align: left;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}
.testimonial-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-card);
  background: var(--df-card-surface-hover);
}
.testimonial-stars { color: var(--df-caramel); font-size: 0.8rem; letter-spacing: 0.2em; }
.testimonial-quote {
  margin: 0;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 500;
  font-size: 1.12rem;
  line-height: 1.5;
  color: var(--df-espresso);
}
.testimonial-meta {
  margin: auto 0 0;
  display: flex;
  align-items: center;
  gap: 0.9rem;
}
.testimonial-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  flex-shrink: 0;
  background: var(--df-espresso);
  color: var(--df-peach);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
}
.testimonial-name { display: block; font-weight: 700; color: var(--df-espresso); font-size: 0.95rem; }
.testimonial-product { display: block; font-size: 0.85rem; color: var(--df-cocoa); }

/* ---- Compliance box ---- */
.compliance-box {
  background: var(--df-cream);
  border: 1px solid var(--df-caramel);
  border-radius: var(--radius-md);
  padding: 1.6rem 1.9rem;
  color: var(--df-espresso);
}
.compliance-box a { text-decoration: underline; }
.compliance-box h2 { display: flex; align-items: center; gap: 0.6rem; }

/* ---- Cards (values, contact info) ---- */
.info-card {
  background: var(--df-card-surface);
  border: 1px solid var(--df-cream);
  border-radius: var(--radius-md);
  padding: 2rem;
}
.value-card {
  text-align: center;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}
.value-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-card);
  background: var(--df-card-surface-hover);
}
.contact-item { display: flex; gap: 1rem; align-items: flex-start; margin-bottom: 1.6rem; }
.contact-item:last-child { margin-bottom: 0; }
.contact-icon {
  width: 46px; height: 46px; flex-shrink: 0;
  border-radius: 50%;
  background: var(--df-peach);
  color: var(--df-espresso);
  display: flex; align-items: center; justify-content: center;
}
.contact-item h3 { font-size: 1rem; margin-bottom: 0.2rem; }
.contact-item a:hover, .contact-item a:focus-visible { color: var(--df-cranberry); }

/* ---- Forms ---- */
.field { margin-bottom: 1.2rem; }
.field label { display: block; font-weight: 700; color: var(--df-espresso); margin-bottom: 0.4rem; font-size: 0.92rem; }
.field input, .field select, .field textarea {
  width: 100%;
  border: 1.5px solid var(--df-cream);
  border-radius: var(--radius-sm);
  padding: 0.8rem 1rem;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--df-espresso);
  background: var(--df-white);
}
.field input:focus, .field select:focus, .field textarea:focus,
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible {
  outline: 2.5px solid var(--df-cranberry);
  outline-offset: 1px;
  border-color: var(--df-cranberry);
}
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; }
@media (max-width: 560px) { .field-row { grid-template-columns: 1fr; } }
.form-note { font-size: 0.88rem; color: var(--df-cocoa); margin-top: 1rem; }

/* ---- Newsletter band ---- */
.newsletter-band {
  background: var(--df-espresso);
  border-radius: var(--radius-lg);
  padding: 3rem;
  color: var(--df-peach);
}
.newsletter-band h2 { color: var(--df-white); }
.newsletter-band .lede { color: var(--df-peach); margin: 0; }
.newsletter-form { display: flex; gap: 0.8rem; flex-wrap: wrap; }
.newsletter-form input {
  flex: 1;
  min-width: 200px;
  padding: 0.9rem 1.2rem;
  border-radius: 999px;
  border: none;
  font-family: var(--font-body);
  font-size: 1rem;
}
.newsletter-form input:focus-visible { outline: 3px solid var(--df-peach); }
.newsletter-msg { color: var(--df-peach); }

/* ---- Market/Instagram feature ---- */
.market-feature {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  min-height: 480px;
  display: flex;
  align-items: flex-end;
  background-size: cover;
  background-position: center;
}
.market-feature::before {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(0deg, rgba(64,19,3,0.88) 0%, rgba(64,19,3,0.15) 65%);
}
.market-feature-content { position: relative; z-index: 2; padding: 2.6rem; color: var(--df-white); max-width: 620px; text-shadow: 0 1px 8px rgba(0, 0, 0, 0.35); }
.market-feature-content .eyebrow { color: var(--df-peach); }
.market-feature-content h2 { color: var(--df-white); }
.market-feature-content p { color: var(--df-cream); }

/* ---- Gallery ---- */
.gallery-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
@media (max-width: 900px) { .gallery-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 560px) { .gallery-grid { grid-template-columns: repeat(2, 1fr); } }
.gallery-item {
  position: relative;
  border-radius: var(--radius-sm);
  overflow: hidden;
  aspect-ratio: 1/1;
  display: block;
  cursor: zoom-in;
}
.gallery-item img, .gallery-item video { width: 100%; height: 100%; object-fit: cover; transition: transform 0.35s ease; }
.gallery-item:hover img, .gallery-item:hover video { transform: scale(1.06); }
.gallery-item video { cursor: default; }
.gallery-cap {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 0.6rem 0.8rem 0.5rem;
  background: linear-gradient(0deg, rgba(64,19,3,0.85), rgba(64,19,3,0));
  color: var(--df-white);
  font-size: 0.82rem;
  font-weight: 700;
}
.gallery-item:focus-visible { outline: 3px solid var(--df-cranberry); outline-offset: 2px; }

.lightbox {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(64, 19, 3, 0.92);
  display: none;
  align-items: center; justify-content: center;
  padding: 5vh 5vw;
}
.lightbox.is-open { display: flex; }
.lightbox img { max-height: 88vh; border-radius: var(--radius-sm); box-shadow: var(--shadow-soft); }
.lightbox-cap { position: absolute; bottom: 6vh; left: 0; right: 0; text-align: center; color: var(--df-peach); font-weight: 700; }
.lightbox-close {
  position: absolute; top: 24px; right: 28px;
  background: none; border: 2px solid var(--df-peach); color: var(--df-peach);
  width: 44px; height: 44px; border-radius: 50%; font-size: 1.4rem; cursor: pointer;
}

/* ---- Accordion (FAQ) ----
   Built on native <details>/<summary> so it's keyboard- and
   screen-reader-accessible with no custom ARIA bookkeeping: no focus
   can hide inside a closed panel, and it works even if JS fails. */
.accordion-item { border-bottom: 1px solid var(--df-cream); }
.accordion-item:first-child { border-top: 1px solid var(--df-cream); }
.accordion-btn {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 1.35rem 0.2rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.08rem;
  color: var(--df-espresso);
  cursor: pointer;
  list-style: none;
}
.accordion-btn::-webkit-details-marker { display: none; }
.accordion-icon {
  flex-shrink: 0; width: 26px; height: 26px; border-radius: 50%;
  border: 2px solid var(--df-cranberry); color: var(--df-cranberry);
  display: flex; align-items: center; justify-content: center;
  transition: transform 0.25s ease; font-size: 0.85rem;
}
.accordion-item[open] .accordion-icon { transform: rotate(45deg); }
.accordion-panel-inner { padding: 0 0.2rem 1.4rem; font-size: 0.98rem; }
.accordion-panel-inner a { text-decoration: underline; }

/* ---- Footer ---- */
/* Footer styles now live in css/footer.css, loaded alongside js/footer.js
   which injects the <footer> markup — see that file to configure the footer. */
.social-icon {
  width: 44px; height: 44px;
  border-radius: 50%;
  border: 1.5px solid var(--df-caramel);
  display: flex; align-items: center; justify-content: center;
  color: var(--df-peach);
}
.social-icon:hover, .social-icon:focus-visible { background: var(--df-peach); color: var(--df-near-black); border-color: var(--df-peach); }

/* ---- Skip link ---- */
.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--df-espresso); color: var(--df-peach);
  padding: 0.8rem 1.2rem; z-index: 999; border-radius: 0 0 10px 0;
}
.skip-link:focus { left: 0; }

/* ---- Utility ---- */
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
