/* Grundgestaltung */

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    background-color: #f1f4f7;
    color: #333333;
    line-height: 1.6;
}


/* Kopfbereich */

header {
    position: relative;
    overflow: hidden;
    padding: 60px 20px;
    background:
        linear-gradient(
            135deg,
            #00284d,
            #0055a5
        );
    color: white;
    text-align: center;
}

header::after {
    position: absolute;
    right: -80px;
    bottom: -120px;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.06);
    content: "";
}

header h1 {
    position: relative;
    z-index: 1;
    max-width: 950px;
    margin: 0 auto 16px;
    font-size: 42px;
    line-height: 1.2;
}

header h2 {
    position: relative;
    z-index: 1;
    margin: 10px 0;
    font-size: 24px;
    font-weight: normal;
    line-height: 1.5;
    color: white;
}

header p {
    position: relative;
    z-index: 1;
    max-width: 750px;
    margin: 30px auto 0;
    font-size: 20px;
    font-style: italic;
}


/* Navigation */

nav {
    position: sticky;
    top: 0;
    z-index: 10;
    padding: 14px;
    background-color: white;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.14);
}

nav a {
    display: inline-block;
    margin: 5px 20px;
    color: #003366;
    font-size: 18px;
    font-weight: bold;
    text-decoration: none;
}

nav a:hover {
    color: #0066cc;
    text-decoration: underline;
}


/* Hauptinhalt */

main {
    max-width: 1150px;
    margin: 40px auto;
    padding: 35px;
    border-radius: 14px;
    background-color: white;
    box-shadow: 0 5px 18px rgba(0, 0, 0, 0.09);
}

section {
    margin-bottom: 45px;
}

section:last-child {
    margin-bottom: 0;
}

h2,
section h2 {
    color: #003366;
}

h3 {
    color: #004c99;
}


/* Begrüßungsbereich */

.willkommen-bereich {
    padding: 10px 5px 35px;
    border-bottom: 1px solid #dce3e9;
    text-align: center;
}

.willkommen-bereich h2 {
    margin-top: 0;
    font-size: 32px;
}

.willkommen-bereich p {
    max-width: 820px;
    margin-right: auto;
    margin-left: auto;
    font-size: 18px;
}

.hauptbutton {
    display: inline-block;
    margin-top: 18px;
    padding: 13px 28px;
    border-radius: 8px;
    background-color: #0066cc;
    color: white;
    font-size: 17px;
    font-weight: bold;
    text-decoration: none;
    box-shadow: 0 4px 10px rgba(0, 70, 140, 0.2);
}

.hauptbutton:hover {
    background-color: #004c99;
}


/* Schulbilder */

.schulen-bereich {
    padding-top: 5px;
}

.abschnitt-kopf {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 28px;
    text-align: left;
}

.abschnitt-kopf h2 {
    margin: 0;
    font-size: 30px;
}

.abschnitt-kopf p {
    margin: 5px 0 0;
    color: #555555;
}

.abschnitt-symbol {
    font-size: 42px;
}

.schulbilder {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px;
}

.schulkarte {
    overflow: hidden;
    margin: 0;
    border: 1px solid #d6dee5;
    border-radius: 12px;
    background-color: white;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.1);
    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.schulkarte:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.14);
}

.schulkarte img {
    display: block;
    width: 100%;
    height: 230px;
    object-fit: cover;
}

.schulkarte figcaption {
    min-height: 125px;
    padding: 18px;
    text-align: center;
}

.schulkarte strong {
    display: block;
    margin-bottom: 8px;
    color: #003366;
    font-size: 18px;
}

.schulkarte span {
    display: block;
    color: #555555;
    font-size: 15px;
}


/* Hinweisbereich */

.hinweise-bereich {
    padding: 25px;
    border-left: 5px solid #0066cc;
    border-radius: 8px;
    background-color: #f1f7fd;
}

.hinweise-bereich h2 {
    margin-top: 0;
}


/* Formulare */

form {
    max-width: 700px;
}

label {
    font-weight: bold;
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="password"],
select,
textarea {
    width: 100%;
    margin-top: 6px;
    padding: 12px;
    border: 1px solid #aab4bd;
    border-radius: 6px;
    background-color: white;
    font-family: inherit;
    font-size: 16px;
}

textarea {
    min-height: 110px;
    resize: vertical;
}

input[type="radio"],
input[type="checkbox"] {
    margin-right: 8px;
}

input:focus,
select:focus,
textarea:focus {
    border-color: #0066cc;
    outline: 3px solid rgba(0, 102, 204, 0.15);
}


/* Allgemeine Buttons */

button {
    margin-top: 20px;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    background-color: #0066cc;
    color: white;
    font-size: 17px;
    cursor: pointer;
}

button:hover {
    background-color: #004c99;
}


/* Kopf des Verwaltungsbereichs */

.verwaltung-kopf {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 30px;
}

.verwaltung-kopf h2 {
    margin: 0;
}

.verwaltung-kopf button {
    margin-top: 0;
}


/* Dashboard-Karten */

.dashboard {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    margin: 25px 0 40px;
}

.dashboard-karte {
    min-height: 135px;
    padding: 22px 18px;
    border: 1px solid #dce3e9;
    border-radius: 12px;
    background-color: #f8fafc;
    text-align: center;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
}

.dashboard-symbol {
    display: block;
    margin-bottom: 5px;
    font-size: 30px;
}

.dashboard-zahl {
    display: block;
    color: #003366;
    font-size: 34px;
    font-weight: bold;
}

.dashboard-text {
    display: block;
    margin-top: 4px;
    color: #555555;
    font-size: 16px;
}


/* Suchfeld */

.suchbereich {
    max-width: 500px;
    margin-bottom: 20px;
}


/* Tabellen */

.tabellen-container {
    width: 100%;
    overflow-x: auto;
}

table {
    width: 100%;
    min-width: 850px;
    margin-top: 20px;
    border-collapse: collapse;
}

th {
    padding: 12px;
    background-color: #003366;
    color: white;
    text-align: left;
    white-space: nowrap;
}

td {
    padding: 10px;
    border-bottom: 1px solid #cccccc;
    vertical-align: middle;
}

tbody tr:nth-child(even) {
    background-color: #f7f9fb;
}

tbody tr:hover {
    background-color: #edf5ff;
}


/* Zahlungsbuttons */

.zahlung-ja,
.zahlung-nein {
    min-width: 64px;
    margin: 0;
    padding: 7px 12px;
    border-radius: 6px;
    color: white;
    font-size: 15px;
}

.zahlung-ja {
    background-color: #28a745;
}

.zahlung-ja:hover {
    background-color: #218838;
}

.zahlung-nein {
    background-color: #dc3545;
}

.zahlung-nein:hover {
    background-color: #c82333;
}


/* Bemerkungs- und Löschen-Button */

.bemerkung-button,
.loeschen-button {
    margin: 0;
    padding: 5px 8px;
    border: none;
    background: none;
    font-size: 21px;
    cursor: pointer;
}

.bemerkung-button:hover,
.loeschen-button:hover {
    background: none;
    transform: scale(1.2);
}


/* Darstellung auf Tablets */

@media (max-width: 900px) {
    .schulbilder {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .schulkarte:last-child {
        grid-column: 1 / -1;
        width: calc(50% - 11px);
        justify-self: center;
    }
}


/* Darstellung auf kleineren Bildschirmen */

@media (max-width: 800px) {
    header {
        padding: 40px 15px;
    }

    header h1 {
        font-size: 32px;
    }

    header h2 {
        font-size: 20px;
    }

    main {
        margin: 20px 12px;
        padding: 22px;
    }

    .dashboard {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .verwaltung-kopf {
        align-items: flex-start;
        flex-direction: column;
    }

    nav {
        position: static;
    }

    nav a {
        margin: 6px 10px;
    }

    .willkommen-bereich h2 {
        font-size: 27px;
    }
}


/* Darstellung auf Handys */

@media (max-width: 600px) {
    .schulbilder {
        grid-template-columns: 1fr;
    }

    .schulkarte:last-child {
        grid-column: auto;
        width: 100%;
    }

    .schulkarte img {
        height: 220px;
    }

    .abschnitt-kopf {
        align-items: flex-start;
    }
}

@media (max-width: 500px) {
    header h1 {
        font-size: 27px;
    }

    header p {
        font-size: 17px;
    }

    .dashboard {
        grid-template-columns: 1fr;
    }

    button {
        width: 100%;
    }

    .zahlung-ja,
    .zahlung-nein,
    .bemerkung-button,
    .loeschen-button {
        width: auto;
    }

    .hauptbutton {
        width: 100%;
        text-align: center;
    }
}
/* Datenschutzhinweise */

.datenschutz-box {
    margin-top: 25px;
    padding: 18px;
    background: #f7f9fc;
    border: 1px solid #d7dde8;
    border-radius: 10px;
    line-height: 1.6;
}

.datenschutz-box label {
    display: block;
    cursor: pointer;
}

.datenschutz-box input[type="checkbox"] {
    margin-right: 10px;
    transform: scale(1.15);
}

.datenschutz-box a {
    color: #0b4a8b;
    font-weight: bold;
    text-decoration: none;
}

.datenschutz-box a:hover {
    text-decoration: underline;
}
/* ===========================
   Footer
=========================== */

footer {
    margin-top: 50px;
    padding: 25px 20px;
    background: #0b4a8b;
    color: white;
    text-align: center;
}

footer p {
    margin: 8px 0;
}

footer a {
    color: white;
    text-decoration: none;
    font-weight: bold;
}

footer a:hover {
    text-decoration: underline;
}