body {
    font-family: Arial, sans-serif;
    margin: 0;
}
header {
    position: fixed;
    top: 0;
    width: 100%;
    background-color: #fff;
    z-index: 1000;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}
nav {
    padding: 10px 0;
}
.nav-buttons {
    display: flex;
    gap: 5px;
    flex-wrap: nowrap;
    padding: 0 15px;
    justify-content: space-between;
}
.controls {
    display: flex;
    gap: 5px;
    flex-wrap: nowrap;
    padding: 0 15px 10px;
    justify-content: space-between;
}
.content {
    padding-top: 80px; /* Fallback padding */
}
h1 {
    font-size: 2rem;
}
h1.glossary-term {
    font-weight: bold;
    font-size: 16px;
}
p {
    margin: 0.5rem 0;
}
.translation {
    margin-bottom: 1rem;
}
.nav-buttons .btn.disabled {
    pointer-events: none;
    opacity: 0.5;
}
.content-text {
    transition: font-size 0.2s ease;
}
.chinese {
    font-weight: bold;
}
.chinese.normal {
    font-weight: normal;
}
.english.hidden {
    display: none;
}

/* Progress indicator styling */
.progress-indicator {
    font-size: 0.8em !important;
    color: #888;
    margin-bottom: 0.5rem;
    font-weight: normal;
    opacity: 0.7;
}

/* Allow font size changes for progress indicators */
.progress-indicator.content-text {
    font-size: inherit !important;
}

/* Highlighting styles */
.highlight-important {
    background-color: #fff3cd !important;
    border-bottom: 2px solid #ffc107 !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
    padding: 1px 2px !important;
    border-radius: 2px !important;
    box-shadow: 0 1px 2px rgba(255, 193, 7, 0.3) !important;
}

.highlight-question {
    background-color: #d1ecf1 !important;
    border-bottom: 2px solid #17a2b8 !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
    padding: 1px 2px !important;
    border-radius: 2px !important;
    box-shadow: 0 1px 2px rgba(23, 162, 184, 0.3) !important;
}

.highlight-action {
    background-color: #d4edda !important;
    border-bottom: 2px solid #28a745 !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
    padding: 1px 2px !important;
    border-radius: 2px !important;
    box-shadow: 0 1px 2px rgba(40, 167, 69, 0.3) !important;
}

.highlight-reference {
    background-color: #e2d9f3 !important;
    border-bottom: 2px solid #6f42c1 !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
    padding: 1px 2px !important;
    border-radius: 2px !important;
    box-shadow: 0 1px 2px rgba(111, 66, 193, 0.3) !important;
}

.highlight-personal {
    background-color: #ffeaa7 !important;
    border-bottom: 2px solid #fd7e14 !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
    padding: 1px 2px !important;
    border-radius: 2px !important;
    box-shadow: 0 1px 2px rgba(253, 126, 20, 0.3) !important;
}

.highlight-important:hover,
.highlight-question:hover,
.highlight-action:hover,
.highlight-reference:hover,
.highlight-personal:hover {
    opacity: 0.8 !important;
    transform: scale(1.02) !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2) !important;
}

.highlight-note {
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    padding: 8px;
    margin: 5px 0;
    font-style: italic;
    font-size: 0.9em;
    color: #6c757d;
}

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

.highlight-modal-content {
    background-color: #fefefe;
    margin: 15% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 500px;
    border-radius: 8px;
}

@media (max-width: 768px) {
    .highlight-modal-content {
        margin: 10% auto;
        width: 95%;
        padding: 15px;
    }
    
    .highlight-type-buttons {
        flex-direction: column;
        gap: 5px;
    }
    
    .highlight-type-btn {
        padding: 10px;
        font-size: 14px;
    }
}

.highlight-close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.highlight-close:hover {
    color: #000;
}

.highlight-type-buttons {
    display: flex;
    gap: 10px;
    margin: 10px 0;
    flex-wrap: wrap;
}

.highlight-type-btn {
    padding: 5px 10px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
}

.highlight-type-btn.important { background-color: #fff3cd; border: 1px solid #ffc107; }
.highlight-type-btn.question { background-color: #d1ecf1; border: 1px solid #17a2b8; }
.highlight-type-btn.action { background-color: #d4edda; border: 1px solid #28a745; }
.highlight-type-btn.reference { background-color: #e2d9f3; border: 1px solid #6f42c1; }
.highlight-type-btn.personal { background-color: #ffeaa7; border: 1px solid #fd7e14; }

.highlight-type-btn.selected {
    box-shadow: 0 0 0 2px #000;
}

.highlight-index-item {
    border: 1px solid #dee2e6;
    border-radius: 4px;
    padding: 10px;
    margin: 5px 0;
    transition: all 0.2s ease;
}

.highlight-index-item:hover {
    background-color: #f8f9fa;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.highlight-index-item .flex-grow-1 {
    cursor: pointer;
}

.highlight-index-item .btn-danger {
    opacity: 0.7;
    transition: opacity 0.2s ease;
}

.highlight-index-item:hover .btn-danger {
    opacity: 1;
}

.highlight-index-text {
    font-weight: bold;
    margin-bottom: 5px;
}

.highlight-index-note {
    font-style: italic;
    color: #6c757d;
    font-size: 0.9em;
}

.highlight-index-meta {
    font-size: 0.8em;
    color: #6c757d;
    margin-top: 5px;
}

.highlight-color-indicator {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin-right: 8px;
}

.highlight-color-indicator.important { background-color: #ffc107; }
.highlight-color-indicator.question { background-color: #17a2b8; }
.highlight-color-indicator.action { background-color: #28a745; }
.highlight-color-indicator.reference { background-color: #6f42c1; }
.highlight-color-indicator.personal { background-color: #fd7e14; }

.highlight-number {
    display: inline-block;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background-color: #007bff;
    color: white;
    text-align: center;
    line-height: 24px;
    font-size: 12px;
    font-weight: bold;
    margin-right: 8px;
    flex-shrink: 0;
}

.highlight-filters {
    margin-bottom: 20px;
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 4px;
}

.highlight-search {
    width: 100%;
    padding: 8px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    margin-bottom: 10px;
}

.highlight-filter-buttons {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
}

.highlight-filter-btn {
    padding: 5px 10px;
    border: 1px solid #ced4da;
    background-color: white;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
}

.highlight-filter-btn.active {
    background-color: #007bff;
    color: white;
    border-color: #007bff;
}

.highlight-export-import {
    margin: 20px 0;
    padding: 15px;
    background-color: #e9ecef;
    border-radius: 4px;
}

.highlight-export-import button {
    margin-right: 10px;
}

@media (max-width: 576px) {
    .nav-buttons .btn, .controls .btn {
        padding: 4px 8px;
        font-size: 0.75rem;
    }
    .nav-buttons, .controls {
        gap: 3px;
    }
    .nav-buttons, .controls {
        justify-content: space-between;
    }
}

/* Color Theme Modal */
.color-theme-modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
}

.color-theme-modal-content {
    background-color: #fefefe;
    margin: 10% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 450px;
    max-height: 80vh;
    border-radius: 8px;
}

.color-theme-close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.color-theme-close:hover {
    color: #000;
}

.color-theme-options-scroll {
    max-height: 400px;
    overflow-y: auto;
    margin: 20px 0;
    padding-right: 10px;
}

.color-theme-options-scroll::-webkit-scrollbar {
    width: 8px;
}

.color-theme-options-scroll::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.color-theme-options-scroll::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

.color-theme-options-scroll::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

.color-theme-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.color-theme-option {
    display: flex;
    align-items: center;
    padding: 15px;
    border: 2px solid #ddd;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.color-theme-option:hover {
    border-color: #007bff;
    transform: scale(1.02);
}

.color-theme-option.selected {
    border-color: #007bff;
    box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.3);
}

.color-theme-preview {
    width: 40px;
    height: 40px;
    border-radius: 6px;
    margin-right: 15px;
    border: 1px solid #ccc;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
}

.color-theme-info {
    flex-grow: 1;
}

.color-theme-name {
    font-weight: bold;
    margin-bottom: 5px;
}

.color-theme-description {
    font-size: 0.9em;
    color: #666;
}

/* Color Theme Styles */
.theme-default {
    background-color: #ffffff !important;
    color: #000000 !important;
}

.theme-dark1 {
    background-color: #1C2526 !important;
    color: #E8ECEF !important;
}

.theme-dark2 {
    background-color: #1C2526 !important;
    color: #D3D3D3 !important;
}

.theme-warm {
    background-color: #F5E6CC !important;
    color: #3C2F2F !important;
}

.theme-cream {
    background-color: #FFFDD0 !important;
    color: #333333 !important;
}

.theme-light-gray {
    background-color: #E5E7EB !important;
    color: #1F2937 !important;
}

.theme-sepia {
    background-color: #F4F1E8 !important;
    color: #2C1810 !important;
}

.theme-blue-light {
    background-color: #E3F2FD !important;
    color: #0D47A1 !important;
}

.theme-green-light {
    background-color: #E8F5E8 !important;
    color: #1B5E20 !important;
}

.theme-purple-light {
    background-color: #F3E5F5 !important;
    color: #4A148C !important;
}

.theme-pink-light {
    background-color: #FCE4EC !important;
    color: #880E4F !important;
}

.theme-orange-light {
    background-color: #FFF3E0 !important;
    color: #E65100 !important;
}

.theme-teal-light {
    background-color: #E0F2F1 !important;
    color: #004D40 !important;
}

.theme-dark3 {
    background-color: #0D1117 !important;
    color: #F0F6FC !important;
}

.theme-dark4 {
    background-color: #1A1A1A !important;
    color: #E0E0E0 !important;
}

.theme-dark5 {
    background-color: #2D3748 !important;
    color: #F7FAFC !important;
}

.theme-paper {
    background-color: #FAFAF8 !important;
    color: #2C2C2C !important;
}

.theme-beige {
    background-color: #F5F5DC !important;
    color: #3E3E3E !important;
}

.theme-mint {
    background-color: #F0FFF0 !important;
    color: #2F4F2F !important;
}

.theme-lavender {
    background-color: #E6E6FA !important;
    color: #4B0082 !important;
}

.theme-peach {
    background-color: #FFE5B4 !important;
    color: #8B4513 !important;
}

.theme-sky {
    background-color: #E0F6FF !important;
    color: #0066CC !important;
}

/* Theme-specific highlight colors */
/* Default theme - original colors */
.theme-default .highlight-important {
    background-color: #fff3cd !important;
    border-bottom: 2px solid #ffc107 !important;
    color: #000000 !important;
}

.theme-default .highlight-question {
    background-color: #d1ecf1 !important;
    border-bottom: 2px solid #17a2b8 !important;
    color: #000000 !important;
}

.theme-default .highlight-action {
    background-color: #d4edda !important;
    border-bottom: 2px solid #28a745 !important;
    color: #000000 !important;
}

.theme-default .highlight-reference {
    background-color: #e2d9f3 !important;
    border-bottom: 2px solid #6f42c1 !important;
    color: #000000 !important;
}

.theme-default .highlight-personal {
    background-color: #ffeaa7 !important;
    border-bottom: 2px solid #fd7e14 !important;
    color: #000000 !important;
}

/* Dark themes - lighter, more visible colors */
.theme-dark1 .highlight-important,
.theme-dark2 .highlight-important {
    background-color: #ffd54f !important;
    border-bottom: 2px solid #ffb300 !important;
    color: #1C2526 !important;
}

.theme-dark1 .highlight-question,
.theme-dark2 .highlight-question {
    background-color: #4fc3f7 !important;
    border-bottom: 2px solid #29b6f6 !important;
    color: #1C2526 !important;
}

.theme-dark1 .highlight-action,
.theme-dark2 .highlight-action {
    background-color: #66bb6a !important;
    border-bottom: 2px solid #4caf50 !important;
    color: #1C2526 !important;
}

.theme-dark1 .highlight-reference,
.theme-dark2 .highlight-reference {
    background-color: #ab47bc !important;
    border-bottom: 2px solid #9c27b0 !important;
    color: #1C2526 !important;
}

.theme-dark1 .highlight-personal,
.theme-dark2 .highlight-personal {
    background-color: #ff9800 !important;
    border-bottom: 2px solid #f57c00 !important;
    color: #1C2526 !important;
}

/* Warm theme - darker, more contrasting colors */
.theme-warm .highlight-important {
    background-color: #ff8f00 !important;
    border-bottom: 2px solid #e65100 !important;
    color: #3C2F2F !important;
}

.theme-warm .highlight-question {
    background-color: #0277bd !important;
    border-bottom: 2px solid #01579b !important;
    color: #F5E6CC !important;
}

.theme-warm .highlight-action {
    background-color: #2e7d32 !important;
    border-bottom: 2px solid #1b5e20 !important;
    color: #F5E6CC !important;
}

.theme-warm .highlight-reference {
    background-color: #6a1b9a !important;
    border-bottom: 2px solid #4a148c !important;
    color: #F5E6CC !important;
}

.theme-warm .highlight-personal {
    background-color: #ef6c00 !important;
    border-bottom: 2px solid #e65100 !important;
    color: #3C2F2F !important;
}

/* Cream theme - medium contrast colors */
.theme-cream .highlight-important {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #333333 !important;
}

.theme-cream .highlight-question {
    background-color: #4dd0e1 !important;
    border-bottom: 2px solid #00bcd4 !important;
    color: #333333 !important;
}

.theme-cream .highlight-action {
    background-color: #81c784 !important;
    border-bottom: 2px solid #66bb6a !important;
    color: #333333 !important;
}

.theme-cream .highlight-reference {
    background-color: #ba68c8 !important;
    border-bottom: 2px solid #ab47bc !important;
    color: #333333 !important;
}

.theme-cream .highlight-personal {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #333333 !important;
}

/* Light gray theme - darker, more visible colors */
.theme-light-gray .highlight-important {
    background-color: #ffcc02 !important;
    border-bottom: 2px solid #f57f17 !important;
    color: #1F2937 !important;
}

.theme-light-gray .highlight-question {
    background-color: #00bcd4 !important;
    border-bottom: 2px solid #0097a7 !important;
    color: #1F2937 !important;
}

.theme-light-gray .highlight-action {
    background-color: #4caf50 !important;
    border-bottom: 2px solid #388e3c !important;
    color: #1F2937 !important;
}

.theme-light-gray .highlight-reference {
    background-color: #9c27b0 !important;
    border-bottom: 2px solid #7b1fa2 !important;
    color: #1F2937 !important;
}

.theme-light-gray .highlight-personal {
    background-color: #ff9800 !important;
    border-bottom: 2px solid #f57c00 !important;
    color: #1F2937 !important;
}

/* Sepia theme highlight colors */
.theme-sepia .highlight-important {
    background-color: #ff8f00 !important;
    border-bottom: 2px solid #e65100 !important;
    color: #2C1810 !important;
}

.theme-sepia .highlight-question {
    background-color: #0277bd !important;
    border-bottom: 2px solid #01579b !important;
    color: #F4F1E8 !important;
}

.theme-sepia .highlight-action {
    background-color: #2e7d32 !important;
    border-bottom: 2px solid #1b5e20 !important;
    color: #F4F1E8 !important;
}

.theme-sepia .highlight-reference {
    background-color: #6a1b9a !important;
    border-bottom: 2px solid #4a148c !important;
    color: #F4F1E8 !important;
}

.theme-sepia .highlight-personal {
    background-color: #ef6c00 !important;
    border-bottom: 2px solid #e65100 !important;
    color: #2C1810 !important;
}

/* Blue light theme highlight colors */
.theme-blue-light .highlight-important {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #0D47A1 !important;
}

.theme-blue-light .highlight-question {
    background-color: #4dd0e1 !important;
    border-bottom: 2px solid #00bcd4 !important;
    color: #0D47A1 !important;
}

.theme-blue-light .highlight-action {
    background-color: #81c784 !important;
    border-bottom: 2px solid #66bb6a !important;
    color: #0D47A1 !important;
}

.theme-blue-light .highlight-reference {
    background-color: #ba68c8 !important;
    border-bottom: 2px solid #ab47bc !important;
    color: #0D47A1 !important;
}

.theme-blue-light .highlight-personal {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #0D47A1 !important;
}

/* Green light theme highlight colors */
.theme-green-light .highlight-important {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #1B5E20 !important;
}

.theme-green-light .highlight-question {
    background-color: #4dd0e1 !important;
    border-bottom: 2px solid #00bcd4 !important;
    color: #1B5E20 !important;
}

.theme-green-light .highlight-action {
    background-color: #81c784 !important;
    border-bottom: 2px solid #66bb6a !important;
    color: #1B5E20 !important;
}

.theme-green-light .highlight-reference {
    background-color: #ba68c8 !important;
    border-bottom: 2px solid #ab47bc !important;
    color: #1B5E20 !important;
}

.theme-green-light .highlight-personal {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #1B5E20 !important;
}

/* Purple light theme highlight colors */
.theme-purple-light .highlight-important {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #4A148C !important;
}

.theme-purple-light .highlight-question {
    background-color: #4dd0e1 !important;
    border-bottom: 2px solid #00bcd4 !important;
    color: #4A148C !important;
}

.theme-purple-light .highlight-action {
    background-color: #81c784 !important;
    border-bottom: 2px solid #66bb6a !important;
    color: #4A148C !important;
}

.theme-purple-light .highlight-reference {
    background-color: #ba68c8 !important;
    border-bottom: 2px solid #ab47bc !important;
    color: #4A148C !important;
}

.theme-purple-light .highlight-personal {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #4A148C !important;
}

/* Pink light theme highlight colors */
.theme-pink-light .highlight-important {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #880E4F !important;
}

.theme-pink-light .highlight-question {
    background-color: #4dd0e1 !important;
    border-bottom: 2px solid #00bcd4 !important;
    color: #880E4F !important;
}

.theme-pink-light .highlight-action {
    background-color: #81c784 !important;
    border-bottom: 2px solid #66bb6a !important;
    color: #880E4F !important;
}

.theme-pink-light .highlight-reference {
    background-color: #ba68c8 !important;
    border-bottom: 2px solid #ab47bc !important;
    color: #880E4F !important;
}

.theme-pink-light .highlight-personal {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #880E4F !important;
}

/* Orange light theme highlight colors */
.theme-orange-light .highlight-important {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #E65100 !important;
}

.theme-orange-light .highlight-question {
    background-color: #4dd0e1 !important;
    border-bottom: 2px solid #00bcd4 !important;
    color: #E65100 !important;
}

.theme-orange-light .highlight-action {
    background-color: #81c784 !important;
    border-bottom: 2px solid #66bb6a !important;
    color: #E65100 !important;
}

.theme-orange-light .highlight-reference {
    background-color: #ba68c8 !important;
    border-bottom: 2px solid #ab47bc !important;
    color: #E65100 !important;
}

.theme-orange-light .highlight-personal {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #E65100 !important;
}

/* Teal light theme highlight colors */
.theme-teal-light .highlight-important {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #004D40 !important;
}

.theme-teal-light .highlight-question {
    background-color: #4dd0e1 !important;
    border-bottom: 2px solid #00bcd4 !important;
    color: #004D40 !important;
}

.theme-teal-light .highlight-action {
    background-color: #81c784 !important;
    border-bottom: 2px solid #66bb6a !important;
    color: #004D40 !important;
}

.theme-teal-light .highlight-reference {
    background-color: #ba68c8 !important;
    border-bottom: 2px solid #ab47bc !important;
    color: #004D40 !important;
}

.theme-teal-light .highlight-personal {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #004D40 !important;
}

/* Dark themes 3-5 highlight colors - lighter, more visible colors */
.theme-dark3 .highlight-important,
.theme-dark4 .highlight-important,
.theme-dark5 .highlight-important {
    background-color: #ffd54f !important;
    border-bottom: 2px solid #ffb300 !important;
    color: #000000 !important;
}

.theme-dark3 .highlight-question,
.theme-dark4 .highlight-question,
.theme-dark5 .highlight-question {
    background-color: #4fc3f7 !important;
    border-bottom: 2px solid #29b6f6 !important;
    color: #000000 !important;
}

.theme-dark3 .highlight-action,
.theme-dark4 .highlight-action,
.theme-dark5 .highlight-action {
    background-color: #66bb6a !important;
    border-bottom: 2px solid #4caf50 !important;
    color: #000000 !important;
}

.theme-dark3 .highlight-reference,
.theme-dark4 .highlight-reference,
.theme-dark5 .highlight-reference {
    background-color: #ab47bc !important;
    border-bottom: 2px solid #9c27b0 !important;
    color: #000000 !important;
}

.theme-dark3 .highlight-personal,
.theme-dark4 .highlight-personal,
.theme-dark5 .highlight-personal {
    background-color: #ff9800 !important;
    border-bottom: 2px solid #f57c00 !important;
    color: #000000 !important;
}

/* Paper theme highlight colors */
.theme-paper .highlight-important {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #2C2C2C !important;
}

.theme-paper .highlight-question {
    background-color: #4dd0e1 !important;
    border-bottom: 2px solid #00bcd4 !important;
    color: #2C2C2C !important;
}

.theme-paper .highlight-action {
    background-color: #81c784 !important;
    border-bottom: 2px solid #66bb6a !important;
    color: #2C2C2C !important;
}

.theme-paper .highlight-reference {
    background-color: #ba68c8 !important;
    border-bottom: 2px solid #ab47bc !important;
    color: #2C2C2C !important;
}

.theme-paper .highlight-personal {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #2C2C2C !important;
}

/* Beige theme highlight colors */
.theme-beige .highlight-important {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #3E3E3E !important;
}

.theme-beige .highlight-question {
    background-color: #4dd0e1 !important;
    border-bottom: 2px solid #00bcd4 !important;
    color: #3E3E3E !important;
}

.theme-beige .highlight-action {
    background-color: #81c784 !important;
    border-bottom: 2px solid #66bb6a !important;
    color: #3E3E3E !important;
}

.theme-beige .highlight-reference {
    background-color: #ba68c8 !important;
    border-bottom: 2px solid #ab47bc !important;
    color: #3E3E3E !important;
}

.theme-beige .highlight-personal {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #3E3E3E !important;
}

/* Mint theme highlight colors */
.theme-mint .highlight-important {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #2F4F2F !important;
}

.theme-mint .highlight-question {
    background-color: #4dd0e1 !important;
    border-bottom: 2px solid #00bcd4 !important;
    color: #2F4F2F !important;
}

.theme-mint .highlight-action {
    background-color: #81c784 !important;
    border-bottom: 2px solid #66bb6a !important;
    color: #2F4F2F !important;
}

.theme-mint .highlight-reference {
    background-color: #ba68c8 !important;
    border-bottom: 2px solid #ab47bc !important;
    color: #2F4F2F !important;
}

.theme-mint .highlight-personal {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #2F4F2F !important;
}

/* Lavender theme highlight colors */
.theme-lavender .highlight-important {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #4B0082 !important;
}

.theme-lavender .highlight-question {
    background-color: #4dd0e1 !important;
    border-bottom: 2px solid #00bcd4 !important;
    color: #4B0082 !important;
}

.theme-lavender .highlight-action {
    background-color: #81c784 !important;
    border-bottom: 2px solid #66bb6a !important;
    color: #4B0082 !important;
}

.theme-lavender .highlight-reference {
    background-color: #ba68c8 !important;
    border-bottom: 2px solid #ab47bc !important;
    color: #4B0082 !important;
}

.theme-lavender .highlight-personal {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #4B0082 !important;
}

/* Peach theme highlight colors */
.theme-peach .highlight-important {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #8B4513 !important;
}

.theme-peach .highlight-question {
    background-color: #4dd0e1 !important;
    border-bottom: 2px solid #00bcd4 !important;
    color: #8B4513 !important;
}

.theme-peach .highlight-action {
    background-color: #81c784 !important;
    border-bottom: 2px solid #66bb6a !important;
    color: #8B4513 !important;
}

.theme-peach .highlight-reference {
    background-color: #ba68c8 !important;
    border-bottom: 2px solid #ab47bc !important;
    color: #8B4513 !important;
}

.theme-peach .highlight-personal {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #8B4513 !important;
}

/* Sky theme highlight colors */
.theme-sky .highlight-important {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #0066CC !important;
}

.theme-sky .highlight-question {
    background-color: #4dd0e1 !important;
    border-bottom: 2px solid #00bcd4 !important;
    color: #0066CC !important;
}

.theme-sky .highlight-action {
    background-color: #81c784 !important;
    border-bottom: 2px solid #66bb6a !important;
    color: #0066CC !important;
}

.theme-sky .highlight-reference {
    background-color: #ba68c8 !important;
    border-bottom: 2px solid #ab47bc !important;
    color: #0066CC !important;
}

.theme-sky .highlight-personal {
    background-color: #ffb74d !important;
    border-bottom: 2px solid #ff9800 !important;
    color: #0066CC !important;
}

/* Apply theme to body and content */
body.theme-default {
    background-color: #ffffff;
    color: #000000;
}

body.theme-dark1 {
    background-color: #1C2526;
    color: #E8ECEF;
}

body.theme-dark2 {
    background-color: #1C2526;
    color: #D3D3D3;
}

body.theme-warm {
    background-color: #F5E6CC;
    color: #3C2F2F;
}

body.theme-cream {
    background-color: #FFFDD0;
    color: #333333;
}

body.theme-light-gray {
    background-color: #E5E7EB;
    color: #1F2937;
}

body.theme-sepia {
    background-color: #F4F1E8;
    color: #2C1810;
}

body.theme-blue-light {
    background-color: #E3F2FD;
    color: #0D47A1;
}

body.theme-green-light {
    background-color: #E8F5E8;
    color: #1B5E20;
}

body.theme-purple-light {
    background-color: #F3E5F5;
    color: #4A148C;
}

body.theme-pink-light {
    background-color: #FCE4EC;
    color: #880E4F;
}

body.theme-orange-light {
    background-color: #FFF3E0;
    color: #E65100;
}

body.theme-teal-light {
    background-color: #E0F2F1;
    color: #004D40;
}

body.theme-dark3 {
    background-color: #0D1117;
    color: #F0F6FC;
}

body.theme-dark4 {
    background-color: #1A1A1A;
    color: #E0E0E0;
}

body.theme-dark5 {
    background-color: #2D3748;
    color: #F7FAFC;
}

body.theme-paper {
    background-color: #FAFAF8;
    color: #2C2C2C;
}

body.theme-beige {
    background-color: #F5F5DC;
    color: #3E3E3E;
}

body.theme-mint {
    background-color: #F0FFF0;
    color: #2F4F2F;
}

body.theme-lavender {
    background-color: #E6E6FA;
    color: #4B0082;
}

body.theme-peach {
    background-color: #FFE5B4;
    color: #8B4513;
}

body.theme-sky {
    background-color: #E0F6FF;
    color: #0066CC;
}

/* Theme-specific header adjustments */
body.theme-dark1 header,
body.theme-dark2 header {
    background-color: #2a3435 !important;
    border-bottom: 1px solid #444;
}

body.theme-warm header {
    background-color: #f8f0e0 !important;
    border-bottom: 1px solid #d4c4a4;
}

body.theme-cream header {
    background-color: #fffef0 !important;
    border-bottom: 1px solid #e6e6b8;
}

body.theme-light-gray header {
    background-color: #f3f4f6 !important;
    border-bottom: 1px solid #d1d5db;
}

body.theme-sepia header {
    background-color: #f8f4f0 !important;
    border-bottom: 1px solid #d4c4a4;
}

body.theme-blue-light header {
    background-color: #e8f4fd !important;
    border-bottom: 1px solid #b3d9ff;
}

body.theme-green-light header {
    background-color: #e8f5e8 !important;
    border-bottom: 1px solid #a5d6a7;
}

body.theme-purple-light header {
    background-color: #f3e5f5 !important;
    border-bottom: 1px solid #ce93d8;
}

body.theme-pink-light header {
    background-color: #fce4ec !important;
    border-bottom: 1px solid #f8bbd9;
}

body.theme-orange-light header {
    background-color: #fff3e0 !important;
    border-bottom: 1px solid #ffcc80;
}

body.theme-teal-light header {
    background-color: #e0f2f1 !important;
    border-bottom: 1px solid #80cbc4;
}

body.theme-dark3 header,
body.theme-dark4 header,
body.theme-dark5 header {
    background-color: #2a2a2a !important;
    border-bottom: 1px solid #444;
}

body.theme-paper header {
    background-color: #fafaf8 !important;
    border-bottom: 1px solid #e0e0e0;
}

body.theme-beige header {
    background-color: #f5f5dc !important;
    border-bottom: 1px solid #d4d4a4;
}

body.theme-mint header {
    background-color: #f0fff0 !important;
    border-bottom: 1px solid #a5d6a7;
}

body.theme-lavender header {
    background-color: #e6e6fa !important;
    border-bottom: 1px solid #b39ddb;
}

body.theme-peach header {
    background-color: #ffe5b4 !important;
    border-bottom: 1px solid #ffcc80;
}

body.theme-sky header {
    background-color: #e0f6ff !important;
    border-bottom: 1px solid #81d4fa;
}

@media (max-width: 768px) {
    .color-theme-modal-content {
        margin: 5% auto;
        width: 95%;
        padding: 15px;
        max-height: 90vh;
    }
    
    .color-theme-option {
        padding: 12px;
    }
    
    .color-theme-preview {
        width: 35px;
        height: 35px;
        font-size: 11px;
    }
    
    .color-theme-options-scroll {
        max-height: 60vh;
    }
}