/* Layout: a technical brochure. Left-aligned text on a 12-column feel, hairline rules instead of
   boxed cards, one dark "subsurface" panel in the hero and one dark band for the Five Zeros. */

/* setting image tones of the website based on the logo */

:root {
  --navy: #113555;        /* logo hexagon + wordmark */
  --navy-deep: #0B2338;   /* dark bands */
  --green: #50B130;       /* logo flame, left */
  --blue: #0073C3;        /* logo flame, right */
  --paper: #FBFAF7;       /* logo background */
  --mist: #EEF2F4;        /* cool neutral for alternate sections */
  --ink: #16293A;
  --muted: #55697A;
  --line: #D5DCE1;
  --line-dark: rgba(255,255,255,.16);
  --on-dark: #E9F0F5;
  --on-dark-muted: #9FB3C3;

  --display: "Archivo", "Arial Narrow", Arial, sans-serif;
  --body: "IBM Plex Sans", "Segoe UI", Arial, sans-serif;
  --mono: "IBM Plex Mono", Consolas, monospace;

  --wrap: 1180px;
  --gutter: clamp(16px, 4vw, 40px);
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 17px/1.6 var(--body); -webkit-font-smoothing: antialiased; }
img, svg { max-width: 100%; display: block; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; }
h1, h2, h3 { font-family: var(--display); font-stretch: 112%; color: var(--navy); margin: 0; text-wrap: balance; line-height: 1.08; letter-spacing: -.01em; }
h1 { font-size: clamp(2.2rem, 4.2vw, 3.3rem); font-weight: 750; }
h2 { font-size: clamp(1.7rem, 3.2vw, 2.5rem); font-weight: 700; }
h3 { font-size: 1.18rem; font-weight: 650; line-height: 1.25; font-stretch: 105%; }
p { margin: 0; }
.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.label { font: 500 .78rem/1.3 var(--mono); letter-spacing: .09em; text-transform: uppercase; color: var(--blue); }
.lede { font-size: 1.15rem; color: var(--muted); max-width: 58ch; }
.section { padding-block: clamp(56px, 8vw, 104px); }
.section-head { display: grid; gap: 14px; margin-bottom: clamp(32px, 5vw, 56px); max-width: 62ch; }
.alt { background: var(--mist); }

/* Buttons */
.btn { display: inline-flex; align-items: center; gap: 10px; padding: 14px 22px; border-radius: 3px; font: 600 1rem/1.2 var(--body); text-decoration: none; border: 1.5px solid transparent; cursor: pointer; transition: background .15s, color .15s, border-color .15s; }
.btn-primary { background: var(--green); color: #06210B; }
.btn-primary:hover { background: #5FC43C; }
.btn-ghost { border-color: var(--navy); color: var(--navy); }
.btn-ghost:hover { background: var(--navy); color: #fff; }
.btn .arrow { font-family: var(--mono); }

/* Header */
.site-header { position: sticky; top: 0; z-index: 20; background: rgba(251,250,247,.94); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; gap: 28px; min-height: 76px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; margin-right: auto; }
.brand img { width: 44px; height: auto; }
.brand-name { display: grid; line-height: 1; }
.brand-name b { font: 800 1.45rem/1 var(--display); font-stretch: 110%; letter-spacing: .01em; color: var(--navy); }
.brand-name span { font: 600 .66rem/1 var(--display); letter-spacing: .2em; color: var(--navy); margin-top: 5px; }
.nav { display: flex; gap: 26px; }
.nav a { font-size: .95rem; font-weight: 500; text-decoration: none; color: var(--ink); padding-block: 6px; border-bottom: 2px solid transparent; }
.nav a:hover { border-color: var(--green); }
.site-header .btn { padding: 11px 16px; font-size: .92rem; white-space: nowrap; }

/* Main image on front page */
.hero { padding-block: clamp(72px, 10vw, 136px); color: var(--on-dark); background-color: var(--navy-deep);
  background-image: linear-gradient(90deg, rgba(11,35,56,.95) 0%, rgba(11,35,56,.86) 42%, rgba(11,35,56,.4) 100%), url("assets/hero-gas-plant.jpg");
  background-size: cover; background-position: center right; }
.hero-copy { display: grid; gap: 24px; max-width: 660px; }
.hero h1 { color: #fff; }
.hero h1 em { font-style: normal; color: #5DB4F0; }
.hero .label { color: var(--green); }
.hero .lede { color: #C9D7E2; }
.hero .btn-ghost { border-color: rgba(255,255,255,.7); color: #fff; }
.hero .btn-ghost:hover { background: #fff; color: var(--navy); }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 6px; }
.hero-note { font-size: .92rem; color: var(--on-dark-muted); }
figure { margin: 0; }

/* image properties */
.figures { border-block: 1px solid var(--line); }
.figures .wrap { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); }
.figure { padding: 28px 20px 26px 0; display: grid; gap: 6px; align-content: start; }
.figure + .figure { padding-left: 20px; border-left: 1px solid var(--line); }
.figure b { font: 750 clamp(1.9rem, 3.4vw, 2.7rem)/1 var(--display); font-stretch: 112%; color: var(--navy); font-variant-numeric: tabular-nums; }
.figure span { font-size: .9rem; color: var(--muted); line-height: 1.4; }

/* Adopted by */
.adopted { padding-block: 34px; }
.adopted .wrap { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 16px 32px; align-items: baseline; }
.names { display: flex; flex-wrap: wrap; gap: 8px 30px; list-style: none; margin: 0; padding: 0; }
.names li { font: 650 1.12rem var(--display); font-stretch: 108%; color: var(--navy); opacity: .82; }
.names.small li { font: 500 .95rem var(--body); opacity: 1; color: var(--muted); }

/* Technology portfolio */
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.tech { padding: 28px 26px 30px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); display: grid; gap: 12px; align-content: start; background: var(--paper); transition: background .15s; }
.tech:hover { background: #fff; }
.tech code { font: 500 .74rem var(--mono); letter-spacing: .08em; color: var(--green); background: var(--navy); padding: 4px 8px; border-radius: 2px; justify-self: start; }
.tech p { font-size: .96rem; color: var(--muted); }
.tech .outcome { font-size: .9rem; color: var(--ink); padding-top: 12px; border-top: 1px dashed var(--line); }

/* Engagement steps */
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(20px, 3vw, 40px); counter-reset: step; list-style: none; margin: 0; padding: 0; }
.steps li { display: grid; gap: 12px; align-content: start; padding-top: 20px; border-top: 3px solid var(--navy); }
.steps li:first-child { border-color: var(--green); }
.steps li::before { counter-increment: step; content: "Phase " counter(step); font: 500 .78rem var(--mono); letter-spacing: .09em; text-transform: uppercase; color: var(--blue); }
.steps p { color: var(--muted); font-size: .98rem; }
.free { font: 600 .78rem var(--mono); letter-spacing: .06em; color: #06210B; background: var(--green); padding: 3px 8px; border-radius: 2px; justify-self: start; }
.clinic { margin-top: clamp(36px, 5vw, 60px); display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: clamp(20px, 4vw, 56px); padding: clamp(24px, 4vw, 40px); background: #fff; border: 1px solid var(--line); border-left: 0; border-right: 0; }
.clinic p { color: var(--muted); }

/* Five Zeros */
.zeros { color: var(--on-dark); background-color: var(--navy-deep);
  background-image: linear-gradient(rgba(11,35,56,.86), rgba(11,35,56,.9)), url("assets/bg-oil-cleanup.jpg");
  background-size: cover; background-position: center; }
.zeros h2 { color: #fff; }
.zeros .label { color: var(--green); }
.zeros .lede { color: var(--on-dark-muted); }
.zero-row { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); border-top: 1px solid var(--line-dark); }
.zero { padding: 30px 16px 6px 0; display: grid; gap: 4px; }
.zero + .zero { padding-left: 22px; border-left: 1px solid var(--line-dark); }
.zero b { font: 800 clamp(3.6rem, 8vw, 6.4rem)/.9 var(--display); font-stretch: 125%; color: transparent; -webkit-text-stroke: 2px var(--green); }
.zero:nth-child(even) b { -webkit-text-stroke-color: #3F9FE6; }
.zero span { font: 650 1.1rem var(--display); font-stretch: 108%; color: #fff; }

/* Fields + training */
.two-col { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 88px); }
.fields { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.fields li { display: grid; gap: 4px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.fields b { font: 650 1.05rem var(--display); font-stretch: 105%; color: var(--navy); }
.fields span { font-size: .93rem; color: var(--muted); }
.courses { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 0; padding: 0; }
.courses li { font-size: .92rem; padding: 8px 13px; border: 1px solid var(--line); border-radius: 2px; background: #fff; }
.stack { display: grid; gap: 22px; align-content: start; }

/* Leadership */
.leader { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.leader-facts { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 0; border-top: 1px solid var(--line); }
.leader-facts li { padding: 16px 12px 16px 0; border-bottom: 1px solid var(--line); display: grid; gap: 2px; }
.leader-facts b { font: 750 1.7rem/1.1 var(--display); font-stretch: 110%; color: var(--navy); }
.leader-facts span { font-size: .88rem; color: var(--muted); }
.leader-body { display: grid; gap: 18px; }
.leader-body p { color: var(--muted); }
.leader-body .role { font: 500 .78rem var(--mono); letter-spacing: .09em; text-transform: uppercase; color: var(--blue); }

/* Contact */
.contact { color: var(--on-dark); background-color: var(--navy);
  background-image: linear-gradient(90deg, rgba(17,53,85,.95) 0%, rgba(17,53,85,.88) 55%, rgba(17,53,85,.7) 100%), url("assets/bg-laboratory.jpg");
  background-size: cover; background-position: center; }
.contact h2 { color: #fff; }
.contact .label { color: var(--green); }
.contact .lede { color: #C5D4DF; }
.contact .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .9fr); gap: clamp(32px, 6vw, 80px); }
.offices { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 12px; padding-top: 22px; border-top: 1px solid var(--line-dark); }
.offices b { display: block; font: 650 1.05rem var(--display); color: #fff; }
.offices span { font: 400 .76rem var(--mono); letter-spacing: .05em; color: var(--on-dark-muted); }
.mail { font: 500 1rem var(--mono); color: #fff; user-select: all; }
form { background: var(--paper); color: var(--ink); padding: clamp(22px, 3vw, 32px); border-radius: 4px; display: grid; gap: 16px; }
form h3 { font-size: 1.25rem; }
.field { display: grid; gap: 6px; }
.field label { font-size: .86rem; font-weight: 600; color: var(--navy); }
.field input, .field select, .field textarea { font: 400 1rem var(--body); color: var(--ink); background: #fff; border: 1px solid #B9C4CC; border-radius: 3px; padding: 11px 12px; width: 100%; }
.field textarea { min-height: 96px; resize: vertical; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-note { font-size: .86rem; color: var(--muted); }
#form-status { font-size: .9rem; font-weight: 600; color: var(--navy); }

/* Footer */
.site-footer { background: var(--navy-deep); color: var(--on-dark-muted); padding-block: 40px; font-size: .9rem; }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 20px 40px; align-items: center; }
.site-footer .brand-name b, .site-footer .brand-name span { color: #fff; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 8px 22px; margin-right: auto; }
.site-footer nav a { text-decoration: none; }
.site-footer nav a:hover { color: #fff; }

/* Responsive */
@media (max-width: 1060px) {
  .nav { display: none; }
}
@media (max-width: 900px) {
  .hero { background-image: linear-gradient(rgba(11,35,56,.86), rgba(11,35,56,.9)), url("assets/hero-gas-plant.jpg"); background-position: center; }
  .hero .wrap, .two-col, .leader, .contact .wrap, .clinic { grid-template-columns: minmax(0, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .figures .wrap { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .figure:nth-child(4) { padding-left: 0; border-left: 0; }
  .figure:nth-child(n+4) { border-top: 1px solid var(--line); }
  .steps { grid-template-columns: minmax(0, 1fr); }
  .adopted .wrap { grid-template-columns: minmax(0, 1fr); }
  .zero-row { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .zero:nth-child(4) { padding-left: 0; border-left: 0; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .site-header .btn { display: none; }
  .grid-3 { grid-template-columns: minmax(0, 1fr); }
  .figures .wrap { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .figure, .figure + .figure { padding: 20px 12px 18px 0; border-left: 0; border-top: 1px solid var(--line); }
  .figure:nth-child(-n+2) { border-top: 0; }
  .zero-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .zero, .zero + .zero { padding: 22px 8px 6px 0; border-left: 0; }
  .form-row, .offices, .leader-facts { grid-template-columns: minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }

/*  Publications page  */
.nav a[aria-current="page"] { border-color: var(--green); color: var(--navy); }
.page-hero { background: var(--navy-deep); color: var(--on-dark); padding-block: clamp(56px, 8vw, 96px); }
.page-hero .wrap { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, .7fr); gap: clamp(28px, 5vw, 72px); align-items: end; }
.page-hero h1 { color: #fff; }
.page-hero .label { color: var(--green); }
.page-hero .lede { color: #C9D7E2; }
.page-hero-copy { display: grid; gap: 20px; }
.page-hero-facts { display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--line-dark); }
.page-hero-facts div { padding: 18px 12px 0 0; display: grid; gap: 4px; }
.page-hero-facts div + div { padding-left: 18px; border-left: 1px solid var(--line-dark); }
.page-hero-facts b { font: 750 clamp(2rem, 4vw, 2.8rem)/1 var(--display); font-stretch: 112%; color: #fff; }
.page-hero-facts span { font-size: .88rem; color: var(--on-dark-muted); }

.shelves { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(48px, 6vw, 80px) clamp(28px, 5vw, 64px); }
.shelf { display: grid; gap: 22px; align-content: start; }
.shelf-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 16px; }
.shelf-head h2 { font-size: 1.35rem; font-stretch: 108%; }
.shelf-head a { font: 500 .78rem var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--blue); text-decoration: none; }
.shelf-head a:hover { text-decoration: underline; }
.shelf-books { --cover-h: 260px; position: relative; display: flex; flex-wrap: wrap; gap: 26px 32px; list-style: none; margin: 0; padding: 0 0 0 18px; }
/* the shelf board sits directly under the covers */
.shelf-books::before { content: ""; position: absolute; left: 0; right: 0; top: var(--cover-h); height: 16px; background: linear-gradient(rgba(255,255,255,.18), rgba(0,0,0,.15)), repeating-linear-gradient(92deg, rgba(60,30,10,.22) 0 1px, transparent 1px 7px, rgba(255,230,190,.12) 7px 8px, transparent 8px 15px), #9A6438; border-bottom: 3px solid #6B4226; border-radius: 2px; box-shadow: 0 10px 18px -8px rgba(60,35,15,.5); }
.book { width: 180px; display: grid; gap: 30px; align-content: start; }
.cover { height: var(--cover-h); display: flex; align-items: flex-end; justify-content: center; }
.cover-inner { position: relative; display: block; max-height: 100%; transition: transform .2s ease; }
.cover-inner img { display: block; max-height: var(--cover-h); max-width: 180px; width: auto; height: auto; border-radius: 1px 3px 3px 1px; box-shadow: 0 1px 0 rgba(0,0,0,.08), 6px 6px 14px -4px rgba(11,35,56,.45); }
/* spine shading on the left edge of each cover */
.cover-inner::after { content: ""; position: absolute; inset: 0 auto 0 0; width: 9px; background: linear-gradient(90deg, rgba(0,0,0,.28), rgba(255,255,255,.12) 60%, transparent); border-radius: 1px 0 0 1px; }
.book:hover .cover-inner { transform: translateY(-6px); }
.book-info { display: grid; gap: 6px; }
.book-info h3 { font-size: 1.02rem; line-height: 1.25; }
.book-info .authors { font-size: .88rem; color: var(--ink); line-height: 1.4; }
.book-info .pub { font: 400 .74rem/1.4 var(--mono); letter-spacing: .04em; color: var(--muted); }
.edition { font: 600 .7rem var(--mono); letter-spacing: .06em; color: var(--navy); background: var(--mist); border: 1px solid var(--line); padding: 2px 6px; border-radius: 2px; justify-self: start; }

.bib-cta { background: var(--mist); border-top: 1px solid var(--line); padding-block: clamp(44px, 6vw, 72px); }
.bib-cta .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px 40px; }
.bib-cta .stack { max-width: 60ch; gap: 10px; }

@media (max-width: 900px) {
  .page-hero .wrap, .shelves { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 560px) {
  .shelf-books { --cover-h: 200px; gap: 24px 20px; padding-left: 0; }
  .book { width: calc(50% - 10px); }
  .cover-inner img { max-width: 100%; }
}
@media (prefers-reduced-motion: reduce) { .book:hover .cover-inner { transform: none; } }

/*Menu button (differentr res screens) */
.menu-toggle { display: none; align-items: center; gap: 8px; background: none; border: 1.5px solid var(--navy); color: var(--navy); border-radius: 3px; padding: 9px 13px; font: 600 .92rem/1 var(--body); cursor: pointer; }
.menu-toggle:hover { background: var(--navy); color: #fff; }
@media (max-width: 1060px) {
  .menu-toggle { display: inline-flex; }
  .site-header.menu-open .nav { display: flex; flex-direction: column; gap: 0; position: absolute; top: 100%; left: 0; right: 0; background: var(--paper); border-bottom: 1px solid var(--line); box-shadow: 0 14px 24px -14px rgba(11,35,56,.35); padding-block: 6px 14px; padding-left: max(16px, var(--gutter)); padding-right: max(16px, var(--gutter)); }
  .site-header.menu-open .nav a { padding-block: 13px; border-bottom: 1px solid var(--line); font-size: 1rem; }
  .site-header.menu-open .nav a:last-child { border-bottom: 0; }
}
