/* Laboratory Management System - Custom Styles */

:root {
    --primary-color: #0066cc;
    --secondary-color: #6c757d;
    --success-color: #28a745;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #17a2b8;
    --light-color: #f8f9fa;
    --dark-color: #343a40;
}

body {
    background-color: #f8f9fa;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.navbar-brand {
    font-weight: 600;
}

.sidebar {
    min-height: 100vh;
    background-color: #fff;
    border-right: 1px solid #dee2e6;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

.main-content {
    padding: 20px;
}

.card {
    border: none;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    border-radius: 10px;
}

.card-header {
    background-color: var(--primary-color);
    color: white;
    border-radius: 10px 10px 0 0 !important;
    font-weight: 600;
}

.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background-color: #0052a3;
    border-color: #0052a3;
}

/* Status badges */
.badge-success {
    background-color: var(--success-color);
}

.badge-danger {
    background-color: var(--danger-color);
}

.badge-warning {
    background-color: var(--warning-color);
}

.badge-secondary {
    background-color: var(--secondary-color);
}

/* Equipment status indicators */
.status-usable {
    color: var(--success-color);
}

.status-damaged {
    color: var(--danger-color);
}

.status-maintenance {
    color: var(--warning-color);
}

.status-unavailable {
    color: var(--secondary-color);
}

/* Dashboard cards */
.dashboard-card {
    background: linear-gradient(135deg, #b45309 0%, #d97706 100%);
    color: white;
    border-radius: 12px;
    padding: 25px 30px;
    margin-bottom: 15px;
    min-height: 140px;
    display: flex;
    align-items: center;
    width: 100%;
}

.dashboard-card.equipment {
    background: linear-gradient(135deg, #dc2626 0%, #ef4444 100%);
}

.dashboard-card.inventory {
    background: linear-gradient(135deg, #059669 0%, #10b981 100%);
}

.dashboard-card.maintenance {
    background: linear-gradient(135deg, #7c3aed 0%, #8b5cf6 100%);
}

/* University-themed variations */
.dashboard-card.university-gold {
    background: linear-gradient(135deg, #eab308 0%, #fbbf24 100%);
}

.dashboard-card.university-amber {
    background: linear-gradient(135deg, #d97706 0%, #f59e0b 100%);
}

.dashboard-card.university-bronze {
    background: linear-gradient(135deg, #92400e 0%, #a16207 100%);
}

/* Additional color variations for diverse stat cards */
.dashboard-card.teal {
    background: linear-gradient(135deg, #0d9488 0%, #14b8a6 100%);
}

.dashboard-card.indigo {
    background: linear-gradient(135deg, #4338ca 0%, #6366f1 100%);
}

.dashboard-card.rose {
    background: linear-gradient(135deg, #e11d48 0%, #f43f5e 100%);
}

.dashboard-card.emerald {
    background: linear-gradient(135deg, #047857 0%, #059669 100%);
}

.dashboard-card.orange {
    background: linear-gradient(135deg, #ea580c 0%, #fb923c 100%);
}

.dashboard-card.slate {
    background: linear-gradient(135deg, #475569 0%, #64748b 100%);
}

.dashboard-card.cyan {
    background: linear-gradient(135deg, #0891b2 0%, #06b6d4 100%);
}

.dashboard-card h1,
.dashboard-card h2 {
    font-size: 3.2rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: white;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.dashboard-card h3 {
    font-size: 2.8rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: white;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.dashboard-card h5 {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.dashboard-card p {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 5px;
    color: white;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.dashboard-card p.small {
    font-size: 1.1rem;
    font-weight: 500;
    color: white;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.dashboard-card small.text-muted {
    color: rgba(255, 255, 255, 0.9) !important;
    font-size: 0.95rem;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* Card body text adjustments */
.dashboard-card .card-body {
    font-size: 1.2rem;
}

.dashboard-card .card-body h3 {
    font-size: 2.8rem;
    font-weight: 700;
    color: white;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.dashboard-card .card-body h5 {
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    font-size: 1.8rem;
}

.dashboard-card .card-body p {
    font-size: 1.3rem;
    font-weight: 500;
    color: white;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.dashboard-card .card-body small {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.9);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* Quick Action Cards */
.quick-action-card {
    text-decoration: none !important;
    color: white !important;
    display: block;
    transition: all 0.3s ease;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
}

.quick-action-card:hover,
.quick-action-card:focus,
.quick-action-card:active,
.quick-action-card:visited {
    text-decoration: none !important;
    color: white !important;
    outline: none;
}

.quick-action-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
}

.quick-action-card:active {
    transform: translateY(-2px);
}

.quick-action-card .dashboard-card {
    margin-bottom: 0;
    height: 100%;
    min-height: 120px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.quick-action-card .dashboard-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0);
    transition: background 0.3s ease;
    pointer-events: none;
}

.quick-action-card:hover .dashboard-card::before {
    background: rgba(255, 255, 255, 0.15);
}

.quick-action-card .dashboard-card .card-body {
    padding: 1.5rem;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    position: relative;
    z-index: 1;
}

/* Enhanced text contrast and styling */
.quick-action-card .dashboard-card h6 {
    font-size: 1.3rem;
    font-weight: 700;
    margin: 0;
    line-height: 1.2;
    color: white !important;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    letter-spacing: 0.5px;
}

.quick-action-card .dashboard-card small {
    color: rgba(255, 255, 255, 0.95) !important;
    font-size: 1rem;
    font-weight: 500;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    margin-top: 4px;
}

.quick-action-card .dashboard-card i {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
    color: white !important;
    opacity: 0.95;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

/* Tables */
.table {
    background-color: white;
}

.table thead th {
    background-color: var(--light-color);
    border-bottom: 2px solid var(--primary-color);
    font-weight: 600;
}

/* QR Code display */
.qr-code-display {
    text-align: center;
    padding: 20px;
}

.qr-code-display img {
    max-width: 200px;
    border: 2px solid var(--primary-color);
    border-radius: 10px;
}

/* Form styles */
.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(0, 102, 204, 0.25);
}

.form-label {
    font-weight: 600;
    color: var(--dark-color);
}

/* Login page styles */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.login-card {
    background: white;
    border-radius: 15px;
    padding: 40px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    width: 100%;
    max-width: 400px;
}

.login-logo {
    text-align: center;
    margin-bottom: 30px;
}

.login-logo i {
    font-size: 3rem;
    color: var(--primary-color);
}

/* Responsive design */
@media (max-width: 1200px) {
    .dashboard-card h1,
    .dashboard-card h2,
    .dashboard-card h3 {
        font-size: 2.2rem;
    }
    
    .dashboard-card p {
        font-size: 1rem;
    }
    
    .dashboard-card small {
        font-size: 0.8rem;
    }
}

@media (max-width: 768px) {
    .dashboard-card {
        padding: 15px;
        min-height: 120px;
    }
    
    .dashboard-card h1,
    .dashboard-card h2,
    .dashboard-card h3 {
        font-size: 1.8rem;
    }
    
    .dashboard-card p {
        font-size: 0.95rem;
    }
    
    .dashboard-card small {
        font-size: 0.75rem;
    }
}

@media (max-width: 992px) {
    .dashboard-card {
        padding: 12px;
        min-height: 110px;
    }
    
    .dashboard-card h3,
    .dashboard-card h5 {
        font-size: 1.4rem;
    }
}

@media (max-width: 768px) {
    .main-content {
        padding: 10px;
    }
    
    .dashboard-card {
        padding: 12px;
        min-height: 100px;
    }
    
    .dashboard-card h3,
    .dashboard-card h5 {
        font-size: 1.5rem;
    }
    
    .dashboard-card p.small {
        font-size: 0.9rem;
    }
    
    .dashboard-card small.text-muted {
        font-size: 0.8rem;
    }
}

@media (max-width: 576px) {
    .dashboard-card {
        padding: 10px;
        min-height: 90px;
    }
    
    .dashboard-card h3,
    .dashboard-card h5 {
        font-size: 1.3rem;
    }
    
    .dashboard-card .fa-lg {
        font-size: 1rem !important;
    }
}

/* Loading spinner */
.spinner-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

/* Print styles */
@media print {
    .navbar, .sidebar, .no-print {
        display: none !important;
    }
    
    .main-content {
        padding: 0;
    }
    
    .card {
        border: 1px solid #000;
        box-shadow: none;
    }
}

/* Letterhead visibility control - Force hide on screen */
.print-letterhead,
div.print-letterhead {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    position: absolute !important;
    left: -9999px !important;
}

@media print {
    .print-letterhead,
    div.print-letterhead {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        position: static !important;
        left: auto !important;
        page-break-inside: avoid !important;
    }
}

