/* Haus Aigina: helle Farben aus Meer, Sand und Stein. Keine externen Schriften (Datenschutz). */
:root {
  --sea: #0e5a6f;
  --sea-deep: #083a4a;
  --turquoise: #2bb3b1;
  --sky: #d7eef2;
  --sand: #f6f1e7;
  --stone: #e7dfd0;
  --paper: #fffdf8;
  --ink: #1f2a30;
  --muted: #5d6b72;
  --terracotta: #c2573a;
  --olive: #6b7a3a;
  --confirmed: #0e5a6f;
  --reserved: #5fb0bc;
  --requested: #c2573a;
  --sun: #e0a526;
  --radius: 10px;
  --shadow: 0 1px 2px rgba(8, 58, 74, .06), 0 6px 20px rgba(8, 58, 74, .06);
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--sand); color: var(--ink); font: 17px/1.55 var(--sans); }
img, video { max-width: 100%; }
a { color: var(--sea); text-underline-offset: 2px; }
a:hover { color: var(--sea-deep); }
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.2; color: var(--sea-deep); margin: 1.2em 0 .5em; }
h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); margin-top: .4em; }
h2 { font-size: 1.45rem; }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; }
small, .muted { color: var(--muted); }
.container { max-width: 1080px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 640px; }

/* Kopfzeile */
.site-header { background: var(--paper); border-bottom: 1px solid var(--stone); }
.site-header .container { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; min-height: 60px; }
.brand { font-family: var(--serif); font-size: 1.25rem; font-weight: 600; color: var(--sea-deep); text-decoration: none; margin-right: auto; }
.brand span { color: var(--turquoise); }
.nav { display: flex; gap: 4px 14px; flex-wrap: wrap; align-items: center; }
.nav a, .nav button { color: var(--ink); text-decoration: none; font-size: .95rem; background: none; border: 0; padding: 4px 0; cursor: pointer; font-family: inherit; }
.nav a:hover, .nav button:hover { color: var(--sea); }
.nav a.active { color: var(--sea); font-weight: 600; }
.lang { display: flex; gap: 6px; font-size: .85rem; }
.lang a { color: var(--muted); text-decoration: none; text-transform: uppercase; }
.lang a.current { color: var(--sea-deep); font-weight: 700; }
.nav form { display: inline; margin: 0; }

main { padding: 24px 0 48px; min-height: 60vh; }
.site-footer { border-top: 1px solid var(--stone); padding: 20px 0 32px; font-size: .9rem; color: var(--muted); }
.site-footer a { color: var(--muted); margin-right: 14px; }

/* Hinweise */
.flash { border-radius: var(--radius); padding: 10px 14px; margin: 0 0 18px; }
.flash.notice { background: #e3f3ef; border: 1px solid #b9e0d6; }
.flash.alert { background: #fbe9e4; border: 1px solid #f0c2b5; }
.errors { background: #fbe9e4; border: 1px solid #f0c2b5; border-radius: var(--radius); padding: 10px 14px 4px; margin-bottom: 16px; }
.errors ul { margin: 4px 0 8px 18px; padding: 0; }

/* Karten und Raster */
.card { background: var(--paper); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; margin-bottom: 20px; }
.card > h2:first-child, .card > h3:first-child { margin-top: 0; }
.grid { display: grid; gap: 20px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.stack > * + * { margin-top: 12px; }
.row { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.spread { display: flex; gap: 12px; flex-wrap: wrap; align-items: baseline; justify-content: space-between; }

/* Formulare */
label { display: block; font-weight: 600; margin-bottom: 4px; }
.field { margin-bottom: 16px; }
.hint { font-size: .88rem; color: var(--muted); margin-top: 4px; }
input[type=text], input[type=email], input[type=tel], input[type=date], input[type=number], select, textarea {
  width: 100%; font: inherit; color: inherit; background: #fff; border: 1px solid #cfc5b3; border-radius: 8px; padding: 10px 12px;
}
input:focus, select:focus, textarea:focus { outline: 2px solid var(--turquoise); outline-offset: 1px; border-color: var(--turquoise); }
textarea { min-height: 120px; }
textarea.markdown { min-height: 420px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .92rem; }
input.code { font-size: 1.8rem; letter-spacing: .35em; text-align: center; max-width: 260px; }
.choice { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; background: #fff; border: 1px solid #cfc5b3; border-radius: 8px; padding: 10px 12px; margin-bottom: 8px; cursor: pointer; }
.choice input { margin-top: 5px; }
.guests { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.dates { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }

.btn, button.btn, input[type=submit] {
  display: inline-block; font: inherit; font-weight: 600; text-decoration: none; cursor: pointer;
  background: var(--sea); color: #fff; border: 0; border-radius: 999px; padding: 10px 20px;
}
.btn:hover, input[type=submit]:hover { background: var(--sea-deep); color: #fff; }
.btn.secondary { background: transparent; color: var(--sea); border: 1.5px solid var(--sea); }
.btn.secondary:hover { background: var(--sky); color: var(--sea-deep); }
.btn.warn { background: var(--terracotta); }
.btn.small { padding: 6px 14px; font-size: .9rem; }
.btn.light { background: rgba(255,255,255,.92); color: var(--sea-deep); }
.button_to { display: inline; }

/* Status */
.badge { display: inline-block; font-size: .78rem; font-weight: 700; letter-spacing: .02em; border-radius: 999px; padding: 2px 10px; white-space: nowrap; }
.badge.confirmed { background: var(--confirmed); color: #fff; }
.badge.reserved { background: var(--reserved); color: #fff; }
.badge.requested { background: #fff; color: var(--requested); border: 1.5px solid var(--requested); }
.badge.declined, .badge.cancelled { background: var(--stone); color: var(--muted); }

/* Tabellen */
table.list { width: 100%; border-collapse: collapse; }
table.list th, table.list td { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--stone); vertical-align: top; }
table.list th { font-size: .85rem; color: var(--muted); font-weight: 600; }
table.list tr.mine td { background: #fff6df; }
table.list tr.mine td:first-child { box-shadow: inset 4px 0 0 var(--sun); }
.badge.mine { background: var(--sun); color: var(--sea-deep); margin-left: 4px; }
.ask { display: flex; flex-wrap: wrap; gap: 2px 12px; margin-top: 2px; font-size: .85rem; }
.button_to.inline { display: inline; margin: 0; }
button.linkish { background: none; border: 0; padding: 0; color: var(--sea); text-decoration: underline; text-underline-offset: 2px; font: inherit; cursor: pointer; }
button.linkish:hover { color: var(--sea-deep); }
.table-wrap { overflow-x: auto; }

/* Startseite mit Film */
.hero { position: relative; min-height: 88vh; display: grid; place-items: center; overflow: hidden; color: #fff; text-align: center; background: var(--sea-deep) center/cover no-repeat; }
.hero video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(8,58,74,.25) 0%, rgba(8,58,74,.15) 45%, rgba(8,58,74,.6) 100%); }
.hero-inner { position: relative; z-index: 1; padding: 0 16px; max-width: 760px; }
.hero h1 { color: #fff; font-size: clamp(2.2rem, 7vw, 4.2rem); margin: 0 0 .25em; text-shadow: 0 2px 18px rgba(0,0,0,.25); }
.hero p { font-size: clamp(1.05rem, 2.4vw, 1.3rem); text-shadow: 0 1px 10px rgba(0,0,0,.35); }
.hero .lang a { color: rgba(255,255,255,.8); }
.hero .lang a.current { color: #fff; }
.hero-top { position: absolute; top: 0; left: 0; right: 0; z-index: 2; display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; }
.hero-top .brand { color: #fff; }
.hero-top .brand span { color: #bdeff0; }
.scroll-hint { display: inline-block; margin-top: 18px; color: #fff; text-decoration: none; font-size: .95rem; opacity: .9; }
.story { background: var(--paper); }
.story .container { padding-top: 48px; padding-bottom: 48px; }
.story-grid { display: grid; gap: 32px; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); align-items: center; }
.story img { border-radius: var(--radius); box-shadow: var(--shadow); display: block; }
.facts { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); margin: 24px 0 8px; }
.fact { border-left: 3px solid var(--turquoise); padding-left: 12px; }
.fact strong { display: block; font-family: var(--serif); font-size: 1.6rem; color: var(--sea-deep); }
.invite-box { text-align: center; padding: 48px 16px; }
@media (prefers-reduced-motion: reduce) { .hero video { display: none; } }

/* Kalender */
.legend { display: flex; flex-wrap: wrap; gap: 8px 16px; font-size: .88rem; color: var(--muted); margin: 8px 0 16px; }
.legend span::before { content: ""; display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.legend .l-confirmed::before { background: var(--confirmed); }
.legend .l-reserved::before { background: var(--reserved); }
.legend .l-requested::before { background: repeating-linear-gradient(135deg, #fff 0 3px, #f2c9bc 3px 6px); border: 1px solid var(--requested); }
.legend .l-note::before { background: #fff; border-bottom: 3px solid var(--olive); }
.legend .l-mine::before { background: #fff; box-shadow: inset 0 0 0 2px var(--sun); }
.months { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(232px, 1fr)); }
.month { background: var(--paper); border-radius: var(--radius); box-shadow: var(--shadow); padding: 12px; }
.month h3 { margin: 0 0 6px; font-size: 1rem; }
.month table { width: 100%; border-collapse: separate; border-spacing: 2px; table-layout: fixed; }
.month th { font-size: .7rem; color: var(--muted); font-weight: 600; }
.month td { height: 28px; text-align: center; font-size: .8rem; border-radius: 4px; padding: 0; }
.month td a { display: block; line-height: 28px; color: inherit; text-decoration: none; border-radius: 4px; }
.month td a:hover { outline: 2px solid var(--turquoise); }
.month td.free { background: #fff; }
.month td.confirmed { background: var(--confirmed); color: #fff; }
.month td.reserved { background: var(--reserved); color: #fff; }
.month td.requested { background: repeating-linear-gradient(135deg, #fff 0 3px, #f2c9bc 3px 6px); }
.month td.note { box-shadow: inset 0 -3px 0 var(--olive); }
/* Eigene Aufenthalte: goldener Rahmen, mit Ferienlinie kombinierbar */
.month td.mine { box-shadow: inset 0 0 0 2px var(--sun); }
.month td.mine.note { box-shadow: inset 0 0 0 2px var(--sun), inset 0 -5px 0 var(--olive); }
.month td.today { font-weight: 800; text-decoration: underline; }
.month td.past { opacity: .55; }
.year-nav { display: flex; gap: 12px; align-items: center; }

/* Infoseiten */
.prose { max-width: 760px; }
.prose h1 { margin-top: 0; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin-bottom: .3em; }
.prose table { border-collapse: collapse; }
.prose td, .prose th { border-bottom: 1px solid var(--stone); padding: 6px 10px 6px 0; text-align: left; }
.prose blockquote { margin: 0 0 1em; padding: 6px 14px; border-left: 3px solid var(--turquoise); background: #fff; }
.machine-note { font-size: .88rem; color: var(--muted); background: #fff; border: 1px dashed var(--stone); border-radius: 8px; padding: 6px 10px; }

/* Nachrichten */
.messages { list-style: none; padding: 0; margin: 0 0 16px; }
.messages li { background: #fff; border-radius: 8px; padding: 10px 12px; margin-bottom: 8px; border: 1px solid var(--stone); }
.messages .meta { font-size: .82rem; color: var(--muted); margin-bottom: 2px; }

@media (max-width: 560px) {
  body { font-size: 16px; }
  .card { padding: 16px; }
  .site-header .container { padding-top: 8px; padding-bottom: 8px; }
}

/* Fotos auf Infoseiten */
.prose img { display: block; max-width: 100%; height: auto; border-radius: var(--radius); margin: 8px 0 16px; }
.photo-grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); margin: 16px 0; }
.photo-grid img { width: 100%; height: 180px; object-fit: cover; border-radius: 8px; display: block; margin: 0; }
.photo-grid figure { margin: 0; background: #fff; border: 1px solid var(--stone); border-radius: 10px; padding: 8px; }
.photo-grid figcaption { font-size: .78rem; margin: 6px 0; word-break: break-all; }

/* Startseite nur mit Film */
.hero-full { min-height: 100vh; min-height: 100svh; }
.btn.ghost { background: transparent; color: #fff; border: 1.5px solid rgba(255,255,255,.85); }
.btn.ghost:hover { background: rgba(255,255,255,.15); color: #fff; }
.hero-bottom { position: absolute; bottom: 14px; left: 0; right: 0; z-index: 2; text-align: center; font-size: .85rem; color: rgba(255,255,255,.85); }
.hero-bottom a { color: rgba(255,255,255,.85); text-decoration: none; }
.hero-bottom a:hover { color: #fff; text-decoration: underline; }

/* Startseite der Mitglieder: Foto des Tages mit Gruß */
.welcome { position: relative; margin: 0 0 24px; min-height: clamp(220px, 32vw, 360px); display: flex; align-items: flex-end; border-radius: var(--radius); overflow: hidden; background: var(--sea-deep); box-shadow: var(--shadow); color: #fff; }
.welcome img { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; object-fit: cover; }
.welcome::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(8,58,74,0) 40%, rgba(8,58,74,.55) 100%); }
.welcome-text { position: relative; z-index: 1; padding: 18px 22px; }
.welcome h1 { color: #fff; margin: 0; font-size: clamp(1.9rem, 5vw, 3rem); text-shadow: 0 2px 14px rgba(0,0,0,.3); }
.welcome p { margin: 4px 0 0; font-size: 1.1rem; text-shadow: 0 1px 8px rgba(0,0,0,.35); }
.welcome p a { color: #fff; text-decoration: none; }
.welcome p a:hover { text-decoration: underline; }
.welcome figcaption { position: absolute; top: 10px; right: 12px; z-index: 1; font-size: .78rem; color: rgba(255,255,255,.9); text-shadow: 0 1px 6px rgba(0,0,0,.5); }

/* Ergänzung vorschlagen und Vorschläge in der Redaktion */
.suggest { margin-top: 32px; }
.suggest textarea { width: 100%; }
.suggestion { border-top: 1px solid var(--stone); padding: 12px 0; }
.suggestion:first-of-type { border-top: 0; }
.suggestion blockquote { margin: 6px 0 10px; padding: 8px 14px; border-left: 3px solid var(--turquoise); background: var(--sand); }
.suggestion blockquote p { margin: 0 0 .4em; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Aufgaben der Eigentümer */
ul.tasks { list-style: none; padding: 0; margin: 0; }
ul.tasks li { display: flex; gap: 12px; align-items: flex-start; padding: 10px 0; border-top: 1px solid var(--stone); }
ul.tasks li:first-child { border-top: 0; }
ul.tasks li > div { flex: 1; min-width: 0; }
ul.tasks small { display: block; margin-top: 2px; }
ul.tasks .task-notes { margin-top: 4px; font-size: .95rem; }
ul.tasks .task-notes p { margin: 0 0 .3em; }
ul.tasks button.check { width: 32px; height: 32px; border-radius: 50%; border: 2px solid var(--sea); background: #fff; color: var(--sea); font-weight: 700; cursor: pointer; padding: 0; line-height: 1; }
ul.tasks button.check:hover { background: var(--sea); color: #fff; }
ul.tasks li.overdue strong { color: var(--terracotta); }
ul.tasks.done span { color: var(--muted); text-decoration: line-through; }

/* Hausbuch */
table.ledger td.num, table.ledger th.num { text-align: right; white-space: nowrap; }
.minus { color: var(--terracotta); }
.plus { color: var(--olive); }
table.ledger tr.total td { border-top: 2px solid var(--stone); }
form.filters { gap: 16px; }
form.filters label { display: flex; gap: 6px; align-items: center; font-size: .95rem; }
form.filters select, form.filters input { width: auto; }

/* Kostenbeitrag */
.contribution-total strong { font-size: 1.5rem; color: var(--sea-deep); margin-right: 8px; }
ul.contribution-lines { margin: 4px 0 12px; padding-left: 1.2em; color: var(--muted); }
dl.payment, dl.handover { display: grid; grid-template-columns: max-content 1fr; gap: 6px 16px; margin: 8px 0 12px; }
dl.payment dt, dl.handover dt { color: var(--muted); }
dl.handover dd p { margin: 0 0 .4em; }
dl.payment dd { margin: 0; }
p.paid { color: var(--olive); font-weight: 600; }
details.owner-tools { margin-top: 16px; border-top: 1px solid var(--stone); padding-top: 12px; }
details.owner-tools summary { cursor: pointer; color: var(--sea); }
figure.girocode { margin: 8px 0 12px; display: inline-block; text-align: center; }
figure.girocode svg { width: 180px; height: 180px; background: #fff; padding: 8px; border-radius: 8px; }
figure.girocode figcaption { font-size: .85rem; color: var(--muted); margin-top: 4px; }
.settlement p.proposal { font-size: 1.15rem; font-weight: 600; color: var(--sea-deep); margin: 12px 0 4px; }
dl.payment dd { min-width: 0; overflow-wrap: anywhere; }
dl.payment code { white-space: normal; word-break: break-all; }
@media (max-width: 480px) { dl.payment { grid-template-columns: 1fr; gap: 2px; } dl.payment dd { margin-bottom: 8px; } }
