/* ===========================
   Grundlayout
   =========================== */

body {
    font-family: system-ui, Arial, sans-serif;
    background: #f4f4f4;
    margin: 0;
    padding: 0;
    color: #222;
}

/* ===========================
   Header & Navigation
   =========================== */

header {
    background: #003366;
    color: white;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}
/* ===========================
   Logo
   =========================== */

.logo-container {
    float: left;
    display: flex;
    align-items: center;
}

.logo {
    height: 48px;        /* Desktop */
    width: auto;
    margin-right: 15px;
}

.app-title {
    font-size: 1.4rem;
    font-weight: bold;
    color: white;
    margin-left: 10px;
}

/* Mobile Logo kleiner */
@media (max-width: 600px) {
    .logo {
        height: 36px;
    }
    .app-title {
        font-size: 1.1rem;
    }
}

header strong {
    font-size: 1.3rem;
}

nav {
    display: flex;
    gap: 15px;
}

nav a {
    color: white;
    text-decoration: none;
    font-weight: bold;
    padding: 6px 10px;
    border-radius: 4px;
}

nav a:hover,
nav a.active {
    background: rgba(255,255,255,0.2);
}

/* Mobile Navigation */
@media (max-width: 600px) {
    nav {
        width: 100%;
        justify-content: flex-start;
        flex-wrap: wrap;
        margin-top: 10px;
    }
}

/* ===========================
   Main Content
   =========================== */

main {
    padding: 20px;
}

/* ===========================
   Tabellen
   =========================== */

table {
    width: 100%;
    border-collapse: collapse;
    background: white;
}

th, td {
    padding: 10px;
    border-bottom: 1px solid #ccc;
}

th {
    background: #e6eef5;
    text-align: left;
}

tr:hover {
    background: #f0f6fc;
}

/* Mobile Tabellen */
@media (max-width: 700px) {
    table, thead, tbody, th, td, tr {
        display: block;
    }

    tr {
        margin-bottom: 15px;
        background: white;
        padding: 10px;
        border-radius: 6px;
    }

    th {
        display: none;
    }

    td {
        display: flex;
        justify-content: space-between;
        padding: 6px 0;
    }

    td::before {
        content: attr(data-label);
        font-weight: bold;
        color: #003366;
    }
}

/* ===========================
   Formulare
   =========================== */

input[type="text"],
input[type="email"],
input[type="password"],
select {
    width: 100%;
    padding: 8px;
    border: 1px solid #bbb;
    border-radius: 4px;
    margin-top: 4px;
    margin-bottom: 12px;
    background: white;
}

button {
    background: #003366;
    color: white;
    padding: 10px 16px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

button:hover {
    background: #00264d;
}

/* ===========================
   Zweispaltige Formulare
   =========================== */

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px 40px; /* vertikal / horizontal */
    margin-bottom: 20px;
}

.form-grid label {
    font-weight: bold;
    margin-bottom: 4px;
    display: block;
}

.form-grid .form-field {
    display: flex;
    flex-direction: column;
}

/* Mobile: einspaltig */
@media (max-width: 700px) {
    .form-grid {
        grid-template-columns: 1fr;
    }
}

/* ===========================
   Meldungen
   =========================== */

.alert-error {
    background: #ffdddd;
    border-left: 4px solid #cc0000;
    padding: 10px;
    margin-bottom: 15px;
}

.alert-success {
    background: #ddffdd;
    border-left: 4px solid #009900;
    padding: 10px;
    margin-bottom: 15px;
}

/* ===========================
   Footer
   =========================== */

footer {
    background: #e0e0e0;
    padding: 10px 20px;
    text-align: center;
    font-size: 0.9em;
    color: #555;
    margin-top: 30px;
}
