/* ======================== */
/* Allgemeine Stile */
/* ======================== */
body {
    font-family: Arial, sans-serif;
    background-color: #f4f4f4;
    margin: 0;
    padding: 0;
    text-align: center;
}

/* ======================== */
/* Haupt-Container */
/* ======================== */
.container {
    max-width: 90%;
    background: white;
    margin: 50px auto;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    position: relative;
}

/* ======================== */
/* Logout-Button */
/* ======================== */
.logout {
    position: absolute;
    top: 10px;
    right: 10px;
    text-decoration: none;
    color: white;
    background-color: #dc3545;
    padding: 8px 15px;
    border-radius: 5px;
}

.logout:hover {
    background-color: #c82333;
}

/* ======================== */
/* Login-Box */
/* ======================== */
.login-box {
    width: 350px;
    margin: 100px auto;
    padding: 20px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.login-box h2 {
    margin-bottom: 20px;
    color: #333;
}

/* Login-Felder */
.login-box input {
    width: calc(100% - 20px);
    padding: 10px;
    margin-bottom: 10px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 16px;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

/* Login-Button */
.login-box button {
    width: 100%;
    padding: 10px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
}

.login-box button:hover {
    background-color: #0056b3;
}

/* Registrierung-Link */
.register-link {
    margin-top: 15px;
    display: block;
    color: #007bff;
    text-decoration: none;
}

.register-link:hover {
    text-decoration: underline;
}

/* ======================== */
/* Neuen Eintrag erfassen */
/* ======================== */
.entry-button {
    display: block;
    margin: 20px auto;
    padding: 10px 15px;
    background-color: #28a745;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    text-align: center;
    width: fit-content;
}

.entry-button:hover {
    background-color: #218838;
}

/* Formular für Neuen Eintrag */
#weightForm {
    display: none;
    margin-top: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 5px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

/* Formularfelder */
#weightForm label {
    font-weight: bold;
    text-align: left;
}

#weightForm input {
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 16px;
}

/* Formular-Button */
#weightForm button {
    background-color: #28a745;
    color: white;
    cursor: pointer;
    border: none;
    font-size: 16px;
    font-weight: bold;
    padding: 10px 15px;
    border-radius: 5px;
}

#weightForm button:hover {
    background-color: #218838;
}

/* ======================== */
/* Tabelle */
/* ======================== */
table {
    width: 100%;
    margin-top: 20px;
    border-collapse: collapse;
    table-layout: fixed;
    border: 1px solid #ddd;
}

/* Tabellenzellen */
th, td {
    padding: 10px;
    border: 1px solid #ddd;
    text-align: center;
    font-size: 16px;
}

/* Monatsüberschriften */
tr.month-header th {
    background-color: #007bff;
    color: white;
    text-align: center;
    font-size: 18px;
    padding: 10px;
    width: 100%;
    border: 1px solid #ddd;
}

/* ======================== */
/* Veränderung: Farben für + und - */
/* ======================== */
.green {
    color: green;
    font-weight: bold;
}

.red {
    color: red;
    font-weight: bold;
}

/* ======================== */
/* Mobile Optimierung */
/* ======================== */
@media (max-width: 600px) {
    .container {
        width: 90%;
        padding: 15px;
    }

    table {
        font-size: 14px;
    }

    th, td {
        padding: 8px;
    }

    .entry-button {
        font-size: 14px;
        padding: 8px 12px;
    }

    .login-box {
        width: 90%;
    }
}










/* Standard-Tabellenstil für Desktop */
table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed; /* Gleichmäßige Spaltenverteilung */
}

td, th {
    padding: 10px;
    text-align: center;
    font-size: 16px;
    word-wrap: break-word;
}

/* Mobile Optimierung */
@media screen and (max-width: 768px) {
    td, th {
        font-size: 8px; /* Kleinere Schrift auf Mobilgeräten */
        padding: 10px;
    }

    .month-header th {
        font-size: 10px; /* Monatsüberschrift größer als der Rest */
    }

    /* Datum mit Wochentag kleiner */
    td:first-child {
        font-size: 8px;
    }

    /* Verhindert, dass die Tabelle den Bildschirm überläuft */
    .container {
        overflow-x: auto;
    }

    table {
        display: block;
        width: 100%;
        overflow-x: auto;
    }
}







/* Standardmäßig Desktop-Version anzeigen */
.desktop-only {
    display: inline;
}

.mobile-only {
    display: none;
}

/* Mobile Optimierung: Kürzere Wochentage */
@media screen and (max-width: 768px) {
    .desktop-only {
        display: none;
    }

    .mobile-only {
        display: inline;
    }
}





.archive-section {
    text-align: center;
    margin-top: 20px;
}

.archive-button {
    display: inline-block;
    margin: 5px;
    padding: 8px 12px;
    background: #007bff;
    color: white;
    text-decoration: none;
    border-radius: 5px;
}

.archive-button:hover {
    background: #0056b3;
}

/* Blauer "Zurück zur aktuellen Übersicht"-Button */
/* Kleinere Button-Größe für "Zurück zur aktuellen Übersicht" */
.blue-button {
    background: #007bff !important;
    color: white !important;
    font-size: 14px; /* Kleinere Schriftgröße */
    padding: 6px 12px; /* Weniger Polsterung */
    border-radius: 4px; /* Abgerundete Ecken */
    display: inline-block;
    text-decoration: none;
    width: fit-content; /* Breite passt sich dem Inhalt an */
    min-width: 120px; /* Mindestbreite, damit es nicht zu klein wird */
    text-align: center;
    margin: 10px auto; /* Zentriert den Button */
}

.blue-button:hover {
    background: #0056b3 !important;
}


select {
    width: 100%;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 16px;
}

select:focus {
    border-color: #007bff;
    outline: none;
}