:root {
    color-scheme: light;
    /* Chorfarben: dunkles Rot (Chor-Shirts) mit warmem Goldakzent */
    --ink: #2b1d20;
    --muted: #6e5a5e;
    --teal: #8b1a2b;       /* Hauptfarbe (Name aus Kompatibilitätsgründen beibehalten) */
    --teal-dark: #5e1220;
    --coral: #d4a24c;      /* Akzent */
    --paper: #faf7f6;
    --line: #ecdfe0;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
    color: var(--ink);
    background: var(--paper);
    line-height: 1.65;
}
a { color: var(--teal); }
a:hover { color: var(--teal-dark); }
:focus-visible { outline: 3px solid var(--coral); outline-offset: 3px; }

.site-header { background: #fff; border-bottom: .25rem solid var(--teal); }
.header-inner, .footer-inner {
    width: min(100% - 3rem, 72rem);
    margin: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
}
.header-inner { min-height: 5.5rem; }
.brand { display: flex; align-items: center; gap: .8rem; color: var(--ink); text-decoration: none; }
.brand:hover { color: var(--ink); }
.brand-logo { display: block; width: 4.5rem; height: auto; }
.brand-text { display: flex; flex-direction: column; line-height: 1.2; }
.brand-text span { font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; }
.brand-text strong { font-size: 1.15rem; }
.site-header nav, .site-footer nav { display: flex; flex-wrap: wrap; gap: 1.5rem; }
.site-header nav a { color: var(--ink); text-decoration: none; font-size: .92rem; font-weight: 650; }
.site-header nav a { padding: .3rem 0; border-bottom: .2rem solid transparent; }
.site-header nav a:hover { color: var(--teal); border-bottom-color: var(--coral); }

.content { width: min(100% - 3rem, 72rem); margin: 2.5rem auto 5rem; flex: 1; }
.content img { max-width: 100%; height: auto; }
.hero {
    overflow: hidden;
    border-radius: 1.75rem;
    background: var(--teal-dark);
    color: #fff;
    box-shadow: 0 1rem 2.5rem rgb(94 18 32 / 22%);
}
.hero > .hero-banner { display: block; width: 100%; aspect-ratio: 16 / 7; object-fit: cover; object-position: center 30%; border-bottom: .4rem solid var(--coral); }
.hero-content { max-width: 55rem; margin: auto; padding: clamp(1.5rem, 4vw, 2.75rem) clamp(1.25rem, 4vw, 3rem); }
.hero-content > p:first-child { margin-top: 0; font-size: clamp(1.6rem, 4vw, 3rem); font-weight: 800; line-height: 1.12; letter-spacing: -.03em; }
.hero-content > p:last-child { margin-bottom: 0; }
.hero-content a { color: #fff; font-weight: 650; text-decoration-color: var(--coral); text-decoration-thickness: .15em; text-underline-offset: .2em; }
.hero-content a:hover { color: #f6dfb0; }
.hero-content img { border-radius: 1rem; }

.news-section { margin-top: clamp(3rem, 7vw, 5.5rem); scroll-margin-top: 2rem; }
.section-heading { margin-bottom: 1.5rem; }
.eyebrow { margin: 0 0 .4rem; color: var(--teal); font-size: .75rem; font-weight: 750; letter-spacing: .11em; text-transform: uppercase; }
h1, h2, h3 { font-weight: 750; line-height: 1.22; letter-spacing: -.025em; }
h1 { margin: 0 0 1.3rem; font-size: clamp(2rem, 4vw, 2.75rem); }
.section-heading h1 { margin: 0; }
.section-heading h1::after { content: ""; display: block; width: 3.5rem; height: .3rem; margin-top: .6rem; border-radius: .2rem; background: var(--coral); }
.posts { display: grid; gap: 1.25rem; }
.post {
    min-width: 0;
    padding: clamp(1.35rem, 3vw, 2.25rem);
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 1.2rem;
    box-shadow: 0 .5rem 1.75rem rgb(94 18 32 / 5%);
}
.posts .post { border-top: .3rem solid var(--teal); transition: transform .15s, box-shadow .15s; }
.posts .post:hover { transform: translateY(-2px); box-shadow: 0 .8rem 2.2rem rgb(94 18 32 / 12%); }
.post-body.has-image { display: grid; grid-template-columns: minmax(0, 20rem) minmax(0, 1fr); gap: 2rem; align-items: start; }
.post-image { display: block; width: 100%; max-width: 26rem; border-radius: .75rem; box-shadow: 0 .4rem 1rem rgb(0 0 0 / 18%); }
.post-detail > .post-image { margin: 1.25rem 0; }
.post-body .rich-text > :first-child { margin-top: 0; }
.image-field { display: grid; gap: .6rem; padding: 1rem; border: 1px solid var(--line); border-radius: .7rem; background: #fff; }
.admin-thumb { max-width: 12rem; border-radius: .5rem; }
.admin-thumb-wide { max-width: 32rem; width: 100%; margin-bottom: 1rem; }
.post h2 { margin: .55rem 0 1rem; font-size: clamp(1.4rem, 3vw, 1.9rem); }
.post h2 a { color: var(--ink); text-decoration: none; }
.post h2 a:hover { color: var(--teal); }
.post-detail { max-width: 55rem; margin: 0 auto; }
.post-detail h1 { margin-top: 1.4rem; }
.post .meta { color: var(--teal); font-size: .85rem; font-weight: 750; letter-spacing: .04em; }
.back-link { font-weight: 650; text-decoration: none; }
.empty-state { color: var(--muted); }
/* Text sauber umbrechen: Wörter nur trennen, wenn sie sonst nicht passen (z. B. lange Links) */
.rich-text { overflow-wrap: break-word; text-wrap: pretty; }
.rich-text a { overflow-wrap: anywhere; hyphens: none; }
.post h2, .post-detail h1, .section-heading h1 { text-wrap: balance; }
.rich-text img { display: inline-block; border-radius: .75rem; }
.post .rich-text img { width: 100%; max-width: 26rem; box-shadow: 0 .4rem 1rem rgb(0 0 0 / 18%); }
@media (max-width: 60rem) { .post-body.has-image { display: block; } .post-body.has-image .post-image { margin-bottom: 1rem; } }
.rich-text blockquote { margin-left: 0; padding-left: 1rem; border-left: 3px solid var(--teal); }
.ql-align-center { text-align: center; }
.ql-align-right { text-align: right; }
.ql-align-justify { text-align: justify; }

.site-footer { color: #f6e9ea; background: var(--teal-dark); border-top: .25rem solid var(--coral); }
.footer-brand { display: flex; align-items: center; gap: 1rem; }
.footer-brand img { width: 3.5rem; height: auto; flex: none; }
.footer-inner { padding: 2rem 0; align-items: flex-start; }
.site-footer p { margin: .25rem 0 0; color: #e3c9cd; font-size: .9rem; }
.site-footer a { color: #fff; font-size: .9rem; }

.btn, button {
    display: inline-block;
    padding: .65rem 1.1rem;
    border: 0;
    border-radius: .6rem;
    color: #fff;
    background: var(--teal);
    font: inherit;
    font-weight: 650;
    text-decoration: none;
    cursor: pointer;
}
.btn:hover, button:hover { color: #fff; background: var(--teal-dark); }
.btn-secondary { background: #6e5a5e; }
button:disabled { opacity: .6; cursor: wait; }
form.stack { display: grid; gap: .9rem; max-width: 48rem; }
form.stack input[type=text], form.stack input[type=password] {
    display: block;
    width: 100%;
    padding: .7rem;
    border: 1px solid #d6c3c6;
    border-radius: .5rem;
    background: #fff;
    color: var(--ink);
    font: inherit;
}
table.admin { width: 100%; border-collapse: collapse; }
table.admin th, table.admin td { text-align: left; padding: .6rem; border-bottom: 1px solid var(--line); }
.error { color: #a92b26; }
.inline { display: inline; }
.editor-dropzone { min-width: 0; border-radius: .5rem; }
.editor-dropzone.is-dragging { outline: 3px dashed var(--teal); outline-offset: 4px; background: #f8ecee; }
#editor { min-height: 20rem; background: #fff; }
.editor-hint { margin: 0; color: var(--muted); font-size: .85rem; }

@media (max-width: 38rem) {
    .header-inner, .footer-inner { width: min(100% - 2rem, 72rem); }
    .header-inner { min-height: 5rem; flex-wrap: wrap; padding: .8rem 0; gap: .6rem 1rem; }
    .site-header nav { gap: 1rem; }
    .content { width: min(100% - 2rem, 72rem); margin: 1.25rem auto 3rem; }
    .hero { border-radius: 1.1rem; }
    .footer-inner { flex-direction: column; }
    table.admin { font-size: .85rem; }
    table.admin th, table.admin td { padding: .35rem; }
}

.social-field { border: 1px solid #ddd; border-radius: .5rem; padding: .75rem 1rem; }
.social-field label { display: block; }
.social-result { background: #eef6ee; border: 1px solid #b9d8b9; border-radius: .5rem; padding: .5rem 1rem; margin-bottom: 1rem; }
.social-result p { margin: .25rem 0; }
.notice { color: #2f6b2f; }
.inline-form { display: flex; gap: .4rem; flex-wrap: wrap; }
.inline-form input { padding: .5rem; border: 1px solid #d6c3c6; border-radius: .5rem; font: inherit; min-width: 12rem; }

/* ===== Verwaltung: groß, klar, gut lesbar ===== */
.is-admin { font-size: 1.125rem; }
.is-admin .content { max-width: 60rem; }
.is-admin h1 { font-size: 2.1rem; }
.is-admin h2 { margin-top: 2.2rem; font-size: 1.45rem; }
.is-admin .lead { font-size: 1.2rem; color: var(--muted); margin-top: -.6rem; }
.is-admin .hint, .is-admin .editor-hint { color: var(--muted); font-size: 1rem; margin: .2rem 0; }
.is-admin .optional { font-weight: 400; color: var(--muted); font-size: 1rem; }
.is-admin label { font-weight: 600; }
.is-admin .btn, .is-admin button { min-height: 2.9rem; padding: .7rem 1.25rem; font-size: 1.05rem; }
.is-admin .btn-big { min-height: 3.4rem; padding: .85rem 2.2rem; font-size: 1.2rem; }
.is-admin .btn-danger, .is-admin button.btn-danger { background: #fff; color: #a92b26; border: 2px solid #a92b26; }
.is-admin .btn-danger:hover { background: #a92b26; color: #fff; }
.is-admin form.stack input[type=text], .is-admin form.stack input[type=password] { padding: .85rem; font-size: 1.1rem; border-width: 2px; }
.is-admin input[type=file] { display: block; margin-top: .4rem; font-size: 1rem; }
.is-admin input[type=checkbox], .is-admin input[type=radio] { width: 1.35rem; height: 1.35rem; accent-color: var(--teal); flex: none; margin-top: .2rem; }
.is-admin .check { display: flex; gap: .7rem; align-items: flex-start; font-weight: 400; padding: .4rem 0; cursor: pointer; }
.is-admin :focus-visible { outline: 3px solid var(--teal); }

.admin-bar { background: #f3e6e8; border-bottom: 1px solid var(--line); }
.admin-bar-inner { width: min(100% - 3rem, 60rem); margin: auto; display: flex; flex-wrap: wrap; gap: .5rem 1.75rem; align-items: center; padding: .6rem 0; font-size: 1rem; }
.admin-bar a { font-weight: 700; text-decoration: none; }
.admin-user { margin-left: auto; color: var(--muted); }

.notice-box, .error-box { padding: .9rem 1.2rem; border-radius: .7rem; font-weight: 600; }
.notice-box { background: #e8f4e8; border: 2px solid #7fb97f; color: #1f4d1f; }
.error-box { background: #fbeaea; border: 2px solid #d98a86; color: #7c1f1b; }

.admin-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); gap: 1rem; margin: 1.5rem 0; }
.admin-tile { display: flex; flex-direction: column; gap: .3rem; padding: 1.4rem; background: #fff; border: 2px solid var(--line); border-radius: 1rem; color: var(--ink); text-decoration: none; transition: border-color .15s, transform .15s; }
.admin-tile:hover { border-color: var(--teal); color: var(--ink); transform: translateY(-2px); }
.admin-tile strong { font-size: 1.25rem; }
.admin-tile span:last-child { color: var(--muted); font-size: 1rem; }
.admin-tile-icon { font-size: 2rem; line-height: 1; }
.admin-tile-main { background: var(--teal); border-color: var(--teal); color: #fff; }
.admin-tile-main:hover { background: var(--teal-dark); color: #fff; }
.admin-tile-main span:last-child { color: #f6dfe2; }

.admin-list { list-style: none; padding: 0; margin: 0; display: grid; gap: .75rem; }
.admin-list li { display: flex; flex-wrap: wrap; gap: .75rem 1.5rem; align-items: center; justify-content: space-between; padding: 1rem 1.2rem; background: #fff; border: 1px solid var(--line); border-radius: .8rem; }
.admin-list-text { display: flex; flex-direction: column; min-width: 0; }
.admin-list-meta { color: var(--muted); font-size: 1rem; }
.admin-list-actions { display: flex; flex-wrap: wrap; gap: .5rem; }
.badge { display: inline-block; padding: .05rem .55rem; border-radius: 1rem; background: #eee; font-size: .9rem; font-weight: 600; }
.badge-ok { background: #e3f1e3; color: #1f4d1f; }
.badge-draft { background: #fff1d6; color: #6b4a00; }
.admin-settings { display: flex; flex-wrap: wrap; gap: .6rem; }

.step { padding: 1.3rem 1.5rem; background: #fff; border: 1px solid var(--line); border-radius: 1rem; }
.step h2 { margin: 0 0 .8rem; font-size: 1.3rem; display: flex; align-items: center; gap: .6rem; }
.step h3 { margin: 1.4rem 0 .4rem; font-size: 1.1rem; }
.step-no { display: inline-grid; place-items: center; width: 2rem; height: 2rem; border-radius: 50%; background: var(--teal); color: #fff; font-size: 1.05rem; }
.form-actions { display: flex; flex-wrap: wrap; gap: .8rem; align-items: center; margin-top: .5rem; }

.is-admin .ql-toolbar.ql-snow { padding: .6rem; position: sticky; top: 0; z-index: 2; background: #fff; }
.is-admin .ql-snow.ql-toolbar button { width: 2.6rem; height: 2.6rem; min-height: 0; padding: .4rem; }
.is-admin .ql-snow .ql-picker { font-size: 1rem; height: 2.6rem; }
.is-admin .ql-snow .ql-picker-label { padding-top: .5rem; }
.is-admin .ql-editor { font-size: 1.15rem; min-height: 18rem; }
.is-admin #editor { min-height: 18rem; }

.login-box { max-width: 30rem; margin: 1rem auto; padding: 2rem; background: #fff; border: 1px solid var(--line); border-radius: 1rem; }
.login-box form.stack { max-width: none; }
.is-admin .ql-snow .ql-picker.ql-header { width: 11.5rem; }
.is-admin .ql-snow .ql-picker.ql-header .ql-picker-label::before,
.is-admin .ql-snow .ql-picker.ql-header .ql-picker-item::before { content: "Normaler Text"; }
.is-admin .ql-snow .ql-picker.ql-header .ql-picker-label[data-value="2"]::before,
.is-admin .ql-snow .ql-picker.ql-header .ql-picker-item[data-value="2"]::before { content: "Zwischenüberschrift"; }
.is-admin form.stack { max-width: none; }
.content .admin-thumb { display: block; max-width: 16rem; margin-bottom: .4rem; }
.content .admin-thumb-wide { max-width: 32rem; width: 100%; }

.footer-credit { order: 3; flex-basis: 100%; margin: 1.25rem 0 0; padding-top: .9rem; border-top: 1px solid rgb(255 255 255 / .15); font-size: .85rem; color: #d9b8bd; opacity: .85; }
.footer-inner { flex-wrap: wrap; }
