/* =========================================================
   Crumb Get Some Bakery — Site Styles
   Edit colors/fonts here in :root to re-theme the whole site.
   ========================================================= */

:root {
  --cream: #fff8f1;
  --cream-dark: #f2e4d3;
  --brown-dark: #4a2e1f;
  --brown: #6b4226;
  --accent: #d98e73;      /* caramel / terracotta buttons */
  --accent-dark: #c2704f;
  --pink: #f3b9c0;        /* soft pink accent */
  --white: #ffffff;
  --shadow: 0 4px 14px rgba(74, 46, 31, 0.12);
  --radius: 16px;
  --max-width: 1100px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: 'Nunito', 'Segoe UI', -apple-system, sans-serif;
  color: var(--brown-dark);
  background: var(--cream);
  line-height: 1.6;
}

h1, h2, h3, h4 {
  font-family: 'Playfair Display', Georgia, 'Times New Roman', serif;
  color: var(--brown-dark);
  margin: 0 0 0.5em;
}

p { margin: 0 0 1em; }

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

img { max-width: 100%; display: block; }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Header / Nav ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--cream);
  border-bottom: 1px solid var(--cream-dark);
}

.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--brown-dark);
}

.brand-logo {
  height: 58px;
  width: 111px;
  flex-shrink: 0;
}

.brand-logo.photo-frame {
  border-radius: 0;
  overflow: visible;
  background: none;
  box-shadow: none;
}

.brand-logo.photo-frame img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.brand-logo .img-placeholder {
  font-size: 8px;
  padding: 2px;
  border-radius: 8px;
}

.brand-name {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.15rem;
  line-height: 1.25;
  font-weight: 700;
  white-space: nowrap;
}

.nav-links {
  display: flex;
  gap: 28px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  text-decoration: none;
  color: var(--brown-dark);
  font-weight: 600;
  font-size: 0.98rem;
  padding: 6px 2px;
  border-bottom: 2px solid transparent;
  transition: border-color 0.2s ease;
}

.nav-links a:hover,
.nav-links a.active {
  border-bottom-color: var(--accent);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.6rem;
  color: var(--brown-dark);
  cursor: pointer;
}

@media (max-width: 720px) {
  .nav-toggle { display: block; }
  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--cream);
    flex-direction: column;
    gap: 0;
    border-bottom: 1px solid var(--cream-dark);
    display: none;
  }
  .nav-links.open { display: flex; }
  .nav-links li { border-top: 1px solid var(--cream-dark); }
  .nav-links a { display: block; padding: 14px 24px; }
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-block;
  padding: 13px 26px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--white);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.98rem;
  border: none;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.15s ease;
}

.btn:hover { background: var(--accent-dark); transform: translateY(-1px); }

.btn-outline {
  background: transparent;
  color: var(--brown-dark);
  border: 2px solid var(--brown-dark);
}

.btn-outline:hover { background: var(--brown-dark); color: var(--white); }

.btn-block { width: 100%; text-align: center; }

/* ---------- Hero ---------- */

.hero {
  padding: 60px 0 40px;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 40px;
  align-items: center;
}

@media (max-width: 800px) {
  .hero-inner { grid-template-columns: 1fr; }
}

.hero-eyebrow {
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--accent-dark);
  margin-bottom: 10px;
}

.hero h1 { font-size: 2.6rem; margin-bottom: 0.35em; }

.hero p.lead { font-size: 1.1rem; max-width: 46ch; }

.hero-ctas { display: flex; gap: 14px; margin-top: 20px; flex-wrap: wrap; }

.hero .photo-frame { aspect-ratio: 4 / 5; border-radius: var(--radius); }

/* ---------- Photo frames & placeholders ---------- */

.photo-frame {
  width: 100%;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--cream-dark);
  box-shadow: var(--shadow);
}

.photo-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ---------- Slideshow (e.g. Singles photo cycling through flavors) ---------- */

.slideshow { position: relative; }

.slideshow .slide,
.slideshow .img-placeholder {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1s ease;
}

.slideshow .slide.active,
.slideshow .img-placeholder.active {
  opacity: 1;
  z-index: 1;
}

/* ---------- Hover-to-play video tiles (About — Behind the Scenes) ---------- */

.video-frame {
  position: relative;
  cursor: pointer;
}

.video-frame video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  background: var(--cream-dark);
}

.video-frame .play-badge {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  color: var(--white);
  background: rgba(74, 46, 31, 0.25);
  transition: opacity 0.2s ease;
}

.video-frame.playing .play-badge {
  opacity: 0;
  pointer-events: none;
}

.img-placeholder {
  width: 100%;
  height: 100%;
  min-height: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 16px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--brown);
  background:
    repeating-linear-gradient(
      45deg,
      var(--cream-dark),
      var(--cream-dark) 10px,
      #eaddc8 10px,
      #eaddc8 20px
    );
  border: 2px dashed var(--accent);
  border-radius: inherit;
}

.img-placeholder .ph-icon { font-size: 1.6rem; display: block; margin-bottom: 6px; }

/* aspect-ratio helper classes used across pages */
.ratio-square { aspect-ratio: 1 / 1; }
.ratio-wide { aspect-ratio: 16 / 9; }
.ratio-portrait { aspect-ratio: 3 / 4; }

/* ---------- Sections ---------- */

section { padding: 50px 0; }

.section-title { text-align: center; margin-bottom: 8px; }

.section-sub {
  text-align: center;
  color: var(--brown);
  max-width: 60ch;
  margin: 0 auto 36px;
}

.band {
  background: var(--cream-dark);
}

/* ---------- Notice / rule banner ---------- */

.notice {
  background: var(--pink);
  color: var(--brown-dark);
  border-radius: var(--radius);
  padding: 18px 22px;
  margin: 0 0 36px;
  font-size: 0.95rem;
  text-align: center;
}

.notice strong { display: block; margin-bottom: 4px; font-size: 1.02rem; }

/* ---------- Policy blocks (Policies page) ---------- */

.policy-block {
  max-width: 720px;
  margin: 0 auto 32px;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px 28px;
}

.policy-block h2 {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.3rem;
  margin-bottom: 14px;
}

.policy-icon { font-size: 1.4rem; }

.policy-block ul {
  margin: 0;
  padding-left: 20px;
}

.policy-block li {
  margin-bottom: 10px;
  color: var(--brown);
}

.policy-block li:last-child { margin-bottom: 0; }

.policy-block li strong { color: var(--brown-dark); }

/* ---------- Product grid ---------- */

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 26px;
}

.product-card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
}

.product-card .photo-frame { border-radius: 0; }

.product-body { padding: 18px 20px 22px; display: flex; flex-direction: column; flex: 1; }

.product-name { font-size: 1.15rem; margin-bottom: 2px; }

.product-price { font-weight: 700; color: var(--accent-dark); margin-bottom: 8px; }

.product-desc { font-size: 0.92rem; color: var(--brown); flex: 1; }

.fulfillment-tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 4px 10px;
  border-radius: 999px;
  margin-bottom: 10px;
}

.tag-pickup { background: var(--pink); color: var(--brown-dark); }

.tag-both { background: var(--accent); color: var(--white); }

/* ---------- Flavor list ---------- */

.flavor-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 14px;
}

.flavor-card {
  background: var(--white);
  border-radius: 12px;
  box-shadow: var(--shadow);
  padding: 10px 16px 10px 10px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-left: 4px solid var(--accent);
}

.flavor-thumb {
  width: 56px;
  height: 56px;
  flex-shrink: 0;
  border-radius: 10px;
  box-shadow: none;
}

.flavor-thumb .img-placeholder {
  font-size: 6px;
  padding: 2px;
  border-width: 1px;
}

.flavor-thumb .ph-icon { font-size: 0.9rem; margin-bottom: 1px; }

.flavor-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.flavor-name {
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 700;
  font-size: 1.02rem;
  color: var(--brown-dark);
}

.flavor-type {
  font-size: 0.85rem;
  color: var(--brown);
}

/* ---------- Editor note (visible in-browser, remove before going live) ---------- */

.edit-note {
  background: #fff3cd;
  border: 1px dashed #b98900;
  color: #6b4f00;
  font-size: 0.8rem;
  padding: 8px 12px;
  border-radius: 8px;
  margin-bottom: 10px;
}

/* ---------- About preview / info blocks ---------- */

.info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}

@media (max-width: 800px) {
  .info-grid { grid-template-columns: 1fr; }
}

/* ---------- Footer ---------- */

.site-footer {
  background: var(--brown-dark);
  color: var(--cream);
  padding: 44px 0 26px;
  margin-top: 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 30px;
  margin-bottom: 30px;
}

@media (max-width: 700px) {
  .footer-grid { grid-template-columns: 1fr; }
}

.site-footer h4 { color: var(--cream); font-family: 'Playfair Display', serif; }

.site-footer a { color: var(--cream); opacity: 0.85; text-decoration: none; }

.site-footer a:hover { opacity: 1; text-decoration: underline; }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.15);
  padding-top: 18px;
  font-size: 0.82rem;
  opacity: 0.75;
  text-align: center;
}

.footer-bottom .disclosure {
  margin: 0 0 8px;
}

.social-row { display: flex; gap: 14px; margin-top: 10px; align-items: center; }
.social-row a { font-size: 1.3rem; display: inline-flex; align-items: center; gap: 6px; }
.social-row svg { vertical-align: middle; }
