/* ============================================================
   ALLOCRA — Shared Stylesheet v2
   ============================================================ */

:root {
  --green-deep: #1B5E20;
  --green-mid: #2E7D32;
  --green-light: #4CAF50;
  --green-pale: #E8F5E9;
  --teal: #00897B;
  --teal-light: #4DB6AC;
  --teal-pale: #E0F2F1;
  --amber: #FF8F00;
  --amber-light: #FFB300;
  --amber-pale: #FFF8E1;
  --dark: #0D1B0E;
  --gray-900: #1A2E1B;
  --gray-700: #37474F;
  --gray-500: #78909C;
  --gray-300: #CFD8DC;
  --gray-200: #E8ECED;
  --gray-100: #F5F7F5;
  --white: #FFFFFF;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.10);
  --shadow-xl: 0 16px 48px rgba(0,0,0,0.12);
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--dark);
  background: var(--white);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---- NAVIGATION ---- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(0,0,0,0.06);
  transition: all 0.3s ease;
}
.nav.scrolled { box-shadow: var(--shadow-sm); }
.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-logo { display: inline-flex; align-items: center; }
.nav-logo svg,
.nav-logo img { display: block; height: 32px; width: auto; }
.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}
.nav-links a {
  font-size: 14px;
  font-weight: 500;
  color: var(--gray-700);
  transition: color 0.15s;
}
.nav-links a:hover { color: var(--green-deep); }
.nav-cta {
  display: inline-flex;
  align-items: center;
  padding: 10px 22px;
  background: var(--green-deep);
  color: var(--white) !important;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 14px;
  transition: background 0.15s;
}
.nav-cta:hover { background: var(--green-mid) !important; }
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  width: 32px; height: 32px;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
}
.nav-toggle span {
  display: block; width: 22px; height: 2px;
  background: var(--dark); border-radius: 2px; transition: all 0.3s;
}

/* ---- BUTTONS ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 32px;
  border-radius: var(--radius-sm);
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 15px;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
}
.btn-amber {
  background: var(--amber);
  color: var(--white);
  box-shadow: 0 4px 16px rgba(255,143,0,0.3);
}
.btn-amber:hover {
  background: var(--amber-light);
  transform: translateY(-1px);
  box-shadow: 0 6px 24px rgba(255,143,0,0.35);
}
.btn-outline-white {
  background: transparent;
  color: var(--white);
  border: 1.5px solid rgba(255,255,255,0.25);
}
.btn-outline-white:hover {
  background: rgba(255,255,255,0.06);
  border-color: rgba(255,255,255,0.4);
}
.btn-green {
  background: var(--green-deep);
  color: var(--white);
}
.btn-green:hover {
  background: var(--green-mid);
  transform: translateY(-1px);
  box-shadow: 0 6px 24px rgba(27,94,32,0.25);
}
.btn-teal {
  background: var(--teal);
  color: var(--white);
}
.btn-teal:hover {
  background: var(--teal-light);
  transform: translateY(-1px);
}
.btn-outline-green {
  background: transparent;
  color: var(--green-deep);
  border: 2px solid var(--green-deep);
}
.btn-outline-green:hover {
  background: var(--green-pale);
}

/* ---- SECTION HEADERS ---- */
.section-tag {
  display: inline-block;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 2.5px;
  font-weight: 700;
  color: var(--teal);
  margin-bottom: 16px;
}

/* ---- FOOTER ---- */
.footer {
  background: var(--dark);
  color: rgba(255,255,255,0.72);
  padding: 64px 0 32px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}
.footer-brand p {
  font-size: 14px;
  line-height: 1.7;
  margin-top: 16px;
  max-width: 300px;
}
.footer-col h4 {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-weight: 700;
  color: rgba(255,255,255,0.85);
  margin-bottom: 20px;
}
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 10px; }
.footer-col a {
  font-size: 14px;
  color: rgba(255,255,255,0.78);
  transition: color 0.15s;
}
.footer-col a:hover { color: var(--teal-light); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
}
.footer-legal { display: flex; gap: 24px; }
.footer-legal a { transition: color 0.15s; }
.footer-legal a:hover { color: var(--teal-light); }

/* ---- VORONOI PATTERN TREATMENTS ---- */
/* A decorative panel that carries the Allocra Voronoi tile as a subtle background */
.voronoi-bg {
  position: relative;
  overflow: hidden;
}
.voronoi-bg::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url('assets/allocra-voronoi-pattern.svg');
  background-size: 560px 560px;
  background-position: right -80px top -80px;
  background-repeat: no-repeat;
  opacity: 0.9;
  pointer-events: none;
  z-index: 0;
}
.voronoi-bg > * { position: relative; z-index: 1; }

/* Dark variant — for hero sections on dark backgrounds */
.voronoi-bg-dark::before {
  background-image: url('assets/allocra-voronoi-dark.svg');
  opacity: 0.18;
  mix-blend-mode: screen;
}

/* A small accent tile used as a corner flourish on cards or sections */
.voronoi-accent {
  position: absolute;
  width: 220px;
  height: 220px;
  background-image: url('assets/allocra-voronoi-accent.svg');
  background-size: contain;
  background-repeat: no-repeat;
  opacity: 0.25;
  pointer-events: none;
}
.voronoi-accent.top-right    { top: -30px;   right: -30px; }
.voronoi-accent.top-left     { top: -30px;   left:  -30px;  transform: scaleX(-1); }
.voronoi-accent.bottom-right { bottom:-30px; right: -30px;  transform: scaleY(-1); }
.voronoi-accent.bottom-left  { bottom:-30px; left:  -30px;  transform: scale(-1,-1); }

/* A thin divider made of voronoi edges */
.voronoi-divider {
  height: 2px;
  background: linear-gradient(90deg,
    transparent,
    rgba(27,94,32,0.18) 20%,
    rgba(0,137,123,0.28) 50%,
    rgba(255,143,0,0.22) 80%,
    transparent);
  margin: 0;
}

/* ---- PRODUCT ICON UTILITIES ---- */
.product-icon {
  display: block;
  border-radius: 22%;
  box-shadow: 0 10px 28px -12px rgba(0,0,0,0.28);
}
.product-icon-lg { width: 120px; height: 120px; border-radius: 26px; }
.product-icon-md { width: 72px;  height: 72px;  border-radius: 16px; }
.product-icon-sm { width: 48px;  height: 48px;  border-radius: 11px; }

/* ---- ANIMATIONS ----
   Default: everything is fully visible. The scroll fade-in is purely
   a desktop-only enhancement — it's added back via the media query
   below. This inversion avoids the brief "blank" flash on mobile
   where the user could see opacity:0 elements during page paint
   before the override kicked in. */
.fade-in {
  opacity: 1;
  transform: none;
}
.fade-in.visible {
  opacity: 1;
  transform: none;
}
/* Desktop with motion enabled: opt INTO the staggered fade-in entrance. */
@media (min-width: 769px) and (prefers-reduced-motion: no-preference) {
  .fade-in {
    opacity: 0;
    transform: translateY(24px);
    transition: all 0.6s cubic-bezier(0.22, 1, 0.36, 1);
  }
  .fade-in.visible {
    opacity: 1;
    transform: translateY(0);
  }
}
/* ---- RESPONSIVE ---- */
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .container { padding: 0 20px; }
  .nav-links { display: none; }
  .nav-toggle { display: flex; }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 64px; left: 0; right: 0;
    background: var(--white);
    padding: 24px 20px;
    gap: 16px;
    border-bottom: 1px solid var(--gray-200);
    box-shadow: var(--shadow-md);
  }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; gap: 12px; text-align: center; }
}
