/* ===========================================================
   SES — Solar Energy Structure
   Design tokens
   =========================================================== */
:root{
  --pine:        #0f3b33;   /* primary deep green, from logo */
  --pine-700:    #0c2f29;
  --pine-900:    #081e1a;
  --teal:        #2cb4a9;   /* accent, from logo mark */
  --teal-700:    #1f8f86;
  --paper:       #fbfaf6;   /* warm off-white background */
  --paper-dim:   #f1efe7;   /* alternate section tint */
  --line:        #dfdccf;   /* hairline / divider */
  --ink:         #14201d;   /* body text */
  --ink-soft:    #3c4a46;   /* secondary text — darkened for contrast */
  --white:       #ffffff;

  --teal-300:    #7fd0c6;   /* light teal tint, for accents on dark backgrounds */

  --serif: "Newsreader", Georgia, "Times New Roman", serif;
  --sans:  "IBM Plex Sans", "Segoe UI", Arial, sans-serif;

  --maxw: 1200px;
  --pad: clamp(1.25rem, 4vw, 3rem);
  --radius: 2px;
}

*, *::before, *::after{ box-sizing: border-box; }
html{ scroll-behavior: smooth; font-size: 17px; }

body{
  margin: 0;
  font-family: var(--sans);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

img{ max-width: 100%; display: block; }

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

.wrap{
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--pad);
}

h1, h2, h3, h4{
  font-family: var(--serif);
  color: var(--pine);
  line-height: 1.15;
  margin: 0 0 0.6em;
  font-weight: 500;
  letter-spacing: -0.01em;
}

h1{ font-size: clamp(2.2rem, 4.4vw, 3.4rem); font-weight: 500; }
h2{ font-size: clamp(1.6rem, 3vw, 2.25rem); }
h3{ font-size: clamp(1.15rem, 1.6vw, 1.4rem); font-family: var(--sans); font-weight: 600; color: var(--pine); }
h4{ font-size: 1.05rem; font-family: var(--sans); font-weight: 600; }

p{ margin: 0 0 1.1em; max-width: 62ch; font-size: 1.05rem; }
p:last-child{ margin-bottom: 0; }

.lede{
  font-size: clamp(1.1rem, 1.6vw, 1.3rem);
  color: var(--ink-soft);
  max-width: 58ch;
  line-height: 1.65;
}

ul.plain{ list-style: none; margin: 0; padding: 0; }

.list-check{
  list-style: none;
  margin: 1.4em 0 0;
  padding: 0;
  display: grid;
  gap: 0.85em;
  max-width: 56ch;
}
.list-check li{
  position: relative;
  padding-left: 1.4em;
  color: var(--ink-soft);
  font-size: 1.02rem;
  line-height: 1.55;
}
.list-check li::before{
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 7px;
  height: 7px;
  background: var(--teal);
}

.btn{
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  padding: 0.85em 1.6em;
  font-family: var(--sans);
  font-weight: 600;
  font-size: 0.95rem;
  border: 1px solid transparent;
  cursor: pointer;
  white-space: nowrap;
}
.btn-primary{
  background: var(--teal);
  color: var(--pine-900);
}
.btn-primary:hover{ background: var(--teal-700); color: var(--white); }
.btn-outline{
  background: transparent;
  border-color: currentColor;
  color: var(--pine);
}
.btn-outline:hover{ background: var(--pine); color: var(--white); border-color: var(--pine); }
.btn-outline.on-dark{ color: var(--white); }
.btn-outline.on-dark:hover{ background: var(--white); color: var(--pine); }

.eyebrow{
  display: block;
  font-family: var(--sans);
  font-weight: 600;
  font-size: 0.8rem;
  color: var(--teal-700);
  margin-bottom: 0.9em;
}

/* ===========================================================
   Header / Nav
   =========================================================== */
.site-header{
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap{
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 96px;
}
.brand{ display: flex; align-items: center; }
.brand img{ height: 46px; width: auto; }

.main-nav{ display: flex; align-items: center; gap: 2.1rem; }
.main-nav ul{
  display: flex;
  gap: 1.9rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.main-nav a{
  font-size: 0.94rem;
  font-weight: 500;
  color: var(--pine);
  padding: 0.4em 0;
  border-bottom: 2px solid transparent;
}
.main-nav a:hover,
.main-nav a[aria-current="page"]{
  border-bottom-color: var(--teal);
}
.nav-cta{ display: inline-flex; }

.nav-toggle{
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  border: 1px solid var(--line);
  background: var(--white);
  cursor: pointer;
}
.nav-toggle span{
  display: block;
  height: 2px;
  width: 20px;
  margin-inline: auto;
  background: var(--pine);
  transition: transform 0.2s ease, opacity 0.2s 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); }

/* ===========================================================
   Hero
   =========================================================== */
.hero{
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  align-items: stretch;
  border-bottom: 1px solid var(--line);
}
.hero-copy{
  padding: clamp(2.5rem, 6vw, 5rem) var(--pad);
  display: flex;
  flex-direction: column;
  justify-content: center;
  border-left: 4px solid var(--teal);
}
.hero-copy .lede{ margin-top: 0.9em; }
.hero-actions{ display: flex; flex-wrap: wrap; gap: 0.9rem; margin-top: 1.8rem; }
.hero-media{ position: relative; min-height: 320px; background: var(--pine-900); }
.hero-media img{ width: 100%; height: 100%; object-fit: cover; }

.page-hero{
  display: grid;
  grid-template-columns: 1fr;
  border-bottom: 1px solid var(--line);
  background: var(--white);
}
.page-hero .wrap{
  padding-block: clamp(2.5rem, 6vw, 4rem);
  border-left: 4px solid var(--teal);
  max-width: calc(var(--maxw) - 4px);
}
.page-hero .lede{ margin-top: 0.7em; }

/* ===========================================================
   Sections
   =========================================================== */
section{ padding-block: clamp(3rem, 7vw, 5.5rem); }
.section-tint{ background: var(--paper-dim); }
.section-dark{ background: var(--pine); color: var(--white); }
.section-dark h2, .section-dark h3{ color: var(--white); }
.section-dark p{ color: #dcece8; }
.section-dark .eyebrow{ color: var(--teal-300); }

.section-head{ max-width: 62ch; margin-bottom: 2.4rem; }
.section-head.center{ margin-inline: auto; text-align: center; }

.grid{ display: grid; gap: clamp(1.5rem, 4vw, 2.5rem); }
.grid-2{ grid-template-columns: repeat(2, 1fr); }
.grid-3{ grid-template-columns: repeat(3, 1fr); }
.grid-4{ grid-template-columns: repeat(4, 1fr); }

.card{
  position: relative;
  background: var(--white);
  border: 1px solid var(--line);
  padding: clamp(1.6rem, 3vw, 2.2rem);
}
.section-dark .card{
  background: rgba(255,255,255,0.05);
  border-color: rgba(255,255,255,0.2);
}
.card .card-no{
  display: block;
  font-family: var(--serif);
  font-size: 1.1rem;
  color: var(--teal-700);
  margin-bottom: 0.7em;
}
.section-dark .card .card-no{ color: var(--teal-300); }
.card h3{ margin-bottom: 0.5em; font-size: 1.2rem; }
.card p{ color: var(--ink-soft); max-width: none; font-size: 1.02rem; }
.section-dark .card p{ color: #dcece8; }

.media-row{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}
.media-row img{ width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4/3; }
.media-row.reverse .media-row-copy{ order: 2; }
.media-row.reverse .media-row-media{ order: 1; }

/* Process / pipeline strip — a real sequence, numbered */
.pipeline{
  display: flex;
  flex-wrap: wrap;
  border: 1px solid var(--line);
  background: var(--white);
}
.pipeline li{
  flex: 1 1 150px;
  padding: 1.4rem 1.2rem;
  border-right: 1px solid var(--line);
  position: relative;
}
.pipeline li:last-child{ border-right: none; }
.pipeline .step-no{
  font-family: var(--serif);
  color: var(--teal-700);
  font-size: 1.4rem;
  display: block;
  margin-bottom: 0.3em;
}
.pipeline .step-label{ font-size: 0.92rem; font-weight: 600; color: var(--pine); }

/* Milestones / timeline (Track Record) — a real sequence, with a vertical
   line and a marker per entry */
.timeline{ list-style: none; margin: 0; padding: 0; position: relative; }
.timeline::before{
  content: "";
  position: absolute;
  top: 10px;
  bottom: 10px;
  left: calc(96px + 1.2rem + 13px);
  width: 2px;
  background: var(--line);
}
.timeline li{
  display: grid;
  grid-template-columns: 96px 28px 1fr;
  column-gap: 1.2rem;
  padding-block: 1.9rem;
  position: relative;
}
.timeline li:not(:last-child){ border-bottom: 1px solid var(--line); }
.timeline .tl-marker{ display: flex; justify-content: center; padding-top: 0.4rem; }
.timeline .tl-dot{
  width: 15px;
  height: 15px;
  border-radius: 50%;
  background: var(--teal);
  border: 3px solid var(--paper);
  box-shadow: 0 0 0 1px var(--line);
  position: relative;
  z-index: 1;
}
.timeline .year{
  font-family: var(--serif);
  color: var(--pine);
  font-size: 1.4rem;
  padding-top: 0.1rem;
}
.timeline .tl-year-inline{ display: none; }
.timeline h3{ margin-bottom: 0.35em; font-size: 1.2rem; }
.timeline p{ color: var(--ink-soft); max-width: 60ch; font-size: 1.03rem; }

.stat-row{
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
  border-top: 1px solid var(--line);
  padding-top: 2.4rem;
  margin-top: 2.4rem;
}
.stat{
  padding-left: 1.6rem;
  border-left: 2px solid var(--line);
}
.stat:first-child{ padding-left: 0; border-left: none; }
.section-dark .stat{ border-left-color: rgba(255,255,255,0.22); }
.stat .num{
  font-family: var(--serif);
  font-size: clamp(2rem, 3.6vw, 2.6rem);
  color: var(--pine);
  display: block;
  line-height: 1.1;
}
.section-dark .stat .num{ color: var(--white); }
.stat .label{
  display: block;
  font-size: 1rem;
  font-weight: 600;
  color: var(--ink);
  margin-top: 0.35em;
}
.section-dark .stat .label{ color: #eaf3f0; }
.stat .caption{
  display: block;
  font-size: 0.96rem;
  color: var(--ink-soft);
  margin-top: 0.4em;
  line-height: 1.5;
}
.section-dark .stat .caption{ color: #bcd4cd; }

.split-cta{
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 2rem;
  align-items: center;
  background: var(--pine);
  color: var(--white);
  padding: clamp(2.2rem, 5vw, 3.5rem);
}
.split-cta h2{ color: var(--white); margin-bottom: 0.3em; }
.split-cta p{ color: #cfe0dc; }
.split-cta-actions{ display: flex; justify-content: flex-end; }

/* Illustrations */
.illustration{
  width: 100%;
  height: auto;
  display: block;
}
.illustration-frame{
  background: var(--paper);
  border: 1px solid var(--line);
  padding: clamp(1.5rem, 4vw, 2.5rem);
  margin-top: 2.4rem;
  overflow-x: auto;
}
.section-dark .illustration-frame{
  background: transparent;
  border-color: rgba(255,255,255,0.18);
}
.illustration-frame.tight{ padding: clamp(1rem, 3vw, 1.6rem); }
.wrap-wide{ max-width: 1400px; }
.illustration-frame{ position: relative; }
.illustration-frame::after{
  content: "";
  position: absolute;
  top: 1px; right: 1px; bottom: 1px;
  width: 36px;
  background: linear-gradient(to right, transparent, var(--paper));
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s ease;
}
.section-dark .illustration-frame::after{ background: linear-gradient(to right, transparent, var(--pine)); }

/* Offices */
.office-card{
  border: 1px solid var(--line);
  background: var(--white);
}
.office-card img{ width: 100%; aspect-ratio: 16/10; object-fit: cover; }
.office-card .office-body{ padding: 1.7rem 1.9rem 2rem; }
.office-card address{ font-style: normal; color: var(--ink-soft); line-height: 1.75; font-size: 1.02rem; }

.general-enquiries{
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  background: var(--paper-dim);
  border: 1px solid var(--line);
  border-left: 4px solid var(--teal);
  padding: 1.4rem 1.7rem;
  margin-top: 1.6rem;
}
.general-enquiries h4{ margin-bottom: 0.2em; }
.general-enquiries p{ margin: 0; color: var(--ink-soft); }
.general-enquiries a{ font-weight: 600; color: var(--pine); }
.general-enquiries a:hover{ color: var(--teal-700); }

/* Contact form */
.contact-layout{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}
.form-field{ margin-bottom: 1.3rem; }
.form-field label{ display: block; font-weight: 600; font-size: 0.9rem; margin-bottom: 0.4em; color: var(--pine); }
.form-field input,
.form-field select,
.form-field textarea{
  width: 100%;
  padding: 0.75em 0.9em;
  border: 1px solid var(--line);
  background: var(--white);
  font-family: var(--sans);
  font-size: 0.98rem;
  color: var(--ink);
}
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus{
  outline: 2px solid var(--teal);
  outline-offset: 1px;
}
.form-field textarea{ resize: vertical; min-height: 130px; }
.form-row{ display: grid; grid-template-columns: 1fr 1fr; gap: 1.3rem; }
.form-note{ font-size: 0.92rem; line-height: 1.6; color: var(--ink-soft); margin-top: 1rem; }
.hp-field{ position: absolute; left: -9999px; top: -9999px; }
.form-status{ margin-top: 1rem; font-weight: 600; }
.form-status[data-state="ok"]{ color: var(--teal-700); }
.form-status[data-state="error"]{ color: #b23b3b; }

/* ===========================================================
   Footer
   =========================================================== */
.site-footer{
  background: var(--pine-900);
  color: #cfe0dc;
  padding-block: 3rem 2rem;
}
.footer-grid{
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 2rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid rgba(255,255,255,0.14);
}
.footer-grid img{ height: 34px; margin-bottom: 1.1rem; }
.footer-grid p{ color: #c3d8d3; max-width: 40ch; font-size: 1rem; line-height: 1.7; }
.footer-col h4{ color: var(--white); font-size: 0.95rem; margin-bottom: 1em; }
.footer-col ul{ list-style: none; margin: 0; padding: 0; display: grid; gap: 0.75em; }
.footer-col a{ color: #d7e6e2; font-size: 1rem; }
.footer-col a:hover{ color: var(--teal-300); }
.footer-bottom{
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 1.6rem;
  font-size: 0.95rem;
  color: #bcd0cb;
}
.footer-bottom ul{ display: flex; gap: 1.3rem; list-style: none; margin: 0; padding: 0; flex-wrap: wrap; }
.footer-bottom a{ color: #bcd0cb; }
.footer-bottom a:hover{ color: var(--teal-300); }

/* ===========================================================
   Skip link / a11y
   =========================================================== */
.skip-link{
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--teal);
  color: var(--pine-900);
  padding: 0.7em 1.2em;
  z-index: 100;
  font-weight: 600;
}
.skip-link:focus{ left: 1rem; top: 1rem; }

:focus-visible{ outline: 2px solid var(--teal); outline-offset: 2px; }

/* ===========================================================
   Responsive
   =========================================================== */
@media (max-width: 980px){
  .grid-3, .grid-4{ grid-template-columns: repeat(2, 1fr); }
  .footer-grid{ grid-template-columns: 1fr 1fr; }
  .footer-grid > :first-child{ grid-column: 1 / -1; }
}

@media (max-width: 860px){
  .site-header .wrap{ height: 74px; }
  .brand img{ height: 36px; }
  .main-nav{ display: none; }
  .nav-toggle{ display: flex; }
  body.nav-open .main-nav{
    display: flex;
    position: fixed;
    inset: 74px 0 0 0;
    background: var(--paper);
    flex-direction: column;
    align-items: flex-start;
    padding: 2rem var(--pad);
    gap: 2rem;
    overflow-y: auto;
    z-index: 40;
  }
  body.nav-open .main-nav ul{ flex-direction: column; gap: 1.4rem; }
  body.nav-open .main-nav a{ font-size: 1.15rem; }
  body.nav-open{ overflow: hidden; }

  .hero{ grid-template-columns: 1fr; }
  .hero-media{ min-height: 260px; order: -1; }
  .hero-copy{ border-left: none; border-top: 4px solid var(--teal); }

  .media-row{ grid-template-columns: 1fr; }
  .media-row.reverse .media-row-copy,
  .media-row.reverse .media-row-media{ order: initial; }

  .split-cta{ grid-template-columns: 1fr; text-align: left; }
  .split-cta-actions{ justify-content: flex-start; }

  .contact-layout{ grid-template-columns: 1fr; }
  .form-row{ grid-template-columns: 1fr; }
}

@media (max-width: 700px){
  .grid-2, .grid-3, .grid-4{ grid-template-columns: 1fr; }

  .stat-row{ grid-template-columns: 1fr 1fr; gap: 1.6rem 1.4rem; }
  .stat{ padding-left: 1.2rem; }
  .stat:nth-child(odd){ padding-left: 0; border-left: none; }

  .timeline::before{ left: 6px; }
  .timeline li{
    grid-template-columns: 14px 1fr;
    column-gap: 0.9rem;
    padding-block: 1.5rem;
  }
  .timeline .year{ display: none; }
  .timeline .tl-marker{ padding-top: 0.35rem; }
  .timeline .tl-year-inline{
    display: inline-block;
    font-family: var(--serif);
    color: var(--pine);
    font-size: 1.1rem;
    margin-bottom: 0.25em;
  }

  .pipeline li{ flex: 1 1 45%; border-bottom: 1px solid var(--line); }
  .footer-grid{ grid-template-columns: 1fr; }

  /* Illustrations keep a legible minimum size and scroll horizontally
     inside their frame, rather than shrinking their labels to the
     point of illegibility. */
  .illustration-frame{ padding: 1.1rem; }
  .illustration-frame img[src*="lifecycle"]{ min-width: 620px; }
  .illustration-frame img[src*="capabilities-hub"]{ min-width: 520px; }
  .illustration-frame::after{ opacity: 1; }
}

@media (max-width: 420px){
  .brand img{ height: 30px; }
}

@media (prefers-reduced-motion: reduce){
  *{ scroll-behavior: auto !important; animation: none !important; transition: none !important; }
}
