/* 2nd Advanced Cadaveric Course — Foot & Ankle
   Ported from the "Course Site" design (Modernist system, navy/blue retune). */

/* ── Tokens ─────────────────────────────────────────────── */
:root {
  --navy: #2e3d5f;
  --navy-deep: #252f4a;
  --navy-ink: #1b2440;
  --blue: #8fb5e0;
  --blue-600: #a9c7ea;
  --blue-700: #c4d9f1;
  --slate: #5a7fb0;
  --paper: #f5f7fb;
  --white: #ffffff;
  --rule: #d3dceb;
  --rule-on-navy: rgba(255, 255, 255, .28);
  --rule-on-navy-soft: rgba(255, 255, 255, .2);

  --font: "Montserrat", system-ui, sans-serif;
  --max: 1440px;
  --header-h: 108px;        /* header height at the top of the page */
  --header-h-stuck: 80px;   /* ...and once it has slimmed down */
  --gutter: clamp(24px, 6vw, 80px);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-h-stuck);   /* anchors land below the sticky header */
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--navy);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.55;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  margin: 0;
  font-family: var(--font);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -.015em;
}
p { margin: 0; }
ul, dl { margin: 0; padding: 0; list-style: none; }
img { display: block; max-width: 100%; }

a { color: var(--navy); text-decoration: none; }
a:hover { color: var(--slate); }

sup { font-size: .5em; vertical-align: .9em; line-height: 0; }

:focus { outline: none; }
:focus-visible { outline: 2px solid var(--slate); outline-offset: 2px; }
.on-navy :focus-visible { outline-color: var(--blue); }

::selection { background: rgba(143, 181, 224, .4); }

.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

/* ── Buttons ────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
  padding: 16px 24px;
  font-family: var(--font);
  font-weight: 700;
  font-size: 14px;
  line-height: 1.2;
  border: 1px solid transparent;
  cursor: pointer;
}
.btn-primary { background: var(--blue); color: var(--navy); }
.btn-primary:hover { background: var(--blue-600); color: var(--navy); }
.btn-primary:active { background: var(--blue-700); }
.btn-secondary { color: var(--white); border-color: var(--rule-on-navy); }
.btn-secondary:hover { background: rgba(255, 255, 255, .07); color: var(--white); }
.btn-secondary:active { background: rgba(255, 255, 255, .14); }

/* ── Hero ───────────────────────────────────────────────── */
.hero {
  display: flex;
  flex-direction: column;
  min-height: 100vh;   /* fallback */
  min-height: 100dvh;  /* full visible viewport, even with mobile browser bars */
  background: var(--navy);
  color: var(--white);
  overflow: hidden;
}

/* Sticky header: transparent over the hero, solid navy (and slimmer) once scrolled */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  color: var(--white);
  background: transparent;
  transition: background-color .3s ease, box-shadow .3s ease;
}
.header-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  align-items: center;
  justify-content: space-between;
  padding-top: 28px;
  padding-bottom: 28px;
  transition: padding .3s ease;
}
.site-header.is-stuck {
  background: var(--navy);
  box-shadow: 0 6px 24px rgba(0, 0, 0, .18);
}
.site-header.is-stuck .header-inner { padding-top: 14px; padding-bottom: 14px; }

.brand { color: var(--white); font-weight: 800; font-size: 18px; white-space: nowrap; }
.brand:hover { color: var(--white); }
.brand span { color: var(--blue); }

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  align-items: center;
  font-size: 16px;
  font-weight: 600;
}
.site-nav a { color: var(--white); transition: color .2s ease; }
.site-nav a:hover { color: var(--blue); }

/* Dynamic underline: draws in from the left on hover/focus, retracts to the right */
.site-nav a:not(.nav-cta) {
  position: relative;
  padding: 6px 0;
}
.site-nav a:not(.nav-cta)::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: var(--blue);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform .3s cubic-bezier(.65, 0, .35, 1);
}
.site-nav a:not(.nav-cta):hover::after,
.site-nav a:not(.nav-cta):focus-visible::after {
  transform: scaleX(1);
  transform-origin: left;
}

.site-nav .nav-cta {
  background: var(--white);
  color: var(--navy);
  padding: 14px 24px;
  line-height: 24px;
  font-weight: 700;
  transition: background .2s ease, color .2s ease;
}
.site-nav .nav-cta:hover { background: var(--blue-700); color: var(--navy); }

/* Hamburger (only shown on small screens, and only when JS is available) */
.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  margin-right: -10px;
  padding: 0;
  background: none;
  border: 0;
  color: var(--white);
  cursor: pointer;
  position: relative;
}
.nav-toggle .bar {
  position: absolute;
  left: 10px;
  right: 10px;
  height: 2px;
  background: currentColor;
  transition: transform .3s ease, opacity .2s ease, top .3s ease;
}
.nav-toggle .bar:nth-child(1) { top: 14px; }
.nav-toggle .bar:nth-child(2) { top: 21px; }
.nav-toggle .bar:nth-child(3) { top: 28px; }
.nav-toggle.is-open .bar:nth-child(1) { top: 21px; transform: rotate(45deg); }
.nav-toggle.is-open .bar:nth-child(2) { opacity: 0; }
.nav-toggle.is-open .bar:nth-child(3) { top: 21px; transform: rotate(-45deg); }

@media (max-width: 899.98px) {
  :root { --header-h: 100px; --header-h-stuck: 72px; }   /* hamburger bar is a little shorter */
  .js .header-inner { flex-wrap: nowrap; }
  .js .nav-toggle { display: block; }

  /* Collapsed by default; opens as a panel under the header */
  .js .site-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    flex-wrap: nowrap;
    align-items: stretch;
    gap: 0;
    padding: 4px var(--gutter) 28px;
    background: var(--navy-ink);
    box-shadow: 0 16px 32px rgba(0, 0, 0, .25);
    font-size: 18px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity .25s ease, transform .25s ease, visibility 0s linear .25s;
  }
  .js .site-nav.is-open {
    opacity: 1;
    visibility: visible;
    transform: none;
    transition-delay: 0s;
  }
  .js .site-nav a:not(.nav-cta) {
    padding: 16px 0;
    border-bottom: 1px solid var(--rule-on-navy-soft);
  }
  .js .site-nav a:not(.nav-cta)::after { bottom: -1px; }
  .js .site-nav .nav-cta { margin-top: 20px; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  .site-nav a::after, .nav-toggle .bar, .js .site-nav { transition: none; }
}

/* auto side margins stop a flex child stretching, so give both rows full width */
.hero > .wrap { width: 100%; }

.hero-grid {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 460px), 1fr));
  align-items: center;   /* copy and drawing both centred in the space below the header */
  padding-top: calc(var(--header-h) + 32px);   /* the header is fixed, so make room for it */
  padding-bottom: 40px;
}
.hero-copy {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

/* Date & place — stacked blocks, as on the poster */
.hero-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 16px 32px;
  font-size: clamp(18px, 1.6vw, 24px);
  font-weight: 700;
  line-height: 1.15;
}
.meta-group { display: flex; flex-direction: column; margin: 0; }
.meta-text {
  display: block;
  margin-top: .12em;
  padding: .06em .28em .1em;
  color: var(--blue);
}
.hero-meta .hl { white-space: nowrap; }
.hero-meta sup { font-size: .55em; }

.hero h1 {
  font-size: clamp(34px, min(4.6vw, 7.4vh), 64px);   /* shrinks on short screens so the hero still fits */
  line-height: 1.08;
}
/* Poster detail: the first two lines sit on solid blocks that hug the text */
.hl {
  display: block;
  width: fit-content;
  max-width: 100%;
  padding: .06em .28em .1em;
}
.hl + .hl { margin-top: .12em; }
.hl-light { background: var(--white); color: var(--navy); }
.hl-dark { background: var(--navy-ink); color: var(--white); }
.h1-rest {
  display: block;
  margin-top: .55em;
  text-wrap: balance;
}
.hero h1 .conj { color: var(--blue); font-weight: 500; }

.hero-lede {
  max-width: 520px;
  font-size: 18px;
  line-height: 1.6;
  color: var(--blue-700);
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }

.hero-art {
  width: 125%;
  max-width: none;
  margin-left: -10%;
}

/* Side by side: the grid sits below the header, so lift the drawing by half the
   header's height to centre it on the whole hero rather than on the leftover space */
@media (min-width: 1060px) {
  .hero-art { transform: translateY(calc(var(--header-h) / -2)); }
}

/* ── Numbered sections ──────────────────────────────────── */
.section {
  display: flex;
  flex-wrap: wrap;
  gap: 48px;
}
.section-label {
  flex: 1 1 220px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-top: 20px;
  border-top: 2px solid var(--navy);
}
.section-label .num { font-size: 14px; font-weight: 700; color: var(--slate); }
.section-label h2 { font-size: 22px; }
.section-body { flex: 3 1 480px; min-width: 0; }

.on-navy .section-label { border-top-color: var(--blue); }
.on-navy .section-label .num { color: var(--blue); }

/* Welcome */
#welcome { padding-top: 112px; padding-bottom: 112px; }
#welcome .section-body {
  display: flex;
  flex-direction: column;
  gap: 24px;
  max-width: 720px;
}
.welcome-lead {
  font-size: clamp(22px, 2.2vw, 30px);
  line-height: 1.4;
  font-weight: 600;
  text-wrap: pretty;
}
.welcome-salutation { font-size: 17px; font-weight: 700; color: var(--slate); }
.welcome-text { display: flex; flex-direction: column; gap: 20px; font-size: 17px; line-height: 1.7; }
.signature { display: flex; flex-direction: column; gap: 24px; padding-top: 8px; }
.signoff { font-size: 17px; font-weight: 600; }
.signers {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
  gap: 40px 32px;
}
.signer { display: flex; flex-direction: column; align-items: flex-start; gap: 20px; }
.signer img { width: 112px; height: 112px; object-fit: cover; }
.signer-info { display: flex; flex-direction: column; gap: 4px; font-size: 15px; line-height: 1.5; }
.signer-info strong { font-size: 20px; font-weight: 800; }
.signer-info .signer-role { font-weight: 700; color: var(--slate); }
.note { font-size: 15px; color: var(--slate); }

/* Committee */
#committee { padding-bottom: 112px; }
.committee-group {
  margin: 0 0 16px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--slate);
}
.committee-list + .committee-group { margin-top: 56px; }
.committee-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
  column-gap: 48px;
  border-top: 2px solid var(--navy);
}
.committee-list li {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 0;
  border-bottom: 1px solid var(--rule);
  font-size: 17px;
}
.committee-list strong { font-weight: 700; }
.committee-list .role { font-size: 14px; color: var(--slate); }

/* Program & registration */
/* Full-width bands that alternate paper / white down the page */
.band-white { background: var(--white); }
.band .wrap { padding-top: 112px; padding-bottom: 112px; }
.band .section-body { display: flex; flex-direction: column; gap: 56px; }

.program-notice {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 720px;
  padding-top: 20px;
  border-top: 2px solid var(--navy);
  font-size: 17px;
  line-height: 1.6;
  color: var(--slate);
}
.program-notice-title { font-size: 24px; font-weight: 800; color: var(--navy); }

.days {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr));
  gap: 48px;
}
.day { border-top: 2px solid var(--navy); }
.day-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  padding: 20px 0;
}
.day-name { font-size: 24px; font-weight: 800; }
.day-date { font-size: 15px; font-weight: 600; color: var(--slate); }
.slot {
  display: grid;
  grid-template-columns: 96px 1fr;
  padding: 14px 0;
  border-top: 1px solid var(--rule);
  font-size: 16px;
}
.slot time { font-weight: 700; color: var(--slate); }

.fees {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  background: var(--navy);
  color: var(--white);
}
.fee {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 32px;
  border-right: 1px solid var(--rule-on-navy-soft);
  border-bottom: 1px solid var(--rule-on-navy-soft);
}
.fee .cat { font-size: 14px; color: var(--blue-700); }
.fee .amount { font-size: 28px; font-weight: 800; }
.fees-cta {
  display: flex;
  align-items: center;
  padding: 32px;
  background: var(--blue);
  color: var(--navy);
  font-weight: 800;
  font-size: 18px;
}
.fees-cta:hover { background: var(--blue-600); color: var(--navy); }

.fees-notes {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: -24px;
  font-size: 15px;
  line-height: 1.6;
  color: var(--navy);
}
.fees-notes li { padding-left: 16px; position: relative; }
.fees-notes li::before { content: "—"; position: absolute; left: 0; }

/* Information & organizers share a key/value grid */
.facts {
  align-self: flex-start;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
  gap: 40px;
}
.fact {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-top: 20px;
  border-top: 2px solid var(--navy);
}
.fact dt, .fact .k {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--slate);
}
.fact dd, .fact .v { margin: 0; font-size: 17px; line-height: 1.55; font-weight: 500; }

.info-body { display: flex; flex-direction: column; gap: 64px; }
.info-grid { row-gap: 48px; }
.fact dd.prose { font-size: 15px; line-height: 1.7; font-weight: 400; }

/* Venues: photo + details + map */
.venues {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
  gap: 48px;
}
.venue {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding-top: 20px;
  border-top: 2px solid var(--navy);
}
.venue-label {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--slate);
}
.venue img {
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 2;
  object-fit: cover;
}
.venue-text { flex: 1; }
.venue-text .place { font-size: 17px; font-weight: 700; line-height: 1.4; }
.venue-text .detail { margin-top: 6px; font-size: 15px; font-weight: 500; color: var(--slate); }
.venue-text .place + .detail { margin-top: 10px; }
.venue-text a { text-decoration: underline; text-underline-offset: 3px; }
.venue-map {
  display: block;
  width: 100%;
  height: 280px;
  border: 0;
  background: var(--rule);
}
.map-link { font-size: 14px; font-weight: 700; }
.map-link:hover { text-decoration: underline; text-underline-offset: 3px; }

/* Wide screens: six-column grid — short facts take two, long texts three */
@media (min-width: 1200px) {
  .info-grid { grid-template-columns: repeat(6, 1fr); }
  .info-grid .fact { grid-column: span 2; }
  .info-grid .fact-wide { grid-column: span 3; }
}

/* Footer / organizers */
.site-footer { background: var(--navy); color: var(--white); }
.site-footer .wrap { padding-top: 80px; padding-bottom: 80px; }
.site-footer .fact { border-top-color: var(--rule-on-navy); }
.site-footer .fact dt { color: var(--blue); }
.site-footer .fact dd { font-size: 17px; font-weight: 600; line-height: 1.45; }
/* Organizers */
.org-grid { grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); }
.org-grid .fact-secretariat { grid-column: 1 / -1; }
.site-footer .fact dd > * + * { margin-top: 16px; }
.logo-tile {
  display: inline-block;
  padding: 14px 18px;
  background: var(--white);
}
.logo-tile img { width: 200px; height: auto; }
.org-name { font-size: 17px; font-weight: 600; line-height: 1.45; }
.org-logo { width: 200px; height: auto; }
.offices {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
  gap: 32px;
}
.office {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-style: normal;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.5;
}
.office strong { font-size: 17px; font-weight: 700; color: var(--blue-700); }
.org-site { font-size: 15px; font-weight: 600; }

@media (min-width: 1200px) {
  .org-grid { grid-template-columns: 1fr 2fr; }
  .org-grid .fact-secretariat { grid-column: auto; }
}

.site-footer a { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.site-footer a:hover { color: var(--blue); }
