/* ============ Base ============ */
:root {
  /* Donders Institute house style */
  --dark-red: #8e0000;
  --ru-red: #be311a;
  --bright-red: #ff0000;

  /* light tints of the red */
  --rose: #f8e1de;
  --rose-line: #ecccc7;

  --ink: #1a1a1a;
  --ink-soft: #555;
  --paper: #fff;
  --paper-alt: #fdf5f3;
  --accent: var(--dark-red);
  --accent-dark: var(--dark-red);
  --line: var(--rose-line);
  --bars: 14px;             /* width of the three red bars on the left */
  --radius: 14px;
  --max: 1100px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 72px; }

body {
  margin: 0;
  padding-left: var(--bars);
  font-family: "Inter", system-ui, -apple-system, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
}

h1, h2, h3 { font-family: "Fraunces", Georgia, serif; line-height: 1.15; margin: 0 0 .6em; }
h2 { font-size: clamp(1.8rem, 3.5vw, 2.4rem); }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; }
a { color: var(--accent-dark); }

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 24px; }

/* Three red bars on the left (Donders house style) */
.bars { position: fixed; left: 0; top: 0; bottom: 0; width: var(--bars); display: flex; z-index: 20; }
.bars span:nth-child(1) { flex: 7; background: var(--dark-red); }
.bars span:nth-child(2) { flex: 5; background: var(--ru-red); }
.bars span:nth-child(3) { flex: 2; background: var(--bright-red); opacity: .55; }

/* ============ Header ============ */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; gap: 24px; height: 64px; }
.logo { font-family: "Fraunces", serif; font-weight: 800; font-size: 1.25rem; color: var(--ink); text-decoration: none; }
.logo span { color: var(--accent); }
.nav { display: flex; gap: 20px; margin-left: auto; }
.nav a { color: var(--ink-soft); text-decoration: none; font-size: .95rem; font-weight: 500; }
.nav a:hover { color: var(--accent-dark); }

.lang-toggle { display: flex; border: 1px solid var(--line); border-radius: 999px; overflow: hidden; }
.lang-toggle button {
  font: inherit; font-size: .85rem; font-weight: 600;
  border: 0; background: transparent; color: var(--ink-soft);
  padding: 6px 12px; cursor: pointer;
}
.lang-toggle button[aria-pressed="true"] { background: var(--dark-red); color: #fff; }

/* Hero  */
.hero {
  background: var(--paper-alt);
  color: var(--ink);
  padding: 96px 0 88px;
  position: relative;
  overflow: hidden;
}
/* simple grid of dots = "memory" motif */
.hero::after {
  content: "";
  position: absolute; inset: 0;
  background-image: radial-gradient(rgba(142,0,0,.13) 1.5px, transparent 1.5px);
  background-size: 28px 28px;
  pointer-events: none;
}
.hero-inner { position: relative; z-index: 1; }
.eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: .8rem; font-weight: 600; color: var(--accent); }
.hero h1 { font-size: clamp(2.4rem, 6vw, 4.4rem); font-weight: 800; margin-bottom: .4em; }
.hero .year { color: var(--accent); }
.hero-meta { font-size: 1.15rem; color: #4a4040; }
.hero-meta .dot { margin: 0 .5em; }
.hero-note { font-size: .95rem; color: #4a4040; margin-top: 18px; }

.countdown { display: flex; gap: 14px; margin: 28px 0; }
.countdown div {
  min-width: 84px; padding: 12px 14px; text-align: center;
  border: 1px solid #f3dcd8; /* lighter than --rose-line to suit the lighter hero */ border-radius: var(--radius);
  background: #fff;
}
.countdown span { display: block; font-family: "Fraunces", serif; font-size: 2rem; font-weight: 800; }
.countdown small { color: #4a4040; font-size: .8rem; }

.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* brain made of letters and numbers, decorative, hidden on small screens */
.hero-brain { display: none; position: absolute; right: 4px; bottom: -8px; width: 300px; height: auto; transform: rotate(6deg); }
@media (min-width: 1001px) { .hero-brain { display: block; } }
@media (min-width: 1200px) { .hero-brain { width: 375px; right: -10px; } }

/* Buttons */
.btn {
  display: inline-block; text-decoration: none; font-weight: 600; font-size: 1.05rem;
  padding: 12px 22px; border-radius: 999px; border: 2px solid transparent;
  transition: background .15s, color .15s, border-color .15s;
}
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--ru-red); }
.btn-ghost { border-color: currentColor; color: var(--accent); }
.btn-ghost:hover { background: rgba(142,0,0,.07); }
.btn-large { padding: 16px 30px; }

/* Key facts */
.facts { border-bottom: 1px solid var(--line); background: #fff; }
.facts-grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.fact { padding: 26px 20px; border-right: 1px solid var(--line); }
.fact:last-child { border-right: 0; }
.fact h3 { font-family: "Inter", sans-serif; font-size: .78rem; text-transform: uppercase; letter-spacing: .1em; color: var(--ink-soft); margin-bottom: .3em; }
.fact p { margin: 0; font-weight: 600; font-size: 1.05rem; }

/* Sections */
.section { padding: 80px 0; }
.section-alt { background: var(--paper-alt); }
.lead { color: var(--ink-soft); max-width: 680px; }
.two-col { display: grid; grid-template-columns: 1.3fr 1fr; gap: 48px; align-items: start; }
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
.card h3:not(:first-child) { margin-top: 1.2em; }
.fine-print { font-size: .82rem; color: var(--ink-soft); margin-bottom: 0; }

/* "TBA" / "provisional" marker — easy to spot what is still open */
.tba {
  display: inline-block; font-size: .8rem; font-weight: 600;
  padding: 2px 10px; border-radius: 999px;
  background: #fff; color: var(--accent-dark); border: 1px dashed var(--ru-red);
}

/* Disciplines (moving row) */
.marquee {
  overflow: hidden;
  margin-top: 32px;
  padding: 8px 0;
  /* fade the cards in and out at the screen edges */
  mask-image: linear-gradient(to right, transparent, #000 6%, #000 94%, transparent);
  -webkit-mask-image: linear-gradient(to right, transparent, #000 6%, #000 94%, transparent);
}
.marquee-track {
  list-style: none; margin: 0; padding: 0;
  display: flex; gap: 16px; width: max-content;
  /* moves left -> right; the list is doubled, so -50% to 0 loops seamlessly */
  animation: slide-right 60s linear infinite;
}
.marquee:hover .marquee-track,
.marquee:focus-within .marquee-track { animation-play-state: paused; }
@keyframes slide-right {
  from { transform: translateX(0); }
  to   { transform: translateX(calc(-50% - 8px)); }
}
.marquee-track li {
  flex: 0 0 260px;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px 22px 20px;
}
.marquee-track .num {
  display: block; margin-bottom: 6px;
  font-family: "Fraunces", serif; font-weight: 800; font-size: 1.1rem; color: var(--accent);
}
.marquee-track h3 { font-size: 1.05rem; margin-bottom: .35em; }
.marquee-track p { margin: 0; font-size: .93rem; color: var(--ink-soft); }

/* People who turn off motion in their system settings get a still, swipeable row */
@media (prefers-reduced-motion: reduce) {
  .marquee { overflow-x: auto; mask-image: none; -webkit-mask-image: none; }
  .marquee-track { animation: none; padding: 0 24px; }
  .marquee-track li[aria-hidden="true"] { display: none; }
}

/* ============ Schedule ============ */
.days { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-top: 32px; align-items: start; }
.day { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.day h3 { margin: 0; padding: 18px 24px; background: var(--paper-alt); color: var(--dark-red); }
.day ul { list-style: none; margin: 0; padding: 8px 0; }
.day li { display: grid; grid-template-columns: 70px 1fr; gap: 12px; padding: 10px 24px; border-bottom: 1px solid var(--line); }
.day li:last-child { border-bottom: 0; }
.day time { font-weight: 600; font-variant-numeric: tabular-nums; }
.day li.break { color: var(--ink-soft); font-style: italic; }
.day li.disc span { font-weight: 600; }
.day li.disc .attempt { color: var(--ink-soft); font-weight: 400; margin-left: .35em; }

/* ============ Participation ============ */
.checklist { list-style: none; padding: 0; margin: 0; }
.checklist li { padding: 10px 0 10px 32px; position: relative; border-bottom: 1px solid var(--line); }
.checklist li::before { content: "✓"; position: absolute; left: 4px; color: var(--accent); font-weight: 700; }
.prize-list { list-style: none; padding: 0; margin: 0 0 14px; }
.prize-list li { padding: 6px 0 6px 32px; position: relative; }
/* Trophy icon: inlined copy of assets/trophy.svg (inlined so the mask also works when opening the file locally) */
.prize-list li::before {
  content: ""; position: absolute; left: 0; top: 50%; transform: translateY(-50%);
  width: 22px; height: 22px; background: var(--dark-red);
  --trophy: url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 24 24%22 width=%2224%22 height=%2224%22 fill=%22none%22 stroke=%22currentColor%22 stroke-width=%221.75%22 stroke-linecap=%22round%22 stroke-linejoin=%22round%22 aria-hidden=%22true%22%3E %3Cpath d=%22M6.5 3.5h11v4c0 3.3-2.4 5.8-5.5 5.8S6.5 10.8 6.5 7.5z%22/%3E %3Cpath d=%22M6.5 5.2H4.3c0 2.6 1.1 4.3 3.1 4.8%22/%3E %3Cpath d=%22M17.5 5.2h2.2c0 2.6-1.1 4.3-3.1 4.8%22/%3E %3Cpath d=%22M12 13.3v3%22/%3E %3Cpath d=%22M9.5 16.3h5l.6 2.2H8.9z%22/%3E %3Cpath d=%22M7.5 20.5h9%22/%3E %3C/svg%3E");
  -webkit-mask: var(--trophy) center / contain no-repeat;
  mask: var(--trophy) center / contain no-repeat;
}

/* ============ Registration ============ */
.steps { list-style: none; padding: 0; margin: 32px 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; counter-reset: step; }
.steps li { counter-increment: step; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px; }
.steps li::before {
  content: counter(step);
  width: 34px; height: 34px; border-radius: 50%;
  background: var(--accent); color: #fff; font-weight: 700;
  display: grid; place-items: center; margin-bottom: 6px;
}
.steps span { color: var(--ink-soft); font-size: .95rem; }
.register-box { text-align: center; padding: 36px; border-radius: var(--radius); background: var(--paper-alt); }
.register-box p { margin-bottom: 20px; }

/* ============ Venue ============ */
address { font-style: normal; margin-bottom: 1em; line-height: 1.7; }
.map-wrap { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: #fff; aspect-ratio: 4 / 3; }
.map-wrap iframe { width: 100%; height: 100%; border: 0; display: block; }

/* ============ Footer ============ */
.partner-logos { background: #fff; border-top: 1px solid var(--line); padding: 24px 0; }
.partner-logos .container { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 16px 36px; }
.partner-logos a { display: block; transition: opacity .15s; }
.partner-logos a:hover { opacity: .7; }
.partner-logos img { display: block; width: auto; }
.logo-donders { height: 42px; position: relative; top: -5px; } /* lines up its name with the other two */
.logo-ru { height: 36px; }
.partner-logos .logo-umc { height: 42px; margin: 0 -7px; } /* this file has white space around the logo */
.site-footer { background: var(--rose); color: #4a4040; padding: 28px 0; font-size: .9rem; }
.site-footer p { margin: 0; }

/* ============ Responsive ============ */
@media (max-width: 860px) {
  .nav { display: none; }
  .lang-toggle { margin-left: auto; }
  :root { --bars: 8px; }
  .two-col, .days, .steps { grid-template-columns: 1fr; }
  .facts-grid { grid-template-columns: 1fr 1fr; }
  .fact:nth-child(2) { border-right: 0; }
  .fact:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .section { padding: 56px 0; }
  .hero { padding: 64px 0; }
  .hero-meta span { display: block; }
  .hero-meta .dot { display: none; }
}
@media (max-width: 480px) {
  .partner-logos .container { flex-direction: column; }
  .container { padding: 0 16px; }
  /* countdown always fits in one row */
  .countdown { gap: 8px; }
  .countdown div { flex: 1; min-width: 0; padding: 10px 4px; }
  .countdown span { font-size: 1.6rem; }
}
