/**
 * Öffentliches Design des Schützenhaus-Portals.
 * Diese Datei ist bewusst eigenständig und kann später als Basis für die
 * Vereins-Hauptseite übernommen werden.
 */

:root {
    --vereins-gruen: #173f2b;
    --vereins-gruen-dunkel: #102f20;
    --vereins-gruen-hell: #245d40;
    --vereins-gold: #c8a42c;
    --hintergrund: #f3f5f3;
    --text: #1c2821;
    --text-hell: #6c766f;
    --linie: #dfe5e1;
    --ok-hintergrund: #e9f6ed;
    --ok-text: #23683a;
    --warn-hintergrund: #fff4d2;
    --warn-text: #705a15;
    --fehler-hintergrund: #fbeaea;
    --fehler-text: #94352e;
    --info-hintergrund: #eaf2f8;
    --info-text: #315e83;
    --footer-hoehe: 72px;
}

* {
    box-sizing: border-box;
}

html {
    min-height: 100%;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    padding-bottom: calc(var(--footer-hoehe) + 18px);
    background: var(--hintergrund);
    color: var(--text);
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input,
select,
textarea {
    font: inherit;
}

.wrap {
    width: min(1250px, calc(100% - 40px));
    margin: 0 auto;
}

/* Kopfbereich ----------------------------------------------------------- */
.site-header {
    background: linear-gradient(135deg, var(--vereins-gruen-dunkel), var(--vereins-gruen));
    color: #fff;
}

.site-header__inner {
    min-height: 78px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.brand__logo {
    width: 58px;
    height: 62px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
}

.brand__logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.brand__text strong {
    display: block;
    font-size: 15px;
}

.brand__text small {
    display: block;
    margin-top: 2px;
    opacity: .72;
}

.public-nav {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.public-nav a {
    padding: 9px 12px;
    border: 1px solid rgba(255, 255, 255, .16);
    border-radius: 9px;
}

.public-nav a:hover,
.public-nav a:focus-visible {
    background: rgba(255, 255, 255, .10);
}

.public-nav__login {
    border-color: rgba(200, 164, 44, .75) !important;
}

/* Hero / Hauptinhalt ---------------------------------------------------- */
.top,
.hero-section {
    background: linear-gradient(135deg, var(--vereins-gruen-dunkel), var(--vereins-gruen));
    color: #fff;
}

.hero {
    padding: 48px 0;
}

.hero h1 {
    margin: 0 0 14px;
    font-size: clamp(2.1rem, 5vw, 2.7rem);
    line-height: 1.05;
}

.hero p {
    max-width: 760px;
    margin-bottom: 0;
    color: #e3ede6;
    font-size: 18px;
    line-height: 1.55;
}

.main {
    padding: 28px 0 60px;
}

.legal-page {
    max-width: 920px;
    margin: 0 auto;
}

.legal-page h1,
.legal-page h2 {
    color: var(--vereins-gruen);
}

.legal-page h2 {
    margin-top: 28px;
}

.legal-page p,
.legal-page li {
    line-height: 1.65;
}

/* Karten, Formulare, Tabellen ------------------------------------------ */
.card {
    margin-bottom: 18px;
    overflow: hidden;
    background: #fff;
    border: 1px solid var(--linie);
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(23, 63, 43, .04);
}

.head {
    padding: 20px 22px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    border-bottom: 1px solid var(--linie);
}

.head h2,
.head h3 {
    margin: 0;
}

.body {
    padding: 22px;
}

.grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}

.grid2 {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.field label {
    display: block;
    margin-bottom: 6px;
    font-size: 13px;
    font-weight: 800;
}

.field input,
.field select,
.field textarea {
    width: 100%;
    padding: 11px 12px;
    background: #fff;
    border: 1px solid #ccd6cf;
    border-radius: 9px;
}

.field textarea {
    min-height: 90px;
    resize: vertical;
}

.btn {
    display: inline-block;
    padding: 11px 14px;
    border: 0;
    border-radius: 9px;
    background: var(--vereins-gruen-hell);
    color: #fff;
    font-weight: 800;
    cursor: pointer;
}

.btn.alt {
    background: #edf3ef;
    color: var(--vereins-gruen);
}

.btn.gold {
    background: var(--vereins-gold);
    color: #212813;
}

.btn.bad {
    background: #9d3932;
}

.btn:disabled {
    opacity: .45;
    cursor: not-allowed;
}

.modes {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 18px;
}

.modes a {
    padding: 17px;
    border: 1px solid var(--linie);
    border-radius: 12px;
}

.modes a.active {
    border: 2px solid var(--vereins-gruen-hell);
    background: #f2f7f4;
}

.modes b {
    display: block;
    margin-bottom: 4px;
}

.muted {
    color: var(--text-hell);
}

.small {
    font-size: 12px;
}

.notice {
    padding: 13px;
    margin: 12px 0;
    border-radius: 10px;
}

.notice.ok {
    background: var(--ok-hintergrund);
    color: var(--ok-text);
}

.notice.warn {
    background: var(--warn-hintergrund);
    color: var(--warn-text);
}

.notice.bad {
    background: var(--fehler-hintergrund);
    color: var(--fehler-text);
}

.notice.blue {
    background: var(--info-hintergrund);
    color: var(--info-text);
}

.tablewrap {
    overflow: auto;
}

.table {
    width: 100%;
    min-width: 760px;
    border-collapse: collapse;
}

.table th,
.table td {
    padding: 11px;
    border-bottom: 1px solid #edf0ee;
    text-align: left;
    vertical-align: top;
    font-size: 13px;
}

.table th {
    background: #f8faf8;
    color: var(--text-hell);
    font-size: 12px;
}

.pill {
    display: inline-block;
    padding: 5px 9px;
    border-radius: 999px;
    background: #edf3ef;
    font-size: 12px;
    font-weight: 800;
}

.pill.ok { background: var(--ok-hintergrund); color: var(--ok-text); }
.pill.warn { background: var(--warn-hintergrund); color: var(--warn-text); }
.pill.blue { background: var(--info-hintergrund); color: var(--info-text); }
.pill.bad { background: var(--fehler-hintergrund); color: var(--fehler-text); }

.actions {
    display: flex;
    gap: 7px;
    flex-wrap: wrap;
}

.right {
    text-align: right;
}

.login {
    max-width: 500px;
    margin: 50px auto;
}

/* Footer: fest am unteren Bildschirmrand ------------------------------- */
.site-footer,
.footer {
    position: fixed;
    z-index: 50;
    left: 0;
    right: 0;
    bottom: 0;
    min-height: var(--footer-hoehe);
    padding: 20px 0;
    background: #102b1d;
    color: #dce6df;
    font-size: 13px;
    box-shadow: 0 -4px 18px rgba(0, 0, 0, .08);
}

.site-footer__inner,
.footerflex {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.site-footer nav {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

@media (max-width: 900px) {
    .grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 680px) {
    :root {
        --footer-hoehe: 104px;
    }

    .site-header__inner {
        padding: 14px 0;
        align-items: flex-start;
        flex-direction: column;
    }

    .brand__logo {
        width: 50px;
        height: 54px;
    }

    .public-nav {
        width: 100%;
    }

    .public-nav a {
        padding: 8px 9px;
        font-size: 13px;
    }

    .grid,
    .grid2,
    .modes {
        grid-template-columns: 1fr;
    }

    .site-footer__inner {
        align-items: flex-start;
        flex-direction: column;
    }
}

/* Seitennavigation wie im internen Bereich */
.layout {
    display: flex;
    gap: 24px;
    align-items: flex-start;
}

.side {
    width: 220px;
    flex-shrink: 0;
    background: #ffffff;
    border: 1px solid #dcdcdc;
    border-radius: 8px;
    padding: 12px;
}

.side a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    color: #2c3e50;
    text-decoration: none;
    border-radius: 6px;
    margin-bottom: 4px;
    font-size: 0.95rem;
    font-weight: 500;
}

.side a .nav-icon {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 24px;
    text-align: center;
    flex-shrink: 0;
    font-size: 1.05rem;
}

.side a:hover {
    background: #f0f4f2;
}

.side a.active {
    background: #1b4d3e;
    color: #ffffff;
    font-weight: 600;
}

.layout > section {
    flex: 1;
    min-width: 0;
}

@media (max-width: 768px) {
    .layout {
        flex-direction: column;
    }
    .side {
        width: 100%;
    }
}

.card.legal-page,
.legal-page {
    max-width: none !important;
    margin: 0 !important;
    width: 100% !important;
}

header.top,
header.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
}

.layout {
    align-items: flex-start;
}

aside.side {
    position: sticky;
    top: 85px;
}