* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: radial-gradient(circle at top, #f7e9ff, #fdf6ec);
    min-height: 100vh;
    display: flex;
    align-items: stretch;
    justify-content: center;
}

/* Passwort-Screen */
.lock-screen {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
}

.lock-card {
    background: #ffffffee;
    padding: 2rem 2.5rem;
    border-radius: 1.5rem;
    max-width: 400px;
    width: 100%;
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.12);
    text-align: center;
}

.lock-card h1 {
    margin-top: 0;
    margin-bottom: 0.75rem;
}

.lock-card p {
    margin-top: 0;
    margin-bottom: 1.5rem;
}

.lock-card form {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.lock-card input[type="password"] {
    padding: 0.75rem 1rem;
    border-radius: 999px;
    border: 1px solid #d0c5f0;
    font-size: 1rem;
}

.lock-card button {
    padding: 0.75rem 1rem;
    border-radius: 999px;
    border: none;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    background: #7a4cff;
    color: white;
    transition: transform 0.08s ease, box-shadow 0.08s ease, background 0.2s ease;
    box-shadow: 0 8px 20px rgba(122, 76, 255, 0.4);
}

.lock-card button:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 28px rgba(122, 76, 255, 0.45);
}

.lock-card button:active {
    transform: translateY(0);
    box-shadow: 0 5px 14px rgba(122, 76, 255, 0.4);
}

.error-msg {
    color: #c0392b;
    min-height: 1.2em;
    font-size: 0.9rem;
}

/* Kalenderbereich */
.calendar {
    display: none;
    /* wird per JS auf flex gesetzt */
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding: 1.5rem;
    width: 100%;
}

.calendar header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.calendar-grid {
    width: 100%;
    max-width: 600px;
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 0.75rem;
}

/* Kacheln */
.day-tile {
    position: relative;
    border: none;
    border-radius: 1rem;
    padding: 1.1rem 0;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    background: #ffffffcc;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
    backdrop-filter: blur(8px);
    transition: transform 0.08s ease, box-shadow 0.08s ease, background 0.2s ease;
}

.day-tile:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.16);
    background: #fffdf7;
}

.day-tile:active:not(:disabled) {
    transform: translateY(0);
    box-shadow: 0 5px 12px rgba(0, 0, 0, 0.14);
}

.day-tile:disabled {
    cursor: default;
    opacity: 0.6;
    background: #e0dde8;
    box-shadow: none;
}

.day-locked::after {
    content: "🔒";
    position: absolute;
    right: 0.45rem;
    top: 0.35rem;
    font-size: 0.9rem;
}

.bildcontainer img {
    width: 80%;
    height: auto;
    /* verhindert Verzerrung */
    display: block;
    /* optional, entfernt kleine Lücke unter dem Bild */
    margin: 0 auto;
    /* optional, zentriert das Bild */
}

/* Responsiv */
@media (max-width: 600px) {
    .calendar-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

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