/* Design System & Variablen */
:root {
    --bg-main: #0B0F19;
    --bg-card: rgba(17, 24, 39, 0.75);
    --bg-card-hover: rgba(31, 41, 55, 0.85);
    --border-color: rgba(255, 255, 255, 0.08);
    --text-primary: #F3F4F6;
    --text-secondary: #9CA3AF;
    --accent-blue: #3B82F6;
    --accent-teal: #14B8A6;
    --accent-teal-glow: rgba(20, 184, 166, 0.15);
    --status-free: #10B981;
    --status-free-bg: rgba(16, 185, 129, 0.12);
    --status-taken: #EF4444;
    --status-taken-bg: rgba(239, 68, 68, 0.12);
    --status-closed: #4B5563;
    --status-closed-bg: rgba(75, 85, 99, 0.1);
    --font-main: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

body {
    background-color: var(--bg-main);
    color: var(--text-primary);
    font-family: var(--font-main);
    padding-top: 80px; /* Platz für die fixierte Navbar */
    min-height: 100vh;
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(59, 130, 246, 0.05) 0%, transparent 40%),
        radial-gradient(circle at 90% 80%, rgba(20, 184, 166, 0.05) 0%, transparent 40%);
    background-attachment: fixed;
}

/* Navbar Styling */
.navbar-custom {
    background-color: rgba(11, 15, 25, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.navbar-brand {
    font-weight: 700;
    letter-spacing: 0.5px;
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-teal));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.navbar-custom .nav-link {
    color: var(--text-secondary);
    font-weight: 500;
    transition: color 0.2s ease, transform 0.2s ease;
    cursor: pointer;
}

.navbar-custom .nav-link:hover,
.navbar-custom .nav-link.active {
    color: var(--text-primary);
}

/* Glassmorphism Cards */
.glass-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    padding: 24px;
    margin-bottom: 24px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.glass-card:hover {
    background: var(--bg-card-hover);
    border-color: rgba(255, 255, 255, 0.12);
}

/* Login View */
.login-container {
    max-width: 450px;
    margin: 80px auto;
}

.form-control-custom {
    background-color: rgba(0, 0, 0, 0.2) !important;
    border: 1px solid var(--border-color) !important;
    color: var(--text-primary) !important;
    border-radius: 10px !important;
    padding: 12px 16px !important;
    font-size: 1.1rem !important;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.form-control-custom:focus {
    border-color: var(--accent-teal) !important;
    box-shadow: 0 0 0 3px var(--accent-teal-glow) !important;
}

/* Buttons */
.btn-primary-custom {
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-teal));
    border: none;
    color: white;
    font-weight: 600;
    padding: 12px 24px;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.btn-primary-custom:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(20, 184, 166, 0.4);
}

.btn-secondary-custom {
    background-color: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    padding: 12px 24px;
    border-radius: 10px;
    transition: all 0.2s ease;
}

.btn-secondary-custom:hover {
    color: var(--text-primary);
    background-color: rgba(255, 255, 255, 0.05);
}

/* Kalender Styling */
.calendar-grid {
    display: grid;
    grid-template-columns: 40px repeat(7, 1fr);
    gap: 6px;
    text-align: center;
    margin-bottom: 20px;
}

.calendar-header {
    font-weight: 600;
    font-size: 0.85rem;
    color: var(--accent-blue);
    padding: 8px 0;
    border-bottom: 1px solid var(--border-color);
}

.calendar-kw {
    font-size: 0.8rem;
    color: var(--text-secondary);
    background-color: rgba(255, 255, 255, 0.03);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

.calendar-day {
    aspect-ratio: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    font-weight: 500;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid transparent;
    position: relative;
}

.calendar-day-num {
    z-index: 2;
}

.calendar-day.day-active {
    background-color: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.05);
}

.calendar-day.day-active:hover {
    background-color: var(--accent-teal-glow);
    border-color: var(--accent-teal);
    transform: scale(1.08);
}

.calendar-day.day-past {
    color: #374151;
    cursor: not-allowed;
}

.calendar-day.day-sunday {
    color: #ef4444;
    opacity: 0.3;
    cursor: not-allowed;
}

.calendar-day.day-holiday {
    color: #f97316;
    background-color: rgba(249, 115, 22, 0.08);
    border-color: rgba(249, 115, 22, 0.2);
    cursor: not-allowed;
}

.calendar-day.day-selected {
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-teal)) !important;
    color: white !important;
    border-color: transparent !important;
    box-shadow: 0 0 10px rgba(20, 184, 166, 0.4);
}

.calendar-title {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 15px;
    text-align: center;
    color: var(--text-primary);
}

/* Wochenansicht (Slots) */
.week-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr); /* Mo - Sa */
    gap: 12px;
}

@media (max-width: 991px) {
    .week-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 575px) {
    .week-grid {
        grid-template-columns: 1fr;
    }
}

.week-column {
    background-color: rgba(0, 0, 0, 0.15);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 12px;
}

.week-day-header {
    text-align: center;
    font-weight: 600;
    margin-bottom: 12px;
    padding-bottom: 6px;
    border-bottom: 1px solid var(--border-color);
}

.week-day-header .date-str {
    font-size: 0.8rem;
    color: var(--text-secondary);
    display: block;
    font-weight: 400;
}

.slots-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 400px;
    overflow-y: auto;
    padding-right: 4px;
}

/* Custom Scrollbar für Slots */
.slots-list::-webkit-scrollbar {
    width: 4px;
}
.slots-list::-webkit-scrollbar-track {
    background: transparent;
}
.slots-list::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
}

.slot-item {
    padding: 8px;
    border-radius: 8px;
    text-align: center;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    cursor: pointer;
    border: 1px solid transparent;
}

.slot-item.slot-free {
    background-color: var(--status-free-bg);
    color: var(--status-free);
    border-color: rgba(16, 185, 129, 0.2);
}

.slot-item.slot-free:hover {
    background-color: var(--status-free);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(16, 185, 129, 0.25);
}

.slot-item.slot-taken {
    background-color: var(--status-taken-bg);
    color: var(--status-taken);
    border-color: rgba(239, 68, 68, 0.2);
    cursor: not-allowed;
    opacity: 0.6;
}

.slot-item.slot-closed {
    background-color: var(--status-closed-bg);
    color: var(--status-closed);
    border-color: rgba(75, 85, 99, 0.2);
    cursor: not-allowed;
    opacity: 0.5;
    text-decoration: line-through;
}

/* Dashboard & Termin-Anzeige */
.booking-card {
    border-left: 5px solid var(--accent-teal);
}

.booking-details-grid {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 16px 24px;
    align-items: center;
    margin-top: 20px;
}

.booking-label {
    color: var(--text-secondary);
    font-weight: 500;
}

.booking-value {
    font-weight: 600;
    font-size: 1.1rem;
}

/* Modals */
.modal-content-custom {
    background-color: #111827 !important;
    border: 1px solid var(--border-color) !important;
    color: var(--text-primary) !important;
    border-radius: 16px !important;
}

.modal-header-custom {
    border-bottom: 1px solid var(--border-color) !important;
}

.modal-footer-custom {
    border-top: 1px solid var(--border-color) !important;
}

/* Print Styles */
@media print {
    body {
        background: white !important;
        color: black !important;
        padding-top: 0 !important;
    }
    .navbar, .btn, .no-print, #booking-view, #week-view {
        display: none !important;
    }
    .print-only {
        display: block !important;
    }
    .glass-card {
        background: none !important;
        border: none !important;
        box-shadow: none !important;
        color: black !important;
    }
    .booking-card {
        border-left: 5px solid black !important;
    }
    .booking-label {
        color: #555 !important;
    }
    .booking-value {
        color: black !important;
    }
}

.print-only {
    display: none;
}
