/* ==========================================================================
   Ben Crosbie — personal site
   Palette derived from The DRIPBaR brand:
     #0E9EC1 primary cyan-blue · #1E404A deep teal · #F7B80C gold accent
   ========================================================================== */

:root {
  --navy-950: #071620;
  --navy-900: #0B1F2A;
  --navy-800: #102E3C;
  --navy-700: #1E404A;
  --line:     rgba(255, 255, 255, 0.10);
  --line-2:   rgba(255, 255, 255, 0.18);

  --cyan-500: #0E9EC1;
  --cyan-400: #2BB8D9;
  --gold:     #F7B80C;

  --text:      #EEF4F7;
  --text-soft: #A9BDC7;
  --text-mute: #7B929E;

  --max: 1120px;
  --gut: 24px;

  --ff-head: "Sora", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --ff-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  --r-sm: 8px;
  --r-md: 14px;
  --r-lg: 22px;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--ff-body);
  font-size: 17px;
  line-height: 1.7;
  color: var(--text);
  background: var(--navy-950);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: var(--cyan-400); text-decoration: none; }
a:hover { color: var(--gold); }

h1, h2, h3, h4 {
  font-family: var(--ff-head);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.02em;
  margin: 0 0 0.5em;
}

h1 { font-size: clamp(2.6rem, 7vw, 4.4rem); }
h2 { font-size: clamp(1.9rem, 4vw, 2.6rem); }
h3 { font-size: 1.15rem; letter-spacing: -0.01em; }

p { margin: 0 0 1.1em; }
p:last-child { margin-bottom: 0; }

.wrap {
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--gut);
}

.eyebrow {
  font-family: var(--ff-head);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.19em;
  text-transform: uppercase;
  color: var(--cyan-400);
  margin: 0 0 1.1rem;
}
.eyebrow--gold { color: var(--gold); }

.lede { font-size: 1.16rem; color: var(--text-soft); }

.skip {
  position: absolute; left: -9999px; top: 0;
  background: var(--gold); color: var(--navy-950);
  padding: 12px 18px; border-radius: 0 0 var(--r-sm) 0; z-index: 100;
  font-weight: 600;
}
.skip:focus { left: 0; }

:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }

/* ---------- Header / nav ---------------------------------------------- */

.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(7, 22, 32, 0.82);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between;
  gap: 20px; min-height: 68px;
}

.brand {
  font-family: var(--ff-head);
  font-weight: 700; font-size: 1.02rem;
  letter-spacing: -0.01em; color: var(--text);
  display: inline-flex; align-items: center; gap: 10px;
}
.brand:hover { color: var(--text); }
.brand .dot {
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--cyan-500);
  box-shadow: 0 0 0 4px rgba(14, 158, 193, 0.18);
  flex: none;
}

.nav { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }

.nav a {
  font-size: 0.93rem; font-weight: 500;
  color: var(--text-soft);
  padding: 8px 12px; border-radius: var(--r-sm);
}
.nav a:hover { color: var(--text); background: rgba(255, 255, 255, 0.06); }
.nav a[aria-current="page"] { color: var(--text); }
.nav a[aria-current="page"]::after {
  content: ""; display: block; height: 2px; margin-top: 4px;
  background: var(--gold); border-radius: 2px;
}
.nav .nav-cta {
  margin-left: 6px; color: var(--navy-950); background: var(--cyan-500);
  font-weight: 600; padding: 9px 16px;
}
.nav .nav-cta:hover { background: var(--cyan-400); color: var(--navy-950); }
.nav .nav-cta::after { display: none; }

/* ---------- Buttons ---------------------------------------------------- */

.btn {
  display: inline-flex; align-items: center; gap: 9px;
  font-family: var(--ff-head); font-weight: 600; font-size: 0.95rem;
  padding: 14px 26px; border-radius: 999px;
  border: 1px solid transparent;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn--primary { background: var(--gold); color: var(--navy-950); }
.btn--primary:hover { background: #ffc832; color: var(--navy-950); }
.btn--ghost { border-color: var(--line-2); color: var(--text); }
.btn--ghost:hover { border-color: var(--cyan-400); color: var(--text); background: rgba(14, 158, 193, 0.10); }

.btn-row { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }

/* ---------- Sections --------------------------------------------------- */

.section { padding: clamp(68px, 9vw, 110px) 0; }
.section--alt { background: var(--navy-900); border-block: 1px solid var(--line); }
.section-head { max-width: 62ch; margin-bottom: 52px; }

/* ---------- Hero ------------------------------------------------------- */

.hero {
  position: relative; overflow: hidden;
  background:
    radial-gradient(1000px 520px at 78% -8%, rgba(14, 158, 193, 0.30), transparent 62%),
    radial-gradient(760px 460px at 4% 108%, rgba(30, 64, 74, 0.85), transparent 66%),
    linear-gradient(170deg, var(--navy-900) 0%, var(--navy-950) 72%);
  padding: clamp(60px, 8vw, 104px) 0 clamp(60px, 8vw, 96px);
}
.hero::after {
  content: ""; position: absolute; inset: auto 0 0 0; height: 3px;
  background: linear-gradient(90deg, var(--cyan-500), var(--gold) 65%, transparent);
  opacity: 0.85;
}

.hero .wrap {
  display: grid; gap: clamp(40px, 6vw, 72px);
  grid-template-columns: 1.25fr 0.9fr; align-items: center;
}

.hero h1 { margin-bottom: 0.32em; }
.hero-title-sub {
  font-family: var(--ff-head); font-weight: 600;
  font-size: clamp(1.05rem, 2.1vw, 1.35rem);
  color: var(--cyan-400); margin: 0 0 1.1rem; letter-spacing: -0.01em;
}
.hero p.lede { max-width: 54ch; }

/* portrait */
.portrait { position: relative; justify-self: center; width: min(360px, 100%); }
.portrait::before {
  content: ""; position: absolute; inset: 16px -16px -16px 16px;
  border: 1px solid var(--cyan-500); border-radius: var(--r-lg); opacity: 0.55;
}
.portrait img {
  position: relative; width: 100%; height: auto; aspect-ratio: 1 / 1; object-fit: cover; object-position: 50% 18%;
  border-radius: var(--r-lg);
  border: 1px solid var(--line-2);
  box-shadow: 0 28px 60px rgba(0, 0, 0, 0.5);
  filter: saturate(1.04) contrast(1.02);
}
.portrait figcaption {
  position: relative; margin-top: 18px;
  font-size: 0.78rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--text-mute); font-family: var(--ff-head); font-weight: 600;
}

/* Cutout variant: the subject is knocked out of his background, so instead of
   sitting in a frame he stands on a soft cyan plate. Double class keeps these
   winning over the framed rules in the responsive blocks below. */
.portrait.portrait--cutout::before {
  inset: 2% -8% 8% -8%;
  border: 0; border-radius: 0; opacity: 1;
  background: radial-gradient(58% 54% at 50% 36%,
              rgba(14, 158, 193, 0.34), rgba(14, 158, 193, 0.07) 56%, transparent 72%);
}
.portrait.portrait--cutout img {
  border: 0; border-radius: 0; background: none; box-shadow: none;
  object-fit: contain; object-position: 50% 100%;
  filter: drop-shadow(0 24px 34px rgba(0, 0, 0, 0.55));
}
.portrait.portrait--cutout figcaption { text-align: center; }

/* ---------- Stat strip -------------------------------------------------- */

.stats {
  background: var(--navy-800);
  border-bottom: 1px solid var(--line);
}
.stats .wrap {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 1px; background: var(--line); border-inline: 1px solid var(--line);
}
.stat { background: var(--navy-800); padding: 34px 26px; }
.stat b {
  display: block; font-family: var(--ff-head); font-weight: 700;
  font-size: clamp(1.9rem, 3.4vw, 2.5rem); line-height: 1;
  color: var(--gold); letter-spacing: -0.03em;
}
.stat span {
  display: block; margin-top: 10px; font-size: 0.86rem;
  color: var(--text-soft); line-height: 1.45;
}

/* ---------- Cards ------------------------------------------------------- */

.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }

.card {
  background: linear-gradient(180deg, rgba(255,255,255,0.045), rgba(255,255,255,0.015));
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 30px 28px 32px;
  position: relative;
}
.card::before {
  content: ""; position: absolute; top: 0; left: 28px; right: 28px; height: 2px;
  background: var(--cyan-500); border-radius: 0 0 2px 2px;
}
.card .role {
  font-size: 0.74rem; letter-spacing: 0.15em; text-transform: uppercase;
  color: var(--gold); font-weight: 600; font-family: var(--ff-head);
  margin: 0 0 12px;
}
.card h3 { margin-bottom: 10px; }
.card p { font-size: 0.97rem; color: var(--text-soft); }
.card .card-link { font-size: 0.9rem; font-weight: 600; display: inline-block; margin-top: 14px; }

/* ---------- Pull quote --------------------------------------------------- */

.quote {
  border-left: 3px solid var(--gold);
  padding: 6px 0 6px 30px; margin: 0;
  max-width: 34ch;
}
.quote blockquote {
  margin: 0; font-family: var(--ff-head); font-weight: 600;
  font-size: clamp(1.3rem, 2.8vw, 1.9rem); line-height: 1.32;
  letter-spacing: -0.02em; color: var(--text);
}
.quote figcaption { margin-top: 16px; color: var(--text-mute); font-size: 0.88rem; }

.split {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: clamp(36px, 6vw, 72px); align-items: center;
}

/* ---------- Timeline ------------------------------------------------------ */

.timeline { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--line-2); }
.timeline li { position: relative; padding: 0 0 38px 30px; }
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before {
  content: ""; position: absolute; left: -6px; top: 9px;
  width: 11px; height: 11px; border-radius: 50%;
  background: var(--navy-950); border: 2px solid var(--cyan-500);
}
.timeline li.is-current::before { background: var(--gold); border-color: var(--gold); }
.timeline .yr {
  display: block; font-family: var(--ff-head); font-weight: 600;
  font-size: 0.76rem; letter-spacing: 0.15em; text-transform: uppercase;
  color: var(--text-mute); margin-bottom: 6px;
}
.timeline h3 { margin-bottom: 4px; font-size: 1.08rem; }
.timeline .org { color: var(--cyan-400); font-size: 0.93rem; font-weight: 500; }
.timeline p { margin-top: 10px; font-size: 0.96rem; color: var(--text-soft); max-width: 62ch; }

/* ---------- Contact ------------------------------------------------------- */

.contact-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.contact-list li {
  border: 1px solid var(--line); border-radius: var(--r-md);
  background: rgba(255, 255, 255, 0.025);
  padding: 22px 26px;
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 18px;
}
.contact-list .label {
  font-family: var(--ff-head); font-size: 0.74rem; font-weight: 600;
  letter-spacing: 0.15em; text-transform: uppercase; color: var(--text-mute);
  min-width: 110px;
}
.contact-list .value { font-size: 1.02rem; font-weight: 500; }
.contact-list .note { flex-basis: 100%; font-size: 0.9rem; color: var(--text-mute); }

/* ---------- CTA band ------------------------------------------------------ */

.cta-band {
  background:
    radial-gradient(760px 380px at 20% 0%, rgba(14, 158, 193, 0.28), transparent 65%),
    var(--navy-800);
  border-top: 1px solid var(--line);
}
.cta-band .wrap {
  padding-block: clamp(56px, 7vw, 88px);
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 30px;
}
.cta-band h2 { margin: 0; max-width: 22ch; }
.cta-band .btn-row { margin-top: 0; }

/* ---------- Footer -------------------------------------------------------- */

.site-footer {
  background: var(--navy-950);
  border-top: 1px solid var(--line);
  padding: 40px 0;
  font-size: 0.88rem; color: var(--text-mute);
}
.site-footer .wrap {
  display: flex; flex-wrap: wrap; gap: 14px 28px;
  align-items: center; justify-content: space-between;
}
.site-footer nav { display: flex; gap: 20px; flex-wrap: wrap; }
.site-footer a { color: var(--text-soft); }
.site-footer a:hover { color: var(--gold); }

/* ---------- Responsive ----------------------------------------------------- */

@media (max-width: 900px) {
  .hero .wrap { grid-template-columns: 1fr; }
  .portrait { order: -1; justify-self: start; width: min(260px, 70%); }
  .portrait::before { inset: 12px -12px -12px 12px; }
  .stats .wrap { grid-template-columns: repeat(2, 1fr); }
  .cards { grid-template-columns: 1fr; }
  .split { grid-template-columns: 1fr; }
  .quote { max-width: none; }
}

@media (max-width: 620px) {
  body { font-size: 16px; }
  .site-header .wrap { min-height: 58px; gap: 8px; }
  .brand { font-size: 0.95rem; }
  .nav { gap: 0; flex-wrap: nowrap; }
  .nav a { padding: 7px 8px; font-size: 0.86rem; }
  /* The header CTA is redundant on a narrow screen -- the CTA band and footer carry it. */
  .nav .nav-cta { display: none; }
  .hero { padding-top: 44px; }
  .portrait::before { display: none; }
  .portrait figcaption { font-size: 0.7rem; letter-spacing: 0.1em; margin-top: 14px; }
  .stat { padding: 26px 20px; }
  .btn { padding: 13px 22px; }
  .cta-band .wrap { flex-direction: column; align-items: flex-start; }
  .contact-list li { padding: 20px; }
  .contact-list .label { min-width: 0; flex-basis: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn:hover { transform: none; }
  * { transition: none !important; }
}
