/* Light Theme - HRconnect */
/* Base Styles */
body {
    background: rgb(249 250 251);
    color: rgb(17 24 39);
}

/* Sidebar Styles */
#sidebar {
    background: white;
    border-right: 1px solid rgb(229 231 235);
}

.sidebar-link {
    color: rgb(107 114 128);
    transition: all 0.2s ease;
}

.sidebar-link:hover {
    background: rgb(239 246 255);
    color: rgb(59 130 246);
}

.sidebar-link.active:hover {
    background: rgb(219 234 254) !important;
    color: rgb(37 99 235) !important;
    border-left: 3px solid rgb(37 99 235) !important;
}

.sidebar-link.active {
    background: rgb(239 246 255);
    color: rgb(59 130 246);
    border-left: 3px solid rgb(59 130 246);
}

/* Mobile Header */
.mobile-header {
    background: white;
    border-bottom: 1px solid rgb(229 231 235);
}

.mobile-menu-btn {
    color: rgb(107 114 128);
}

.mobile-menu-btn:hover {
    background: rgb(243 244 246);
    color: rgb(55 65 81);
}

.mobile-title {
    color: rgb(17 24 39);
}

/* Main Content */
main {
    background: rgb(249 250 251);
}

/* Dashboard Cards */
.stat-card {
    background: white;
    border: 1px solid rgb(229 231 235);
    box-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1);
}

.stat-card:hover {
    box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1);
}

/* Activity Cards */
.bg-white {
    background: white;
    border: 1px solid rgb(229 231 235);
}

.bg-gray-50 {
    background: rgb(249 250 251);
}

/* Employee Table */
.employee-table {
    background: white;
    border: 1px solid rgb(229 231 235);
}

.employee-table-header {
    background: rgb(249 250 251);
    border-bottom: 1px solid rgb(229 231 235);
}

.employee-table-header th {
    color: rgb(55 65 81);
    font-weight: 600;
}

.employee-table-body tr {
    border-bottom: 1px solid rgb(229 231 235);
    transition: background-color 0.2s ease;
}

.employee-table-body tr:hover {
    background: rgb(249 250 251);
}

.employee-cell {
    color: rgb(55 65 81);
}

.employee-name {
    color: rgb(17 24 39);
    font-weight: 600;
}

.employee-title {
    color: rgb(107 114 128);
}

.employee-dept {
    background: rgb(239 246 255);
    color: rgb(59 130 246);
}

.employee-email {
    color: rgb(107 114 128);
}

/* Status Badges */
.status-badge {
    font-weight: 500;
}

.status-badge.active {
    background: rgb(220 252 231);
    color: rgb(34 197 94);
}

.status-badge.inactive {
    background: rgb(254 226 226);
    color: rgb(239 68 68);
}

.status-badge.on-leave {
    background: rgb(254 249 195);
    color: rgb(245 158 11);
}

/* Buttons */
.view-details-btn {
    background: rgb(59 130 246);
    color: white;
}

.view-details-btn:hover {
    background: rgb(37 99 235);
}

/* Search Bar */
.search-container {
    background: white;
    border: 1px solid rgb(229 231 235);
}

.search-input {
    background: white;
    border: 1px solid rgb(229 231 235);
    color: rgb(17 24 39);
}

.search-input:focus {
    border-color: rgb(59 130 246);
    box-shadow: 0 0 0 3px rgb(59 130 246 / 0.1);
}

/* Modals */
.modal {
    background: rgba(0, 0, 0, 0.5);
}

.employee-details-modal {
    background: white;
    border: 1px solid rgb(229 231 235);
    box-shadow: 0 20px 25px -5px rgb(0 0 0 / 0.1);
}

.modal-header-enhanced {
    background: linear-gradient(135deg, rgb(248 250 252) 0%, rgb(241 245 249) 100%);
    border-bottom: 1px solid rgb(229 231 235);
}

.modal-title-enhanced {
    color: rgb(17 24 39);
}

.modal-close-btn {
    color: rgb(107 114 128);
}

.modal-close-btn:hover {
    background: rgb(243 244 246);
    color: rgb(55 65 81);
}

.employee-profile-header {
    background: linear-gradient(135deg, rgb(249 250 251) 0%, rgb(243 244 246) 100%);
    border-bottom: 1px solid rgb(229 231 235);
}

.profile-details h3 {
    color: rgb(17 24 39);
}

.profile-details p {
    color: rgb(107 114 128);
}

.employee-info-grid {
    background: white;
}

.info-item {
    background: rgb(248 250 251);
    border: 1px solid rgb(229 231 235);
}

.info-item:hover {
    background: white;
    box-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1);
}

.info-label {
    color: rgb(107 114 128);
}

.info-value {
    color: rgb(17 24 39);
}

.modal-actions {
    background: rgb(248 250 251);
    border-top: 1px solid rgb(229 231 235);
}

.action-btn.primary {
    background: linear-gradient(135deg, rgb(59 130 246) 0%, rgb(37 99 235) 100%);
    color: white;
}

.action-btn.danger {
    background: linear-gradient(135deg, rgb(239 68 68) 0%, rgb(220 38 38) 100%);
    color: white;
}

.reviews-section {
    background: white;
    border-top: 1px solid rgb(229 231 235);
}

.reviews-title {
    color: rgb(17 24 39);
}

.add-review-btn {
    background: linear-gradient(135deg, rgb(34 197 94) 0%, rgb(22 163 74) 100%);
    color: white;
}

.review-card {
    background: white;
    border: 1px solid rgb(229 231 235);
}

.review-card:hover {
    box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1);
}

.review-date {
    color: rgb(107 114 128);
}

.review-summary {
    color: rgb(55 65 81);
}

.empty-reviews {
    color: rgb(107 114 128);
}

/* Reports Page */
.reports-filters {
    background: white;
    border: 1px solid rgb(229 231 235);
}

.report-summary-cards > div {
    background: white;
    border: 1px solid rgb(229 231 235);
}

.report-section {
    background: white;
    border: 1px solid rgb(229 231 235);
}

.top-performers-table {
    background: white;
}

.top-performers-table th {
    color: rgb(55 65 81);
    font-weight: 600;
}

.top-performers-table td {
    color: rgb(55 65 81);
    border-bottom: 1px solid rgb(229 231 235);
}

/* Typography */
.page-title {
    color: rgb(17 24 39);
}

.page-subtitle {
    color: rgb(107 114 128);
}

/* Theme Toggle Button */
.theme-toggle-btn {
    background: rgb(243 244 246);
    border: 1px solid rgb(229 231 235);
    color: rgb(107 114 128);
}

.theme-toggle-btn:hover {
    background: rgb(229 231 235);
    color: rgb(55 65 81);
}

/* Icons */
.icon-blue { color: rgb(59 130 246); }
.icon-green { color: rgb(34 197 94); }
.icon-yellow { color: rgb(245 158 11); }
.icon-purple { color: rgb(147 51 234); }
.icon-red { color: rgb(239 68 68); }
.icon-gray { color: rgb(107 114 128); }

/* Calendar Styles - Light Theme */
.calendar-grid {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.calendar-header {
    border-bottom: 2px solid #e5e7eb;
}

.calendar-body {
    min-height: 400px;
}

.calendar-day {
    position: relative;
    transition: all 0.2s ease;
    border: 1px solid transparent;
    background: white;
}

.calendar-day:hover {
    border-color: #3b82f6;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.1);
    z-index: 10;
}

.calendar-day.bg-blue-50 {
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%) !important;
    border-color: #3b82f6;
}

.calendar-day .text-blue-600 {
    font-weight: 600;
}

/* Event Type Colors - Light Theme */
.bg-red-100 { background-color: #fee2e2 !important; }
.text-red-700 { color: #b91c1c !important; }
.bg-pink-100 { background-color: #fce7f3 !important; }
.text-pink-700 { color: #be185d !important; }
.bg-blue-100 { background-color: #dbeafe !important; }
.text-blue-700 { color: #1d4ed8 !important; }
.bg-green-100 { background-color: #dcfce7 !important; }
.text-green-700 { color: #15803d !important; }
.bg-yellow-100 { background-color: #fef3c7 !important; }
.text-yellow-700 { color: #a16207 !important; }
.bg-purple-100 { background-color: #f3e8ff !important; }
.text-purple-700 { color: #6b21a8 !important; }

/* Calendar Controls - Light Theme */
.calendar-controls {
    background: linear-gradient(135deg, #ffffff 0%, #f9fafb 100%);
    border: 1px solid #e5e7eb;
}

.calendar-controls button {
    transition: all 0.2s ease;
}

.calendar-controls button:hover {
    background-color: #f3f4f6;
    transform: scale(1.05);
}

.calendar-controls button:active {
    transform: scale(0.95);
}

/* Calendar Event Pills */
.event-pill {
    display: inline-block;
    padding: 2px 6px;
    border-radius: 12px;
    font-size: 10px;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

.event-pill.holiday {
    background-color: #fee2e2;
    color: #b91c1c;
}

.event-pill.birthday {
    background-color: #fce7f3;
    color: #be185d;
}

.event-pill.company {
    background-color: #dbeafe;
    color: #1d4ed8;
}

.event-pill.team {
    background-color: #dcfce7;
    color: #15803d;
}

.event-pill.meeting {
    background-color: #fef3c7;
    color: #a16207;
}

/* Calendar Loading Animation */
.calendar-loading {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 400px;
}

.calendar-loading::after {
    content: '';
    width: 40px;
    height: 40px;
    border: 4px solid #e5e7eb;
    border-top: 4px solid #3b82f6;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* News Details Modal - Mobile Responsive */
#newsDetailsModal {
    padding: 1rem !important;
}

#newsDetailsModal .bg-white {
    max-height: calc(100vh - 2rem) !important;
    margin: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    border-radius: 0.75rem !important;
    overflow: hidden !important;
    display: flex !important;
    flex-direction: column !important;
}

/* Mobile specific modal adjustments */
@media (max-width: 768px) {
    #newsDetailsModal {
        padding: 0.5rem !important;
        align-items: flex-start !important;
        padding-top: 2rem !important;
        padding-bottom: 2rem !important;
    }
    
    #newsDetailsModal .bg-white {
        max-height: calc(100vh - 4rem) !important;
        border-radius: 0.5rem !important;
        margin: 0 0.5rem !important;
        width: calc(100% - 1rem) !important;
    }
    
    #newsDetailsModal .modal-content {
        overflow-y: auto !important;
        -webkit-overflow-scrolling: touch !important;
        scrollbar-width: thin !important;
        scrollbar-color: rgb(209 213 219) rgb(243 244 246) !important;
    }
    
    #newsDetailsModal .modal-content::-webkit-scrollbar {
        width: 6px !important;
    }
    
    #newsDetailsModal .modal-content::-webkit-scrollbar-track {
        background: rgb(243 244 246) !important;
        border-radius: 3px !important;
    }
    
    #newsDetailsModal .modal-content::-webkit-scrollbar-thumb {
        background: rgb(209 213 219) !important;
        border-radius: 3px !important;
    }
    
    #newsDetailsModal .modal-content::-webkit-scrollbar-thumb:hover {
        background: rgb(156 163 175) !important;
    }
}

/* Small mobile devices */
@media (max-width: 480px) {
    #newsDetailsModal {
        padding: 1rem !important;
        align-items: center !important;
        justify-content: center !important;
    }
    
    #newsDetailsModal .bg-white {
        max-height: 90vh !important;
        border-radius: 1rem !important;
        margin: 0 !important;
        width: 100% !important;
        max-width: calc(100vw - 2rem) !important;
        min-height: auto !important;
    }
    
    #newsDetailsModal .modal-content {
        padding: 1rem !important;
        overflow-y: auto !important;
        -webkit-overflow-scrolling: touch !important;
    }
}

/* Mobile Menu Overlay */
.mobile-menu-overlay {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    background: rgba(0, 0, 0, 0.5) !important;
    z-index: 39 !important;
    opacity: 0 !important;
    visibility: hidden !important;
    transition: opacity 0.3s ease, visibility 0.3s ease !important;
}

.mobile-menu-overlay.show {
    opacity: 1 !important;
    visibility: visible !important;
}

/* Ensure sidebar has proper flex structure for app info positioning */
#sidebar {
    display: flex !important;
    flex-direction: column !important;
    height: 100vh !important;
}

#sidebar nav {
    flex: 1 !important;
    overflow-y: auto !important;
}

/* App Info Area - Always at bottom */
.app-info-area {
    margin-top: auto !important;
    flex-shrink: 0 !important;
    background: white !important;
    border-top: 1px solid rgb(229 231 235) !important;
}

/* Mobile Sidebar - Ensure app info stays at bottom */
@media (max-width: 1023px) {
    #sidebar {
        position: fixed !important;
        left: 0 !important;
        top: 0 !important;
        bottom: 0 !important;
        z-index: 40 !important;
        transform: translateX(-100%) !important;
        transition: transform 0.3s ease !important;
    }
    
    #sidebar.show {
        transform: translateX(0) !important;
    }
    
    #sidebar nav {
        overflow-y: auto !important;
        -webkit-overflow-scrolling: touch !important;
    }
    
    .app-info-area {
        position: sticky !important;
        bottom: 0 !important;
        background: white !important;
        border-top: 1px solid rgb(229 231 235) !important;
    }
}

/* Small mobile devices */
@media (max-width: 480px) {
    #sidebar {
        width: 100% !important;
    }
    
    .app-info-area {
        position: fixed !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        z-index: 41 !important;
        background: white !important;
        border-top: 1px solid rgb(229 231 235) !important;
        box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1) !important;
    }
    
    #sidebar.show ~ main {
        padding-bottom: 120px !important;
    }
}
