/* ============================================================
   Cleanlight Inc. — Design System
   Palette: warm white base, deep navy text, muted gold accent
   Type: Cormorant Garamond (serif) + Inter (sans)
   ============================================================ */

/* --- Custom Properties --------------------------------------- */
:root {
  --base:          #FAF9F7;
  --surface:       #F2EEE8;
  --text:          #14212E;
  --text-mid:      #3D4F5E;
  --text-light:    #6B7F8E;
  --accent:        #9B7D47;
  --accent-light:  #C4A87A;
  --divider:       #DDD8CF;
  --divider-dark:  #B8B0A4;

  --font-serif:    'Cormorant Garamond', Georgia, 'Times New Roman', serif;
  --font-sans:     'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;

  --content:       1140px;
  --pad:           clamp(20px, 5vw, 64px);
  --gap:           clamp(24px, 4vw, 48px);
  --section-y:     clamp(64px, 8vw, 112px);

  --radius:        0px;
  --transition:    180ms ease;
}

/* --- Reset --------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scroll-padding-top: 62px; }
body {
  background: var(--base);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.65;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
}

/* --- Typography --------------------------------------------- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-serif);
  font-weight: 500;
  line-height: 1.15;
  color: var(--text);
  letter-spacing: -0.01em;
}

h1, h2, h3 { text-wrap: balance; }

h1 { font-family: var(--font-sans); font-size: clamp(2.2rem, 4.5vw, 3.8rem); font-weight: 700; line-height: 1.06; letter-spacing: -0.03em; }
h2 { font-family: var(--font-sans); font-size: clamp(1.7rem, 3vw, 2.4rem); font-weight: 600; letter-spacing: -0.025em; }
h3 { font-size: clamp(1.2rem, 2vw, 1.6rem); font-weight: 500; }
h4 { font-size: 1rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; font-family: var(--font-sans); }

p { color: var(--text-mid); }
p + p { margin-top: 1.2em; }

strong { font-weight: 600; color: var(--text); }

.eyebrow {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}

/* --- Layout -------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--content);
  margin-inline: auto;
  padding-inline: var(--pad);
}

.section {
  padding-block: var(--section-y);
}

.section--bordered {
  border-top: 1px solid var(--divider);
}

/* Two-column: label | content (IC-memo style) */
.split {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 0 clamp(40px, 6vw, 80px);
  align-items: start;
}

.split__label {
  padding-top: 0.1em;
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-light);
  position: sticky;
  top: 80px;
}

.split__content {}

/* Three columns */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0 clamp(32px, 5vw, 60px);
}

/* --- Navigation --------------------------------------------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--base);
  border-bottom: 1px solid var(--divider);
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
}

.nav__logo {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  font-weight: 500;
  text-decoration: none;
  color: var(--text);
  letter-spacing: -0.01em;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 36px;
  list-style: none;
}

.nav__links a {
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--text-mid);
  transition: color var(--transition);
}

.nav__links a:hover { color: var(--text); }

.nav__links a.active {
  color: var(--text);
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-underline-offset: 4px;
  text-decoration-thickness: 1.5px;
}

.nav__cta {
  font-size: 0.75rem !important;
  font-weight: 600 !important;
  color: var(--text) !important;
  border: 1px solid var(--divider-dark);
  padding: 7px 18px;
  transition: border-color var(--transition), background var(--transition) !important;
}

.nav__cta:hover {
  border-color: var(--text) !important;
  background: var(--surface) !important;
}

/* Mobile nav toggle */
.nav__toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  color: var(--text);
}

/* --- Hero ---------------------------------------------------- */
.hero {
  padding-top: clamp(56px, 7vw, 96px);
  padding-bottom: clamp(64px, 8vw, 108px);
  border-bottom: 1px solid var(--divider);
  background-image: radial-gradient(circle, rgba(20,33,46,0.065) 1px, transparent 1px);
  background-size: 28px 28px;
  overflow: hidden;
}

.hero__inner {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 0;
  align-items: stretch;
}

.hero__eyebrow {
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.hero__eyebrow::before {
  content: '';
  display: block;
  width: 20px;
  height: 1.5px;
  background: var(--accent);
  flex-shrink: 0;
}

.hero__headline {
  font-size: clamp(2rem, 3.5vw, 2.8rem);
  font-weight: 600;
  line-height: 1.12;
  margin-bottom: 20px;
  color: var(--text);
}

.hero__sub {
  font-size: clamp(0.95rem, 1.4vw, 1.05rem);
  line-height: 1.7;
  color: var(--text-mid);
  max-width: 440px;
  margin-bottom: 40px;
}

.hero__headline em {
  font-style: italic;
  color: var(--text-mid);
}

.hero__cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--text);
  transition: gap var(--transition), color var(--transition);
}

.hero__cta:hover { gap: 16px; color: var(--accent); }

.hero__cta svg { flex-shrink: 0; }

.hero__copy {
  padding-right: clamp(40px, 5vw, 72px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
}

/* Thesis flow diagram — dark panel, bleeds to viewport edge */
.hero__diagram {
  background: var(--text);
  margin-right: calc(-1 * var(--pad));
  position: relative;
  overflow: hidden;
}

/* Americas map — atmospheric background layer */
.hero__diagram::before {
  content: '';
  position: absolute;
  inset: -10% -5% -10% -15%;
  background-image: url('/assets/americas.svg');
  background-repeat: no-repeat;
  background-size: 140%;
  background-position: 55% 50%;
  filter: invert(1);
  opacity: 0.22;
  pointer-events: none;
}

.thesis-diagram {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: calc(100% - 2 * clamp(32px, 4vw, 52px));
  height: auto;
  display: block;
  z-index: 1;
}

@media (max-width: 820px) {
  .hero__inner { grid-template-columns: 1fr; }
  .hero__copy { padding-right: 0; padding-bottom: clamp(40px, 5vw, 56px); }
  .hero__diagram {
    margin-right: calc(-1 * var(--pad));
    margin-left: calc(-1 * var(--pad));
    min-height: 200px;
  }
}

@media (max-width: 480px) {
  .hero__diagram { display: none; }
}

/* --- Strip --------------------------------------------------- */
.strip {
  background: var(--surface);
  border-bottom: 1px solid var(--divider);
  padding-block: 22px;
}

.strip__inner {
  display: flex;
  align-items: center;
  gap: 0;
  flex-wrap: wrap;
}

.strip__item {
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-light);
}

.strip__sep {
  display: inline-block;
  width: 1px;
  height: 12px;
  background: var(--divider-dark);
  margin-inline: 20px;
  vertical-align: middle;
  flex-shrink: 0;
}

/* --- Pillars (home) ----------------------------------------- */
.pillars {
  padding-block: var(--section-y);
}

.pillars__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0 clamp(32px, 5vw, 56px);
}

.pillar {
  padding-top: 32px;
  border-top: 1px solid var(--text);
}

.pillar__label {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
}

.pillar__body {
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--text-mid);
}

/* --- Home CTA (dark section) -------------------------------- */
.home-cta {
  background: var(--text);
  padding-block: var(--section-y);
}

.home-cta__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 40px;
}

.home-cta__text {
  font-family: var(--font-serif);
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  font-weight: 400;
  color: var(--base);
  line-height: 1.2;
  letter-spacing: -0.01em;
}

/* --- Page header --------------------------------------------- */
.page-header {
  padding-block: clamp(56px, 7vw, 96px);
  border-bottom: 1px solid var(--divider);
}

.page-header__title {
  font-size: clamp(2rem, 4vw, 3.2rem);
  font-weight: 400;
  color: var(--text);
  margin-bottom: 24px;
}

.page-header__intro {
  max-width: 640px;
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--text-mid);
}

/* --- Thesis sections ---------------------------------------- */
.thesis-section {
  padding-block: var(--section-y);
  border-bottom: 1px solid var(--divider);
}

.thesis-section:last-child { border-bottom: none; }

.thesis-num {
  font-family: var(--font-serif);
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--accent);
  margin-bottom: 6px;
}

.thesis-heading {
  font-size: clamp(1.5rem, 2.5vw, 2rem);
  font-weight: 400;
  margin-bottom: 0;
}

.definition-list {
  margin-top: 36px;
}

.definition-item {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 0 clamp(24px, 4vw, 48px);
  padding-block: 22px;
  border-top: 1px solid var(--divider);
  align-items: baseline;
}

.definition-item:last-child { border-bottom: 1px solid var(--divider); }

.definition-term {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text);
}

.definition-detail {
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--text-mid);
}

.thesis-body {
  font-size: 1rem;
  line-height: 1.8;
  color: var(--text-mid);
  max-width: 680px;
  margin-top: 32px;
}

/* --- Timeline ----------------------------------------------- */
.timeline {
  margin-top: 48px;
}

.timeline__track {
  display: flex;
  align-items: flex-start;
  position: relative;
  padding-top: 32px;
}

.timeline__track::before {
  content: '';
  position: absolute;
  top: 10px;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--divider);
}

.timeline__phase {
  flex: 1;
  position: relative;
  padding-top: 28px;
}

.timeline__phase::before {
  content: '';
  position: absolute;
  top: -22px;
  left: 0;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--divider-dark);
  border: 2px solid var(--base);
  box-shadow: 0 0 0 1px var(--divider-dark);
}

.timeline__phase--complete::before {
  background: var(--text);
  box-shadow: 0 0 0 1px var(--text);
}

.timeline__phase--active::before {
  background: var(--accent);
  box-shadow: 0 0 0 3px var(--base), 0 0 0 4px var(--accent);
}

.timeline__phase-label {
  font-family: var(--font-serif);
  font-size: 1rem;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 6px;
}

.timeline__phase--active .timeline__phase-label {
  color: var(--accent);
}

.timeline__phase-detail {
  font-size: 0.82rem;
  color: var(--text-light);
  line-height: 1.5;
  max-width: 200px;
}

/* --- Team --------------------------------------------------- */
.team-section {
  padding-block: var(--section-y);
}

.person-block {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 0 clamp(48px, 6vw, 80px);
  align-items: start;
  padding-bottom: var(--section-y);
  border-bottom: 1px solid var(--divider);
}

.person-meta {}

.person-name {
  font-family: var(--font-serif);
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 400;
  color: var(--text);
  margin-bottom: 6px;
}

.person-title {
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 32px;
}

.person-credentials {
  list-style: none;
  border-top: 1px solid var(--divider);
  padding-top: 24px;
}

.person-credentials li {
  font-size: 0.82rem;
  color: var(--text-mid);
  padding-block: 7px;
  border-bottom: 1px solid var(--divider);
  line-height: 1.4;
}

.person-bio {}

.person-bio p {
  font-size: 1rem;
  line-height: 1.8;
  color: var(--text-mid);
  margin-bottom: 1.2em;
}

.person-bio p:last-child { margin-bottom: 0; }

.network-section {
  padding-top: var(--section-y);
  border-top: 1px solid var(--divider);
}

.placeholder-note {
  font-size: 0.82rem;
  color: var(--text-light);
  font-style: italic;
  padding: 20px;
  border: 1px dashed var(--divider);
  border-left: 3px solid var(--accent-light);
  margin-top: 24px;
}

/* --- Contact ------------------------------------------------ */
.contact-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 0 clamp(48px, 7vw, 100px);
  align-items: start;
}

.contact-form {}

.form-group {
  margin-bottom: 24px;
}

.form-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text);
  margin-bottom: 8px;
}

.form-control {
  display: block;
  width: 100%;
  padding: 11px 14px;
  font-size: 0.95rem;
  color: var(--text);
  background: var(--base);
  border: 1px solid var(--divider-dark);
  border-radius: var(--radius);
  transition: border-color var(--transition), box-shadow var(--transition);
  appearance: none;
  -webkit-appearance: none;
}

.form-control:focus {
  outline: none;
  border-color: var(--text);
  box-shadow: 0 0 0 3px rgba(20,33,46,0.08);
}

.form-control::placeholder { color: var(--text-light); }

textarea.form-control { resize: vertical; min-height: 130px; }

select.form-control {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236B7F8E' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
}

.form-submit {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 8px;
  padding: 13px 28px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--base);
  background: var(--text);
  border: 1px solid var(--text);
  cursor: pointer;
  transition: background var(--transition), border-color var(--transition);
}

.form-submit:hover { background: var(--text-mid); border-color: var(--text-mid); }

.form-after {
  margin-top: 20px;
  font-size: 0.82rem;
  color: var(--text-light);
}

.contact-aside {}

.contact-aside__heading {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-light);
  margin-bottom: 12px;
}

.contact-aside__email {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  font-weight: 400;
  color: var(--text);
  text-decoration: none;
  border-bottom: 1px solid var(--divider);
  padding-bottom: 3px;
  transition: border-color var(--transition), color var(--transition);
}

.contact-aside__email:hover { color: var(--accent); border-color: var(--accent); }

.contact-aside__note {
  margin-top: 20px;
  font-size: 0.85rem;
  color: var(--text-light);
  line-height: 1.65;
}

/* Form success message */
.form-success {
  display: none;
  padding: 20px 24px;
  border-left: 3px solid var(--accent);
  background: var(--surface);
  font-size: 0.95rem;
  color: var(--text);
  margin-top: 16px;
}

.form-success.visible { display: block; }

/* --- Footer ------------------------------------------------- */
.footer {
  border-top: 1px solid var(--divider);
  padding-block: 40px;
  margin-top: 0;
}

.footer__inner {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.footer__row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 24px;
  padding-bottom: 24px;
}

.footer__brand {
  font-family: var(--font-serif);
  font-size: 1.1rem;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 6px;
}

.footer__meta {
  font-size: 0.78rem;
  color: var(--text-light);
}

.footer__nav-unused {
  display: flex;
  gap: 24px;
  list-style: none;
  justify-content: flex-end;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.footer__nav a {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--text-light);
  transition: color var(--transition);
}

.footer__nav a:hover { color: var(--text); }

.footer__disclaimer {
  padding-top: 24px;
  border-top: 1px solid var(--divider);
  font-size: 0.75rem;
  color: var(--text-light);
  line-height: 1.7;
}

.footer__disclaimer mark {
  background: #FFF3CD;
  color: #856404;
  padding: 0 2px;
  font-weight: 500;
}

/* --- Utilities ---------------------------------------------- */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 13px 28px;
  background: var(--text);
  color: var(--base);
  cursor: pointer;
  transition: background var(--transition), gap var(--transition);
}

.btn:hover { background: var(--text-mid); gap: 16px; }

.btn--outline {
  background: transparent;
  color: var(--base);
  border: 1.5px solid rgba(250, 249, 247, 0.45);
}

.btn--outline:hover {
  background: rgba(250, 249, 247, 0.1);
  border-color: var(--base);
}

/* --- Hero entrance ------------------------------------------ */
@keyframes heroReveal {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}

.hero__copy {
  animation: heroReveal 0.55s ease-out both;
  animation-delay: 0.05s;
}

/* --- Diagram draw-in ---------------------------------------- */
@keyframes diagDraw {
  to { stroke-dashoffset: 0; }
}

@keyframes diagFade {
  to { opacity: 1; }
}

.diag-box {
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  animation: diagDraw 0.5s ease-out both;
}
.diag-left  { animation-delay: 0.2s; }
.diag-right { animation-delay: 0.7s; }

.diag-line {
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  animation: diagDraw 0.35s ease-out both;
  animation-delay: 0.55s;
}

.diag-head, .diag-label, .diag-text {
  opacity: 0;
  animation: diagFade 0.3s ease-out both;
}
.diag-head  { animation-delay: 0.8s; }
.diag-label { animation-delay: 0.7s; }
.diag-text  { animation-delay: 0.85s; }

/* Fade-in on scroll */
.fade-in {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 500ms ease, transform 500ms ease;
}

.fade-in.visible {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  .fade-in { transition: opacity 200ms ease; transform: none; }
  .hero__copy { animation: none; }
  .diag-box, .diag-line { animation: none; stroke-dasharray: none; stroke-dashoffset: 0; }
  .diag-head, .diag-label, .diag-text { animation: none; opacity: 1; }
}

/* --- Responsive ---------------------------------------------- */
@media (max-width: 900px) {
  .pillars__grid { grid-template-columns: 1fr; gap: 36px 0; }
  .split { grid-template-columns: 1fr; }
  .split__label { position: static; margin-bottom: 6px; }
  .definition-item { grid-template-columns: 1fr; gap: 6px 0; }
  .person-block { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .contact-aside { border-top: 1px solid var(--divider); padding-top: 40px; margin-top: 0; }
  .home-cta__inner { gap: 32px; }
  .timeline__track { flex-direction: column; gap: 36px; }
  .timeline__track::before { display: none; }
  .timeline__phase { padding-top: 0; }
  .timeline__phase::before { display: none; }
  .timeline__phase-detail { max-width: none; }
  .footer__row { flex-direction: column; gap: 6px; }
}

@media (max-width: 640px) {
  .nav__links { display: none; }
  .nav__links.open {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 60px;
    left: 0; right: 0;
    background: var(--base);
    border-bottom: 1px solid var(--divider);
    padding: 24px clamp(20px, 5vw, 64px);
    gap: 20px;
    z-index: 99;
  }
  .nav__links.open a { font-size: 1rem; text-transform: none; letter-spacing: 0; }
  .nav__toggle { display: flex; }
  .strip__inner { flex-direction: column; align-items: flex-start; gap: 6px; }
  .strip__sep { display: none; }
}
