:root {
  --color-primary: #9ed2ee;
  --color-primary-dark: #5fa8cf;
  --color-text: #18242b;
  --color-text-muted: #66727a;
  --color-background: #ffffff;
  --color-background-soft: #f5f8fa;
  --color-border: #dfe7eb;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--color-text);
  background: var(--color-background-soft);
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
}
* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; line-height: 1.55; }
a { color: inherit; }
button { font: inherit; }
img { display: block; max-width: 100%; }
[hidden] { display: none !important; }
.site-header { background: var(--color-background); border-bottom: 1px solid var(--color-border); }
.header-inner { max-width: 1180px; min-height: 82px; margin: auto; padding: 12px 24px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.brand { display: block; flex-shrink: 0; }
.brand img { width: 180px; height: 60px; object-fit: contain; }
.header-links { display: flex; align-items: center; gap: 24px; font-size: .85rem; font-weight: 650; }
.header-links a { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; text-decoration: none; }
.app-label { color: var(--color-text-muted); border-right: 1px solid var(--color-border); padding-right: 24px; }
main { width: min(100% - 48px, 900px); margin: auto; min-height: 72vh; padding: 48px 0 72px; }
p { margin: 0 0 16px; }
h1 { font-size: clamp(2.4rem, 6vw, 3.8rem); line-height: 1.04; letter-spacing: -.045em; margin: 12px 0 20px; }
h2 { font-size: 1.35rem; line-height: 1.3; letter-spacing: -.025em; margin: 0; }
.eyebrow { color: #35657f; font-size: .75rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; margin: 0 0 12px; }
.intro { position: relative; overflow: hidden; isolation: isolate; border-radius: 24px; padding: 64px 48px; min-height: 520px; display: flex; align-items: center; color: #fff; background: #24343c url('/images/gemeindehaus.jpg') center / cover; }
.intro::before { content: ''; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg,rgba(7,18,24,.91),rgba(7,18,24,.76) 55%,rgba(7,18,24,.4)); }
.intro-content { max-width: 620px; }
.intro .eyebrow, .intro h1 span { color: var(--color-primary); }
.intro h1 { font-size: clamp(2.25rem, 5.3vw, 3.7rem); line-height: 1.07; }
.intro-content > p:not(.eyebrow):not(.hint) { max-width: 44ch; font-size: 1.08rem; color: #ecf2f5; line-height: 1.7; margin-bottom: 28px; }
.intro .hint { color: #d3e1e9; font-size: .8rem; margin: 18px 0 0; }
.primary, .quiet, nav button { display: inline-flex; align-items: center; justify-content: center; gap: 12px; min-height: 48px; border-radius: 999px; padding: 12px 22px; font-size: .95rem; font-weight: 700; line-height: 1.4; border: 1px solid transparent; cursor: pointer; text-decoration: none; }
.primary { background: var(--color-primary); color: var(--color-text); }
.primary:hover { background: var(--color-primary-dark); }
.quiet { background: #fff; color: var(--color-text); border-color: var(--color-border); }
.quiet:hover { background: #edf4f8; border-color: #b8ceda; }
[aria-disabled='true'], button:disabled { opacity: .55; cursor: not-allowed; }
.heading { display: flex; justify-content: space-between; align-items: flex-start; gap: 24px; margin-bottom: 28px; }
.heading h1 { margin-bottom: 16px; }
.heading > .quiet { flex-shrink: 0; margin-top: 25px; font-size: .85rem; }
.workspace-intro { color: var(--color-text-muted); max-width: 50ch; margin: 0; }
.notice { background: #edf5fa; border: 1px solid #d1e5f0; border-radius: 16px; padding: 16px 20px; font-size: .9rem; }
.mode-notice { display: flex; align-items: center; gap: 16px; color: #3b5869; }
.mode-label { display: inline-flex; background: #fff; border: 1px solid #cfe1eb; padding: 5px 12px; border-radius: 999px; font-size: .73rem; font-weight: 750; white-space: nowrap; color: #355d73; }
nav { display: flex; width: fit-content; gap: 4px; margin: 32px 0; padding: 5px; border-radius: 999px; background: #e7edf1; }
nav button { background: transparent; color: #52626d; padding-inline: 24px; }
nav [aria-current] { color: var(--color-text); background: #fff; box-shadow: 0 2px 8px #18242b0c; }
.filters { display: flex; gap: 8px; margin: -12px 0 24px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.filters::-webkit-scrollbar { display: none; }
.filters.sub { margin-top: -12px; }
.chip { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 8px 16px; border-radius: 999px; border: 1px solid var(--color-border); background: #fff; color: var(--color-text); font: inherit; font-size: .88rem; font-weight: 650; cursor: pointer; white-space: nowrap; }
.chip:hover { border-color: #b8ceda; background: #edf4f8; }
.chip small { color: var(--color-text-muted); font-size: .76rem; font-weight: 700; }
.chip[aria-pressed="true"] { background: var(--color-primary); border-color: var(--color-primary); }
.chip[aria-pressed="true"] small { color: var(--color-text); }
.filters.sub .chip { min-height: 40px; font-size: .82rem; }
.empty-state .quiet { margin-top: 12px; }
.list-heading { display: flex; justify-content: space-between; align-items: center; margin: 0 0 24px; gap: 16px; }
.count-badge { color: var(--color-text-muted); font-size: .8rem; white-space: nowrap; }
.event { margin-bottom: 28px; padding: 24px; background: #fff; border: 1px solid var(--color-border); border-radius: 20px; box-shadow: 0 4px 20px #18242b03; }
.event-heading { display: flex; align-items: center; gap: 16px; margin-bottom: 18px; }
.event-heading h3 { font-size: 1.05rem; font-weight: 750; line-height: 1.45; margin: 0; letter-spacing: -.02em; overflow-wrap: anywhere; }
.event-title { min-width: 0; }
.event-time { display: block; color: var(--color-text-muted); font-size: .84rem; margin-top: 2px; }
.event-note { margin: -6px 0 18px; color: var(--color-text-muted); font-size: .86rem; line-height: 1.5; white-space: pre-line; overflow-wrap: anywhere; }
.date-stamp { flex: 0 0 52px; min-height: 58px; display: flex; flex-direction: column; align-items: center; justify-content: center; background: #edf6fb; border-radius: 12px; color: #244d64; line-height: 1.1; gap: 4px; }
.date-stamp strong { font-size: 1.4rem; font-weight: 800; }
.date-stamp small { font-size: .67rem; text-transform: uppercase; letter-spacing: .06em; font-weight: 700; }
.slot { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 18px 0; border-top: 1px solid #edf1f4; }
.slot:last-child { padding-bottom: 0; }
.slot > div { min-width: 0; }
.area-label { display: block; color: var(--color-text-muted); font-size: .74rem; margin-bottom: 4px; }
.slot strong { font-size: 1.12rem; font-weight: 700; overflow-wrap: anywhere; }
.claim-button { flex-shrink: 0; min-width: 110px; }
.assignment-status { flex-shrink: 0; border-radius: 999px; padding: 6px 12px; font-size: .75rem; background: #f5f1e6; color: #6b5927; }
.assignment-status.confirmed { background: #eaf4ee; color: #36614b; }
.refresh-button { margin-top: 4px; font-size: .85rem; }
.empty-state { padding: 28px; border: 1px dashed #cbd9e2; border-radius: 16px; color: var(--color-text-muted); background: #fff; }
details { margin-top: 40px; border-top: 1px solid var(--color-border); padding-top: 16px; font-size: .85rem; color: var(--color-text-muted); }
summary { cursor: pointer; min-height: 44px; display: list-item; padding-block: 10px; font-weight: 650; }
details > p { margin-top: 12px; }
#diagnostics { white-space: pre-wrap; overflow-wrap: anywhere; font-size: .75rem; }
#message:not(:empty) { margin-top: 24px; padding: 16px 20px; border: 1px solid #d1e5f0; border-radius: 16px; background: #edf5fa; color: #355365; font-size: .9rem; }
footer { max-width: 1180px; margin: auto; padding: 32px 24px; border-top: 1px solid var(--color-border); display: flex; justify-content: space-between; align-items: center; gap: 24px; color: var(--color-text-muted); font-size: .78rem; }
footer strong { display: block; color: var(--color-text); font-size: .9rem; margin-bottom: 6px; }
footer a { display: inline-flex; gap: 6px; align-items: center; min-height: 44px; text-decoration: none; font-weight: 700; color: #35657f; }
dialog { width: min(92vw, 500px); border: 1px solid var(--color-border); border-radius: 24px; padding: 32px; color: var(--color-text); box-shadow: 0 24px 80px #07121840; }
dialog::backdrop { background: #071218b3; }
dialog h2 { font-size: 1.7rem; margin-bottom: 20px; }
.actions { display: flex; flex-direction: column-reverse; gap: 10px; margin-top: 24px; }
a:focus-visible, button:focus-visible, summary:focus-visible { outline: 3px solid #276084; outline-offset: 4px; }
.skip { position: absolute; left: -10000px; }
.skip:focus { left: 16px; top: 8px; background: white; padding: 10px; z-index: 30; }
@media (max-width: 600px) {
  .header-inner { min-height: 76px; padding: 10px 20px; }
  .brand img { width: 156px; height: 52px; }
  .header-links { font-size: .8rem; }
  .app-label { display: none; }
  main { width: calc(100% - 32px); padding-top: 32px; padding-bottom: 48px; }
  .intro { padding: 40px 24px; min-height: 500px; background-position: 58% center; }
  .intro::before { background: linear-gradient(0deg,rgba(7,18,24,.96),rgba(7,18,24,.8) 60%,rgba(7,18,24,.5)); }
  .intro h1 { font-size: clamp(2rem,8vw,2.65rem); }
  .intro .primary { width: 100%; }
  .heading { gap: 12px; }
  .heading h1 { font-size: 2.3rem; }
  .heading > .quiet { margin-top: 20px; padding: 10px 14px; font-size: .75rem; min-height: 44px; }
  .workspace-intro { font-size: .9rem; }
  .mode-notice { align-items: flex-start; flex-direction: column; gap: 8px; padding: 14px 16px; font-size: .8rem; }
  nav { width: 100%; margin: 24px 0 28px; }
  nav button { flex: 1; padding-inline: 12px; font-size: .85rem; }
  .event { padding: 18px; border-radius: 18px; }
  .event-heading { gap: 12px; }
  .event-heading h3 { font-size: .95rem; }
  .slot { gap: 10px; }
  .slot strong { font-size: 1rem; }
  .claim-button { min-width: 96px; padding-inline: 16px; font-size: .85rem; }
  footer { padding: 28px 20px; flex-direction: column; align-items: flex-start; gap: 12px; }
  dialog { padding: 24px; }
}
@media (min-width: 601px) { .actions { flex-direction: row; justify-content: flex-end; } }
