/* ==========================================================
   Kamoun Lab Alumni & Friends — site styles
   Modular: every section is a <section class="block"> with its own
   id; swap/reorder blocks in index.html without touching this file.
   Change the accent in one place: --accent.
   ========================================================== */

:root {
  --bg: #fdfdfb;
  --bg-soft: #f4f4ef;
  --ink: #17181c;
  --ink-2: #4a4c55;
  --ink-3: #8a8c96;
  --line: #e4e4dd;
  --accent: #d8461f;
  --accent-ink: #b1361a;
  --accent-soft: #fbe9e2;
  --max: 1080px;
  --radius: 14px;
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent-ink); text-decoration: none; border-bottom: 1px solid transparent; }
a:hover { border-bottom-color: currentColor; }
img { max-width: 100%; display: block; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 500; line-height: 1.15; margin: 0; letter-spacing: -0.01em; }
h2 { font-size: clamp(30px, 4vw, 42px); margin-bottom: 14px; }
h3 { font-size: 22px; margin-bottom: 8px; }
p { margin: 0 0 1em; }
.muted { color: var(--ink-2); }
.small { font-size: 14px; color: var(--ink-3); }
.check { display: inline-block; font-size: 11px; font-weight: 600; letter-spacing: .04em; padding: 1px 6px; border-radius: 4px; background: #fff3c4; color: #7a5a00; vertical-align: middle; margin-left: 4px; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 22px; }
.block { padding: 84px 0; border-top: 1px solid var(--line); }
.block.soft { background: var(--bg-soft); }
.kicker { font-size: 13px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); margin-bottom: 14px; }
.lede { font-size: 20px; color: var(--ink-2); max-width: 720px; }

/* ---------- Nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(253,253,251,.9);
  backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav .wrap { display: flex; align-items: center; justify-content: space-between; height: 60px; gap: 16px; }
.brand { font-family: var(--font-display); font-size: 18px; color: var(--ink); white-space: nowrap; }
.brand span { color: var(--accent); }
.nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; }
.nav ul::-webkit-scrollbar { display: none; }
.nav li a { display: block; padding: 8px 11px; font-size: 14px; color: var(--ink-2); border-radius: 8px; border-bottom: 0; white-space: nowrap; }
.nav li a:hover, .nav li a.active { background: var(--accent-soft); color: var(--accent-ink); }

/* ---------- Hero ---------- */
.hero { padding: 96px 0 72px; position: relative; overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: auto -10% -40% auto; width: 60vw; max-width: 720px; aspect-ratio: 1;
  background: radial-gradient(closest-side, var(--accent-soft), transparent 70%); pointer-events: none;
}
.hero .wrap { position: relative; }
.hero h1 { font-size: clamp(44px, 8vw, 92px); font-weight: 400; letter-spacing: -0.02em; }
.hero h1 em { font-style: italic; color: var(--accent); }
.hero .meta { display: flex; flex-wrap: wrap; gap: 10px 26px; margin-top: 26px; font-size: 17px; color: var(--ink-2); }
.hero .meta strong { color: var(--ink); font-weight: 600; }
.hero .actions { margin-top: 34px; display: flex; gap: 12px; flex-wrap: wrap; }
.btn { display: inline-block; padding: 12px 20px; border-radius: 999px; font-weight: 600; font-size: 15px; border: 1.5px solid var(--ink); color: var(--ink); }
.btn:hover { background: var(--ink); color: #fff; border-bottom-color: var(--ink); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.primary:hover { background: var(--accent-ink); border-color: var(--accent-ink); }

/* ---------- Welcome ---------- */
.welcome-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 48px; align-items: start; }
.welcome-grid .prose p { font-size: 19px; }
.signoff { margin-top: 24px; font-family: var(--font-display); font-size: 20px; }
.signoff .small { display: block; font-family: var(--font-body); margin-top: 4px; }
.organisers { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 24px; }
.organisers h3 { font-size: 16px; font-family: var(--font-body); font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); }
.organisers ul { list-style: none; padding: 0; margin: 12px 0 0; }
.organisers li { padding: 10px 0; border-top: 1px solid var(--line); }
.organisers li:first-child { border-top: 0; }
.organisers li strong { display: block; }

/* ---------- Cards (pre-event, venue) ---------- */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 18px; }
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.card h3 { font-size: 20px; }
.card .when { color: var(--accent-ink); font-weight: 600; font-size: 14px; letter-spacing: .04em; text-transform: uppercase; margin-bottom: 8px; }
.card p:last-child { margin-bottom: 0; }

/* ---------- Programme ---------- */
.prog { border-top: 1px solid var(--line); }
.prog .session { display: grid; grid-template-columns: 220px 1fr; gap: 18px 32px; padding: 26px 0; border-bottom: 1px solid var(--line); }
.prog .session-head h3 { font-size: 20px; }
.prog .session-head .chair { color: var(--ink-3); font-size: 14px; }
.prog .slot { display: grid; grid-template-columns: 120px 1fr; gap: 12px; padding: 9px 0; }
.prog .slot .t { font-variant-numeric: tabular-nums; color: var(--ink-2); font-weight: 600; font-size: 15px; padding-top: 2px; }
.prog .slot .who { font-weight: 600; }
.prog .slot .aff { color: var(--ink-3); font-size: 14px; }
.prog .slot .title { color: var(--ink-2); }
.prog .slot.break { color: var(--accent-ink); }
.prog .slot.break .t { color: var(--accent-ink); }
.prog .slot.discussion .title { font-style: italic; }
.prog .plain .session-head { display: none; }
.prog .plain { grid-template-columns: 1fr; }

/* ---------- Speakers ---------- */
.speakers { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; }
.speaker { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 22px; display: flex; flex-direction: column; gap: 4px; }
.speaker .session-tag { font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.speaker .name { font-family: var(--font-display); font-size: 21px; }
.speaker .aff { color: var(--ink-3); font-size: 14px; }
.speaker .title { color: var(--ink-2); font-size: 15px; margin-top: 6px; }
.speaker .link { font-size: 14px; margin-top: auto; padding-top: 10px; }

/* ---------- Venue ---------- */
.venue-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.venue-grid dl { margin: 0; }
.venue-grid dt { font-weight: 600; margin-top: 16px; }
.venue-grid dd { margin: 4px 0 0; color: var(--ink-2); }
.address { font-family: var(--font-display); font-size: 24px; }

/* ---------- Participants ---------- */
.group { margin-top: 42px; }
.group h3 { display: flex; align-items: baseline; gap: 12px; }
.group h3 .count { font-family: var(--font-body); font-size: 14px; color: var(--ink-3); font-weight: 500; }
.people { list-style: none; margin: 14px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 2px 28px; }
.people li { padding: 9px 0; border-top: 1px solid var(--line); display: flex; flex-direction: column; }
.people .n { font-weight: 600; }
.people .n a { color: var(--ink); }
.people .n a:hover { color: var(--accent-ink); }
.people .a { color: var(--ink-3); font-size: 14px; }


/* ---------- Then & Now ---------- */
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline > li { display: grid; grid-template-columns: 110px 1fr; gap: 24px; padding: 34px 0; border-top: 1px solid var(--line); }
.timeline .year { font-family: var(--font-display); font-size: 40px; color: var(--accent); line-height: 1; position: sticky; top: 80px; align-self: start; }
.timeline .entry h3 { font-size: 20px; }
.timeline .entry p { color: var(--ink-2); }
.gallery { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; margin: 14px 0 8px; }
.gallery figure { margin: 0; }
.gallery img { width: 100%; height: auto; object-fit: cover; aspect-ratio: 4/3; border-radius: 10px; background: var(--bg-soft); }
.gallery img.contain { object-fit: contain; aspect-ratio: auto; height: auto; }
.gallery figcaption { font-size: 13px; color: var(--ink-3); margin-top: 6px; }
.gallery.wide { grid-template-columns: 1fr; }
.gallery.wide img { aspect-ratio: auto; object-fit: contain; height: auto; max-height: 720px; margin: 0 auto; width: auto; max-width: 100%; }
.roster { columns: 2; column-gap: 32px; font-size: 15px; color: var(--ink-2); margin: 8px 0 0; padding-left: 18px; }

/* ---------- Networking ---------- */
.eras { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; margin-top: 24px; }
.era { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; border-top: 4px solid var(--accent); }
.era .span { font-family: var(--font-display); font-size: 24px; }
.era p { font-size: 15px; color: var(--ink-2); margin: 6px 0 0; }

/* ---------- Footer ---------- */
footer { padding: 44px 0 60px; border-top: 1px solid var(--line); color: var(--ink-3); font-size: 14px; }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .welcome-grid, .venue-grid { grid-template-columns: 1fr; }
  .prog .session { grid-template-columns: 1fr; gap: 10px; }
  .timeline > li { grid-template-columns: 1fr; gap: 6px; }
  .timeline .year { position: static; font-size: 32px; }
  .roster { columns: 1; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .block { padding: 60px 0; }
  .hero { padding: 64px 0 48px; }
  .prog .slot { grid-template-columns: 1fr; gap: 2px; }
  .brand { font-size: 16px; }
}
