/* The Founders Circle.
   Colours come from the two sister sites: the JSW Fund navy and gold, and the
   Sovereign Cove sea. Type: Instrument Serif (Sovereign Cove) for the voice,
   Red Hat Display (JSW Fund) for everything functional. */
:root {
  --abyss: #030D22;      /* page ground: the JSW navy, taken deeper */
  --ink: #06183A;        /* JSW Fund navy */
  --gold: #D4B26C;       /* JSW Fund gold: the ring, headings, rules */
  --sea: #7FC8C6;        /* Sovereign Cove sea: focus and hover only */
  --ivory: #F3EFE6;      /* text */
  --ivory-60: rgba(243, 239, 230, .62);
  --rule: rgba(212, 178, 108, .28);
  --serif: "Instrument Serif", "Iowan Old Style", Georgia, serif;
  --sans: "Red Hat Display", system-ui, -apple-system, "Segoe UI", sans-serif;
  --measure: 34rem;
  --ease: cubic-bezier(.22, 1, .36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--abyss);
  color: var(--ivory);
  font: 300 1.0625rem/1.75 var(--sans);
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
:focus-visible { outline: 1px solid var(--sea); outline-offset: 6px; }
.skip { position: absolute; left: -999px; top: 0; padding: .75rem 1rem; background: var(--gold); color: var(--abyss); }
.skip:focus { left: 0; z-index: 2; }

/* ---- Hero: the Circle ---------------------------------------------------- */
.hero {
  min-height: 100svh;
  display: grid;
  grid-template-rows: 1fr auto;
  justify-items: center;
  align-items: center;
  padding: 6vh 1.5rem 5vh;
  background: radial-gradient(70% 56% at 50% 42%, var(--ink) 0%, var(--abyss) 100%);
}
.circle {
  position: relative;
  width: min(86vw, 72svh, 44rem);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  container-type: inline-size;
}
.ring { position: absolute; inset: 0; width: 100%; height: 100%; }
.ring path {
  stroke: var(--gold);
  stroke-width: 1px;
  vector-effect: non-scaling-stroke;
  opacity: 0;
  animation: seat .9s var(--ease) forwards;
  animation-delay: calc(var(--i) * 4ms + 300ms);
}
@keyframes seat { to { opacity: .9; } }

.circle-in { text-align: center; padding: 0 6%; animation: arrive 1.6s var(--ease) 1.2s both; }
@keyframes arrive { from { opacity: 0; } to { opacity: 1; } }
/* The name is sized from the ring itself, so it fills the circle on every screen. */
.circle .chair { font-size: 5.4cqw; margin-bottom: 1cqw; }
.circle h1 { font-size: 13.5cqw; }
.chair {
  margin: 0 0 .4rem;
  font: italic 400 clamp(1.15rem, 3.4vw, 1.75rem)/1 var(--serif);
  color: var(--gold);
}
h1 {
  margin: 0;
  font: 400 clamp(2.4rem, 8.6vw, 5.25rem)/.98 var(--serif);
  letter-spacing: -.01em;
}
.seats {
  margin: 1.5rem 0 0;
  font: 400 .75rem/1 var(--sans);
  letter-spacing: .34em;
  text-transform: uppercase;
  color: var(--ivory-60);
  padding-left: .34em;
}

.nav { display: flex; gap: clamp(1.5rem, 6vw, 3.5rem); margin-top: 4vh; animation: arrive 1.6s var(--ease) 2.4s both; }
.nav a {
  font: 400 .75rem/1 var(--sans);
  letter-spacing: .28em;
  text-transform: uppercase;
}
.nav a { font-size: clamp(.75rem, .6rem + .4vw, .95rem); text-decoration: none; color: var(--ivory-60); padding: .75rem 0; transition: color .3s; }
.nav a:hover { color: var(--sea); }

/* ---- The creed: short statements, set small and in capitals ---------------- */
.creed {
  margin: 0 auto;
  padding: clamp(2rem, 6vh, 4rem) 1.5rem clamp(5rem, 14vh, 8rem);
  text-align: center;
  font-size: clamp(.875rem, .6rem + .85vw, 1.3rem);
}
.creed p {
  max-width: 44em;
  margin: 0 auto;
  font: 400 1em/2.05 var(--sans);
  letter-spacing: .22em;
  text-transform: uppercase;
  text-wrap: balance;
}
.nb { white-space: nowrap; }
.creed p + p { margin-top: 1.9em; }
.creed .nav { justify-content: center; margin-top: 3.2em; animation: none; }
.creed .nav a { color: var(--gold); }
.creed .nav a:hover { color: var(--sea); }

/* ---- Contact page -------------------------------------------------------------- */
.contact-page { min-height: 100svh; display: grid; grid-template-rows: auto 1fr; }
.mast { padding: clamp(2.5rem, 8vh, 4.5rem) 1.5rem 0; text-align: center; }
.mast a { text-decoration: none; display: inline-block; }
.mast .chair { display: block; font-size: 1.05rem; margin-bottom: .2rem; }
.mast .name { display: block; font: 400 2rem/1 var(--serif); }
.contact { align-self: center; padding: 4rem 1.5rem; text-align: center; }
.contact h1 {
  margin: 0 0 2.75rem;
  color: var(--gold);
  font: 400 .8125rem/1 var(--sans);
  letter-spacing: .28em;
  text-transform: uppercase;
}
address, .mail { font: 300 1rem/2 var(--sans); letter-spacing: .06em; font-style: normal; }
.mail { margin: 1.75rem 0 0; }
.mail b { font-weight: 500; }
.mail a {
  color: var(--gold);
  text-decoration: none;
  border-bottom: 1px solid var(--rule);
  overflow-wrap: anywhere;
  transition: color .3s, border-color .3s;
}
.mail a:hover { color: var(--sea); border-bottom-color: var(--sea); }
.contact .nav { justify-content: center; margin-top: 3.5rem; animation: none; }

/* ---- 404 ---------------------------------------------------------------------- */
.lost { min-height: 100svh; display: grid; place-content: center; text-align: center; padding: 2rem; }
.lost h1 { font-size: clamp(2rem, 6vw, 3.25rem); }
.lost a { color: var(--gold); letter-spacing: .28em; text-transform: uppercase; font: 400 .75rem var(--sans); text-decoration: none; }

/* ---- Wide screens: the ring forms in the centre, then moves to the left half
        and the statements come in on the right. One screen, no scrolling. ---- */
@media (min-width: 64rem) and (min-height: 34rem) {
  .stage { display: grid; grid-template-columns: 1fr 1fr; align-items: center; min-height: 100svh; overflow: hidden; }
  .hero {
    background: radial-gradient(50% 50% at 50% 46%, var(--ink) 0%, var(--abyss) 100%);
    animation: settle 1.6s var(--ease) 3.3s both;
  }
  .circle { width: min(40vw, 72svh, 44rem); }
  .creed {
    padding: 4rem clamp(2rem, 6vw, 7rem) 4rem 0;
    text-align: left;
    font-size: clamp(.8125rem, .42rem + .62vw, 1.15rem);
  }
  .creed p { max-width: 34em; margin: 0; text-wrap: pretty; opacity: 0; animation: enter 1.5s var(--ease) 4.3s forwards; }
  .creed p:nth-child(2) { animation-delay: 4.65s; }
  .creed p:nth-child(3) { animation-delay: 5s; }
  .creed .nav { justify-content: flex-start; opacity: 0; animation: enter 1.5s var(--ease) 5.4s forwards; }
}
@keyframes settle { from { transform: translateX(50%); } to { transform: none; } }
@keyframes enter { from { opacity: 0; transform: translateX(1.5rem); } to { opacity: 1; transform: none; } }

@media (max-width: 34rem) {
  .ring path { stroke-width: .7px; }
  .creed p { letter-spacing: .16em; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .ring path { animation: none; opacity: .9; }
  .circle-in, .nav { animation: none; }
  .hero { animation: none; }
  .creed p { animation: none; opacity: 1; }
  .creed .nav { animation: none; opacity: 1; }
}