/* ===================================
   SALUS DIGITAL SIGNAGE - DISPLAY STYLES
   Zentrale Styles für alle Display-Seiten
   =================================== */

/* ===================================
   CSS CUSTOM PROPERTIES (CI-FARBEN)
   =================================== */
:root {
    /* Salus Corporate Colors */
    --primary-color: #398c8c;
    --primary-light: #5aa5a5;
    --primary-dark: #2d7070;
    --secondary-color: #eff6f6;
    
    /* Akzent-Farben für Schichten (Türkis-Basis) */
    --shift-early: #398c8c;
    /* Frühdienst - Original Türkis */
    --shift-late: #3d9999;
    /* Spätdienst - Etwas wärmer */
    --shift-night: #357a7a;
    /* Nachtdienst - Etwas kühler */
    --shift-day: #45b3b3;
    /* Tagesschicht - Heller */
    
    /* Text Colors */
    --text-primary: #1f2937;
    --text-secondary: #6b7280;
    --text-light: #9ca3af;
    
    /* Background Colors */
    --bg-white: #ffffff;
    --bg-light: #f9fafb;
    --bg-gray: #f3f4f6;
    
    /* Status Colors */
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    
    /* Spacing */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
    --spacing-2xl: 3rem;
    
    /* Border Radius */
    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    --radius-full: 9999px;
    
    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.15);
}

/* ===================================
   GLOBAL RESET & BASE STYLES
   =================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    background: linear-gradient(135deg, var(--primary-color) 0%, #2c7a7a 100%);
    color: var(--text-primary);
    overflow: hidden;
    height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ===================================
   HEADER
   =================================== */
.header {
    background: rgba(57, 140, 140, 0.95);
    padding: 1.5rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    width: 100%;
    transform: translateZ(0);
    will-change: transform;
}

.logo h1 {
    font-size: 2rem;
    font-weight: 300;
    letter-spacing: 1px;
    color: white;
}

.header-info {
    display: flex;
    align-items: center;
    gap: 2rem;
    font-size: 1.1rem;
}

.current-time {
    font-weight: 500;
    font-size: 1.3rem;
}

.current-date {
    opacity: 0.9;
}

/* ===================================
   MAIN CONTENT
   =================================== */
.main-content {
    flex: 1;
    padding: 2rem;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: var(--spacing-xl);
}

/* ===================================
   FOOTER
   =================================== */
.footer {
    background: rgba(57, 140, 140, 0.95);
    padding: 1rem 2rem;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    font-size: 0.9rem;
    width: 100%;
    transform: translateZ(0);
    will-change: transform;
}

/* ===================================
   ZURÜCK-BUTTON (ROTER VERTIKALER BUTTON)
   WICHTIG: EXAKT WIE IM ORIGINAL - NICHT ÄNDERN!
   =================================== */
.back-button {
    position: fixed;
    top: 50%;
    right: 2rem;
    transform: translateY(-50%) scale(0) translateZ(0);
    background: #dc2626;
    border: 2px solid rgba(220, 38, 38, 0.5);
    color: white;
    width: 50px;
    height: 250px;
    border-radius: 25px;
    font-size: 1.2rem;
    font-weight: 600;
    cursor: pointer;
    z-index: 1000;
    opacity: 0;
    transition: transform 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55), opacity 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.2rem;
    letter-spacing: 0.1rem;
    will-change: transform, opacity;
    /* Touch-Optimierung */
    user-select: none;
    -webkit-user-select: none;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

.back-button.show {
    opacity: 0.9;
    transform: translateY(-50%) scale(1) translateZ(0);
}

/* Hover nur für Maus-Geräte */
@media (hover: hover) {
.back-button:hover {
    opacity: 1;
        transform: translateY(-50%) scale(1.05) translateZ(0);
    background: #b91c1c;
    }
}

.back-button .letter {
    display: block;
    line-height: 1;
}

/* ===================================
   LOADING STATE
   =================================== */
.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-2xl);
    gap: var(--spacing-lg);
}

.loading-spinner {
    width: 60px;
    height: 60px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.loading-text {
    color: white;
    font-size: 1.2rem;
    font-weight: 500;
}

/* ===================================
   EMPTY STATE
   =================================== */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-2xl);
    text-align: center;
    color: white;
}

.empty-state-icon {
    font-size: 4rem;
    margin-bottom: var(--spacing-lg);
    opacity: 0.6;
}

.empty-state h2 {
    font-size: 2rem;
    font-weight: 300;
    margin-bottom: var(--spacing-md);
}

.empty-state p {
    font-size: 1.2rem;
    opacity: 0.8;
    max-width: 600px;
}

/* ===================================
   RESPONSIVE DESIGN
   =================================== */
@media (max-width: 768px) {
    .header {
        padding: 1rem;
        flex-direction: column;
        gap: 1rem;
    }
    
    .header-info {
        flex-direction: column;
        gap: 0.5rem;
        font-size: 1rem;
    }
    
    .main-content {
        padding: 1rem;
    }
}

/* Touch-optimized (Original-Verhalten) */
@media (pointer: coarse) {
    .back-button {
        width: 70px;
        height: 70px;
    }
}