/* Custom CSS für Sign Application */

/* ========================================
   FORCE LIGHT MODE - 2026-01-12
   Prevents browser dark mode from affecting the UI
   ======================================== */
:root {
    color-scheme: light only;
}

html {
    color-scheme: light only;
}

/* ========================================
   GLOBAL BODY STYLES
   ======================================== */
body {
    margin: 0;
    font-family: Poppins, sans-serif;
    font-size: var(--bs-body-font-size);
    font-weight: var(--bs-body-font-weight);
    line-height: var(--bs-body-line-height);
    color: var(--bs-body-color);
    text-align: var(--bs-body-text-align);
    background-color: var(--bs-body-bg);
    -webkit-text-size-adjust: 100%;
    -webkit-tap-highlight-color: transparent;
}

/* ========================================
   MODAL SCROLL PREVENTION - CRITICAL FIX
   Der JavaScript-Handler in modal-scroll-fix.js speichert/restored die Scroll-Position
   Basierend auf: https://css-tricks.com/prevent-page-scrolling-when-a-modal-is-open/
   ======================================== */
html.modal-open,
body.modal-open {
    overflow: hidden !important;
}

/* Auch Wrapper-Container locken */
body.modal-open .main-content,
body.modal-open .container-fluid,
body.modal-open main {
    overflow: hidden !important;
}

/* Animationen */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes slideIn {
    from { transform: translateX(-100%); }
    to { transform: translateX(0); }
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* Allgemeine Styles */
.fade-in {
    animation: fadeIn 0.5s ease-out;
}

.slide-in {
    animation: slideIn 0.3s ease-out;
}

/* Hover-Effekte */
.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

/* Status-Badges */
.status-badge {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.85em;
    font-weight: 500;
}

.status-created {
    background-color: #fff3cd;
    color: #856404;
    border: 1px solid #ffeaa7;
}

.status-requested {
    background-color: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

.status-approved {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.status-rejected {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Tabellen */
.table-custom {
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.table-custom thead th {
    background: linear-gradient(135deg, #08344c 0%, #0056b3 100%);
    color: white;
    border: none;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.85em;
    letter-spacing: 0.5px;
}

.table-custom tbody tr {
    transition: all 0.3s ease;
}

.table-custom tbody tr:hover {
    background-color: #f8f9fa;
    transform: scale(1.01);
}

/* Formulare */
.form-floating {
    position: relative;
}

.form-floating > .form-control {
    height: calc(3.5rem + 2px);
    padding: 1rem 0.75rem;
}

.form-floating > label {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    padding: 1rem 0.75rem;
    pointer-events: none;
    border: 1px solid transparent;
    transform-origin: 0 0;
    transition: opacity 0.1s ease-in-out, transform 0.1s ease-in-out;
}

/* Buttons */
.btn-gradient {
    background: linear-gradient(135deg, #08344c 0%, #0056b3 100%);
    border: none;
    color: white;
    transition: all 0.3s ease;
}

.btn-gradient:hover {
    background: linear-gradient(135deg, #0056b3 0%, #08344c 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    color: white;
}

.btn-outline-gradient {
    border: 2px solid #08344c;
    color: #08344c;
    background: transparent;
    transition: all 0.3s ease;
}

.btn-outline-gradient:hover {
    background: linear-gradient(135deg, #08344c 0%, #0056b3 100%);
    color: white;
    transform: translateY(-2px);
}

/* Cards */
.card-hover {
    transition: all 0.3s ease;
    border: none;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.card-hover:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.card-gradient {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

/* Sidebar */
.sidebar-item {
    position: relative;
    overflow: hidden;
}

.sidebar-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.sidebar-item:hover::before {
    left: 100%;
}

/* Loading Spinner */
.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #08344c;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive */
@media (max-width: 768px) {
    .main-content {
        margin-left: 0;
        padding: 15px;
    }
    
    .stats-card {
        margin-bottom: 15px;
    }
    
    .login-card {
        margin: 20px;
        padding: 30px 20px;
    }
}

/* Signatur-Canvas */
.signature-canvas {
    border: 2px dashed #dee2e6;
    border-radius: 8px;
    cursor: crosshair;
    background-color: #fff;
    transition: border-color 0.3s ease;
}

.signature-canvas:hover {
    border-color: #08344c;
}

.signature-canvas.signing {
    border-color: #28a745;
    border-style: solid;
}

/* Signature Pad Container */
.signature-container {
    background: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.signature-controls {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 15px;
}

/* PDF Viewer */
.pdf-preview {
    border: 1px solid #dee2e6;
    border-radius: 8px;
    background: #f8f9fa;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Utility Classes */
.text-gradient {
    background: linear-gradient(135deg, #08344c 0%, #0056b3 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.shadow-custom {
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.shadow-hover {
    transition: box-shadow 0.3s ease;
}

.shadow-hover:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

/* Dark Mode Support */
/* Dark mode removed - 2026-01-12 */
