/* ---------------------------------------------------
   GLOBAL
--------------------------------------------------- */

html, body {
    height: 100%;
}

body {
    margin: 0;
    padding: 0;
    font-family: Arial, sans-serif;
    background: #f2f2f2;
    color: #000;

    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

main {
    padding: 20px;
    min-height: 60vh;
}

/* ---------------------------------------------------
   HEADER (Farben/Bild kommen aus DB per inline-style)
--------------------------------------------------- */

.site-header {
    background-size: cover;
    background-position: center;
    text-align: center;
    padding: 30px 20px;
}

.site-header h1 {
    margin: 0;
    padding-bottom: 10px;
}

/* HEADER NAVIGATION */
.site-nav ul {
    list-style: none;
    margin: 15px 0 0 0;
    padding: 0;
    display: flex;
    gap: 20px;
    justify-content: center;
}

.site-nav li {
    display: inline-block;
}

.site-nav a {
    text-decoration: none;
    font-weight: bold;
    transition: opacity 0.2s ease;
}

.site-nav a:hover {
    opacity: 0.7;
}

/* ---------------------------------------------------
   FOOTER (Farben/Bild kommen aus DB per inline-style)
--------------------------------------------------- */

.site-footer {
    background-size: cover;
    background-position: center;
    padding: 20px;
    text-align: center;
    margin-top: auto; /* Footer immer unten */
}

/* FOOTER NAVIGATION */
.footer-nav ul {
    list-style: none;
    margin: 0 0 10px 0;
    padding: 0;
    display: flex;
    gap: 15px;
    justify-content: center;
}

.footer-nav li {
    display: inline-block;
}

.footer-nav a {
    text-decoration: none;
    font-weight: bold;
    transition: opacity 0.2s ease;
}

.footer-nav a:hover {
    opacity: 0.7;
}

/* ---------------------------------------------------
   SIDEBAR (Frontend)
--------------------------------------------------- */

/* Toggle Button */
.sidebar-toggle {
    position: fixed;
    top: 15px;
    left: 15px;
    z-index: 2000;
    background: #007bff;
    color: #fff;
    border: none;
    padding: 12px 14px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 20px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.25);
}

.sidebar-toggle:active {
    transform: scale(0.95);
}

/* Sidebar START eingeklappt */
.site-sidebar {
    position: fixed;
    top: 0;
    left: -260px;
    width: 260px;
    height: 100vh;
    background: #222;
    color: #fff;
    padding: 25px 20px;
    box-sizing: border-box;
    transition: left 0.25s ease;
    z-index: 1500;
    overflow-y: auto;
}

.site-sidebar.expanded {
    left: 0;
}

.site-sidebar h2 {
    text-align: center;
    margin-top: 0;
    margin-bottom: 25px;
    font-size: 24px;
}

.site-sidebar a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    margin-bottom: 10px;
    color: #fff;
    text-decoration: none;
    border-radius: 8px;
    background: rgba(255,255,255,0.08);
    transition: background 0.15s ease;
}

.site-sidebar a:hover {
    background: rgba(255,255,255,0.18);
}

.site-sidebar a:active {
    background: rgba(255,255,255,0.25);
}

/* ---------------------------------------------------
   CONTENT BEREICH
--------------------------------------------------- */

.site-content {
    margin-left: 40px;
    padding: 40px;
    text-align: center;
    transition: 0.3s ease;
    flex: 1;
}

.site-sidebar.expanded ~ .site-content {
    margin-left: 260px;
}

/* ---------------------------------------------------
   RESPONSIVE (SMARTPHONE)
--------------------------------------------------- */

@media (max-width: 600px) {

    /* Header & Footer Navigation einspaltig */
    .site-nav ul,
    .footer-nav ul {
        flex-direction: column;
        gap: 10px;
    }

    /* Content */
    .site-content {
        margin-left: 0;
        padding: 20px;
    }

    /* Sidebar */
    .site-sidebar {
        width: 240px;
        padding: 20px 15px;
    }

    .site-sidebar h2 {
        font-size: 22px;
    }

    .site-sidebar a {
        font-size: 18px;
        padding: 12px;
    }

    /* Toggle Button */
    .sidebar-toggle {
        left: 10px;
        top: 10px;
        padding: 10px 12px;
        font-size: 18px;
    }
}
