/* ==========================================================================
   Varun Kumar portfolio
   Palette: navy, white, grey. Type: Archivo (display + body), Newsreader (ledes).
   ========================================================================== */

:root {
  /* Colour */
  --navy-900: #101F38;   /* deep navy: hero, dark sections, footer */
  --navy-700: #243B59;   /* slate navy: secondary dark surfaces */
  --white: #FFFFFF;
  --grey-100: #E8EBEF;   /* soft light grey: alternate sections */
  --grey-200: #D3D8DF;   /* rules on light backgrounds */
  --steel: #778392;      /* steel grey: decorative rules and numbers only */
  --text-muted: #566273; /* secondary text on white/grey (AA) */
  --text-muted-dark: #A7B2C0; /* secondary text on navy (AA) */
  --rule-dark: rgba(255, 255, 255, 0.16);

  /* Type */
  --font-sans: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --font-serif: "Newsreader", Georgia, "Times New Roman", serif;

  --step--1: 0.875rem;
  --step-0: 1.0625rem;
  --step-1: clamp(1.25rem, 1.1rem + 0.5vw, 1.5rem);
  --step-2: clamp(1.5rem, 1.25rem + 1vw, 2rem);
  --step-display: clamp(2.75rem, 1.6rem + 4.2vw, 4.75rem);

  /* Layout */
  --container: 80rem;
  --gutter: clamp(1.25rem, 4vw, 4rem);
  --section-y: clamp(4.5rem, 3rem + 7vw, 9rem);
  --header-h: 4rem;
}

/* ---------- Base ---------- */

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-h);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: var(--step-0);
  line-height: 1.6;
  color: var(--navy-900);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

h1, h2, h3, p, ul, ol, dl, dd, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }

a { color: inherit; text-underline-offset: 0.2em; text-decoration-thickness: 1px; }

:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 3px;
}

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

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 100;
  padding: 0.75rem 1rem;
  background: var(--white);
  color: var(--navy-900);
  font-weight: 600;
}
.skip-link:focus { top: 1rem; }

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* ---------- Type roles ---------- */

.display {
  font-family: var(--font-sans);
  font-stretch: 68%;
  font-variation-settings: "wdth" 68;
  font-weight: 800;
  text-transform: uppercase;
  line-height: 0.92;
  letter-spacing: 0;
}

.display--section { font-size: var(--step-display); }

.display--property {
  font-size: clamp(2.5rem, 1.5rem + 4.5vw, 5rem);
  max-width: 12ch;
}

.lede {
  font-family: var(--font-serif);
  font-size: var(--step-2);
  line-height: 1.32;
  font-weight: 400;
}

.meta {
  font-size: var(--step--1);
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.placeholder {
  display: inline-block;
  padding: 0.05em 0.4em;
  border: 1px dashed var(--steel);
  color: var(--text-muted);
  font-size: 0.9em;
}
.placeholder--dark { border-color: var(--text-muted-dark); color: var(--text-muted-dark); }

.plain-list li {
  padding: 0.55rem 0;
  border-top: 1px solid var(--grey-200);
}
.plain-list li:last-child { border-bottom: 1px solid var(--grey-200); }

@media (min-width: 40em) {
  .plain-list--two {
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: 2rem;
  }
  .plain-list--two li:nth-last-child(2):nth-child(odd) { border-bottom: 1px solid var(--grey-200); }
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3rem;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  font-size: 0.975rem;
  text-decoration: none;
  border: 1px solid transparent;
  border-radius: 2px;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.btn--light { background: var(--white); color: var(--navy-900); border-color: var(--white); }
.btn--light:hover { background: var(--grey-100); border-color: var(--grey-100); }
.btn--outline { color: var(--white); border-color: rgba(255, 255, 255, 0.55); }
.btn--outline:hover { border-color: var(--white); background: var(--navy-700); }

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--navy-900);
  color: var(--white);
  border-bottom: 1px solid var(--rule-dark);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: var(--header-h);
}

.wordmark {
  font-stretch: 68%;
  font-variation-settings: "wdth" 68;
  font-weight: 800;
  font-size: 1.35rem;
  text-transform: uppercase;
  text-decoration: none;
  letter-spacing: 0.01em;
}

.nav-toggle {
  min-height: 2.75rem;
  padding: 0 1rem;
  font: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--white);
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 2px;
  cursor: pointer;
}

.site-nav {
  display: none;
  position: absolute;
  inset: var(--header-h) 0 auto 0;
  background: var(--navy-900);
  border-bottom: 1px solid var(--rule-dark);
}
.site-nav.is-open { display: block; }
.site-nav ul { padding: 0.5rem var(--gutter) 1.25rem; }
.site-nav a {
  display: block;
  padding: 0.85rem 0;
  font-size: 1.125rem;
  text-decoration: none;
  border-top: 1px solid var(--rule-dark);
}
.site-nav a:hover { text-decoration: underline; }

@media (min-width: 52em) {
  .nav-toggle { display: none; }
  .site-nav { display: block; position: static; border: 0; background: none; }
  .site-nav ul { display: flex; gap: 2rem; padding: 0; }
  .site-nav a { padding: 0.5rem 0; font-size: 0.95rem; border: 0; color: var(--text-muted-dark); }
  .site-nav a:hover { color: var(--white); text-decoration: none; }
}

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

.hero {
  background: var(--navy-900);
  color: var(--white);
  overflow: hidden;
}

.hero__photo img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: 50% 20%;
}

.hero__text {
  position: relative;
  z-index: 1;
  padding: 0 var(--gutter) clamp(3rem, 6vw, 5rem);
}

.hero__name {
  font-stretch: 62%;
  font-variation-settings: "wdth" 62;
  font-weight: 850;
  text-transform: uppercase;
  font-size: clamp(5rem, 27vw, 8rem);
  line-height: 0.82;
  letter-spacing: -0.005em;
  /* Sits over the navy polo at the foot of the photo on small screens */
  margin-top: -0.95em;
}
.hero__name span { display: block; }

.hero__title {
  margin-top: 1.5rem;
  font-family: var(--font-serif);
  font-size: var(--step-2);
  line-height: 1.25;
  max-width: 22ch;
}

.hero__intro {
  margin-top: 1.25rem;
  max-width: 34rem;
  color: var(--text-muted-dark);
}

.hero__specialities {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0;
  margin-top: 1.5rem;
  font-size: var(--step--1);
  color: var(--white);
}
.hero__specialities li:not(:last-child)::after {
  content: "/";
  margin: 0 0.6rem;
  color: var(--steel);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2rem;
}

@media (min-width: 60em) {
  .hero__inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 0.86fr);
    min-height: clamp(38rem, calc(100svh - var(--header-h) - 5.5rem), 52rem);
  }
  .hero__photo { grid-column: 2; grid-row: 1; position: relative; }
  .hero__photo img {
    position: absolute;
    inset: 0;
    height: 100%;
    aspect-ratio: auto;
    object-position: 50% 15%;
  }
  .hero__text {
    grid-column: 1; grid-row: 1;
    align-self: end;
    padding: 4rem 0 4.5rem var(--gutter);
    padding-left: max(var(--gutter), calc((100vw - var(--container)) / 2 + var(--gutter)));
  }
  .hero__name {
    margin-top: 0;
    font-size: clamp(7rem, 13.5vw, 13rem);
  }
}

/* Single load-in moment for the name */
@media (prefers-reduced-motion: no-preference) {
  .hero__name span {
    animation: rise 0.9s cubic-bezier(0.2, 0.7, 0.1, 1) both;
  }
  .hero__name span + span { animation-delay: 0.08s; }
  @keyframes rise {
    from { opacity: 0; transform: translateY(0.25em); }
    to { opacity: 1; transform: none; }
  }
}

/* Record strip under the hero */
.record-strip {
  background: var(--navy-700);
}
.record-strip__list {
  display: grid;
}
.record-strip__list li {
  padding: 1.1rem 0;
  font-stretch: 68%;
  font-variation-settings: "wdth" 68;
  font-weight: 700;
  font-size: clamp(1.15rem, 1rem + 0.8vw, 1.6rem);
  text-transform: uppercase;
  line-height: 1.1;
}
.record-strip__list li + li { border-top: 1px solid var(--rule-dark); }

@media (min-width: 48em) {
  .record-strip__list { grid-template-columns: repeat(3, auto); justify-content: space-between; }
  .record-strip__list li { padding: 1.6rem 0; }
  .record-strip__list li + li { border-top: 0; border-left: 1px solid var(--rule-dark); padding-left: 2rem; }
}

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

.section { padding-block: var(--section-y); }
.section--white { background: var(--white); }
.section--grey { background: var(--grey-100); }

.section-head {
  display: grid;
  gap: 1.5rem;
  margin-bottom: clamp(2.5rem, 5vw, 4.5rem);
}
.section-head p { max-width: 34rem; color: var(--text-muted); }

@media (min-width: 60em) {
  .section-head { grid-template-columns: 7fr 5fr; align-items: end; gap: 4rem; }
  .section-head .display { max-width: 12ch; }
}

/* ---------- About ---------- */

.about { display: grid; gap: 2rem; }
.about__body { display: grid; gap: 1.25rem; max-width: 40rem; }
.about__body .lede { margin-bottom: 0.5rem; }
.about__body p:not(.lede) { color: var(--text-muted); }

@media (min-width: 60em) {
  .about { grid-template-columns: 5fr 7fr; gap: 4rem; }
  .about .display { max-width: 7ch; }
}

.highlights {
  display: grid;
  margin-top: clamp(3.5rem, 7vw, 6rem);
  border-top: 2px solid var(--navy-900);
}
.highlight { padding: 1.5rem 0; }
.highlight + .highlight { border-top: 1px solid var(--grey-200); }
.highlight__title {
  font-stretch: 68%;
  font-variation-settings: "wdth" 68;
  font-weight: 800;
  font-size: var(--step-2);
  text-transform: uppercase;
  line-height: 1;
  margin-bottom: 0.6rem;
}
.highlight p { color: var(--text-muted); max-width: 26rem; }

@media (min-width: 48em) {
  .highlights { grid-template-columns: repeat(3, 1fr); }
  .highlight { padding: 1.75rem 2rem 0 0; }
  .highlight + .highlight { border-top: 0; border-left: 1px solid var(--grey-200); padding-left: 2rem; }
}

/* ---------- Photos (reusable) ---------- */

.photo img { width: 100%; }
.photo figcaption {
  margin-top: 0.75rem;
  font-size: var(--step--1);
  color: var(--text-muted);
}

.gallery {
  display: grid;
  gap: 2rem 1.5rem;
  margin-top: clamp(3.5rem, 7vw, 6rem);
}
.gallery img { aspect-ratio: 4 / 5; object-fit: cover; object-position: 50% 30%; }

@media (min-width: 48em) {
  .gallery { grid-template-columns: repeat(3, 1fr); }
}

/* ---------- Experiences ---------- */

.experiences { display: grid; gap: 3rem; }
.experiences__intro { margin-top: 1.25rem; color: var(--text-muted); max-width: 26rem; }
.photo--coaching { margin-top: 2.5rem; }
.photo--coaching img { aspect-ratio: 1 / 1; object-fit: cover; object-position: 30% 50%; }

.experience-list { border-top: 2px solid var(--navy-900); }

.experience {
  display: grid;
  grid-template-columns: 2.75rem 1fr;
  column-gap: 0.75rem;
  padding: 1.75rem 0;
  border-bottom: 1px solid var(--grey-200);
}
.experience__num {
  grid-row: span 2;
  font-stretch: 68%;
  font-variation-settings: "wdth" 68;
  font-weight: 700;
  font-size: 1.25rem;
  line-height: 1.5;
  color: var(--text-muted);
}
.experience__title {
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: var(--step-2);
  line-height: 1.2;
  margin-bottom: 0.6rem;
}
.experience p { color: var(--text-muted); max-width: 36rem; }

@media (min-width: 60em) {
  .experiences { grid-template-columns: 5fr 7fr; gap: 5rem; align-items: start; }
  .experiences__aside { position: sticky; top: calc(var(--header-h) + 2rem); }
  .experiences__aside .display { max-width: 8ch; }
  .experience { grid-template-columns: 4rem 1fr; padding: 2rem 0; }
}

/* ---------- Competitive record ---------- */

.competition {
  display: grid;
  background: var(--navy-900);
  color: var(--white);
}

.competition__photo { position: relative; }
.competition__photo img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: 55% 40%;
  /* Monochrome treatment to sit inside the navy palette. Delete this line to show the photo in colour. */
  filter: grayscale(1) contrast(1.08);
}
.competition__photo figcaption {
  position: absolute;
  left: var(--gutter);
  bottom: 1rem;
  font-size: var(--step--1);
  color: var(--white);
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.6);
}

.competition__text {
  padding: clamp(3rem, 6vw, 6rem) var(--gutter) var(--section-y);
}
.competition__text > p { margin-top: 2.5rem; max-width: 32rem; color: var(--text-muted-dark); }

.titles { margin-top: 2.5rem; border-top: 1px solid var(--rule-dark); }
.titles li { padding: 1.1rem 0; border-bottom: 1px solid var(--rule-dark); }
.titles__name {
  display: block;
  font-family: var(--font-serif);
  font-size: var(--step-2);
  line-height: 1.2;
}

@media (min-width: 60em) {
  .competition { grid-template-columns: 11fr 9fr; min-height: 44rem; }
  .competition__photo img { height: 100%; aspect-ratio: auto; }
  .competition__text {
    align-self: center;
    padding: var(--section-y) var(--gutter) var(--section-y) clamp(2.5rem, 5vw, 5rem);
    max-width: 40rem;
  }
}

/* ---------- Hospitality ---------- */

.hospitality { display: grid; gap: 3rem; }
.hospitality__role {
  margin-top: 1.5rem;
  font-weight: 600;
  font-size: var(--step-1);
}
.hospitality__dates { color: var(--text-muted); }
.hospitality__body { display: grid; gap: 1.25rem; max-width: 40rem; }
.hospitality__body > p:not(.lede) { color: var(--text-muted); }

/* Award recognition: set off by a navy rule, no badge or icon */
.recognition {
  margin-top: 2.5rem;
  padding: 0.25rem 0 0.25rem 1.25rem;
  border-left: 3px solid var(--navy-900);
  max-width: 26rem;
}
.recognition__title {
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: var(--step-2);
  line-height: 1.15;
}
.recognition__date {
  margin-top: 0.3rem;
  font-stretch: 68%;
  font-variation-settings: "wdth" 68;
  font-weight: 700;
  font-size: 1.05rem;
  text-transform: uppercase;
  color: var(--text-muted);
}
.recognition__text {
  margin-top: 0.75rem;
  font-size: var(--step--1);
  line-height: 1.55;
  color: var(--text-muted);
}

.list-heading {
  margin-top: 1.5rem;
  font-size: var(--step--1);
  font-weight: 600;
}

@media (min-width: 60em) {
  .hospitality { grid-template-columns: 5fr 7fr; gap: 4rem; }
  .hospitality__head { position: sticky; top: calc(var(--header-h) + 2rem); align-self: start; }
}

/* ---------- Programmes ---------- */

.programmes { display: grid; gap: 3rem 4rem; }

.programme {
  padding-top: 1.5rem;
  border-top: 2px solid var(--navy-900);
}
.programme__title {
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: var(--step-2);
  line-height: 1.2;
  margin-bottom: 0.75rem;
}
.programme > p { color: var(--text-muted); margin-bottom: 1.25rem; max-width: 32rem; }
.programme .plain-list li { border-color: var(--grey-200); padding: 0.45rem 0; }
.section--grey .plain-list li { border-color: #CDD3DB; }

@media (min-width: 48em) {
  .programmes { grid-template-columns: 1fr 1fr; }
}

.terms {
  margin-top: clamp(3rem, 6vw, 4.5rem);
  padding-top: 1.5rem;
  border-top: 1px solid var(--steel);
  max-width: 44rem;
  font-family: var(--font-serif);
  font-size: var(--step-1);
  line-height: 1.4;
}

/* ---------- Credentials ---------- */

.credentials { margin-top: clamp(2.5rem, 5vw, 4rem); border-top: 2px solid var(--navy-900); }
.credentials__row {
  display: grid;
  gap: 0.75rem;
  padding: 1.75rem 0;
  border-bottom: 1px solid var(--grey-200);
}
.credentials dt {
  font-stretch: 68%;
  font-variation-settings: "wdth" 68;
  font-weight: 800;
  font-size: var(--step-1);
  text-transform: uppercase;
}
.credentials dt { line-height: 1.05; }

/* Experience timeline: dates set in the display face, role in the serif */
.timeline__item {
  display: grid;
  gap: 0.35rem;
  padding: 1rem 0;
  border-top: 1px solid var(--grey-200);
}
.timeline__item:first-child { border-top: 0; padding-top: 0; }
.timeline__item:last-child { padding-bottom: 0; }
.timeline__dates {
  font-stretch: 68%;
  font-variation-settings: "wdth" 68;
  font-weight: 700;
  font-size: 1.05rem;
  text-transform: uppercase;
  color: var(--text-muted);
  line-height: 1.6;
}
.timeline__role,
.quals__name {
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: var(--step-1);
  line-height: 1.3;
}
.timeline__org,
.quals__detail {
  font-size: var(--step--1);
  color: var(--text-muted);
  margin-top: 0.2rem;
}

.timeline__note {
  margin-top: 0.5rem;
  font-size: var(--step--1);
  font-weight: 600;
  color: var(--navy-900);
}

/* Certifications and training */
.quals { display: grid; gap: 1.25rem; }

@media (min-width: 48em) {
  .credentials dt { max-width: 12ch; }
  .timeline__item { grid-template-columns: 11rem 1fr; gap: 1.5rem; }
  .quals { grid-template-columns: 1fr 1fr; gap: 2rem; }
}

.credentials .plain-list li:first-child { border-top: 0; padding-top: 0; }
.credentials .plain-list li:last-child { border-bottom: 0; }

@media (min-width: 48em) {
  .credentials__row { grid-template-columns: 14rem 1fr; gap: 2rem; }
  .credentials .plain-list--two li:nth-child(2) { border-top: 0; padding-top: 0; }
  .credentials .plain-list--two li { border-bottom: 0 !important; }
}

/* ---------- Footer: collaborations + contact ---------- */

.site-footer {
  background: var(--navy-900);
  color: var(--white);
  padding-top: var(--section-y);
}

.collab { display: grid; gap: 2.5rem; }
.collab__body { display: grid; gap: 1.5rem; justify-items: start; max-width: 38rem; }
.collab__body > p:not(.lede) { color: var(--text-muted-dark); }

.collab__list { width: 100%; border-top: 1px solid var(--rule-dark); }
.collab__list li {
  padding: 0.8rem 0;
  border-bottom: 1px solid var(--rule-dark);
  font-stretch: 68%;
  font-variation-settings: "wdth" 68;
  font-weight: 700;
  font-size: var(--step-2);
  text-transform: uppercase;
  line-height: 1.1;
}

@media (min-width: 60em) {
  .collab { grid-template-columns: 6fr 6fr; gap: 4rem; }
  .collab .display { max-width: 9ch; }
}

.contact-list {
  display: grid;
  margin-top: clamp(4rem, 8vw, 6rem);
  border-top: 2px solid var(--white);
}
.contact-list li {
  display: grid;
  align-content: start;
  gap: 0.25rem;
  padding: 1.25rem 0;
  border-bottom: 1px solid var(--rule-dark);
}
.contact-list__label { font-size: var(--step--1); color: var(--text-muted-dark); }
.contact-list a { font-size: var(--step-1); text-decoration: none; overflow-wrap: anywhere; }
.contact-list a:hover { text-decoration: underline; }

@media (min-width: 48em) {
  .contact-list { grid-template-columns: repeat(3, 1fr); }
  .contact-list li { padding-right: 1.5rem; border-bottom: 0; }
  .contact-list li + li { border-left: 1px solid var(--rule-dark); padding-left: 1.5rem; }
}

.site-footer__base {
  display: grid;
  gap: 0.5rem;
  margin-top: clamp(3rem, 6vw, 5rem);
  padding: 1.5rem 0 2rem;
  border-top: 1px solid var(--rule-dark);
  font-size: var(--step--1);
  color: var(--text-muted-dark);
}

@media (min-width: 48em) {
  .site-footer__base { grid-template-columns: auto 1fr; gap: 2rem; }
  .site-footer__base p:last-child { text-align: right; }
}

/* ---------- Motion preferences ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
