/* ══════════════════════════════════════════════════════════════
   CV. ALLPIN — Global Stylesheet
   Palette: Forest #546B41 · Sage #99AD7A · Sand #DCCCAC · Cream #FFF8EC
   Fonts: Lora (serif display) + Poppins (sans body)
══════════════════════════════════════════════════════════════ */

/* ── Reset ─────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
img { display: block; max-width: 100%; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }

/* ── Design Tokens ──────────────────────────────────────────── */
:root {
  /* Brand palette */
  --forest:   #546B41;
  --sage:     #99AD7A;
  --sand:     #DCCCAC;
  --cream:    #FFF8EC;

  /* Typography */
  --text:       #3a4b2d;
  --text-mid:   rgba(58,75,45,0.65);
  --text-faint: rgba(58,75,45,0.38);

  /* Borders / lines */
  --line:    rgba(84,107,65,0.18);
  --line-md: rgba(84,107,65,0.28);

  /* Legacy aliases — keep about-us.html working */
  --deep:    var(--forest);
  --night:   var(--text);
  --stone:   var(--cream);
  --gilt:    var(--forest);
  --bark:    var(--sage);
  --moss:    var(--sage);
  --bronze:  var(--forest);
  --line-lt: var(--line);

  /* Layout */
  --nav-h:  72px;
  --pad-x:  clamp(1.5rem, 5vw, 6rem);
  --radius: 2px;
}

/* ── Base typography ───────────────────────────────────────── */
body {
  font-family: 'Poppins', Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: 'Lora', Georgia, serif;
  font-weight: 400;
  line-height: 1.1;
  color: var(--text);
}

/* ── Utility classes ───────────────────────────────────────── */
.eyebrow {
  font-family: 'Poppins', Arial, sans-serif;
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--forest);
  margin-bottom: 1rem;
}
.eyebrow.on-dark { color: rgba(255,248,236,0.7); }

.rule {
  width: 32px;
  height: 1px;
  background: var(--sage);
  margin-bottom: 1.5rem;
}
.rule.on-dark { background: rgba(153,173,122,0.5); }

/* ── Scroll reveal ─────────────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.75s ease, transform 0.75s ease;
}
.reveal.visible {
  opacity: 1;
  transform: none;
}

/* ── Animations ────────────────────────────────────────────── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(28px); }
  to   { opacity: 1; transform: none; }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* ══════════════════════════════════════════════════════════════
   NAVIGATION
══════════════════════════════════════════════════════════════ */
.site-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--pad-x);
  background: rgba(255,248,236,0.92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
  z-index: 100;
  transition: box-shadow 0.3s ease;
}
.site-nav.scrolled {
  box-shadow: 0 2px 24px rgba(84,107,65,0.08);
}

.nav-logo {
  height: 36px;
  width: auto;
}

.nav-links {
  display: flex;
  gap: 2.8rem;
  align-items: center;
}
.nav-links a {
  font-family: 'Poppins', Arial, sans-serif;
  font-size: 0.72rem;
  font-weight: 400;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-mid);
  transition: color 0.2s ease;
  position: relative;
}
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -3px; left: 0;
  width: 0; height: 1px;
  background: var(--sage);
  transition: width 0.3s ease;
}
.nav-links a:hover { color: var(--forest); }
.nav-links a:hover::after { width: 100%; }
.nav-links a[aria-current="page"] { color: var(--forest); }
.nav-links a[aria-current="page"]::after { width: 100%; }

/* ── Companies dropdown ─────────────────── */
.nav-dropdown { position: relative; }
.nav-dropdown > a {
  display: flex;
  align-items: center;
  gap: 0.3rem;
}
.nav-dropdown > a svg {
  width: 10px; height: 10px;
  transition: transform 0.2s;
  flex-shrink: 0;
}
.nav-dropdown:hover > a svg { transform: rotate(180deg); }
/* Bridge fills the gap so cursor stays inside hover zone */
.nav-dropdown::before {
  content: '';
  position: absolute;
  top: 100%;
  left: -1rem;
  right: -1rem;
  height: 1.2rem;
  background: transparent;
}
.nav-dropdown-menu {
  position: absolute;
  top: calc(100% + 1rem);
  left: 50%;
  transform: translateX(-50%);
  background: var(--cream);
  border: 1px solid var(--line-md);
  border-radius: 4px;
  min-width: 280px;
  display: flex;
  flex-direction: column;
  box-shadow: 0 12px 40px rgba(13,18,16,0.12);
  z-index: 200;
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}
.nav-dropdown:hover .nav-dropdown-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition-delay: 0s;
}
.nav-dropdown-item {
  display: flex;
  flex-direction: column;
  padding: 1rem 1.3rem;
  border-bottom: 1px solid var(--line);
  transition: background 0.18s;
  text-decoration: none;
}
.nav-dropdown-item:last-child { border-bottom: none; }
.nav-dropdown-item:hover { background: var(--sand); }
.nav-dropdown-item:hover .nav-dropdown-label { color: var(--forest); }
.nav-dropdown-label {
  font-family: 'Poppins', Arial, sans-serif;
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--text);
  letter-spacing: 0.02em;
  transition: color 0.18s;
}
.nav-dropdown-sub {
  font-family: 'Poppins', Arial, sans-serif;
  font-size: 0.6rem;
  color: var(--text-faint);
  margin-top: 0.2rem;
  letter-spacing: 0.04em;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 1.2rem;
}

/* Lang switcher */
.lang-switcher {
  position: relative;
}
.lang-btn {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: none;
  border: 1px solid var(--line-md);
  border-radius: var(--radius);
  padding: 0.4rem 0.8rem;
  font-family: 'Poppins', Arial, sans-serif;
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  color: var(--forest);
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
}
.lang-btn:hover {
  background: rgba(84,107,65,0.06);
}
.lang-btn svg {
  width: 10px; height: 10px;
  transition: transform 0.2s;
}
.lang-btn.open svg { transform: rotate(180deg); }

.lang-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background: var(--cream);
  border: 1px solid var(--line-md);
  border-radius: var(--radius);
  padding: 0.4rem 0;
  min-width: 140px;
  box-shadow: 0 8px 32px rgba(84,107,65,0.1);
  display: none;
  z-index: 50;
}
.lang-dropdown.open { display: block; }
.lang-option {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  width: 100%;
  padding: 0.5rem 1rem;
  background: none;
  border: none;
  font-family: 'Poppins', Arial, sans-serif;
  font-size: 0.72rem;
  color: var(--text-mid);
  cursor: pointer;
  text-align: left;
  transition: background 0.15s, color 0.15s;
}
.lang-option:hover, .lang-option.active {
  background: rgba(84,107,65,0.06);
  color: var(--forest);
}
.lang-flag { font-size: 1rem; }

/* Hamburger */
.nav-hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  width: 32px;
  height: 32px;
}
.nav-hamburger span {
  display: block;
  width: 22px; height: 1.5px;
  background: var(--forest);
  transition: transform 0.3s ease, opacity 0.3s ease;
}
.nav-hamburger.open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav-hamburger.open span:nth-child(2) { opacity: 0; }
.nav-hamburger.open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* Mobile menu */
.mobile-menu {
  position: fixed;
  top: var(--nav-h); left: 0; right: 0;
  background: var(--cream);
  border-bottom: 1px solid var(--line);
  padding: 2rem var(--pad-x) 2.5rem;
  display: none;
  z-index: 99;
  box-shadow: 0 12px 40px rgba(84,107,65,0.1);
}
.mobile-menu.open { display: block; }
.mobile-menu ul { display: flex; flex-direction: column; gap: 0; }
.mobile-menu ul li a {
  display: block;
  padding: 0.85rem 0;
  font-family: 'Poppins', Arial, sans-serif;
  font-size: 0.85rem;
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-mid);
  border-bottom: 1px solid var(--line);
  transition: color 0.2s, padding-left 0.2s;
}
.mobile-menu ul li a:hover { color: var(--forest); padding-left: 0.5rem; }
.mobile-lang {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-top: 1.5rem;
}
.mobile-lang-btn {
  background: none;
  border: 1px solid var(--line-md);
  border-radius: var(--radius);
  padding: 0.35rem 0.7rem;
  font-family: 'Poppins', Arial, sans-serif;
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  color: var(--text-mid);
  cursor: pointer;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}
.mobile-lang-btn.active,
.mobile-lang-btn:hover {
  background: var(--forest);
  color: var(--cream);
  border-color: var(--forest);
}

/* ══════════════════════════════════════════════════════════════
   FOOTER
══════════════════════════════════════════════════════════════ */
.site-footer {
  background: var(--sand);
  border-top: 1px solid var(--line-md);
}

.footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 4rem;
  padding: 5rem var(--pad-x) 4rem;
}

.footer-brand img {
  height: 32px;
  width: auto;
  margin-bottom: 1.5rem;
  filter: sepia(0.3) saturate(0.8);
}

.footer-tagline {
  font-family: 'Lora', Georgia, serif;
  font-style: italic;
  font-size: 0.9rem;
  line-height: 1.7;
  color: var(--text-mid);
  max-width: 28ch;
  margin-bottom: 1.5rem;
}

.footer-address {
  font-family: 'Poppins', Arial, sans-serif;
  font-size: 0.72rem;
  line-height: 1.9;
  color: var(--text-faint);
  letter-spacing: 0.02em;
}

.footer-col-title {
  font-family: 'Poppins', Arial, sans-serif;
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--forest);
  margin-bottom: 1.4rem;
}

.footer-col ul { display: flex; flex-direction: column; gap: 0.6rem; }
.footer-col ul li a {
  font-family: 'Poppins', Arial, sans-serif;
  font-size: 0.78rem;
  color: var(--text-mid);
  transition: color 0.2s;
}
.footer-col ul li a:hover { color: var(--forest); }

.footer-contact-item {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  font-family: 'Poppins', Arial, sans-serif;
  font-size: 0.78rem;
  color: var(--text-mid);
  margin-bottom: 0.6rem;
}
.footer-contact-item svg { color: var(--sage); flex-shrink: 0; }

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem var(--pad-x);
  border-top: 1px solid var(--line);
}

.footer-copy {
  font-family: 'Poppins', Arial, sans-serif;
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  color: var(--text-faint);
}

.footer-legal {
  display: flex;
  gap: 2rem;
}
.footer-legal a {
  font-family: 'Poppins', Arial, sans-serif;
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  color: var(--text-faint);
  transition: color 0.2s;
}
.footer-legal a:hover { color: var(--forest); }

/* ══════════════════════════════════════════════════════════════
   SHARED SECTION STYLES (used across all pages)
══════════════════════════════════════════════════════════════ */

/* Generic page hero */
.page-hero {
  padding-top: var(--nav-h);
  background: var(--cream);
  min-height: 50vh;
  display: flex;
  align-items: flex-end;
  padding-bottom: 5rem;
  position: relative;
  overflow: hidden;
}

/* Leaf watermark motif — decorative */
.leaf-mark {
  position: absolute;
  pointer-events: none;
}

/* Section tag strip */
.tag-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}
.tag {
  padding: 0.4rem 1rem;
  border: 1px solid var(--line-md);
  border-radius: 100px;
  font-family: 'Poppins', Arial, sans-serif;
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--forest);
  background: transparent;
  transition: background 0.2s, color 0.2s;
}
.tag:hover {
  background: var(--forest);
  color: var(--cream);
  border-color: var(--forest);
}

/* Stat / number display */
.stat-num {
  font-family: 'Lora', Georgia, serif;
  font-size: clamp(2.8rem, 5vw, 4.5rem);
  font-weight: 400;
  color: var(--forest);
  line-height: 1;
}
.stat-label {
  font-family: 'Poppins', Arial, sans-serif;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin-top: 0.5rem;
}

/* Button styles */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: 'Poppins', Arial, sans-serif;
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 0.9rem 2rem;
  border-radius: var(--radius);
  cursor: pointer;
  transition: all 0.25s ease;
  border: 1px solid transparent;
}
.btn-primary {
  background: var(--forest);
  color: var(--cream);
  border-color: var(--forest);
}
.btn-primary:hover {
  background: #3d5230;
  border-color: #3d5230;
}
.btn-outline {
  background: transparent;
  color: var(--forest);
  border-color: var(--forest);
}
.btn-outline:hover {
  background: var(--forest);
  color: var(--cream);
}
.btn-outline-light {
  background: transparent;
  color: var(--cream);
  border-color: rgba(255,248,236,0.5);
}
.btn-outline-light:hover {
  background: rgba(255,248,236,0.12);
  border-color: var(--cream);
}
.btn svg {
  width: 14px; height: 14px;
  transition: transform 0.2s;
}
.btn:hover svg { transform: translateX(3px); }

/* ══════════════════════════════════════════════════════════════
   ABOUT-US.HTML OVERRIDES
   (re-skin dark sections to light palette)
══════════════════════════════════════════════════════════════ */

/* Origin section bg */
.about-origin {
  background: var(--cream) !important;
}
.origin-title { color: var(--text) !important; }
.origin-title em { color: var(--forest) !important; }
.origin-text { color: var(--text-mid) !important; }

/* Values — was dark, now sage-sand */
.about-values {
  background: var(--sand) !important;
}
.about-values::before {
  background-image:
    repeating-linear-gradient(0deg, transparent, transparent 59px, rgba(84,107,65,0.04) 59px, rgba(84,107,65,0.04) 60px) !important;
}
.values-title { color: var(--text) !important; }
.values-intro { color: var(--text-mid) !important; }

.value-card {
  background: rgba(255,248,236,0.7) !important;
  border-color: var(--line-md) !important;
}
.value-card:hover { background: var(--cream) !important; }
.value-card-num { color: rgba(84,107,65,0.1) !important; }
.value-icon {
  border-color: var(--line-md) !important;
  color: var(--forest) !important;
}
.value-title { color: var(--text) !important; }
.value-text { color: var(--text-mid) !important; }

/* Process — was cream (stone), stays cream */
.about-process { background: var(--cream) !important; }
.about-process::before { color: rgba(84,107,65,0.04) !important; }
.process-title { color: var(--text) !important; }
.process-intro { color: var(--text-mid) !important; }
.process-steps::before { background: var(--line) !important; }
.step-dot {
  background: var(--cream) !important;
  border-color: var(--line-md) !important;
  color: var(--sage) !important;
}
.process-step:hover .step-dot {
  background: var(--sage) !important;
  border-color: var(--sage) !important;
  color: var(--cream) !important;
}
.step-num { color: var(--sage) !important; }
.step-title { color: var(--text) !important; }
.step-text { color: var(--text-mid) !important; }

/* By-products — was dark night, now sand */
.about-byproducts { background: var(--sand) !important; }
.about-byproducts::before {
  background-image: repeating-linear-gradient(
    135deg, transparent, transparent 60px,
    rgba(84,107,65,0.03) 60px, rgba(84,107,65,0.03) 61px
  ) !important;
}
.byproducts-title { color: var(--text) !important; }
.byproducts-intro { color: var(--text-mid) !important; }

.byproduct-card {
  background: rgba(255,248,236,0.65) !important;
  border-color: var(--line-md) !important;
}
.byproduct-card:hover { background: var(--cream) !important; }
.byproduct-card::before { background: var(--sage) !important; }
.byproduct-icon {
  border-color: var(--line-md) !important;
  color: var(--forest) !important;
}
.byproduct-name { color: var(--text) !important; }
.byproduct-desc { color: var(--text-mid) !important; }
.byproduct-tag {
  border-color: var(--line-md) !important;
  color: var(--sage) !important;
}

.byproducts-quote-wrap { border-color: var(--line-md) !important; }
.byproducts-quote-label { color: var(--forest) !important; }
.byproducts-quote-text { color: var(--text) !important; }

/* Certifications — was forest moss, now sage */
.about-certs { background: var(--forest) !important; }
.about-certs::before {
  background-image: radial-gradient(ellipse 90% 70% at 50% 50%, rgba(153,173,122,0.12) 0%, transparent 70%) !important;
}
.certs-title { color: var(--cream) !important; }
.certs-body { color: rgba(255,248,236,0.72) !important; }
.cert-badge {
  background: rgba(255,248,236,0.1) !important;
  border-color: rgba(220,204,172,0.3) !important;
  color: var(--sand) !important;
}
.certs-quote {
  background: rgba(255,248,236,0.07) !important;
  border-color: rgba(220,204,172,0.2) !important;
}
.certs-quote-text { color: var(--cream) !important; }
.certs-quote-attr { color: rgba(255,248,236,0.5) !important; }

/* About hero — restyle to light */
.about-hero { background: var(--cream) !important; }
.about-hero-right { background: var(--sand) !important; }
.about-hero-right::before {
  background: linear-gradient(145deg, var(--sage) 0%, var(--forest) 100%) !important;
}
.about-hero-right::after {
  background-image: radial-gradient(circle, rgba(255,248,236,0.18) 1px, transparent 1px) !important;
}
.about-hero::after {
  background: linear-gradient(to bottom, transparent, rgba(153,173,122,0.3) 30%, rgba(153,173,122,0.3) 70%, transparent) !important;
}
.about-hero-eyebrow { color: var(--sage) !important; }
.about-hero-title { color: var(--text) !important; }
.about-hero-title em { color: var(--forest) !important; }
.about-hero-sub { color: var(--text-faint) !important; }

/* ══════════════════════════════════════════════════════════════
   RESPONSIVE — global
══════════════════════════════════════════════════════════════ */
@media (max-width: 960px) {
  .footer-top {
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
  }
  .nav-links { display: none; }
  .nav-hamburger { display: flex; }
}

@media (max-width: 640px) {
  .footer-top { grid-template-columns: 1fr; gap: 2rem; }
  .footer-bottom { flex-direction: column; gap: 1rem; text-align: center; }
}
