/* ============================================
   HR REPORTS DASHBOARD STYLES
   People & Partners Insurance PLC
   ============================================ */

/* Password Protection Modal */
.password-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, var(--teal-primary) 0%, var(--teal-dark) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: fadeIn 0.3s ease;
}

.password-modal-content {
    background: white;
    border-radius: var(--radius-xl);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    padding: 50px 60px;
    max-width: 500px;
    width: 90%;
    text-align: center;
    animation: modalSlideIn 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-30px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.password-header svg {
    margin-bottom: 20px;
}

.password-header h2 {
    font-size: 28px;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 12px;
}

.password-header p {
    font-size: 15px;
    color: var(--gray-600);
    margin-bottom: 30px;
}

.password-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.password-input {
    width: 100%;
    padding: 16px 20px;
    border: 2px solid var(--gray-200);
    border-radius: var(--radius);
    font-size: 16px;
    font-family: inherit;
    transition: all 0.3s ease;
    text-align: center;
    letter-spacing: 2px;
}

.password-input:focus {
    outline: none;
    border-color: var(--teal-primary);
    box-shadow: 0 0 0 3px rgba(90, 172, 168, 0.1);
}

.password-input.shake {
    animation: shake 0.5s ease;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
    20%, 40%, 60%, 80% { transform: translateX(5px); }
}

.password-submit-btn {
    width: 100%;
    padding: 16px 24px;
    background: linear-gradient(135deg, var(--teal-primary), var(--teal-dark));
    color: white;
    border: none;
    border-radius: var(--radius);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(90, 172, 168, 0.3);
}

.password-submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(90, 172, 168, 0.4);
}

.password-submit-btn:active {
    transform: translateY(0);
}

.back-to-home-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-600);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    padding: 10px;
    transition: all 0.3s ease;
}

.back-to-home-link:hover {
    color: var(--teal-primary);
}

.password-error {
    margin-top: 16px;
    padding: 12px;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: var(--radius);
    color: #dc2626;
    font-size: 14px;
    font-weight: 500;
}

.password-error.hidden {
    display: none;
}

/* Back Button */
.back-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    background: var(--gray-100);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius);
    color: var(--gray-700);
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    margin-right: 20px;
}

.back-btn:hover {
    background: var(--teal-primary);
    color: white;
    border-color: var(--teal-primary);
    transform: translateX(-3px);
}

.back-btn svg {
    transition: transform 0.3s ease;
}

.back-btn:hover svg {
    transform: translateX(-3px);
}

/* Report Navigation */
.report-nav {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 30px;
}

.nav-btn {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: var(--radius);
    color: white;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: left;
}

.nav-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateX(5px);
}

.nav-btn.active {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.4);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.nav-btn svg {
    flex-shrink: 0;
}

/* Quick Stats */
.quick-stats {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin-top: auto;
}

.quick-stats h3 {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.quick-stat-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.quick-stat-item:last-child {
    border-bottom: none;
}

.quick-stat-item .stat-label {
    font-size: 12px;
    opacity: 0.9;
}

.quick-stat-item .stat-value {
    font-size: 18px;
    font-weight: 700;
}

/* Report Header */
.report-header {
    background: white;
    padding: 30px;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-md);
    margin-bottom: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.header-content {
    display: flex;
    align-items: center;
    gap: 20px;
}

.header-content h1 {
    font-size: 28px;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 6px;
}

.header-content p {
    font-size: 14px;
    color: var(--gray-600);
}

.header-actions {
    display: flex;
    gap: 12px;
}

.action-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    background: var(--gray-100);
    border: 1px solid var(--gray-300);
    border-radius: var(--radius);
    color: var(--gray-700);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.action-btn:hover {
    background: var(--gray-200);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.action-btn.primary {
    background: var(--teal-primary);
    color: white;
    border-color: var(--teal-primary);
}

.action-btn.primary:hover {
    background: var(--teal-dark);
    border-color: var(--teal-dark);
}

/* Filters Section */
.filters-section {
    background: white;
    padding: 24px 30px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    margin-bottom: 24px;
    display: flex;
    gap: 20px;
    align-items: flex-end;
    flex-wrap: wrap;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.filter-group label {
    font-size: 13px;
    font-weight: 600;
    color: var(--gray-700);
}

.filter-input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-sm);
    font-size: 15px;
    font-family: 'Poppins', sans-serif;
    color: var(--gray-900);
    background: white;
    min-width: 150px;
    transition: all 0.2s ease;
    cursor: pointer;
}

.filter-input:focus {
    outline: none;
    border-color: var(--teal-primary);
    box-shadow: 0 0 0 3px var(--teal-lighter);
}

.filter-input option {
    padding: 12px 16px;
    font-size: 15px;
    font-family: 'Poppins', sans-serif;
    background: white;
    color: var(--gray-900);
}

.filter-input option:hover,
.filter-input option:checked {
    background: var(--teal-lighter);
    color: var(--gray-900);
}

.filter-btn {
    padding: 10px 24px;
    background: var(--teal-primary);
    border: none;
    border-radius: var(--radius-sm);
    color: white;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-btn:hover {
    background: var(--teal-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

/* Report Content */
.report-content {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* Statistics Cards */
.stats-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    padding: 24px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    border-left: 4px solid var(--teal-primary);
    transition: all 0.3s ease;
}

.stat-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-4px);
}

.stat-card.success {
    border-left-color: var(--success);
}

.stat-card.warning {
    border-left-color: var(--warning);
}

.stat-card.info {
    border-left-color: #3b82f6;
}

.stat-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 16px;
}

.stat-card-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--teal-lighter);
    color: var(--teal-primary);
}

.stat-card.success .stat-card-icon {
    background: rgba(15, 169, 104, 0.1);
    color: var(--success);
}

.stat-card.warning .stat-card-icon {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
}

.stat-card-value {
    font-size: 36px;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 8px;
}

.stat-card-label {
    font-size: 14px;
    color: var(--gray-600);
    font-weight: 500;
}

.stat-card-trend {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--gray-200);
    font-size: 13px;
    color: var(--gray-600);
    display: flex;
    align-items: center;
    gap: 6px;
}

.trend-up {
    color: var(--success);
}

.trend-down {
    color: var(--error);
}

/* Data Table */
.data-table-container {
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.table-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--gray-200);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.table-header h3 {
    font-size: 18px;
    font-weight: 600;
    color: var(--gray-900);
}

.table-search {
    padding: 8px 14px;
    border: 1px solid var(--gray-300);
    border-radius: var(--radius-sm);
    font-size: 14px;
    width: 250px;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table thead {
    background: var(--gray-50);
}

.data-table th {
    padding: 14px 20px;
    text-align: left;
    font-size: 13px;
    font-weight: 600;
    color: var(--gray-700);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.data-table td {
    padding: 16px 20px;
    border-top: 1px solid var(--gray-200);
    font-size: 14px;
    color: var(--gray-900);
}

.data-table tbody tr {
    transition: all 0.2s ease;
}

.data-table tbody tr:hover {
    background: var(--gray-50);
}

.status-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 50px;
    font-size: 12px;
    font-weight: 600;
}

.status-badge.on-time {
    background: rgba(15, 169, 104, 0.1);
    color: var(--success);
}

.status-badge.late {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
}

/* Charts Container */
.charts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 24px;
}

.chart-container {
    background: white;
    padding: 24px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
}

.chart-header {
    margin-bottom: 20px;
}

.chart-header h3 {
    font-size: 16px;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 4px;
}

.chart-header p {
    font-size: 13px;
    color: var(--gray-600);
}

.chart-placeholder {
    height: 300px;
    background: var(--gray-50);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-400);
    font-size: 14px;
}

/* Employee Card */
.employee-card {
    background: white;
    padding: 20px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    display: flex;
    gap: 16px;
    align-items: center;
    transition: all 0.3s ease;
}

.employee-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.employee-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--teal-primary), var(--teal-dark));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 20px;
    font-weight: 700;
    flex-shrink: 0;
}

.employee-info {
    flex: 1;
}

.employee-info h4 {
    font-size: 16px;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 4px;
}

.employee-info p {
    font-size: 13px;
    color: var(--gray-600);
}

.employee-stats {
    display: flex;
    gap: 20px;
}

.employee-stat {
    text-align: center;
}

.employee-stat-value {
    font-size: 20px;
    font-weight: 700;
    color: var(--gray-900);
}

.employee-stat-label {
    font-size: 11px;
    color: var(--gray-600);
    text-transform: uppercase;
}

/* Print Styles */
@media print {
    .left-panel,
    .header-actions,
    .filters-section,
    .action-btn {
        display: none !important;
    }

    .main-container {
        grid-template-columns: 1fr;
    }

    .report-content {
        page-break-inside: avoid;
    }

    .stat-card,
    .data-table-container {
        box-shadow: none;
        border: 1px solid #ddd;
    }
}

/* Responsive */
@media (max-width: 968px) {
    .report-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .filters-section {
        flex-direction: column;
        align-items: stretch;
    }

    .filter-input {
        width: 100%;
    }

    .charts-grid {
        grid-template-columns: 1fr;
    }
}
