/* Food directory pages: real ingredient and finished-food imagery on a warm, clean canvas. */
body.chem-food {
  --food-paper: #fbf6f1;
  --food-surface: #fffdfa;
  --food-soft: #f2e7dc;
  --food-ink: #201b17;
  --food-muted: #746d67;
  --food-line: rgba(46, 35, 27, .1);
  --food-accent: #9a5544;
  background: var(--food-paper);
  color: var(--food-ink);
}

body.chem-food .dir { background: var(--food-paper); color: var(--food-ink); }
body.chem-food .dir-wrap { width: min(var(--cdb-page-max), calc(100% - var(--cdb-page-gutter))); padding-top: 2rem; padding-bottom: 2rem; }
body.chem-food .dir-crumb { align-items: center; gap: .65rem; margin-bottom: 1.5rem; color: var(--food-muted); }
body.chem-food .dir-crumb a { text-decoration: none; }
body.chem-food .dir-kicker { color: var(--food-accent); }
body.chem-food .dir-lede,
body.chem-food .dir-copy { color: var(--food-muted); }
body.chem-food .dir h1 { color: var(--food-ink); }
body.chem-food .dir h1 em { color: var(--food-accent); }
body.chem-food .dir-block { margin-top: 2.5rem; }
body.chem-food .dir-block > h2 { margin-bottom: 1rem; font-family: var(--sans); font-size: clamp(1.5rem, 2.4vw, 2rem); font-weight: 750; letter-spacing: -.055em; }

/* Industry landing */
body.chem-food-home .food-home .land-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  grid-template-columns: minmax(0, 1.05fr) minmax(280px, .95fr);
  gap: clamp(1rem, 4vw, 3rem);
  min-height: 29rem;
  margin: .5rem 0 1.5rem;
  padding: clamp(1.6rem, 4vw, 3.4rem);
  border: 1px solid rgba(108, 72, 53, .08);
  border-radius: 2rem;
  background: radial-gradient(ellipse at 79% 52%, rgba(229, 192, 161, .35), transparent 40%), linear-gradient(128deg, #f2e6db, #fffaf5 63%);
}
body.chem-food-home .food-home .land-hero > div { position: relative; z-index: 1; }
body.chem-food-home .food-home .land-hero h1 { max-width: none; font-size: clamp(2.7rem, 5vw, 4.7rem); line-height: .98; letter-spacing: -.075em; }
body.chem-food-home .food-home .land-hero h1 em { font-weight: 700; font-style: normal; }
body.chem-food-home .food-home .land-hero .dir-lede { max-width: 37rem; margin-top: 1.1rem; font-size: 1.08rem; line-height: 1.6; }
body.chem-food-home .food-home .land-hero img {
  align-self: stretch;
  width: 100%;
  height: auto;
  min-height: 20rem;
  object-fit: contain;
  padding: .2rem;
  background: transparent;
  filter: drop-shadow(0 18px 22px rgba(70, 45, 27, .1));
  mix-blend-mode: multiply;
}
body.chem-food-home .food-home .land-ask { max-width: 43rem; margin-top: 1.5rem; border: 1px solid var(--food-line); box-shadow: 0 15px 35px rgba(62, 43, 30, .08); }
body.chem-food-home .food-home .land-prompts a { border: 1px solid var(--food-line); background: rgba(255, 253, 250, .78); }
body.chem-food-home .food-home .land-paths { gap: .85rem; margin: 1.2rem 0 2.2rem; }
body.chem-food-home .food-home .land-paths a {
  position: relative;
  min-height: 8.5rem;
  justify-content: flex-start;
  padding: 1.3rem 1.4rem;
  border: 1px solid var(--food-line);
  border-radius: 1.35rem;
  background: var(--food-surface);
  transition: transform .18s ease, box-shadow .18s ease;
}
body.chem-food-home .food-home .land-paths a:hover,
body.chem-food-home .food-home .land-companies a:hover,
body.chem-food .sup-list a:hover { transform: translateY(-2px); box-shadow: 0 14px 32px rgba(62, 43, 30, .08); }
body.chem-food-home .food-home .land-paths .cdb-icon { width: 1.35rem; height: 1.35rem; color: var(--food-accent); }
body.chem-food-home .food-home .land-paths strong { font-size: 1.08rem; }
body.chem-food-home .food-home .land-paths span { max-width: 28rem; }

/* Ingredient/formulation cards */
body.chem-food .dir-grid { gap: .9rem; }
body.chem-food .dir-card {
  overflow: hidden;
  padding: .7rem .7rem 1.15rem;
  border: 1px solid var(--food-line);
  border-radius: 1.35rem;
  background: var(--food-surface);
  box-shadow: 0 5px 18px rgba(60, 44, 31, .025);
  transition: transform .18s ease, box-shadow .18s ease;
}
body.chem-food .dir-card:hover { transform: translateY(-3px); box-shadow: 0 16px 34px rgba(60, 44, 31, .1); }
body.chem-food .dir-card img {
  display: block;
  width: 100%;
  height: clamp(10rem, 16vw, 14.5rem);
  margin: 0 0 1rem;
  padding: .8rem;
  object-fit: contain;
  border-radius: 1rem;
  background: radial-gradient(ellipse at 50% 72%, rgba(235, 218, 200, .6), transparent 64%), linear-gradient(140deg, #f4ece4, #fbf7f2);
}
body.chem-food .dir-card h2 {
  margin: 0 .45rem .45rem;
  color: var(--food-ink);
  font-family: var(--sans);
  font-size: 1.08rem;
  font-weight: 750;
  line-height: 1.25;
  letter-spacing: -.045em;
}
body.chem-food .dir-card p { margin-right: .45rem; margin-left: .45rem; color: var(--food-muted); }
body.chem-food .dir-card .dir-meta { align-items: center; gap: .4rem; font-size: .76rem; font-weight: 650; }
body.chem-food .dir-card .dir-meta .cdb-icon { width: .9rem; height: .9rem; color: var(--food-accent); }
body.chem-food .land-head { align-items: center; margin-bottom: 1rem; }
body.chem-food .land-head h2 { font-family: var(--sans); font-weight: 750; letter-spacing: -.06em; }
body.chem-food .land-head a { color: var(--food-accent); }

/* Ingredient detail */
body.chem-food-detail .dir-product .dir-stage {
  gap: clamp(1.4rem, 4vw, 3.6rem);
  align-items: center;
  margin: .7rem 0 2.8rem;
  padding: clamp(1.2rem, 3vw, 2.3rem);
  border: 1px solid var(--food-line);
  border-radius: 1.8rem;
  background: radial-gradient(ellipse at 18% 50%, rgba(236, 206, 177, .36), transparent 46%), linear-gradient(125deg, #f4e9df, #fffdfa 66%);
}
body.chem-food-detail .dir-photo {
  height: clamp(19rem, 32vw, 30rem);
  padding: 1.1rem;
  object-fit: contain;
  border: 1px solid rgba(82, 60, 42, .06);
  background: rgba(255, 253, 250, .64);
  box-shadow: 0 18px 42px rgba(65, 45, 30, .07);
}
body.chem-food-detail .dir-product h1 { max-width: 13ch; font-family: var(--sans); font-size: clamp(2.7rem, 4.6vw, 4.4rem); font-weight: 750; letter-spacing: -.075em; line-height: 1; }
body.chem-food-detail .dir-supplier-line { margin-top: 1rem; font-size: .95rem; }
body.chem-food-detail .dir-supplier-line a { color: var(--food-accent); text-decoration: none; }
body.chem-food-detail .dir-product .dir-copy { max-width: 46rem; margin-top: 1rem; font-size: 1rem; line-height: 1.7; }
body.chem-food-detail .dir-facts { gap: .55rem; }
body.chem-food-detail .dir-fact { min-height: 4.7rem; border: 1px solid var(--food-line); background: rgba(255, 253, 250, .88); }
body.chem-food-detail .dir-fact strong { color: var(--food-ink); font-family: var(--sans); font-size: .98rem; font-weight: 750; letter-spacing: -.025em; }
body.chem-food-detail .dir-fact .cdb-icon { color: var(--food-accent); }
body.chem-food-detail .dir-doc,
body.chem-food-detail .dir-panel,
body.chem-food-detail .dir-fold { border: 1px solid var(--food-line); background: var(--food-surface); }
body.chem-food-detail .dir-panel { min-height: 17rem; padding: 1.2rem; }
body.chem-food-detail .dir-fold { padding-right: 1rem; padding-left: 1rem; }
body.chem-food-detail .dir-chart { min-height: 13rem; }

/* Supplier directory and individual supplier */
body.chem-food-suppliers .sup > .dir-kicker { margin-top: .5rem; }
body.chem-food-suppliers .sup h1 { max-width: 14ch; font-family: var(--sans); font-size: clamp(2.8rem, 5vw, 4.3rem); font-weight: 750; letter-spacing: -.08em; }
body.chem-food-suppliers .sup-list { gap: .65rem; margin-top: 1.5rem; }
body.chem-food-suppliers .sup-list a {
  min-height: 4.6rem;
  padding: .8rem 1rem;
  border: 1px solid var(--food-line);
  border-radius: 1.1rem;
  background: var(--food-surface);
  transition: transform .18s ease, box-shadow .18s ease;
}
body.chem-food-suppliers .sup-list b { width: 2.7rem; height: 2.7rem; background: #f0e3d7; color: var(--food-accent); }
body.chem-food-suppliers .sup-list strong { font-size: .95rem; }
body.chem-food-suppliers .sup-list small { margin-top: .1rem; color: var(--food-muted); font-size: .78rem; }
body.chem-food-suppliers .sup-list em { font-size: 1.2rem; }
body.chem-food-company .food-supplier-hero { align-items: stretch; margin: .4rem 0 2.7rem; }
body.chem-food-company .food-supplier-hero h1 { font-family: var(--sans); font-size: clamp(2.8rem, 5vw, 4.4rem); font-weight: 750; letter-spacing: -.08em; }
body.chem-food-company .food-supplier-hero .dir-lede { max-width: 40rem; line-height: 1.65; }
body.chem-food-company .sup-mark {
  position: relative;
  overflow: hidden;
  display: flex;
  min-height: 18rem;
  height: auto;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-end;
  padding: clamp(1.5rem, 4vw, 2.5rem);
  border: 1px solid rgba(106, 72, 52, .1);
  border-radius: 1.8rem;
  color: var(--food-ink);
  background: radial-gradient(circle at 83% 19%, rgba(197, 146, 113, .24), transparent 34%), linear-gradient(135deg, #f0e0d3, #fffaf5);
  box-shadow: inset 0 0 0 8px rgba(255,255,255,.28);
}
body.chem-food-company .sup-mark-kicker { position: relative; z-index: 1; margin-bottom: auto; color: var(--food-accent); font: 800 .68rem/1 var(--sans); letter-spacing: .14em; }
body.chem-food-company .sup-mark strong { position: relative; z-index: 1; max-width: 11ch; font: 750 clamp(2.1rem, 4vw, 3.5rem)/.98 var(--sans); letter-spacing: -.075em; overflow-wrap: anywhere; }
body.chem-food-company .sup-mark small { position: relative; z-index: 1; margin-top: .65rem; color: var(--food-muted); font-size: .82rem; }
body.chem-food-company .sup-mark-orbit { position: absolute; right: 11%; top: 19%; width: 8rem; height: 8rem; border: 1px solid rgba(154, 85, 68, .26); border-radius: 50%; }
body.chem-food-company .sup-mark-orbit::before,
body.chem-food-company .sup-mark-orbit::after { content: ""; position: absolute; border: 1px solid rgba(154, 85, 68, .2); border-radius: 50%; }
body.chem-food-company .sup-mark-orbit::before { inset: 1.15rem -1.4rem; transform: rotate(35deg); }
body.chem-food-company .sup-mark-orbit::after { inset: -1.25rem 1.2rem; transform: rotate(-35deg); }
body.chem-food-company .sup-mark-orbit i { position: absolute; width: .55rem; height: .55rem; border: 2px solid #fffaf5; border-radius: 50%; background: var(--food-accent); }
body.chem-food-company .sup-mark-orbit i:nth-child(1) { top: -.22rem; left: 48%; }
body.chem-food-company .sup-mark-orbit i:nth-child(2) { right: .15rem; bottom: 1.5rem; background: #84947e; }
body.chem-food-company .sup-mark-orbit i:nth-child(3) { bottom: .3rem; left: .8rem; background: #d7a675; }
body.chem-food-company .sup-stats { max-width: 39rem; gap: .7rem; }
body.chem-food-company .sup-stats div { min-height: 5.1rem; padding: .8rem 1rem; border: 1px solid var(--food-line); background: var(--food-surface); }
body.chem-food-company .sup-stats strong { color: var(--food-accent); font-size: 1.8rem; }
body.chem-food-company .dir-block > h2 { font-size: clamp(1.65rem, 2.5vw, 2.1rem); }

@media (min-width: 860px) {
  body.chem-food-home .food-home .land-paths { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  body.chem-food-home .food-home .land-companies { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  body.chem-food-suppliers .sup-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 859px) {
  body.chem-food .dir-wrap { width: min(var(--cdb-page-max), calc(100% - var(--cdb-page-gutter))); padding-top: 1.2rem; }
  body.chem-food-home .food-home .land-hero { grid-template-columns: 1fr; min-height: 0; padding: 1.3rem; border-radius: 1.4rem; }
  body.chem-food-home .food-home .land-hero img { min-height: 13rem; max-height: 17rem; }
  body.chem-food-home .food-home .land-hero h1 { max-width: 12ch; font-size: clamp(2.6rem, 12vw, 4rem); }
  body.chem-food .dir-grid { grid-template-columns: 1fr 1fr; gap: .6rem; }
  body.chem-food .dir-card { padding: .5rem .5rem .85rem; border-radius: 1rem; }
  body.chem-food .dir-card img { height: 9.5rem; padding: .45rem; border-radius: .75rem; }
  body.chem-food .dir-card h2 { margin: 0 .2rem .3rem; font-size: .94rem; }
  body.chem-food .dir-card p { margin-right: .2rem; margin-left: .2rem; font-size: .78rem; }
  body.chem-food-detail .dir-product .dir-stage { padding: .75rem; border-radius: 1.3rem; }
  body.chem-food-detail .dir-photo { height: 17rem; }
  body.chem-food-detail .dir-facts { grid-template-columns: 1fr 1fr; }
  body.chem-food-company .sup-mark { min-height: 14rem; }
  body.chem-food-company .sup-mark-orbit { width: 6rem; height: 6rem; right: 9%; }
}

/* Food routes use the same headline face and the same recovery cards as other directories. */
body.chem-food .dir h1,
body.chem-food .dir-block > h2,
body.chem-food .land-head h2,
body.chem-food .land-answer > h2,
body.chem-food .dir-empty-state h2 {
  font-family: var(--sans) !important;
  font-weight: 750;
  letter-spacing: -.06em;
}
body.chem-food .dir-empty-state { border-color: var(--food-line); background: linear-gradient(120deg, #f3e7dc, var(--food-surface) 78%); }
body.chem-food .dir-empty-icon { background: #ead8ca; color: var(--food-accent); }
body.chem-food .dir-empty-actions .dir-empty-primary { background: var(--food-ink); color: #fffdfa; }
body.chem-food .dir-empty-actions .dir-empty-primary:hover { background: var(--food-accent); }

@media (min-width: 641px) and (max-width: 859px) {
  body.chem-food .cdb-main-row,
  body.chem-food .cdb-foot-shell { width: min(var(--cdb-page-max), calc(100% - var(--cdb-page-gutter))); }
}

@media (max-width: 420px) {
  body.chem-food .dir-grid { grid-template-columns: 1fr; }
  body.chem-food .dir-card img { height: 13rem; }
  body.chem-food-company .sup-stats { grid-template-columns: 1fr; }
  body.chem-food-suppliers .sup-list { grid-template-columns: 1fr; }
}

/* Match food page hero and record headlines to the site's global title scale. */
body.chem-food .dir h1,
body.chem-food-home .food-home .land-hero h1,
body.chem-food-detail .dir-product h1,
body.chem-food-suppliers .sup h1,
body.chem-food-company .food-supplier-hero h1 {
  font-size: clamp(3.2rem, 4.4vw, 4rem);
}

@media (max-width: 859px) {
  body.chem-food .dir h1,
  body.chem-food-home .food-home .land-hero h1,
  body.chem-food-detail .dir-product h1,
  body.chem-food-suppliers .sup h1,
  body.chem-food-company .food-supplier-hero h1 {
    font-size: clamp(2.4rem, 8vw, 3.2rem);
  }
}
