/* èªå®ä¹ç®¡çåå°æ ·å¼ - ä¿®å¤å¸å± */

/* ========== æ´ä½å¸å± - ä½¿ç¨flex ========== */
#container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    padding-top: 60px;
}

/* ========== Header ç»ä»¶ ========== */
#header {
    background: #2c3e50;
    color: white;
    padding: 0 20px;
    height: 60px;
    box-sizing: border-box;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
}

#branding h1 {
    margin: 0;
    padding: 0;
    line-height: 60px;
}

#branding a {
    color: white;
    text-decoration: none;
    font-size: 18px;
    font-weight: bold;
}

#user-tools {
    color: white;
    font-size: 13px;
}

#user-tools a {
    color: white;
    text-decoration: none;
    margin-left: 10px;
}

#user-tools a:hover {
    text-decoration: underline;
}

/* ========== Breadcrumbs é¢åå± ========== */
.breadcrumbs {
    background: #ecf0f1;
    padding: 10px 20px;
    border-bottom: 1px solid #ddd;
    font-size: 12px;
    flex-shrink: 0;
}

.breadcrumbs a {
    color: #34495e;
    text-decoration: none;
}

.breadcrumbs a:hover {
    text-decoration: underline;
}

/* ========== Content åå®¹åºå - å³é®ï¼å·¦å³å¸å± ========== */
#content {
    display: flex !important;
    flex-direction: row !important;
    flex: 1;
    padding: 0 !important;
    background: #f5f5f5;
    overflow: visible;
    position: relative;
    z-index: 100;
}

/* ========== Menu èåç»ä»¶ - å·¦ä¾§åºå® ========== */
#nav-sidebar {
    width: 220px !important;
    min-width: 220px !important;
    max-width: 220px !important;
    background: #34495e;
    padding: 0;
    flex-shrink: 0;
    overflow-y: auto;
    max-height: calc(100vh - 50px);
    order: 1;
    position: relative;
    z-index: 10;
}

/* éèDjangoé»è®¤çappåè¡¨ */
#nav-sidebar .module {
    display: none !important;
}

.app-list {
    margin-bottom: 0;
}

.app-list h2 {
    font-size: 12px;
    font-weight: bold;
    margin: 0;
    color: #ecf0f1;
    background: #2c3e50;
    padding: 12px 15px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.app-header {
    cursor: pointer;
    user-select: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.app-header:hover {
    background: #1a252f;
}

.toggle-icon {
    font-size: 10px;
    transition: transform 0.3s ease;
}

.app-list.collapsed .toggle-icon {
    transform: rotate(-90deg);
}

.app-list.collapsed .model-list {
    display: none;
}

.model-list {
    list-style: none;
    padding: 0;
    margin: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.model-list li {
    margin: 0;
    border-bottom: 1px solid #2c3e50;
}

.model-list a {
    display: block;
    padding: 12px 15px 12px 25px;
    color: #bdc3c7;
    text-decoration: none;
    font-size: 13px;
    transition: all 0.3s;
}

.model-list a:hover {
    background: #3498db;
    color: white;
}

.model-list a.current-model {
    background: #3498db;
    color: white;
    border-left: 4px solid #2ecc71;
}

.change-form .aligned label {
    width: 200px !important;
}

.change-form .aligned .vTextField {
    width: 600px !important;
}

.change-form .aligned .vLargeTextField,
.change-form .aligned textarea {
    width: 800px !important;
    height: 500px !important;
}

.change-form .aligned select {
    width: 600px !important;
}

.change-form .aligned label + div {
    margin-left: 220px !important;
}

.change-form .form-row {
    padding: 6px 0 !important;
}

.change-form .aligned .form-row.datetime input {
    width: auto !important;
}

.change-form .aligned .form-row.datetime .datetime.date {
    float: left;
    margin-right: 20px;
}

.change-form .aligned .form-row.datetime .datetime.time {
    float: left;
}

.change-form .aligned .form-row.field-content label {
    display: none !important;
}

.change-form .aligned .form-row.field-content div {
    margin-left: 0 !important;
}

.change-form .aligned .form-row.field-content .django-ckeditor-widget,
.change-form .aligned .form-row.field-content textarea {
    width: 100% !important;
}

.change-form .aligned .form-row.field-content .cke {
    width: 100% !important;
}

/* ========== Main Content ä¸»åå®¹åº - å³ä¾§èªéåº ========== */
#content-main {
    flex: 1 !important;
    order: 2;
    background: white;
    padding: 20px;
    margin: 0 !important;
    overflow-y: auto;
    max-height: calc(100vh - 50px);
    width: auto !important;
    float: none !important;
    position: relative;
    z-index: 150;
}

/* ========== æ¶é´éæ©å¨ä¿®å¤ ========== */
.calendar-popup, .time-popup {
    z-index: 10000 !important;
    position: fixed !important;
    transform: none !important;
}

/* ç¡®ä¿ææå¼¹åºåç´ é½å¨æä¸å± */
.popup, .ui-datepicker, .bootstrap-datetimepicker-widget {
    z-index: 10000 !important;
    position: fixed !important;
}

/* ä¿®å¤è¡¨åä¸­çæ¶é´è¾å¥åºå */
.form-row {
    position: relative;
}

/* ç¡®ä¿æ¶é´éæ©å¨æé®ä¸ä¼è¢«é®æ¡ */
.vDateField, .vTimeField {
    position: relative;
    z-index: 10;
}

/* ========== ä¸æéæ©æ¡ä¿®å¤ ========== */
/* ç¡®ä¿ä¸æéæ©æ¡æ¾ç¤ºå®æ´ */
select {
    min-height: 34px !important;
    padding: 6px 12px !important;
    font-size: 14px !important;
    line-height: 1.5 !important;
    color: #495057 !important;
    background-color: #fff !important;
    background-clip: padding-box !important;
    border: 1px solid #ced4da !important;
    border-radius: 4px !important;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out !important;
    position: relative !important;
    z-index: 10 !important;
}

/* ç¡®ä¿ä¸æéé¡¹æ¾ç¤ºå®æ´ */
select option {
    padding: 6px 12px !important;
    font-size: 14px !important;
    line-height: 1.5 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

/* ç¡®ä¿è¡¨åè¡ä¸­çä¸æéæ©æ¡æè¶³å¤çç©ºé´ */
.form-row select {
    width: 100% !important;
    min-width: 300px !important;
    max-width: 500px !important;
}

/* ä¿®å¤Django adminé»è®¤çéæ©æ¡æ ·å¼ */
.vForeignKeyRawIdAdminField, .vManyToManyRawIdAdminField {
    position: relative !important;
    z-index: 10 !important;
}

/* ç¡®ä¿ç¸å³çè¾å¥æ¡ä¹è½æ­£å¸¸æ¾ç¤º */
.vTextField, .vIntegerField, .vFloatField, .vDecimalField {
    min-height: 34px !important;
    padding: 6px 12px !important;
    font-size: 14px !important;
    line-height: 1.5 !important;
    color: #495057 !important;
    background-color: #fff !important;
    background-clip: padding-box !important;
    border: 1px solid #ced4da !important;
    border-radius: 4px !important;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out !important;
    position: relative !important;
    z-index: 10 !important;
}

/* ç¡®ä¿è¡¨åè¡æè¶³å¤çç©ºé´ */
.form-row {
    margin-bottom: 15px !important;
    padding: 10px !important;
    background: #f8f9fa !important;
    border: 1px solid #dee2e6 !important;
    border-radius: 4px !important;
}

/* ç¡®ä¿å­æ®µæ ç­¾æè¶³å¤çç©ºé´ */
.form-row label {
    display: block !important;
    margin-bottom: 5px !important;
    font-weight: 600 !important;
    font-size: 14px !important;
    color: #495057 !important;
}

/* ========== æééæ©è¡¨æ ¼ç¾å ========== */
/* å å®½æééæ©åºå */
.form-row select[multiple] {
    width: 100% !important;
    min-width: 400px !important;
    max-width: 600px !important;
    min-height: 300px !important;
    padding: 8px !important;
    border: 1px solid #ced4da !important;
    border-radius: 4px !important;
    font-size: 14px !important;
    line-height: 1.5 !important;
    background-color: #fff !important;
    background-clip: padding-box !important;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out !important;
}

/* ç¾åå¤éæ¡éé¡¹ */
.form-row select[multiple] option {
    padding: 6px 12px !important;
    line-height: 1.5 !important;
}

/* é¼ æ æ¬åææ */
.form-row select[multiple] option:hover {
    background-color: #e9ecef !important;
    cursor: pointer;
}

/* èç¦ææ */
.form-row select[multiple]:focus {
    border-color: #80bdff !important;
    outline: 0 !important;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25) !important;
}

/* æééç½®åºåæ ·å¼ */
fieldset.collapsed {
    margin-bottom: 20px !important;
}

fieldset {
    margin-bottom: 20px !important;
    border: 1px solid #dee2e6 !important;
    border-radius: 4px !important;
    padding: 15px !important;
    background-color: #f8f9fa !important;
}

fieldset legend {
    font-weight: bold !important;
    color: #495057 !important;
    padding: 0 10px !important;
    margin-bottom: 10px !important;
}

/* ========== Footer ç»ä»¶ - åè¡å±ä¸­ ========== */
#footer {
    background: #2c3e50;
    padding: 15px 20px;
    border-top: 1px solid #34495e;
    color: #bdc3c7;
    font-size: 12px;
    flex-shrink: 0;
    text-align: center;
}

#footer p {
    margin: 0;
    line-height: 1.5;
}

/* ========== ç»å½é¡µé¢æ ·å¼ ========== */
body.login #container {
    background: #f5f5f5;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

body.login #content {
    display: block !important;
    background: transparent;
    padding: 0;
}

body.login #content-main {
    background: white;
    border: 1px solid #ddd;
    border-radius: 5px;
    padding: 40px;
    max-width: 400px;
    width: 100%;
    margin: 0 auto;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

body.login #content-main h1 {
    text-align: center;
    border-bottom: none;
    margin-bottom: 30px;
}

body.login .form-row {
    padding: 10px 0;
}

body.login label {
    display: block;
    margin-bottom: 5px;
    font-size: 13px;
    color: #555;
}

body.login input[type="text"],
body.login input[type="password"] {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 3px;
    font-size: 14px;
    box-sizing: border-box;
}

body.login .submit-row {
    padding: 20px 0 0 0;
    border-top: 1px solid #eee;
    margin-top: 20px;
    text-align: center;
}

body.login input[type="submit"] {
    width: 100%;
    padding: 12px;
    background: #3498db;
    color: white;
    border: none;
    border-radius: 3px;
    font-size: 14px;
    cursor: pointer;
}

body.login input[type="submit"]:hover {
    background: #2980b9;
}

body.login .errornote {
    color: #e74c3c;
    font-size: 13px;
    margin-bottom: 15px;
    text-align: center;
}

/* ========== Dashboard ç³»ç»ä»ç»é¡µé¢æ ·å¼ ========== */
.dashboard-container {
    max-width: 1200px;
    margin: 0 auto;
}

.welcome-section {
    text-align: center;
    padding: 40px 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 8px;
    margin-bottom: 30px;
}

.welcome-section h1 {
    font-size: 32px;
    margin-bottom: 10px;
    color: white !important;
    border-bottom: none !important;
}

.welcome-section .subtitle {
    font-size: 16px;
    opacity: 0.9;
    margin-bottom: 15px;
}

.welcome-section .description {
    font-size: 14px;
    opacity: 0.85;
    max-width: 600px;
    margin: 0 auto;
}

.modules-overview {
    margin-bottom: 30px;
}

.modules-overview h2 {
    font-size: 20px;
    color: #2c3e50;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #3498db;
}

.modules-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.module-card {
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 20px;
    transition: transform 0.2s, box-shadow 0.2s;
}

.module-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.module-icon {
    font-size: 36px;
    margin-bottom: 10px;
}

.module-card h3 {
    font-size: 16px;
    color: #2c3e50;
    margin-bottom: 8px;
}

.module-card > p {
    font-size: 13px;
    color: #666;
    margin-bottom: 12px;
}

.module-card ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.module-card li {
    margin-bottom: 5px;
}

.module-card a {
    color: #3498db;
    text-decoration: none;
    font-size: 13px;
}

.module-card a:hover {
    text-decoration: underline;
}

.quick-stats {
    margin-bottom: 30px;
}

.quick-stats h2 {
    font-size: 20px;
    color: #2c3e50;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #3498db;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
}

.stat-item {
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 20px;
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 32px;
    font-weight: bold;
    color: #3498db;
    margin-bottom: 5px;
}

.stat-label {
    font-size: 13px;
    color: #666;
}

.system-info {
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 20px;
}

.system-info h2 {
    font-size: 20px;
    color: #2c3e50;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #3498db;
}

.info-content p {
    margin-bottom: 8px;
    font-size: 13px;
    color: #555;
}

/* ç¡®ä¿åå®¹æ é¢ä¸ä¼ä¸å·¥å·æ éå  */
#content-main h1 {
    font-size: 20px;
    color: #2c3e50;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #3498db;
    margin-top: 0;
}

/* ========== ç»æåè¡¨è¡¨æ ¼æ ·å¼ ========== */
#result_list {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    border-radius: 8px;
    overflow: hidden;
    background-color: #fff !important;
}

#result_list th {
    padding: 12px 15px;
    border: 1px solid #e9ecef;
    text-align: left;
    background: #fff !important;
    font-weight: bold;
    color: #000 !important;
    text-transform: none;
    font-size: 12px;
    letter-spacing: 0.5px;
    border-bottom: 1px solid #ddd;
    border-top: 1px solid #ddd;
}

#result_list td {
    padding: 12px 15px;
    border: 1px solid #e9ecef;
    text-align: left;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 200px;
    text-transform: none;
    background-color: #fff !important;
    color: #000 !important;
}

#result_list tr {
    transition: all 0.3s ease;
    background-color: #fff !important;
    color: #000 !important;
}

#result_list tr:hover {
    background: #f5f5f5 !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
}

/* äº¤æ¿è¡é¢è² */
#result_list tr:nth-child(even) {
    background: #f8f9fa !important;
}

/* ç¡®ä¿ææè¡¨æ ¼ååæ ¼é½ä½¿ç¨ç½è²èæ¯ï¼æé«ä¼åçº§ï¼ */
body table#result_list tbody tr td {
    background-color: #fff !important;
    color: #000 !important;
}

/* ç¡®ä¿ç¨æ·ååèæ¯è²ä¸ºç½è²ï¼è¶é«ä¼åçº§ï¼ */
body.app-users.model-user table#result_list tbody tr td:first-child,
body.app-users.model-user table#result_list tbody tr td:nth-child(2),
body.app-users.model-user table#result_list tbody tr td[data-colname="username"],
body.app-users.model-user table#result_list tbody tr td.field-username,
body.app-users.model-user table#result_list tbody tr td[class*="username"] {
    background-color: #fff !important;
    color: #000 !important;
    background-image: none !important;
    background: #fff !important;
}

/* ç¡®ä¿ææè¡¨æ ¼ååæ ¼èæ¯è²ä¸ºç½è²ï¼æé«ä¼åçº§ï¼ */
* table#result_list tbody tr td {
    background-color: #fff !important;
    color: #000 !important;
    background-image: none !important;
    background: #fff !important;
}

/* ç¡®ä¿è§è²ç®¡çé¡µé¢ç¬¬ä¸åï¼è§è²æ è¯ï¼èæ¯è²ä¸ºç½è² */
body.app-users.model-role table#result_list tbody tr td:first-child,
body.app-users.model-role table#result_list tbody tr td.field-name,
body.app-users.model-role table#result_list tbody tr td[data-colname="name"] {
    background-color: #fff !important;
    color: #000 !important;
    background-image: none !important;
    background: #fff !important;
}

/* è§è²ç®¡çé¡µé¢ææè¡¨æ ¼ååæ ¼ç½è²èæ¯ */
body.app-users.model-role table#result_list tbody tr td {
    background-color: #fff !important;
    color: #000 !important;
    background-image: none !important;
    background: #fff !important;
}

/* è§è²ç®¡çé¡µé¢é¾æ¥é¢è² */
body.app-users.model-role table#result_list tbody tr td a {
    color: #3182ce !important;
}

/* å¹è®­åç±»é¡µé¢ææè¡¨æ ¼ååæ ¼ç½è²èæ¯ */
body.app-training_employment.model-trainingcategory table#result_list tbody tr td {
    background-color: #fff !important;
    color: #000 !important;
    background-image: none !important;
    background: #fff !important;
}

/* å¹è®­åç±»é¡µé¢é¾æ¥é¢è² */
body.app-training_employment.model-trainingcategory table#result_list tbody tr td a {
    color: #3182ce !important;
}

/* å¹è®­è¯¾ç¨é¡µé¢ææè¡¨æ ¼ååæ ¼ç½è²èæ¯ */
body.app-training_employment.model-course table#result_list tbody tr td {
    background-color: #fff !important;
    color: #000 !important;
    background-image: none !important;
    background: #fff !important;
}

/* å¹è®­è¯¾ç¨é¡µé¢é¾æ¥é¢è² */
body.app-training_employment.model-course table#result_list tbody tr td a {
    color: #3182ce !important;
}

/* è¯¾ç¨è¯¾ä»¶é¡µé¢ææè¡¨æ ¼ååæ ¼ç½è²èæ¯ */
body.app-training_employment.model-coursematerial table#result_list tbody tr td {
    background-color: #fff !important;
    color: #000 !important;
    background-image: none !important;
    background: #fff !important;
}

/* è¯¾ç¨è¯¾ä»¶é¡µé¢é¾æ¥é¢è² */
body.app-training_employment.model-coursematerial table#result_list tbody tr td a {
    color: #3182ce !important;
}



/* æä½æé®æ ·å¼ */
#result_list .button {
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
    margin-right: 5px;
}

#result_list .button:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

#result_list .button.default {
    background: #3498db;
    color: white;
}

#result_list .button.delete {
    background: #e74c3c;
    color: white;
}

/* ========== åé¡µæ ·å¼ ========== */
.paginator {
    margin-top: 30px;
    padding: 15px 0;
    text-align: center;
    background: #f8f9fa;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.paginator a,
.paginator span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 16px;
    margin: 0 4px;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    text-decoration: none;
    color: #495057;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    min-width: 40px;
    height: 40px;
}

.paginator a:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-color: #667eea;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(102, 126, 234, 0.3);
}

.paginator .this-page {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-color: #667eea;
    font-weight: 600;
}

.paginator .disabled {
    color: #adb5bd;
    cursor: not-allowed;
    background: #f8f9fa;
}

.paginator .disabled:hover {
    background: #f8f9fa;
    color: #adb5bd;
    border-color: #e9ecef;
    transform: none;
    box-shadow: none;
}

/* ========== è¡¨åæ ·å¼ä¼å ========== */
.form-row {
    padding: 15px;
    margin-bottom: 15px;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    background: #f8f9fa;
    transition: all 0.3s ease;
}

.form-row:hover {
    box-shadow: 0 4px 8px rgba(0,0,0,0.05);
    transform: translateY(-1px);
}

.form-row label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: #495057;
    font-size: 14px;
}

.form-row input[type="text"],
.form-row input[type="email"],
.form-row input[type="password"],
.form-row input[type="number"],
.form-row textarea,
.form-row select {
    width: 100%;
    max-width: 600px;
    padding: 12px 16px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 14px;
    box-sizing: border-box;
    transition: all 0.3s ease;
    background: white;
}

.form-row input:focus,
.form-row textarea:focus,
.form-row select:focus {
    border-color: #667eea;
    outline: none;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
    transform: translateY(-1px);
}

/* æç´¢æ¡æ ·å¼ */
#changelist-search {
    margin-bottom: 20px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

#changelist-search input {
    width: 100%;
    max-width: 400px;
    padding: 12px 16px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.3s ease;
}

#changelist-search input:focus {
    border-color: #667eea;
    outline: none;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

#changelist-search button {
    padding: 12px 24px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-left: 10px;
}

#changelist-search button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(102, 126, 234, 0.3);
}

/* è¿æ»¤å¨æ ·å¼ */
#changelist-filter {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 20px;
    margin-top: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

#changelist-filter h2 {
    font-size: 16px;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #667eea;
}

#changelist-filter ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

#changelist-filter li {
    margin-bottom: 8px;
}

#changelist-filter a {
    color: #495057;
    text-decoration: none;
    font-size: 13px;
    transition: all 0.2s ease;
    display: block;
    padding: 6px 12px;
    border-radius: 4px;
}

#changelist-filter a:hover {
    background: #667eea;
    color: white;
}

#changelist-filter a.selected {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-weight: 500;
}

/* ========== æäº¤æé®æ ·å¼ ========== */
.submit-row {
    padding: 15px 0;
    margin-top: 20px;
    border-top: 1px solid #eee;
    text-align: right;
}

.submit-row input[type="submit"],
.submit-row button {
    padding: 10px 20px;
    background: #3498db;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
    margin-left: 10px;
}

.submit-row input[type="submit"]:hover,
.submit-row button:hover {
    background: #2980b9;
}

.submit-row .deletelink-box {
    float: left;
}

.submit-row .deletelink {
    padding: 10px 20px;
    background: #e74c3c;
    color: white;
    border-radius: 4px;
    text-decoration: none;
}

.submit-row .deletelink:hover {
    background: #c0392b;
}

/* ========== é¢åå±å¯¼èªä¼å ========== */
.breadcrumbs {
    background: #f8f9fa;
    padding: 12px 20px;
    border-bottom: 1px solid #e9ecef;
    font-size: 13px;
    position: relative;
    z-index: 50;
}

.breadcrumbs a {
    color: #34495e;
    text-decoration: none;
}

.breadcrumbs a:hover {
    text-decoration: underline;
}

/* ========== å­æ®µéæ ·å¼ ========== */
fieldset {
    margin-bottom: 20px;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    padding: 20px;
    background: white;
}

fieldset h2 {
    font-size: 16px;
    color: #2c3e50;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #e9ecef;
}

/* ========== CKEditorç¼è¾å¨æ ·å¼ ========== */
.cke {
    z-index: 1000 !important;
}

.cke_editor {
    z-index: 1000 !important;
}

.cke_dialog {
    z-index: 10000 !important;
}

.cke_dialog_background_cover {
    z-index: 9999 !important;
}

/* ========== ä¸æèååéæ©å¨æ ·å¼ ========== */
.select2-dropdown,
.select2-container--open .select2-dropdown {
    z-index: 10000 !important;
}

/* ========== æ¥ææ¶é´éæ©å¨æ ·å¼ ========== */
.clockbox,
.calendarbox {
    z-index: 10000 !important;
    position: fixed !important;
}

/* ========== ååºå¼è°æ´ ========== */
@media (max-width: 768px) {
    #content {
        flex-direction: column !important;
    }
    
    #nav-sidebar {
        width: 100% !important;
        max-width: 100% !important;
        max-height: none !important;
        order: 1;
    }
    
    #content-main {
        order: 2;
        max-height: none !important;
    }
    
    .modules-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ========== è¡¨åå¸å±ä¼å - è§£å³å±æ¬¡å¼å½¢é®é¢ ========== */
/* å°ä¸è¬è¡¨ååä¸ºå·¦å³ä¸¤ä¸ªåºå */
.change-form .aligned {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.change-form .aligned .form-row {
    display: flex;
    flex-direction: column;
    width: calc(50% - 10px);
    min-width: 300px;
    padding: 15px !important;
    margin-bottom: 15px !important;
    background: #f8f9fa !important;
    border: 1px solid #e9ecef !important;
    border-radius: 8px !important;
    box-sizing: border-box;
}

/* è½®æ¬¡ä¸¤è¡ååºå */
.change-form .aligned .form-row:nth-child(odd) {
    clear: left;
}

/* æ ç­¾æ ·å¼ */
.change-form .aligned label {
    display: block !important;
    width: auto !important;
    padding: 0 !important;
    margin-bottom: 6px !important;
    font-weight: 600 !important;
    font-size: 14px !important;
    color: #495057 !important;
    text-align: left !important;
    line-height: 1.4 !important;
}

/* ç¼è¾åºåæ ·å¼ */
.change-form .aligned label + div {
    margin-left: 0 !important;
    width: 100% !important;
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* æ©å±è¡¨åæ ·å¼ - éä½éå£°æè¿°ä¸è¾å¥æ¡çéé¤ */
.change-form .aligned .form-row.field-content {
    width: 100% !important;
    padding: 15px !important;
}

.change-form .aligned .form-row.field-content label {
    display: block !important;
    margin-bottom: 6px !important;
    padding-bottom: 0 !important;
}

.change-form .aligned .form-row.field-content div {
    margin-left: 0 !important;
    width: 100% !important;
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* CKEditorç¼è¾å¨æ ·å¼ - æ§å¶ä¸è¾¹è· */
.change-form .aligned .form-row.field-content .django-ckeditor-widget,
.change-form .aligned .form-row.field-content textarea {
    width: 100% !important;
    margin-top: 0 !important;
    padding-top: 0 !important;
}

.change-form .aligned .form-row.field-content .cke {
    width: 100% !important;
    margin-top: 0 !important;
    border-top: none !important;
}

/* CKEditorç¼è¾å¨å¤´é¨æ ·å¼ */
.change-form .aligned .form-row.field-content .cke_top {
    border-top-left-radius: 6px !important;
    border-top-right-radius: 6px !important;
    margin-top: 0 !important;
}

/* CKEditorç¼è¾å¨ä¸»ä½æ ·å¼ */
.change-form .aligned .form-row.field-content .cke_contents {
    border-bottom-left-radius: 6px !important;
    border-bottom-right-radius: 6px !important;
}

/* è¾å¥æ¡æ ·å¼ */
.change-form .aligned input[type="text"],
.change-form .aligned input[type="email"],
.change-form .aligned input[type="number"],
.change-form .aligned input[type="date"],
.change-form .aligned input[type="datetime-local"],
.change-form .aligned select {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 200px !important;
    padding: 10px 14px !important;
    font-size: 14px !important;
    line-height: 1.5 !important;
    color: #495057 !important;
    background-color: #fff !important;
    background-clip: padding-box !important;
    border: 1px solid #ced4da !important;
    border-radius: 6px !important;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out !important;
    box-sizing: border-box !important;
}

/* éæ©æ¡æ ·å¼ */
.change-form .aligned select {
    min-height: 40px !important;
}

/* èæ æ ·å¼ */
.change-form .aligned textarea {
    width: 100% !important;
    max-width: 100% !important;
    min-height: 100px !important;
    padding: 10px 14px !important;
    font-size: 14px !important;
    line-height: 1.5 !important;
    color: #495057 !important;
    background-color: #fff !important;
    background-clip: padding-box !important;
    border: 1px solid #ced4da !important;
    border-radius: 6px !important;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out !important;
    box-sizing: border-box !important;
}

/* å¤§å­æ®µææ¬æ¡ */
.change-form .aligned .vLargeTextField {
    min-height: 200px !important;
}

/* è¾å¥æ¡èç¦ææ */
.change-form .aligned input:focus,
.change-form .aligned select:focus,
.change-form .aligned textarea:focus {
    border-color: #667eea !important;
    outline: none !important;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1) !important;
}

/* æ¶é´è¾å¥æ¡ */
.change-form .aligned .form-row.datetime {
    width: calc(50% - 10px) !important;
}

.change-form .aligned .form-row.datetime input {
    width: auto !important;
    min-width: 150px !important;
}

.change-form .aligned .form-row.datetime .datetime.date,
.change-form .aligned .form-row.datetime .datetime.time {
    display: inline-block;
    margin-right: 15px;
}

/* æä»¶ä¸ä¼ æ¡ */
.change-form .aligned input[type="file"] {
    padding: 5px !important;
    border: 1px dashed #ced4da !important;
    border-radius: 6px !important;
    background: #fff !important;
}

/* æä»¶ä¸ä¼ æ¡èç¦ */
.change-form .aligned input[type="file"]:focus {
    border-color: #667eea !important;
    outline: none !important;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1) !important;
}

/* ========== ä¿®å¤æé®é®æ¡é®é¢ ========== */
/* ç¡®ä¿.object-toolså·¥å·æ ä¸ä¼è¢«é®æ¡ */
.object-tools {
    position: relative;
    z-index: 100;
    margin-bottom: 15px;
}

/* ç¡®ä¿æé®ä¸ä¼è¢«æç´¢æ¡é®æ¡ */
#changelist-filter {
    margin-top: 20px !important;
}

/* 确保内容区域有足够的空间 */
.changelist-form-container {
    margin-left: 200px;
}

/* ========== 充值记录管理页面样式 ========== */

/* 统计区域 */
.stats-section {
    margin-bottom: 20px;
}

/* 统计卡片网格 */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 24px;
}

/* 统计卡片 */
.stat-card {
    background: white;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid #f0f0f0;
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

/* 卡片背景渐变 */
.stat-pending {
    background: linear-gradient(135deg, #fff7ed 0%, #ffedd5 100%);
    border-color: #fed7aa;
}

.stat-approved {
    background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
    border-color: #6ee7b7;
}

.stat-rejected {
    background: linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%);
    border-color: #fca5a5;
}

.stat-paid {
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    border-color: #93c5fd;
}

/* 图标区域 */
.stat-icon {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin-bottom: 16px;
}

.stat-pending .stat-icon {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
}

.stat-approved .stat-icon {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
}

.stat-rejected .stat-icon {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
}

.stat-paid .stat-icon {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
}

/* 统计内容 */
.stat-content {
    display: flex;
    flex-direction: column;
}

.stat-number {
    font-size: 42px;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 4px;
}

.stat-pending .stat-number {
    color: #d97706;
}

.stat-approved .stat-number {
    color: #059669;
}

.stat-rejected .stat-number {
    color: #dc2626;
}

.stat-paid .stat-number {
    color: #2563eb;
}

.stat-label {
    font-size: 14px;
    color: #6b7280;
    font-weight: 500;
}

/* 提醒徽章 */
.stat-badge {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 24px;
    height: 24px;
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 700;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.4);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(239, 68, 68, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(239, 68, 68, 0);
    }
}

/* 提醒卡片 */
.alert-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 24px;
    background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
    border: 1px solid #fcd34d;
}

.alert-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    color: white;
    flex-shrink: 0;
}

.alert-content {
    flex: 1;
}

.alert-content h4 {
    margin: 0 0 4px 0;
    font-size: 16px;
    font-weight: 600;
    color: #92400e;
}

.alert-content p {
    margin: 0;
    font-size: 14px;
    color: #78350f;
}

.alert-content strong {
    color: #d97706;
    font-weight: 700;
}

.alert-action {
    flex-shrink: 0;
}

/* 按钮样式 */
.alert-action .btn {
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.alert-action .btn-warning {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
    border: none;
}

.alert-action .btn-warning:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.4);
}

/* 响应式布局 */
@media (max-width: 992px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .alert-card {
        flex-direction: column;
        text-align: center;
    }
}

/* ========== Global button font color with background changed to white ========== */
button,
input[type="submit"],
input[type="button"],
.button,
.btn,
a.button,
a.btn,
.default,
input[type="submit"].default,
button.default,
.button.default,
.actions button,
.actions .button,
.action-select,
.submit-row input,
.submit-row button,
.form-actions button,
.form-actions input,
.paginator a,
.paginator button,
[style*="background"]:not(a):not(span):not(div):not(p):not(td):not(th),
[style*="background-color"]:not(a):not(span):not(div):not(p):not(td):not(th),
.btn-primary,
.btn-secondary,
.btn-success,
.btn-danger,
.btn-warning,
.btn-info,
.btn-light,
.btn-dark,
input[type="submit"]:not(.btn):not(.button),
button:not([class*="no-color"]),
.object-tools a,
.object-tools button,
.filters button,
.filters input[type="submit"],
.change-form input[type="submit"],
.change-form button,
.change-form .btn,
.changelist-form input[type="submit"],
.changelist-form button,
.deletion-confirmation input[type="submit"],
.deletion-confirmation button {
    color: white !important;
}

button:hover,
input[type="submit"]:hover,
input[type="button"]:hover,
.button:hover,
.btn:hover,
a.button:hover,
a.btn:hover,
.default:hover,
.submit-row input:hover,
.actions button:hover,
.actions .button:hover,
.paginator a:hover,
[style*="background"]:hover:not(a):not(span):not(div):not(p),
.btn-primary:hover,
.btn-secondary:hover,
.btn-success:hover,
.btn-danger:hover,
.btn-warning:hover,
.btn-info:hover,
.object-tools a:hover,
.object-tools button:hover {
    color: white !important;
}
