@font-face { font-family: "Michroma"; src: url("/assets/fonts/michroma-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Montserrat"; src: url("/assets/fonts/montserrat-latin-300-normal.woff2") format("woff2"); font-weight: 300; font-display: swap; }
@font-face { font-family: "Montserrat"; src: url("/assets/fonts/montserrat-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Montserrat"; src: url("/assets/fonts/montserrat-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-display: swap; }

:root {
  --ink: #231F20;
  --stone: #A19E95;
  --bone: #E9E9E9;
  --slate: #73716D;
  --rule: rgba(161, 158, 149, 0.32);
  --ocean: #0F4C6D;
  --emerald: #0E6B57;
  --emerald-bright: #41A58A;
  --sea-glass: #8FB8CC;
  --pad: clamp(1.5rem, 6vw, 6rem);
  --display: "Michroma", "Eurostile", "Helvetica Neue", Arial, sans-serif;
  --text: "Montserrat", "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--ink);
  color: var(--bone);
  font-family: var(--text);
  font-weight: 300;
  font-size: 1.125rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

h1, h2 { font-family: var(--display); font-weight: 400; margin: 0; }
p { margin: 0 0 1.2em; }
a { color: inherit; }

:focus-visible { outline: 2px solid var(--emerald-bright); outline-offset: 4px; }

/* Top bar — sticky */
.bar {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 10;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.1rem var(--pad);
  background: rgba(35, 31, 32, 0.84);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(161, 158, 149, 0.16);
}
.mark {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  text-decoration: none;
  color: var(--stone);
  font-family: var(--display);
  font-size: 0.8rem;
  letter-spacing: 0.06em;
}
.mark img { display: block; width: 40px; height: auto; }
.bar-right { display: flex; align-items: center; gap: 1rem; }
.bar-link {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--bone);
  text-decoration: none;
  background: var(--emerald);
  padding: 0.65rem 1.15rem;
  border-radius: 2px;
}
.bar-link:hover { background: #0B5746; }
.theme-btn {
  font-family: var(--display);
  font-size: 0.62rem;
  letter-spacing: 0.04em;
  color: var(--stone);
  background: transparent;
  border: 1px solid var(--rule);
  border-radius: 2px;
  padding: 0.68rem 0.95rem;
  cursor: pointer;
  white-space: nowrap;
}
.theme-btn:hover { color: var(--bone); border-color: var(--stone); }

/* Hero */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: flex-end;
  padding: 8rem var(--pad) clamp(3rem, 9vh, 6rem);
  overflow: hidden;
  background: linear-gradient(165deg, #0E3B52 0%, var(--ink) 58%);
}
.hero-loop { position: absolute; inset: 0; overflow: hidden; }
.hero-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.55;
}
.hero-loop.video-on img { opacity: 0 !important; }
.hero-loop img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 1.8s ease;
}
.hero-loop img.is-on { opacity: 0.55; }
@media (prefers-reduced-motion: no-preference) {
  .hero-loop img.is-on { animation: rb-drift 9s ease-out forwards; }
  @keyframes rb-drift {
    from { transform: scale(1); }
    to { transform: scale(1.07); }
  }
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(35, 31, 32, 0.92) 0%, rgba(35, 31, 32, 0) 60%);
  pointer-events: none;
}
.hero-inner { position: relative; z-index: 2; max-width: 72rem; }
.hero h1 {
  font-size: clamp(2.3rem, 7vw, 6.4rem);
  line-height: 1.08;
  color: var(--bone);
  margin-bottom: 2rem;
}
.hero-sub {
  max-width: 36ch;
  font-size: clamp(1.05rem, 1.5vw, 1.3rem);
  color: var(--stone);
  margin: 0;
}

/* Light sections */
.light {
  background: var(--bone);
  color: var(--ink);
  padding: clamp(5rem, 14vh, 9rem) var(--pad);
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: clamp(2rem, 8vw, 8rem);
  row-gap: 4rem;
}
.light + .light { padding-top: 0; }
.light h2 {
  font-size: 0.95rem;
  color: var(--slate);
  margin-bottom: 1.75rem;
}
.col { max-width: 34em; }
.col p { font-size: 1.2rem; }

.quiet-line {
  align-self: end;
  font-family: var(--display);
  font-size: clamp(1.35rem, 3vw, 2.4rem);
  line-height: 1.3;
  max-width: 24ch;
  margin: 2rem 0 0;
  color: var(--ocean);
}

.paths { margin: 2.25rem 0 0; }
.paths div {
  display: grid;
  grid-template-columns: 9.5rem 1fr;
  gap: 1.5rem;
  padding: 1.1rem 0;
  border-top: 1px solid rgba(35, 31, 32, 0.18);
}
.paths dt { font-family: var(--display); font-size: 0.9rem; padding-top: 0.25rem; color: var(--emerald); }
.paths dd { margin: 0; font-size: 1.1rem; }

.principal .name {
  font-family: var(--display);
  font-size: clamp(1.4rem, 2.4vw, 1.9rem);
  margin-bottom: 1.5rem;
}
.principal .portrait {
  display: block;
  width: min(300px, 100%);
  height: auto;
  margin-top: 1.75rem;
  filter: saturate(0.85);
}

/* Footprint */
.dark { background: var(--ink); color: var(--bone); padding: clamp(5rem, 14vh, 9rem) var(--pad); }
.footprint-head { display: flex; justify-content: space-between; align-items: baseline; gap: 2rem; flex-wrap: wrap; margin-bottom: 3rem; }
.footprint-head h2, .request-head h2 { font-size: 0.95rem; color: var(--stone); }
.footprint-head p { margin: 0; color: var(--stone); max-width: 30ch; }
.cities { list-style: none; margin: 0; padding: 0; border-bottom: 1px solid var(--rule); }
.cities li {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1.5rem;
  padding: clamp(1rem, 2.4vh, 1.6rem) 0;
  border-top: 1px solid var(--rule);
}
.city { font-family: var(--display); font-size: clamp(1.1rem, 2.6vw, 2.1rem); line-height: 1.2; }
.cities time { color: var(--sea-glass); font-variant-numeric: tabular-nums; font-size: clamp(1rem, 1.6vw, 1.25rem); white-space: nowrap; }

/* Request */
.request { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: clamp(2rem, 8vw, 8rem); }
.request-head p { margin-top: 1.75rem; max-width: 30ch; font-size: 1.2rem; }
.form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.75rem 2rem; }
.form .wide { grid-column: 1 / -1; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.field { display: flex; flex-direction: column; gap: 0.5rem; }
.field span { font-size: 0.85rem; font-weight: 400; color: var(--stone); }
.field input, .field select, .field textarea {
  font: inherit;
  font-size: 1.05rem;
  color: var(--bone);
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--stone);
  border-radius: 0;
  padding: 0.55rem 0;
}
.field textarea { resize: vertical; }
.field select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--stone) 50%), linear-gradient(135deg, var(--stone) 50%, transparent 50%); background-position: calc(100% - 12px) 55%, calc(100% - 6px) 55%; background-size: 6px 6px; background-repeat: no-repeat; }
.field select option { color: var(--ink); }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-bottom-color: var(--emerald-bright); }
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible { outline: 2px solid var(--stone); outline-offset: 4px; }
.submit-row { display: flex; align-items: center; gap: 1.5rem; flex-wrap: wrap; margin-top: 0.5rem; }
.submit-row button {
  font-family: var(--display);
  font-size: 0.85rem;
  color: var(--bone);
  background: var(--emerald);
  border: 0;
  border-radius: 2px;
  padding: 1.05rem 1.6rem;
  cursor: pointer;
}
.submit-row button:hover { background: #0B5746; }
.fine { margin: 0; font-size: 0.85rem; color: var(--stone); max-width: 32ch; }

/* Footer */
.foot {
  display: flex;
  align-items: flex-start;
  gap: 1.5rem;
  padding: 3rem var(--pad) 3.5rem;
  border-top: 1px solid var(--rule);
  color: var(--stone);
  font-size: 0.875rem;
  line-height: 1.6;
}
.foot img { width: 48px; height: auto; }
.foot p { margin: 0; }
.foot a { text-underline-offset: 0.25em; }
.foot .copy { margin-left: auto; }

/* The flip: the boardroom by default, the back room after hours */
html.theme-dark body { background: #121415; }
html.theme-dark .bar { background: rgba(10, 18, 16, 0.84); border-bottom-color: rgba(63, 169, 140, 0.18); }
html.theme-dark .mark { color: #7FA99C; }
html.theme-dark .theme-btn { color: #3FA98C; border-color: rgba(63, 169, 140, 0.4); }
html.theme-dark .theme-btn:hover { color: #DCE8E4; border-color: #3FA98C; }
html.theme-dark .bar-link { background: #3FA98C; color: #0E1513; }
html.theme-dark .bar-link:hover { background: #5FBFA5; }
html.theme-dark .hero {
  background:
    radial-gradient(130% 100% at 85% 0%, rgba(14, 107, 87, 0.42), transparent 55%),
    radial-gradient(90% 70% at 10% 100%, rgba(15, 76, 109, 0.32), transparent 60%),
    linear-gradient(165deg, #0D2B26 0%, #121415 62%);
}
html.theme-dark .hero-loop img.is-on { opacity: 0.3; }
html.theme-dark .hero-video { opacity: 0.3; }
html.theme-dark .hero-loop.video-on img { opacity: 0 !important; }
html.theme-dark .hero::before {
  content: "";
  position: absolute;
  inset: -20%;
  z-index: 1;
  background:
    radial-gradient(40% 30% at 30% 40%, rgba(63, 169, 140, 0.13), transparent 70%),
    radial-gradient(35% 25% at 70% 30%, rgba(143, 184, 204, 0.09), transparent 70%);
  animation: rb-smoke 26s ease-in-out infinite alternate;
  pointer-events: none;
}
@keyframes rb-smoke {
  from { transform: translate3d(-3%, 0, 0) scale(1); }
  to { transform: translate3d(3%, 4%, 0) scale(1.08); }
}
@media (prefers-reduced-motion: reduce) {
  html.theme-dark .hero::before { animation: none; }
}
html.theme-dark .hero h1 { color: #DCE8E4; }
html.theme-dark .hero-sub { color: #7FA99C; }
html.theme-dark .light { background: #1A201E; color: #DFE5E2; }
html.theme-dark .light h2 { color: #6F8F85; }
html.theme-dark .paths div { border-top-color: rgba(143, 184, 204, 0.16); }
html.theme-dark .paths dt { color: #8FB8CC; }
html.theme-dark .quiet-line { color: #3FA98C; text-shadow: 0 0 28px rgba(63, 169, 140, 0.3); }
html.theme-dark .dark { background: linear-gradient(180deg, #0A2434 0%, #121415 90%); }
html.theme-dark .footprint-head h2, html.theme-dark .footprint-head p { color: #8FB8CC; }
html.theme-dark .cities { border-bottom-color: rgba(143, 184, 204, 0.22); }
html.theme-dark .cities li { border-top-color: rgba(143, 184, 204, 0.22); }
html.theme-dark .cities time { color: #3FA98C; text-shadow: 0 0 20px rgba(63, 169, 140, 0.4); }
html.theme-dark .request { background: linear-gradient(180deg, #121415 0%, #0D1F1B 100%); }
html.theme-dark .request-head h2 { color: #8FB8CC; }
html.theme-dark .field span { color: #6F8F85; }
html.theme-dark .field input, html.theme-dark .field select, html.theme-dark .field textarea { border-bottom-color: rgba(143, 184, 204, 0.4); }
html.theme-dark .field input:focus, html.theme-dark .field select:focus, html.theme-dark .field textarea:focus { border-bottom-color: #3FA98C; }
html.theme-dark .submit-row button { background: #3FA98C; color: #0E1513; }
html.theme-dark .submit-row button:hover { background: #5FBFA5; }
html.theme-dark .fine { color: #6F8F85; }
html.theme-dark .foot { color: #6F8F85; border-top-color: rgba(63, 169, 140, 0.16); }

/* Received page */
.received { min-height: 100vh; min-height: 100svh; display: flex; align-items: center; padding: 8rem var(--pad); }
.received h1 { font-size: clamp(1.8rem, 4.5vw, 3.6rem); line-height: 1.12; margin-bottom: 1.5rem; }
.received p { color: var(--stone); max-width: 34ch; font-size: 1.2rem; }

@media (max-width: 820px) {
  .light, .request { grid-template-columns: 1fr; }
  .light + .light { padding-top: 0; }
  .form { grid-template-columns: 1fr; }
  .paths div { grid-template-columns: 1fr; gap: 0.35rem; }
  .mark span { display: none; }
  .bar-link { padding: 0.6rem 0.8rem; }
  .theme-btn { padding: 0.55rem 0.6rem; }
  .foot { flex-wrap: wrap; }
  .foot .copy { margin-left: 0; width: 100%; }
}
