/* SanoGrain — design tokens */
:root {
  --brown: #835E54;
  --brown-deep: #6b4a42;
  --ink: #443728;
  --cream: #FDF8F4;
  --cream-deep: #F6EDE3;
  --cream-warm: #EFE3D4;
  --border: #E8DDD5;
  --white: #FFFFFF;
  --accent-green: #5A7A3E;
  --shadow-sm: 0 1px 2px rgba(68, 55, 40, 0.04), 0 2px 8px rgba(68, 55, 40, 0.04);
  --shadow-md: 0 4px 16px rgba(68, 55, 40, 0.08);
  --shadow-lg: 0 12px 48px rgba(68, 55, 40, 0.12);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  background: var(--cream);
  color: var(--ink);
  font-family: 'Open Sans', system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  scroll-behavior: smooth;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Crimson Pro', Georgia, serif;
  color: var(--brown);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.01em;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
input, textarea, select { font-family: inherit; font-size: inherit; color: inherit; }

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

/* ---------- NAV ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: grid; grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 18px 48px;
  background: rgba(253, 248, 244, 0.78);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s, padding .3s;
}
.nav.scrolled { border-bottom-color: var(--border); padding: 12px 48px; }
.nav-left, .nav-right { display: flex; gap: 32px; align-items: center; }
.nav-right { justify-content: flex-end; }
.nav-link {
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink);
  padding: 6px 0;
  position: relative;
  transition: color .2s;
}
.nav-link:hover { color: var(--brown); }
.nav-link.active { color: var(--brown); }
.nav-link.active::after {
  content: ''; position: absolute; bottom: 0; left: 0; right: 0;
  height: 1px; background: var(--brown);
}
.nav-logo {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  font-family: 'Crimson Pro', serif;
}
.nav-logo .mark {
  font-size: 28px; font-weight: 700; color: var(--ink);
  letter-spacing: -0.02em; line-height: 1;
}
.nav-logo .logo-img {
  display: block; width: auto; object-fit: contain;
}
.nav-logo .mark-leaf { color: var(--accent-green); }
.nav-logo .tag {
  font-family: 'Open Sans', sans-serif;
  font-size: 9px; letter-spacing: 0.32em; text-transform: uppercase;
  color: var(--brown); margin-top: 4px;
}
.nav-cart {
  position: relative; display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px; border: 1px solid var(--border); border-radius: 999px;
  font-size: 13px; letter-spacing: 0.06em;
  transition: border-color .2s, background .2s;
}
.nav-cart:hover { border-color: var(--brown); background: var(--cream-deep); }
.cart-count {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px;
  background: var(--brown); color: var(--cream);
  font-size: 11px; font-weight: 700;
}

/* ---------- BUTTONS ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 14px 28px; border-radius: 999px;
  font-size: 13px; letter-spacing: 0.1em; text-transform: uppercase;
  font-weight: 600;
  transition: transform .15s, background .2s, color .2s, box-shadow .2s;
}
.btn-primary { background: var(--brown); color: var(--cream); }
.btn-primary:hover { background: var(--brown-deep); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-ghost { background: transparent; color: var(--brown); border: 1px solid var(--brown); }
.btn-ghost:hover { background: var(--brown); color: var(--cream); }
.btn-sm { padding: 10px 20px; font-size: 11px; }

/* ---------- LAYOUT ---------- */
.container { max-width: 1280px; margin: 0 auto; padding: 0 48px; }
.container-wide { max-width: 1480px; margin: 0 auto; padding: 0 48px; }
section { padding: 120px 0; }
.section-eyebrow {
  font-size: 11px; letter-spacing: 0.32em; text-transform: uppercase;
  color: var(--brown); margin-bottom: 16px; font-weight: 600;
}
.section-title { font-size: 56px; margin-bottom: 20px; }
.section-sub { font-size: 18px; color: var(--ink); opacity: 0.8; max-width: 640px; }

/* ---------- HERO ---------- */
.hero {
  position: relative; min-height: 100vh;
  display: grid; grid-template-columns: 1.1fr 1fr;
  align-items: center;
  padding: 140px 48px 100px;
  overflow: hidden;
}
.hero-copy { position: relative; z-index: 2; max-width: 620px; }
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 11px; letter-spacing: 0.32em; text-transform: uppercase;
  color: var(--brown); margin-bottom: 28px;
}
.hero-eyebrow::before {
  display: none;
}
.hero-title {
  font-size: 96px; line-height: 1.02; letter-spacing: -0.02em;
  margin-bottom: 28px;
}
.hero-title em {
  font-style: italic; color: var(--brown); font-weight: 700;
}
.hero-sub {
  font-size: 19px; line-height: 1.7; max-width: 480px;
  margin-bottom: 40px; color: var(--ink); opacity: 0.88;
}
.hero-ctas { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-scene {
  position: absolute; inset: 0; z-index: 1;
  pointer-events: auto;
}
.hero-scene canvas { width: 100% !important; height: 100% !important; }
.hero-stats {
  position: absolute; left: 48px; right: 48px; bottom: 48px; z-index: 2;
  display: flex; gap: 56px;
  padding-top: 32px;
  border-top: 1px solid var(--border);
}
.hero-stat .num {
  font-family: 'Crimson Pro', serif; font-size: 40px; color: var(--brown); font-weight: 700;
  line-height: 1;
}
.hero-stat .lbl {
  font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase;
  margin-top: 6px; color: var(--ink); opacity: 0.7;
}

/* ---------- MARQUEE / TICKER ---------- */
.ticker {
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 22px 0; overflow: hidden;
  background: var(--cream-deep);
}
.ticker-track {
  display: flex; gap: 64px;
  animation: ticker 38s linear infinite;
  white-space: nowrap;
}
.ticker-item {
  display: inline-flex; align-items: center; gap: 18px;
  font-family: 'Crimson Pro', serif; font-size: 22px; color: var(--brown);
  font-style: italic;
}
.ticker-item::after {
  content: '❋'; color: var(--brown); font-style: normal; opacity: 0.5;
}
@keyframes ticker { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---------- PRODUCT GRID ---------- */
.product-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 32px; margin-top: 60px;
}
.product-grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.product-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 28px 28px 24px;
  transition: transform .35s cubic-bezier(.22,.61,.36,1), box-shadow .35s, border-color .3s;
  cursor: pointer;
  position: relative;
  transform-style: preserve-3d;
  perspective: 900px;
}
.product-card:hover {
  box-shadow: var(--shadow-lg);
  border-color: var(--brown);
  transform: translateY(-6px);
}
.product-card .pimg {
  aspect-ratio: 2/3;
  background: var(--cream-deep);
  border-radius: 2px;
  overflow: hidden;
  margin-bottom: 20px;
  transition: transform .5s;
}
.product-card .pimg img { width: 100%; height: 100%; object-fit: cover; }
.product-card:hover .pimg { transform: translateZ(20px); }
.product-card .pcat {
  font-size: 10px; letter-spacing: 0.24em; text-transform: uppercase;
  color: var(--brown); margin-bottom: 8px;
}
.product-card .pname {
  font-family: 'Crimson Pro', serif; font-size: 24px; color: var(--ink);
  font-weight: 600; margin-bottom: 6px;
}
.product-card .pweight { font-size: 13px; color: var(--ink); opacity: 0.65; margin-bottom: 14px; }
.product-card .prow { display: flex; justify-content: space-between; align-items: center; }
.product-card .pprice {
  font-family: 'Crimson Pro', serif; font-size: 24px; color: var(--brown); font-weight: 700;
}
.product-card .padd {
  width: 36px; height: 36px; border-radius: 999px;
  background: var(--cream-deep); color: var(--brown);
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 18px; transition: background .2s, color .2s;
}
.product-card .padd:hover { background: var(--brown); color: var(--cream); }
.pprice-original {
  text-decoration: line-through;
  color: var(--ink); opacity: 0.5;
  font-size: 16px; font-weight: 400;
  margin-right: 6px;
}
.pprice-off {
  font-size: 11px; font-weight: 700;
  color: var(--accent-green);
  margin-left: 8px;
  letter-spacing: 0.02em;
}
.pd-price-original {
  text-decoration: line-through;
  color: var(--ink); opacity: 0.45;
  font-size: 28px; font-weight: 400;
  margin-right: 8px;
}
.pd-price-off {
  font-size: 18px; font-weight: 700;
  color: var(--accent-green);
  margin-left: 12px;
  letter-spacing: 0.02em;
}
.pbadge {
  position: absolute; top: 16px; left: 16px;
  padding: 4px 10px; border-radius: 999px;
  background: var(--brown); color: var(--cream);
  font-size: 9px; letter-spacing: 0.2em; text-transform: uppercase;
}

/* ---------- WHY / STORY ---------- */
.why-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 0; margin-top: 60px;
  border-top: 1px solid var(--border);
}
.why-cell {
  padding: 48px 36px 48px 0;
  border-bottom: 1px solid var(--border);
}
.why-cell:not(:last-child) { border-right: 1px solid var(--border); padding-right: 36px; }
.why-cell + .why-cell { padding-left: 36px; }
.why-num {
  font-family: 'Crimson Pro', serif; font-size: 13px; color: var(--brown);
  letter-spacing: 0.1em; margin-bottom: 24px;
}
.why-h { font-size: 26px; margin-bottom: 12px; color: var(--ink); font-weight: 600; }
.why-p { font-size: 15px; line-height: 1.65; color: var(--ink); opacity: 0.82; }

/* ---------- STORY SPLIT ---------- */
.story {
  background: var(--cream-deep);
}
.story-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: center; }
.story-img {
  aspect-ratio: 4/5; border-radius: 2px; overflow: hidden;
  background: linear-gradient(135deg, var(--cream-warm), #ddc9b5);
  position: relative;
}
.story-pouch {
  position: absolute; inset: 12% 18%;
  display: flex; align-items: center; justify-content: center;
}
.story-pouch img { max-height: 100%; filter: drop-shadow(0 20px 40px rgba(0,0,0,0.15)); }
.story-quote {
  font-family: 'Crimson Pro', serif; font-style: italic;
  font-size: 22px; color: var(--brown);
  border-left: 2px solid var(--brown); padding-left: 20px;
  margin: 24px 0;
}
.story-body p { margin-bottom: 16px; font-size: 16px; line-height: 1.8; }

/* ---------- TESTIMONIALS ---------- */
.testi-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 56px; }
.testi {
  background: var(--white); border: 1px solid var(--border);
  padding: 36px 32px; border-radius: 4px; position: relative;
}
.testi .stars { color: var(--brown); letter-spacing: 2px; margin-bottom: 16px; font-size: 14px; }
.testi .quote {
  font-family: 'Crimson Pro', serif; font-size: 20px; line-height: 1.45;
  color: var(--ink); margin-bottom: 24px; font-style: italic;
}
.testi .who { display: flex; align-items: center; gap: 12px; }
.testi .avatar {
  width: 40px; height: 40px; border-radius: 999px;
  background: var(--cream-deep); color: var(--brown);
  display: inline-flex; align-items: center; justify-content: center;
  font-family: 'Crimson Pro', serif; font-weight: 700;
}
.testi .who .nm { font-weight: 600; font-size: 14px; }
.testi .who .loc { font-size: 12px; opacity: 0.65; }

/* ---------- NEWSLETTER ---------- */
.newsletter {
  background: var(--brown); color: var(--cream);
  padding: 96px 0;
}
.newsletter h2 { color: var(--cream); font-size: 52px; max-width: 720px; }
.newsletter p { opacity: 0.85; margin: 20px 0 36px; max-width: 560px; font-size: 17px; }
.newsletter-form {
  display: flex; gap: 0; max-width: 520px;
  border-bottom: 1px solid rgba(253, 248, 244, 0.4);
  padding-bottom: 10px;
}
.newsletter-form input {
  flex: 1; background: transparent; border: none; outline: none;
  color: var(--cream); font-size: 16px; padding: 10px 0;
}
.newsletter-form input::placeholder { color: rgba(253, 248, 244, 0.6); }
.newsletter-form button {
  color: var(--cream); font-size: 13px; letter-spacing: 0.1em;
  text-transform: uppercase; font-weight: 600;
}

/* ---------- FOOTER ---------- */
.footer {
  background: var(--ink); color: var(--cream);
  padding: 80px 0 40px;
}
.footer-grid {
  display: grid; grid-template-columns: 1.3fr repeat(3, 1fr);
  gap: 48px; margin-bottom: 60px;
}
.footer h4 {
  font-family: 'Open Sans', sans-serif; color: var(--cream);
  font-size: 11px; letter-spacing: 0.24em; text-transform: uppercase;
  font-weight: 600; margin-bottom: 20px; opacity: 0.7;
}
.footer ul { list-style: none; }
.footer li { padding: 6px 0; font-size: 14px; opacity: 0.85; }
.footer li:hover { opacity: 1; cursor: pointer; }
.footer-logo {
  font-family: 'Crimson Pro', serif; font-size: 32px; color: var(--cream);
  margin-bottom: 16px; font-weight: 700;
}
.footer-tag { font-size: 14px; opacity: 0.7; max-width: 280px; line-height: 1.6; margin-bottom: 24px; }
.socials { display: flex; gap: 12px; }
.socials a {
  width: 40px; height: 40px; border-radius: 999px;
  border: 1px solid rgba(253, 248, 244, 0.2);
  display: inline-flex; align-items: center; justify-content: center;
  transition: border-color .2s, background .2s;
}
.socials a:hover { background: var(--cream); color: var(--ink); border-color: var(--cream); }
.footer-bottom {
  border-top: 1px solid rgba(253, 248, 244, 0.12);
  padding-top: 24px;
  display: flex; justify-content: space-between; align-items: center;
  font-size: 12px; opacity: 0.6;
}

/* ---------- SHOP ---------- */
.page-hero {
  padding: 160px 0 60px;
  border-bottom: 1px solid var(--border);
}
.page-hero h1 { font-size: 88px; letter-spacing: -0.02em; margin-bottom: 16px; }
.page-hero p { font-size: 18px; max-width: 600px; opacity: 0.8; }
.shop-layout { display: grid; grid-template-columns: 240px 1fr; gap: 56px; }
.filters h4 {
  font-size: 11px; letter-spacing: 0.24em; text-transform: uppercase;
  color: var(--brown); font-family: 'Open Sans', sans-serif;
  margin-bottom: 16px; padding-bottom: 10px; border-bottom: 1px solid var(--border);
}
.filter-group { margin-bottom: 40px; }
.filter-opt {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 0; cursor: pointer; font-size: 14px;
  color: var(--ink); transition: color .2s;
}
.filter-opt:hover { color: var(--brown); }
.filter-opt input { accent-color: var(--brown); }
.filter-opt.active { color: var(--brown); font-weight: 600; }
.sort-bar {
  display: flex; justify-content: space-between; align-items: center;
  padding-bottom: 20px; margin-bottom: 24px;
  border-bottom: 1px solid var(--border);
}
.sort-bar .count { font-size: 14px; opacity: 0.7; }
.sort-bar select {
  background: transparent; border: 1px solid var(--border);
  padding: 8px 14px; border-radius: 999px; font-size: 13px;
  color: var(--ink); cursor: pointer;
}

/* ---------- PRODUCT DETAIL ---------- */
.pd-layout {
  padding-top: 130px;
  display: grid; grid-template-columns: 1.1fr 1fr;
  gap: 80px; min-height: 100vh;
}
.pd-img-wrap {
  background: var(--cream-deep);
  aspect-ratio: 3/4;
  position: relative; overflow: hidden;
  border-radius: 2px;
}
.pd-img-wrap canvas { position: absolute; inset: 0; }
.pd-img-wrap .pouch {
  position: absolute; inset: 10%;
  display: flex; align-items: center; justify-content: center;
  pointer-events: none; z-index: 2;
}
.pd-img-wrap .pouch img {
  max-height: 100%; filter: drop-shadow(0 30px 60px rgba(68, 55, 40, 0.2));
  transition: transform .6s cubic-bezier(.22,.61,.36,1);
}
.pd-details { padding: 40px 0; }
.pd-cat { font-size: 11px; letter-spacing: 0.3em; text-transform: uppercase; color: var(--brown); margin-bottom: 16px; }
.pd-name { font-size: 72px; line-height: 1; margin-bottom: 16px; letter-spacing: -0.02em; }
.pd-rating { display: flex; align-items: center; gap: 8px; margin-bottom: 24px; font-size: 14px; opacity: 0.75; }
.pd-rating .stars { color: var(--brown); letter-spacing: 2px; }
.pd-price {
  font-family: 'Crimson Pro', serif; font-size: 48px;
  color: var(--brown); font-weight: 700; margin-bottom: 24px;
}
.pd-desc { font-size: 16px; line-height: 1.75; margin-bottom: 32px; opacity: 0.88; }
.pd-props { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; margin-bottom: 36px; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.pd-prop { padding: 20px 16px; border-right: 1px solid var(--border); }
.pd-prop:last-child { border-right: none; }
.pd-prop .lbl { font-size: 10px; letter-spacing: 0.24em; text-transform: uppercase; color: var(--brown); margin-bottom: 6px; }
.pd-prop .val { font-family: 'Crimson Pro', serif; font-size: 22px; color: var(--ink); font-weight: 600; }
.pd-actions { display: flex; gap: 12px; align-items: center; margin-bottom: 32px; }
.qty {
  display: inline-flex; align-items: center; gap: 0;
  border: 1px solid var(--brown); border-radius: 999px; overflow: hidden;
}
.qty button {
  width: 44px; height: 46px; color: var(--brown);
  transition: background .2s;
}
.qty button:hover { background: var(--cream-deep); }
.qty .v { width: 44px; text-align: center; font-family: 'Crimson Pro', serif; font-size: 18px; font-weight: 600; }
.pd-nut { border-top: 1px solid var(--border); padding-top: 32px; }
.pd-nut h4 { font-family: 'Crimson Pro', serif; font-size: 22px; color: var(--brown); margin-bottom: 20px; }
.nut-row { display: grid; grid-template-columns: 1fr auto; padding: 10px 0; border-bottom: 1px dotted var(--border); font-size: 14px; }
.nut-row:last-child { border: none; }
.nut-row .k { opacity: 0.7; }

/* ---------- CART ---------- */
.cart-layout { display: grid; grid-template-columns: 1.5fr 1fr; gap: 64px; padding-top: 120px; }
.cart-item {
  display: grid; grid-template-columns: 100px 1fr auto auto; gap: 24px;
  align-items: center; padding: 24px 0; border-bottom: 1px solid var(--border);
}
.cart-item img { width: 100px; aspect-ratio: 2/3; object-fit: cover; border: 1px solid var(--border); background: var(--cream-deep); }
.cart-item .nm { font-family: 'Crimson Pro', serif; font-size: 22px; color: var(--ink); font-weight: 600; }
.cart-item .meta { font-size: 13px; opacity: 0.65; margin-top: 4px; }
.cart-summary {
  background: var(--cream-deep); padding: 40px 36px; border-radius: 4px;
  position: sticky; top: 120px; height: fit-content;
}
.cart-summary h3 { font-size: 28px; margin-bottom: 24px; color: var(--brown); }
.cart-summary .row { display: flex; justify-content: space-between; padding: 10px 0; font-size: 15px; }
.cart-summary .row.total { font-family: 'Crimson Pro', serif; font-size: 26px; font-weight: 700; color: var(--brown); padding-top: 20px; margin-top: 12px; border-top: 1px solid var(--border); }
.cart-summary .btn { width: 100%; margin-top: 24px; }

/* forms */
.field { margin-bottom: 20px; }
.field label { display: block; font-size: 11px; letter-spacing: 0.24em; text-transform: uppercase; color: var(--brown); margin-bottom: 8px; }
.field input, .field textarea, .field select {
  width: 100%; padding: 12px 14px; border: 1px solid var(--border);
  background: var(--white); border-radius: 2px; outline: none;
  font-size: 15px; transition: border-color .2s;
}
.field input:focus, .field textarea:focus, .field select:focus { border-color: var(--brown); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

/* checkout steps */
.steps { display: flex; gap: 0; margin-bottom: 48px; border-bottom: 1px solid var(--border); }
.step {
  padding: 18px 28px; font-size: 12px; letter-spacing: 0.2em;
  text-transform: uppercase; color: var(--ink); opacity: 0.5;
  border-bottom: 2px solid transparent; margin-bottom: -1px;
  display: flex; align-items: center; gap: 10px;
}
.step.active { opacity: 1; color: var(--brown); border-bottom-color: var(--brown); }
.step .n {
  width: 22px; height: 22px; border-radius: 999px;
  background: var(--cream-deep); color: var(--brown);
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 700;
}
.step.active .n { background: var(--brown); color: var(--cream); }

/* pay methods */
.pay-opt {
  display: flex; align-items: center; gap: 14px;
  padding: 16px 20px; border: 1px solid var(--border); border-radius: 2px;
  margin-bottom: 12px; cursor: pointer; transition: border-color .2s, background .2s;
}
.pay-opt:hover { border-color: var(--brown); }
.pay-opt.active { border-color: var(--brown); background: var(--cream-deep); }
.pay-opt input { accent-color: var(--brown); }
.pay-opt .logo {
  width: 48px; height: 32px; border-radius: 2px;
  background: var(--brown); color: var(--cream);
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 10px; font-weight: 700; letter-spacing: 0.08em;
}

/* ---------- ACCOUNT / AUTH ---------- */
.auth-layout { display: grid; grid-template-columns: 1fr 1fr; min-height: 100vh; padding-top: 80px; }
.auth-side {
  background: var(--brown); color: var(--cream);
  padding: 80px 64px; position: relative;
  display: flex; flex-direction: column; justify-content: space-between;
  overflow: hidden;
}
.auth-side h2 { color: var(--cream); font-size: 64px; line-height: 1.05; max-width: 440px; }
.auth-side p { opacity: 0.85; margin-top: 20px; max-width: 380px; }
.auth-side .deco {
  position: absolute; right: -80px; bottom: -80px;
  width: 320px; height: 320px; border-radius: 999px;
  background: rgba(253, 248, 244, 0.08);
}
.auth-form-wrap { padding: 80px 64px; display: flex; flex-direction: column; justify-content: center; max-width: 520px; }
.auth-toggle { display: flex; gap: 8px; margin-bottom: 32px; }
.auth-toggle button {
  padding: 10px 20px; border-radius: 999px; font-size: 13px;
  letter-spacing: 0.1em; text-transform: uppercase; font-weight: 600;
  color: var(--ink); opacity: 0.55;
}
.auth-toggle button.active { background: var(--cream-deep); color: var(--brown); opacity: 1; }

/* account dashboard */
.acc-layout { display: grid; grid-template-columns: 260px 1fr; gap: 48px; padding-top: 120px; }
.acc-side { border-right: 1px solid var(--border); padding-right: 32px; }
.acc-profile { display: flex; gap: 14px; align-items: center; margin-bottom: 36px; padding-bottom: 24px; border-bottom: 1px solid var(--border); }
.acc-profile .avatar { width: 52px; height: 52px; border-radius: 999px; background: var(--brown); color: var(--cream); display: inline-flex; align-items: center; justify-content: center; font-family: 'Crimson Pro', serif; font-size: 24px; font-weight: 700; }
.acc-profile .nm { font-family: 'Crimson Pro', serif; font-size: 20px; color: var(--ink); font-weight: 600; }
.acc-profile .em { font-size: 13px; opacity: 0.6; }
.acc-menu { list-style: none; }
.acc-menu li {
  padding: 12px 14px; margin: 2px 0;
  font-size: 14px; cursor: pointer;
  border-radius: 2px; transition: background .2s, color .2s;
  display: flex; align-items: center; gap: 12px;
}
.acc-menu li:hover { background: var(--cream-deep); color: var(--brown); }
.acc-menu li.active { background: var(--brown); color: var(--cream); }
.order-row {
  display: grid; grid-template-columns: 1fr 1fr 1fr 1fr auto;
  gap: 20px; padding: 20px 24px; border: 1px solid var(--border);
  border-radius: 2px; margin-bottom: 12px; align-items: center;
  background: var(--white); font-size: 14px;
  transition: border-color .2s;
}
.order-row:hover { border-color: var(--brown); }
.order-row .k { font-size: 10px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--brown); margin-bottom: 4px; }
.order-row .v { font-family: 'Crimson Pro', serif; font-size: 17px; color: var(--ink); font-weight: 600; }
.pill { display: inline-block; padding: 4px 10px; border-radius: 999px; font-size: 10px; letter-spacing: 0.16em; text-transform: uppercase; font-weight: 600; }
.pill.delivered { background: #E5EEDD; color: var(--accent-green); }
.pill.shipped { background: var(--cream-deep); color: var(--brown); }
.pill.processing { background: #F4E4D0; color: #8A5F30; }

/* ---------- BLOG ---------- */
.blog-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 36px; margin-top: 56px; }
.blog-card { cursor: pointer; transition: transform .3s; }
.blog-card:hover { transform: translateY(-4px); }
.blog-card .img {
  aspect-ratio: 4/3; margin-bottom: 20px;
  background: var(--cream-deep); border-radius: 4px;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Crimson Pro', serif; font-size: 72px;
  color: var(--brown); opacity: 1;
  position: relative; overflow: hidden;
}
.blog-card .img::before {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 40%, rgba(68, 55, 40, 0.15) 100%);
  z-index: 1;
}
.blog-card .tag { font-size: 10px; letter-spacing: 0.24em; text-transform: uppercase; color: var(--brown); margin-bottom: 8px; }
.blog-card h3 { font-size: 28px; line-height: 1.2; margin-bottom: 10px; color: var(--ink); }
.blog-card .meta { font-size: 13px; opacity: 0.6; }

/* ---------- ABOUT ---------- */
.about-hero {
  padding: 180px 0 120px;
  text-align: center;
}
.about-hero h1 { font-size: 120px; letter-spacing: -0.03em; line-height: 1; margin-bottom: 24px; }
.about-hero p { font-size: 20px; max-width: 680px; margin: 0 auto; opacity: 0.8; }
.vm-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; margin-top: 64px; border-top: 1px solid var(--border); }
.vm-cell { padding: 40px 32px 40px 0; border-bottom: 1px solid var(--border); border-right: 1px solid var(--border); }
.vm-cell:nth-child(3n) { border-right: none; }
.vm-cell:last-child { border-right: none; }
.vm-cell .n { font-family: 'Crimson Pro', serif; color: var(--brown); font-size: 12px; margin-bottom: 16px; }
.vm-cell h4 { font-size: 22px; color: var(--ink); margin-bottom: 10px; font-weight: 600; }
.vm-cell p { font-size: 14px; line-height: 1.65; opacity: 0.82; }
.vm-cell + .vm-cell { padding-left: 32px; }
.team-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; margin-top: 56px; }
.team-card .avatar { aspect-ratio: 4/5; background: var(--cream-deep); margin-bottom: 16px; border-radius: 2px; display: flex; align-items: center; justify-content: center; font-family: 'Crimson Pro', serif; font-size: 72px; color: var(--brown); opacity: 0.4; }
.team-card .nm { font-family: 'Crimson Pro', serif; font-size: 22px; font-weight: 600; color: var(--ink); }
.team-card .role { font-size: 13px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--brown); margin-top: 4px; }

/* ---------- CONTACT ---------- */
.contact-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; padding-top: 120px; }
.contact-info h2 { font-size: 72px; letter-spacing: -0.02em; line-height: 1.05; margin-bottom: 24px; }
.contact-block { padding: 28px 0; border-bottom: 1px solid var(--border); }
.contact-block .k { font-size: 11px; letter-spacing: 0.24em; text-transform: uppercase; color: var(--brown); margin-bottom: 8px; }
.contact-block .v { font-family: 'Crimson Pro', serif; font-size: 24px; color: var(--ink); font-weight: 600; }
.wa-link {
  display: inline-flex; align-items: center; gap: 12px;
  padding: 14px 24px; background: var(--accent-green); color: var(--cream);
  border-radius: 999px; font-size: 13px; letter-spacing: 0.1em;
  text-transform: uppercase; font-weight: 600;
  transition: transform .15s;
}
.wa-link:hover { transform: translateY(-1px); }

/* ---------- ADMIN ---------- */
.admin-shell { display: grid; grid-template-columns: 240px 1fr; min-height: 100vh; background: var(--cream); }
.admin-side {
  background: var(--ink); color: var(--cream);
  padding: 32px 20px;
  position: sticky; top: 0; height: 100vh; overflow-y: auto;
}
.admin-logo { font-family: 'Crimson Pro', serif; font-size: 24px; color: var(--cream); margin-bottom: 40px; display: flex; align-items: center; gap: 8px; }
.admin-logo .dot { width: 8px; height: 8px; border-radius: 999px; background: var(--accent-green); }
.admin-menu { list-style: none; }
.admin-menu li { padding: 10px 14px; margin: 2px 0; border-radius: 2px; font-size: 13px; cursor: pointer; opacity: 0.75; transition: background .15s, opacity .15s; display: flex; align-items: center; gap: 12px; }
.admin-menu li:hover { opacity: 1; background: rgba(253, 248, 244, 0.06); }
.admin-menu li.active { background: var(--brown); opacity: 1; }
.admin-menu .sec { font-size: 10px; letter-spacing: 0.2em; text-transform: uppercase; opacity: 0.4; margin: 24px 14px 8px; }
.admin-main { padding: 32px 48px; overflow-y: auto; }
.admin-topbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 40px; }
.admin-topbar h1 { font-size: 44px; }
.admin-search { padding: 10px 18px; border: 1px solid var(--border); background: var(--white); border-radius: 999px; font-size: 13px; width: 320px; }
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-bottom: 32px; }
.stat-card { background: var(--white); border: 1px solid var(--border); padding: 24px; border-radius: 2px; }
.stat-card .lbl { font-size: 11px; letter-spacing: 0.24em; text-transform: uppercase; color: var(--brown); margin-bottom: 12px; }
.stat-card .val { font-family: 'Crimson Pro', serif; font-size: 40px; font-weight: 700; color: var(--ink); line-height: 1; }
.stat-card .delta { font-size: 12px; margin-top: 8px; color: var(--accent-green); }
.stat-card .delta.down { color: #b05a4a; }
.admin-panel { background: var(--white); border: 1px solid var(--border); border-radius: 2px; padding: 28px 32px; margin-bottom: 24px; }
.admin-panel h3 { font-size: 24px; margin-bottom: 20px; }
.chart-bars { display: grid; grid-template-columns: repeat(12, 1fr); gap: 8px; height: 220px; align-items: end; margin: 24px 0; }
.chart-bars .b {
  background: var(--brown); border-radius: 2px 2px 0 0;
  transition: background .2s; position: relative;
}
.chart-bars .b:hover { background: var(--brown-deep); }
.chart-bars .b.muted { background: var(--cream-warm); }
.chart-labels { display: grid; grid-template-columns: repeat(12, 1fr); gap: 8px; margin-top: 8px; font-size: 10px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink); opacity: 0.5; text-align: center; }
.admin-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.admin-table th { text-align: left; font-family: 'Open Sans', sans-serif; font-size: 10px; letter-spacing: 0.24em; text-transform: uppercase; color: var(--brown); padding: 12px 16px; border-bottom: 1px solid var(--border); font-weight: 600; }
.admin-table td { padding: 16px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.admin-table tr:hover td { background: var(--cream-deep); }
.admin-table .prod-cell { display: flex; align-items: center; gap: 12px; }
.admin-table .prod-cell img { width: 40px; height: 56px; object-fit: cover; border: 1px solid var(--border); }
.admin-table .prod-cell .nm { font-family: 'Crimson Pro', serif; font-size: 16px; font-weight: 600; color: var(--ink); }
.admin-table .prod-cell .c { font-size: 11px; opacity: 0.6; }
.admin-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }

/* ---------- LOADER ---------- */
.loader {
  position: fixed; inset: 0; z-index: 999;
  background: var(--cream);
  display: flex; align-items: center; justify-content: center;
  flex-direction: column;
  transition: opacity .6s, visibility .6s;
}
.loader.hidden { opacity: 0; visibility: hidden; }
.loader .mark {
  font-family: 'Crimson Pro', serif; font-size: 48px;
  color: var(--ink); letter-spacing: -0.02em;
  font-weight: 700;
  position: relative;
}
.loader .mark::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: -6px;
  height: 2px; background: var(--brown);
  animation: loader-line 1.6s cubic-bezier(.55,0,.3,1) infinite;
  transform-origin: left;
}
@keyframes loader-line {
  0% { transform: scaleX(0); transform-origin: left; }
  45% { transform: scaleX(1); transform-origin: left; }
  55% { transform: scaleX(1); transform-origin: right; }
  100% { transform: scaleX(0); transform-origin: right; }
}
.loader .leaf { position: absolute; top: -24px; right: -10px; color: var(--accent-green); font-size: 18px; }
.loader .tag {
  font-size: 11px; letter-spacing: 0.32em; text-transform: uppercase;
  color: var(--brown); margin-top: 28px;
}

/* ---------- PAGE ENTER ---------- */
.page-enter { animation: pageFade .5s cubic-bezier(.22,.61,.36,1); }
@keyframes pageFade {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: none; }
}

/* fade-up on scroll */
.fade-up { opacity: 0; transform: translateY(24px); transition: opacity .8s, transform .8s; }
.fade-up.in { opacity: 1; transform: none; }

/* recipe of the week */
.rotw {
  display: grid; grid-template-columns: 1fr 1fr; gap: 60px;
  background: var(--cream-deep); padding: 80px;
  border-radius: 4px; align-items: center;
  margin-top: 60px;
}
.rotw-img {
  aspect-ratio: 4/5; background: linear-gradient(135deg, var(--cream-warm), #ddc9b5);
  position: relative; overflow: hidden; border-radius: 2px;
  display: flex; align-items: center; justify-content: center;
}
.rotw-img .placeholder {
  font-family: 'Crimson Pro', serif; font-size: 96px;
  color: var(--brown); opacity: 0.3; font-style: italic;
}
.rotw-body .ey { font-size: 11px; letter-spacing: 0.32em; text-transform: uppercase; color: var(--brown); margin-bottom: 16px; }
.rotw-body h3 { font-size: 48px; line-height: 1.05; margin-bottom: 20px; }
.rotw-body p { font-size: 16px; line-height: 1.7; margin-bottom: 24px; opacity: 0.85; }
.rotw-ingredients { font-size: 13px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--brown); margin-bottom: 20px; }
.rotw-ingredients span { margin-right: 16px; }

/* page route fade */
.route { min-height: 100vh; }




/* ---------- ADMIN MODAL ---------- */
.admin-modal-bg {
  position: fixed; inset: 0; z-index: 100;
  background: rgba(42, 28, 22, 0.58);
  backdrop-filter: blur(6px);
  display: flex; align-items: flex-start; justify-content: center;
  padding: 40px 20px;
  overflow-y: auto;
  animation: modalFade 0.25s ease-out;
}
@keyframes modalFade { from { opacity: 0; } to { opacity: 1; } }
.admin-modal {
  background: var(--cream);
  width: 100%; max-width: 880px;
  border-radius: 4px;
  box-shadow: 0 30px 80px -20px rgba(42, 28, 22, 0.5);
  animation: modalSlide 0.3s cubic-bezier(.2,.8,.2,1);
  overflow: hidden;
}
@keyframes modalSlide { from { transform: translateY(20px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
.admin-modal-head {
  padding: 28px 36px; border-bottom: 1px solid var(--border);
  display: flex; justify-content: space-between; align-items: flex-start;
  background: var(--white);
}
.admin-modal-close {
  width: 36px; height: 36px; border-radius: 999px;
  background: var(--cream-deep); color: var(--brown);
  font-size: 14px; display: inline-flex; align-items: center; justify-content: center;
  transition: background 0.2s, color 0.2s;
}
.admin-modal-close:hover { background: var(--brown); color: var(--cream); }
.admin-modal-body {
  padding: 32px 36px; max-height: 70vh; overflow-y: auto;
}
.admin-modal-foot {
  padding: 20px 36px; border-top: 1px solid var(--border);
  display: flex; justify-content: flex-end; gap: 10px;
  background: var(--white);
}

.img-upload {
  display: grid; grid-template-columns: 220px 1fr; gap: 28px;
  margin-bottom: 28px; padding-bottom: 28px;
  border-bottom: 1px solid var(--border);
}
.img-preview {
  aspect-ratio: 3 / 4;
  background: var(--cream-deep);
  border: 1px solid var(--border);
  overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  position: relative;
}
.img-preview img {
  width: 100%; height: 100%; object-fit: cover;
}
.img-actions { display: flex; flex-direction: column; justify-content: center; }
.img-actions input[type="text"], .img-actions input:not([type]) {
  padding: 10px 14px; font-size: 13px;
  background: var(--white); border: 1px solid var(--border);
  font-family: inherit;
}

.modal-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 12px 16px;
}
.modal-grid .field:nth-child(3),
.modal-grid .field:nth-child(4),
.modal-grid .field:nth-child(5),
.modal-grid .field:nth-child(6),
.modal-grid .field:nth-child(7),
.modal-grid .field:nth-child(8) {
  grid-column: span 1;
}
.admin-modal-body .field { margin-bottom: 4px; }
.admin-modal-body .field label {
  display: block; font-size: 10px; letter-spacing: 0.2em;
  text-transform: uppercase; color: var(--brown);
  margin-bottom: 6px; font-weight: 600;
}
.admin-modal-body .field input,
.admin-modal-body .field select,
.admin-modal-body .field textarea,
.admin-modal-body input:not([type="file"]):not([type="radio"]):not([type="checkbox"]) {
  width: 100%; padding: 10px 14px;
  background: var(--white); border: 1px solid var(--border);
  font-size: 14px; font-family: inherit;
  transition: border-color 0.2s;
}
.admin-modal-body .field input:focus,
.admin-modal-body .field select:focus,
.admin-modal-body .field textarea:focus,
.admin-modal-body input:focus {
  outline: none; border-color: var(--brown);
}
.admin-modal-body .field input:disabled {
  background: var(--cream-deep); color: var(--ink); opacity: 0.6; cursor: not-allowed;
}
.admin-modal-body textarea { resize: vertical; min-height: 80px; }

.admin-toast {
  position: fixed; bottom: 32px; left: 50%;
  transform: translateX(-50%);
  background: var(--ink); color: var(--cream);
  padding: 14px 26px; border-radius: 999px;
  font-size: 13px; letter-spacing: 0.1em; text-transform: uppercase;
  font-weight: 600;
  box-shadow: 0 20px 50px -10px rgba(42, 28, 22, 0.4);
  z-index: 200;
  animation: toastIn 0.3s cubic-bezier(.2,.8,.2,1);
}
@keyframes toastIn {
  from { transform: translate(-50%, 20px); opacity: 0; }
  to { transform: translate(-50%, 0); opacity: 1; }
}

@media (max-width: 720px) {
  .img-upload { grid-template-columns: 1fr; }
  .modal-grid { grid-template-columns: 1fr; }
}

/* ========== RESPONSIVE / MOBILE ========== */

/* NAV burger + drawer — hidden on desktop */
.nav-burger { display: none; }
.nav-drawer { display: none; }
.nav-cart .nav-cart-label { display: inline; }

/* Tablet ≤ 1100px */
@media (max-width: 1100px) {
  .container, .container-wide { padding: 0 32px; }
  section { padding: 80px 0; }
  .hero { grid-template-columns: 1fr; padding: 120px 32px 80px; min-height: auto; }
  .hero-title { font-size: 64px; }
  .hero-sub { font-size: 17px; }
  .section-title { font-size: 44px; }
  .product-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 40px; }
  .shop-layout { grid-template-columns: 1fr; gap: 32px; }
  .filters { position: static; max-width: none; }
  .admin-shell { grid-template-columns: 1fr; }
  .admin-side { position: static; height: auto; border-right: none; border-bottom: 1px solid var(--border); }
  .story-grid, .rotw, .contact-layout, .about-hero h1 { }
  .story-grid { grid-template-columns: 1fr; gap: 40px; }
  .story-body h2 { font-size: 40px !important; }
  .rotw { grid-template-columns: 1fr; gap: 32px; }
  .rotw-img { min-height: 380px; }
  .contact-layout { grid-template-columns: 1fr; gap: 40px; }
  .cart-layout { grid-template-columns: 1fr; gap: 40px; }
  .cart-summary { position: static; }
  .acc-layout { grid-template-columns: 1fr; gap: 32px; }
  .acc-side { position: static; }
  .pd-layout { grid-template-columns: 1fr; gap: 48px; padding-top: 100px; }
  .pd-img-wrap { position: static; height: auto; aspect-ratio: 1; }
  .auth-layout { grid-template-columns: 1fr; }
  .auth-side { min-height: 260px; padding: 48px 32px; }
  .auth-form-wrap { padding: 48px 32px; }
  .why-grid, .vm-grid { grid-template-columns: repeat(2, 1fr); }
  .team-grid { grid-template-columns: repeat(2, 1fr); }
  .testi-grid { grid-template-columns: 1fr 1fr; }
  .blog-grid { grid-template-columns: 1fr 1fr; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .admin-grid-2 { grid-template-columns: 1fr; gap: 20px; }
}

/* Phone ≤ 720px — MOBILE-FIRST priority */
@media (max-width: 720px) {
  body { font-size: 15px; }
  .container, .container-wide { padding: 0 20px; }
  section { padding: 60px 0; }

  /* NAV — hamburger layout */
  .nav {
    grid-template-columns: auto 1fr auto;
    padding: 14px 20px;
    gap: 16px;
  }
  .nav.scrolled { padding: 10px 20px; }
  .nav-left, .nav-right { display: none; }
  .nav-burger {
    display: flex; flex-direction: column; gap: 5px; justify-content: center;
    width: 32px; height: 32px; padding: 6px 4px;
    justify-self: start;
  }
  .nav-burger span {
    width: 100%; height: 1.5px; background: var(--ink); display: block;
    transition: transform .2s;
  }
  .nav-logo-link { justify-self: center; }
  .nav-logo .logo-img { height: 32px !important; }
  .nav-logo .tag { display: none; }
  .nav-cart {
    justify-self: end;
    padding: 8px 10px;
    font-size: 12px;
    display: inline-flex;
  }
  .nav-cart .nav-cart-label { display: none; }
  .cart-count { position: absolute; top: -6px; right: -6px; }

  /* DRAWER */
  .nav-drawer {
    display: block;
    position: fixed; inset: 0; z-index: 200;
    background: rgba(42, 28, 22, 0); backdrop-filter: blur(0px);
    pointer-events: none;
    transition: background .3s;
  }
  .nav-drawer.open {
    background: rgba(42, 28, 22, 0.5);
    backdrop-filter: blur(8px);
    pointer-events: auto;
  }
  .nav-drawer aside {
    position: absolute; top: 0; left: 0; bottom: 0;
    width: 84%; max-width: 340px;
    background: var(--cream);
    transform: translateX(-100%);
    transition: transform .35s cubic-bezier(.2,.8,.2,1);
    display: flex; flex-direction: column;
    overflow-y: auto;
  }
  .nav-drawer.open aside { transform: translateX(0); }
  .nav-drawer-head {
    display: flex; align-items: center; justify-content: space-between;
    padding: 20px 24px; border-bottom: 1px solid var(--border);
  }
  .nav-drawer-head button {
    width: 36px; height: 36px; border-radius: 999px;
    background: var(--cream-deep); color: var(--brown);
    font-size: 15px;
  }
  .nav-drawer-menu { list-style: none; padding: 24px 0; flex: 1; }
  .nav-drawer-menu li a {
    display: block; padding: 14px 28px;
    font-family: 'Crimson Pro', serif;
    font-size: 24px; color: var(--ink);
    border-left: 2px solid transparent;
  }
  .nav-drawer-menu li a.active {
    color: var(--brown);
    border-left-color: var(--brown);
    background: var(--cream-deep);
  }
  .nav-drawer-menu li.divider {
    height: 1px; background: var(--border); margin: 16px 28px;
  }
  .nav-drawer-foot {
    padding: 24px 28px; border-top: 1px solid var(--border);
    font-family: 'Crimson Pro', serif; font-style: italic;
    color: var(--brown); font-size: 15px;
  }

  /* HERO */
  .hero {
    padding: 100px 20px 60px;
    min-height: auto;
  }
  .hero-title { font-size: 44px; letter-spacing: -0.01em; }
  .hero-sub { font-size: 16px; line-height: 1.6; margin-bottom: 28px; }
  .hero-ctas { flex-direction: column; align-items: stretch; }
  .hero-ctas .btn { width: 100%; justify-content: center; }
  .hero-eyebrow { font-size: 10px; letter-spacing: 0.24em; margin-bottom: 20px; }

  /* SECTIONS */
  .section-title { font-size: 32px; letter-spacing: -0.01em; }
  .section-sub { font-size: 16px; }
  .section-eyebrow { font-size: 10px; letter-spacing: 0.24em; }

  /* TICKER */
  .ticker { padding: 16px 0; }
  .ticker-item { font-size: 16px; }

  /* PRODUCT GRID */
  .product-grid, .product-grid.cols-3 { grid-template-columns: 1fr; gap: 24px; }
  .product-card { }
  .product-card .img { aspect-ratio: 4/5; }
  .product-card .price { font-size: 20px; }

  /* FEATURES */
  .why-grid, .vm-grid { grid-template-columns: 1fr; gap: 32px; }

  /* STORY */
  .story-grid { grid-template-columns: 1fr; gap: 32px; }
  .story-body h2 { font-size: 32px !important; }
  .story-img { aspect-ratio: 4/5; }
  .story-pouch { width: 70%; }
  .story-quote { font-size: 20px; padding: 16px 0; }

  /* RECIPE */
  .rotw { grid-template-columns: 1fr; gap: 24px; }
  .rotw-img { min-height: 320px; aspect-ratio: 4/5; }
  .rotw-body h3 { font-size: 28px; }

  /* TESTIMONIALS */
  .testi-grid { grid-template-columns: 1fr; gap: 20px; }

  /* TEAM */
  .team-grid { grid-template-columns: 1fr 1fr; gap: 24px; }

  /* BLOG */
  .blog-grid { grid-template-columns: 1fr; gap: 28px; }
  .blog-card .img { aspect-ratio: 16/10; }

  /* NEWSLETTER */
  .newsletter h2 { font-size: 32px; }
  .newsletter p { font-size: 15px; }
  .newsletter-form { flex-direction: column; align-items: stretch; gap: 12px; }
  .newsletter-form input { text-align: center; }
  .newsletter-form button { width: 100%; justify-content: center; }

  /* FOOTER */
  .footer { padding: 60px 0 32px; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .footer-bottom {
    flex-direction: column; gap: 8px; text-align: center; font-size: 11px;
  }

  /* PAGE HEROES (shop, blog, about) */
  .page-hero { padding: 100px 0 40px; }
  .page-hero h1 { font-size: 44px !important; }
  .page-hero p { font-size: 16px; }

  /* SHOP */
  .shop-layout { grid-template-columns: 1fr; gap: 24px; }
  .filters {
    position: static; padding: 20px; background: var(--cream-deep); border-radius: 2px;
  }
  .filter-group { margin-bottom: 20px; }
  .sort-bar {
    flex-direction: column; gap: 12px; align-items: stretch;
  }
  .sort-bar select { width: 100%; }

  /* PRODUCT DETAIL */
  .pd-layout { grid-template-columns: 1fr; gap: 32px; padding-top: 90px; }
  .pd-img-wrap { position: static; height: auto; aspect-ratio: 1; }
  .pouch { width: 60% !important; }
  .pd-name { font-size: 38px !important; }
  .pd-price { font-size: 28px; }
  .pd-desc { font-size: 15px; }
  .pd-props { grid-template-columns: 1fr; }
  .pd-actions { flex-direction: column; align-items: stretch; gap: 12px; }
  .pd-actions .qty { align-self: flex-start; }

  /* CART */
  .cart-layout { grid-template-columns: 1fr; gap: 24px; }
  .cart-summary { position: static; }
  .cart-item {
    grid-template-columns: 80px 1fr;
    grid-template-areas:
      "img info"
      "qty price";
    gap: 16px; padding: 20px 0;
  }
  .cart-item img { grid-area: img; width: 80px !important; height: 100px !important; }
  .cart-item > div:nth-child(2) { grid-area: info; }
  .cart-item .qty { grid-area: qty; justify-self: start; }
  .cart-item > div:last-child { grid-area: price; justify-self: end; align-self: center; }

  /* CHECKOUT */
  .steps { gap: 8px; overflow-x: auto; }
  .step { font-size: 11px; padding: 10px 16px; white-space: nowrap; }
  .step .n { width: 22px; height: 22px; font-size: 11px; }
  .field-row { grid-template-columns: 1fr; gap: 0; }

  /* AUTH */
  .auth-layout { grid-template-columns: 1fr; min-height: auto; }
  .auth-side {
    min-height: 200px; padding: 80px 24px 32px;
  }
  .auth-side h2 { font-size: 28px !important; margin-top: 28px !important; }
  .auth-side p { font-size: 14px; }
  .auth-side .deco { display: none; }
  .auth-form-wrap { padding: 32px 24px; }

  /* ACCOUNT */
  .acc-layout { grid-template-columns: 1fr; gap: 24px; padding-top: 100px; }
  .acc-side { position: static; padding: 24px; background: var(--cream-deep); border-radius: 2px; }
  .acc-menu li { padding: 12px 0; font-size: 14px; }
  .acc-profile { padding-bottom: 20px; }
  .order-row {
    grid-template-columns: 1fr 1fr;
    gap: 8px 12px;
    padding: 20px 0;
  }
  .order-row > div { font-size: 13px; }
  .order-row > span.pill { grid-column: span 2; justify-self: start; }

  /* ABOUT */
  .about-hero h1 { font-size: 52px !important; }

  /* CONTACT */
  .contact-layout { grid-template-columns: 1fr; gap: 32px; }
  .contact-info h2 { font-size: 32px; }
  .contact-layout form { padding: 28px 24px !important; }

  /* ADMIN */
  .admin-shell { grid-template-columns: 1fr; }
  .admin-side {
    position: static; width: 100%; height: auto;
    border-right: none; border-bottom: 1px solid var(--border);
    padding: 20px;
  }
  .admin-menu { margin-bottom: 10px; }
  .admin-main { padding: 20px; }
  .admin-topbar {
    flex-direction: column; gap: 16px; align-items: stretch;
  }
  .admin-topbar h1 { font-size: 32px; }
  .admin-search { width: 100% !important; }
  .stat-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .stat-card { padding: 20px; }
  .stat-card .val { font-size: 32px; }
  .admin-grid-2 { grid-template-columns: 1fr; }
  .admin-panel { padding: 24px 20px; }
  .admin-panel h3 { font-size: 18px; }
  /* Admin tables — turn rows into cards */
  .admin-table { display: block; }
  .admin-table thead { display: none; }
  .admin-table tbody, .admin-table tr { display: block; }
  .admin-table tr {
    padding: 16px;
    background: var(--cream);
    margin-bottom: 12px;
    border: 1px solid var(--border);
    border-radius: 2px;
  }
  .admin-table td {
    display: flex; justify-content: space-between; align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid var(--border);
    font-size: 13px;
  }
  .admin-table td:last-child { border-bottom: none; }
  .admin-table td::before {
    content: attr(data-label);
    font-size: 10px; letter-spacing: 0.2em; text-transform: uppercase;
    color: var(--brown); font-weight: 600;
  }
  .admin-table .prod-cell { justify-content: flex-end; gap: 12px; }
  .chart-bars { gap: 4px; }

  /* ADMIN MODAL */
  .admin-modal-bg { padding: 0; align-items: stretch; }
  .admin-modal {
    max-width: 100%; min-height: 100vh; border-radius: 0;
  }
  .admin-modal-head, .admin-modal-foot { padding: 20px 24px; }
  .admin-modal-body { padding: 24px 20px; max-height: none; }
  .img-upload { grid-template-columns: 1fr; gap: 20px; }
  .img-preview { max-width: 220px; margin: 0 auto; }
  .modal-grid { grid-template-columns: 1fr; }

  /* Buttons - larger tap targets */
  .btn { padding: 14px 24px; min-height: 48px; }
  .btn-sm { padding: 10px 18px; min-height: 40px; font-size: 11px; }

  /* Loader */
  .loader img { height: 56px !important; }

  /* Reduce breadcrumb density */
  .pd-layout .pd-details > div:first-child { font-size: 11px !important; }
}

/* Very small ≤ 400px */
@media (max-width: 400px) {
  .hero-title { font-size: 36px; }
  .section-title { font-size: 26px; }
  .pd-name { font-size: 30px !important; }
  .page-hero h1 { font-size: 36px !important; }
  .nav-logo .logo-img { height: 28px !important; }
  .team-grid { grid-template-columns: 1fr; }
}

/* Tap highlight */
@media (hover: none) {
  .product-card:hover { transform: none; }
  .btn-primary:hover { transform: none; }
}


/* ---------- ADMIN MEDIA ---------- */
.media-intro {
  background: var(--white);
  border: 1px solid var(--border);
  padding: 28px 32px;
  margin-bottom: 24px;
  display: flex; justify-content: space-between; align-items: flex-start;
  gap: 24px;
}
.media-panel { margin-bottom: 24px; }
.media-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 20px;
}
.media-card {
  background: var(--cream);
  border: 1px solid var(--border);
  border-radius: 2px;
  overflow: hidden;
  transition: box-shadow 0.2s, transform 0.2s;
}
.media-card:hover { box-shadow: 0 8px 24px -12px rgba(42,28,22,0.18); transform: translateY(-2px); }
.media-thumb {
  position: relative;
  background: var(--cream-deep);
  overflow: hidden;
}
.media-thumb img {
  width: 100%; height: 100%; object-fit: cover;
}
.media-empty {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Crimson Pro', serif; font-style: italic;
  font-size: 14px; opacity: 0.5;
}
.media-badge {
  position: absolute; top: 10px; left: 10px;
  background: var(--brown); color: var(--cream);
  font-size: 9px; letter-spacing: 0.2em; text-transform: uppercase;
  padding: 4px 10px; border-radius: 999px; font-weight: 600;
}
.media-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 50%, rgba(42,28,22,0.72) 100%);
  display: flex; align-items: flex-end; justify-content: center;
  gap: 8px; padding: 14px;
  opacity: 0; transition: opacity 0.2s;
}
.media-card:hover .media-overlay,
.media-card:focus-within .media-overlay { opacity: 1; }
.media-icon-btn {
  width: 34px; height: 34px;
  border-radius: 999px;
  background: var(--cream);
  color: var(--brown);
  display: inline-flex; align-items: center; justify-content: center;
  transition: background 0.2s, color 0.2s, transform 0.15s;
  box-shadow: 0 4px 12px -4px rgba(0,0,0,0.25);
}
.media-icon-btn:hover { background: var(--brown); color: var(--cream); transform: scale(1.06); }
.media-icon-btn.danger:hover { background: #b05a4a; color: var(--cream); }
.media-meta {
  padding: 14px 16px;
}
.media-label {
  font-family: 'Crimson Pro', serif;
  font-size: 16px; font-weight: 600; color: var(--ink);
  line-height: 1.3;
}
.media-sub {
  font-size: 11px; letter-spacing: 0.06em;
  color: var(--brown); opacity: 0.75;
  margin-top: 4px;
}

@media (max-width: 720px) {
  .media-intro { flex-direction: column; padding: 20px; }
  .media-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; }
  .media-meta { padding: 10px 12px; }
  .media-label { font-size: 14px; }
  .media-overlay { opacity: 1; background: linear-gradient(180deg, transparent 40%, rgba(42,28,22,0.78) 100%); }
}

/* ---------- AI CHATBOT ---------- */
.chat-fab {
  position: fixed; bottom: 28px; right: 28px; z-index: 90;
  width: 56px; height: 56px; border-radius: 999px;
  background: var(--brown); color: var(--cream);
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 8px 24px -8px rgba(68, 55, 40, 0.4);
  transition: transform .2s, box-shadow .2s;
  cursor: pointer; border: none;
}
.chat-fab:hover { transform: scale(1.08); box-shadow: 0 12px 32px -8px rgba(68, 55, 40, 0.5); }

.chat-panel {
  position: fixed; bottom: 28px; right: 28px; z-index: 100;
  width: 400px; max-height: 600px; height: 70vh;
  background: var(--cream);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: 0 20px 60px -15px rgba(42, 28, 22, 0.35);
  display: flex; flex-direction: column;
  overflow: hidden;
  animation: chatSlideUp .3s cubic-bezier(.22,.61,.36,1);
}
@keyframes chatSlideUp {
  from { opacity: 0; transform: translateY(20px) scale(0.95); }
  to { opacity: 1; transform: none; }
}

.chat-header {
  padding: 18px 20px;
  background: var(--brown); color: var(--cream);
  display: flex; justify-content: space-between; align-items: center;
  flex-shrink: 0;
}
.chat-header-title {
  font-family: 'Crimson Pro', serif; font-size: 20px; font-weight: 700;
}
.chat-header-sub { font-size: 11px; opacity: 0.75; margin-top: 2px; }
.chat-close {
  width: 32px; height: 32px; border-radius: 999px;
  background: rgba(253,248,244,0.15); color: var(--cream);
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; border: none; cursor: pointer;
  transition: background .2s;
}
.chat-close:hover { background: rgba(253,248,244,0.3); }

.chat-messages {
  flex: 1; overflow-y: auto; padding: 16px;
  display: flex; flex-direction: column; gap: 12px;
}

.chat-msg {
  display: flex; gap: 10px; align-items: flex-end;
}
.chat-msg-user { flex-direction: row-reverse; }

.chat-avatar {
  width: 30px; height: 30px; border-radius: 999px;
  background: var(--brown); color: var(--cream);
  display: flex; align-items: center; justify-content: center;
  font-family: 'Crimson Pro', serif; font-size: 12px; font-weight: 700;
  flex-shrink: 0;
}
.chat-avatar-user { background: var(--cream-deep); color: var(--brown); }

.chat-bubble {
  max-width: 80%; padding: 12px 16px;
  border-radius: 14px 14px 14px 4px;
  background: var(--white); border: 1px solid var(--border);
  font-size: 14px; line-height: 1.55;
}
.chat-msg-user .chat-bubble {
  background: var(--brown); color: var(--cream);
  border-color: var(--brown);
  border-radius: 14px 14px 4px 14px;
}

.chat-typing {
  display: flex; gap: 4px; padding: 14px 20px;
}
.chat-typing span {
  width: 7px; height: 7px; border-radius: 999px;
  background: var(--brown); opacity: 0.4;
  animation: chatDot 1.2s infinite;
}
.chat-typing span:nth-child(2) { animation-delay: 0.2s; }
.chat-typing span:nth-child(3) { animation-delay: 0.4s; }
@keyframes chatDot {
  0%, 60%, 100% { opacity: 0.3; transform: scale(0.8); }
  30% { opacity: 1; transform: scale(1); }
}

.chat-cart-action {
  margin-top: 12px; padding-top: 12px;
  border-top: 1px solid var(--border);
}
.chat-cart-item {
  display: flex; justify-content: space-between;
  padding: 6px 0; font-size: 13px;
  border-bottom: 1px dotted var(--border);
}
.chat-cart-item:last-of-type { border-bottom: none; margin-bottom: 4px; }

.chat-input-bar {
  display: flex; gap: 0; padding: 12px 14px;
  border-top: 1px solid var(--border);
  background: var(--white);
  flex-shrink: 0;
}
.chat-input-bar input {
  flex: 1; border: 1px solid var(--border); border-right: none;
  padding: 10px 14px; border-radius: 999px 0 0 999px;
  font-size: 14px; outline: none; background: var(--cream);
}
.chat-input-bar input:focus { border-color: var(--brown); }
.chat-input-bar button {
  padding: 10px 16px; border-radius: 0 999px 999px 0;
  background: var(--brown); color: var(--cream);
  border: 1px solid var(--brown);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: background .2s;
}
.chat-input-bar button:hover { background: var(--brown-deep); }
.chat-input-bar button:disabled { opacity: 0.5; cursor: not-allowed; }

@media (max-width: 720px) {
  .chat-panel {
    bottom: 0; right: 0; left: 0;
    width: 100%; max-height: 100vh; height: 100vh;
    border-radius: 0;
  }
  .chat-fab { bottom: 20px; right: 20px; }
}
