/*
  Shared static-site styles for Claire Hardaker's pages.
  The palette keeps the original lavender, violet, aqua, green and yellow,
  but gives them grown-up contrast, valid colour values and actual units.
*/

:root {
  color-scheme: light;
  --page: #eeeeff;
  --surface: #ffffff;
  --surface-soft: #f8f8ff;
  --ink: #202033;
  --muted: #626278;
  --line: #ccccdd;
  --line-strong: #adadc4;
  --violet: #8888ee;
  --violet-soft: #dadaff;
  --violet-deep: #5b55b5;
  --violet-dark: #333399;
  --aqua: #74d9dd;
  --aqua-soft: #d7f7f8;
  --aqua-deep: #207579;
  --green: #83d895;
  --green-soft: #ddf6e2;
  --green-deep: #2f7043;
  --yellow: #eedb72;
  --yellow-soft: #fff8c9;
  --yellow-deep: #76630e;
  --shadow: 0 18px 45px rgba(51, 51, 102, 0.10);
  --shadow-small: 0 8px 22px rgba(51, 51, 102, 0.08);
  --radius-large: 24px;
  --radius-medium: 14px;
  --reading-width: 68ch;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--page);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.6;
  scroll-behavior: smooth;
}

body {
  min-width: 280px;
  margin: 0;
  background:
    radial-gradient(circle at 6% 3%, rgba(116, 217, 221, 0.27), transparent 27rem),
    radial-gradient(circle at 96% 9%, rgba(131, 216, 149, 0.19), transparent 24rem),
    var(--page);
  color: var(--ink);
}

a {
  color: var(--violet-dark);
  text-underline-offset: 0.18em;
  text-decoration-thickness: 1px;
}

a:hover {
  text-decoration-thickness: 2px;
}

a:focus-visible {
  border-radius: 4px;
  outline: 3px solid var(--violet-dark);
  outline-offset: 4px;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
h3 {
  text-wrap: balance;
}

h1 {
  max-width: 13ch;
  margin-bottom: 1.15rem;
  font-size: clamp(3rem, 8vw, 6.1rem);
  font-weight: 780;
  letter-spacing: -0.06em;
  line-height: 0.94;
}

h2 {
  margin-bottom: 0.8rem;
  font-size: clamp(2rem, 5vw, 3.45rem);
  letter-spacing: -0.045em;
  line-height: 1.03;
}

h3 {
  margin-bottom: 0.55rem;
  font-size: clamp(1.15rem, 2vw, 1.45rem);
  letter-spacing: -0.025em;
  line-height: 1.2;
}

p {
  margin-bottom: 1rem;
}

.shell {
  width: min(1180px, calc(100% - 2.5rem));
  margin-inline: auto;
}

.skip-link {
  position: fixed;
  z-index: 100;
  top: 0.75rem;
  left: 0.75rem;
  padding: 0.65rem 0.9rem;
  border-radius: 8px;
  background: var(--violet-dark);
  color: #ffffff;
  transform: translateY(-180%);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  position: sticky;
  z-index: 20;
  top: 0;
  border-bottom: 1px solid rgba(173, 173, 196, 0.72);
  background: rgba(238, 238, 255, 0.92);
  backdrop-filter: blur(14px);
}

.nav {
  display: flex;
  min-height: 68px;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
}

.nav__name {
  color: var(--ink);
  font-weight: 800;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.nav__links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.25rem 1rem;
}

.nav__links a {
  color: var(--ink);
  font-size: 0.9rem;
  font-weight: 650;
  text-decoration: none;
}

.nav__links a:hover {
  color: var(--violet-dark);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(280px, 0.75fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: end;
  padding-block: clamp(4.5rem, 10vw, 8.5rem) clamp(4rem, 8vw, 7rem);
}

.eyebrow,
.card-kicker {
  margin-bottom: 0.55rem;
  color: var(--violet-dark);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.hero__strapline {
  max-width: 41ch;
  margin-bottom: 1.15rem;
  font-size: clamp(1.25rem, 2.7vw, 1.8rem);
  font-weight: 690;
  letter-spacing: -0.025em;
  line-height: 1.28;
}

.hero__intro {
  max-width: var(--reading-width);
  color: var(--muted);
  font-size: 1.06rem;
}

.button-row,
.factor-strip__links,
.inline-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  align-items: center;
}

.button-row {
  margin-top: 1.65rem;
}

.button {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.65rem 1rem;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  font-weight: 750;
  line-height: 1.2;
  text-decoration: none;
  transition: background 120ms ease, border-color 120ms ease, transform 120ms ease;
}

.button:hover {
  transform: translateY(-1px);
}

.button--primary {
  border-color: var(--violet-dark);
  background: var(--violet-dark);
  color: #ffffff;
}

.button--primary:hover {
  background: #282878;
}

.button--secondary {
  border-color: var(--violet-deep);
  background: var(--violet-soft);
  color: #282865;
}

.button--secondary:hover {
  background: #c9c9ff;
}

.button--quiet {
  background: rgba(255, 255, 255, 0.7);
  color: var(--ink);
}

.button--quiet:hover {
  background: #ffffff;
}

.role-card,
.programme-card,
.capacity-card,
.project-card,
.expertise-card,
.public-card {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-small);
}

.role-card {
  position: relative;
  overflow: hidden;
  padding: clamp(1.4rem, 4vw, 2.1rem);
  border-radius: var(--radius-large);
  box-shadow: var(--shadow);
}

.role-card::before {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 5px;
  background: linear-gradient(90deg, var(--violet), var(--aqua), var(--green));
  content: "";
}

.role-card h2 {
  font-size: 1.65rem;
  letter-spacing: -0.03em;
}

.role-list {
  margin: 1.35rem 0 1.25rem;
  padding: 0;
  list-style: none;
}

.role-list li {
  display: grid;
  gap: 0.12rem;
  padding: 0.85rem 0;
  border-top: 1px solid var(--line);
}

.role-list li:last-child {
  border-bottom: 1px solid var(--line);
}

.role-list span {
  font-weight: 760;
}

.role-list a,
.role-card__faculty a {
  color: var(--muted);
  font-size: 0.92rem;
}

.role-card__faculty {
  margin-bottom: 0;
}

.section {
  padding-block: clamp(4rem, 8vw, 7rem);
  scroll-margin-top: 76px;
}

.section-heading {
  max-width: 760px;
  margin-bottom: clamp(2rem, 5vw, 3.25rem);
}

.section-heading > p:last-child {
  max-width: var(--reading-width);
  margin-bottom: 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.section-heading--split {
  display: grid;
  max-width: none;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.7fr);
  gap: 2rem;
  align-items: end;
}

.section-heading--split h2,
.section-heading--split p {
  margin-bottom: 0;
}

.expertise-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
}

.expertise-card {
  position: relative;
  overflow: hidden;
  min-height: 240px;
  padding: 1.45rem;
  border-radius: var(--radius-medium);
}

.expertise-card::before,
.public-card::before {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 5px;
  content: "";
}

.expertise-card--violet::before,
.public-card--violet::before {
  background: var(--violet);
}

.expertise-card--aqua::before,
.public-card--aqua::before {
  background: var(--aqua);
}

.expertise-card--green::before,
.public-card--green::before {
  background: var(--green);
}

.expertise-card--yellow::before {
  background: var(--yellow);
}

.expertise-card p,
.project-card p,
.public-card p,
.programme-card p,
.capacity-card p {
  color: var(--muted);
}

.section--projects {
  border-block: 1px solid var(--line);
  background: rgba(248, 248, 255, 0.78);
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.project-card {
  display: flex;
  min-height: 270px;
  flex-direction: column;
  padding: clamp(1.4rem, 3vw, 2rem);
  border-radius: var(--radius-large);
}

.project-card--feature {
  background:
    linear-gradient(135deg, rgba(218, 218, 255, 0.76), rgba(255, 255, 255, 0.92));
}

.text-link {
  width: fit-content;
  margin-top: auto;
  color: var(--violet-dark);
  font-weight: 780;
}

.factor-strip {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 2rem;
  align-items: center;
  margin-top: 1rem;
  padding: clamp(1.5rem, 4vw, 2.4rem);
  border: 1px solid var(--line);
  border-radius: var(--radius-large);
  background: var(--yellow-soft);
}

.factor-strip p:last-child,
.factor-strip h3 {
  margin-bottom: 0;
}

.factor-strip > div:first-child p:last-child {
  max-width: 70ch;
  color: #5c5430;
}

.teaching-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(280px, 0.7fr);
  gap: 1rem;
}

.programme-card,
.capacity-card {
  padding: clamp(1.5rem, 4vw, 2.4rem);
  border-radius: var(--radius-large);
}

.capacity-card {
  border-color: #d5c76e;
  background: var(--yellow-soft);
}

.capacity-card p {
  color: #5c5430;
}

.muted {
  color: var(--muted);
  font-size: 0.94rem;
}

.students {
  margin-top: clamp(2rem, 5vw, 3.5rem);
}

.students__heading {
  display: grid;
  grid-template-columns: minmax(0, 0.6fr) minmax(280px, 1fr);
  gap: 1.5rem;
  align-items: end;
  margin-bottom: 1.25rem;
}

.students__heading h3,
.students__heading p {
  margin-bottom: 0;
}

.students__heading p {
  color: var(--muted);
}

.student-grid {
  display: grid;
  margin: 0;
  padding: 0;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  list-style: none;
}

.student-grid li {
  display: grid;
  grid-template-columns: minmax(6rem, 0.32fr) minmax(7.5rem, 0.38fr) minmax(0, 1fr);
  gap: 0.75rem;
  padding: 1rem 1.1rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.78);
}

.student-grid li:last-child {
  grid-column: 1 / -1;
}

.student-role {
  color: var(--violet-deep);
  font-size: 0.9rem;
  font-weight: 720;
}

.profiles {
  border-block: 1px solid var(--line);
  background: #29294e;
  color: #ffffff;
}

.profiles .eyebrow {
  color: #b9f1f3;
}

.profiles .section-heading > p:last-child {
  color: #d2d2e6;
}

.profiles__inner {
  display: grid;
  grid-template-columns: minmax(280px, 0.8fr) minmax(0, 1.2fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: start;
}

.profiles__inner .section-heading {
  margin-bottom: 0;
}

.profile-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}

.profile-links a {
  display: grid;
  min-height: 120px;
  align-content: end;
  padding: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  text-decoration: none;
}

.profile-links a:hover {
  border-color: var(--aqua);
  background: rgba(255, 255, 255, 0.13);
}

.profile-links a:last-child {
  grid-column: 1 / -1;
}

.profile-links span {
  color: #cfcfe3;
  font-size: 0.88rem;
}

.public-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.public-card {
  position: relative;
  display: flex;
  min-height: 295px;
  overflow: hidden;
  flex-direction: column;
  padding: 1.5rem;
  border-radius: var(--radius-medium);
}

.inline-links {
  margin-top: auto;
}

.inline-links .text-link {
  margin-top: 0;
}

.contact {
  padding-block: clamp(3.5rem, 8vw, 6.5rem);
  background: var(--aqua-soft);
  scroll-margin-top: 76px;
}

.contact__inner {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(280px, 0.75fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: end;
}

.contact__inner > div p:last-child {
  max-width: var(--reading-width);
  margin-bottom: 0;
  color: #355e61;
}

.contact address {
  padding-left: 1.4rem;
  border-left: 4px solid var(--aqua-deep);
  color: #355e61;
  font-style: normal;
}

.site-footer {
  padding-block: 1.5rem;
  background: #202033;
  color: #d5d5e5;
}

.site-footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
}

.site-footer p {
  margin-bottom: 0;
  font-size: 0.9rem;
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.75rem 1rem;
}

.site-footer a {
  color: #ffffff;
  font-size: 0.88rem;
}

@media (max-width: 940px) {
  .hero,
  .profiles__inner {
    grid-template-columns: 1fr;
  }

  .hero {
    align-items: start;
  }

  .role-card {
    max-width: 680px;
  }

  .expertise-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .expertise-card {
    min-height: 210px;
  }

  .public-grid {
    grid-template-columns: 1fr;
  }

  .public-card {
    min-height: 235px;
  }
}

@media (max-width: 760px) {
  .site-header {
    position: static;
  }

  .nav {
    align-items: flex-start;
    padding-block: 0.85rem;
  }

  .nav__links {
    max-width: 75%;
  }

  .section-heading--split,
  .teaching-grid,
  .factor-strip,
  .students__heading,
  .contact__inner {
    grid-template-columns: 1fr;
  }

  .student-grid {
    grid-template-columns: 1fr;
  }

  .student-grid li:last-child {
    grid-column: auto;
  }

  .factor-strip__links {
    justify-content: flex-start;
  }
}

@media (max-width: 620px) {
  .shell {
    width: min(100% - 1.4rem, 1180px);
  }

  .nav {
    display: block;
  }

  .nav__name {
    display: block;
    margin-bottom: 0.45rem;
  }

  .nav__links {
    max-width: none;
    justify-content: flex-start;
    gap: 0.25rem 0.8rem;
  }

  .nav__links a {
    font-size: 0.82rem;
  }

  .hero {
    padding-top: 3.5rem;
  }

  h1 {
    font-size: clamp(2.75rem, 16vw, 4.4rem);
  }

  .expertise-grid,
  .project-grid,
  .profile-links {
    grid-template-columns: 1fr;
  }

  .profile-links a:last-child {
    grid-column: auto;
  }

  .student-grid li {
    grid-template-columns: 1fr;
    gap: 0.15rem;
  }

  .student-grid li > span:last-child {
    margin-top: 0.35rem;
  }

  .site-footer__inner {
    display: block;
  }

  .site-footer p {
    margin-bottom: 0.65rem;
  }

  .site-footer nav {
    justify-content: flex-start;
  }
}

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

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
  }
}

@media print {
  .site-header,
  .button-row,
  .site-footer,
  .skip-link {
    display: none;
  }

  body {
    background: #ffffff;
  }

  .shell {
    width: 100%;
  }

  .hero,
  .section {
    padding-block: 1.5rem;
  }

  .role-card,
  .programme-card,
  .capacity-card,
  .project-card,
  .expertise-card,
  .public-card {
    break-inside: avoid;
    box-shadow: none;
  }

  a {
    color: #000000;
  }
}
