/* ICSD 2027 — conference homepage */
:root {
  --olive: #4b5a2a;
  --olive-dark: #3f4d22;
  --accent: #8c3f1f;
  --accent-dark: #7a3e1c;
  --ink: #222;
  --muted: #444;
  --line: #c4b79a;
  --bg: #faf6ee;
  --bg-alt: #efe7d6;
  --notice: #e4d8bf;
  --white: #fff;
  --footer: #241f18;
  --footer-text: #e8e0d0;
  --wrap: 1080px;
  --radius: 3px;
  --font: "Source Sans 3", "Noto Sans", "Segoe UI", sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--bg);
}

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

h1, h2, h3 {
  font-weight: 700;
  line-height: 1.25;
  margin: 0 0 0.6em;
  color: var(--ink);
}

h1 { font-size: 1.85rem; }
h2 { font-size: 1.45rem; }
h3 { font-size: 1.05rem; margin-bottom: 0.35em; }

p { margin: 0 0 0.85em; }
p:last-child { margin-bottom: 0; }

a { color: var(--accent); }
a:hover { color: var(--accent-dark); text-decoration: underline; }

address { font-style: normal; }

.wrap {
  width: min(calc(100% - 32px), var(--wrap));
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  left: 8px;
  top: -40px;
  background: var(--white);
  color: var(--olive);
  padding: 8px 12px;
  z-index: 200;
}
.skip-link:focus { top: 8px; }

.btn {
  display: inline-block;
  padding: 8px 14px;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  border: 1px solid var(--olive);
  border-radius: var(--radius);
  background: var(--olive);
  color: var(--white);
  cursor: pointer;
}
.btn:hover { background: var(--olive-dark); border-color: var(--olive-dark); color: var(--white); text-decoration: none; }

.btn-outline {
  background: var(--white);
  color: var(--olive);
}
.btn-outline:hover { background: var(--olive); color: var(--white); }

.btn-light {
  background: transparent;
  color: var(--white);
  border-color: var(--white);
}
.btn-light:hover { background: var(--white); color: var(--ink); border-color: var(--white); }

.btn-outline-dark {
  background: transparent;
  color: var(--olive);
  border-color: var(--olive);
}
.btn-outline-dark:hover { background: var(--olive); color: var(--white); }

.text-link { font-weight: 600; }

.section { padding: 2.25rem 0; }
.section-plain { background: var(--bg-alt); }

/* Top bar */
.topbar {
  background: var(--olive-dark);
  color: #efe7d6;
  font-size: 0.82rem;
}
.topbar a { color: #fff; text-decoration: none; }
.topbar a:hover { text-decoration: underline; }
.topbar-inner {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 6px 0;
}
.topbar p { margin: 0; }

/* Header */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 12px 16px;
  padding: 10px 0;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--ink);
  min-width: 0;
  grid-column: 1;
}
.brand:hover { text-decoration: none; color: var(--ink); }
.brand-logo { width: 64px; height: auto; flex-shrink: 0; }
.brand-text { display: flex; flex-direction: column; min-width: 0; }
.brand-title {
  font-weight: 700;
  font-size: 0.98rem;
  line-height: 1.25;
  color: var(--olive);
}
.brand-sub { font-size: 0.8rem; color: var(--muted); }

.header-actions { display: flex; gap: 8px; flex-shrink: 0; }
.header-actions-bar { grid-column: 2; }
.header-actions-menu { display: none; }

.site-nav { background: var(--olive); }
.nav-inner { display: flex; align-items: center; }
.site-nav ul {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0;
  list-style: none;
  margin: 0;
  padding: 0;
}
.site-nav a {
  color: #fff;
  text-decoration: none;
  font-size: 0.95rem;
  display: inline-block;
  padding: 8px 14px 8px 0;
}
.site-nav a:hover { text-decoration: underline; color: #fff; }
.site-nav a[aria-current="page"] { font-weight: 700; }

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  background: var(--white);
  border-radius: var(--radius);
  cursor: pointer;
  padding: 0;
  grid-column: 3;
  grid-row: 1;
}
.menu-toggle-bars,
.menu-toggle-bars::before,
.menu-toggle-bars::after {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--ink);
  margin: 0 auto;
  position: relative;
}
.menu-toggle-bars::before,
.menu-toggle-bars::after { content: ""; position: absolute; left: 0; }
.menu-toggle-bars::before { top: -6px; }
.menu-toggle-bars::after { top: 6px; }

/* Updates */
.updates {
  background: var(--notice);
  border-bottom: 1px solid #d4c6a8;
  font-size: 0.9rem;
}
.updates-inner {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 7px 0;
}
.updates-label {
  margin: 0;
  font-weight: 700;
  color: var(--olive);
  white-space: nowrap;
}
.updates-viewport { overflow: hidden; flex: 1; min-width: 0; }
.updates-track {
  display: flex;
  gap: 4rem;
  width: max-content;
  animation: ticker 36s linear infinite;
}
.updates-track p { margin: 0; white-space: nowrap; }
.updates:hover .updates-track { animation-play-state: paused; }

@keyframes ticker {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* Hero */
.hero {
  position: relative;
  color: var(--white);
  background: #1a1914;
  min-height: 28rem;
}
.hero-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 45%;
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: rgba(28, 26, 18, 0.55);
}
.hero-inner {
  position: relative;
  z-index: 1;
  padding: 2.75rem 0 2rem;
  max-width: 44rem;
  margin-left: auto;
  margin-right: auto;
  width: min(calc(100% - 32px), 44rem);
}
.hero-inner { margin-left: max(16px, calc((100% - var(--wrap)) / 2)); }

.hero-kicker { margin: 0 0 0.7rem; font-size: 0.95rem; }
.hero h1 { color: var(--white); font-size: clamp(1.6rem, 3vw, 2.15rem); font-weight: 700; margin-bottom: 0.6rem; }
.hero-sub { font-size: 1.05rem; margin-bottom: 0.6rem; }
.hero-auspices { font-size: 0.95rem; color: #eee; margin-bottom: 1.15rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 1rem; }
.countdown { margin: 0 0 1.25rem; font-size: 0.95rem; }
.photo-credit {
  margin: 0;
  font-size: 0.75rem;
  color: var(--footer-text);
}
.photo-credit a { color: #fff; }

/* Facts */
.facts { padding: 0; border-bottom: 1px solid var(--line); }
.facts-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.98rem;
}
.facts-table th,
.facts-table td {
  text-align: left;
  padding: 10px 12px 10px 0;
  vertical-align: top;
}
.facts-table th {
  font-weight: 700;
  font-size: 0.8rem;
  padding-top: 14px;
  padding-bottom: 0;
}
.facts-table td { padding-bottom: 14px; }

/* About */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: start;
}
.about-photo figcaption {
  margin-top: 0.4rem;
  font-size: 0.8rem;
  color: var(--muted);
}
.about-photo img { width: 100%; border: 1px solid var(--line); }

/* Pillars */
.pillar-list { display: grid; grid-template-columns: 1fr 1fr; gap: 0 2.5rem; }
.pillar-list article {
  padding: 1rem 0;
  border-top: 1px solid var(--line);
}
.pillar-list article p { color: var(--muted); }

/* Tables */
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.98rem;
}
.data-table th,
.data-table td {
  border: 1px solid var(--line);
  padding: 8px 10px;
  text-align: left;
  vertical-align: top;
}
.data-table thead th { background: var(--bg-alt); font-weight: 700; }

/* Partner / lists */
.partner-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: start;
}
.plain-list,
.attend-list {
  margin: 0;
  padding-left: 1.2rem;
}
.attend-list {
  columns: 2;
  column-gap: 2.5rem;
}
.attend-list li,
.plain-list li { break-inside: avoid; margin-bottom: 0.35rem; }

/* Organizers */
.logo-strip {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 12px;
  align-items: stretch;
}
.org {
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--line);
  padding: 12px 14px;
  background: var(--white);
  min-height: 100px;
}
.org img { width: 56px; height: auto; flex-shrink: 0; }
.org p { margin: 0; }
.org-text { justify-content: center; text-align: center; }
.org-cta {
  text-decoration: none;
  color: inherit;
  justify-content: center;
  text-align: center;
  border-style: dashed;
}
.org-cta:hover { color: var(--accent); }

/* Closing */
.closing {
  background: var(--bg-alt);
  border-top: 1px solid var(--line);
  padding: 2rem 0;
}
.closing .hero-actions { margin-bottom: 0; }

/* Footer */
.site-footer {
  background: var(--footer);
  color: var(--footer-text);
  font-size: 0.92rem;
  padding: 2rem 0 1.25rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr 1.1fr;
  gap: 1.75rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid #5a5346;
}
.footer-brand {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}
.footer-brand img { flex-shrink: 0; }
.footer-heading {
  margin: 0 0 0.45rem;
  font-weight: 700;
  color: #fff;
  font-size: 0.85rem;
}
.footer-heading + .footer-heading,
.site-footer .footer-heading:not(:first-child) { margin-top: 0.9rem; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin: 0 0 0.25rem; }
.site-footer a { color: #eee8dc; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 1rem;
  font-size: 0.82rem;
  color: #c4bba8;
}

@media (max-width: 960px) {
  .header-inner { grid-template-columns: 1fr auto; }
  .header-actions-bar { display: none; }
  .header-actions-menu { display: flex; padding: 10px 0 4px; }
  .menu-toggle { display: inline-flex; align-items: center; justify-content: center; grid-column: 2; }
  .site-nav {
    display: none;
    background: var(--white);
    border-top: 1px solid var(--line);
  }
  body.nav-open .site-nav { display: block; }
  .nav-inner { flex-direction: column; align-items: stretch; }
  .site-nav ul { flex-direction: column; align-items: stretch; }
  .site-nav a {
    color: var(--ink);
    display: block;
    padding: 8px 0;
    border-bottom: 1px solid var(--line);
  }
  .site-nav a:hover,
  .site-nav a[aria-current="page"] { color: var(--olive); }
  .about-grid,
  .pillar-list,
  .partner-layout,
  .logo-strip,
  .footer-grid { grid-template-columns: 1fr; }
  .attend-list { columns: 1; }
  .hero-inner { margin-left: auto; width: min(calc(100% - 32px), var(--wrap)); }
}

@media (max-width: 640px) {
  .facts-table, .facts-table tbody, .facts-table tr, .facts-table th, .facts-table td { display: block; }
  .facts-table thead { display: none; }
  .facts-table td { padding: 2px 0 12px; }
  .facts-table td::before {
    content: attr(data-label);
    display: block;
    font-weight: 700;
    font-size: 0.8rem;
    padding-top: 8px;
  }
  /* labels via first-child etc if no data-label - we'll add data-label in HTML if needed.
     Fallback: use th from thead is hidden, so add data-labels in HTML. */
  .hero { min-height: 0; }
  .hero-inner { padding: 1.75rem 0 1.5rem; }
  .topbar-inner { flex-direction: column; gap: 2px; }
  .brand-title { font-size: 0.9rem; }
  .updates-track { animation-duration: 42s; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .updates-track { animation: none; }
  .updates-viewport { overflow: visible; }
  .updates-track { display: block; width: auto; }
  .updates-track p { white-space: normal; }
  .updates-track p[aria-hidden="true"] { display: none; }
}

/* Inner pages */
.page-header {
  padding: 2rem 0 1.5rem;
  border-bottom: 1px solid var(--line);
  background: var(--bg);
}
.page-header h1 { margin-bottom: 0.45em; }
.page-header .lede { max-width: 42rem; color: var(--muted); }

.page-main { padding-bottom: 2.5rem; }
.prose { max-width: 42rem; }
.prose ul, .prose ol { margin: 0 0 1rem; padding-left: 1.25rem; }
.prose li { margin-bottom: 0.3rem; }

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 1rem 0 0;
}
.cta-row.top { margin-top: 0; margin-bottom: 1rem; }

.tba {
  display: inline;
  font-weight: 600;
  color: var(--accent);
}
.note {
  margin: 0 0 1rem;
  padding: 10px 12px;
  background: var(--bg-alt);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  max-width: 42rem;
}
.draft-banner {
  margin: 0 0 1.25rem;
  padding: 10px 12px;
  background: var(--notice);
  border: 1px solid #d4c6a8;
  border-radius: var(--radius);
  max-width: 46rem;
}

button.btn { font-family: inherit; }
button.btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

/* Forms */
.form-card {
  max-width: 40rem;
}
.form-card h2 { margin-top: 0; }
.field {
  margin: 0 0 1rem;
}
.field label,
.field .label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.3rem;
}
.optional { font-weight: 400; color: var(--muted); }
.field input[type="text"],
.field input[type="email"],
.field input[type="tel"],
.field input[type="url"],
.field input[type="number"],
.field input[type="file"],
.field select,
.field textarea {
  width: 100%;
  max-width: 40rem;
  padding: 8px 10px;
  font-family: inherit;
  font-size: 1rem;
  color: var(--ink);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.field textarea { min-height: 7rem; resize: vertical; }
.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: 2px solid var(--olive);
  outline-offset: 2px;
  border-color: var(--olive);
}
.field input[aria-invalid="true"],
.field select[aria-invalid="true"],
.field textarea[aria-invalid="true"] {
  border-color: var(--accent);
}
.hint { display: block; margin-top: 0.25rem; font-size: 0.85rem; color: var(--muted); }
.checkbox, .check-list label {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-weight: 400;
  margin-bottom: 0.35rem;
}
.checkbox input, .check-list input { margin-top: 0.3rem; flex-shrink: 0; }
.check-list { margin: 0.25rem 0 0; }

.honeypot {
  position: absolute;
  left: -10000px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.form-errors {
  display: none;
  margin: 0 0 1rem;
  padding: 10px 12px;
  border: 1px solid var(--accent);
  background: #f8efe8;
  border-radius: var(--radius);
}
.form-errors.is-visible { display: block; }
.form-errors h3 { font-size: 1rem; color: var(--accent-dark); margin-bottom: 0.4em; }
.form-errors ul { margin: 0; padding-left: 1.2rem; }

.form-success {
  display: none;
  max-width: 40rem;
  padding: 1.25rem 1rem;
  border: 1px solid var(--line);
  background: var(--white);
  border-radius: var(--radius);
}
.form-success.is-visible { display: block; }
.form-success h2 { color: var(--olive-dark); }
.local-note { margin-top: 1rem; }

.unavailable {
  display: inline-block;
  font-size: 0.9rem;
  color: var(--muted);
}

.map-link { margin: 0.75rem 0 1rem; }
.map-frame {
  width: 100%;
  max-width: 42rem;
  height: 240px;
  border: 1px solid var(--line);
  background: var(--bg-alt);
}

.faq details {
  border-bottom: 1px solid var(--line);
  padding: 0.7rem 0;
}
.faq summary {
  cursor: pointer;
  font-weight: 600;
}
.faq details p { margin: 0.45rem 0 0; color: var(--muted); }

.step-list { padding-left: 1.25rem; }
.step-list li { margin-bottom: 0.45rem; }

@media (max-width: 960px) {
  .map-frame { height: 200px; }
}

figure.page-figure { margin: 0 0 1rem; max-width: 42rem; }
figure.page-figure img { border: 1px solid var(--line); }
figure.page-figure figcaption { font-size: 0.85rem; color: var(--muted); margin-top: 0.35rem; }

h4 {
  font-weight: 700;
  font-size: 1rem;
  margin: 0 0 0.4em;
  color: var(--ink);
}

.page-header + .section { padding-top: 1.75rem; }


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


/* Keep telephone numbers on one line */
a[href^="tel:"] { white-space: nowrap; }

.table-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 0 0 1rem;
  max-width: 100%;
}
