/* Energy Tree — corporate site */

:root {
  --bg: #eef3ef;
  --bg-elevated: #f7faf7;
  --bg-section: #e2ebe4;
  --surface: #ffffff;
  --text: #0f2419;
  --text-muted: #4d6356;
  --accent: #b86a2e;
  --accent-strong: #944f1c;
  --accent-soft: rgba(184, 106, 46, 0.12);
  --evergreen: #1a4d36;
  --evergreen-soft: rgba(26, 77, 54, 0.14);
  --line: rgba(15, 36, 25, 0.1);
  --font-display: "Sora", sans-serif;
  --font-body: "Figtree", sans-serif;
  --space: clamp(1.25rem, 4vw, 2.5rem);
  --max: 1120px;
  --header-h: 4.25rem;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0;
}

p {
  margin: 0;
}

ul, ol, dl {
  margin: 0;
  padding: 0;
  list-style: none;
}

/* Header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  border-bottom: 1px solid transparent;
  background: rgba(238, 243, 239, 0.78);
  backdrop-filter: blur(14px);
  transition: border-color 0.3s var(--ease), background 0.3s var(--ease);
}

.site-header.is-scrolled {
  border-bottom-color: var(--line);
  background: rgba(247, 250, 247, 0.94);
}

.header-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--space);
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.logo {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: -0.03em;
  color: var(--evergreen);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 1.75rem;
}

.site-nav a {
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--text-muted);
  transition: color 0.2s ease;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  color: var(--text);
}

.nav-cta {
  color: #ffffff !important;
  background: var(--accent);
  padding: 0.45rem 0.95rem;
  border-radius: 2px;
  font-weight: 600 !important;
}

.nav-cta:hover,
.nav-cta:focus-visible {
  background: var(--accent-strong);
  color: #ffffff !important;
}

.nav-toggle {
  display: none;
  width: 2.5rem;
  height: 2.5rem;
  border: 0;
  background: transparent;
  padding: 0;
  cursor: pointer;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
}

.nav-toggle span {
  display: block;
  width: 1.35rem;
  height: 2px;
  background: var(--text);
  margin-inline: auto;
  transition: transform 0.25s var(--ease), opacity 0.2s ease;
}

.nav-toggle[aria-expanded="true"] span:first-child {
  transform: translateY(4px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:last-child {
  transform: translateY(-4px) rotate(-45deg);
}

/* Hero — one composition, brand-first, full-bleed */

.hero {
  position: relative;
  min-height: calc(100svh - var(--header-h));
  display: grid;
  align-items: end;
  overflow: hidden;
  isolation: isolate;
}

.hero-atmosphere {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(ellipse 75% 55% at 72% 18%, rgba(26, 77, 54, 0.18), transparent 55%),
    radial-gradient(ellipse 45% 40% at 12% 78%, rgba(184, 106, 46, 0.14), transparent 50%),
    linear-gradient(168deg, #e6efe8 0%, #f4f8f4 48%, #eef3ef 100%);
}

.hero-canopy {
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(ellipse 18px 10px at 20% 15%, rgba(26, 77, 54, 0.08), transparent 70%),
    radial-gradient(ellipse 22px 12px at 55% 8%, rgba(26, 77, 54, 0.07), transparent 70%),
    radial-gradient(ellipse 16px 9px at 80% 22%, rgba(26, 77, 54, 0.09), transparent 70%),
    linear-gradient(rgba(15, 36, 25, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(15, 36, 25, 0.05) 1px, transparent 1px);
  background-size: auto, auto, auto, 72px 72px, 72px 72px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.5), transparent 88%);
  animation: canopy-drift 32s linear infinite;
}

.hero-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
}

.hero-glow--a {
  width: min(50vw, 420px);
  height: min(50vw, 420px);
  right: 6%;
  top: 10%;
  background: rgba(26, 77, 54, 0.28);
  animation: pulse-glow 8s ease-in-out infinite;
}

.hero-glow--b {
  width: min(38vw, 300px);
  height: min(38vw, 300px);
  left: 4%;
  bottom: 16%;
  background: rgba(184, 106, 46, 0.22);
  animation: pulse-glow 10s ease-in-out infinite reverse;
}

.hero-trunk {
  position: absolute;
  right: max(0px, calc((100% - var(--max)) / 2 - 1.5rem));
  top: 10%;
  bottom: 16%;
  width: min(40vw, 420px);
  border: 1px solid rgba(26, 77, 54, 0.25);
  background:
    linear-gradient(155deg, rgba(26, 77, 54, 0.12), transparent 42%),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.65), rgba(226, 235, 228, 0.4));
  clip-path: polygon(18% 0, 100% 0, 100% 82%, 78% 100%, 0 100%, 0 18%);
  box-shadow: inset 0 0 80px rgba(26, 77, 54, 0.06);
}

.hero-trunk::after {
  content: "";
  position: absolute;
  inset: 14% 16%;
  border: 1px solid rgba(15, 36, 25, 0.08);
  background:
    repeating-linear-gradient(
      -22deg,
      transparent,
      transparent 20px,
      rgba(184, 106, 46, 0.1) 20px,
      rgba(184, 106, 46, 0.1) 21px
    );
}

.hero-content {
  max-width: var(--max);
  width: 100%;
  margin: 0 auto;
  padding: clamp(3rem, 10vh, 6rem) var(--space) clamp(3.5rem, 12vh, 7rem);
}

.brand {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.85rem, 5.2vw, 3.6rem);
  letter-spacing: -0.04em;
  line-height: 1.05;
  max-width: 18ch;
  margin-bottom: 1.25rem;
  color: var(--evergreen);
  animation: hero-in 0.9s var(--ease) both;
}

.hero-headline {
  max-width: 18ch;
  font-size: clamp(1.55rem, 3.4vw, 2.35rem);
  font-weight: 600;
  color: var(--text);
  margin-bottom: 1rem;
  animation: hero-in 0.9s var(--ease) 0.12s both;
}

.hero-lead {
  max-width: 38ch;
  color: var(--text-muted);
  font-size: clamp(1rem, 2vw, 1.15rem);
  margin-bottom: 2rem;
  animation: hero-in 0.9s var(--ease) 0.22s both;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  animation: hero-in 0.9s var(--ease) 0.32s both;
}

/* Buttons */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 1.35rem;
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: 2px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.2s var(--ease), background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn:active {
  transform: translateY(0);
}

.btn-primary {
  background: var(--accent);
  color: #ffffff;
}

.btn-primary:hover,
.btn-primary:focus-visible {
  background: var(--accent-strong);
}

.btn-ghost {
  background: transparent;
  border-color: var(--line);
  color: var(--text);
}

.btn-ghost:hover,
.btn-ghost:focus-visible {
  border-color: var(--evergreen);
  color: var(--evergreen);
}

/* Sections */

.section {
  padding: clamp(4.5rem, 12vw, 7.5rem) 0;
  border-top: 1px solid var(--line);
}

.section-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--space);
}

.section-head {
  max-width: 38rem;
  margin-bottom: clamp(2.5rem, 6vw, 3.5rem);
}

.eyebrow {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.85rem;
}

.section-head h2,
.about-layout h2 {
  font-size: clamp(1.85rem, 4vw, 2.75rem);
  margin-bottom: 1rem;
  color: var(--evergreen);
}

.section-lead {
  color: var(--text-muted);
  font-size: 1.05rem;
}

/* Products — image + copy features */

.product-feature {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: center;
  padding: clamp(2rem, 5vw, 3rem) 0;
  border-top: 1px solid var(--line);
}

.product-feature:last-child {
  border-bottom: 1px solid var(--line);
}

.product-feature--reverse .product-feature-media {
  order: 2;
}

.product-feature--reverse .product-feature-body {
  order: 1;
}

.product-feature-media {
  margin: 0;
  overflow: hidden;
  border-radius: 2px;
  aspect-ratio: 4 / 3;
  background: var(--bg-section);
  border: 1px solid var(--line);
}

.product-feature-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform 0.6s var(--ease);
}

.product-feature:hover .product-feature-media img {
  transform: scale(1.02);
}

.product-code {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1rem;
  color: var(--accent);
  margin-bottom: 0.65rem;
}

.product-feature-body h3 {
  font-size: clamp(1.4rem, 2.5vw, 1.85rem);
  color: var(--evergreen);
  margin-bottom: 0.75rem;
}

.product-feature-lead {
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  max-width: 40rem;
}

.feature-points {
  display: grid;
  gap: 0.65rem;
  margin-bottom: 1.25rem;
}

.feature-points li {
  color: var(--text-muted);
  padding-left: 0.9rem;
  border-left: 2px solid var(--accent-soft);
  font-size: 0.98rem;
}

.feature-points strong {
  color: var(--text);
  font-weight: 600;
}

.series-note {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.55;
  max-width: 40rem;
}

.series-note strong {
  color: var(--evergreen);
}

/* Applications — horizontal rail */

.applications {
  background: var(--bg-section);
}

.solution-rail {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  border-top: 1px solid var(--line);
}

.solution-rail li {
  padding: 1.75rem 1.25rem 1.75rem 0;
  border-bottom: 1px solid var(--line);
  border-right: 1px solid var(--line);
  padding-right: 1.5rem;
  margin-right: 1.5rem;
}

.solution-rail li:last-child {
  border-right: 0;
  margin-right: 0;
  padding-right: 0;
}

.solution-rail h3 {
  font-size: 1.15rem;
  margin-bottom: 0.65rem;
  color: var(--evergreen);
}

.solution-rail p {
  color: var(--text-muted);
  font-size: 0.98rem;
}

/* Capabilities */

.capabilities {
  background:
    radial-gradient(ellipse 60% 50% at 100% 0%, var(--evergreen-soft), transparent 55%),
    var(--bg);
}

.tech-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 6vw, 4rem);
  align-items: start;
}

.tech-layout .section-head {
  margin-bottom: 0;
}

.tech-points {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
  border-left: 1px solid var(--line);
  padding-left: clamp(1.5rem, 4vw, 2.5rem);
}

.tech-points dt {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  margin-bottom: 0.4rem;
  color: var(--evergreen);
}

.tech-points dd {
  color: var(--text-muted);
  margin: 0;
}

/* About */

.about {
  background: var(--bg-elevated);
}

.about-layout {
  max-width: 40rem;
}

.about-copy {
  color: var(--text-muted);
  font-size: 1.1rem;
  line-height: 1.7;
}

/* Contact */

.contact-layout {
  max-width: 40rem;
}

.contact-layout .section-head {
  margin-bottom: 0;
}

.contact-details {
  margin-top: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
}

.contact-details p {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.contact-label {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}

.contact-details a {
  color: var(--text);
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 0.2em;
  text-decoration-color: rgba(184, 106, 46, 0.4);
  transition: color 0.2s ease, text-decoration-color 0.2s ease;
}

.contact-details a:hover,
.contact-details a:focus-visible {
  color: var(--accent-strong);
  text-decoration-color: var(--accent);
}

.contact-address {
  color: var(--text-muted);
  max-width: 36rem;
  line-height: 1.55;
}

/* Footer */

.site-footer {
  border-top: 1px solid var(--line);
  padding: 2.5rem 0 3rem;
  background: var(--bg);
}

.footer-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--space);
  display: grid;
  gap: 1.5rem;
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
}

.footer-nav a {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.footer-nav a:hover {
  color: var(--text);
}

.footer-contact {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.55;
  max-width: 42rem;
}

.footer-contact a {
  color: var(--text);
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 0.2em;
  text-decoration-color: rgba(184, 106, 46, 0.4);
}

.footer-contact a:hover,
.footer-contact a:focus-visible {
  color: var(--accent-strong);
}

.footer-sep {
  margin: 0 0.5rem;
  opacity: 0.5;
}

.footer-meta {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* Motion */

@keyframes hero-in {
  from {
    opacity: 0;
    transform: translateY(28px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes canopy-drift {
  from { background-position: 0 0, 0 0, 0 0, 0 0, 0 0; }
  to { background-position: 12px -8px, -10px 6px, 8px 10px, 72px 72px, 72px 72px; }
}

@keyframes pulse-glow {
  0%, 100% { opacity: 0.7; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.08); }
}

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .brand,
  .hero-headline,
  .hero-lead,
  .hero-actions,
  .reveal {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
  .hero-canopy,
  .hero-glow {
    animation: none !important;
  }
  .product-feature-media img {
    transition: none !important;
  }
  .product-feature:hover .product-feature-media img {
    transform: none !important;
  }
}

/* Responsive */

@media (max-width: 900px) {
  .hero-trunk {
    opacity: 0.45;
    width: min(55vw, 300px);
    top: 8%;
    bottom: 40%;
  }

  .product-feature,
  .product-feature--reverse {
    grid-template-columns: 1fr;
  }

  .product-feature--reverse .product-feature-media,
  .product-feature--reverse .product-feature-body {
    order: unset;
  }

  .solution-rail {
    grid-template-columns: 1fr 1fr;
  }

  .solution-rail li:nth-child(2n) {
    border-right: 0;
    margin-right: 0;
    padding-right: 0;
  }

  .tech-layout {
    grid-template-columns: 1fr;
  }

  .tech-points {
    border-left: 0;
    border-top: 1px solid var(--line);
    padding-left: 0;
    padding-top: 1.75rem;
  }
}

@media (max-width: 720px) {
  .nav-toggle {
    display: flex;
  }

  .site-nav {
    position: fixed;
    inset: var(--header-h) 0 auto 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 0.5rem var(--space) 1.25rem;
    background: rgba(247, 250, 247, 0.98);
    border-bottom: 1px solid var(--line);
    transform: translateY(-120%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.35s var(--ease), opacity 0.25s ease;
  }

  .site-nav.is-open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .site-nav a {
    padding: 0.85rem 0;
    border-bottom: 1px solid var(--line);
  }

  .nav-cta {
    margin-top: 0.75rem;
    text-align: center;
    border-bottom: 0 !important;
  }

  .solution-rail {
    grid-template-columns: 1fr;
  }

  .solution-rail li {
    border-right: 0;
    margin-right: 0;
    padding-right: 0;
  }

  .hero-trunk {
    display: none;
  }

  .brand {
    max-width: none;
  }
}
