/* UVC-IV landing page — PMOD/WRC
   Colours taken from the UVC-IV flyer and www.pmodwrc.ch */

@font-face {
  font-family: "Montserrat";
  src: url("montserrat-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --navy: #1d334f;        /* deepened flyer title band */
  --navy-soft: #284161;   /* flyer title band */
  --blue: #0070c0;        /* flyer headings */
  --sky: #78d0f0;         /* flyer "UVC-IV" */
  --steel: #75a5d3;       /* pmodwrc.ch accent, logo arc */
  --mist: #dee9f4;        /* flyer header band, pmodwrc.ch */
  --mist-line: #c3d3e6;
  --ink: #363b4c;         /* pmodwrc.ch text */
  --paper: #ffffff;

  --wrap: 1120px;
  --gutter: clamp(20px, 5vw, 48px);
  --block: clamp(56px, 8vw, 104px);
}

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

html { scroll-behavior: smooth; scroll-padding-top: 88px; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  font-family: "Montserrat", "Helvetica Neue", Arial, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--paper);
}

img { max-width: 100%; height: auto; display: block; }
h1, h2, h3, p, ul, ol { margin: 0; }
ul, ol { padding: 0; list-style: none; }
address { font-style: normal; }

a { color: var(--blue); text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2px; }
a:focus-visible, .btn:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; border-radius: 2px; }
.block-navy a:focus-visible, .hero a:focus-visible { outline-color: var(--sky); }

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

.skip {
  position: absolute; left: 12px; top: -60px; z-index: 20;
  background: var(--navy); color: #fff; padding: 10px 16px; border-radius: 4px;
}
.skip:focus { top: 12px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.2;
  padding: 15px 26px;
  border-radius: 4px;
  text-decoration: none;
  border: 2px solid transparent;
  transition: background-color .15s ease, color .15s ease, border-color .15s ease;
}
.btn-small { padding: 10px 18px; font-size: 0.9375rem; }
.btn-blue { background: var(--blue); color: #fff; }
.btn-blue:hover { background: #005a9c; }
.btn-sky { background: var(--sky); color: var(--navy); }
.btn-sky:hover { background: #fff; }
.btn-ghost { border-color: rgba(255,255,255,.65); color: #fff; }
.btn-ghost:hover { border-color: #fff; background: rgba(255,255,255,.12); }

/* ---------- Header ---------- */
.top {
  position: sticky; top: 0; z-index: 10;
  background: var(--mist);
  border-bottom: 3px solid #adbddf;
}
.top-inner { display: flex; align-items: center; gap: 28px; min-height: 68px; }
.brand { flex: none; margin-right: auto; }
.brand img { width: 132px; }
.nav { display: flex; gap: 26px; }
.nav a {
  color: var(--navy); text-decoration: none; font-weight: 500; font-size: 0.9375rem;
  padding-block: 6px; border-bottom: 2px solid transparent;
}
.nav a:hover { border-bottom-color: var(--blue); }
@media (max-width: 860px) { .nav { display: none; } }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  background: var(--navy);
  color: #fff;
  overflow: hidden;
  min-height: clamp(540px, 50vw, 720px);
  display: flex; align-items: center;
}
.hero-photo {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover; object-position: 50% 78%;
}
/* Navy from the left carries the text; the instruments stay clear on the right */
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background:
    linear-gradient(90deg, var(--navy) 0%, rgba(29,51,79,.96) 34%, rgba(29,51,79,.55) 52%, rgba(29,51,79,0) 72%),
    linear-gradient(180deg, rgba(29,51,79,.55) 0%, rgba(29,51,79,0) 38%);
}
.hero-text { position: relative; z-index: 2; width: 100%; padding-block: clamp(44px, 6vw, 72px); }
.hero h1 { font-weight: 700; }
.hero-short {
  display: block;
  font-size: clamp(4rem, 11vw, 8.5rem);
  font-weight: 800;
  line-height: 0.92;
  letter-spacing: -0.035em;
  color: var(--sky);
  margin-left: -0.04em;
}
.hero-long {
  display: block;
  margin-top: 0.5em;
  font-size: clamp(1.35rem, 2.8vw, 2.125rem);
  line-height: 1.2;
  letter-spacing: -0.01em;
  max-width: 18ch;
}
.hero-date { margin-top: 22px; font-size: clamp(1.125rem, 2vw, 1.5rem); font-weight: 600; }
.hero-place { font-size: 1.0625rem; color: #d5e2f0; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

@media (max-width: 760px) {
  .hero { display: block; min-height: 0; }
  .hero::before { display: none; }
  .hero-photo { position: static; height: 62vw; object-position: 62% 70%; }
  .hero-text { padding-block: 40px 36px; }
}

/* ---------- Content blocks ---------- */
.block { padding-block: var(--block); }
.block-mist { background: var(--mist); }
.block-navy { background: var(--navy); color: #fff; }
.block-mist a, .notice a { color: #005a9c; }

.cols { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 24px clamp(32px, 6vw, 80px); align-items: start; }
@media (max-width: 860px) { .cols { grid-template-columns: 1fr; } }

h2 {
  font-size: clamp(1.5rem, 2.6vw, 2rem);
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: var(--blue);
}
.block-navy h2 { color: var(--sky); }
h3 { font-size: 1.125rem; line-height: 1.35; font-weight: 700; color: var(--navy); }

.body { max-width: 68ch; }
.body > * + * { margin-top: 1.1em; }
.lead, .lead p { font-size: clamp(1.125rem, 1.6vw, 1.3125rem); line-height: 1.55; }
.lead p + p { margin-top: 1em; }

/* Flyer download */
.body > .flyer {
  display: inline-flex; align-items: center; gap: 18px;
  margin-top: 2em; padding: 10px 22px 10px 10px;
  border: 1px solid var(--mist-line); border-radius: 4px;
  font-size: 1.0625rem; line-height: 1.35; text-decoration: none;
  transition: border-color .15s ease, background-color .15s ease;
}
.flyer:hover { border-color: var(--blue); background: #f4f8fc; }
.flyer img { width: 60px; border: 1px solid var(--mist-line); }
.flyer strong { display: block; font-weight: 600; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
.flyer small { display: block; margin-top: 2px; font-size: 0.875rem; color: var(--ink); }

/* Calibration list */
.measures li { padding-block: 20px; border-top: 1px solid var(--mist-line); }
.measures li:first-child { border-top: 3px solid var(--blue); }
.measures li:last-child { border-bottom: 1px solid var(--mist-line); }
.measures p { margin-top: 4px; }
.fn-ref { text-decoration: none; padding-inline: 2px; }
.footnote { font-size: 0.9375rem; line-height: 1.6; }
.footnote:target { background: #fff; outline: 10px solid #fff; }

/* Participation */
.topics { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 36px 44px; }
@media (max-width: 640px) { .topics { grid-template-columns: 1fr; gap: 28px; } }
.topic h3 { padding-top: 14px; border-top: 3px solid var(--blue); }
.topic p { margin-top: 8px; }
.body > .notice {
  margin-top: 44px;
  padding: 18px 22px;
  background: var(--mist);
  border-left: 4px solid var(--steel);
}

/* Schedule */
.chart { margin-bottom: 36px; }
.chart-track {
  position: relative; height: 52px; margin-top: 30px;
  background: #fff; border-radius: 4px;
}
.seg { position: absolute; top: 0; bottom: 0; }
.seg-reg {
  border-radius: 4px 0 0 4px;
  background: repeating-linear-gradient(135deg, var(--steel) 0 2px, transparent 2px 8px);
}
.seg-run {
  background: var(--blue); color: #fff; border-radius: 3px;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.875rem; font-weight: 600; white-space: nowrap; overflow: hidden;
}
.tick { position: absolute; top: -26px; font-size: 0.8125rem; font-weight: 600; color: var(--navy); white-space: nowrap; }
.tick-end { transform: translateX(-100%); }
.chart-months {
  display: grid; grid-template-columns: 30fr 31fr 30fr 31fr 31fr 30fr 31fr;
  margin-top: 6px; font-size: 0.8125rem; color: var(--ink);
}
.chart-months span { border-left: 1px solid #9db3cc; padding-left: 6px; }
@media (max-width: 560px) { .chart { display: none; } }

.steps li {
  display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 4px 24px;
  padding-block: 14px; border-top: 1px solid var(--mist-line);
}
.steps li:last-child { border-bottom: 1px solid var(--mist-line); }
.steps .when { font-weight: 700; color: var(--navy); }
@media (max-width: 560px) { .steps li { grid-template-columns: 1fr; } }

/* Register */
.block-navy .lead { color: #fff; }
.checklist { margin-top: 1.4em; }
.checklist li { position: relative; padding: 10px 0 10px 30px; border-top: 1px solid rgba(255,255,255,.2); }
.checklist li:last-child { border-bottom: 1px solid rgba(255,255,255,.2); }
.checklist li::before {
  content: ""; position: absolute; left: 4px; top: 1.15em;
  width: 9px; height: 9px; border-radius: 50%; background: var(--sky);
}
.body > .checklist + p { margin-top: 32px; }

/* Contact */
.people { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 44px; }
@media (max-width: 640px) { .people { grid-template-columns: 1fr; } }
.people address { padding-top: 14px; border-top: 3px solid var(--blue); }
.people strong { display: block; color: var(--navy); font-size: 1.125rem; }
.people a { overflow-wrap: anywhere; }

/* ---------- Footer ---------- */
.foot { background: var(--mist); border-top: 3px solid #adbddf; font-size: 0.9375rem; line-height: 1.6; }
.foot-inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 36px 64px; padding-block: 48px 36px; }
.foot-org img { width: 150px; margin-bottom: 18px; }
.foot-org a { color: var(--navy); }
.foot-partners { max-width: 300px; }
.partner-logos { display: flex; gap: 14px; margin-top: 14px; }
.partner-logos img { height: 104px; width: auto; background: #fff; }
.foot-legal { display: flex; flex-wrap: wrap; gap: 8px 24px; padding-block: 16px 28px; border-top: 1px solid var(--mist-line); }
.foot-legal a { color: var(--navy); }
