/* ---- Reset & base ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --black: #0b0f0d;
  --black-soft: #101512;
  --green: #16a34a;
  --green-dark: #0e7a37;
  --green-bright: #22c55e;
  --white: #ffffff;
  --gray-100: #f4f6f5;
  --gray-300: #d1d7d4;
  --gray-500: #8a938e;
  --gray-700: #4b544f;
  --text-heading: #0b0f0d;
  --text-body: #4b544f;
  --text-light: #d1d7d4;
  --navbar-bg: #0b0f0d;
  --navbar-text: #ffffff;
  --font-family: "Jost", "Segoe UI", Roboto, -apple-system, BlinkMacSystemFont, Arial, sans-serif;
  --font-weight-base: 400;
  --size-h1: 3.2rem;
  --weight-h1: 700;
  --size-h2: 2.1rem;
  --weight-h2: 700;
  --size-subtitle: 1.05rem;
  --weight-subtitle: 400;
  --size-body: .95rem;
  --weight-body: 400;
  --size-menu: .95rem;
  --weight-menu: 400;
  --size-small: .85rem;
  --weight-small: 700;
  --size-btn: .95rem;
  --weight-btn: 600;
  --header-h: 64px;
  --radius: 10px;
  --max-w: 1200px;
  font-size: 16px;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-family);
  font-weight: var(--font-weight-base);
  color: var(--black);
  background: var(--white);
  line-height: 1.5;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { font: inherit; background: none; border: none; cursor: pointer; color: inherit; }

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--green);
  color: var(--white);
  padding: 10px 16px;
  z-index: 1000;
}
.skip-link:focus { left: 8px; top: 8px; }

/* ---- Header ---- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 500;
  background: var(--navbar-bg);
  height: var(--header-h);
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.site-header.is-not-sticky { position: relative; }

.header-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
}
.site-header.menu-align-left .header-inner { flex-direction: row-reverse; }

.logo { display: flex; align-items: center; gap: 10px; color: var(--navbar-text); }
.logo-default { display: flex; align-items: center; gap: 10px; }
.logo-mark {
  width: 26px; height: 26px;
  border-radius: 6px;
  background: linear-gradient(135deg, var(--green-bright), var(--green-dark));
  display: inline-block;
}
.logo-text { font-weight: 700; font-size: 1.15rem; letter-spacing: .3px; }
.logo-img { height: 32px; width: auto; display: block; }

.nav-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  z-index: 600;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--navbar-text);
  transition: transform .25s ease, opacity .25s ease;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.main-nav {
  position: fixed;
  top: var(--header-h);
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--navbar-bg);
  transform: translateX(100%);
  transition: transform .3s ease;
  overflow-y: auto;
  padding: 10px 20px 40px;
}
.main-nav.open { transform: translateX(0); }

.nav-list { display: flex; flex-direction: column; }
.nav-item { border-bottom: 1px solid rgba(255,255,255,.08); }
.nav-link {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 16px 4px;
  color: var(--navbar-text);
  font-size: var(--size-menu);
  font-weight: var(--weight-menu);
  text-align: left;
}
.nav-link .chev { margin-left: auto; }

.nav-icon { flex-shrink: 0; display: none; }
.main-nav.show-icons .nav-icon { display: inline-flex; }

.chev {
  width: 9px; height: 9px;
  border-right: 2px solid var(--gray-300);
  border-bottom: 2px solid var(--gray-300);
  transform: rotate(45deg);
  transition: transform .25s ease;
  flex-shrink: 0;
}
.submenu-toggle[aria-expanded="true"] .chev { transform: rotate(-135deg); }

.submenu {
  max-height: 0;
  overflow: hidden;
  transition: max-height .3s ease;
}
.has-submenu.open .submenu { max-height: 400px; }
.submenu ul { padding: 0 4px 12px 12px; }
.submenu a {
  display: block;
  padding: 10px 0;
  color: var(--gray-300);
  font-size: .95rem;
  border-left: 2px solid var(--green);
  padding-left: 12px;
}
.submenu a:hover { color: var(--green-bright); }

.nav-cta { margin-top: 20px; display: flex; align-items: center; gap: 10px; }

.btn-admin-access {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.3);
  color: var(--gray-300);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color .2s ease, color .2s ease;
}
.btn-admin-access:hover { border-color: var(--green-bright); color: var(--green-bright); }

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 999px;
  font-weight: var(--weight-btn);
  font-size: var(--size-btn);
  transition: background .2s ease, color .2s ease, border-color .2s ease;
  white-space: nowrap;
}
.btn-primary { background: var(--green); color: var(--white); }
.btn-primary:hover { background: var(--green-dark); }
.btn-ghost { border: 1px solid var(--black); color: var(--black); }
.btn-ghost:hover { background: var(--black); color: var(--white); }
.btn-text-only { padding: 0; border: none; background: transparent; }
.btn-text-only:hover { text-decoration: underline; }
.btn-icon { display: inline-flex; }
.btn-icon svg { display: block; }
.btn-outline-light { border: 1px solid rgba(255,255,255,.4); color: var(--white); width: 100%; }
.btn-outline-light:hover { background: var(--white); color: var(--black); }

/* ---- Hero ---- */
.hero {
  position: relative;
  overflow: hidden;
  background: radial-gradient(120% 100% at 100% 0%, #123321 0%, var(--black) 55%);
  color: var(--hero-text, var(--white));
  padding: 32px 20px;
  display: flex;
  align-items: center;
}

.hero.is-sticky {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1;
}
.hero.is-sticky ~ .hero,
.hero.is-sticky ~ .stats,
.hero.is-sticky ~ .section,
.hero.is-sticky ~ .cta-banner {
  position: relative;
  z-index: 2;
}

.hero-media {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}
.hero-media video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hero-media iframe {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 177.77vh;   /* 16:9 cover trick */
  height: 56.25vw;
  min-width: 100%;
  min-height: 100%;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.hero-inner {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 32px;
}
.hero-inner.has-side-image { align-items: center; }

.hero-text { min-width: 0; }

.hero-side-image { display: none; order: 1; }
.hero-side-image.is-visible { display: block; width: 100%; max-width: var(--hero-side-image-size-mobile, 60%); margin: 0 auto; }
.hero-inner.image-mobile-above .hero-side-image { order: -1; }
.hero-side-image img {
  width: 100%;
  border-radius: var(--radius);
  display: block;
}

.eyebrow {
  color: var(--green-bright);
  font-weight: var(--weight-small);
  font-size: var(--size-small);
  text-transform: uppercase;
  letter-spacing: 1.2px;
  margin-bottom: 14px;
}
.hero h1 {
  font-size: min(var(--size-h1), 14vw);
  line-height: 1.15;
  font-weight: var(--weight-h1);
  max-width: 16ch;
  margin-bottom: 18px;
  color: inherit;
}
.hero-sub {
  color: inherit;
  opacity: .85;
  font-size: var(--size-subtitle);
  font-weight: var(--weight-subtitle);
  max-width: 46ch;
  margin-bottom: 28px;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-actions .btn-ghost { border-color: rgba(255,255,255,.5); color: inherit; }
.hero-actions .btn-ghost:hover { background: var(--white); color: var(--black); }

/* ---- Stats ---- */
.stats { background: var(--black-soft); padding: 32px 20px; }
.stats-grid {
  max-width: var(--max-w);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}
.stat { text-align: center; color: var(--white); }
.stat-number {
  display: block;
  font-size: clamp(1.6rem, 5vw, 2.4rem);
  font-weight: 700;
  color: var(--green-bright);
}
.stat-label { font-size: var(--size-small); font-weight: var(--weight-small); color: var(--text-light); }

/* ---- Sections ---- */
.section { background: var(--white); padding: 56px 20px; }
.section > * { max-width: var(--max-w); margin-left: auto; margin-right: auto; }
.section-head { margin-bottom: 28px; }
.section-head h2 { font-size: min(var(--size-h2), 10vw); font-weight: var(--weight-h2); color: var(--text-heading); }
.section-head .section-sub { margin-top: 10px; font-size: var(--size-subtitle); font-weight: var(--weight-subtitle); color: var(--text-body); }
.section .eyebrow { color: var(--green-dark); }

/* ---- Cards / Services ---- */
.card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
}
.card {
  display: flex;
  flex-direction: column;
  background: var(--cuadro-card-bg, var(--white));
  border: 1px solid var(--gray-300);
  border-radius: 18px;
  padding: 28px;
  transition: border-color .2s ease, transform .2s ease, box-shadow .2s ease;
}
.card:hover {
  border-color: var(--green);
  transform: translateY(-3px);
  box-shadow: 0 16px 32px rgba(11, 15, 13, .08);
}
.card-icon {
  width: 42px; height: 42px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--green-bright), var(--green-dark));
  margin-bottom: 16px;
}
.card h3 { font-size: 1.2rem; font-weight: 600; line-height: 1.3; margin-bottom: 10px; color: var(--text-heading); }
.card p { color: var(--text-body); font-size: var(--size-body); font-weight: var(--weight-body); line-height: 1.65; margin-bottom: 18px; }
.card-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--green-dark);
  font-weight: 600;
  font-size: .9rem;
  margin-top: auto;
  transition: gap .2s ease;
}
.card-link:hover { gap: 10px; }

.cuadro-title-row { display: flex; align-items: center; gap: 10px; order: -3; margin-bottom: 10px; }
.cuadro-title-row h3 { margin-bottom: 0; }
.cuadro-icon, .cuadro-icon-svg { width: var(--cuadro-icon-size, 28px); height: var(--cuadro-icon-size, 28px); object-fit: contain; order: -1; flex-shrink: 0; color: var(--cuadro-icon-color, var(--green-dark)); }
.cuadro-icon-svg svg { width: 100%; height: 100%; stroke-width: var(--cuadro-icon-weight, 2); }
.cuadro-title-row.icon-after .cuadro-icon,
.cuadro-title-row.icon-after .cuadro-icon-svg { order: 1; }

.cuadro-image {
  width: 100%;
  aspect-ratio: 16 / 11;
  object-fit: cover;
  border-radius: 14px;
  display: block;
  background: var(--gray-100);
  order: -2;
  margin-bottom: 18px;
}
.card.image-below .cuadro-image { order: 2; margin-bottom: 0; margin-top: 18px; }

/* ---- Industries (horizontal scroll on mobile) ---- */
.industry-scroll {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  padding-bottom: 8px;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}
.industry-scroll::-webkit-scrollbar { display: none; }
.industry-card {
  flex: 0 0 62%;
  scroll-snap-align: start;
  height: 140px;
  border-radius: var(--radius);
  background: linear-gradient(160deg, var(--black-soft), var(--black));
  display: flex;
  align-items: flex-end;
  padding: 16px;
}
.industry-card span { color: var(--white); font-weight: 600; font-size: 1.05rem; }

/* ---- Insights ---- */
.insight-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}
.insight-thumb {
  height: 160px;
  border-radius: var(--radius);
  background: linear-gradient(135deg, #e8f5ec, #cdeeda);
  margin-bottom: 14px;
}
.insight-tag {
  color: var(--green-dark);
  font-weight: 700;
  font-size: .78rem;
  text-transform: uppercase;
  letter-spacing: .6px;
  margin-bottom: 6px;
}
.insight-card h3 { font-size: 1.05rem; line-height: 1.4; color: var(--text-heading); }

/* ---- CTA banner ---- */
.cta-banner {
  background: linear-gradient(135deg, var(--green-dark), var(--black));
  color: var(--white);
  padding: 56px 20px;
  text-align: center;
}
.cta-inner { max-width: 560px; margin: 0 auto; }
.cta-inner h2 { font-size: min(var(--size-h2), 10vw); font-weight: var(--weight-h2); margin-bottom: 12px; }
.cta-inner p { color: var(--text-light); margin-bottom: 24px; }

/* ---- Footer ---- */
.site-footer { background: var(--black); color: var(--white); padding: 40px 20px 24px; }
.footer-top { max-width: var(--max-w); margin: 0 auto 24px; }
.footer-brand { display: flex; align-items: center; gap: 10px; }

.footer-columns { max-width: var(--max-w); margin: 0 auto; }
.footer-col { border-top: 1px solid rgba(255,255,255,.1); }
.footer-col-toggle {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 0;
  color: var(--white);
  font-weight: 600;
}
.footer-col-toggle::after {
  content: "+";
  font-size: 1.2rem;
  color: var(--green-bright);
}
.footer-col-toggle[aria-expanded="true"]::after { content: "–"; }
.footer-col ul {
  max-height: 0;
  overflow: hidden;
  transition: max-height .3s ease;
}
.footer-col.open ul { max-height: 300px; padding-bottom: 12px; }
.footer-col ul li a {
  display: block;
  padding: 8px 0;
  color: var(--gray-300);
  font-size: .92rem;
}
.footer-col ul li a:hover { color: var(--green-bright); }

.footer-bottom {
  max-width: var(--max-w);
  margin: 24px auto 0;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,.1);
  display: flex;
  flex-direction: column;
  gap: 16px;
  color: var(--gray-500);
  font-size: .82rem;
}
.footer-social { display: flex; gap: 14px; }
.footer-social a {
  width: 32px; height: 32px;
  border: 1px solid rgba(255,255,255,.2);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: .8rem;
  color: var(--gray-300);
}
.footer-social a:hover { border-color: var(--green); color: var(--green-bright); }

/* =========================================================
   Tablet / Desktop (mobile-first breakpoints)
   ========================================================= */
@media (min-width: 640px) {
  .stats-grid { grid-template-columns: repeat(4, 1fr); }
  .card-grid { grid-template-columns: repeat(2, 1fr); }
  .insight-grid { grid-template-columns: repeat(2, 1fr); }
  .industry-card { flex: 0 0 38%; }

  .hero-inner.has-side-image {
    flex-direction: row;
    align-items: center;
    gap: 56px;
    text-align: left;
  }
  .hero-inner.has-side-image .hero-text { flex: 1; min-width: 0; }
  .hero-inner.has-side-image .hero-side-image.is-visible { flex: 0 0 auto; max-width: var(--hero-side-image-size-desktop, 45%); }
  .hero-inner.image-desktop-left .hero-side-image { order: -1; }
}

@media (min-width: 960px) {
  :root { --header-h: 76px; }

  .header-inner { padding: 0 40px; }
  .nav-toggle { display: none; }

  .main-nav {
    position: static;
    transform: none;
    background: transparent;
    padding: 0;
    overflow: visible;
    display: flex;
    align-items: center;
    gap: 28px;
    flex: 1;
    justify-content: flex-end;
  }

  .nav-list {
    flex-direction: row;
    align-items: center;
    gap: 4px;
  }
  .nav-item { border-bottom: none; position: relative; }
  .nav-link { padding: 10px 14px; font-size: .95rem; white-space: nowrap; }
  .nav-link:hover { color: var(--green-bright); }

  .submenu {
    position: absolute;
    top: 100%;
    left: 0;
    max-height: none;
    height: 0;
    opacity: 0;
    visibility: hidden;
    background: var(--black-soft);
    border-radius: var(--radius);
    min-width: 240px;
    padding: 8px 0;
    box-shadow: 0 12px 24px rgba(0,0,0,.35);
    transition: opacity .2s ease;
  }
  .has-submenu:hover .submenu,
  .has-submenu.open .submenu {
    height: auto;
    opacity: 1;
    visibility: visible;
  }
  .submenu ul { padding: 4px 8px; }
  .submenu a { border-left: none; padding-left: 12px; }

  .nav-cta { margin-top: 0; }
  .btn-outline-light { width: auto; }

  .hero { padding: 48px 40px; }
  .hero-inner { display: flex; flex-direction: column; }
  .hero h1 { max-width: 20ch; }

  .section { padding: 80px 40px; }
  .card-grid { grid-template-columns: repeat(3, 1fr); }
  .insight-grid { grid-template-columns: repeat(3, 1fr); }
  .industry-card { flex: 0 0 24%; }

  .footer-columns { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
  .footer-col { border-top: none; }
  .footer-col-toggle { pointer-events: none; padding: 0 0 12px; }
  .footer-col-toggle::after { display: none; }
  .footer-col ul { max-height: none; overflow: visible; }
  .footer-col ul li a { padding: 6px 0; }
  .footer-bottom { flex-direction: row; justify-content: space-between; align-items: center; }
}
