/* Elementum Global Earth - brand theme + motion layer
   Palette: Forest Green #0C4723 | Metallic Gold #D4A13B | Emerald Green #00854A | Warm Ivory #F5F0DF
   Load AFTER styles.css, animations.css and flip-cards.css. Pair with theme.js. */

/* ---------- Fonts (self-hosted) ---------- */
@font-face{font-family:"Fraunces";src:url("../fonts/fraunces-latin-wght-normal.woff2") format("woff2");font-weight:100 900;font-style:normal;font-display:swap}
@font-face{font-family:"Manrope";src:url("../fonts/manrope-latin-wght-normal.woff2") format("woff2");font-weight:200 800;font-style:normal;font-display:swap}
:root{--font-display:"Fraunces","Iowan Old Style","Palatino Linotype",Georgia,serif;--font-body:"Manrope","Segoe UI",Inter,Roboto,Arial,sans-serif;--card:#FFFDF7}
body{font-family:var(--font-body)}
.title,.hero h1,.story h3,.story-dark h3,.form-head h2,.form-head h3,.why-card h3,.flip-copy h3,.flip-back h3,.product h3,.brand strong,.footer-brand-text strong{font-family:var(--font-display);font-weight:600}
.title{letter-spacing:-.02em;line-height:1.1;color:var(--green)}
.why-card h3,.flip-copy h3,.flip-back h3{font-weight:600;letter-spacing:-.005em}
::selection{background:var(--gold);color:var(--green-dark)}
:focus-visible{outline:3px solid var(--gold);outline-offset:3px;border-radius:6px}

/* ---------- Eyebrow + title ornament ---------- */
.eyebrow{display:flex;align-items:center;gap:12px;color:var(--emerald-deep);letter-spacing:.16em}
.eyebrow::before{content:"";flex:none;width:30px;height:2px;border-radius:2px;background:linear-gradient(90deg,var(--gold),var(--gold-light))}
.hero .eyebrow,.sustain .eyebrow{color:var(--gold-light)}
.tag,.form-badge{color:var(--emerald-deep)}
.form-badge{background:var(--green-soft)}
.title::after{content:"";display:block;width:76px;height:3px;margin-top:18px;border-radius:3px;background:linear-gradient(90deg,var(--gold),var(--gold-light));transform:scaleX(0);transform-origin:left;transition:transform .9s .55s cubic-bezier(.2,.7,.2,1)}
.title.tw-in::after{transform:scaleX(1)}
html:not(.fx-on) .title::after{transform:scaleX(1)}
.title.reveal{opacity:1;transform:none;transition:none}

/* split-word title reveal (classes added by theme.js) */
.tw-split .tw{display:inline-block;overflow:hidden;vertical-align:top;padding-bottom:.16em;margin-bottom:-.16em}
.tw-split .tw>span{display:inline-block;transform:translateY(112%);transition:transform .95s cubic-bezier(.2,.8,.2,1);transition-delay:calc(var(--i) * 55ms)}
.tw-split.tw-in .tw>span{transform:none}

/* ---------- Header ---------- */
.site-header{background:rgba(250,247,235,.86);backdrop-filter:saturate(1.4) blur(14px);-webkit-backdrop-filter:saturate(1.4) blur(14px);border-bottom-color:transparent}
.site-header::after{content:"";position:absolute;left:0;right:0;bottom:0;height:1px;background:linear-gradient(90deg,transparent,rgba(212,161,59,.75),transparent)}
.brand img{background:transparent;box-shadow:none;border-radius:0}
.brand strong{font-size:1.12rem;font-weight:700;letter-spacing:-.01em}
.brand small{color:var(--gold-deep)}
.nav-links a:not(.btn){color:var(--green)}
.nav-links a.is-active:not(.btn){color:var(--emerald-deep)}
@media(min-width:981px){.nav-links a.is-active:not(.btn)::after{transform:scaleX(1)}}
.menu{background:var(--card);border-color:var(--line)}
@media(max-width:980px){.nav-links{background:var(--ivory-soft)}}
.scroll-progress{height:3px;background:linear-gradient(90deg,var(--emerald),var(--gold),var(--gold-light))}

/* ---------- Buttons ---------- */
.btn{font-weight:800;letter-spacing:.01em;translate:var(--bx,0px) var(--by,0px)}
.btn-primary{background:linear-gradient(135deg,var(--gold-light),var(--gold) 55%,#C28F2B);color:var(--green)}
.btn-primary:hover{background:linear-gradient(135deg,#F6DE9E,var(--gold-light));color:var(--green);box-shadow:0 12px 28px rgba(212,161,59,.4)}
.btn-dark:hover{background:var(--emerald);color:#fff;box-shadow:0 12px 26px rgba(0,133,74,.3)}
.btn-outline{border-color:rgba(245,240,223,.6);color:var(--ivory)}
.btn-outline:hover{background:var(--ivory);border-color:var(--ivory);color:var(--green)}

/* ---------- Hero ---------- */
.hero{background:linear-gradient(135deg,#06301A 0%,#0C4723 50%,#0B5A30 100%);padding:74px 0 124px;isolation:isolate}
.hero:before{background:radial-gradient(circle at 10% 8%,rgba(0,133,74,.4),transparent 34%),radial-gradient(circle at 92% 88%,rgba(212,161,59,.16),transparent 36%);z-index:0}
.hero .container{position:relative;z-index:1}
.hero-fx{position:absolute;inset:0;overflow:hidden;pointer-events:none;z-index:0}
.hero-fx .glow{position:absolute;border-radius:50%;will-change:transform}
.hero-fx .g1{width:720px;height:720px;left:-240px;top:-280px;background:radial-gradient(circle,rgba(0,133,74,.55),transparent 66%);animation:glowA 16s ease-in-out infinite alternate}
.hero-fx .g2{width:640px;height:640px;right:-220px;bottom:-260px;background:radial-gradient(circle,rgba(212,161,59,.26),transparent 66%);animation:glowB 20s ease-in-out infinite alternate}
@keyframes glowA{to{transform:translate(90px,70px) scale(1.12)}}
@keyframes glowB{to{transform:translate(-80px,-60px) scale(1.15)}}
.hero-fx .orbits{position:absolute;right:-16%;top:-26%;width:min(980px,96vw);height:auto;opacity:.6;animation:orbitSpin 150s linear infinite;translate:0 calc(var(--scroll,0) * .1px)}
@keyframes orbitSpin{to{transform:rotate(360deg)}}
.hero-fx canvas{position:absolute;inset:0;width:100%;height:100%}
.hero-fx .spot{position:absolute;left:0;top:0;width:520px;height:520px;border-radius:50%;background:radial-gradient(circle,rgba(235,200,117,.16),transparent 62%);translate:calc(var(--sx,-900px) - 260px) calc(var(--sy,-900px) - 260px);transition:translate .35s ease-out}
.hero h1{color:var(--ivory);font-size:clamp(2.3rem,4.1vw,3.8rem);line-height:1.06;letter-spacing:-.026em;min-height:3.28em}
.hero-copy{color:rgba(245,240,223,.88)}
.hero-copy{min-height:4.9em}
.trust{background:rgba(245,240,223,.07);border-color:rgba(235,200,117,.3)}
.trust-dot{background:var(--gold-light)}
.b2b-badge{border-color:rgba(235,200,117,.5);background:rgba(212,161,59,.14)}
.b2b-chips span{border-color:rgba(235,200,117,.32);background:rgba(245,240,223,.07)}
.hero-rotator .typed{color:var(--gold-light)}
.proof{background:rgba(245,240,223,.07);border-color:rgba(235,200,117,.22)}
.hero-marquee{border-block-color:rgba(235,200,117,.3)}
.marq-track span{color:rgba(245,240,223,.92)}

/* hero visual: parallax + gold frames */
.hero-visual{--px:0;--py:0}
.hero-photo{border:1px solid rgba(235,200,117,.55);box-shadow:0 26px 60px rgba(0,0,0,.32),0 0 0 7px rgba(245,240,223,.05)}
.hero-photo.one{translate:calc(var(--px) * 16px) calc(var(--py) * 12px)}
.hero-photo.two{translate:calc(var(--px) * -12px) calc(var(--py) * -10px)}
.hero-logo{z-index:3;background:var(--ivory-soft);border:3px solid var(--gold);translate:calc(var(--px) * -24px) calc(var(--py) * -18px)}
.hero-logo img{background:transparent;padding:6px}
.hero-logo::after{background:linear-gradient(100deg,transparent,rgba(255,240,200,.7),transparent)}
.logo-orbit{--logo:166px;position:absolute;right:6%;bottom:6%;width:var(--logo);height:var(--logo);z-index:4;pointer-events:none;translate:calc(var(--px) * -24px) calc(var(--py) * -18px)}
.logo-orbit svg{position:absolute;left:50%;top:50%;width:calc(var(--logo) * 1.95);height:calc(var(--logo) * 1.95);translate:-50% -50%;overflow:visible}
.lo-ring{stroke-dasharray:100;stroke-dashoffset:100;animation:ringDraw 2.2s 1.3s cubic-bezier(.5,0,.2,1) forwards}
.lo-dot{opacity:0;animation:fadeIn .5s 3s forwards}
@keyframes ringDraw{to{stroke-dashoffset:0}}
@keyframes fadeIn{to{opacity:1}}
@media(max-width:640px){.logo-orbit{--logo:122px}.hero h1{font-size:2.3rem;min-height:3.28em}.hero-copy{min-height:5.4em}.hero{padding-bottom:110px}}

/* curved ribbon edge between hero and the next section */
.hero-curve{position:absolute;left:0;right:0;bottom:-1px;height:92px;z-index:2;pointer-events:none}
.hero-curve svg{display:block;width:100%;height:100%;overflow:visible}
.hc-fill{fill:var(--ivory-soft)}
.hc-line{fill:none;stroke:var(--gold);stroke-width:3;stroke-linecap:round;stroke-dasharray:100;stroke-dashoffset:100;animation:ringDraw 2.4s 1.1s cubic-bezier(.5,0,.2,1) forwards;filter:drop-shadow(0 0 6px rgba(235,200,117,.55))}

/* ---------- Sections ---------- */
.about{background:linear-gradient(180deg,var(--ivory-soft) 0%,var(--ivory) 100%)}
.why{background-color:var(--ivory);background-image:radial-gradient(rgba(12,71,35,.08) 1px,transparent 1.5px);background-size:24px 24px}
.products{background:var(--ivory-soft)}
.logistics{background:var(--ivory)}
.contact{background:var(--ivory-soft)}

/* cards */
.card{background:var(--card);border-color:var(--line)}
.why-card,.cap,.story,.contact-card{position:relative}
.why-card::before,.cap::before,.story::before,.contact-card::before{content:"";position:absolute;left:22px;right:22px;top:-1px;height:3px;border-radius:0 0 4px 4px;background:linear-gradient(90deg,var(--gold),var(--gold-light));transform:scaleX(0);transform-origin:left;transition:transform .55s cubic-bezier(.2,.7,.2,1);pointer-events:none}
.why-card:hover::before,.cap:hover::before,.story:hover::before,.contact-card:hover::before{transform:scaleX(1)}
.why-card,.cap,.contact-card,.story,.mini{background-image:radial-gradient(360px circle at var(--mx,-500px) var(--my,-500px),rgba(212,161,59,.17),transparent 60%);background-repeat:no-repeat}
@media(hover:hover){
  .why-card:not(.reveal):hover,.cap:not(.reveal):hover,.contact-card:not(.reveal):hover{transform:perspective(900px) rotateX(var(--rx,0deg)) rotateY(var(--ry,0deg)) translateY(-7px);box-shadow:0 22px 46px rgba(7,45,23,.16);border-color:#D9C88A}
  .why-card:hover .icon-box{background:var(--green);color:var(--gold-light);transform:scale(1.1) rotate(-6deg)}
}
.cap h3,.cap h4,.why-card h3,.mini h3,.mini h4,.step h3,.step h4,.contact-card strong{color:var(--green)}
.icon-box{background:linear-gradient(145deg,var(--gold-light),var(--gold));color:var(--green);box-shadow:0 8px 18px rgba(168,122,30,.28)}
.icon-box svg{width:24px;height:24px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.story-dark{background:linear-gradient(145deg,var(--green-dark),var(--green) 55%,#0A6A3A);border:1px solid rgba(235,200,117,.35);position:relative;overflow:hidden}
.story-dark::after{content:"";position:absolute;right:-70px;top:-70px;width:220px;height:220px;border-radius:50%;border:1px solid rgba(235,200,117,.35);box-shadow:0 0 0 24px rgba(235,200,117,.06),0 0 0 54px rgba(235,200,117,.04);animation:ringBreath 7s ease-in-out infinite}
@keyframes ringBreath{50%{transform:scale(1.12)}}
.story-dark ul{color:rgba(245,240,223,.86)}
.media-copy strong{color:var(--green)}

/* products */
.tab{background:var(--card);border-color:var(--line);color:var(--green)}
.tab:hover{border-color:var(--gold);transform:translateY(-2px)}
.tab.active{background:var(--green);border-color:var(--green);color:var(--ivory);box-shadow:0 10px 22px rgba(12,71,35,.25),inset 0 -3px 0 var(--gold)}
.flip-front::after{background:linear-gradient(to top,rgba(7,45,23,.95) 0,rgba(7,45,23,.55) 42%,rgba(7,45,23,0) 75%)}
.flip-front::before{content:"";position:absolute;inset:0;z-index:2;pointer-events:none;background:linear-gradient(115deg,transparent 35%,rgba(255,238,190,.3) 50%,transparent 65%);transform:translateX(-130%)}
@media(hover:hover){.flip:hover .flip-front::before{transform:translateX(130%);transition:transform 1s ease}}
.flip-back{background:linear-gradient(150deg,var(--green-dark),var(--green) 55%,#0A5A31);border-top:3px solid var(--gold)}
.flip-face{border-color:rgba(212,161,59,.35)}
@media(hover:hover){.flip:hover .flip-face{box-shadow:0 24px 52px rgba(7,45,23,.3),0 0 0 1px rgba(212,161,59,.7)}}
.flip-badges span{background:var(--card);border-color:var(--line)}
.products.cards-armed:not(.cards-in) .flip{opacity:0}
@keyframes flipIn{from{opacity:0;transform:translateY(34px) scale(.96)}to{opacity:1;transform:none}}
.products.cards-in .panel:not([hidden]) .flip{animation:flipIn .75s cubic-bezier(.2,.7,.2,1) backwards;animation-delay:calc(var(--n,0) * 70ms)}
.flip:nth-child(2){--n:1}.flip:nth-child(3){--n:2}.flip:nth-child(4){--n:3}.flip:nth-child(5){--n:4}.flip:nth-child(6){--n:5}.flip:nth-child(7){--n:6}.flip:nth-child(8){--n:7}

/* sustainability = dark forest band */
.sustain{position:relative;overflow:hidden;color:var(--ivory);background:radial-gradient(900px 520px at 88% 0%,rgba(0,133,74,.38),transparent 60%),radial-gradient(700px 420px at 0% 100%,rgba(212,161,59,.12),transparent 60%),linear-gradient(160deg,#06301A,#0C4723 60%,#0A5A31)}
.sustain .container{position:relative;z-index:1}
.sustain .title{color:var(--ivory);font-size:clamp(2.1rem,4vw,3.4rem);line-height:1.08;letter-spacing:-.026em}
/* hero-style motion: gold light wave runs through the words after they rise in */
.sustain .title.tw-in .tw>span{animation:egeWave 6s ease-in-out infinite;animation-delay:calc(1.4s + var(--i) * .22s)}
/* the two photo cards float gently like the hero photos (uses "translate" so hover lift still works) */
@keyframes floatT{0%,100%{translate:0 0}50%{translate:0 -10px}}
@keyframes floatTb{0%,100%{translate:0 0}50%{translate:0 10px}}
.sustain-media .sustain-card:nth-child(1){animation:floatT 7s 1.2s ease-in-out infinite}
.sustain-media .sustain-card:nth-child(2){animation:floatTb 8s 1.4s ease-in-out infinite}
/* mini cards: gold edge sweeps in one after another */
.sustain .mini{position:relative;overflow:hidden}
.sustain .mini::after{content:"";position:absolute;top:0;bottom:0;left:0;width:45%;background:linear-gradient(100deg,transparent,rgba(235,200,117,.16),transparent);transform:translateX(-140%) skewX(-18deg);animation:egeShine 7s ease-in-out infinite;animation-delay:calc(var(--k,0) * 1.2s);pointer-events:none}
.sustain .mini:nth-child(2){--k:1}.sustain .mini:nth-child(3){--k:2}.sustain .mini:nth-child(4){--k:3}
.sustain .sustain-grid{align-items:start}
.sustain .lead{color:rgba(245,240,223,.84)}
.sustain .mini{background-color:rgba(245,240,223,.07);border-color:rgba(235,200,117,.25)}
.sustain .mini h4{color:var(--gold-light)}
.sustain .mini p{color:rgba(245,240,223,.8)}
.sustain-card{border-color:rgba(235,200,117,.4)}
.leaves{position:absolute;inset:0;pointer-events:none;z-index:0}
.leaf{position:absolute;height:auto;color:var(--gold-light);opacity:.16;animation:leafDrift 16s ease-in-out infinite alternate}
@keyframes leafDrift{0%{transform:translate(0,0) rotate(var(--r0,-20deg))}100%{transform:translate(22px,-30px) rotate(var(--r1,20deg))}}

/* logistics route + timeline */
.log-image{position:relative}
.log-image::after{content:"";position:absolute;inset:0;pointer-events:none;background:linear-gradient(to top,rgba(7,45,23,.6),transparent 50%)}
.route{position:absolute;inset:0;z-index:2;width:100%;height:100%;pointer-events:none}
.route .r{fill:none;stroke:var(--gold-light);stroke-width:3;stroke-linecap:round;stroke-dasharray:2 10;animation:routeMarch 1.4s linear infinite;filter:drop-shadow(0 0 4px rgba(0,0,0,.4))}
@keyframes routeMarch{to{stroke-dashoffset:-12}}
.route .pr{fill:rgba(235,200,117,.45);transform-box:fill-box;transform-origin:center;animation:pinPulse 2.2s ease-out infinite}
@keyframes pinPulse{from{transform:scale(.6);opacity:.9}to{transform:scale(3);opacity:0}}
.steps{position:relative}
.steps::before,.steps::after{content:"";position:absolute;left:20px;top:22px;bottom:22px;width:2px;border-radius:2px}
.steps::before{background:rgba(12,71,35,.14)}
.steps::after{background:linear-gradient(180deg,var(--gold),var(--emerald));transform:scaleY(var(--prog,0));transform-origin:top}
.num{position:relative;z-index:1;background:linear-gradient(145deg,var(--gold-light),var(--gold));color:var(--green);box-shadow:0 0 0 5px var(--ivory)}

/* images: wipe-in */
html.fx-on .img-wipe{clip-path:inset(0 0 100% 0);transform:scale(1.16)}
html.fx-on .img-wipe.is-in{clip-path:inset(0);transform:scale(1);transition:clip-path 1.2s cubic-bezier(.7,0,.2,1),transform 1.6s cubic-bezier(.2,.7,.2,1)}

/* ---------- Contact / form ---------- */
.contact-card span span{color:var(--muted)}
form.form{background:linear-gradient(180deg,var(--card) 0,var(--ivory-soft) 100%);border-color:var(--line)}
.form input,.form select,.form textarea{background-color:#fff}
.social-pill{background:var(--card)}
.social-pill:hover .ico,.social-foot:hover .ico{background:var(--gold);color:var(--green)}

/* ---------- Footer ---------- */
.site-footer{position:relative;background:linear-gradient(180deg,#0C4723,#06301A);color:var(--ivory)}
.site-footer::before{content:"";position:absolute;left:0;right:0;top:0;height:3px;background:linear-gradient(90deg,var(--green),var(--gold),var(--gold-light),var(--gold),var(--green));background-size:200% 100%;animation:egeBar 7s linear infinite}
.footer-logo{background:var(--ivory-soft);box-shadow:0 0 0 3px rgba(235,200,117,.35)}
.footer-title{color:var(--gold-light)}
.footer-links a:hover{color:var(--gold-light)}
.footer-copy{color:rgba(245,240,223,.78)}
.footer-bottom{border-top-color:rgba(235,200,117,.22);color:rgba(245,240,223,.68)}

/* ---------- Back to top with progress ring ---------- */
.to-top{position:fixed;right:20px;bottom:20px;z-index:55;width:54px;height:54px;padding:0;border:0;border-radius:50%;display:grid;place-items:center;background:var(--green);color:var(--gold-light);cursor:pointer;box-shadow:0 12px 28px rgba(7,45,23,.38);opacity:0;visibility:hidden;translate:0 16px;transition:opacity .3s ease,translate .3s ease,visibility .3s,background .25s ease}
.to-top.show{opacity:1;visibility:visible;translate:0 0}
.to-top:hover{background:var(--emerald)}
.to-top svg{position:absolute;inset:0;width:100%;height:100%}
.to-top .ring{transform:rotate(-90deg)}
.to-top .ring circle{fill:none;stroke-width:3}
.to-top .ring .bg{stroke:rgba(245,240,223,.16)}
.to-top .ring .fg{stroke:var(--gold);stroke-linecap:round;stroke-dasharray:150.8;stroke-dashoffset:150.8}
.to-top .arrow{width:20px;height:20px;inset:auto;position:relative;fill:none;stroke:currentColor;stroke-width:2.4;stroke-linecap:round;stroke-linejoin:round;transition:transform .25s ease}
.to-top:hover .arrow{transform:translateY(-3px)}

/* ---------- Mobile polish ---------- */
@media(max-width:980px){.hero-fx .orbits{right:-40%;top:-12%;opacity:.45}}
@media(max-width:640px){.brand strong{font-size:.98rem}.brand small{font-size:.6rem;letter-spacing:.1em}.brand img{width:46px;height:46px}.to-top{right:14px;bottom:14px;width:48px;height:48px}.title::after{width:60px}}
@media(hover:none){.hero-fx .spot{display:none}}

/* ---------- Respect "reduce motion" ---------- */
@media(prefers-reduced-motion:reduce){
  .hero-fx .orbits,.hero-fx .glow,.leaf,.sustain-card,.sustain .mini::after,.route .r,.route .pr,.lo-ring,.hc-line,.story-dark::after,.site-footer::before{animation:none!important}
  .lo-ring,.hc-line{stroke-dashoffset:0}
  .lo-dot{opacity:1}
  .hero-fx canvas,.hero-fx .spot{display:none}
}

/* Extend the home typography and palette to the standalone product and company pages. */
body.content-page,body.food-page,body.coco-page,body.product-detail-page,body[data-category]{
  background:var(--ivory-soft);
  color:var(--ink);
  font-family:var(--font-body);
}
body.content-page h1,body.content-page h2,body.content-page h3,body.content-page h4,
body.food-page h1,body.food-page h2,body.food-page h3,body.food-page h4,
body.coco-page h1,body.coco-page h2,body.coco-page h3,body.coco-page h4,
body.product-detail-page h1,body.product-detail-page h2,body.product-detail-page h3,body.product-detail-page h4,
body[data-category] h1,body[data-category] h2,body[data-category] h3,body[data-category] h4{
  font-family:var(--font-display)!important;
  letter-spacing:-.025em;
}
body.content-page .card,body.food-page .card,body.coco-page .card,body.product-detail-page .card,
body[data-category] .card,body[data-category] .category-card,body[data-category] .glance,
body[data-category] .items>div,body[data-category] .cols>div{
  border-color:var(--line);
  border-radius:20px;
  background-color:var(--card);
  box-shadow:var(--shadow-sm);
}
body.content-page input,body.content-page select,body.content-page textarea,
body.food-page input,body.food-page select,body.food-page textarea,
body.coco-page input,body.coco-page select,body.coco-page textarea,
body.product-detail-page input,body.product-detail-page select,body.product-detail-page textarea,
body[data-category] input,body[data-category] select,body[data-category] textarea{
  border-color:#D9CFA6;
  border-radius:12px;
  background:#fff;
  color:var(--ink);
}

/* Product cards use their own product photo as a full-card background. */
.ag-page #products .product{
  position:relative;
  isolation:isolate;
  overflow:hidden;
  min-height:420px;
  border-color:rgba(235,200,117,.5)!important;
  background-position:center!important;
  background-size:cover!important;
  color:var(--ivory)!important;
  box-shadow:0 20px 42px rgba(7,45,23,.24)!important;
}
.ag-page #products .product:nth-child(1),.ag-page #products .product:nth-child(2){
  background-image:linear-gradient(180deg,rgba(5,39,23,.42) 0%,rgba(5,39,23,.78) 42%,rgba(5,39,23,.97) 100%),url('/images/corn-harvest.jpg')!important;
}
.ag-page #products .product:nth-child(3){
  background-image:linear-gradient(180deg,rgba(5,39,23,.42) 0%,rgba(5,39,23,.78) 42%,rgba(5,39,23,.97) 100%),url('/images/soybean-harvest.jpg')!important;
}
.ag-page #products .product h3,.ag-page #products .product p,.ag-page #products .product>div,
.ag-page #products .product>div span{color:var(--ivory)!important}
.ag-page #products .product h3,.ag-page #products .product p,.ag-page #products .product>div{ text-shadow:0 1px 3px rgba(0,0,0,.6) }
.ag-page #products .product h3{font-size:clamp(1.5rem,2.2vw,2rem)!important}
.ag-page #products .product a[style*="align-self"]{background:var(--gold)!important;color:var(--green)!important}

.product-grid>.product:has(.product-image-link){
  position:relative;
  isolation:isolate;
  overflow:hidden;
  min-height:590px;
  border-color:rgba(235,200,117,.48)!important;
  background:linear-gradient(180deg,#0c4723,#072d17)!important;
  color:var(--ivory)!important;
}
.product-grid>.product:has(.product-image-link)::after{
  position:absolute;
  z-index:-1;
  inset:0;
  background:linear-gradient(180deg,rgba(5,39,23,.48) 0%,rgba(5,39,23,.76) 36%,rgba(5,39,23,.97) 72%);
  content:"";
  pointer-events:none;
}
.product-grid>.product:has(.product-image-link)>.product-image-link{
  position:absolute;
  z-index:-2;
  inset:0;
  margin:0;
  border-radius:inherit;
}
.product-grid>.product:has(.product-image-link)>.product-image-link img{width:100%;height:100%;object-fit:cover}
.product-grid>.product:has(.product-image-link)>:not(.product-image-link){position:relative;z-index:1}
.product-grid>.product:has(.product-image-link) .tag{color:var(--gold-light)}
.product-grid>.product:has(.product-image-link) h3,.product-grid>.product:has(.product-image-link) h3 a,
.product-grid>.product:has(.product-image-link) p,.product-grid>.product:has(.product-image-link) .specs,
.product-grid>.product:has(.product-image-link) .specs strong{color:var(--ivory)!important}
.product-grid>.product:has(.product-image-link) .specs li{border-color:rgba(245,240,223,.24)}
.product-grid>.product:has(.product-image-link) .tag,.product-grid>.product:has(.product-image-link) h3,
.product-grid>.product:has(.product-image-link) p,.product-grid>.product:has(.product-image-link) .specs{ text-shadow:0 1px 3px rgba(0,0,0,.62) }
.product-grid>.product:has(.product-image-link) .btn{border-color:var(--gold);background:var(--gold);color:var(--green)}

.rare-page .cards article.card:has(.tile){
  position:relative;
  isolation:isolate;
  overflow:hidden;
  border-color:rgba(235,200,117,.48)!important;
  background-position:center!important;
  background-size:cover!important;
  color:var(--ivory);
}
.rare-page .cards article.card:has(.tile)::before{position:absolute;z-index:-1;inset:0;background:linear-gradient(180deg,rgba(5,39,23,.38),rgba(5,39,23,.97));content:""}
.rare-page .cards article.card:has(.tile):nth-child(1){background-image:url('/images/rare-earth-minerals.jpg')!important}
.rare-page .cards article.card:has(.tile):nth-child(2){background-image:url('/images/rare-earth-minerals1.jpg')!important}
.rare-page .cards article.card:has(.tile):nth-child(3){background-image:url('/images/rare-earth-mine.jpg')!important}
.rare-page .cards article.card:has(.tile) h3,.rare-page .cards article.card:has(.tile) h3 a,
.rare-page .cards article.card:has(.tile) p,.rare-page .cards article.card:has(.tile) .go{color:var(--ivory)!important}
.rare-page .cards article.card:has(.tile) .tile{box-shadow:0 10px 28px rgba(0,0,0,.28)}

.coco-page .pcard{position:relative;isolation:isolate;overflow:hidden;min-height:410px;border-color:rgba(235,200,117,.48)!important;background-position:center!important;background-size:cover!important;color:var(--ivory)!important}
.coco-page .pcard::after{position:absolute;z-index:-1;inset:0;background:linear-gradient(180deg,rgba(5,39,23,.36),rgba(5,39,23,.97));content:"";pointer-events:none}
.coco-page .pcard:nth-child(1){background-image:url('/images/coco-blocks.jpg')!important}
.coco-page .pcard:nth-child(2){background-image:url('/images/coco-chips.jpg')!important}
.coco-page .pcard:nth-child(3){background-image:url('/images/coco-mixed-blocks.jpg')!important}
.coco-page .pcard:nth-child(4){background-image:url('/images/coco-grow-bags.jpg')!important}
.coco-page .pcard:nth-child(5){background-image:url('/images/coco-open-top-bags.jpg')!important}
.coco-page .pcard:nth-child(6){background-image:url('/images/coco-briquettes.jpg')!important}
.coco-page .pcard:nth-child(7){background-image:url('/images/coco-discs.jpg')!important}
.coco-page .pcard:nth-child(8){background-image:url('/images/coco-plugs.jpg')!important}
.coco-page .pcard .tag,.coco-page .pcard h3,.coco-page .pcard h3 a,.coco-page .pcard p,.coco-page .pcard li{color:var(--ivory)!important}
.coco-page .pcard .more{color:var(--gold-light)!important}

.food-page .cards>li{position:relative;isolation:isolate;overflow:hidden;min-height:260px;border-color:rgba(235,200,117,.48)!important;background-position:center!important;background-size:cover!important;color:var(--ivory)!important}
.food-page .cards>li::after{position:absolute;z-index:-1;inset:0;background:linear-gradient(180deg,rgba(5,39,23,.48) 0%,rgba(5,39,23,.76) 45%,rgba(5,39,23,.97) 100%);content:"";pointer-events:none}
.food-page .cards>li:nth-child(1){background-image:url('/images/food-dals.jpg')!important}
.food-page .cards>li:nth-child(2){background-image:url('/images/food-rice.jpg')!important}
.food-page .cards>li:nth-child(3){background-image:url('/images/food-flours.jpg')!important}
.food-page .cards>li:nth-child(4){background-image:url('/images/food-spices.jpg')!important}
.food-page .cards>li:nth-child(5){background-image:url('/images/food-masalas.jpg')!important}
.food-page .cards>li:nth-child(6){background-image:url('/images/food-nuts.jpg')!important}
.food-page .cards>li a,.food-page .cards>li h3,.food-page .cards>li p,.food-page .cards>li span{position:relative;z-index:1;color:var(--ivory)!important}
.food-page .cards>li h3,.food-page .cards>li p,.food-page .cards>li span{text-shadow:0 1px 4px rgba(0,0,0,.75)}
.food-page .cards>li h3{font-size:1.45rem}
.food-page .cards>li span{color:var(--gold-light)!important}

/* Existing category cards keep their own photos and place the copy over the image. */
body[data-category] .category-grid .category-card{min-height:300px;overflow:hidden;border-color:rgba(235,200,117,.48);background:var(--green-dark);box-shadow:0 18px 38px rgba(7,45,23,.2)}
body[data-category] .category-grid .category-card>a{position:relative;isolation:isolate;display:flex;min-height:300px;flex-direction:column;justify-content:flex-end;overflow:hidden;color:var(--ivory)}
body[data-category] .category-grid .category-card>a::after{position:absolute;z-index:-1;inset:0;background:linear-gradient(180deg,rgba(5,39,23,.28) 8%,rgba(5,39,23,.64) 42%,rgba(5,39,23,.98) 100%);content:""}
body[data-category] .category-grid .category-card>a>img{position:absolute;z-index:-2;inset:0;width:100%;height:100%;object-fit:cover;transition:transform .55s ease}
body[data-category] .category-grid .category-card:hover>a>img{transform:scale(1.06)}
body[data-category] .category-grid .category-card .category-card-copy{position:relative;z-index:1;padding:22px;color:var(--ivory)}
body[data-category] .category-grid .category-card h2,body[data-category] .category-grid .category-card h3,
body[data-category] .category-grid .category-card p{color:var(--ivory)!important}
body[data-category] .category-grid .category-card h2,body[data-category] .category-grid .category-card h3{font-size:1.4rem}
.rare-page main>section:nth-of-type(3) .grid4 .step p{color:rgba(255,255,255,.92)!important}
.rare-page main>section:nth-of-type(3) .grid4 .step b{color:var(--gold-light)!important}

/* Keep illustrated hero captions readable over every product and company page. */
body .category-art__caption h2.category-art__title{
  color:var(--ivory,#F5F0DF)!important;
  text-shadow:0 2px 10px rgba(0,0,0,.82)!important;
}
body .category-art__caption .category-art__subtitle{
  color:rgba(255,255,255,.96)!important;
  text-shadow:0 1px 5px rgba(0,0,0,.8);
}

@media(max-width:640px){.ag-page #products .product,.product-grid>.product:has(.product-image-link),.coco-page .pcard{min-height:360px}}
