:root {
  --ground: #04161a;
  --ink: #f1ece2;
  --dim: rgba(241, 236, 226, 0.62);
  --line: rgba(241, 236, 226, 0.18);
  --gutter: clamp(16px, 5vw, 64px);
  --serif: 'Fraunces', Georgia, 'Times New Roman', serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  /* fallback when WebGL is unavailable */
  background: linear-gradient(#0b5a63, #021014 70%);
  background-attachment: fixed;
  color: var(--ink);
  font-family: var(--serif);
  font-optical-sizing: auto;
  font-variation-settings: 'SOFT' 50, 'WONK' 0;
  font-weight: 350;
  font-size: 17px;
  line-height: 1.5;
}

#water {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  z-index: 0;
}

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

.small {
  font-size: 13px;
  font-style: italic;
  color: var(--dim);
  margin: 0;
}

/* header */

.bar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 18px var(--gutter);
}

.mark { display: flex; align-items: center; gap: 12px; font-size: 18px; font-variation-settings: 'SOFT' 100, 'WONK' 1; }

.logo { width: 44px; height: auto; filter: invert(1); }

nav { display: flex; gap: 22px; flex-wrap: wrap; justify-content: flex-end; }

nav a { font-size: 15px; color: var(--dim); font-style: italic; }
nav a:hover, nav a.active { color: var(--ink); }
nav a.active { font-style: normal; }

/* views */

main { position: relative; z-index: 1; pointer-events: none; }

.view {
  min-height: 100vh;
  padding: 130px var(--gutter) 90px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 24px;
  max-width: 900px;
}

.view a { pointer-events: auto; }
.view[hidden] { display: none; }

h1 {
  font-weight: 300;
  font-size: clamp(44px, 9vw, 128px);
  line-height: 0.98;
  letter-spacing: -0.02em;
  margin: 0;
}

/* per-letter variable-axis animation, driven by caustic.js */
.wave .word { display: inline-block; white-space: nowrap; }
.wave .ch { display: inline-block; }

.intro { font-size: clamp(18px, 2vw, 22px); max-width: 34ch; margin: 0; }

/* manifesto */

.manifesto { justify-content: flex-start; }
.manifesto ol { list-style: none; margin: 0; padding: 0; }

.statement {
  display: grid;
  grid-template-columns: 2.5em 1fr;
  gap: 12px;
  padding: 18px 0;
  border-top: 1px solid var(--line);
  font-size: clamp(18px, 2.2vw, 26px);
  line-height: 1.3;
}

.statement-index { font-size: 13px; font-style: italic; color: var(--dim); padding-top: 0.5em; }

.epigraph { margin: 28px 0 0; padding: 0 0 0 calc(2.5em + 12px); }
.epigraph p { margin: 0; }
.epigraph-latin { font-style: italic; font-size: 20px; }
.epigraph-english, .epigraph-source { color: var(--dim); }
.epigraph-source { font-size: 13px; margin-top: 6px !important; }

/* team */

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

.member {
  display: grid;
  grid-template-columns: 12em 1fr;
  column-gap: 16px;
  padding: 18px 0;
  border-top: 1px solid var(--line);
}

.member-role { grid-row: span 2; font-style: italic; color: var(--dim); }
.member-name { font-size: 24px; font-variation-settings: 'SOFT' 100, 'WONK' 1; }
.member-bio { color: var(--dim); }

.contact { display: flex; flex-direction: column; gap: 4px; margin: 0; }
.contact a { font-size: clamp(24px, 4vw, 44px); font-style: italic; border-bottom: 1px solid var(--line); align-self: flex-start; }

.hint { position: fixed; right: var(--gutter); bottom: 18px; z-index: 2; }
html:not([data-page="home"]) .hint { display: none; }

@media (max-width: 600px) {
  .bar { flex-direction: column; align-items: flex-start; }
  .member { grid-template-columns: 1fr; }
  .member-role { grid-row: auto; }
  .hint { display: none; }
}
