/* ==========================================
   开始界面样式
   ========================================== */

/* 开始界面主容器 */
.start-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000033;
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: auto;
}

.start-content {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    backdrop-filter: blur(10px);
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.1);
    position: relative;
    z-index: 2001;
    pointer-events: auto;
}

/* Logo 样式 */
.logo-container {
    margin-bottom: 0;
    text-align: center;
    order: 1;
}

.logo {
    max-width: 300px;
    height: auto;
    filter: drop-shadow(0 0 10px rgba(255, 215, 0, 0.5));
}

/* 设置区域 */
.settings {
    margin-bottom: 30px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    position: relative;
    z-index: 2002;
    pointer-events: auto;
    order: 3;
}

.toggle-container {
    display: flex;
    justify-content: center;
    gap: 20px;
    width: 100%;
    padding: 10px 0;
    position: relative;
    z-index: 2003;
    pointer-events: auto;
}

.setting-item {
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
}

.setting-item select {
    padding: 8px 15px;
    border-radius: 15px;
    border: none;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    font-size: 16px;
    cursor: pointer;
    margin-left: 10px;
}

.setting-item select:focus {
    outline: none;
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.3);
}

.setting-item label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.setting-item input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

/* 开始按钮 */
.start-button {
    background: #e0af00;
    color: #e9e9e9;
    border: none;
    padding: 15px 40px;
    font-size: 24px;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.start-button:hover {
    transform: scale(1.05);
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.5);
}

/* 切换按钮通用样式 */
.toggle-btn {
    width: 180px;
    height: 45px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 16px;
    font-weight: bold;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
    pointer-events: auto;
    box-sizing: border-box;
    transform-origin: center;
    border: 1px solid transparent;
}

.toggle-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.2);
}

/* 各个按钮的特定样式 */
.toggle-btn.pinyin {
    background: linear-gradient(135deg, #2196F3, #1976D2);
}

.toggle-btn.sound {
    background: linear-gradient(135deg, #9C27B0, #7B1FA2);
}

.toggle-btn.stars {
    background: linear-gradient(135deg, #1A237E, #3949AB);
}

/* 按钮激活状态的高级效果 */
.toggle-btn.active {
    background: linear-gradient(135deg, #26c000, #a5ff9c);
    box-shadow:
        inset 0 0 8px rgba(255, 255, 255, 0.314);
    transform: scale(1.05);
    color: #fff;
    text-shadow: 0 0 5px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.8);
    position: relative;
    overflow: hidden;
}

/* 为每种类型的按钮提供不同的激活颜色 */
.toggle-btn.pinyin.active {
    background: linear-gradient(135deg, #2196F3, #64b5f6);
}

.toggle-btn.sound.active {
    background: linear-gradient(135deg, #9C27B0, #ce93d8);
}

.toggle-btn.stars.active {
    background: linear-gradient(135deg, #1A237E, #5c6bc0);
}

/* 右上角按钮样式 */
.corner-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 150px;
    height: 40px;
    font-size: 14px;
    z-index: 2002;
    box-sizing: border-box;
    transform-origin: center;
    border: 1px solid transparent;
}

.corner-btn .tooltip {
    visibility: hidden;
    position: absolute;
    bottom: -40px;
    left: 50%;
    transform: translateX(-50%);
    background-color: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 12px;
    white-space: nowrap;
    opacity: 0;
    transition: opacity 0.3s;
}

.corner-btn:hover .tooltip {
    visibility: visible;
    opacity: 1;
}

.corner-btn .tooltip::before {
    content: '';
    position: absolute;
    top: -5px;
    left: 50%;
    transform: translateX(-50%);
    border-width: 0 5px 5px 5px;
    border-style: solid;
    border-color: transparent transparent rgba(0, 0, 0, 0.8) transparent;
}

/* 确保激活状态按钮固定位置 */
.corner-btn.active {
    position: absolute !important;
    top: 20px !important;
    right: 20px !important;
    margin: 0 !important;
}

/* 教程按钮样式 */
.tutorial-button {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6a11cb, #2575fc);
    color: white;
    font-size: 24px;
    font-weight: bold;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
    position: absolute;
    left: -20px;
    top: -15px;
}

.tutorial-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.4);
}

/* 时间模式按钮样式 */
.toggle-btn.time {
    background-color: #14a41e;
}

.toggle-btn.time.active {
    background-color: #33cc33;
    color: white;
    box-shadow: 0 0 15px rgba(51, 204, 51, 0.6);
}

/* Start Button Wrapper */
.start-btn-wrapper {
    position: relative;
    width: 150px;
    /* Match start button width */
    height: 60px;
    /* Match start button height */
    margin: 0 auto;
    transition: width 0.3s ease;
    display: flex;
    justify-content: center;
    align-items: center;
}

.start-btn-wrapper.expanded {
    width: 320px;
    /* 150px * 2 + 20px gap */
}

/* Learning Mode Button (Hidden by default on Desktop) */
.learning-mode-btn {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, #4CAF50, #8BC34A);
    border: none;
    border-radius: 25px;
    color: white;
    font-size: 20px;
    font-weight: bold;
    cursor: pointer;
    opacity: 0;
    transform: translateX(0);
    transition: all 0.3s ease;
    z-index: 1;
    pointer-events: none;
    /* Disable clicks when hidden */
    box-shadow: 0 4px 15px rgba(76, 175, 80, 0.3);
    white-space: nowrap;
    /* Prevent text wrapping during animation */
    overflow: hidden;
    /* Ensure text doesn't spill out */
}

.learning-mode-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(76, 175, 80, 0.5);
}

/* Start Button Adjustments */
.start-button {
    position: absolute;
    top: 0;
    right: 0;
    width: 100%;
    height: 100%;
    transition: all 0.3s ease;
    z-index: 2;
}

/* Expanded State */
.start-btn-wrapper.expanded .learning-mode-btn {
    opacity: 1;
    width: 150px;
    pointer-events: auto;
    transform: translateX(0);
}

.start-btn-wrapper.expanded .start-button {
    width: 150px;
    /* Remove translateX, rely on right: 0 and wrapper expansion */
    transform: none;
    background: #e0af00;
    /* Keep original color */
}

/* ==========================================
   Desktop Sidebar Menu (≥769px)
   ========================================== */
@media (min-width: 769px) {
    /* Override start-screen to use row layout */
    .start-screen.has-desktop-sidebar {
        display: flex;
        flex-direction: row;
        justify-content: flex-start;
        align-items: stretch;
    }

    .start-screen.has-desktop-sidebar .start-content {
        display: none;
    }

    /* Sidebar */
    .desktop-sidebar {
        width: 240px;
        min-width: 240px;
        background: #00001e;
        display: flex;
        flex-direction: column;
        padding: 24px 0;
        border-right: 1px solid rgba(255, 255, 255, 0.08);
        z-index: 1;
    }

    /* Nav Items */
    .desktop-nav-items {
        flex: 1;
        display: flex;
        flex-direction: column;
        gap: 4px;
        padding: 16px 12px 0;
    }

    .desktop-nav-item {
        display: flex;
        align-items: center;
        gap: 14px;
        padding: 14px 16px;
        border-radius: 12px;
        cursor: pointer;
        transition: all 0.2s ease;
        color: rgba(238, 238, 238, 0.6);
        font-size: 15px;
        font-weight: 500;
        border: none;
        background: transparent;
        width: 100%;
        text-align: left;
    }

    .desktop-nav-item:hover {
        background: rgba(255, 255, 255, 0.06);
        color: #eeffee;
    }

    .desktop-nav-item.active {
        background: rgba(51, 204, 51, 0.15);
        color: #eeffee;
    }

    .desktop-nav-item .nav-icon {
        width: 22px;
        height: 22px;
        display: flex;
        align-items: center;
        justify-content: center;
        flex-shrink: 0;
    }

    .desktop-nav-item .nav-icon svg {
        width: 20px;
        height: 20px;
        stroke: currentColor;
        fill: none;
        stroke-width: 2;
        stroke-linecap: round;
        stroke-linejoin: round;
    }

    .desktop-nav-item.active .nav-icon svg {
        stroke: #33cc33;
    }

    .desktop-nav-item .nav-label {
        flex: 1;
    }

    /* Language Switcher */
    .desktop-lang-switcher {
        display: flex;
        gap: 3px;
        padding: 3px;
        margin: 0 20px 16px;
        background: #0f0f3a;
        border-radius: 8px;
        border: 1px solid rgba(255, 255, 255, 0.08);
    }

    .desktop-lang-btn {
        flex: 1;
        padding: 8px 0;
        border: none;
        border-radius: 7px;
        background: transparent;
        color: rgba(238, 238, 238, 0.5);
        font-size: 13px;
        font-weight: 500;
        cursor: pointer;
        transition: all 0.2s ease;
        text-align: center;
    }

    .desktop-lang-btn:hover {
        background: rgba(255, 255, 255, 0.08);
        color: #eeffee;
    }

    .desktop-lang-btn.active {
        background: rgba(51, 204, 51, 0.2);
        color: #33cc33;
        font-weight: 600;
    }

    /* Content Area */
    .desktop-content-area {
        flex: 1;
        display: flex;
        flex-direction: column;
        overflow-y: auto;
        padding: 40px 50px;
    }

    .desktop-page {
        display: none;
        flex-direction: column;
        flex: 1;
        width: 100%;
    }

    .desktop-page.active {
        display: flex;
    }

    .desktop-page-title {
        font-size: 28px;
        font-weight: 700;
        color: #eeffee;
        margin: 0 0 30px 0;
        text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    }

    /* ─── Start Page ─── */
    .desktop-start-page {
        align-items: center;
        justify-content: center;
        gap: 30px;
        width: 100%;
    }

    .desktop-tutorial-hint {
        display: flex;
        align-items: center;
        gap: 16px;
        background: rgba(255, 255, 255, 0.08);
        padding: 16px 24px;
        border-radius: 14px;
        backdrop-filter: blur(10px);
        cursor: pointer;
        transition: all 0.3s ease;
        width: 100%;
        max-width: 480px;
        border: 1px solid rgba(255, 255, 255, 0.06);
    }

    .desktop-tutorial-hint:hover {
        background: rgba(255, 255, 255, 0.12);
        transform: translateY(-2px);
    }

    .desktop-tutorial-icon {
        width: 44px;
        height: 44px;
        border-radius: 50%;
        background: linear-gradient(135deg, #6a11cb, #2575fc);
        color: white;
        font-size: 26px;
        font-weight: bold;
        display: flex;
        align-items: center;
        justify-content: center;
        flex-shrink: 0;
    }

    .desktop-tutorial-text {
        color: rgba(255, 255, 255, 0.85);
        font-size: 14px;
        line-height: 1.5;
    }

    .desktop-logo-hero {
        text-align: center;
    }

    .desktop-logo-hero img {
        max-width: 320px;
        height: auto;
        filter: drop-shadow(0 0 20px rgba(255, 215, 0, 0.5));
    }

    /* Action area: left (learn) | divider | right (start + toggles) */
    .desktop-action-buttons {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 0;
        width: 100%;
        max-width: 600px;
    }

    .desktop-action-left {
        display: flex;
        align-items: center;
        justify-content: center;
        flex: 1;
        padding: 0 20px;
    }

    .desktop-action-divider {
        width: 1px;
        height: 160px;
        background: linear-gradient(to bottom, transparent, rgba(255, 255, 255, 0.2), transparent);
        flex-shrink: 0;
    }

    .desktop-action-right {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 20px;
        flex: 1;
        padding: 0 20px;
    }

    /* Mode toggles on start page — vertical, below start button */
    .desktop-mode-toggles {
        display: flex;
        flex-direction: column;
        gap: 10px;
    }

    .desktop-mode-toggle-item {
        display: flex;
        align-items: center;
        gap: 12px;
        background: rgba(255, 255, 255, 0.06);
        padding: 10px 18px;
        border-radius: 10px;
        border: 1px solid rgba(255, 255, 255, 0.08);
    }

    .desktop-mode-toggle-label {
        color: #eeffee;
        font-size: 14px;
        font-weight: 500;
    }

    .desktop-btn {
        border: none;
        padding: 16px 40px;
        font-size: 20px;
        font-weight: bold;
        border-radius: 30px;
        cursor: pointer;
        transition: all 0.3s ease;
        color: #fff;
        text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
        min-width: 200px;
        text-align: center;
    }

    .desktop-btn-start {
        background: linear-gradient(135deg, #e0af00, #ffcc00);
        box-shadow: 0 4px 20px rgba(224, 175, 0, 0.4);
    }

    .desktop-btn-start:hover {
        transform: scale(1.05);
        box-shadow: 0 6px 25px rgba(224, 175, 0, 0.6);
    }

    .desktop-btn-learning {
        background: linear-gradient(135deg, #4CAF50, #8BC34A);
        box-shadow: 0 4px 20px rgba(76, 175, 80, 0.4);
    }

    .desktop-btn-learning:hover {
        transform: scale(1.05);
        box-shadow: 0 6px 25px rgba(76, 175, 80, 0.6);
    }

    /* Hide close button on word library when opened from desktop sidebar */
    .word-library-manager.desktop-dictionary-modal .library-manager-close {
        display: none;
    }

    /* ─── Leaderboard Page ─── */
    .desktop-leaderboard-tabs {
        display: flex;
        margin-bottom: 24px;
        border-bottom: 2px solid rgba(51, 204, 51, 0.2);
    }

    .desktop-leaderboard-tab {
        flex: 1;
        padding: 14px 12px;
        background: transparent;
        border: none;
        border-bottom: 3px solid transparent;
        color: rgba(238, 238, 238, 0.6);
        font-size: 16px;
        font-weight: 500;
        cursor: pointer;
        transition: all 0.2s ease;
        text-align: center;
        margin-bottom: -2px;
    }

    .desktop-leaderboard-tab:hover {
        color: #eeffee;
        background-color: rgba(51, 204, 51, 0.06);
    }

    .desktop-leaderboard-tab.active {
        color: #eeffee;
        font-weight: 600;
        border-bottom-color: #33cc33;
        background-color: rgba(51, 204, 51, 0.05);
    }

    .desktop-leaderboard-list {
        flex: 1;
        overflow-y: auto;
    }

    .desktop-leaderboard-empty {
        text-align: center;
        color: rgba(255, 255, 255, 0.5);
        font-size: 16px;
        padding: 60px 20px;
        font-style: italic;
    }

    .desktop-leaderboard-items {
        list-style: none;
        padding: 0;
        margin: 0;
    }

    .desktop-leaderboard-item {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 14px 16px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.06);
        transition: background 0.2s ease;
    }

    .desktop-leaderboard-item:nth-child(odd) {
        background: rgba(255, 255, 255, 0.02);
    }

    .desktop-leaderboard-item:hover {
        background: rgba(255, 255, 255, 0.05);
    }

    .desktop-leaderboard-rank {
        flex: 0 0 60px;
        font-weight: bold;
        color: #a0a0a0;
        font-size: 16px;
    }

    .desktop-leaderboard-name {
        flex: 1;
        color: #eeffee;
        font-size: 16px;
        padding: 0 16px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .desktop-leaderboard-score {
        flex: 0 0 100px;
        text-align: right;
        font-weight: bold;
        color: #ffdd00;
        font-size: 18px;
    }

    /* ─── Wrong Log Page ─── */
    .desktop-wronglog-list {
        flex: 1;
        overflow-y: auto;
    }

    .desktop-wronglog-empty {
        text-align: center;
        color: rgba(255, 255, 255, 0.5);
        font-size: 16px;
        padding: 60px 20px;
        font-style: italic;
    }

    .desktop-wronglog-items {
        list-style: none;
        padding: 0;
        margin: 0;
        display: flex;
        flex-direction: column;
        gap: 10px;
    }

    .desktop-wronglog-item {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 14px 16px;
        background: rgba(255, 255, 255, 0.04);
        border: 1px solid rgba(255, 255, 255, 0.08);
        border-radius: 12px;
        transition: all 0.2s ease;
    }

    .desktop-wronglog-item:hover {
        background: rgba(255, 255, 255, 0.07);
    }

    .desktop-wronglog-item-text {
        color: #eeffee;
        font-size: 17px;
        font-weight: 500;
        flex: 1;
    }

    .desktop-wronglog-buttons {
        display: flex;
        gap: 8px;
        flex-shrink: 0;
    }

    .desktop-wronglog-btn {
        width: 40px;
        height: 40px;
        border: none;
        border-radius: 10px;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        transition: all 0.2s ease;
        font-size: 18px;
        color: white;
    }

    .desktop-wronglog-btn.search {
        background: linear-gradient(135deg, #3F51B5, #303F9F);
    }

    .desktop-wronglog-btn.search:hover {
        background: linear-gradient(135deg, #5C6BC0, #3949AB);
    }

    .desktop-wronglog-btn.remove {
        background: linear-gradient(135deg, #f44336, #d32f2f);
    }

    .desktop-wronglog-btn.remove:hover {
        background: linear-gradient(135deg, #e57373, #ef5350);
    }

    /* ─── Settings Page ─── */
    .desktop-settings-section {
        margin-bottom: 28px;
    }

    .desktop-settings-section h3 {
        color: #eeffee;
        font-size: 17px;
        font-weight: 600;
        margin: 0 0 16px 0;
        padding-bottom: 10px;
        border-bottom: 1px solid rgba(51, 204, 51, 0.25);
    }

    .desktop-settings-item {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 14px 16px;
        background: rgba(255, 255, 255, 0.03);
        border-radius: 10px;
        margin-bottom: 10px;
    }

    .desktop-settings-label {
        color: #eeffee;
        font-size: 15px;
        flex: 1;
    }

    /* Toggle switch */
    .desktop-toggle-switch {
        position: relative;
        width: 50px;
        height: 28px;
        flex-shrink: 0;
    }

    .desktop-toggle-switch input {
        opacity: 0;
        width: 0;
        height: 0;
    }

    .desktop-slider {
        position: absolute;
        cursor: pointer;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background-color: rgba(255, 255, 255, 0.2);
        transition: 0.3s;
        border-radius: 28px;
    }

    .desktop-slider:before {
        position: absolute;
        content: "";
        height: 22px;
        width: 22px;
        left: 3px;
        bottom: 3px;
        background-color: white;
        transition: 0.3s;
        border-radius: 50%;
    }

    .desktop-toggle-switch input:checked + .desktop-slider {
        background: linear-gradient(135deg, #33cc33, #28a428);
    }

    .desktop-toggle-switch input:checked + .desktop-slider:before {
        transform: translateX(22px);
    }

    .desktop-toggle-switch input:disabled + .desktop-slider {
        opacity: 0.5;
        cursor: not-allowed;
    }

    /* Volume */
    .desktop-volume-item {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    .desktop-volume-control {
        display: flex;
        align-items: center;
        gap: 12px;
        width: 100%;
    }

    .desktop-volume-slider {
        flex: 1;
        height: 6px;
        border-radius: 3px;
        background: rgba(255, 255, 255, 0.2);
        outline: none;
        -webkit-appearance: none;
        appearance: none;
    }

    .desktop-volume-slider::-webkit-slider-thumb {
        -webkit-appearance: none;
        width: 18px;
        height: 18px;
        border-radius: 50%;
        background: linear-gradient(135deg, #33cc33, #28a428);
        cursor: pointer;
    }

    .desktop-volume-slider::-moz-range-thumb {
        width: 18px;
        height: 18px;
        border-radius: 50%;
        background: linear-gradient(135deg, #33cc33, #28a428);
        cursor: pointer;
        border: none;
    }

    .desktop-volume-value {
        color: #eeffee;
        font-size: 14px;
        min-width: 45px;
        text-align: right;
    }

    /* Language select */
    .desktop-language-select {
        background: rgba(255, 255, 255, 0.1);
        border: 1px solid rgba(255, 255, 255, 0.2);
        border-radius: 8px;
        color: #eeffee;
        padding: 8px 12px;
        font-size: 15px;
        min-width: 140px;
        cursor: pointer;
    }

    .desktop-language-select:focus {
        outline: none;
        border-color: #33cc33;
        box-shadow: 0 0 8px rgba(51, 204, 51, 0.3);
    }

    .desktop-language-select option {
        background-color: #1a1a3e;
        color: white;
    }

    /* Changelog button */
    .desktop-changelog-btn {
        padding: 14px 24px;
        background: linear-gradient(135deg, #6c757d, #5a6268);
        border: none;
        border-radius: 10px;
        color: white;
        font-size: 15px;
        cursor: pointer;
        transition: all 0.3s ease;
        display: flex;
        align-items: center;
        gap: 10px;
    }

    .desktop-changelog-btn:hover {
        background: linear-gradient(135deg, #5a6268, #495057);
        transform: translateY(-2px);
    }

    .desktop-clear-cache-btn {
        padding: 14px 24px;
        margin-top: 10px;
        background: linear-gradient(135deg, #e74c3c, #c0392b);
        border: none;
        border-radius: 10px;
        color: white;
        font-size: 15px;
        cursor: pointer;
        transition: all 0.3s ease;
        display: flex;
        align-items: center;
        gap: 10px;
    }

    .desktop-clear-cache-btn:hover {
        background: linear-gradient(135deg, #c0392b, #a93226);
        transform: translateY(-2px);
    }

    /* ─── Dictionary Page ─── */
    .desktop-dict-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        margin-bottom: 24px;
    }

    .desktop-dict-header .desktop-page-title {
        margin: 0;
    }

    .dict-tutorial-btn {
        background: none;
        border: 1px solid rgba(255, 255, 255, 0.3);
        color: rgba(255, 255, 255, 0.7);
        font-size: 14px;
        font-weight: 700;
        cursor: pointer;
        border-radius: 50%;
        width: 28px;
        height: 28px;
        display: flex;
        align-items: center;
        justify-content: center;
        margin-left: 10px;
        transition: all 0.2s ease;
    }

    .dict-tutorial-btn:hover {
        color: white;
        border-color: rgba(255, 255, 255, 0.6);
        background: rgba(255, 255, 255, 0.1);
    }

    .desktop-dict-add-btn {
        padding: 10px 20px;
        background: linear-gradient(135deg, #33cc33, #28a428);
        border: none;
        border-radius: 8px;
        color: white;
        font-size: 14px;
        font-weight: 600;
        cursor: pointer;
        transition: all 0.2s ease;
    }

    .desktop-dict-add-btn:hover {
        transform: translateY(-1px);
        box-shadow: 0 4px 12px rgba(51, 204, 51, 0.3);
    }

    .desktop-library-list {
        display: flex;
        flex-direction: column;
        gap: 8px;
        margin-bottom: 28px;
        max-height: 40vh;
        overflow-y: auto;
        padding-right: 4px;
    }

    .desktop-library-list::-webkit-scrollbar {
        width: 6px;
    }

    .desktop-library-list::-webkit-scrollbar-track {
        background: rgba(255, 255, 255, 0.03);
        border-radius: 3px;
    }

    .desktop-library-list::-webkit-scrollbar-thumb {
        background: rgba(255, 255, 255, 0.15);
        border-radius: 3px;
    }

    .desktop-library-item {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 14px 16px;
        background: rgba(255, 255, 255, 0.03);
        border-radius: 10px;
        border-left: 3px solid transparent;
        cursor: pointer;
        transition: all 0.2s ease;
    }

    .desktop-library-item:hover {
        background: rgba(255, 255, 255, 0.06);
    }

    .desktop-library-item.active {
        background: rgba(51, 204, 51, 0.08);
        border-left-color: #33cc33;
    }

    .desktop-library-item-info {
        display: flex;
        flex-direction: column;
        gap: 2px;
        flex: 1;
    }

    .desktop-library-item-name {
        color: #eeffee;
        font-size: 15px;
        font-weight: 600;
    }

    .desktop-library-item-count {
        color: rgba(238, 255, 238, 0.5);
        font-size: 13px;
    }

    .desktop-library-item-actions {
        display: flex;
        align-items: center;
        gap: 10px;
    }

    .desktop-library-view-btn {
        padding: 6px 14px;
        background: transparent;
        border: 1px solid rgba(51, 204, 51, 0.4);
        border-radius: 6px;
        color: #33cc33;
        font-size: 13px;
        cursor: pointer;
        transition: all 0.2s ease;
    }

    .desktop-library-view-btn:hover {
        background: rgba(51, 204, 51, 0.1);
    }

    .desktop-library-current-tag {
        padding: 4px 10px;
        background: rgba(51, 204, 51, 0.2);
        border-radius: 12px;
        color: #33cc33;
        font-size: 12px;
        font-weight: 600;
    }

    .desktop-library-delete-btn {
        background: transparent;
        border: none;
        color: rgba(255, 100, 100, 0.6);
        cursor: pointer;
        font-size: 16px;
        padding: 4px;
        transition: all 0.2s ease;
        display: flex;
        align-items: center;
    }

    .desktop-library-delete-btn:hover {
        color: #ff6464;
    }

    .desktop-dict-upload-section {
        background: rgba(255, 255, 255, 0.03);
        border-radius: 10px;
        padding: 20px;
        margin-bottom: 20px;
    }

    .desktop-dict-upload-section h3 {
        color: #eeffee;
        font-size: 15px;
        font-weight: 600;
        margin: 0 0 14px 0;
    }

    .desktop-dict-upload-row {
        display: flex;
        gap: 10px;
        align-items: center;
        margin-bottom: 12px;
    }

    .desktop-dict-upload-row input[type="text"] {
        flex: 1;
        padding: 10px 14px;
        background: rgba(255, 255, 255, 0.06);
        border: 1px solid rgba(255, 255, 255, 0.1);
        border-radius: 8px;
        color: #eeffee;
        font-size: 14px;
        outline: none;
    }

    .desktop-dict-upload-row input[type="text"]::placeholder {
        color: rgba(238, 255, 238, 0.3);
    }

    .desktop-dict-upload-row input[type="text"]:focus {
        border-color: rgba(51, 204, 51, 0.5);
    }

    .desktop-dict-file-btn {
        padding: 10px 16px;
        background: rgba(255, 255, 255, 0.06);
        border: 1px solid rgba(255, 255, 255, 0.1);
        border-radius: 8px;
        color: #eeffee;
        font-size: 13px;
        cursor: pointer;
        transition: all 0.2s ease;
        white-space: nowrap;
    }

    .desktop-dict-file-btn:hover {
        background: rgba(255, 255, 255, 0.1);
    }

    .desktop-dict-upload-btn {
        padding: 10px 18px;
        background: linear-gradient(135deg, #33cc33, #28a428);
        border: none;
        border-radius: 8px;
        color: white;
        font-size: 13px;
        font-weight: 600;
        cursor: pointer;
        transition: all 0.2s ease;
        white-space: nowrap;
    }

    .desktop-dict-upload-btn:disabled {
        opacity: 0.4;
        cursor: not-allowed;
    }

    .desktop-dict-upload-btn:not(:disabled):hover {
        transform: translateY(-1px);
    }

    .desktop-dict-guide-btn {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        padding: 10px 20px;
        background: rgba(51, 204, 51, 0.1);
        border: 1px solid rgba(51, 204, 51, 0.3);
        border-radius: 8px;
        color: #33cc33;
        font-size: 14px;
        font-weight: 500;
        cursor: pointer;
        transition: all 0.2s ease;
    }

    .desktop-dict-guide-btn:hover {
        background: rgba(51, 204, 51, 0.2);
        border-color: rgba(51, 204, 51, 0.5);
        color: #44dd44;
    }

    .desktop-dict-actions {
        display: flex;
        gap: 10px;
    }

    .desktop-dict-export-btn,
    .desktop-dict-import-btn {
        flex: 1;
        padding: 12px 16px;
        border: none;
        border-radius: 8px;
        color: white;
        font-size: 14px;
        font-weight: 500;
        cursor: pointer;
        transition: all 0.2s ease;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
    }

    .desktop-dict-export-btn {
        background: linear-gradient(135deg, #7c4dff, #651fff);
    }

    .desktop-dict-import-btn {
        background: linear-gradient(135deg, #2196f3, #1976d2);
    }

    .desktop-dict-export-btn:hover,
    .desktop-dict-import-btn:hover {
        transform: translateY(-1px);
    }

    .desktop-dict-empty {
        text-align: center;
        padding: 40px 20px;
        color: rgba(238, 255, 238, 0.3);
        font-size: 14px;
    }
}