/* Adventsfenster - Stylesheet (mobile first) */

:root {
    --bg: #17372d;
    --bg-soft: #24513f;
    --panel: #fffdf8;
    --text: #28332d;
    --text-muted: #687168;
    --line: #e3dac9;
    --accent: #982b36;
    --accent-dark: #741d28;
    --green: #285b43;
    --green-dark: #173d2e;
    --gold: #c9a54a;
    --cream: #f8f1e3;
    --radius: 14px;
    --shadow: 0 8px 28px rgba(42, 49, 43, .09);
    --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }

body {
    font-family: var(--font);
    font-size: 16px;
    line-height: 1.55;
    color: var(--text);
    background: #f5f1e8;
    -webkit-text-size-adjust: 100%;
    overflow-wrap: anywhere;
}

.wrap {
    width: 100%;
    max-width: 940px;
    margin: 0 auto;
    padding: 0 16px;
}

.skip-link {
    position: absolute;
    left: -9999px;
    background: #fff;
    color: var(--text);
    padding: 10px 14px;
    border-radius: 0 0 8px 0;
    z-index: 1000;
}

.skip-link:focus { left: 0; top: 0; }

:focus-visible {
    outline: 3px solid var(--accent);
    outline-offset: 2px;
}

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

.site-header {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #173d2e 0%, #24533f 54%, #7f2430 100%);
    color: #fff;
    padding: 30px 0;
    border-bottom: 4px solid var(--gold);
}

.site-header::before {
    content: "";
    position: absolute;
    inset: 0;
    opacity: .16;
    pointer-events: none;
    background-image:
        radial-gradient(circle at 10% 22%, #fff 0 1px, transparent 2px),
        radial-gradient(circle at 26% 70%, #fff 0 1.5px, transparent 2.5px),
        radial-gradient(circle at 48% 32%, #fff 0 1px, transparent 2px),
        radial-gradient(circle at 72% 68%, #fff 0 1.5px, transparent 2.5px),
        radial-gradient(circle at 88% 20%, #fff 0 1px, transparent 2px);
    background-size: 150px 120px, 190px 160px, 170px 150px, 210px 180px, 180px 140px;
}

.site-header h1 { margin: 0; font-size: clamp(1.9rem, 5vw, 3.35rem); line-height: 1.08; letter-spacing: -.02em; text-wrap: balance; }
.site-header__sub { margin: 4px 0 0; color: #f1e8d6; font-size: .95rem; }
.site-header--hero {
    padding: 72px 0 64px;
    background:
        linear-gradient(180deg, rgba(10, 28, 22, .62) 0%, rgba(14, 38, 30, .48) 45%, rgba(60, 18, 26, .72) 100%),
        url("../images/KircheHassel.jpg") center 62% / cover no-repeat,
        linear-gradient(135deg, #173d2e 0%, #24533f 54%, #7f2430 100%);
}
.site-header--hero h1,
.site-header--hero .hero__lead { text-shadow: 0 2px 14px rgba(0, 0, 0, .55); }
.hero { position: relative; z-index: 1; text-align: center; max-width: 980px; }
.hero__eyebrow { margin: 0 0 10px; color: #f3d98d; font-size: .83rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.hero__lead { max-width: 700px; margin: 14px auto 0; color: #f8f3e8; font-size: clamp(1rem, 2.2vw, 1.2rem); }
.hero__ornament { display: flex; justify-content: center; align-items: center; gap: 14px; margin-top: 18px; color: #f2d77c; font-size: 1.1rem; }
.hero__ornament span:nth-child(2) { font-size: .78rem; opacity: .75; }

.site-footer { padding: 30px 0 42px; color: #e9e2d5; font-size: .9rem; text-align: center; background: linear-gradient(135deg, #17372d, #10291f); border-top: 3px solid var(--gold); }
.site-footer a { color: #f5e6b7; }
.site-footer__nav { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 6px 10px; }
.powered-by { white-space: nowrap; }
.powered-by a { font-weight: 700; text-decoration: none; }
.powered-by a:hover, .powered-by a:focus-visible { text-decoration: underline; }
.site-footer--admin { padding-top: 10px; }

main { padding-bottom: 24px; }

.intro {
    background: #fffdf7;
    border-left: 4px solid var(--gold);
    padding: 14px 16px;
    margin-top: 20px;
    border-radius: 0 var(--radius) var(--radius) 0;
}

.panel {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 18px 16px;
    margin: 20px 0;
}

.panel h2 { margin: 0 0 12px; font-size: 1.2rem; }

/* ---------- Ein-/ausklappbare Bereiche ---------- */

.collapse > .collapse__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    cursor: pointer;
    list-style: none;
    user-select: none;
}
.collapse > .collapse__head::-webkit-details-marker { display: none; }
.collapse > .collapse__head::marker { content: ""; }
.collapse[open] > .collapse__head { margin-bottom: 12px; }
.collapse__titles { display: block; min-width: 0; }
.collapse__titles .section-kicker { display: block; }
.collapse__title { display: block; font-size: 1.2rem; font-weight: 700; line-height: 1.25; }
.public-site .collapse__title { color: var(--green-dark); }
.collapse__icon {
    flex: 0 0 auto;
    width: 32px;
    height: 32px;
    border: 1px solid var(--line);
    border-radius: 50%;
    position: relative;
    background: #fff;
    transition: transform .2s ease;
}
.collapse__icon::before {
    content: "";
    position: absolute;
    left: 50%;
    top: 45%;
    width: 8px;
    height: 8px;
    border-right: 2px solid var(--accent);
    border-bottom: 2px solid var(--accent);
    transform: translate(-50%, -50%) rotate(45deg);
}
.collapse[open] > .collapse__head .collapse__icon { transform: rotate(180deg); }
.collapse > .collapse__head:focus-visible { outline: 3px solid var(--gold); outline-offset: 4px; border-radius: 6px; }
@media (prefers-reduced-motion: reduce) { .collapse__icon { transition: none; } }
.muted { color: var(--text-muted); }

/* ---------- Terminraster ---------- */

.slot-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-top: 14px;
}

@media (min-width: 560px) { .slot-grid { grid-template-columns: repeat(4, 1fr); } }
@media (min-width: 760px) { .slot-grid { grid-template-columns: repeat(6, 1fr); } }

.slot {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    min-height: 76px;
    padding: 8px 4px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fbfcfd;
    font: inherit;
    color: var(--text);
    cursor: pointer;
    text-align: center;
    transition: transform .08s ease, box-shadow .12s ease;
}

.slot:hover:not([disabled]) {
    transform: translateY(-1px);
    box-shadow: var(--shadow);
    border-color: var(--accent);
}

.slot[disabled] { cursor: default; }

.slot__day { font-size: 1.35rem; font-weight: 700; line-height: 1.1; }
.slot__weekday { font-size: .74rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--text-muted); line-height: 1.2; }

.slot__info {
    font-size: .72rem;
    color: var(--text-muted);
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.slot--free { border-color: #bcd9c7; background: #f2fbf5; }
.slot--held { background: #fdf4e6; border-color: #e8d3aa; }
.slot--confirmed { background: #eef1f5; border-color: #ccd4de; color: var(--text-muted); }
.slot--confirmed .slot__day { color: var(--accent); }
.slot--own { outline: 3px solid var(--accent); background: #fff; }

/* Fensterart-Kennzeichnung im Kalender (einheitlich in der Farbe "vergeben") */
.slot__type {
    display: inline-block;
    max-width: 100%;
    margin-top: 3px;
    padding: 1px 8px;
    border-radius: 8px;
    background: var(--accent);
    color: #fff;
    font-size: .66rem;
    font-weight: 700;
    line-height: 1.35;
    overflow-wrap: anywhere;
}

/* ---------- Legenden ---------- */

.legend {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 10px 18px;
    margin: 12px 0 0;
    padding: 0;
    font-size: .85rem;
    color: var(--text-muted);
}

.legend li { display: flex; align-items: center; gap: 6px; }

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: inline-block;
    border: 1px solid rgba(0, 0, 0, .15);
}

.dot--free { background: #4f9d6d; }
.dot--held { background: #c9962c; }
.dot--confirmed { background: var(--accent); }

/* ---------- Formular ---------- */

.form-grid { display: grid; gap: 14px; }

.field { display: block; margin: 0; }

.field__label {
    display: block;
    font-weight: 600;
    font-size: .92rem;
    margin-bottom: 4px;
}

.field__hint { display: block; font-size: .8rem; color: var(--text-muted); margin-top: 4px; }

.field--split { display: grid; grid-template-columns: 2fr 1fr; gap: 10px; }
.field--narrow { min-width: 0; }

@media (max-width: 480px) {
    .field--split { grid-template-columns: 1fr; }
}

input[type="text"], input[type="tel"], input[type="password"], input[type="date"], input[type="url"],
input[type="datetime-local"], input[type="number"], select, textarea {
    width: 100%;
    max-width: 100%;
    padding: 10px 12px;
    font: inherit;
    color: var(--text);
    background: #fff;
    border: 1px solid #b9c3cf;
    border-radius: 8px;
}

input:disabled { background: #f1f3f6; color: var(--text-muted); }

fieldset.field {
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 12px;
    margin: 0;
}

fieldset.field legend { padding: 0 6px; }

.choice { display: flex; gap: 10px; align-items: flex-start; padding: 6px 0; cursor: pointer; }
.choice input { margin-top: 4px; flex: 0 0 auto; width: 20px; height: 20px; }
.choice small { display: block; color: var(--text-muted); font-size: .82rem; }

.choice--privacy {
    background: #fbfcfd;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 12px;
    font-size: .9rem;
}

.offerings { display: grid; grid-template-columns: 1fr; gap: 2px; }
@media (min-width: 560px) { .offerings { grid-template-columns: 1fr 1fr; } }
.choice--inline { padding: 4px 0; }

.form-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }

.btn {
    display: inline-block;
    padding: 11px 18px;
    border: 1px solid transparent;
    border-radius: 8px;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    text-align: center;
}

.btn--primary { background: var(--accent); color: #fff; }
.btn--primary:hover { background: var(--accent-dark); }
.btn--ghost { background: #fff; border-color: #b9c3cf; color: var(--text); }
.btn--danger { background: #fff; border-color: #d9a3a3; color: #8a2222; }
.btn--small { padding: 6px 10px; font-size: .85rem; }
.btn[disabled] { opacity: .6; cursor: default; }

.hold-hint {
    background: #fffdf7;
    border: 1px solid #eddfba;
    border-radius: 8px;
    padding: 8px 12px;
    font-size: .9rem;
}

.picker-status { font-size: .85rem; color: var(--text-muted); margin: 8px 0; }

/* ---------- Hinweise ---------- */

.notice { padding: 12px 14px; border-radius: 8px; margin: 0 0 14px; font-size: .95rem; }
.notice--error { background: #fdf0f0; border: 1px solid #e6bcbc; color: #7d1f1f; }
.notice--success { background: #eef8f1; border: 1px solid #b9ddc8; color: #1c5636; }
.notice--info { background: #eef4fb; border: 1px solid #c2d6ed; color: #21486f; }

.panel--success { border-color: #b9ddc8; }

.edit-link-box {
    background: #fffdf7;
    border: 1px solid #eddfba;
    border-radius: 8px;
    padding: 12px 14px;
}

.edit-link { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: .82rem; word-break: break-all; }

/* ---------- Oeffentliche Liste ---------- */

.public-list { display: grid; gap: 12px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .public-list { grid-template-columns: 1fr 1fr; } }

.window-card {
    border: 1px solid var(--line);
    border-left: 4px solid var(--accent);
    border-radius: 8px;
    padding: 12px 14px;
    background: #fdfefe;
}

.window-card h3 { margin: 0 0 4px; font-size: 1rem; color: var(--accent); }
.window-card__name { margin: 0; font-weight: 600; }
.window-card__address { margin: 2px 0 6px; color: var(--text-muted); font-size: .9rem; }
.window-card__type { margin: 0; font-size: .88rem; font-weight: 600; }
.window-card__info { margin: 6px 0 0; font-size: .88rem; color: var(--text-muted); }

.tags { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; padding: 0; margin: 8px 0 0; }
.tags li { background: #eef1f5; border-radius: 999px; padding: 2px 10px; font-size: .78rem; }

/* ---------- Karte ---------- */

.map {
    height: 360px;
    border-radius: 8px;
    border: 1px solid var(--line);
    overflow: hidden;
    z-index: 0;
}

.map--picker { height: 260px; margin-top: 8px; }

@media (min-width: 760px) {
    .map { height: 440px; }
    .map--picker { height: 320px; }
}

.map-hint { font-size: .78rem; margin: 8px 0 0; }

.af-marker {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    color: #fff;
    font-weight: 700;
    font-size: .9rem;
    border: 2px solid #fff;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .35);
}

.af-popup { font-size: .9rem; }
.af-popup__type { margin: 6px 0 0; font-weight: 600; }
.af-popup__list { margin: 6px 0 0; padding-left: 18px; }
.af-popup__info { margin: 6px 0 0; color: #556374; }

/* ---------- Zusammenfassung und Fliesstext ---------- */

.summary { display: grid; grid-template-columns: 120px 1fr; gap: 6px 12px; margin: 14px 0; }
.summary dt { font-weight: 600; color: var(--text-muted); }
.summary dd { margin: 0; }

@media (max-width: 480px) { .summary { grid-template-columns: 1fr; } }

.prose h2 { margin-top: 22px; font-size: 1.05rem; }
.prose p, .prose ul { margin: 8px 0; }

/* ---------- Adminbereich ---------- */

body.admin { background: #eef1f5; }

.admin-bar { background: var(--bg); color: #fff; padding: 12px 16px; }
.admin-bar__title { font-weight: 700; margin-bottom: 8px; }

.admin-nav { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: .9rem; }
.admin-nav a { color: #d3dde7; text-decoration: none; }
.admin-nav a:hover { color: #fff; text-decoration: underline; }

.admin-main { max-width: 1150px; margin: 0 auto; padding: 18px 16px 60px; }
.admin-main h1 { font-size: 1.35rem; margin: 0 0 16px; }

.card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 16px;
    margin-bottom: 18px;
    box-shadow: var(--shadow);
}

.card h2 { margin: 0 0 12px; font-size: 1.05rem; }

.table-scroll { overflow-x: auto; }

table.data { width: 100%; border-collapse: collapse; font-size: .9rem; background: #fff; }

table.data th, table.data td {
    border-bottom: 1px solid var(--line);
    padding: 8px 10px;
    text-align: left;
    vertical-align: top;
}

table.data th { background: #f5f7fa; font-weight: 600; white-space: nowrap; }
table.data td.actions { white-space: nowrap; }

.badge { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: .75rem; font-weight: 600; }
.badge--free { background: #e6f5ec; color: #1c5636; }
.badge--held { background: #fbf1de; color: #7d5a12; }
.badge--confirmed { background: #e9edf2; color: #313e4d; }

.inline-form { display: inline; }

.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 640px) { .stats { grid-template-columns: repeat(4, 1fr); } }

.stat { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; text-align: center; }
.stat__value { font-size: 1.5rem; font-weight: 700; }
.stat__label { font-size: .8rem; color: var(--text-muted); }

.login-wrap { max-width: 380px; margin: 60px auto; padding: 0 16px; }


/* ---------- Weihnachtliche oeffentliche Gestaltung ---------- */

.public-site {
    background-color: #f6f1e7;
    background-image:
        radial-gradient(circle at 20px 20px, rgba(201,165,74,.055) 0 1.5px, transparent 1.7px),
        radial-gradient(circle at 65px 70px, rgba(40,91,67,.035) 0 1.5px, transparent 1.7px);
    background-size: 90px 90px;
}

.public-site main { padding-top: 6px; }

.public-site .panel {
    background: rgba(255,253,248,.98);
    border-color: #e1d6c0;
    border-top: 3px solid var(--gold);
    box-shadow: 0 12px 34px rgba(51,56,48,.08);
}

.public-site .panel h2,
.public-site .welcome-card h2,
.public-site .window-option h2 {
    color: var(--green-dark);
}

.section-kicker {
    margin: 0 0 4px;
    color: var(--accent);
    font-size: .76rem;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.welcome-card {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 18px;
    align-items: start;
    margin: 24px 0 14px;
    padding: 22px;
    color: #303a34;
    background: linear-gradient(135deg, #fffdf8 0%, #fbf4e5 100%);
    border: 1px solid #e2d4b5;
    border-radius: 18px;
    box-shadow: var(--shadow);
}

.welcome-card__icon {
    width: 68px;
    height: 78px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff8e5;
    background: linear-gradient(155deg, var(--accent), #741d28);
    border: 2px solid #d4b463;
    border-radius: 8px 8px 18px 18px;
    font-size: 1.6rem;
    font-weight: 800;
    box-shadow: inset 0 0 0 4px rgba(255,255,255,.08), 0 6px 16px rgba(116,29,40,.18);
}

.welcome-card h2 { margin: 0 0 8px; font-size: clamp(1.25rem, 3vw, 1.7rem); }
.welcome-card p { margin: 8px 0 0; }
.welcome-card__extra { padding-top: 10px; border-top: 1px dashed #d8c8a6; color: var(--text-muted); }

.window-options {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    margin: 14px 0 22px;
}

.window-option {
    display: grid;
    grid-template-columns: 46px 1fr;
    gap: 12px;
    padding: 17px;
    border-radius: 14px;
    border: 1px solid #dfd3bd;
    box-shadow: 0 5px 18px rgba(51,56,48,.055);
}

.window-option h2 { margin: 0 0 4px; font-size: 1.02rem; }
.window-option p { margin: 0; color: #566158; font-size: .92rem; }
.window-option__symbol {
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-weight: 800;
    font-size: 1.15rem;
}
.window-option--quiet { background: #f1f7f2; border-color: #c9dcca; }
.window-option--quiet .window-option__symbol { color: #fff; background: var(--green); }
.window-option--plus { background: #fff4f1; border-color: #e7c8c5; }
.window-option--plus .window-option__symbol { color: #fff7e8; background: var(--accent); }

@media (min-width: 700px) {
    .window-options { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 520px) {
    .site-header--hero { padding: 48px 0 44px; background-position: center, center 55%, center; }
    .welcome-card { grid-template-columns: 1fr; padding: 18px; }
    .welcome-card__icon { width: 58px; height: 64px; }
}

.public-site .slot-grid { gap: 10px; }
.public-site .slot {
    position: relative;
    min-height: 88px;
    overflow: hidden;
    border-width: 1px;
    box-shadow: 0 4px 12px rgba(45,55,48,.06);
}
.public-site .slot::before {
    content: "";
    position: absolute;
    width: 48px;
    height: 48px;
    right: -24px;
    top: -24px;
    transform: rotate(45deg);
    background: rgba(201,165,74,.15);
}
.public-site .slot__day { font-size: 1.55rem; font-weight: 800; }
.public-site .slot--free { border-color: #b9d3be; background: linear-gradient(145deg, #fbfffa, #edf7ef); }
.public-site .slot--free .slot__day { color: var(--green); }
.public-site .slot--held { background: #fff8e9; border-color: #e6d19d; }
.public-site .slot--confirmed { background: linear-gradient(145deg, #fbf2ef, #f4e6e2); border-color: #dcbdb7; }
.public-site .slot--confirmed .slot__day { color: var(--accent); }
.public-site .slot:hover:not([disabled]) { transform: translateY(-2px); box-shadow: 0 8px 18px rgba(40,91,67,.14); }

.public-site .btn { border-radius: 999px; }
.public-site .btn--primary { background: linear-gradient(135deg, var(--accent), #7b202b); box-shadow: 0 4px 12px rgba(152,43,54,.18); }
.public-site .btn--primary:hover { background: linear-gradient(135deg, #a8323e, #721b26); }

.public-site .window-card {
    background: linear-gradient(145deg, #fffefa, #faf5ea);
    border-color: #ded2bd;
    border-left: 5px solid var(--accent);
    border-radius: 12px;
    box-shadow: 0 5px 16px rgba(52,57,50,.05);
}
.public-site .window-card h3 { color: var(--accent); }
.public-site .tags li { background: #efe6cf; color: #4a4c42; border: 1px solid #e1d2ad; }
.public-site .map { border: 2px solid #d9c89f; border-radius: 12px; box-shadow: 0 8px 24px rgba(51,56,48,.07); }

.public-site .choice--privacy,
.public-site .edit-link-box,
.public-site .hold-hint { background: #fff9ea; border-color: #e4d2a7; }

@media (prefers-reduced-motion: reduce) {
    .slot { transition: none; }
}

/* ---------- Export (Adminbereich) ---------- */

.export-grid { display: grid; gap: 18px; margin-bottom: 18px; }
.export-grid > .card { margin-bottom: 0; display: flex; flex-direction: column; }
.export-grid > .card .button-row { margin-top: auto; padding-top: 12px; }
@media (min-width: 760px) { .export-grid { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); } }

.button-row { display: flex; flex-wrap: wrap; gap: 8px; }
.segmented { display: inline-flex; flex-wrap: wrap; gap: 4px; }
.btn[aria-current="page"] { background: var(--green); border-color: var(--green); color: #fff; }

table.data td.nowrap { white-space: nowrap; }

/* Druckfertiges Kartenblatt: Groesse = Druckbereich (Papier minus 10 mm Rand),
   identisch auf Bildschirm und Papier, damit der Kartenausschnitt erhalten bleibt. */

body.export-sheet-page { background: #dfe4ea; }

.export-toolbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 12px;
    padding: 10px 16px;
    background: var(--bg);
    color: #fff;
}

.export-toolbar__hint { flex-basis: 100%; margin: 0; font-size: .8rem; color: #d3dde7; }
.export-toolbar__hint a { color: #fff; }
.export-toolbar__warn { flex-basis: 100%; margin: 0; padding: 6px 10px; border-radius: 6px; background: #fdf0f0; color: #7d1f1f; font-size: .85rem; font-weight: 600; }

.sheet-scroll { overflow: auto; padding: calc(10mm + 16px) calc(10mm + 16px) 48px; }

.sheet {
    display: flex;
    flex-direction: column;
    gap: 3mm;
    width: var(--sheet-w, 277mm);
    height: var(--sheet-h, 189mm);
    margin: 0 auto;
    overflow: hidden;
    background: #fff;
    /* weisser Papierrand nur optisch, ohne die Blattgroesse zu veraendern */
    box-shadow: 0 0 0 10mm #fff, 0 8px 30px 10mm rgba(23, 55, 45, .18);
    font-size: 8.5pt;
    line-height: 1.3;
    overflow-wrap: anywhere;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
}

.sheet__head {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 6mm;
    padding-bottom: 2mm;
    border-bottom: .6mm solid var(--accent);
}

.sheet__title { margin: 0; font-size: 17pt; line-height: 1.1; color: var(--accent); }
.sheet__meta { margin: 1mm 0 0; color: var(--text-muted); }

.sheet-legend {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 1mm 4mm;
    margin: 0;
    padding: 0;
}

.sheet-legend li { display: flex; align-items: center; gap: 1.5mm; white-space: nowrap; }
.sheet-legend .dot { width: 3.2mm; height: 3.2mm; }

.sheet__body { flex: 1; min-height: 0; display: flex; gap: 4mm; }

.sheet__map {
    position: relative;
    z-index: 0;
    flex: 1;
    min-width: 0;
    min-height: 0;
    border: .3mm solid #b9c3cf;
}

.sheet__side { flex: none; width: 104mm; min-height: 0; overflow: hidden; }

.sheet-list { list-style: none; margin: 0; padding: 0; columns: 2; column-gap: 4mm; }

.sheet-list li {
    display: flex;
    gap: 1.8mm;
    padding: 0 0 1.6mm;
    break-inside: avoid;
    page-break-inside: avoid;
}

.sheet-list__nr {
    flex: none;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 5.4mm;
    height: 5.4mm;
    border-radius: 50%;
    color: #fff;
    font-size: 7.5pt;
    font-weight: 700;
}

.sheet-list__nr--nomap { outline: .4mm dashed #687168; outline-offset: .4mm; }
.sheet-list__text { display: flex; flex-direction: column; min-width: 0; }
.sheet-list__name { font-weight: 700; }
.sheet-list__meta { color: var(--text-muted); font-size: 7.5pt; }

.sheet__foot { display: flex; justify-content: space-between; gap: 4mm; color: var(--text-muted); font-size: 7pt; }

.sheet--portrait .sheet__body { flex-direction: column; }
.sheet--portrait .sheet__side { width: auto; flex: none; max-height: 46%; }
.sheet--portrait .sheet-list { columns: 3; }
.sheet--a3-quer .sheet__side { width: 124mm; }
.sheet--a3-quer, .sheet--a3-hoch { font-size: 9.5pt; }
.sheet--a3-hoch .sheet-list { columns: 3; }
.sheet--dense .sheet-list { font-size: 7.2pt; line-height: 1.25; }
.sheet--dense .sheet-list__meta { font-size: 6.6pt; }
.sheet--dense .sheet-list li { padding-bottom: 1mm; }

.af-marker--export { width: 26px; height: 26px; font-size: .8rem; border-width: 2px; }

@media print {
    body.admin, body.export-sheet-page { background: #fff; }
    .admin-bar, .site-footer, .skip-link, .no-print, .export-toolbar,
    .leaflet-control-zoom, .admin-main > h1 { display: none !important; }
    .admin-main { max-width: none; padding: 0; }
    .card { border: 0; box-shadow: none; padding: 0; }
    .table-scroll { overflow: visible; }
    table.data { font-size: 9pt; }
    table.data tr { break-inside: avoid; page-break-inside: avoid; }
    table.data thead { display: table-header-group; }
    .sheet-scroll { padding: 0; overflow: visible; }
    .sheet { margin: 0; outline: 0; box-shadow: none; break-inside: avoid; page-break-inside: avoid; }
}

/* ---------- Live-Karte (livemap.html) ---------- */

/* Kopf mit demselben Hintergrundbild wie die Startseite, aber kompakt (Karte soll schnell sichtbar sein) */
.lm-header {
    padding: 30px 0 26px;
    text-align: center;
    background:
        linear-gradient(180deg, rgba(10, 28, 22, .62) 0%, rgba(14, 38, 30, .48) 45%, rgba(60, 18, 26, .72) 100%),
        url("../images/KircheHassel.jpg") center 62% / cover no-repeat,
        linear-gradient(135deg, #173d2e 0%, #24533f 54%, #7f2430 100%);
}
.lm-header h1,
.lm-header .hero__eyebrow { text-shadow: 0 2px 14px rgba(0, 0, 0, .55); }
@media (min-width: 760px) { .lm-header { padding: 44px 0 38px; } }
.lm-header__inner { position: relative; z-index: 1; }
.lm-header .hero__eyebrow { margin-bottom: 4px; }
.lm-header h1 { font-size: clamp(1.25rem, 4.6vw, 2.1rem); }

.lm-main { max-width: 1240px; margin: 0 auto; padding: 14px 16px 28px; }

.lm-today {
    margin-bottom: 14px;
    padding: 14px 16px;
    background: rgba(255, 253, 248, .98);
    border: 1px solid #e1d6c0;
    border-top: 3px solid var(--gold);
    border-radius: var(--radius);
    box-shadow: 0 8px 24px rgba(51, 56, 48, .08);
}

.lm-today--live { background: linear-gradient(135deg, #fffaf0, #fbefe0); border-top-color: var(--accent); }
.lm-today__loading, .lm-today__msg { margin: 0; }
.lm-today__inner { display: flex; gap: 14px; align-items: center; }
.lm-today__text { min-width: 0; }
.lm-today__kicker { margin: 0; color: var(--accent); font-size: .78rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.lm-today__name { margin: 2px 0 0; font-size: 1.15rem; font-weight: 700; color: var(--green-dark); line-height: 1.25; }
.lm-today__addr { margin: 2px 0 0; color: var(--text-muted); }
.lm-today__actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }

.lm-map {
    position: relative;
    z-index: 0;
    height: 62vh;
    height: 62svh;
    min-height: 320px;
    max-height: 760px;
    border: 2px solid #d9c89f;
    border-radius: 12px;
    overflow: hidden;
}

.lm-map__error { padding: 16px; }

.lm-legend {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 6px 16px;
    margin: 10px 0 0;
    padding: 0;
    font-size: .82rem;
    color: var(--text-muted);
}

.lm-legend li { display: flex; align-items: center; gap: 6px; }
.lm-legend__mk.lm-marker { width: 14px; height: 14px; border-width: 2px; box-shadow: none; }
.lm-legend__mk.lm-marker::after { display: none; }

/* Marker: gefuellt = schon geoeffnet, Ring = noch geschlossen, gross + Puls = heute */

.lm-marker-wrapper { background: none; border: 0; }

.lm-marker {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: var(--c, #8c1c1c);
    color: #fff;
    border: 2px solid #fff;
    box-shadow: 0 1px 5px rgba(0, 0, 0, .4);
    font-family: var(--font);
    font-size: 13px;
    font-weight: 800;
    line-height: 1;
    transition: transform .15s ease;
}

.lm-marker--future { background: #fff; color: var(--c, #8c1c1c); border: 3px solid var(--c, #8c1c1c); }
.lm-marker--next { border: 3px dashed var(--gold); font-size: 15px; }
.lm-marker--today { font-size: 18px; border: 3px solid var(--gold); box-shadow: 0 0 0 3px rgba(255, 255, 255, .85), 0 3px 12px rgba(0, 0, 0, .45); }

.lm-marker--today::after {
    content: "";
    position: absolute;
    inset: -9px;
    border-radius: 50%;
    border: 3px solid var(--gold);
    animation: lm-pulse 1.8s ease-out infinite;
    pointer-events: none;
}

.lm-marker.is-selected { transform: scale(1.18); box-shadow: 0 0 0 3px #fff, 0 0 0 6px var(--green-dark), 0 4px 12px rgba(0, 0, 0, .4); }

@keyframes lm-pulse {
    0% { transform: scale(.8); opacity: .95; }
    100% { transform: scale(1.5); opacity: 0; }
}

/* Kurzwahl auf der Karte */
.lm-ctl button {
    display: block;
    width: 100%;
    padding: 7px 11px;
    background: #fff;
    border: 0;
    border-bottom: 1px solid #ccc;
    font: 700 13px var(--font);
    color: var(--green-dark);
    cursor: pointer;
}
.lm-ctl button:last-child { border-bottom: 0; }
.lm-ctl button:hover { background: #f4f4f4; }
.lm-ctl button[hidden] { display: none; }

/* Tagesbadge in Liste, Hinweis und Details */
.lm-badge {
    flex: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--c, #8c1c1c);
    color: #fff;
    border: 2px solid #fff;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .25);
    font-weight: 800;
}
.lm-badge--future { background: #fff; color: var(--c, #8c1c1c); border: 3px solid var(--c, #8c1c1c); }
.lm-badge--today { border: 3px solid var(--gold); }
.lm-today .lm-badge { width: 56px; height: 56px; font-size: 1.45rem; }
.lm-badge--lg { width: 52px; height: 52px; font-size: 1.35rem; }

.lm-chip { display: inline-block; padding: 1px 8px; border-radius: 999px; font-size: .74rem; font-weight: 700; vertical-align: middle; }
.lm-chip--today { background: var(--accent); color: #fff; }
.lm-chip--next { background: #fbf1de; color: #7d5a12; }
.lm-chip--past { background: #e6f5ec; color: #1c5636; }
.lm-chip--future { background: #eef1f5; color: #313e4d; }

/* Details: auf dem Handy als Blatt von unten, am Desktop neben der Karte */
.lm-detail {
    background: #fffdf8;
    border: 1px solid #e1d6c0;
    border-top: 3px solid var(--gold);
    border-radius: var(--radius);
    box-shadow: 0 10px 30px rgba(51, 56, 48, .12);
    padding: 16px;
}

.lm-detail__close {
    float: right;
    width: 36px;
    height: 36px;
    margin: -6px -6px 0 8px;
    border: 0;
    border-radius: 50%;
    background: #f1ece1;
    color: var(--text);
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
}

.lm-detail__head { display: flex; gap: 12px; align-items: center; }
.lm-detail__date { margin: 0 0 2px; font-weight: 700; color: var(--accent); }
.lm-detail__name { margin: 12px 0 4px; font-size: 1.25rem; line-height: 1.25; color: var(--green-dark); }
.lm-detail__name:focus { outline: none; }
.lm-detail__address { margin: 0 0 10px; }
.lm-detail__type { display: flex; align-items: center; gap: 8px; margin: 0; font-weight: 600; }
.lm-detail__tags { margin-top: 10px; }
.lm-detail__info { margin: 10px 0 0; padding: 10px 12px; background: #f6f1e7; border-radius: 8px; font-size: .92rem; }
.lm-detail__hint { margin: 10px 0 0; font-size: .85rem; color: var(--text-muted); }

.lm-route { margin-top: 14px; }
.lm-route__main { display: block; width: 100%; }
.lm-route__alt { margin: 8px 0 0; font-size: .85rem; color: var(--text-muted); text-align: center; }
.lm-route__alt a { color: var(--green-dark); }

.lm-detail__nav { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 14px; padding-top: 12px; border-top: 1px solid #e8dfcc; }
.lm-detail__pos { font-size: .82rem; color: var(--text-muted); white-space: nowrap; }

@media (max-width: 899px) {
    .lm-detail {
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 1100;
        max-height: 60vh;
        max-height: 60svh;
        overflow-y: auto;
        overscroll-behavior: contain;
        border-radius: 18px 18px 0 0;
        border-bottom: 0;
        padding: 20px 16px calc(16px + env(safe-area-inset-bottom));
        box-shadow: 0 -10px 34px rgba(23, 55, 45, .28);
        animation: lm-sheet-in .22s ease-out;
    }
    .lm-detail::before {
        content: "";
        position: absolute;
        top: 7px;
        left: 50%;
        width: 40px;
        height: 4px;
        margin-left: -20px;
        border-radius: 2px;
        background: #d6cbb5;
    }
}

@keyframes lm-sheet-in {
    from { transform: translateY(40px); opacity: .4; }
    to { transform: translateY(0); opacity: 1; }
}

@media (min-width: 900px) {
    .lm-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; align-items: start; }
    .lm-layout.has-detail { grid-template-columns: minmax(0, 1fr) 360px; }
    .lm-map { height: 72vh; }
    .lm-detail { position: sticky; top: 12px; max-height: calc(100vh - 24px); overflow-y: auto; }
}

/* Liste aller Fenster */
.lm-all { margin-top: 22px; }
.lm-all h2 { margin: 0 0 10px; font-size: 1.15rem; color: var(--green-dark); }
.lm-list { list-style: none; display: grid; gap: 8px; margin: 0; padding: 0; }
@media (min-width: 640px) { .lm-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1000px) { .lm-list { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

.lm-item {
    display: flex;
    gap: 12px;
    align-items: center;
    width: 100%;
    padding: 10px 12px;
    background: #fffdf8;
    border: 1px solid #e1d6c0;
    border-radius: 12px;
    font: inherit;
    color: inherit;
    text-align: left;
    cursor: pointer;
}
.lm-item:hover { border-color: #cdb98c; }
.lm-item--today { background: #fff6e6; border: 2px solid var(--gold); }
.lm-item[aria-current="true"] { outline: 3px solid var(--green-dark); outline-offset: 1px; }
.lm-item__text { display: flex; flex-direction: column; min-width: 0; }
.lm-item__date { font-size: .8rem; font-weight: 700; color: var(--accent); }
.lm-item__name { font-weight: 700; line-height: 1.25; }
.lm-item__addr { font-size: .86rem; color: var(--text-muted); }

.lm-note { margin: 14px 0 10px; font-size: .8rem; color: var(--text-muted); }

@media (prefers-reduced-motion: reduce) {
    .lm-marker--today::after, .lm-detail { animation: none; }
    .lm-marker { transition: none; }
}

.copy-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.copy-row input { flex: 1 1 260px; min-width: 0; padding: 7px 10px; border: 1px solid #b9c3cf; border-radius: 8px; font: inherit; font-size: .9rem; background: #f8fafc; }

/* ---------- Icons der Fensterarten ---------- */

.ti { display: inline-block; width: 1.1em; height: 1.1em; flex: none; vertical-align: -0.15em; }
img.ti--img { object-fit: contain; }

.icon-form { padding: 14px 0; border-top: 1px solid var(--line); }
.icon-form__head { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.icon-form__head h3 { margin: 0; font-size: 1rem; }
.icon-form__upload { margin-top: 12px; display: grid; gap: 6px; max-width: 520px; }

.icon-preview {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    border: 2px solid var(--c, #8c1c1c);
    color: var(--c, #8c1c1c);
    background: #fff;
}
.icon-preview .ti { width: 30px; height: 30px; }

.icon-picker { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; border: 0; }
.icon-picker label { position: relative; cursor: pointer; }
.icon-picker input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.icon-picker label > span {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border: 1px solid #ccd3dc;
    border-radius: 10px;
    background: #fff;
    color: var(--c, #8c1c1c);
}
.icon-picker .ti { width: 26px; height: 26px; }
.icon-picker__none { font-size: 1.3rem; color: var(--text-muted); }
.icon-picker label:hover > span { border-color: #8a97a8; }
.icon-picker input:checked + span { border-color: var(--green-dark); box-shadow: 0 0 0 2px var(--green-dark); background: #f3f8f4; }
.icon-picker input:focus-visible + span { outline: 3px solid var(--accent); outline-offset: 2px; }

/* ---------- Flyer A5 (admin/flyer.php) ---------- */

body.flyer-page { background: #dfe4ea; }

.fl-app { display: grid; grid-template-columns: 360px minmax(0, 1fr); min-height: 100vh; }
@media (max-width: 1000px) { .fl-app { grid-template-columns: 1fr; } }

.fl-editor {
    background: #fff;
    border-right: 1px solid var(--line);
    padding: 16px 18px 40px;
    font-size: .92rem;
    overflow-y: auto;
    max-height: 100vh;
    position: sticky;
    top: 0;
}
@media (max-width: 1000px) { .fl-editor { position: static; max-height: none; border-right: 0; } }
.fl-editor h1 { margin: 4px 0 12px; font-size: 1.3rem; }
.fl-editor__back { margin: 0; font-size: .85rem; }
.fl-editor .field { margin: 0 0 10px; }
.fl-editor .choice small { display: block; }
.fl-group { margin: 0 0 14px; padding: 10px 12px 4px; border: 1px solid var(--line); border-radius: 10px; }
.fl-group legend { padding: 0 6px; font-weight: 700; }
.fl-editor__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 14px 0 8px; }
.fl-editor__hint { margin: 6px 0 0; font-size: .8rem; color: var(--text-muted); }
.fl-editor [hidden] { display: none !important; }
.fl [hidden] { display: none !important; }
.fl-dirty { font-size: .8rem; font-weight: 700; color: #7d5a12; }
.fl-editor input[type="range"] { width: 100%; }

.fl-preview { overflow: auto; padding: 28px; }

/* Papierbogen: Groesse = Seitengroesse der Druckvariante */
.fl-sheet {
    position: relative;
    width: var(--page-w);
    height: calc(var(--page-h) - .3mm);
    margin: 0 auto;
    background: #fff;
    box-shadow: 0 8px 30px rgba(23, 55, 45, .2);
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
}

/* Endformat je Variante, Seitengroesse je Druckform (Druckerei: +3 mm Beschnitt, +8 mm Rand fuer Marken) */
body.flyer-page { --trim-w: 148mm; --trim-h: 210mm; }
body.flyer-page.layout-a4 { --trim-w: 210mm; --trim-h: 297mm; }
.mode-a5    { --page-w: var(--trim-w); --page-h: var(--trim-h); }
.mode-a4x2  { --page-w: 297mm; --page-h: 210mm; }
.mode-bleed { --page-w: calc(var(--trim-w) + 22mm); --page-h: calc(var(--trim-h) + 22mm); }

.fl.fl--copy, .fl-cutline, .fl-crop { display: none; }
.mode-a4x2 .fl.fl--copy { display: flex; left: 148.5mm; }
.mode-a4x2 .fl-cutline { display: block; position: absolute; top: 0; bottom: 0; left: 148.5mm; border-left: .25mm dashed #b7b7b7; }
.mode-bleed .fl-crop { display: block; }
.fl-crop i { position: absolute; border-top: .2mm solid #000; border-left: .2mm solid #000; }
.fl-crop i.h { width: 6mm; height: 0; }
.fl-crop i.v { width: 0; height: 6mm; }
.fl-crop i.h.tl { left: 2mm; top: 11mm; }
.fl-crop i.v.tl { left: 11mm; top: 2mm; }
.fl-crop i.h.tr { left: calc(var(--trim-w) + 14mm); top: 11mm; }
.fl-crop i.v.tr { left: calc(var(--trim-w) + 11mm); top: 2mm; }
.fl-crop i.h.bl { left: 2mm; top: calc(var(--trim-h) + 11mm); }
.fl-crop i.v.bl { left: 11mm; top: calc(var(--trim-h) + 14mm); }
.fl-crop i.h.br { left: calc(var(--trim-w) + 14mm); top: calc(var(--trim-h) + 11mm); }
.fl-crop i.v.br { left: calc(var(--trim-w) + 11mm); top: calc(var(--trim-h) + 14mm); }

/* Der Flyer selbst */
.fl {
    --outer: 6mm;
    --bleed: 0mm;
    --tx: 0mm;
    --foot-pad: 0mm;
    --qr: 24mm;
    --map-h: 86mm;
    position: absolute;
    top: 0;
    left: 0;
    display: flex;
    flex-direction: column;
    width: var(--trim-w);
    height: var(--trim-h);
    padding: var(--outer);
    overflow: hidden;
    background: #fff;
    color: var(--text);
    font-family: var(--font);
    font-size: 7pt;
    line-height: 1.25;
    overflow-wrap: anywhere;
}
.mode-a4x2 .fl { width: 148.5mm; }
.mode-bleed .fl { --outer: 0mm; --bleed: 3mm; --tx: 8mm; --foot-pad: 4.5mm; top: 8mm; left: 8mm; width: calc(var(--trim-w) + 6mm); height: calc(var(--trim-h) + 6mm); }

.fl-head {
    flex: none;
    padding: calc(var(--bleed) + 3.2mm) calc(var(--tx) + 4mm) 3mm;
    background: linear-gradient(135deg, #173d2e 0%, #24533f 55%, #7f2430 100%);
    border-bottom: .8mm solid var(--gold);
    color: #fff;
    text-align: center;
}
.fl-head__title { margin: 0; font-size: 19pt; line-height: 1.08; font-weight: 800; letter-spacing: -.01em; }
.fl-head__sub { margin: 1.2mm 0 0; font-size: 8.5pt; color: #f3d98d; font-weight: 600; }

.fl-map { position: relative; flex: none; height: var(--map-h); background: #e9ecef; }
.fl-map__canvas { position: absolute; inset: 0; z-index: 0; }
.fl-map .leaflet-container { background: #e9ecef; font-family: var(--font); }

.fl-qr {
    position: absolute;
    z-index: 500;
    width: calc(var(--qr) + 3.6mm);
    padding: 1.8mm 1.8mm 1.4mm;
    background: #fff;
    border-radius: 2mm;
    box-shadow: 0 .4mm 2mm rgba(0, 0, 0, .35);
    text-align: center;
}
.fl-qr__code svg { display: block; width: var(--qr); height: var(--qr); }
.fl-qr__cap { margin: 1.2mm 0 0; font-size: 6pt; font-weight: 700; line-height: 1.15; color: var(--green-dark); }
.fl--qr-tl .fl-qr { top: 2.5mm; left: calc(var(--tx) + 2.5mm); }
.fl--qr-tr .fl-qr { top: 2.5mm; right: calc(var(--tx) + 2.5mm); }
.fl--qr-bl .fl-qr { bottom: 2.5mm; left: calc(var(--tx) + 2.5mm); }
.fl--qr-br .fl-qr { bottom: 2.5mm; right: calc(var(--tx) + 2.5mm); }

.fl-osm {
    position: absolute;
    z-index: 500;
    bottom: .8mm;
    right: calc(var(--tx) + 1mm);
    padding: .2mm 1mm;
    background: rgba(255, 255, 255, .8);
    font-size: 4.6pt;
    color: #444;
}
.fl--qr-br .fl-osm { right: auto; left: calc(var(--tx) + 1mm); }

/* Marker */
.fl-mk-wrap { background: none; border: 0; }
.fl-mk {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--c, #8c1c1c);
    border: 1.5px solid #fff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, .45);
    color: #fff;
    font: 800 10px/1 var(--font);
}
.fl-mk b { font-weight: 800; }
.fl-mk__ic {
    position: absolute;
    top: -7px;
    right: -8px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #fff;
    color: var(--c, #8c1c1c);
    box-shadow: 0 0 0 1px var(--c, #8c1c1c);
}
.fl-mk__ic .ti { width: 10px; height: 10px; }

/* Stationsliste */
.fl-body {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: 1.4mm;
    padding: 2.6mm var(--tx) 0;
    overflow: hidden;
}
.fl-intro { margin: 0; font-size: 7.6pt; line-height: 1.3; }
.fl-place { margin: 0; font-size: 6.6pt; font-weight: 700; color: var(--accent); text-transform: uppercase; letter-spacing: .04em; }
.fl-legend { list-style: none; display: flex; flex-wrap: wrap; gap: .6mm 3.5mm; margin: 0; padding: 0 0 .8mm; border-bottom: .25mm solid #e3dac9; font-size: 6.4pt; }
.fl-legend li { display: flex; align-items: center; gap: .9mm; }
.fl-dot { width: 2.4mm; height: 2.4mm; border-radius: 50%; background: var(--c); }
.fl-legend .ti { width: 2.9mm; height: 2.9mm; color: var(--c); }

.fl-list {
    flex: 1;
    min-height: 0;
    list-style: none;
    margin: 0;
    padding: 0;
    columns: 3;
    column-gap: 3mm;
    overflow: hidden;
    font-size: var(--list-fs, 7pt);
    line-height: 1.22;
}
.fl-list li { display: flex; gap: .6em; padding: 0 0 .6em; break-inside: avoid; page-break-inside: avoid; }
.fl-nr {
    flex: none;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 1.85em;
    height: 1.85em;
    border-radius: 50%;
    background: var(--c, #8c1c1c);
    color: #fff;
    font-size: .95em;
    font-weight: 800;
}
.fl-entry { display: flex; flex-direction: column; min-width: 0; }
.fl-entry__name { font-weight: 700; }
.fl-entry__type { display: flex; align-items: center; gap: .8mm; color: var(--text-muted); }
.fl-entry .ti { width: 1.15em; height: 1.15em; color: var(--c); }
.fl-entry__inline-icon { display: none; margin-left: .8mm; }
.fl--no-typetext .fl-entry__type { display: none; }
.fl--no-typetext .fl-entry__inline-icon { display: inline; }
.fl-empty { color: var(--text-muted); }


.fl-foot {
    flex: none;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: .5mm 3mm;
    margin: 1.4mm var(--tx) 0;
    padding: 1.4mm 0 calc(var(--bleed) + var(--foot-pad));
    border-top: .25mm solid #e3dac9;
    font-size: 6pt;
    color: var(--text-muted);
}
.fl-foot__url { font-weight: 700; color: var(--green-dark); }

@media print {
    body.flyer-page { background: #fff; }
    .fl-editor { display: none !important; }
    .fl-app { display: block; min-height: 0; }
    .fl-preview { padding: 0 !important; overflow: visible; }
    .fl-sheet { margin: 0; box-shadow: none; overflow: hidden; break-after: avoid; page-break-after: avoid; }
    .layout-info .fl-sheet--front { break-after: page; page-break-after: always; }
    .fl-sheet + .fl-sheet { margin-top: 0; }
    .fl-sheet__label { display: none; }
    .fl .leaflet-control-container { display: none; }
}

/* Icons auf der Live-Karte */
.lm-type { display: inline-flex; align-items: center; gap: 6px; font-size: .84rem; color: var(--text-muted); }
.lm-type .ti { width: 1.2em; height: 1.2em; color: var(--c, #8c1c1c); }
.lm-today__type { margin-top: 3px; }
.lm-item__type { margin-top: 2px; }
.lm-detail__type .lm-type { font-size: 1rem; font-weight: 600; color: var(--text); }
.lm-legend .ti { width: 16px; height: 16px; color: var(--c, #8c1c1c); }
.lm-marker__ic {
    position: absolute;
    z-index: 1;
    top: -7px;
    right: -8px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 17px;
    height: 17px;
    border-radius: 50%;
    background: #fff;
    color: var(--c, #8c1c1c);
    box-shadow: 0 0 0 1.5px var(--c, #8c1c1c), 0 1px 3px rgba(0, 0, 0, .3);
}
.lm-marker__ic .ti { width: 12px; height: 12px; }
.lm-marker--today .lm-marker__ic { top: -8px; right: -9px; width: 21px; height: 21px; }
.lm-marker--today .lm-marker__ic .ti { width: 15px; height: 15px; }

/* Icons auf der Gesamtkarte (Export) */
.af-marker--export { position: relative; }
.af-marker__ic {
    position: absolute;
    top: -6px;
    right: -7px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #fff;
    color: var(--c, #8c1c1c);
    box-shadow: 0 0 0 1px var(--c, #8c1c1c);
}
.af-marker__ic .ti { width: 10px; height: 10px; }
.sheet-legend .ti, .sheet-list__meta .ti { width: 1.15em; height: 1.15em; color: var(--c, #8c1c1c); vertical-align: -.2em; }

/* ---------- Flyer: zweiseitige Variante mit Erklaerung ---------- */

.layout-compact .fl-sheet--front { display: none; }
.layout-info .fl-intro { display: none; }
.fl-sheet__label { display: none; }

/* Nur Bildschirmvorschau: Abstaende und Beschriftung der Boegen (im Druck stoeren sie) */
@media screen {
    .fl-sheet + .fl-sheet { margin-top: 46px; }
    .layout-info .fl-sheet__label { display: block; position: absolute; top: -24px; left: 0; font: 700 .8rem var(--font); color: var(--text-muted); letter-spacing: .04em; text-transform: uppercase; }
    .layout-info .fl-preview { padding-top: 46px; }
}

.fl.fl--front { font-size: var(--front-fs, 9pt); line-height: 1.38; }

.flf-hero {
    flex: none;
    padding: calc(var(--bleed) + 7mm) calc(var(--tx) + 6mm) 6mm;
    background: linear-gradient(135deg, #173d2e 0%, #24533f 55%, #7f2430 100%);
    border-bottom: .8mm solid var(--gold);
    color: #fff;
    text-align: center;
}
.flf--hero-img .flf-hero {
    padding-top: calc(var(--bleed) + 17mm);
    padding-bottom: 8mm;
    background:
        linear-gradient(180deg, rgba(10, 28, 22, .55) 0%, rgba(14, 38, 30, .42) 45%, rgba(60, 18, 26, .78) 100%),
        url("../images/KircheHassel.jpg") center 62% / cover no-repeat,
        linear-gradient(135deg, #173d2e 0%, #24533f 54%, #7f2430 100%);
}
.flf-hero__eyebrow { margin: 0 0 1.5mm; font-size: 7pt; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: #f3d98d; }
.flf-hero__title { margin: 0; font-size: 23pt; line-height: 1.05; font-weight: 800; letter-spacing: -.01em; text-shadow: 0 .5mm 3mm rgba(0, 0, 0, .45); }
.flf-hero__sub { margin: 2mm 0 0; font-size: 9pt; font-weight: 600; color: #f8f3e8; text-shadow: 0 .3mm 2mm rgba(0, 0, 0, .45); }

.flf-body {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: 3.4mm;
    padding: 5mm calc(var(--tx) + 3mm) 0;
    overflow: hidden;
}
.flf-sec h3 { margin: 0 0 1.2mm; font-size: 1.15em; line-height: 1.2; font-weight: 800; color: var(--accent); }
.flf-text { margin: 0; white-space: pre-line; }
.flf-extra { padding: 2mm 3mm; background: #f6f1e7; border-radius: 2mm; }

.flf-types { list-style: none; display: grid; gap: 2.2mm; margin: 0; padding: 0; }
.flf-types li { display: flex; align-items: flex-start; gap: 2.6mm; }
.flf-typeicon {
    flex: none;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.6em;
    height: 2.6em;
    border-radius: 50%;
    background: var(--c, #8c1c1c);
    color: #fff;
}
.flf-typeicon .ti { width: 1.6em; height: 1.6em; }
.flf-typeicon img.ti--img { width: 2.1em; height: 2.1em; border-radius: 50%; background: #fff; }
.flf-typetext { display: flex; flex-direction: column; min-width: 0; padding-top: .15em; }
.flf-typetext strong { color: var(--green-dark); }

.flf-steps { list-style: none; display: grid; gap: 1.6mm; margin: 0; padding: 0; }
.flf-steps li { display: flex; align-items: flex-start; gap: 2.2mm; }
.flf-steps__nr {
    flex: none;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 1.55em;
    height: 1.55em;
    margin-top: .05em;
    border-radius: 50%;
    background: var(--green-dark);
    color: #fff;
    font-size: .9em;
    font-weight: 800;
}

.flf-qr {
    flex: none;
    display: flex;
    align-items: center;
    gap: 4mm;
    margin: 3.5mm calc(var(--tx) + 3mm) 0;
    padding: 3mm;
    background: #fffaf0;
    border: .4mm solid var(--gold);
    border-radius: 3mm;
}
.flf--no-foot .flf-qr { margin-bottom: calc(var(--bleed) + var(--foot-pad) + 1mm); }
.flf-qr__code { flex: none; }
.flf-qr__code svg { display: block; width: 30mm; height: 30mm; }
.flf-qr__text { min-width: 0; }
.flf-qr__title { margin: 0; font-size: 12.5pt; font-weight: 800; line-height: 1.15; color: var(--accent); }
.flf-qr__cap { margin: 1mm 0 0; font-size: 9pt; font-weight: 700; line-height: 1.25; color: var(--green-dark); }
.flf-qr__hint { margin: 2.2mm 0 0; font-size: 7pt; color: var(--text-muted); }
.flf-qr__url { margin: .4mm 0 0; font-size: 7.5pt; font-weight: 700; color: var(--green-dark); }
.flf-foot { font-size: 6.5pt; }

/* ---------- Flyer: A4 einseitig mit allen Infos ---------- */

.fl-sheet--a4 { display: none; }
.layout-a4 .fl-sheet--a4 { display: block; }
.layout-a4 .fl-sheet--front,
.layout-a4 .fl-sheet--back { display: none; }

.fl.fl--a4 { font-size: 8.4pt; line-height: 1.35; }
.fl--a4 .flf-hero { padding-top: calc(var(--bleed) + 6mm); padding-bottom: 5mm; }
.fl--a4.flf--hero-img .flf-hero { padding-top: calc(var(--bleed) + 12mm); padding-bottom: 6mm; }
.fl--a4 .flf-hero__title { font-size: 27pt; }
.fl--a4 .flf-hero__sub { font-size: 10pt; }

.fla-info {
    flex: none;
    display: grid;
    grid-template-columns: 1.3fr 1fr 1fr;
    gap: 5mm;
    padding: 4.5mm calc(var(--tx) + 3mm) 0;
}
.fla-info .flf-sec[hidden] { display: none; }
.fla-extra { flex: none; margin: 3mm calc(var(--tx) + 3mm) 0; }
.fl--a4 .fl-body { padding: 4mm calc(var(--tx) + 3mm) 0; gap: 1.6mm; border-top: 0; }
.fl--a4 .fl-place { font-size: 8pt; }
.fl--a4 .fl-legend { font-size: 7.4pt; }
.fl--a4 .fl-list { columns: 4; column-gap: 4mm; }
.fl--a4 .fl-foot { margin-left: calc(var(--tx) + 3mm); margin-right: calc(var(--tx) + 3mm); font-size: 7pt; }
