/* Martyrs Hall – plain, readable, works on a phone. */
:root {
  --ink: #1d2433;
  --muted: #5b6475;
  --line: #d7dbe3;
  --accent: #6b1d2a;
  --bg: #ffffff;
  --panel: #f5f6f8;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font: 16px/1.5 system-ui, -apple-system, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--bg);
}

.site-header {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 16px;
  background: var(--accent);
}
.site-header a, .site-header .link { color: #fff; }
.site-name { font-weight: 600; text-decoration: none; }
.site-header nav { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; }
.site-header form { margin: 0; }

main { max-width: 60rem; margin: 0 auto; padding: 1rem 16px 3rem; }
main.narrow { max-width: 28rem; }

h1 { font-size: 1.6rem; margin: 1rem 0; }
h2 { font-size: 1.2rem; margin-top: 2rem; }

label { display: block; font-weight: 600; margin-bottom: 0.25rem; }
input[type=text], input[type=password], input[type=email], input[type=number], input[type=tel], select {
  width: 100%;
  padding: 0.5rem;
  font: inherit;
  border: 1px solid var(--line);
  border-radius: 4px;
}
.helptext, .hint { display: block; color: var(--muted); font-size: 0.9rem; }
.errorlist { color: #a40000; padding-left: 1.2rem; }

button, .button, .btn {
  display: inline-block;
  padding: 0.5rem 1rem;
  font: inherit;
  color: #fff;
  background: var(--accent);
  border: 0;
  border-radius: 4px;
  text-decoration: none;
  cursor: pointer;
}
button:disabled, .btn[disabled] { visibility: hidden; }
.btn-secondary, .btn-link { color: var(--accent); background: none; border: 1px solid var(--accent); }
button.link { padding: 0; background: none; text-decoration: underline; }
.float-right { float: right; }

.messages { list-style: none; padding: 0 16px; max-width: 60rem; margin: 1rem auto 0; }
.messages li { padding: 0.5rem 1rem; background: var(--panel); border-left: 4px solid var(--accent); }

.codes { columns: 2; font-size: 1.1rem; }

.inline-form { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; }
.inline-form input { width: auto; }
.table-scroll { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; }
th, td { padding: 0.4rem 0.6rem; border-bottom: 1px solid var(--line); text-align: left; }
.num { text-align: right; font-variant-numeric: tabular-nums; }
tbody.combinations th { background: var(--panel); }

.tiles { list-style: none; padding: 0; display: grid; gap: 0.75rem;
  grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr)); }
.tiles a { display: block; padding: 1rem; border: 1px solid var(--line); border-radius: 6px;
  text-decoration: none; color: var(--ink); background: var(--panel); height: 100%; }
.tiles strong { display: block; color: var(--accent); }
.tile-static { padding: 1rem; border: 1px solid var(--line); border-radius: 6px; background: var(--panel); height: 100%; }
.count { display: block; font-weight: 600; }
.count.urgent { color: #a40000; }

.attention { list-style: none; padding: 0; }
.attention li { display: flex; gap: 1rem; padding: 0.6rem 0.75rem; border-left: 4px solid var(--line);
  margin-bottom: 0.4rem; background: var(--panel); }
.attention li.urgent { border-left-color: #b00020; }
.attention .when { flex: 0 0 7.5rem; font-variant-numeric: tabular-nums; }
.attention .what { flex: 1; }
@media (max-width: 30rem) { .attention li { flex-direction: column; gap: 0.2rem; } }

/* --- calendar --- */
.cal-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 0.5rem; }
.cal-nav { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.filters { display: flex; flex-wrap: wrap; gap: 0.5rem 1rem; align-items: end; margin: 0.75rem 0; }
.filters label { font-weight: 400; margin: 0; }
.filters select { width: auto; max-width: 14rem; padding: 0.3rem; font: inherit; }
.filters .check { display: flex; gap: 0.3rem; align-items: center; }
table.week, table.month { table-layout: fixed; min-width: 56rem; }
table.week th, table.week td, table.month td { vertical-align: top; border: 1px solid var(--line); padding: 0.3rem; }
table.week thead th, table.month thead th { background: #1f3a5f; color: #fff; text-align: center; }
.room-col { width: 9rem; background: var(--panel); }
td.past, section.past { background: #f1f1f1; }
td.today, section.today, th.today { background: #fff8e1; }
table.week thead th.today { background: #fff8e1; color: var(--ink); }
td.other { opacity: 0.55; }
.entries { list-style: none; margin: 0; padding: 0; font-size: 0.82rem; line-height: 1.3; }
.entry { margin-bottom: 0.35rem; }
.entry .t { font-variant-numeric: tabular-nums; color: var(--muted); }
.entry.one-off a, .entry.one-off .n { font-style: italic; }
.entry.clash, .entry.possible { color: #b00020; }
.entry.clash a { color: #b00020; font-weight: 700; }
.entry.cancelled { text-decoration: line-through; opacity: 0.6; }
.entry.block-out { color: #7a4e00; font-style: italic; }
.entry .dot { color: #b07a00; }
.entry .activity { display: block; color: var(--muted); font-size: 0.75rem; }
.tag { font-size: 0.7rem; padding: 0 0.3rem; border-radius: 3px; background: var(--panel); border: 1px solid var(--line); }
.tag.bad { border-color: #b00020; color: #b00020; }
.tag.changed { font-style: italic; }
.chip { display: inline-block; font-size: 0.7rem; font-weight: 700; color: #fff; background: var(--chip);
  border-radius: 3px; padding: 0 0.25rem; margin-right: 0.15rem; }
.daynum { font-weight: 700; text-decoration: none; }
.week-list { display: none; }
.week-list section { border: 1px solid var(--line); border-radius: 6px; padding: 0.5rem 0.75rem; margin-bottom: 0.5rem; }
.week-list h2 { margin: 0 0 0.4rem; font-size: 1rem; }
@media (max-width: 48rem) {
  .week-table { display: none; }
  .week-list { display: block; }
  .entries { font-size: 0.95rem; }
}

@media print {
  .site-header, form, button { display: none; }
}
