/* Frontend styles for LMS Platforma */

/* Company Activity Table */
.company-activity-table {
    margin: 20px 0;
    overflow-x: auto;
}

/* LMS Filters */
.lms-filters {
    background: #fff;
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 4px;
}

.lms-filters form {
    margin: 0;
}

.lms-filters label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: var(--text-title);
}

.lms-filters select,
.lms-filters input[type="date"] {
    width: 100%;
    padding: 6px 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

select {
    background-color:white;
    line-height: var(--text-l);
}

.lms-filters .button {
    padding: 6px 12px;
    border-radius: 3px;
    background: #f7f7f7;
    color: #333;
    text-decoration: none;
    font-size: 13px;
    line-height: 1.4;
    cursor: pointer;
    display: inline-block;
    margin: 0;
    outline: none;
    box-shadow: 0 1px 0 #ccc;
}

.lms-filters .button:hover {
    background: #e9e9e9;
    border-color: #999;
}

.lms-filters .button-primary {
    background: var(--primary);;
    color: #fff;
}

.lms-filters .button-primary:hover {
    background: #2563EB;
    border-color: #2563EB;
}

/* LMS History Table */
.lms-history-table {
    background: #fff;
    border-radius: 4px;
    overflow: hidden;
}

/* WP List Table Styles (adapted for frontend) */
.wp-list-table {
    width: 100%;
    border-collapse: collapse;
    margin: 0;
    font-size: var(--text-xs);
}

.wp-list-table th,
.wp-list-table td {
    padding: 8px 10px;
    border-bottom: 1px solid #e1e1e1;
    vertical-align: top;
}

.wp-list-table th {
    background: var(--text-title);
    font-weight: 600;
    text-align: left;
    color: #fff;
}

.wp-list-table.widefat thead th {
    border-left: 1px solid #e1e1e1;
}

.wp-list-table.widefat thead th:first-child {
    border-left: none;
}

.employees-table.widefat thead th {
    border-left: 1px solid #e1e1e1;
}

.employees-table.widefat thead th:first-child {
    border-left: none;
}

.wp-list-table tbody tr:hover {
    background: #f6f7f7;
}

.wp-list-table.striped tbody tr:nth-child(odd) {
    background: #fff;
}

.wp-list-table.striped tbody tr:nth-child(even) {
    background: #F9FAFB;
}

.employees-table.striped tbody tr:nth-child(odd) {
    background: #fff;
}

.employees-table.striped tbody tr:nth-child(even) {
    background: #F9FAFB;
}

/* LMS Pagination */
.lms-pagination {
    margin-top: 20px;
    text-align: center;
}

.lms-pagination .page-numbers {
    padding: 6px 12px;
    margin: 0 2px;
    background: #fff;
    color: var(--primary);
    text-decoration: none;
    border-radius: 3px;
}

.lms-pagination .page-numbers:hover,
.lms-pagination .page-numbers.current {
    background: var(--primary);
    color: #fff;
}


/* Company Employees List */
.company-employees-list {
    margin: 20px 0;
    overflow-x: auto;
}

.employees-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border: 1px solid #ccd0d4;
    border-radius: var(--radius-l);
    overflow: hidden;
    font-size:var(--text-xs);
}

.employees-table th,
.employees-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #e1e1e1;
}

.employees-table th {
    background: #1e336a;
    font-weight: 600;
    color: #fff;
    border-bottom: 1px solid #778dc7;
}

.employees-table tbody tr:hover {
    background: #f6f7f7;
}

.employees-table tbody tr:nth-child(even) {
    background: #F9FAFB;
}

.toggle-details {
    background: var(--primary);
    color: #fff;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s ease;
}

.toggle-details:hover {
    background: var(--primary-d-1);
}

.employee-details {
    background: #F8F9FA;
    transition: all 0.3s ease;
}

.details-content {
    display: none;
}

.employee-details td {
    padding: 0;
    border-bottom: none;
}

.details-content {
    padding: 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}


.completed-courses h4,
.completed-lessons h4 {
    margin: 0 0 10px 0;
    color: var(--text-title);
    font-size: 16px;
}

.completed-courses ul,
.completed-lessons ul {
    margin: 0;
    padding-left: 0;
}

.completed-courses li,
.completed-lessons li {
    margin-bottom: 5px;
    color: #555;
    list-style: none;
}

.completed-courses li::before,
.completed-lessons li::before {
    content: "✅";
    margin-right: 8px;
}

.completed-courses p,
.completed-lessons p {
    margin: 0;
    color: #666;
    font-style: italic;
}

/* LMS Message Styles */
.lms-message {
    padding: 12px 16px;
    margin: 10px 0;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    position: relative;
    z-index: 1000;
}

.lms-message.success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.lms-message.error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* LMS Button Loading State */
.lms-button-loading {
    opacity: 0.7;
    cursor: not-allowed;
    position: relative;
}

.lms-button-loading::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    margin: auto;
    border: 2px solid #ffffff;
    border-top: 2px solid transparent;
    border-radius: 50%;
    animation: lms-button-spinner 1s linear infinite;
}

@keyframes lms-button-spinner {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive adjustments for employees list */
@media screen and (max-width: 768px) {
    .employees-table th,
    .employees-table td {
        padding: 8px 10px;
        font-size: 14px;
    }

    .details-content {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .completed-courses,
    .completed-lessons {
        padding: 12px;
    }
}