:root {
  --paper: #ffffff;
  --paper-raised: #f7f5fc;
  --paper-sunken: #efeafb;
  --ink: #180b60;
  --ink-muted: #6a63a0;
  --line: #e2ddf3;
  --accent: #b09ef6;
  --accent-ink: #180b60;
  --accent-deep: #6a4ee0;
  --warm: #ed8279;
  --warm-ink: #5c1f16;
  --ok-fill: #a5e3b7;
  --ok-ink: #0c5a30;
  --full-fill: #f6d9d5;
  --full-ink: #9c2c1c;
  --danger: #9c2c1c;
  --shadow: 0 1px 2px rgba(24,11,96,0.06), 0 8px 24px rgba(24,11,96,0.07);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #180b60;
    --paper-raised: #221374;
    --paper-sunken: #140a52;
    --ink: #ffffff;
    --ink-muted: #bcb2f0;
    --line: #3a2c94;
    --accent: #c3b4ff;
    --accent-ink: #180b60;
    --accent-deep: #d7cbff;
    --warm: #f2a49a;
    --warm-ink: #3a0f09;
    --ok-fill: #163f28;
    --ok-ink: #a5e3b7;
    --full-fill: #4a1712;
    --full-ink: #f2a49a;
    --danger: #f2a49a;
    --shadow: 0 1px 2px rgba(0,0,0,0.25), 0 10px 28px rgba(0,0,0,0.35);
  }
}
:root[data-theme="dark"] {
  --paper: #180b60;
  --paper-raised: #221374;
  --paper-sunken: #140a52;
  --ink: #ffffff;
  --ink-muted: #bcb2f0;
  --line: #3a2c94;
  --accent: #c3b4ff;
  --accent-ink: #180b60;
  --accent-deep: #d7cbff;
  --warm: #f2a49a;
  --warm-ink: #3a0f09;
  --ok-fill: #163f28;
  --ok-ink: #a5e3b7;
  --full-fill: #4a1712;
  --full-ink: #f2a49a;
  --danger: #f2a49a;
  --shadow: 0 1px 2px rgba(0,0,0,0.25), 0 10px 28px rgba(0,0,0,0.35);
}

/* De navy identiteitsband is een vast merkelement, kleurt niet mee met het thema. */
:root { --brand-navy: #180b60; }

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: 'Early Sans Variable', 'Work Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
}

h1, h2, h3 {
  font-family: 'Bricolage Grotesque', 'Arial Black', sans-serif;
  font-weight: 800;
  letter-spacing: -0.01em;
  margin: 0;
}

a { color: inherit; }

/* --- identity strip --- */

.topbar { background: var(--brand-navy); }

.topbar-inner {
  max-width: 900px;
  margin: 0 auto;
  padding: 1.1rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
}

.brand img { height: 30px; display: block; }
.brand .divider { width: 1px; height: 18px; background: rgba(255,255,255,0.25); }
.brand .product { font-size: 0.95rem; font-weight: 600; color: #ffffff; }

.topbar nav {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
}

.topbar .who {
  color: rgba(255,255,255,0.7);
  font-size: 0.85rem;
  margin-right: 0.4rem;
}

.topbar nav a {
  color: rgba(255,255,255,0.75);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.85rem;
  padding: 0.5rem 1rem;
  border-radius: 999px;
}

.topbar nav a.active {
  background: #ffffff;
  color: var(--brand-navy);
}

.topbar nav a:hover:not(.active) { color: #ffffff; }

/* --- hamburger (mobiel) --- */

.nav-toggle {
  display: none;
  flex: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  border: none;
  background: transparent;
  padding: 0;
  border-radius: 8px;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: #ffffff;
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.nav-toggle:focus-visible { outline: 2px solid #ffffff; outline-offset: 3px; }
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 640px) {
  .nav-toggle { display: inline-flex; }

  .topbar-inner { position: relative; }

  .topbar nav {
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0.15rem;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--brand-navy);
    padding: 0.4rem 1.25rem 1.1rem;
    box-shadow: var(--shadow);
    z-index: 20;
  }
  .topbar nav.open { display: flex; }

  .topbar .who { margin: 0.4rem 0 0.3rem; padding: 0 0.5rem; }

  .topbar nav a {
    padding: 0.75rem 0.6rem;
    border-radius: 8px;
  }
  .topbar nav a.active { background: rgba(255,255,255,0.14); color: #ffffff; }
}

/* --- content shell --- */

main { max-width: 900px; margin: 0 auto; padding: 2rem 1.25rem 4rem; }

.eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent-deep);
  background: var(--paper-sunken);
  padding: 0.3rem 0.7rem;
  border-radius: 999px;
  margin-bottom: 0.9rem;
}

.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.75rem; }
.page-head h1 { font-size: clamp(1.6rem, 4vw, 2.15rem); }
.page-head p { margin: 0.4rem 0 0; color: var(--ink-muted); max-width: 46ch; }

.section-title { font-size: 1.05rem; margin: 2.2rem 0 0.9rem; }
.section-title:first-of-type { margin-top: 0; }

/* --- view toggle (lijst / maandoverzicht) --- */

.view-toggle {
  display: inline-flex;
  background: var(--paper-sunken);
  border-radius: 999px;
  padding: 0.25rem;
  gap: 0.15rem;
  flex: none;
}

.view-toggle a {
  font: inherit;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--ink-muted);
  text-decoration: none;
  padding: 0.5rem 1rem;
  border-radius: 999px;
}

.view-toggle a.active { background: var(--paper); color: var(--ink); box-shadow: var(--shadow); }

/* --- maandoverzicht (kalender) --- */

.cal-wrap { background: var(--paper-raised); border: 1px solid var(--line); border-radius: 16px; padding: 1.4rem 1.5rem; }

.cal-head {
  display: flex; align-items: center; justify-content: center; gap: 1.25rem;
  margin-bottom: 1.1rem;
}
.cal-head h2 { font-size: 1.15rem; min-width: 11ch; text-align: center; }

.cal-nav {
  display: inline-flex; align-items: center; justify-content: center;
  width: 32px; height: 32px; border-radius: 999px;
  background: var(--paper-sunken); color: var(--ink);
  text-decoration: none; font-weight: 600;
}
.cal-nav.disabled { opacity: 0.35; pointer-events: none; }

.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

.cal-weekday {
  text-align: center; font-size: 0.72rem; font-weight: 600; text-transform: uppercase;
  letter-spacing: 0.04em; color: var(--ink-muted); padding-bottom: 0.4rem;
}

.cal-day {
  min-height: 64px;
  border-radius: 10px;
  padding: 0.4rem;
  background: var(--paper);
  border: 1px solid var(--line);
  display: flex; flex-direction: column; gap: 0.3rem;
}
.cal-day.out { background: transparent; border-color: transparent; opacity: 0.4; }
.cal-day.today { border-color: var(--accent-deep); border-width: 2px; }

.cal-day-num { font-size: 0.82rem; font-weight: 600; }

.cal-dots { display: flex; flex-wrap: wrap; gap: 0.25rem; }

.cal-dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--accent); display: inline-block;
}
.cal-dot.warm { background: var(--warm); }

.cal-legend { margin: 1.1rem 0 0; font-size: 0.8rem; color: var(--ink-muted); display: flex; align-items: center; gap: 0.4rem; }
.cal-legend .cal-dot { vertical-align: middle; }

@media (max-width: 640px) {
  .cal-day { min-height: 46px; padding: 0.3rem; }
  .cal-weekday { font-size: 0.62rem; }
}

/* --- login --- */

.login-wrap {
  max-width: 540px;
  margin: 2rem auto 0;
  display: flex;
  flex-direction: column;
  background: var(--paper-raised);
  border: 1px solid var(--line);
  border-radius: 24px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.login-panel {
  background: var(--brand-navy);
  color: #ffffff;
  padding: 2.5rem 2rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 1rem;
  position: relative;
}

.login-panel .swatch {
  position: absolute;
  width: 130px; height: 130px;
  background: var(--warm);
  border-radius: 999px 24px 24px 999px;
  right: -30px; bottom: -30px;
  opacity: 0.9;
}

.login-panel h1 { color: #ffffff; font-size: clamp(1.5rem, 4vw, 1.9rem); position: relative; z-index: 1; }
.login-panel p { color: rgba(255,255,255,0.75); margin: 0; max-width: 32ch; position: relative; z-index: 1; }

.login-form { padding: 2.25rem 2rem; display: flex; flex-direction: column; gap: 1.1rem; }

@media (max-width: 640px) {
  .login-panel { padding: 2rem 1.5rem; }
  .login-form { padding: 2rem 1.5rem 2.25rem; }
}

/* --- forms --- */

label {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--ink-muted);
}

.hint { font-weight: 400; color: var(--ink-muted); }

input[type=text], input[type=email], input[type=date], input[type=time],
input[type=number], input[type=tel], textarea, select {
  font: inherit;
  font-size: 0.95rem;
  padding: 0.7rem 0.8rem;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--ink);
  width: 100%;
  box-sizing: border-box;
  line-height: 1.3;
}

textarea { min-height: 4.5rem; resize: vertical; font-family: inherit; }

/* Selects krijgen anders per browser een eigen hoogte/pijltje dat niet bij de
   rest van de velden past. appearance:none + een eigen pijltje (getekend met
   gradients in currentColor, dus geen los plaatje nodig en werkt vanzelf mee
   met het donkere thema) houdt 'm exact even hoog en gestyled als de rest. */
select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  cursor: pointer;
  padding-right: 2.3rem;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--ink-muted) 50%),
    linear-gradient(135deg, var(--ink-muted) 50%, transparent 50%);
  background-position:
    calc(100% - 19px) calc(50% - 2px),
    calc(100% - 14px) calc(50% - 2px);
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}

fieldset { border: 1px solid var(--line); border-radius: 12px; margin: 0; padding: 1rem 1.1rem; }
legend { font-size: 0.82rem; font-weight: 600; color: var(--ink-muted); padding: 0 0.3rem; }

form { display: flex; flex-direction: column; gap: 1.1rem; }

.role-rows { display: flex; flex-direction: column; gap: 0.6rem; }
.role-row { display: flex; flex-direction: row; gap: 0.5rem; align-items: center; flex-wrap: wrap; }
.role-row .role-select, .role-row .role-custom { flex: 1 1 12rem; width: auto; }
.role-row input[type=number] { width: 6.5rem; flex: none; }
.btn-add-row { margin-top: 0.75rem; padding: 0.5rem 0.9rem; font-size: 0.85rem; }

/* --- buttons --- */

button, .button {
  appearance: none;
  border: none;
  font: inherit;
  font-weight: 600;
  font-size: 0.92rem;
  padding: 0.75rem 1.3rem;
  border-radius: 999px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  background: var(--accent);
  color: var(--accent-ink);
  text-decoration: none;
}

button:focus-visible, input:focus-visible, a:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--accent-deep);
  outline-offset: 2px;
}

button.secondary { background: transparent; color: var(--ink); border: 1px solid var(--line); }
button.small { padding: 0.4rem 0.85rem; font-size: 0.8rem; background: var(--ink); color: var(--paper); }
button.link-button { background: none; color: var(--danger); padding: 0; text-decoration: underline; font-size: 0.85rem; font-weight: 500; }

/* --- cards --- */

.card {
  background: var(--paper-raised);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 1.4rem 1.5rem;
  margin-bottom: 1rem;
}

.card.narrow { max-width: 480px; }

.event-card { display: flex; gap: 1.1rem; align-items: flex-start; }

.event-mark {
  flex: none;
  width: 56px; height: 56px;
  border-radius: 999px 16px 16px 999px;
  background: var(--accent);
  display: flex; align-items: center; justify-content: center;
  font-family: 'Bricolage Grotesque', sans-serif;
  font-weight: 800;
  color: var(--accent-ink);
  font-size: 1.1rem;
}
.event-mark.warm { background: var(--warm); color: var(--warm-ink); }

.event-body { flex: 1; min-width: 0; }
.event-body h2 { font-size: 1.1rem; margin-bottom: 0.2rem; }
.meta, .event-meta { color: var(--ink-muted); font-size: 0.85rem; margin: 0 0 0.9rem; }

@media (max-width: 640px) {
  .event-card { flex-direction: column; }
}

.header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.actions { display: flex; gap: 1rem; font-size: 0.85rem; }
.actions a { color: var(--accent-deep); text-decoration: none; font-weight: 600; }

ul.roles { list-style: none; padding: 0; margin: 0.75rem 0 0; display: flex; flex-direction: column; gap: 0.55rem; }
ul.roles li {
  display: flex; align-items: center; gap: 0.6rem; flex-wrap: wrap;
  padding-top: 0.55rem; border-top: 1px solid var(--line);
}
ul.roles li:first-child { padding-top: 0; border-top: none; }

.role-name { font-weight: 600; font-size: 0.92rem; }
.role-cap { font-size: 0.8rem; color: var(--ink-muted); margin-right: auto; }

.badge {
  font-size: 0.76rem; font-weight: 600;
  padding: 0.28rem 0.6rem; border-radius: 999px;
  white-space: nowrap;
  background: var(--ok-fill); color: var(--ok-ink);
}
.badge.full { background: var(--full-fill); color: var(--full-ink); }
.badge.neutral { background: var(--paper-sunken); color: var(--ink-muted); }

.available-row {
  margin-top: 1rem; padding-top: 1rem; border-top: 1px dashed var(--line);
  display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; flex-wrap: wrap;
}
.available-row p { margin: 0; font-size: 0.85rem; color: var(--ink-muted); max-width: 34ch; }
.available-row form { flex-direction: row; }

ul.my-signups { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.6rem; }
ul.my-signups li {
  display: flex; justify-content: space-between; align-items: center; gap: 0.75rem; flex-wrap: wrap;
  background: var(--paper-raised); border: 1px solid var(--line); border-radius: 12px; padding: 0.9rem 1.1rem;
  font-size: 0.9rem;
}
ul.my-signups li form { display: inline-flex; }
ul.my-signups .who { color: var(--ink-muted); }

/* --- coordinator --- */

.summary-row { display: flex; gap: 0.9rem; flex-wrap: wrap; margin-bottom: 1.6rem; }
.summary-tile {
  flex: 1; min-width: 140px;
  background: var(--paper-raised); border: 1px solid var(--line); border-radius: 14px;
  padding: 0.9rem 1.1rem;
}
.summary-tile .num { font-family: 'Bricolage Grotesque', sans-serif; font-weight: 800; font-size: 1.6rem; font-variant-numeric: tabular-nums; }
.summary-tile .label { font-size: 0.78rem; color: var(--ink-muted); }

.coord-event { border: 1px solid var(--line); border-radius: 16px; overflow: hidden; background: var(--paper-raised); margin-bottom: 1rem; }
.coord-head {
  background: var(--brand-navy); color: #ffffff;
  padding: 1rem 1.4rem;
  display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap;
}
.coord-head h2 { font-size: 1rem; color: #ffffff; margin: 0; }
.coord-head .meta { color: rgba(255,255,255,0.7); font-size: 0.82rem; margin: 0; }
.coord-head .actions a { color: rgba(255,255,255,0.85); }

.assign-body { padding: 1rem 1.4rem 1.2rem; display: flex; flex-direction: column; gap: 1.2rem; }
.assign-role-head {
  display: flex; justify-content: space-between; align-items: baseline; gap: 0.75rem; flex-wrap: wrap;
  margin-bottom: 0.5rem;
}
.assign-role-head strong { font-size: 0.92rem; }
.assign-count { font-size: 0.78rem; color: var(--ink-muted); }
.assign-empty { margin: 0; font-size: 0.85rem; color: var(--ink-muted); }

ul.assign-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.5rem; }
ul.assign-list li {
  display: flex; justify-content: space-between; align-items: center; gap: 0.75rem; flex-wrap: wrap;
  background: var(--paper-sunken); border-radius: 10px; padding: 0.6rem 0.85rem; font-size: 0.88rem;
}
ul.assign-list li form { display: inline-flex; }
ul.assign-list .who { color: var(--ink-muted); font-size: 0.82rem; margin-left: 0.5rem; }
ul.assign-list .history {
  color: var(--ink-muted); font-size: 0.78rem; margin-left: 0.5rem;
  padding: 0.1rem 0.5rem; border-radius: 999px; background: var(--paper-raised);
  white-space: nowrap;
}
.assign-actions { display: flex; align-items: center; gap: 0.6rem; flex-wrap: wrap; }

.assign-buttons { display: flex; flex-wrap: wrap; gap: 0.4rem; }

.section-header {
  display: flex; justify-content: space-between; align-items: flex-end;
  gap: 1rem; flex-wrap: wrap; margin-bottom: 1rem;
}
.month-filter { flex-direction: row; align-items: center; gap: 0.6rem; }
.month-filter label { flex-direction: row; align-items: center; gap: 0.5rem; }
.month-filter select { width: auto; min-width: 11rem; }

table.contact-table { width: 100%; border-collapse: collapse; font-size: 0.88rem; }
table.contact-table th {
  text-align: left; font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.05em;
  color: var(--ink-muted); font-weight: 600; padding: 0.9rem 1.4rem 0.5rem;
}
table.contact-table td { padding: 0.7rem 1.4rem; border-top: 1px solid var(--line); vertical-align: middle; }
table.contact-table tr:last-child td { padding-bottom: 1rem; }

@media (max-width: 640px) {
  table.contact-table { display: block; overflow-x: auto; }
}

.experience-form { flex-direction: row; align-items: center; gap: 0.5rem; flex-wrap: wrap; }
.experience-form input[type="number"] { width: 4.5rem; }
.experience-form input[type="text"] { width: 16rem; }

/* --- flash / dev box --- */

.flash {
  max-width: 900px;
  margin: 1.25rem auto 0;
  padding: 0 1.25rem;
}
.flash p {
  background: var(--paper-sunken);
  border: 1px solid var(--line);
  color: var(--ink);
  border-radius: 10px;
  padding: 0.7rem 1rem;
  margin: 0 0 0.5rem;
  font-size: 0.88rem;
}

.dev-box {
  margin-top: 1rem;
  background: var(--paper-sunken);
  border: 1px dashed var(--accent-deep);
  border-radius: 12px;
  padding: 0.9rem 1.1rem;
  font-size: 0.85rem;
  word-break: break-all;
}

@media (max-width: 480px) {
  main { padding: 1.25rem 1rem 3rem; }
  .card { padding: 1.1rem 1.2rem; }
}

/* --- aanmeldvenster: uitleg en maandknoppen (30 september 2026) --- */

.window-info { display: flex; flex-direction: column; gap: 0.2rem; }
.window-info span { color: var(--ink-muted); }

.month-chips {
  display: flex;
  gap: 0.4rem;
  overflow-x: auto;
  padding: 0.2rem 0 0.6rem;
  margin: 0.5rem 0 0.5rem;
  -webkit-overflow-scrolling: touch;
}
.month-chip {
  flex: none;
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  color: var(--ink);
  background: var(--paper-sunken);
  border-radius: 999px;
  padding: 0.45rem 0.9rem;
  white-space: nowrap;
}
.month-chip.locked { color: var(--ink-muted); }
.month-chip.active { background: var(--accent); color: var(--accent-ink); }
.window-note { color: var(--ink-muted); margin: 0 0 1rem; }

.window-card-actions { display: flex; flex-direction: column; align-items: flex-end; gap: 0.3rem; }
.window-card-actions .hint { font-size: 0.8rem; color: var(--ink-muted); }
.window-card-actions button { background: transparent; color: var(--ink); border: 1px solid var(--line); box-shadow: none; }

/* Teamleider van een dienst (30 september 2026): koraal, valt op naast "Bevestigd". */
.badge.lead { background: #ed8279; color: #180b60; }

/* Na aanmelden landt de vrijwilliger via #event-<id> weer bij het evenement.
   Kleine marge boven, zodat de kaart niet tegen de rand plakt, en een korte
   oplichting zodat op mobiel duidelijk is waar je bent. */
.event-card { scroll-margin-top: 1rem; }
.event-card:target { animation: event-target-flash 1.6s ease-out; }
@keyframes event-target-flash {
  0%   { box-shadow: 0 0 0 3px rgba(106, 78, 224, 0.5); }
  100% { box-shadow: 0 0 0 3px rgba(106, 78, 224, 0); }
}
@media (prefers-reduced-motion: reduce) {
  .event-card:target { animation: none; }
}

/* --- Update november 2026: afronden, handmatig toevoegen, overzicht --- */
.signup-deadline { display: block; margin-top: 0.25rem; font-size: 0.8rem; color: var(--ink-muted); }
.small-link { font-size: 0.85rem; font-weight: 600; color: var(--accent-deep); }

.manual-add { margin: 0 1.4rem 1rem; font-size: 0.88rem; }
.manual-add summary { cursor: pointer; color: var(--accent-deep); font-weight: 600; }
.manual-add-form { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; margin-top: 0.6rem; }
.manual-add-form select { width: auto; min-width: 10rem; flex: 1 1 10rem; margin: 0; }
.manual-add .hint { margin: 0.4rem 0 0; font-size: 0.8rem; }

.finalize-box {
  margin: 0 1.4rem 1.3rem; padding: 0.9rem 1rem; border-radius: 12px;
  border: 1px dashed var(--line); background: var(--paper-sunken);
  display: flex; flex-wrap: wrap; gap: 0.8rem; align-items: center; justify-content: space-between;
}
.finalize-box p { margin: 0; font-size: 0.88rem; max-width: 62ch; }
.finalize-box.ready { border-style: solid; border-color: var(--accent); background: var(--paper-raised); }
.finalize-box.done { border-style: solid; border-color: transparent; background: var(--ok-fill); color: var(--ok-ink); }

.finalize-box form { flex: 1 1 100%; min-width: 0; }
.call-times { margin: 0 0 0.8rem; }
.call-times .hint { display: inline; }
.call-time-row { display: grid; grid-template-columns: minmax(8rem, 1fr) 10rem 7rem; gap: 0.5rem; align-items: center; padding: 0.3rem 0; font-size: 0.88rem; }
.call-time-row input { margin: 0; width: 100%; }
.call-times-edit { flex: 1 1 100%; font-size: 0.88rem; }
.call-times-edit summary { cursor: pointer; font-weight: 600; }
.call-times-edit form { margin-top: 0.6rem; }
@media (max-width: 560px) {
  .call-time-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .call-time-row > span { grid-column: 1 / -1; font-weight: 600; padding-top: 0.3rem; }
}

.checkbox-line { display: flex; align-items: center; gap: 0.5rem; font-weight: 500; }
.checkbox-line input { width: auto; margin: 0; }
.bulk-result { margin-top: 1rem; font-size: 0.85rem; border-top: 1px solid var(--line); padding-top: 0.8rem; }
.bulk-result p { margin: 0 0 0.5rem; }
.access-form select { margin: 0; width: auto; font-size: 0.85rem; padding-top: 0.3rem; padding-bottom: 0.3rem; }

.grid-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 14px; background: var(--paper-raised); }
.grid-table { border-collapse: collapse; width: 100%; font-size: 0.85rem; min-width: 720px; }
.grid-table th, .grid-table td { border-bottom: 1px solid var(--line); border-right: 1px solid var(--line); padding: 0.55rem 0.7rem; vertical-align: top; text-align: left; }
.grid-table th { background: var(--paper-sunken); font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.04em; color: var(--ink-muted); position: sticky; top: 0; }
.grid-table .grid-event { min-width: 13rem; }
.grid-table .grid-event a { color: inherit; text-decoration: none; }
.grid-table .grid-event .who { display: block; color: var(--ink-muted); font-size: 0.78rem; }
.grid-table tr.is-rond td { background: color-mix(in srgb, var(--ok-fill) 25%, transparent); }
.grid-name { line-height: 1.5; }
.grid-open { color: var(--full-ink); font-weight: 600; font-size: 0.8rem; }
.grid-wait { color: var(--ink-muted); font-size: 0.75rem; }
.grid-none { color: var(--ink-muted); }

@media print {
  .topbar, .no-print, .flash { display: none !important; }
  body { background: #fff; color: #000; }
  .grid-wrap { border: none; overflow: visible; }
  .grid-table { min-width: 0; font-size: 9pt; }
  .grid-table th { position: static; }
}
label.checkbox-line { flex-direction: row; }
.table-scroll { overflow-x: auto; }
.manual-add-form { flex-direction: row; }
.manual-add-form select { flex: 1 1 12rem; }
.person-cell .who { display: block; font-size: 0.82rem; color: var(--ink-muted); margin-top: 0.15rem; }
.experience-form input[type="text"] { width: auto; flex: 1 1 12rem; min-width: 10rem; }
.experience-form input, .experience-form button { margin: 0; }
td.row-actions { min-width: 13rem; }
.row-actions .access-form { gap: 0.4rem; }
.row-links { display: flex; flex-wrap: wrap; gap: 0.2rem 0.9rem; margin-top: 0.45rem; }
.row-links form { display: inline; }
