.tms-courses-grid {
    /* display: grid; */
    /* grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); */
    /* gap: 20px; */
    display: flex;
    flex-direction: column;
    row-gap: 20px;
    margin: 0 auto;
    
}
[v-cloak] {
    display: none;
}
.tms-input {
        padding: 10px 12px;
        border: 1px solid #ddd;
        border-radius: 4px;
        font-size: 14px;
        transition: border-color 0.2s;
    }

    .tms-input:focus {
        outline: none;
        border-color: #309a06;
        box-shadow: 0 0 0 2px rgba(48, 154, 6, 0.1);
    }

    .tms-button-disabled {
        background: #ccc !important;
        cursor: not-allowed !important;
        opacity: 0.7;
    }
.tms-main {
    background-color: #fff;
    padding: 20px;
}
.tms-main .tms-my-account {
    max-width: 100%;
}
#tms-courses {
    /* max-width: var(--wp--style--global--wide-size); */
}
.tms_pdf_receipt {
    margin-left: 10px;
}
.tms-course-list {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    row-gap: 20px;
    gap: 20px;
    margin: 0 auto;
}

.tms-course-date {
    font-weight: 600;
    font-size: 20px;
    margin-bottom: 10px;
    position: sticky;
    top: 0;
    background: #fff;
    padding: 10px 0;
    z-index: 100000;
}

.tms-course-list-item {
    background-color: #f2f2f2;
    border-radius: 10px;
    padding: 20px;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    justify-content: space-between;
}
.tms-course-list .tms-course-info-item.class-date {
    border: 1px dashed #cfcfcf;
    padding: 10px;
    margin: 5px 0;
    border-radius: 10px;
    font-size: 16px;
    cursor: pointer;
}
.tms-course-list .tms-course-info-item.class-date:hover {
    border-color: #333;
}
.instuctor-courses {
    
}
.instuctor-courses .title {
    color: #999;
}
.instuctor-courses .list .item {
    border-bottom: 1px dashed #cfcfcf;
    padding: 5px 0;
}
.instuctor-courses .list .item:last-child {
    border-bottom: none;
}
.tms-course-list-item .tms-left {
    width: 100%;
}
.tms-cours
.tms-left {
    display: flex;
    gap: 20px;
    align-items: center;
}
.tms-right {
    border-top: 1px solid #e3e3e3;
    padding-top: 10px;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    row-gap: 30px;
}
.tms-course-list-item:last-child {
    border-bottom: none;
}
.tms-course-info-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 16px;
}
.tms-course-info-item .tms-key {
    font-size: 14px;
    color: #999;
}
.tms-course-info-item .tms-value {
    color: #333;
    font-weight: 600;
    font-size: 14px;
}
.tms-course-time {
    font-weight: 600;
}


.tms-button {
    display: inline-block;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.3s ease;
}
.tms-button:disabled {
    background-color: #ccc !important;
    cursor: not-allowed !important;
    opacity: 0.7;
}
.tms-button-success {
    background-color: #3d8717;
    color: #fff;
}
.tms-button-success:hover {
    background-color: #288745;
}
.tms-button-primary {
    background-color: #041f30;
    color: #fff;
}

.tms-button-primary:hover {
    background-color: #041f30;
}
.tms-button-danger {
    background-color: #d63638;
    color: #fff;
}

.tms-button-danger:hover {
    background-color: #a52a2a;
}
.tms-button-circle {
    border-radius: 50px;
}
.tms-text-danger {
    color: #d63638;
}

.tms-button-disabled {
    background-color: #ccc;
    color: #666;
    cursor: not-allowed;
}
.tms-button-booked {
    background-color: #3d871750;
    color: #fff;
}

.tms-button-booked:hover {
    background-color: #3d871750;
}

.tms-course-detail {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 30px;
    margin: 20px 0;
}

.tms-course-detail .tms-course-title {
    font-size: 28px;
    color: #333;
    margin-bottom: 20px;
}

.tms-course-description {
    margin: 20px 0;
    padding: 15px;
    background: #f9f9f9;
    border-radius: 4px;
}

.tms-course-description h3 {
    margin-top: 0;
    color: #333;
}

.tms-course-info {
    /* margin: 20px 0; */
}

.tms-course-info p {
    margin: 10px 0;
    color: #555;
}

.tms-course-info strong {
    color: #333;
}

.tms-course-schedule {
    margin: 20px 0;
}

.tms-course-schedule h3 {
    color: #333;
    margin-bottom: 15px;
}

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

.tms-schedule-table th,
.tms-schedule-table td {
    padding: 10px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

.tms-schedule-table th {
    background-color: #f9f9f9;
    color: #333;
    font-weight: 600;
}

.tms-course-enroll {
    display: flex;

    gap: 10px;
    align-items: center;
}

.tms-course-enroll-text {
    display: flex;
    align-items: center;
    font-size: 12px;
    color:#333;
    font-weight: normal;
    margin-top: 2px;
}
.tms-course-enroll .tms-button {
    font-weight: bold;
    line-height: 1.2;
    padding: 5px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}
.tms-course-spots {
    text-align: right;
    font-weight: bold;
}
.tms-my-courses {
    margin: 20px 0;
}

.tms-my-courses h2 {
    color: #333;
    margin-bottom: 20px;
}

.tms-my-course-card {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 15px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.tms-my-course-card h3 {
    margin: 0 0 10px 0;
    color: #333;
}

.tms-my-course-card .tms-course-code {
    color: #666;
    font-size: 14px;
    margin: 5px 0;
}

.tms-course-progress {
    margin: 15px 0;
    padding: 10px;
    background: #f9f9f9;
    border-radius: 4px;
}

.tms-course-progress p {
    margin: 5px 0;
    color: #555;
}

.tms-course-progress strong {
    color: #333;
}
.wp-block-spacer {
    height: 0 !important;
}
.tms-courses-filter {
    padding: 10px;
    background-color: #f2f2f2;
    margin-bottom: 20px;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    row-gap: 10px;
}
.tms-filter-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 16px;
    gap: 10px;
}
.tms-filter-button {
    justify-content: flex-end;
}
.tms-filter-select {
    border: 1px solid #ccc;
    border-radius: 4px;
    background-color: #fff;
    
    font-size: 14px;
    width: 50%;
}
.tms-filter-select select {
    padding: 10px;
    width: 100%;
    border: none;
    outline: none;
    background: none;
}
.tms-filter-date {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 20px 0 10px 0;
    justify-content: space-between;
    border-top: 1px dashed #ccc;
    font-weight: bold;
}
.tms-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.tms-modal-content {
    background: #fff;
    border-radius: 8px;
    max-width: 800px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.tms-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 2px solid #e5e5e5;
}

.tms-modal-header h3 {
    margin: 0;
    font-size: 20px;
    color: #23282d;
}

.tms-modal-close {
    background: none;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: #666;
    padding: 0;
    line-height: 1;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.tms-modal-close:hover {
    background: #f0f0f1;
    color: #dc3232;
}

.tms-modal-body {
    padding: 20px;
}

.tms-modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 20px;
    border-top: 2px solid #e5e5e5;
}

.tms-course-students-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border-radius: 4px;
    overflow: hidden;
}

.tms-course-students-table thead {
    background: #f9f9f9;
}

.tms-course-students-table th {
    padding: 12px 15px;
    text-align: left;
    font-weight: 600;
    color: #23282d;
    border-bottom: 2px solid #e5e5e5;
}

.tms-course-students-table td {
    padding: 12px 15px;
    border-bottom: 1px solid #e5e5e5;
}

.tms-course-students-table tbody tr:hover {
    background: #f9f9f9;
}

.tms-course-students-table tbody tr:last-child td {
    border-bottom: none;
}

.tms-exam-status-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.tms-exam-status-pending {
    background: #fff3cd;
    color: #856404;
}

.tms-exam-status-passed {
    background: #d4edda;
    color: #155724;
}

.tms-exam-status-failed {
    background: #f8d7da;
    color: #721c24;
}

.tms-button-secondary {
    background: #6c757d;
    color: #fff;
    border: none;
}

.tms-button-secondary:hover {
    background: #5a6268;
}

.tms-loading {
    text-align: center;
    padding: 40px;
    color: #666;
}

.tms-no-data {
    text-align: center;
    padding: 40px;
    color: #666;
}
/* .tms-courses-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
}

.tms-course-card {
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.tms-course-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.tms-course-header {
    border-bottom: 2px solid #00a0d2;
    padding-bottom: 12px;
    margin-bottom: 15px;
}

.tms-course-title {
    font-size: 18px;
    font-weight: 600;
    color: #23282d;
    margin: 0 0 5px 0;
}

.tms-course-code {
    display: inline-block;
    background: #f0f0f1;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 12px;
    color: #666;
    font-weight: 500;
}

.tms-course-info {
    margin-bottom: 15px;
}

.tms-course-info p {
    margin: 8px 0;
    font-size: 14px;
    color: #444;
    line-height: 1.5;
}

.tms-course-info strong {
    color: #23282d;
    font-weight: 600;
}

.tms-course-exam {
    background: #f9f9f9;
    padding: 15px;
    border-radius: 6px;
    margin-bottom: 15px;
}

.tms-course-exam h4 {
    font-size: 14px;
    font-weight: 600;
    color: #23282d;
    margin: 0 0 10px 0;
} */
[data-block-name="woocommerce/product-new"]{
    display:none !important;
}
.tms-exam-type-selector {
    display: flex;
    gap: 15px;
    margin-bottom: 10px;
}

.tms-exam-type-selector label {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 13px;
    color: #444;
    transition: color 0.2s ease;
}

.tms-exam-type-selector label:hover {
    color: #00a0d2;
}

.tms-exam-type-selector input[type="radio"] {
    margin-right: 6px;
    cursor: pointer;
    width: 16px;
    height: 16px;
}

.tms-exam-info {
    font-size: 13px;
    color: #666;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #e5e5e5;
}

.tms-exam-info p {
    margin: 5px 0;
}

.tms-exam-info strong {
    color: #23282d;
    font-weight: 600;
}

.tms-warning {
    color: #dc3232;
    font-size: 13px;
    display: block;
    margin-top: 10px;
}

.tms-course-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
}

.tms-button-small {
    padding: 8px 16px;
    font-size: 13px;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.tms-button-primary {
    background: #00a0d2;
    color: #fff;
    border: none;
}

.tms-button-primary:hover {
    background: #0085ba;
}

.tms-button-small:not(.tms-button-primary) {
    background: #f0f0f1;
    color: #23282d;
    border: 1px solid #ddd;
}

.tms-button-small:not(.tms-button-primary):hover {
    background: #e5e5e5;
    border-color: #ccc;
}
.tms-instructor-attendance-container {
    max-width: 1400px;
    margin: 0 auto;
    /* padding: 20px; */
}

.tms-page-title {
    font-size: 32px;
    margin-bottom: 30px;
    color: #333;
    text-align: center;
}

.tms-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-bottom: 24px;
    padding: 5px;
    background: rgba(118, 118, 128, 0.12);
    border-radius: 10px;
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
}

.tms-tab-button {
    padding: 7px 14px;
    background: none;
    border: none;
    font-size: 14px;
    font-weight: 500;
    color: #3c3c43;
    cursor: pointer;
    position: relative;
    transition: all 0.2s ease;
    white-space: nowrap;
    flex-shrink: 0;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    line-height: 1.4;
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'SF Pro Display', 'Helvetica Neue', sans-serif;
}

.tms-tab-button:hover {
    color: #000;
    background: rgba(255, 255, 255, 0.55);
}

.tms-tab-button:focus-visible {
    outline: 2px solid #007aff;
    outline-offset: -2px;
}

.tms-tab-button.active {
    color: #000;
    background: #fff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08), 0 1px 1px rgba(0, 0, 0, 0.04);
    font-weight: 600;
}

.tms-tab-button.active::after {
    display: none;
}

.tms-tab-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    background: #ff9500;
    color: #fff;
    border-radius: 9px;
    font-size: 11px;
    font-weight: 600;
    line-height: 1;
}

.tms-tab-button.active .tms-tab-count {
    background: #007aff;
}

.tms-tab-content {
    min-height: 400px;
}

.tms-tab-panel {
    display: none;
}

.tms-tab-panel.active {
    display: block;
}

.tms-session-block {
    background: white;
    border-radius: 8px;
    padding: 20px 0;
    margin-bottom: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.tms-session-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e0e0e0;
    padding: 0 10px;
}

.tms-session-title {
    font-size: 20px !important;
    margin: 0 !important;
    color: #333;
    padding: 10px 0;
}

.tms-session-info {
    display: flex;
    gap: 15px;
    align-items: center;
}

.tms-session-date,
.tms-session-time {
    color: #666;
    font-size: 14px;
}

.tms-substitute-badge {
    display: inline-block;
    background: rgba(255, 193, 7, 0.3);
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 14px;
}

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

.tms-attendance-table thead {
    background: #f8f9fa;
}

.tms-attendance-table th {
    padding: 15px 12px;
    text-align: left;
    font-weight: 600;
    font-size: 14px;
    color: #555;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.tms-attendance-table tbody tr {
    border-bottom: 1px solid #e0e0e0;
    transition: background-color 0.2s ease;
}

.tms-attendance-table tbody tr:hover {
    background-color: #f8f9fa;
}

.tms-attendance-table td {
    padding: 12px;
}

.tms-student-name {
    font-weight: 500;
    color: #333;
}

.tms-student-code {
    color: #666;
    font-family: monospace;
}

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

/* 课程状态颜色 */
.tms-status-badge.status-pending,
.tms-status-badge.status-draft {
    background: #fef3c7 !important;
    color: #92400e !important;
}

.tms-status-badge.status-open_for_enrollment {
    background: #dbeafe !important;
    color: #1e40af !important;
}

.tms-status-badge.status-in_progress,
.tms-status-badge.status-active,
.tms-status-badge.status-paid {
    background: #d1fae5 !important;
    color: #065f46 !important;
}

.tms-status-badge.status-completed,
.tms-status-badge.status-ended {
    background: #e0e7ff !important;
    color: #3730a3 !important;
}

.tms-status-badge.status-cancelled {
    background: #fee2e2 !important;
    color: #991b1b !important;
}

.tms-status-badge.status-refunded,
.tms-status-badge.status-refunding {
    background: #fed7aa !important;
    color: #9a3412 !important;
}

/* 状态筛选按钮 */
.tms-status-filter-btn {
    transition: all 0.2s ease;
}
.tms-status-filter-btn.active {
    background: #2563eb !important;
    color: #fff !important;
    border-color: #2563eb !important;
}
.tms-status-filter-btn:hover {
    background: #f3f4f6;
}

.tms-status-present {
    background: #d4edda !important;
    color: #155724 !important;
}

.tms-status-absent {
    background: #f8d7da !important;
    color: #721c24 !important;
}

.tms-status-pending {
    background: #fff3cd !important;
    color: #856404 !important;
}

.tms-attendance-time {
    color: #666;
    font-size: 14px;
}

.tms-operator-name {
    color: #666;
    font-size: 14px;
}

.tms-button {
    padding: 8px 16px;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-right: 5px;
}

.tms-button-present {
    background: #28a745;
    color: white;
}

.tms-button-present:hover {
    background: #218838;
}

.tms-button-absent {
    background: #dc3545;
    color: white;
}
.tms-button-score {
    background: #ffc107;
    color: white;
}

.tms-button-score:hover {
    background: #e6a800;
}
.tms-button-score.pending {
    background: #ffc107;
    color: white;
}
.tms-button-score.present {
    background: #255724;
    color: white;
}
.tms-button-score.fail {
    background: #dc3545;
    color: white;
}

.tms-button-absent:hover {
    background: #c82333;
}

.tms-button-primary {
    background: #007bff;
    color: white;
}

.tms-button-primary:hover {
    background: #0056b3;
}

.tms-no-sessions,
.tms-no-students {
    text-align: center;
    padding: 40px;
    color: #999;
}

.tms-loading {
    text-align: center;
    padding: 40px;
    color: #666;
}

.tms-history-filters {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.tms-date-input {
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.tms-stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.tms-stat-card {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
    gap: 15px;
}

.tms-stat-icon {
    font-size: 36px;
}

.tms-stat-info h4 {
    margin: 0 0 5px 0;
    font-size: 14px;
    color: #666;
}

.tms-stat-value {
    margin: 0;
    font-size: 24px;
    font-weight: 600;
    color: #333;
}

.tms-history-item {
    background: white;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 10px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.tms-history-item h4 {
    margin: 0 0 10px 0;
    color: #333;
}

.tms-history-item p {
    margin: 5px 0;
    color: #666;
}
.tms-instructor-courses-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

.tms-page-title {
    font-size: 32px;
    margin-bottom: 30px;
    color: #333;
    text-align: center;
}

.tms-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-bottom: 24px;
    padding: 5px;
    background: rgba(118, 118, 128, 0.12);
    border-radius: 10px;
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
}

.tms-tab-button {
    padding: 7px 14px;
    background: none;
    border: none;
    font-size: 14px;
    font-weight: 500;
    color: #3c3c43;
    cursor: pointer;
    position: relative;
    transition: all 0.2s ease;
    white-space: nowrap;
    flex-shrink: 0;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    line-height: 1.4;
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'SF Pro Display', 'Helvetica Neue', sans-serif;
}

.tms-tab-button:hover {
    color: #000;
    background: rgba(255, 255, 255, 0.55);
}

.tms-tab-button:focus-visible {
    outline: 2px solid #007aff;
    outline-offset: -2px;
}

.tms-tab-button.active {
    color: #000;
    background: #fff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08), 0 1px 1px rgba(0, 0, 0, 0.04);
    font-weight: 600;
}

.tms-tab-button.active::after {
    display: none;
}

.tms-tab-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    background: #ff9500;
    color: #fff;
    border-radius: 9px;
    font-size: 11px;
    font-weight: 600;
    line-height: 1;
}

.tms-tab-button.active .tms-tab-count {
    background: #007aff;
}

.tms-tab-content {
    min-height: 400px;
}

.tms-tab-panel {
    display: none;
}

.tms-tab-panel.active {
    display: block;
}

.tms-courses-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 20px;
}

.tms-course-card {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 0px 5px rgba(0, 0, 0, 0.1);
}

.tms-course-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e0e0e0;
}

.tms-course-title {
    font-size: 18px;
    margin: 0;
    color: #333;
}

.tms-course-code {
    background: #F88C00;
    color: white;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 12px;
}

.tms-course-info p {
    margin: 8px 0;
    color: #666;
    font-size: 14px;
}

.tms-course-exam {
    margin: 20px 0;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 6px;
}

.tms-course-exam h4 {
    margin: 0 0 15px 0;
    color: #333;
    font-size: 16px;
}

.tms-exam-type-selector {
    display: flex;
    gap: 20px;
    margin-bottom: 15px;
}

.tms-exam-type-selector label {
    display: flex;
    align-items: center;
    gap: 5px;
    cursor: pointer;
}

.tms-exam-settings {
    padding: 10px;
    background: white;
    border-radius: 4px;
}

.tms-warning {
    color: #856404;
    background: #fff3cd;
    padding: 10px;
    border-radius: 4px;
    margin: 10px 0;
}

.tms-note {
    color: #666;
    font-size: 13px;
    margin: 5px 0;
}

.tms-course-actions {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #e0e0e0;
}

.tms-button {
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tms-button-small {
    padding: 6px 12px;
    font-size: 13px;
}

.tms-button-primary {
    background: #F88C00;
    color: white;
}

.tms-button-primary:hover {
    background: #F88C00;
}

.tms-button-secondary {
    background: #6c757d;
    color: white;
}

.tms-button-secondary:hover {
    background: #545b62;
}
.ld-course-list-items {
    display: flex;
    flex-wrap: wrap;
}
.tms-students-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.tms-students-table thead {
    background: #f8f9fa;
}

.tms-students-table th {
    padding: 15px 12px;
    text-align: left;
    font-weight: 600;
    font-size: 14px;
    color: #555;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.tms-students-table tbody tr {
    border-bottom: 1px solid #e0e0e0;
    transition: background-color 0.2s ease;
}

.tms-students-table tbody tr:hover {
    background-color: #f8f9fa;
}

.tms-students-table td {
    padding: 12px;
}

.tms-exam-type-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.tms-exam-type-online {
    background: #d1ecf1;
    color: #0c5460;
}

.tms-exam-type-offline {
    background: #d4edda;
    color: #155724;
}

.tms-exam-type-none {
    background: #e2e3e5;
    color: #383d41;
}

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

.tms-exam-status-pending {
    background: #fff3cd;
    color: #856404;
}

.tms-exam-status-passed {
    background: #d4edda;
    color: #155724;
}

.tms-exam-status-failed {
    background: #f8d7da;
    color: #721c24;
}

.tms-loading {
    text-align: center;
    padding: 40px;
    color: #666;
}

.tms-no-data {
    text-align: center;
    padding: 40px;
    color: #999;
}

.tms-modal {
    display: block;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
}

.tms-modal-content {
    background-color: white;
    margin: 5% auto;
    padding: 0;
    border-radius: 8px;
    width: 90%;
    max-width: 800px;
    max-height: 80vh;
    overflow-y: auto;
}

.tms-modal-header {
    padding: 20px;
    border-bottom: 1px solid #e0e0e0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.tms-modal-header h3 {
    margin: 0;
    color: #333;
}

.tms-modal-close {
    background: none;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: #999;
}

.tms-modal-close:hover {
    color: #333;
}

.tms-modal-body {
    padding: 20px;
    max-height: 55vh;
    overflow-y: auto;
}

.tms-modal-footer {
    padding: 20px;
    border-top: 1px solid #e0e0e0;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.tms-offline-exam-table {
    width: 100%;
    border-collapse: collapse;
}

.tms-offline-exam-table th,
.tms-offline-exam-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

.tms-score-input {
    width: 100px;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.tms-status-select {
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
}
.tms-edit-score-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.tms-edit-score-form .tms-form-group .tms-form-control {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
}
.tms-review-homework-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}
.tms-review-homework-form .tms-form-group .tms-form-control {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
}
.tms-homework-files-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.tms-homework-link {
    display: inline-flex;
    align-items: center;
    padding: 8px 12px;
    background: #f5f5f5;
    border-radius: 4px;
    color: #309a06;
    text-decoration: none;
    font-size: 14px;
    transition: background 0.2s;
}
.tms-homework-link:hover {
    background: #e8e8e8;
    color: #247a05;
}
.tms-homework-status-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}
.tms-homework-status-pending {
    background: #fff3cd;
    color: #856404;
}
.tms-homework-status-pass {
    background: #d4edda;
    color: #155724;
}
.tms-homework-status-fail {
    background: #f8d7da;
    color: #721c24;
}
@media (max-width: 1024px) {
    .tms-tabs {
        gap: 3px;
        margin-bottom: 20px;
    }

    .tms-tab-button {
        padding: 6px 12px;
        font-size: 13px;
    }
}
@media (max-width: 768px) {
    .income-summary-container {
        padding: 10px 0;
    }
    .tms-instructor-attendance-container {
        padding: 10px 0;
    }
    .gwat-myaccount-container {
        display: flex !important;
        flex-direction: column;
    }
    .has-global-padding {
        padding-right: 15px;
        padding-left: 15px;
    }
    .tms-courses-grid {
        grid-template-columns: 1fr;
    }
    
    .tms-course-detail {
        padding: 20px;
    }
    
    .tms-schedule-table {
        font-size: 14px;
    }
    .tms-course-list-item {
        flex-direction: column;
        align-items: flex-start;
        padding: 10px;
        font-size: 14px;
    }
    .tms-left {
        flex-direction: column;
        align-items: flex-start;
    }
    .tms-right {
        padding-top: 10px;
        width: 100%;
        display: flex;
        align-items: center;
        justify-content:center;
        gap: 20px;
        flex-direction: row;
    }
    .tms-button{
        width: auto;
    }
    .woocommerce-MyAccount-navigation-left .dropdown-menu {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    .tms-modal-content {
        width: 95%;
        max-height: 95vh;
    }
    
    .tms-modal-header,
    .tms-modal-body,
    .tms-modal-footer {
        padding: 15px;
    }
    
    .tms-course-students-table th,
    .tms-course-students-table td {
        padding: 8px 10px;
        font-size: 13px;
    }
    
    .tms-modal-footer {
        flex-direction: column;
    }
    
    .tms-modal-footer button {
        width: 100%;
    }
    .tms-courses-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .tms-course-card {
        padding: 15px;
    }
    
    .tms-course-title {
        font-size: 16px;
    }
    
    .tms-course-info p {
        font-size: 13px;
    }
    
    .tms-exam-type-selector {
        flex-direction: column;
        gap: 8px;
    }
    
    .tms-course-actions {
        flex-direction: column;
    }
    
    .tms-button-small {
        width: 100%;
        text-align: center;
    }
    .tms-tabs {
        display: flex;
        flex-wrap: wrap;
        gap: 3px;
        margin-bottom: 16px;
        padding: 4px;
        background: rgba(118, 118, 128, 0.12);
        border-radius: 10px;
        -webkit-backdrop-filter: blur(10px);
        backdrop-filter: blur(10px);
    }

    .tms-tab-button {
        flex: 0 0 auto;
        min-width: 0;
        padding: 6px 10px;
        font-size: 13px;
        border-radius: 7px;
        justify-content: center;
        text-align: center;
        line-height: 1.3;
        gap: 4px;
    }

    .tms-tab-button.active {
        background: #fff;
        box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08), 0 1px 1px rgba(0, 0, 0, 0.04);
    }

    .tms-tab-button.active::after {
        display: none;
    }

    .tms-tab-button:hover {
        background: rgba(255, 255, 255, 0.55);
    }

    .tms-tab-button.active:hover {
        background: #fff;
    }

    .tms-session-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .tms-session-info {
        flex-wrap: wrap;
    }
    
    .tms-attendance-table {
        font-size: 12px;
    }
    
    .tms-attendance-table th,
    .tms-attendance-table td {
        padding: 8px 6px;
    }

    .tms-courses-grid {
        grid-template-columns: 1fr;
    }
    
    .tms-students-table {
        font-size: 12px;
    }
    
    .tms-students-table th,
    .tms-students-table td {
        padding: 8px 6px;
    }
}

@media (max-width: 480px) {
    .tms-instructor-courses-container {
        padding: 15px;
    }

    .tms-course-card {
        padding: 12px;
    }

    .tms-course-title {
        font-size: 15px;
    }

    .tms-course-code {
        font-size: 11px;
        padding: 3px 8px;
    }

    .tms-tabs {
        gap: 2px;
        padding: 3px;
        border-radius: 8px;
    }

    .tms-tab-button {
        padding: 5px 8px;
        font-size: 12px;
        border-radius: 6px;
    }

    .tms-tab-count {
        min-width: 16px;
        height: 16px;
        font-size: 10px;
        padding: 0 4px;
        border-radius: 8px;
    }
}

.tms-booking-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999999;
    padding: 20px;
}

.tms-booking-modal {
    background: #fff;
    border-radius: 12px;
    width: 100%;
    max-width: 800px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

.tms-booking-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 25px;
    border-bottom: 1px solid #e0e0e0;
    flex-shrink: 0;
}

.tms-booking-modal-header h3 {
    margin: 0 !important;
    font-size: 20px;
    color: #333;
}

.tms-modal-close-btn {
    background: none;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: #666;
    padding: 0;
    line-height: 1;
}

.tms-modal-close-btn:hover {
    color: #333;
}

.tms-booking-modal-body {
    padding: 20px 25px;
    flex: 1 1 auto;
    overflow-y: auto;
    min-height: 0;
}
.tms-booking-modal-body input {
    width: 100%;
}

.tms-course-info-card {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 10px;
    padding: 18px;
    margin-bottom: 20px;
    border: 1px solid #dee2e6;
}

.tms-course-info-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 12px;
    border-bottom: 1px solid #ced4da;
}

.tms-course-info-title {
    font-size: 18px;
    font-weight: 700;
    color: #309a06;
}

.tms-course-info-price {
    font-size: 20px;
    font-weight: 700;
    color: #d63638;
}

.tms-course-info-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.tms-course-info-item {
    display: flex;
    flex-wrap: wrap;
}

.tms-course-info-item .tms-info-label {
    color: #666;
    margin-right: 5px;
}

.tms-course-info-item .tms-info-value {
    color: #000;
    font-weight: 500;
    width: 66%;
}

.tms-form-divider {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin: 16px 0 12px 0;
    padding-bottom: 8px;
    border-bottom: 2px solid #309a06;
}

.tms-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 14px;
}

.tms-form-group {
    display: flex;
    flex-direction: column;
}

.tms-form-group.full-width {
    grid-column: 1 / -1;
}

/* 單行緊湊佈局：label 和 radio 在同一行 */
.tms-form-row-inline {
    grid-template-columns: 1fr;
    margin-bottom: 10px;
}
.tms-form-group-inline {
    flex-direction: row;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}
.tms-form-group-inline > label {
    margin-bottom: 0;
    flex: 0 1 auto;
}
.tms-form-group-inline .tms-radio-group {
    margin-top: 0;
}
.tms-fee-tag {
    display: inline-block;
    background: #fff3cd;
    color: #8a6a00;
    font-size: 12px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 10px;
    margin-left: 4px;
    border: 1px solid #ffe7a0;
}

.tms-form-group label {
    font-weight: 600;
    margin-bottom: 4px;
    color: #333;
    font-size: 13px;
}

.tms-field-hint {
    font-size: 12px;
    color: #888;
    margin: 4px 0 0 0;
}

.tms-form-input {
    padding: 9px 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.tms-form-input:focus {
    outline: none;
    border-color: #309a06;
    box-shadow: 0 0 0 3px rgba(48, 154, 6, 0.1);
}

.tms-form-input::placeholder {
    color: #aaa;
}

textarea.tms-form-input {
    resize: vertical;
    min-height: 50px;
}

.tms-radio-group {
    display: flex;
    gap: 25px;
    margin-top: 8px;
}

.tms-radio-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 14px;
}

.tms-radio-label input[type="radio"] {
    width: 18px;
    height: 18px;
    accent-color: #309a06;
}

.required {
    color: #d63638;
}

.tms-form-error {
    background: #fff0f0;
    color: #d63638;
    padding: 12px 15px;
    border-radius: 8px;
    margin-top: 10px;
    font-size: 14px;
    border: 1px solid #ffccd5;
}

.tms-booking-modal-footer {
    display: flex;
    justify-content: space-between;
    gap: 15px;
    padding: 15px 25px;
    border-top: 1px solid #e0e0e0;
    background: #f9f9f9;
    border-radius: 0 0 12px 12px;
    flex-shrink: 0;
}

.tms-button-secondary {
    background: #6c757d;
    color: #fff;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: background 0.2s;
}


.tms-button-secondary:hover {
    background: #5a6268;
}

.tms-button-success {
    background: #309a06;
    color: #fff;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: background 0.2s;
}

.tms-button-success:hover {
    background: #267a05;
}

.tms-button-success:disabled {
    background: #ccc;
    cursor: not-allowed;
}
#tms-online-courses {
    max-width: 1200px;
    margin: 0 auto;
}

@media (max-width: 600px) {
    .tms-form-row {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }
    .tms-form-row.tms-form-row-inline {
        grid-template-columns: 1fr;
    }
    
    .tms-booking-modal {
        max-height: 95vh;
    }
    
    .tms-booking-modal-header,
    .tms-booking-modal-body,
    .tms-booking-modal-footer {
        padding: 15px;
    }
    
    .tms-booking-modal-footer {
        flex-direction: column;
    }
    
    .tms-booking-modal-footer button {
        width: 100%;
    }
    
    .tms-radio-group {
        flex-direction: column;
        gap: 12px;
    }
    
    .tms-course-info-details {
        grid-template-columns: 1fr;
    }
    
    .tms-course-info-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    
    .tms-course-info-title {
        font-size: 16px;
    }
    
    .tms-course-info-price {
        font-size: 18px;
    }

    /* buy-modal 手機版：footer 保持橫向，聲明在上按鈕在下 */
    .tms-buy-modal-footer {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }
    .tms-buy-declaration {
        min-width: 0;
    }
    .tms-buy-actions {
        justify-content: stretch;
    }
    .tms-buy-actions button {
        flex: 1;
    }
    /* inline 表單組在手機上恢復垂直排列 */
    .tms-form-group-inline {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }
    .tms-form-group-inline .tms-radio-group {
        flex-direction: row;
        gap: 20px;
    }
}

.tms-video-reviewers-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0;
}

.tms-section-title {
    font-size: 24px;
    margin-bottom: 20px;
    color: #333;
}

.tms-video-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.tms-video-table th,
.tms-video-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

.tms-video-table th {
    background: #f8f9fa;
    font-weight: 600;
    color: #333;
}

.tms-video-table tr:hover {
    background: #f5f5f5;
}

.tms-video-link {
    color: #007bff;
    text-decoration: none;
}

.tms-video-link:hover {
    text-decoration: underline;
}

.tms-status {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.tms-status-pending {
    background: #fff3cd;
    color: #856404;
}

.tms-status-pass {
    background: #d4edda;
    color: #155724;
}

.tms-status-fail {
    background: #f8d7da;
    color: #721c24;
}

.tms-button-sm {
    padding: 6px 12px;
    font-size: 12px;
}

.tms-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-top: 20px;
    padding: 15px 0;
}

.tms-pagination-btn {
    padding: 8px 16px;
    background: #007bff;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tms-pagination-btn:hover:not(:disabled) {
    background: #0056b3;
}

.tms-pagination-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.tms-pagination-info {
    color: #666;
    font-size: 14px;
}

.tms-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.tms-modal-content {
    background: #fff;
    border-radius: 8px;
    width: 90%;
    /* max-width: 500px; */
    max-height: 90vh;
    overflow-y: auto;
}

.tms-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    border-bottom: 1px solid #e0e0e0;
}
.tms-button-cart {
    position: fixed;
    bottom: 50px;
    right: 50px;
    z-index: 9999;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}
.tms-button-cart .cart-count {
    position: absolute;
    width: 20px;
    height: 20px;
    
    top: -5px;
    right: -5px;
    background: #ff4d4f;
    color: #fff;
    border-radius: 50%;
    font-size: 12px;
}
.tms-modal-header h3 {
    margin: 0;
    font-size: 18px;
}

.tms-modal-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #666;
}

.tms-modal-close:hover {
    color: #333;
}

.tms-modal-body {
    padding: 20px;
}

.tms-modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 15px 20px;
    border-top: 1px solid #e0e0e0;
}

[v-cloak] {
    display: none;
}
.tms-revenue-cards {
    display: flex;
    flex-direction: column;
    gap: 15px;
}
.tms-revenue-card {
    border: 1px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
}
.tms-revenue-card-header {
    background: #f5f5f5;
    padding: 10px 15px;
    border-bottom: 1px solid #ddd;
    display: flex;
    align-items: center;
    gap: 10px;
}
.tms-revenue-course-code {
    font-weight: bold;
    color: #0073aa;
}
.tms-revenue-course-name {
    color: #333;
}
.tms-revenue-card-body {
    padding: 15px;
}
.tms-revenue-row {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 10px;
}
.tms-revenue-row:last-child {
    margin-bottom: 0;
}
.tms-revenue-item {
    flex: 1;
    min-width: 120px;
}
.tms-revenue-label {
    display: block;
    font-size: 12px;
    color: #666;
    margin-bottom: 3px;
}
.tms-revenue-value {
    font-weight: 500;
}
.tms-revenue-card-footer {
    background: #f9f9f9;
    padding: 10px 15px;
    border-top: 1px solid #ddd;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.tms-revenue-total {
    font-size: 18px;
    font-weight: bold;
    color: #5cb85c;
}

.tms-checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    cursor: pointer;
    font-size: 14px;
    line-height: 1.5;
}

.tms-checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #309a06;
    margin-top: 2px;
    flex-shrink: 0;
}

/* 結賬彈窗 Footer：聲明在左，按鈕在右 */
.tms-buy-modal-footer {
    flex-wrap: wrap;
    align-items: center;
}
.tms-buy-declaration {
    flex: 1 1 auto;
    min-width: 200px;
}
.tms-buy-declaration .tms-checkbox-label {
    align-items: center;
    margin: 0;
}
.tms-buy-actions {
    display: flex;
    gap: 10px;
    flex-shrink: 0;
}

.tms-link {
    color: #0073aa;
    text-decoration: underline;
    cursor: pointer;
}

.tms-link:hover {
    color: #005177;
}

.tms-declaration-content {
    line-height: 1.8;
    color: #333;
}

/* Revenue Summary Table Styles */
.tms-table-header { background: #f5f5f5 !important; }
.tms-table-header th { padding: 12px 10px; text-align: left; font-weight: 600; color: #333; border: 1px solid #ddd; }
.tms-align-right { text-align: right !important; }
.tms-align-center { text-align: center !important; }
.tms-data-row { background: #fff; }
.tms-row-even { background: #fff; }
.tms-row-odd { background: #fafafa; }
.revenue-summary-table tr td { padding: 10px; border: 1px solid #ddd; }
.tms-course-code-cell { font-weight: 500; color: #333; vertical-align: middle; text-align: left; }
.tms-center-cell { text-align: center; color: #666; }
.tms-right-cell { text-align: right; color: #333; }
.tms-fee-color { color: #d9534f; }
.tms-income-cell { color: #5cb85c; font-weight: 600; }
.tms-subtotal-row { background: #e8f4f8 !important; font-weight: 600; }
.tms-total-row { background: #dff0d8 !important; font-weight: 700; font-size: 15px; border: 2px solid #5cb85c !important; }
.tms-total-row td { border: 2px solid #5cb85c !important; padding: 14px 10px; }
.tms-total-cell { text-align: center; color: #3c763d; }

.payment-credit-card { color: #007bff; font-weight: 500; }
.payment-alipay { color: #1677ff; font-weight: 500; }
.payment-payme { color: #00C851; font-weight: 500; }
.payment-fps { color: #FF6B35; font-weight: 500; }
.payment-cash { color: #6c757d; font-weight: 500; }

/* Income Summary Tab Styles */
.income-summary-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0;
}

.tms-income-filters {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
    align-items: center;
    background: #f9f9f9;
    padding: 15px 20px;
    border-radius: 8px;
}

.tms-filter-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.tms-filter-group label {
    font-weight: 600;
    color: #333;
    font-size: 14px;
}

.tms-month-input {
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    min-width: 180px;
}

.tms-income-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.tms-income-card {
    background: white;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    display: flex;
    align-items: center;
    gap: 18px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-left: 5px solid #007bff;
}

.tms-income-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.12);
}

.tms-card-total { border-left-color: #007bff; }
.tms-card-fees { border-left-color: #d9534f; }
.tms-card-net { border-left-color: #5cb85c; }

.tms-income-card-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    font-weight: bold;
    flex-shrink: 0;
}

.tms-card-fees .tms-income-card-icon {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.tms-card-net .tms-income-card-icon {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.tms-income-card-info h4 {
    margin: 0 0 8px 0;
    font-size: 13px;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}

.tms-income-amount {
    margin: 0;
    font-size: 26px;
    font-weight: 700;
    color: #333;
}

@media (max-width: 768px) {
    .tms-income-filters {
        flex-direction: column;
        align-items: stretch;
    }

    .tms-filter-group {
        flex-direction: column;
        align-items: stretch;
    }

    .tms-month-input {
        width: 100%;
    }

    .tms-income-cards {
        grid-template-columns: 1fr;
    }

    .tms-income-card {
        padding: 18px;
    }

    .tms-income-amount {
        font-size: 22px;
    }
}

/* Desktop/Mobile Toggle */
.tms-desktop-only { display: block; }
.tms-mobile-only { display: none; }

@media (max-width: 768px) {
    .tms-desktop-only { display: none !important; }
    .tms-mobile-only { display: block !important; }
}

/* Mobile Income Cards */
.tms-income-courses-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 20px;
}

.tms-course-income-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.tms-course-card-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 15px 18px;
}

.tms-course-code-title {
    margin: 0;
    color: white;
    font-size: 16px;
    font-weight: 600;
}

.tms-course-payments-list {
    padding: 15px 18px;
}

.tms-payment-item {
    background: #f9f9f9;
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 12px;
}

.tms-payment-item:last-child {
    margin-bottom: 0;
}

.tms-payment-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    padding-bottom: 8px;
    border-bottom: 1px solid #e0e0e0;
}

.tms-payment-label {
    font-weight: 600;
    color: #333;
    font-size: 14px;
}

.tms-payment-method-badge {
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    background: rgba(0,0,0,0.05);
}

.tms-payment-details {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.tms-detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
}

.tms-detail-label {
    color: #666;
}

.tms-detail-value {
    font-weight: 600;
    color: #333;
}

.tms-net-row {
    padding-top: 6px;
    margin-top: 6px;
    border-top: 1px dashed #ddd;
}

.tms-course-subtotal {
    background: #e8f4f8;
    padding: 15px 18px;
    border-top: 2px solid #0073aa;
}

.tms-subtotal-row-mobile {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
    font-size: 14px;
}

.tms-subtotal-label {
    color: #666;
    font-weight: 500;
}

.tms-subtotal-value {
    font-weight: 600;
    color: #333;
}

.tms-total-net-row {
    padding-top: 10px;
    margin-top: 8px;
    border-top: 1px solid #b8d4e3;
}

.tms-mobile-total-card {
    background: linear-gradient(135deg, #dff0d8 0%, #d4edda 100%);
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 4px 12px rgba(92, 184, 92, 0.2);
    border: 2px solid #5cb85c;
}

.tms-mobile-total-card h4 {
    margin: 0 0 15px 0;
    color: #3c763d;
    font-size: 18px;
    text-align: center;
    padding-bottom: 12px;
    border-bottom: 2px solid #5cb85c;
}

.tms-total-breakdown {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.tms-total-row-mobile {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    font-size: 15px;
}

.tms-total-row-mobile span {
    color: #3c763d;
}

.tms-total-row-mobile strong {
    font-size: 16px;
}

.tms-final-total {
    padding-top: 12px;
    margin-top: 8px;
    border-top: 2px solid #5cb85c;
    font-size: 16px;
}

.tms-final-total strong {
    font-size: 18px;
}
.tms-required {
    color: red;
}

/* ============================================
   统一卡片式 Income Summary（PC + 移动端）
   ============================================ */

/* 区域标题 */
.tms-section-title {
    margin: 30px 0 18px;
    font-size: 18px;
    font-weight: 600;
    color: #2c3e50;
    padding-bottom: 10px;
    border-bottom: 3px solid #0073aa;
    display: flex;
    align-items: center;
    gap: 8px;
}

.tms-section-title::before {
    content: "";
    display: inline-block;
    width: 5px;
    height: 22px;
    background: linear-gradient(180deg, #0073aa 0%, #00b4d8 100%);
    border-radius: 3px;
}

.tms-section-title-course {
    border-bottom-color: #0073aa;
    color: #0073aa;
}

.tms-section-title-activity {
    border-bottom-color: #ff9800;
    color: #e65100;
}

.tms-section-title-activity::before {
    background: linear-gradient(180deg, #ff9800 0%, #ffb74d 100%);
}

/* Session 卡片（统一 PC+移动） */
.session-income-section,
.revenue-summary-section {
    margin-bottom: 30px;
}

.tms-activity-list {
    display: grid;
    /* grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); */
    gap: 18px;
    margin-bottom: 22px;
}

.tms-activity-card {
    background: #ffffff;
    border-radius: 14px;
    padding: 0;
    box-shadow: 0 4px 14px rgba(255, 152, 0, 0.10);
    border-left: 5px solid #ff9800;
    overflow: hidden;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.tms-activity-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(255, 152, 0, 0.18);
}

.tms-activity-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 18px;
    background: linear-gradient(135deg, #fff3e0 0%, #ffe0b2 100%);
    border-bottom: 1px solid rgba(255, 152, 0, 0.2);
}

.tms-activity-org {
    margin: 0;
    font-size: 15px;
    font-weight: 600;
    color: #e65100;
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.tms-status-badge {
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    flex-shrink: 0;
    margin-left: 10px;
}

.tms-status-completed {
    color: #155724;
    background: #d4edda;
}

.tms-status-scheduled {
    color: #856404;
    background: #fff3cd;
}

.tms-activity-card-subtitle {
    padding: 10px 18px 4px;
    background: #fffaf0;
}

.tms-activity-name {
    font-size: 13px;
    color: #666;
    font-style: italic;
}

.tms-activity-details {
    padding: 12px 18px 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.tms-detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    padding: 4px 0;
}

.tms-detail-label {
    color: #666;
    font-weight: 500;
}

.tms-detail-value {
    color: #2c3e50;
    font-weight: 600;
    text-align: right;
}

.tms-net-row {
    margin-top: 6px;
    padding-top: 10px;
    border-top: 2px dashed #f0f0f0;
}

.tms-billable-hours {
    color: #0073aa;
    font-weight: 700;
}

.tms-original-instructor {
    color: #999;
    font-style: italic;
    font-size: 12px;
}

/* Role 颜色 */
.tms-role-main {
    color: #1565c0;
    font-weight: 600;
    padding: 2px 8px;
    background: rgba(21, 101, 192, 0.1);
    border-radius: 4px;
    font-size: 12px;
}

.tms-role-assistant {
    color: #e65100;
    font-weight: 600;
    padding: 2px 8px;
    background: rgba(230, 81, 0, 0.1);
    border-radius: 4px;
    font-size: 12px;
}

.tms-role-substitute {
    color: #ff9800;
    font-weight: 600;
    padding: 2px 8px;
    background: rgba(255, 152, 0, 0.1);
    border-radius: 4px;
    font-size: 12px;
}

/* Session 收入汇总卡片 */
.tms-activity-total-card {
    background: linear-gradient(135deg, #fff8e1 0%, #ffecb3 100%);
    border-radius: 12px;
    padding: 18px 22px;
    margin-top: 8px;
    box-shadow: 0 2px 8px rgba(255, 152, 0, 0.1);
    border-top: 3px solid #ff9800;
}

.tms-activity-total-card h4 {
    margin: 0 0 12px 0;
    color: #e65100;
    font-size: 15px;
    font-weight: 600;
}

/* Grand Total 统一卡片（PC + 移动端） */
.tms-grand-total-section {
    margin-top: 24px;
    padding: 22px 24px;
    background: linear-gradient(135deg, #0073aa 0%, #005177 100%);
    color: #ffffff;
    border-radius: 14px;
    box-shadow: 0 6px 20px rgba(0, 115, 170, 0.25);
}

.tms-grand-total-breakdown-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.tms-grand-total-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    font-size: 14px;
}

.tms-grand-total-row:not(:last-child) {
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.tms-grand-total-row-label {
    font-weight: 500;
    color: rgba(255, 255, 255, 0.85);
}

.tms-grand-total-row-value {
    font-weight: 700;
    color: #ffffff;
}

.tms-grand-total-final {
    margin-top: 8px;
    padding-top: 14px;
    border-bottom: none;
    border-top: 2px solid rgba(255, 255, 255, 0.3);
    font-size: 18px;
}

.tms-grand-total-final .tms-grand-total-row-label {
    font-weight: 700;
    color: #ffd54f;
}

.tms-grand-total-final .tms-grand-total-row-value {
    font-size: 22px;
    color: #ffd54f;
}

/* 颜色辅助类 */
.tms-pending-color {
    color: #ff9800 !important;
}

.tms-paid-color {
    color: #5cb85c !important;
}

.tms-fee-color {
    color: #d9534f !important;
}

.tms-income-cell {
    color: #5cb85c !important;
    font-weight: 700;
}

.tms-status-pending {
    color: #ff9800;
    font-weight: 600;
}

.tms-status-paid {
    color: #5cb85c;
    font-weight: 600;
}

/* 响应式 */
@media (max-width: 768px) {
    .tms-section-title {
        font-size: 16px;
        margin: 22px 0 14px;
    }

    .tms-activity-list {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .tms-activity-card-header {
        padding: 12px 14px;
    }

    .tms-activity-org {
        font-size: 14px;
    }

    .tms-activity-details {
        padding: 10px 14px 14px;
        gap: 6px;
    }

    .tms-detail-row {
        font-size: 12px;
    }


    .tms-grand-total-section {
        padding: 18px 16px;
    }

    .tms-grand-total-row {
        font-size: 13px;
    }

    .tms-grand-total-final {
        font-size: 16px;
    }

    .tms-grand-total-final .tms-grand-total-row-value {
        font-size: 18px;
    }
}

@media (min-width: 1200px) {
    .tms-activity-list {
        /* grid-template-columns: repeat(3, 1fr); */
    }
}
