/* IMS annual conference 2026 - visual language follows the conference poster:
   deep navy, National Library blue, pale stone. Room colours follow the booklet's floor map. */
:root {
  --navy: #14295a;
  --blue: #24509a;
  --blue-soft: #e4ecf8;
  --ink: #1b2436;
  --muted: #5b6577;
  --line: #dbe1ea;
  --bg: #f4f6f9;
  --card: #ffffff;
  --sem: #b4622a;
  --sem-bg: #fbeee4;
  --exhibit: #6d4a9c;
  --exhibit-bg: #efe8f7;
  --foyer: #2f7a68;
  --foyer-bg: #e3f1ed;
  --warn-bg: #fff4d6;
  --warn: #7a5200;
  --ok: #1f7a4a;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(20, 41, 90, .06), 0 4px 14px rgba(20, 41, 90, .06);
  --tabs-h: 62px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 70px; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 400 16px/1.6 Heebo, "Segoe UI", "Arial Hebrew", Arial, sans-serif;
  padding-bottom: calc(var(--tabs-h) + env(safe-area-inset-bottom) + 18px);
}
a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { color: var(--navy); line-height: 1.25; margin: 0; text-wrap: balance; }
h1 { font-size: 1.55rem; font-weight: 800; }
h2 { font-size: 1.15rem; font-weight: 700; }
h3 { font-size: 1rem; font-weight: 700; }
p { margin: 0 0 .9em; }
button, input, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid #7aa7e8; outline-offset: 2px; border-radius: 6px; }
.skip { position: absolute; inset-inline-start: -999px; }
.skip:focus { inset-inline-start: 8px; top: 8px; background: #fff; padding: 8px 12px; z-index: 50; }

/* top bar */
.top {
  position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between;
  gap: 8px; padding: 8px 14px; background: rgba(255, 255, 255, .96); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--navy); font-weight: 500; font-size: .92rem; line-height: 1.2; min-width: 0; }
.brand:hover { text-decoration: none; }
.brand img { height: 34px; width: auto; flex: none; mix-blend-mode: multiply; }
.brand b { font-weight: 800; }
.top-btn { flex: none; width: 42px; height: 42px; display: grid; place-items: center; border-radius: 50%; color: var(--navy); }
.top-btn:hover { background: var(--blue-soft); }
svg.i { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }

.announce { background: var(--warn-bg); color: var(--warn); padding: 10px 16px; font-weight: 500; display: flex; gap: 10px; align-items: flex-start; border-bottom: 1px solid #f0dca0; }
.announce[hidden] { display: none; }
.announce span { flex: 1; }
.announce button { background: none; border: 0; cursor: pointer; font-size: 1.2rem; line-height: 1; padding: 2px 6px; color: inherit; }

main { max-width: 760px; margin: 0 auto; padding: 16px 16px 8px; outline: none; }
.loading, .empty { color: var(--muted); text-align: center; padding: 40px 10px; }
.page-head { margin: 4px 0 16px; }
.page-head p { color: var(--muted); margin: 6px 0 0; }
.crumb { display: inline-flex; align-items: center; gap: 4px; font-size: .9rem; margin-bottom: 10px; }

/* bottom tabs */
.tabs {
  position: fixed; bottom: 0; inset-inline: 0; z-index: 30; display: flex; justify-content: space-around;
  background: #fff; border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom);
  height: calc(var(--tabs-h) + env(safe-area-inset-bottom));
}
.tabs a { flex: 1; max-width: 150px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; color: var(--muted); font-size: .72rem; font-weight: 500; position: relative; }
.tabs a:hover { text-decoration: none; color: var(--navy); }
.tabs a[aria-current="page"] { color: var(--blue); font-weight: 700; }
.tabs a[aria-current="page"]::before { content: ""; position: absolute; top: 0; width: 34px; height: 3px; border-radius: 0 0 3px 3px; background: var(--blue); }
.tabs .badge { position: absolute; top: 8px; inset-inline-start: calc(50% + 6px); background: var(--blue); color: #fff; border-radius: 9px; font-size: .62rem; min-width: 17px; height: 17px; display: grid; place-items: center; padding: 0 4px; font-weight: 700; }

/* hero */
.hero { margin: -16px -16px 18px; background: var(--navy); color: #fff; }
.hero img { display: block; width: 100%; height: 190px; object-fit: cover; object-position: center 40%; }
.hero-text { padding: 16px 18px 20px; }
.hero small { display: block; font-size: 1rem; font-weight: 500; opacity: .85; }
.hero h1 { color: #fff; font-size: 1.75rem; margin: 2px 0 10px; }
.hero .meta { display: flex; flex-wrap: wrap; gap: 4px 18px; font-size: .95rem; opacity: .92; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px; margin-bottom: 14px; }
.card > h2 { margin-bottom: 10px; }
.kicker { font-size: .78rem; font-weight: 700; letter-spacing: .02em; color: var(--blue); display: flex; align-items: center; gap: 6px; margin-bottom: 6px; }
.live-dot { width: 9px; height: 9px; border-radius: 50%; background: #d43b3b; box-shadow: 0 0 0 0 rgba(212, 59, 59, .5); animation: pulse 1.8s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 9px rgba(212, 59, 59, 0); } 100% { box-shadow: 0 0 0 0 rgba(212, 59, 59, 0); } }
@media (prefers-reduced-motion: reduce) { .live-dot { animation: none; } }

.tiles { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 14px; }
.tile { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; color: var(--navy); font-weight: 700; display: flex; flex-direction: column; gap: 6px; box-shadow: var(--shadow); }
.tile:hover { text-decoration: none; border-color: var(--blue); }
.tile span { font-weight: 400; font-size: .85rem; color: var(--muted); line-height: 1.35; }
.tile svg { color: var(--blue); }

/* room chips */
.room { display: inline-flex; align-items: center; gap: 5px; font-size: .8rem; font-weight: 700; padding: 2px 9px; border-radius: 99px; white-space: nowrap; }
.room::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.room-sem1, .room-sem3, .room-sem { color: var(--sem); background: var(--sem-bg); }
.room-exhibit { color: var(--exhibit); background: var(--exhibit-bg); }
.room-foyer { color: var(--foyer); background: var(--foyer-bg); }
.time { font-weight: 800; color: var(--navy); font-variant-numeric: tabular-nums; }
.metaline { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; color: var(--muted); font-size: .9rem; }
.tag { font-size: .74rem; font-weight: 700; color: var(--blue); background: var(--blue-soft); border-radius: 6px; padding: 1px 7px; }

/* programme */
.jump { position: sticky; top: 59px; z-index: 10; display: flex; gap: 8px; overflow-x: auto; padding: 8px 16px; margin: 0 -16px 12px; background: var(--bg); scrollbar-width: none; }
.jump::-webkit-scrollbar { display: none; }
.chip { flex: none; border: 1px solid var(--line); background: #fff; color: var(--navy); border-radius: 99px; padding: 5px 13px; font-size: .88rem; font-weight: 500; cursor: pointer; font-variant-numeric: tabular-nums; }
.chip:hover { text-decoration: none; border-color: var(--blue); }
.chip.on { background: var(--navy); border-color: var(--navy); color: #fff; }
.slot { margin-bottom: 22px; }
.slot-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 10px; border-bottom: 2px solid var(--navy); padding-bottom: 4px; }
.slot-head .time { font-size: 1.3rem; }
.slot-head span { color: var(--muted); font-size: .88rem; }
.plain-row { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 10px; background: #e9edf3; color: var(--muted); margin-bottom: 22px; font-weight: 500; }
.plain-row .time { font-size: 1rem; }
.sess { padding: 0; overflow: hidden; }
.sess-head { display: block; padding: 14px 16px 12px; color: inherit; border-bottom: 1px solid var(--line); }
.sess-head:hover { text-decoration: none; background: #fafbfd; }
.sess-head h3 { margin: 6px 0 4px; font-size: 1.05rem; }
.talk-row { display: flex; align-items: flex-start; gap: 4px; border-bottom: 1px solid var(--line); }
.talk-row:last-child { border-bottom: 0; }
.talk-row > a { flex: 1; padding: 11px 16px 11px 6px; color: var(--ink); min-width: 0; }
.talk-row > a:hover { text-decoration: none; background: #fafbfd; }
.talk-row .t { font-weight: 500; line-height: 1.4; }
.talk-row .s { color: var(--muted); font-size: .88rem; margin-top: 2px; }
.star { flex: none; background: none; border: 0; cursor: pointer; width: 46px; min-height: 46px; display: grid; place-items: center; color: #a9b2c2; border-radius: 10px; }
.star:hover { color: var(--blue); }
.star svg { width: 23px; height: 23px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linejoin: round; }
.star[aria-pressed="true"] { color: #e0a100; }
.star[aria-pressed="true"] svg { fill: currentColor; }
.star.big { width: auto; padding: 8px 14px; border: 1px solid var(--line); background: #fff; gap: 8px; display: inline-flex; align-items: center; font-weight: 500; color: var(--navy); min-height: 42px; }
.star.big svg { color: #a9b2c2; }
.star.big[aria-pressed="true"] { background: #fff8e1; border-color: #ecd27a; }
.star.big[aria-pressed="true"] svg { color: #e0a100; }

/* talk page */
.abstract p { text-align: start; hyphens: auto; }
.abstract h4 { color: var(--navy); margin: 1.2em 0 .4em; font-size: 1rem; }
.abstract ul, .list { margin: 0 0 1em; padding-inline-start: 1.2em; }
.abstract li, .list li { margin-bottom: .35em; }
.who { display: flex; flex-direction: column; gap: 8px; margin: 12px 0 4px; }
.who a { display: flex; align-items: center; gap: 10px; color: var(--navy); font-weight: 700; }
.avatar { flex: none; width: 38px; height: 38px; border-radius: 50%; background: var(--blue-soft); color: var(--blue); display: grid; place-items: center; font-weight: 800; font-size: .95rem; }
.who small { display: block; font-weight: 400; color: var(--muted); font-size: .82rem; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0 2px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid var(--line); background: #fff; color: var(--navy); border-radius: 10px; padding: 8px 14px; font-weight: 500; cursor: pointer; min-height: 42px; }
.btn:hover { text-decoration: none; border-color: var(--blue); }
.btn.primary { background: var(--blue); border-color: var(--blue); color: #fff; font-weight: 700; }
.btn.primary:hover { background: var(--navy); }
.btn[disabled] { opacity: .55; cursor: default; }
.btn.small { min-height: 34px; padding: 4px 10px; font-size: .86rem; }
details.bio { border-top: 1px solid var(--line); padding: 10px 0; }
details.bio:last-of-type { border-bottom: 1px solid var(--line); }
details.bio summary { cursor: pointer; font-weight: 700; color: var(--navy); }
details.bio p { margin: 8px 0 0; color: var(--ink); }
.ltr { direction: ltr; text-align: left; }
.way { background: var(--blue-soft); border-radius: 10px; padding: 10px 14px; font-size: .92rem; margin-top: 12px; }
.way b { color: var(--navy); }

/* message form */
.msg { border-color: #c5d4ee; background: linear-gradient(#f7faff, #fff 90px); }
.msg .lock { display: flex; gap: 8px; color: var(--muted); font-size: .88rem; margin: 2px 0 12px; align-items: flex-start; }
.msg .lock svg { flex: none; margin-top: 2px; width: 17px; height: 17px; }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; margin-bottom: 10px; background: #fff; }
.seg label { padding: 7px 16px; cursor: pointer; font-weight: 500; color: var(--muted); }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg input:checked + span { color: #fff; }
.seg label:has(input:checked) { background: var(--navy); color: #fff; }
.seg label:has(input:focus-visible) { outline: 3px solid #7aa7e8; outline-offset: -3px; }
textarea, input[type="text"], input[type="search"] { width: 100%; border: 1px solid #c3ccd9; border-radius: 10px; padding: 10px 12px; background: #fff; }
textarea { min-height: 110px; resize: vertical; display: block; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 8px 0 12px; }
@media (max-width: 480px) { .row2 { grid-template-columns: 1fr; } }
.hp { position: absolute; inset-inline-start: -9999px; }
.hint { color: var(--muted); font-size: .84rem; }
.sent { border-top: 1px solid var(--line); margin-top: 14px; padding-top: 10px; }
.bubble { background: var(--blue-soft); border-radius: 12px 12px 12px 3px; padding: 9px 12px; margin: 8px 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.bubble small { display: block; color: var(--muted); font-size: .78rem; margin-top: 4px; }
.bubble.pending { background: var(--warn-bg); }

/* people */
.people { list-style: none; margin: 0; padding: 0; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.people li + li { border-top: 1px solid var(--line); }
.people a { display: flex; align-items: center; gap: 12px; padding: 10px 14px; color: var(--ink); }
.people a:hover { background: #fafbfd; text-decoration: none; }
.people .n { font-weight: 700; color: var(--navy); }
.people .r { color: var(--muted); font-size: .84rem; line-height: 1.35; }
.letter { font-weight: 800; color: var(--blue); margin: 16px 4px 6px; }
.hit mark { background: #ffe9a8; color: inherit; border-radius: 3px; padding: 0 1px; }
.hit .snip { color: var(--muted); font-size: .86rem; margin-top: 3px; }

.map-img { width: 100%; height: auto; border-radius: 10px; border: 1px solid var(--line); background: #f4f6f6; display: block; }
.dir { padding-inline-start: 0; list-style: none; margin: 0; }
.dir li { padding: 10px 0; border-bottom: 1px solid var(--line); }
.dir li:last-child { border: 0; }
.donors { columns: 2; padding: 0; list-style: none; margin: 0; }
.donors li { padding: 2px 0; }
.notice { background: var(--warn-bg); color: var(--warn); border-radius: 10px; padding: 10px 14px; font-size: .92rem; margin-bottom: 12px; }
.foot { text-align: center; color: var(--muted); font-size: .82rem; padding: 16px 8px 0; }
.foot img { height: 30px; width: auto; opacity: .9; mix-blend-mode: multiply; display: block; margin: 0 auto 8px; }

/* organiser + speaker inbox */
table.grid { width: 100%; border-collapse: collapse; font-size: .88rem; }
table.grid td, table.grid th { text-align: start; padding: 7px 6px; border-bottom: 1px solid var(--line); vertical-align: top; }
.mono { font-family: ui-monospace, Consolas, monospace; font-size: .8rem; direction: ltr; overflow-wrap: anywhere; }
.m { border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; margin: 8px 0; background: #fff; }
.m.hidden-m { opacity: .5; }
.m .b { white-space: pre-wrap; overflow-wrap: anywhere; }
.m .f { color: var(--muted); font-size: .82rem; margin-top: 6px; display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: center; }

.toast { position: fixed; bottom: calc(var(--tabs-h) + env(safe-area-inset-bottom) + 14px); inset-inline: 0; margin: auto; width: max-content; max-width: calc(100% - 32px); background: var(--navy); color: #fff; padding: 10px 16px; border-radius: 12px; z-index: 40; box-shadow: 0 6px 20px rgba(0, 0, 0, .25); font-weight: 500; }
.toast[hidden] { display: none; }

@media (min-width: 700px) {
  .hero { margin: 0 0 18px; border-radius: var(--radius); overflow: hidden; }
  .hero img { height: 260px; }
  .tiles { grid-template-columns: repeat(4, 1fr); }
  h1 { font-size: 1.8rem; }
}
@media print {
  .top, .tabs, .jump, .star, .msg, .actions, .announce { display: none !important; }
  body { background: #fff; padding: 0; }
  .card { box-shadow: none; break-inside: avoid; }
}
