/* Allotrope Energy — single page site */
:root {
  --graphite: #1c2729;
  --ink: #2a484d;
  --slate: #5b7479;
  --mist: #cdd8d9;
  --fog: #e8edec;
  --paper: #f5f6f5;
  --white: #ffffff;
  --signal: #8ccb45;
  --signal-ink: #3f6b14;
  --error: #a3342b;

  --display: "Raleway", "Helvetica Neue", Arial, sans-serif;
  --body: "Source Sans 3", "Helvetica Neue", Arial, sans-serif;

  --wrap: 1180px;
  --gutter: clamp(20px, 4vw, 48px);
  --section: clamp(72px, 10vw, 136px);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--graphite);
  font-family: var(--body);
  font-size: 18px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--ink); }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--signal);
  outline-offset: 3px;
}

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }

h1, h2, h3 { font-family: var(--display); color: var(--graphite); margin: 0; }
h1 { font-weight: 300; font-size: clamp(2.5rem, 6vw, 4.6rem); line-height: 1.04; letter-spacing: -0.02em; }
h2 { font-weight: 300; font-size: clamp(2rem, 4vw, 3rem); line-height: 1.1; letter-spacing: -0.015em; }
h3 { font-weight: 600; font-size: 1.5rem; line-height: 1.25; }
p { margin: 0 0 1em; }
.lede { font-size: 1.22rem; line-height: 1.55; color: var(--ink); max-width: 38em; }

.skip { position: absolute; left: -999px; top: 8px; background: var(--white); padding: 8px 14px; z-index: 100; }
.skip:focus { left: 8px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(245, 246, 245, 0.92);
  backdrop-filter: saturate(140%) blur(10px);
  -webkit-backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid rgba(91, 116, 121, 0.18);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--graphite); }
.brand img { width: 34px; height: 34px; }
.brand span { font-family: var(--display); font-weight: 600; font-size: 1.05rem; letter-spacing: 0.02em; }
.nav { display: flex; align-items: center; gap: 30px; }
.nav a { font-family: var(--display); font-weight: 500; font-size: 0.95rem; text-decoration: none; color: var(--ink); }
.nav a:hover { color: var(--graphite); }
.nav a.btn { color: var(--white); }

.btn {
  display: inline-block;
  font-family: var(--display); font-weight: 600; font-size: 0.98rem;
  background: var(--ink); color: var(--white);
  padding: 13px 24px; border-radius: 4px; border: 0;
  text-decoration: none; cursor: pointer;
  transition: background-color .15s ease;
}
.btn:hover { background: var(--graphite); }
.btn.small { padding: 9px 16px; font-size: 0.9rem; }
.btn.light { background: var(--white); color: var(--graphite); }
.btn.light:hover { background: var(--mist); }

@media (max-width: 760px) {
  .nav a:not(.btn) { display: none; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: min(88vh, 780px);
  display: flex; align-items: flex-end;
  color: var(--white);
  background: var(--graphite) url("img/hero-line.jpg") center 40% / cover no-repeat;
}
.hero::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(28,39,41,0.25) 0%, rgba(28,39,41,0.55) 45%, rgba(28,39,41,0.92) 100%);
}
.hero .wrap { position: relative; width: 100%; padding-bottom: clamp(56px, 8vw, 104px); padding-top: 140px; }
.hero h1 { color: var(--white); max-width: 13em; }
.hero p { font-size: 1.25rem; max-width: 34em; color: rgba(255,255,255,0.86); margin: 24px 0 36px; }
.hero-actions { display: flex; gap: 22px; align-items: center; flex-wrap: wrap; }
.hero-actions a.text { color: var(--white); font-family: var(--display); font-weight: 500; text-underline-offset: 5px; }

/* ---------- Sections ---------- */
section { padding: var(--section) 0; }
.section-head { display: grid; grid-template-columns: 1fr 1.25fr; gap: clamp(24px, 6vw, 96px); align-items: end; margin-bottom: clamp(40px, 6vw, 72px); }
.section-head p { margin: 0; color: var(--ink); font-size: 1.12rem; max-width: 36em; }
@media (max-width: 860px) { .section-head { grid-template-columns: 1fr; } }

/* ---------- Power gap chart ---------- */
.gap { background: var(--white); border-bottom: 1px solid var(--fog); }
.chart-wrap { display: grid; grid-template-columns: 1.6fr 1fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
.chart { min-width: 0; margin: 0; }
.chart svg { width: 100%; height: auto; overflow: visible; }
.chart text { font-family: var(--body); }
.chart figcaption { font-size: 0.88rem; color: var(--slate); margin-top: 14px; }
.chart-key { list-style: none; margin: 0; padding: 0; }
.chart-key li { display: grid; grid-template-columns: 18px 1fr; gap: 14px; padding: 16px 0; border-top: 1px solid var(--fog); }
.chart-key li:last-child { border-bottom: 1px solid var(--fog); }
.chart-key .dot { width: 14px; height: 14px; border-radius: 50%; margin-top: 6px; }
.chart-key strong { font-family: var(--display); font-weight: 600; display: block; font-size: 1.02rem; }
.chart-key span { font-size: 0.95rem; color: var(--slate); }
@media (max-width: 900px) { .chart-wrap { grid-template-columns: 1fr; } }

/* ---------- Technology ---------- */
.tech-item {
  display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 6vw, 88px);
  align-items: center;
  padding: clamp(48px, 6vw, 80px) 0;
  border-top: 1px solid rgba(91,116,121,0.22);
}
.tech-item:first-of-type { border-top: 0; padding-top: 0; }
.tech-item.flip .tech-media { order: 2; }
.tech-media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 3px; }
.tech-media .pair { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.tech-media .pair figure { margin: 0; }
.tech-media .pair img { aspect-ratio: 1 / 1; }
.tech-media .pair figcaption { font-size: 0.85rem; color: var(--slate); margin-top: 8px; }
.tech-copy .kind { font-family: var(--display); font-weight: 500; color: var(--slate); font-size: 1rem; margin: 0 0 10px; }
.tech-copy h3 { font-size: clamp(1.6rem, 2.6vw, 2.1rem); font-weight: 400; margin-bottom: 18px; }
.tech-copy p { color: #33464a; }

.specs { display: grid; grid-template-columns: repeat(3, 1fr); margin: 28px 0 0; border-top: 2px solid var(--ink); }
.specs div { padding: 14px 14px 0 0; }
.specs dt { font-size: 0.85rem; color: var(--slate); line-height: 1.35; }
.specs dd { margin: 4px 0 0; font-family: var(--display); font-weight: 600; font-size: 1.35rem; color: var(--graphite); line-height: 1.2; }
.specs dd small { font-size: 0.8rem; font-weight: 500; color: var(--slate); }
.status { display: inline-block; margin-top: 22px; font-size: 0.92rem; color: var(--signal-ink); background: rgba(140,203,69,0.16); padding: 5px 12px; border-radius: 3px; }

@media (max-width: 860px) {
  .tech-item { grid-template-columns: 1fr; }
  .tech-item.flip .tech-media { order: 0; }
}
@media (max-width: 480px) {
  .specs { grid-template-columns: 1fr 1fr; }
}

/* ---------- Conductivity table ---------- */

/* ---------- Progress ---------- */
.progress { background: var(--graphite); color: var(--white); }
.progress h2 { color: var(--white); }
.progress .section-head p { color: rgba(255,255,255,0.75); }
.timeline { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid rgba(255,255,255,0.25); }
.timeline li { padding: 26px 26px 0 0; position: relative; }
.timeline li::before { content: ""; position: absolute; top: -6px; left: 0; width: 11px; height: 11px; border-radius: 50%; background: var(--mist); }
.timeline li:last-child::before { background: var(--signal); }
.timeline .year { font-family: var(--display); font-weight: 300; font-size: 2rem; display: block; margin-bottom: 12px; }
.timeline ul { margin: 0; padding: 0; list-style: none; }
.timeline ul li { padding: 0 0 10px; font-size: 0.98rem; color: rgba(255,255,255,0.8); line-height: 1.45; }
.timeline ul li::before { display: none; }
.readiness { margin-top: clamp(48px, 6vw, 72px); display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.readiness div { border-left: 2px solid var(--signal); padding-left: 18px; }
.readiness strong { display: block; font-family: var(--display); font-weight: 600; font-size: 1.1rem; }
.readiness span { color: rgba(255,255,255,0.75); font-size: 0.95rem; }
@media (max-width: 860px) {
  .timeline { grid-template-columns: 1fr 1fr; row-gap: 36px; }
  .readiness { grid-template-columns: 1fr; }
}
@media (max-width: 480px) { .timeline { grid-template-columns: 1fr; } }

/* ---------- About ---------- */
.about-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(32px, 6vw, 88px); align-items: start; }
.about-grid figure { margin: 0; }
.about-grid figure img { width: 100%; border-radius: 3px; }
.about-grid figcaption { font-size: 0.88rem; color: var(--slate); margin-top: 10px; }
.about-copy p { color: #33464a; }
.about-copy p.lede { color: var(--ink); }
.facts { list-style: none; padding: 0; margin: 28px 0 0; }
.facts li { padding: 12px 0; border-top: 1px solid rgba(91,116,121,0.22); font-size: 1rem; }
.about-lab { margin-top: clamp(40px, 6vw, 72px); }
.about-lab img { width: 100%; aspect-ratio: 21 / 8; object-fit: cover; border-radius: 3px; }
@media (max-width: 860px) { .about-grid { grid-template-columns: 1fr; } }

/* ---------- Contact ---------- */
.contact { background: var(--white); border-top: 1px solid var(--fog); }
.contact-grid { display: grid; grid-template-columns: 1fr 1.35fr; gap: clamp(32px, 6vw, 96px); }
.contact-details { margin-top: 32px; font-size: 1rem; }
.contact-details p { margin: 0 0 6px; }
.contact-details a { text-decoration: none; border-bottom: 1px solid var(--mist); }
.contact-details .addr { color: var(--slate); margin-top: 14px; }

form { display: grid; grid-template-columns: 1fr 1fr; gap: 20px 22px; }
.field { display: flex; flex-direction: column; gap: 7px; }
.field.full { grid-column: 1 / -1; }
label { font-family: var(--display); font-weight: 600; font-size: 0.9rem; color: var(--graphite); }
label .opt { font-weight: 400; color: var(--slate); }
input, select, textarea {
  font: inherit; font-size: 1rem; color: var(--graphite);
  background: var(--paper);
  border: 1px solid #c3cfd0; border-radius: 3px;
  padding: 12px 14px; width: 100%;
}
textarea { min-height: 150px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--ink); background: var(--white); }
input[aria-invalid="true"], textarea[aria-invalid="true"], select[aria-invalid="true"] { border-color: var(--error); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-foot { grid-column: 1 / -1; display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.form-foot small { color: var(--slate); font-size: 0.88rem; flex: 1; min-width: 220px; }
.form-msg { grid-column: 1 / -1; margin: 0; padding: 14px 16px; border-radius: 3px; font-size: 1rem; display: none; }
.form-msg.ok { display: block; background: rgba(140,203,69,0.16); color: var(--signal-ink); }
.form-msg.err { display: block; background: rgba(163,52,43,0.08); color: var(--error); }
button[disabled] { opacity: .6; cursor: progress; }
@media (max-width: 860px) { .contact-grid { grid-template-columns: 1fr; } }
@media (max-width: 560px) { form { grid-template-columns: 1fr; } }

/* ---------- Footer ---------- */
.site-footer { background: var(--graphite); color: rgba(255,255,255,0.72); padding: clamp(56px, 7vw, 88px) 0 0; font-size: 0.95rem; line-height: 1.6; }
.site-footer a { color: rgba(255,255,255,0.88); text-decoration: none; }
.site-footer a:hover { color: var(--white); text-decoration: underline; text-underline-offset: 4px; }
.site-footer .brand { color: var(--white); }
.site-footer .brand:hover { text-decoration: none; }
.site-footer p { margin: 0 0 14px; }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 0.8fr; gap: clamp(28px, 4vw, 56px); }
.footer-brand p { margin-top: 18px; max-width: 26em; }
.footer-h { font-family: var(--display); font-weight: 600; font-size: 0.95rem; color: var(--white); margin: 6px 0 14px; letter-spacing: 0; }
.footer-nav, .social { list-style: none; margin: 0; padding: 0; }
.footer-nav li { margin-bottom: 8px; }
.social { display: flex; gap: 20px; margin-top: 4px; }
.footer-base { margin-top: clamp(40px, 5vw, 64px); padding-bottom: 28px; font-size: 0.85rem; color: rgba(255,255,255,0.55); }
.footer-base > span { display: block; padding-top: 22px; border-top: 1px solid rgba(255,255,255,0.12); }
@media (max-width: 900px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; } }

/* Keep chart labels legible on phones: scroll the chart, not the page */
@media (max-width: 600px) {
  .chart .scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 0 calc(var(--gutter) * -1); padding: 0 var(--gutter); }
  .chart svg { min-width: 560px; }
}

/* ---------- Media ---------- */
.media { border-top: 1px solid rgba(91,116,121,0.18); }
.media-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 88px); }
.media-sub { font-family: var(--display); font-weight: 500; font-size: 1rem; color: var(--slate); margin: 0 0 6px; }
.releases, .coverage { list-style: none; margin: 0; padding: 0; }
.releases li { padding: 20px 0; border-top: 1px solid rgba(91,116,121,0.22); display: grid; gap: 4px; }
.releases a { font-family: var(--display); font-weight: 500; font-size: 1.2rem; line-height: 1.35; color: var(--graphite); text-decoration: none; }
.releases a:hover { text-decoration: underline; text-underline-offset: 4px; text-decoration-color: var(--mist); }
.media time { font-size: 0.88rem; color: var(--slate); }
.media .outlet { font-size: 0.88rem; color: var(--slate); }
.coverage li { border-top: 1px solid rgba(91,116,121,0.22); }
.coverage a { display: grid; grid-template-columns: 112px 1fr; gap: 18px; padding: 20px 0; text-decoration: none; color: inherit; align-items: start; }
.coverage img { width: 112px; height: 84px; object-fit: cover; border-radius: 2px; background: var(--fog); filter: grayscale(1); opacity: 0.75; transition: filter .25s ease, opacity .25s ease; }
.coverage a:hover img, .coverage a:focus-visible img { filter: none; opacity: 1; }
.cov-text { display: grid; gap: 4px; }
.cov-text strong { font-family: var(--display); font-weight: 500; font-size: 1.05rem; line-height: 1.35; color: var(--graphite); }
.coverage a:hover strong { text-decoration: underline; text-underline-offset: 4px; text-decoration-color: var(--mist); }
@media (max-width: 860px) { .media-grid { grid-template-columns: 1fr; } }
@media (max-width: 420px) { .coverage a { grid-template-columns: 84px 1fr; } .coverage img { width: 84px; height: 63px; } }

/* ---------- Composite electrode note ---------- */
.tech-note {
  display: grid; grid-template-columns: 1fr 1.25fr; gap: clamp(24px, 6vw, 88px);
  margin: 0 0 clamp(48px, 6vw, 80px);
  padding: clamp(32px, 4vw, 48px) clamp(24px, 4vw, 48px);
  background: var(--fog);
  border-left: 3px solid var(--slate);
  border-radius: 0 3px 3px 0;
}
.tech-note .kind { font-family: var(--display); font-weight: 500; color: var(--slate); font-size: 1rem; margin: 0 0 8px; }
.tech-note h3 { font-size: clamp(1.4rem, 2.2vw, 1.75rem); font-weight: 400; }
.tech-note-copy p { color: #33464a; }
.note-points { list-style: none; margin: 18px 0 0; padding: 0; }
.note-points li { padding: 10px 0 10px 18px; border-top: 1px solid rgba(91,116,121,0.22); position: relative; font-size: 0.98rem; }
.note-points li::before { content: ""; position: absolute; left: 0; top: 19px; width: 7px; height: 7px; border-radius: 50%; background: var(--slate); }
@media (max-width: 860px) { .tech-note { grid-template-columns: 1fr; } }
.note-lede { margin: 12px 0 0; color: var(--slate); font-size: 1.1rem; max-width: 18em; }

.spec-note { font-size: 0.85rem; color: var(--slate); margin: 14px 0 0; }
.download { margin: 22px 0 0; display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.download a { font-family: var(--display); font-weight: 600; color: var(--ink); text-underline-offset: 4px; }
.download a::before { content: ""; display: inline-block; width: 10px; height: 10px; margin-right: 10px; border: solid var(--ink); border-width: 0 2px 2px 0; transform: translateY(-3px) rotate(45deg); }
.download span { font-size: 0.85rem; color: var(--slate); }

/* ---------- Applications ---------- */
.apps { background: var(--white); padding: clamp(56px, 7vw, 96px) 0; border-top: 1px solid var(--fog); }
.apps-head { display: flex; justify-content: space-between; align-items: baseline; gap: 24px; flex-wrap: wrap; margin-bottom: 28px; }
.apps-head h2 { font-size: clamp(1.6rem, 2.6vw, 2.1rem); }
.apps-head p { margin: 0; color: var(--slate); font-size: 1rem; }
.apps-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 0 24px; }
.apps-list li { border-top: 2px solid var(--ink); padding-top: 16px; display: flex; flex-direction: column; gap: 6px; }
.apps-list strong { font-family: var(--display); font-weight: 600; font-size: 1.02rem; line-height: 1.3; }
.apps-list span { font-size: 0.93rem; color: #33464a; line-height: 1.5; }
.apps-list em { font-style: normal; font-size: 0.82rem; color: var(--slate); margin-top: auto; padding-top: 6px; }
@media (max-width: 1000px) { .apps-list { grid-template-columns: repeat(3, 1fr); row-gap: 28px; } }
@media (max-width: 600px) { .apps-list { grid-template-columns: 1fr; } }

/* ---------- How we work with you ---------- */
.engage { list-style: none; margin: 28px 0 0; padding: 0; counter-reset: step; }
.engage li { counter-increment: step; display: grid; grid-template-columns: 30px 1fr; column-gap: 12px; padding: 10px 0; border-top: 1px solid var(--fog); font-size: 0.97rem; }
.engage li::before { content: counter(step); grid-row: span 2; font-family: var(--display); font-weight: 300; font-size: 1.4rem; color: var(--slate); line-height: 1.2; }
.engage strong { font-family: var(--display); font-weight: 600; }
.engage span { color: #33464a; }

/* ---------- Downloads ---------- */
.downloads { margin-top: clamp(40px, 5vw, 64px); }
.downloads ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 0 clamp(32px, 6vw, 88px); }
.downloads li { border-top: 1px solid rgba(91,116,121,0.22); padding: 16px 0; display: flex; justify-content: space-between; gap: 16px; align-items: baseline; flex-wrap: wrap; }
.downloads a { font-family: var(--display); font-weight: 500; color: var(--graphite); text-decoration: none; }
.downloads a:hover { text-decoration: underline; text-underline-offset: 4px; }
.downloads span { font-size: 0.85rem; color: var(--slate); }
@media (max-width: 860px) { .downloads ul { grid-template-columns: 1fr; } }
form { align-content: start; }
