/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Avenir Next", "Avenir", sans-serif;
    font-weight: 300;
    background: #F4F4F4;
    min-height: auto;
    color: #000000;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 15px 8px;
    min-height: auto;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

/* 头部通用按钮样式 */
.header-btn {
    height: 36px;
    padding: 0 16px;
    border: none;
    border-radius: 8px;
    background: #FFFFFF;
    color: #000000;
    font-family: "Avenir Next", "Avenir", sans-serif;
    font-size: 0.9em;
    font-weight: 400;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    display: flex;
    align-items: center;
}

/* 头部样式 */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    backdrop-filter: blur(10px);
    border-radius: 10px;
    padding: 15px 20px 14.5px;
    flex-shrink: 0;
    position: relative;
}

/* 头部分割线 */
header::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 0.5px;
    background: #DDDDDD;
}

.header-left {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    flex: 1;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

header h1 {
    color: #000000;
    font-size: 1.5em;
    font-weight: 500;
    margin: 0;
    white-space: nowrap;
    min-width: max-content;
}

/* 难度选择 */
.difficulty-tabs {
    display: flex;
    gap: 2px;
    background: none;
    padding: 2px;
    border-radius: 8px;
    margin-right: auto;
}

.difficulty-dropdown {
    display: none;
    margin-right: auto;
}

.difficulty-dropdown select {
    height: 32px;
    padding: 0 8px;
    border: none;
    border-radius: 6px;
    background: #FFFFFF;
    color: #000000;
    font-family: "Avenir Next", "Avenir", sans-serif;
    font-size: 0.9em;
    font-weight: 400;
    cursor: pointer;
    transition: all 0.2s ease;
    outline: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6,9 12,15 18,9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 8px center;
    background-size: 16px;
    padding-right: 32px;
    width: fit-content;
    min-width: fit-content;
    max-width: none;
    display: inline-block;
}

/* 只在非触摸设备上应用hover效果 */
@media (hover: hover) and (pointer: fine) {
    .difficulty-dropdown select:hover {
        background-color: #F2F2F2;
    }
}

/* 移动端点击效果 */
.difficulty-dropdown select:active {
    background-color: #E8E8E8;
}

.difficulty-dropdown select:focus {
    background-color: #F2F2F2;
}

.difficulty-tabs .tab {
    height: 32px;
    padding: 0 8px;
    border: none;
    border-radius: 6px;
    background: none;
    color: #666666;
    font-family: "Avenir Next", "Avenir", sans-serif;
    font-size: 0.9em;
    font-weight: 400;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    display: flex;
    align-items: center;
}

/* 只在非触摸设备上应用hover效果 */
@media (hover: hover) and (pointer: fine) {
    .difficulty-tabs .tab:hover {
        background: #F2F2F2;
    }
}

/* 移动端点击效果 */
.difficulty-tabs .tab:active {
    background: #E8E8E8;
}

.difficulty-tabs .tab.active {
    background: none;
    color: #000000;
    font-weight: 600;
}

/* 计时器和状态信息 */
.timer-container, .mistakes, .language-switcher {
    height: 36px;
    padding: 0 16px;
    border: none;
    border-radius: 8px;
    background: #FFFFFF;
    color: #000000;
    font-family: "Avenir Next", "Avenir", sans-serif;
    font-size: 0.9em;
    font-weight: 500;
    white-space: nowrap;
    display: flex;
    align-items: center;
}

.timer-container {
    gap: 8px;
}

.timer-container #timer {
    font-family: "Avenir Next", "Avenir", sans-serif;
    font-size: 0.9em;
    font-weight: 600;
}

.timer-container #pause-btn {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 只在非触摸设备上应用hover效果 */
@media (hover: hover) and (pointer: fine) {
    .timer-container #pause-btn:hover {
        transform: scale(1.1);
    }
}

/* 移动端点击效果 */
.timer-container #pause-btn:active {
    transform: scale(1.05);
}

.timer-container #pause-btn .btn-icon {
    width: 20px;
    height: 20px;
    margin: 0;
}

/* 语言切换样式已移至footer */

/* 新游戏按钮 */
#new-game-btn {
    height: 36px;
    padding: 0 16px;
    border: none;
    border-radius: 8px;
    background: #DFE7C6;
    color: #000000;
    font-family: "Avenir Next", "Avenir", sans-serif;
    font-size: 0.9em;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    display: flex;
    align-items: center;
}

/* 只在非触摸设备上应用hover效果 */
@media (hover: hover) and (pointer: fine) {
    #new-game-btn:hover {
        background: #E8EED6;
        transform: translateY(-1px);
    }
}

/* 移动端点击效果 */
#new-game-btn:active {
    background: #D6E3BF;
    transform: translateY(0px);
}

/* 主要内容区域 */
main {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
    min-height: 0;
    overflow-x: hidden;
    width: 100%;
}

.game-area {
    border-radius: 15px;
    padding: 10px 5px;
    display: flex;
    flex-direction: row;
    gap: 25px;
    align-items: flex-start;
    justify-content: center;
    max-width: 950px;
    width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
    margin: 0 auto;
}

/* 数独网格 */
.sudoku-grid {
    display: grid;
    grid-template-columns: repeat(9, 1fr);
    grid-template-rows: repeat(9, 1fr);
    gap: 1px;
    background: #cdcdcd;
    padding: 2px;
    border-radius: 12px;
    width: min(450px, 90vw);
    height: min(450px, 90vw);
    flex-shrink: 0;
    box-sizing: border-box;
    overflow: hidden;  /* 确保内部单元格不会超出圆角 */
    position: relative; /* 为暂停覆盖层提供定位上下文 */
}

/* 单元格样式 */
.cell {
    aspect-ratio: 1;
    border: none;
    background: white;
    font-size: 1.5em;
    font-family: "Avenir Next", "Avenir", sans-serif;
    font-weight: 400;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    color: #6D7B43;  /* 用户填入的数字颜色 */
}

/* 四个角落的单元格圆角 */
.cell:first-child {
    border-top-left-radius: 10px;
}

.cell:nth-child(9) {
    border-top-right-radius: 10px;
}

.cell:nth-child(73) {
    border-bottom-left-radius: 10px;
}

.cell:nth-child(81) {
    border-bottom-right-radius: 10px;
}

.cell:hover {
    background: #DFE7C6;
}

.cell.highlighted {
    background: #F5F7ED  /* 使用半透明的高亮色 */
}

.cell.same-number,
.cell.selected.same-number {  /* 确保选中的数字格和其他相同数字的背景色一致 */
    background: #DFE7C6;
}

.cell.selected:not(.same-number) {  /* 仅当不是相同数字时才使用选中样式 */
    background: rgba(223, 231, 198, 0.5);
}

.cell.error {
    color: #FF0000;
}

.cell.given {
    color: #2c2c2c;  /* 预置数字为黑色 */
    font-weight: 400;  /* 预置数字字重 */
}

.cell.hint {
    background: #fff3e0;
    color: #6D7B43;
}

/* 3x3 宫格边框 */
.cell:nth-child(-n+9),
.cell:nth-child(n+28):nth-child(-n+36),
.cell:nth-child(n+55):nth-child(-n+63) {
    border-top: 0.5px solid #999999;
}

.cell:nth-child(n+19):nth-child(-n+27),
.cell:nth-child(n+46):nth-child(-n+54),
.cell:nth-child(n+73):nth-child(-n+81) {
    border-bottom: 0.5px solid #999999;
}

.cell:nth-child(9n+1),
.cell:nth-child(9n+4),
.cell:nth-child(9n+7) {
    border-left: 0.5px solid #999999;
}

.cell:nth-child(9n+3),
.cell:nth-child(9n+6),
.cell:nth-child(9n+9) {
    border-right: 0.5px solid #999999;
}

/* 暂停状态样式 */
.game-paused .cell,
.game-paused .cell.given,
.game-paused .cell.same-number,
.game-paused .cell.error,
.game-paused .cell.hint {
    color: transparent !important;
    text-shadow: 0 0 8px rgba(0, 0, 0, 0.3);
}

.game-paused .cell.notes-grid {
    opacity: 0.3;
}

.game-paused .note-number {
    color: transparent !important;
    text-shadow: 0 0 4px rgba(0, 0, 0, 0.2);
}

/* 暂停覆盖层和继续图标 */
.pause-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.7);
    display: none;
    justify-content: center;
    align-items: center;
    border-radius: 12px;
    z-index: 10;
    cursor: pointer;
}

.resume-icon {
    width: 64px;
    height: 64px;
    background-image: url('assets/icons/play64_64green.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    transition: transform 0.2s ease;
}

.resume-icon:hover {
    transform: scale(1.1);
}

/* 笔记样式 */
.cell.notes-grid {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
    box-sizing: border-box;
    padding: 1px;
}

.notes-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(3, 1fr);
    width: 100%;
    height: 100%;
    gap: 1px;
}

.note-number {
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(224, 224, 224, 0.15);
    border-radius: 1px;
    font-family: "Avenir Next", "Avenir", sans-serif;
    font-weight: 400;
    color: #a7a7a7;
    font-size: 0.25em;
    width: 100%;
    height: 100%;
    box-sizing: border-box;
    overflow: hidden;
    min-width: 0;
    min-height: 0;
}

/* 控制区域 */
.controls {
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: center;
    flex: 1;
    min-width: 0;
    max-width: 320px;
    width: 100%;
    position: relative;
    min-height: 400px;
    justify-content: flex-start;
}

/* 游戏状态区域 */
.game-status {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    width: 100%;
    margin-bottom: 15px;
}

/* 数字按钮 */
.number-pad {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    width: 100%;
    margin-top: 8px;
}

.number-btn {
    padding: 12px;
    font-size: 1.5em;
    font-family: "Avenir Next", "Avenir", sans-serif;
    font-weight: 500;
    border: 0px solid #DDDDDD;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    background: #FFFFFF;
    color: #6D7B43;
}

/* 只在非触摸设备上应用hover效果 */
@media (hover: hover) and (pointer: fine) {
    .number-btn:hover:not(:disabled) {
        background: #F2F2F2;
        transform: translateY(-2px);
    }
}

/* 移动端点击效果 */
.number-btn:active:not(:disabled) {
    background: #E8E8E8;
    transform: translateY(-1px);
}

.number-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: #F4F4F4;
}

/* 功能按钮 */
.icon-buttons {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    width: 100%;
    max-width: 420px;
    margin-top: 0px;
    justify-content: center;
}

.icon-button {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 8px 12px;
    font-size: 0.85em;
    font-weight: 400;
    border: 0px solid #DDDDDD;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    background: #FFFFFF;
    color: #00000050;
    min-height: 80px;
    min-width: 80px;
    width: 100%;
    box-sizing: border-box;
    position: relative;
}

.icon-button .btn-icon {
    width: 32px;
    height: 32px;
    margin: 0 auto 4px;
    display: block;
    object-fit: contain;
}

.icon-button span {
    text-align: center;
    display: block;
    width: 100%;
    white-space: normal;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.2;
    word-wrap: break-word;
    hyphens: auto;
    max-height: 2.4em;
}

.icon-button.active {
    background: #E8EED6;
    border-color: #A3B18A;
}

/* 只在非触摸设备上应用hover效果 */
@media (hover: hover) and (pointer: fine) {
    .icon-button:hover {
        background: #F2F2F2;
        transform: translateY(-2px);
    }
    
    .icon-button.active:hover {
        background: #D6E3BF;
    }
}

/* 移动端点击效果 */
.icon-button:active {
    background: #E8E8E8;
    transform: translateY(-1px);
}

.icon-button.active:active {
    background: #D6E3BF;
}

/* 提示计数器 */
.hint-counter {
    position: absolute;
    top: 4px;
    right: 4px;
    background: #F4F4F4;
    color: #6D7B43;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8em;
    font-weight: 600;
    font-family: "Avenir Next", "Avenir", sans-serif;
}

.icon-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.icon-button:disabled .hint-counter {
    background: #DDDDDD;
    color: #666666;
}

/* 暂停按钮图标切换 */
#pause-btn.paused .btn-icon {
    content: url('assets/icons/play64_64.png');
}

/* 弹窗样式 */
.game-controls {
    transition: opacity 0.3s ease;
}

.game-complete-content, .game-fail-content {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: white;
    padding: 30px;
    border-radius: 15px;
    text-align: center;
    animation: contentFadeIn 0.3s ease-out;
    display: flex;
    flex-direction: column;
    justify-content: center;
    box-sizing: border-box;
    z-index: 10;
}

@keyframes contentFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.game-complete-content h2, .game-fail-content h2 {
    color: #4CAF50;
    margin-bottom: 20px;
    font-size: 1.8em;
    font-weight: 500;
}

.game-fail-content h2 {
    color: #FF5252;
}

.complete-info {
    margin-bottom: 20px;
}

.complete-info p {
    margin: 10px 0;
    font-size: 1.1em;
    color: #333333;
}

/* 游戏结束信息中的数字样式 */
#final-time, #final-difficulty {
    font-weight: 600;
}

.best-records {
    background: #F4F4F4;
    border-radius: 10px;
    padding: 15px;
    margin: 20px 0;
    text-align: left;
}

.best-records h3 {
    color: #000000;
    margin-bottom: 15px;
    font-size: 1.2em;
    font-weight: 500;
    text-align: center;
}

.record-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    font-size: 1em;
    color: #333333;
    padding: 0 10px;
}

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

#play-again-btn, #retry-btn {
    background: #4CAF50;
    color: white;
    border: none;
    padding: 12px 25px;
    font-size: 1.1em;
    border-radius: 8px;
    cursor: pointer;
    margin: 20px auto 0;
    transition: all 0.2s ease;
    font-family: "Avenir Next", "Avenir", sans-serif;
    min-width: 150px;
}

#retry-btn {
    background: #FF5252;
}

#play-again-btn:hover, #retry-btn:hover {
    transform: translateY(-1px);
    filter: brightness(1.1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* 确认对话框 */
.confirm-dialog, .clear-data-dialog {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

.confirm-dialog.active, .clear-data-dialog.active {
    opacity: 1;
    visibility: visible;
}

/* 确保清除数据对话框默认隐藏 */
.clear-data-dialog {
    display: none;
}

.clear-data-dialog.active {
    display: flex;
}

.confirm-content {
    background: white;
    padding: 25px;
    border-radius: 15px;
    text-align: center;
    width: 90%;
    max-width: 300px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transform: translateY(0);
    opacity: 1;
    transition: all 0.2s ease;
}

.confirm-content h3 {
    color: #000000;
    margin-bottom: 15px;
    font-size: 1.2em;
    font-weight: 500;
}

.confirm-content p {
    color: #666666;
    margin-bottom: 20px;
    font-size: 0.95em;
    line-height: 1.4;
}

.confirm-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
}

.confirm-buttons button {
    padding: 10px 24px;
    border: none;
    border-radius: 6px;
    font-size: 0.9em;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: "Avenir Next", "Avenir", sans-serif;
    min-width: 90px;
}

#confirm-cancel {
    background: #F4F4F4;
    color: #666666;
}

#confirm-ok {
    background: #DFE7C6;
    color: #000000;
}

#confirm-cancel:hover {
    background: #E8E8E8;
    transform: translateY(-1px);
}

#confirm-ok:hover {
    background: #E8EED6;
    transform: translateY(-1px);
}

#clear-data-confirm {
    background: #d32f2f;
    color: white;
}

#clear-data-confirm:hover {
    background: #b71c1c;
    transform: translateY(-1px);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        padding: 6px 0;
        width: 100%;
    }
    
    /* 在768px断点下隐藏tab按钮，显示下拉菜单 */
    .difficulty-tabs {
        display: none;
    }
    
    .difficulty-dropdown {
        display: block;
    }
    
    .difficulty-dropdown select {
        height: 32px;
        padding: 0 8px;
        font-size: 0.9em;
        font-weight: 500;
        width: fit-content;
        min-width: fit-content;
        max-width: none;
        display: inline-block;
        padding-right: 32px;
    }
    
    .timer-container, .mistakes {
        padding: 6px 10px;
        font-size: 1.0em;
        font-weight: 400;
        flex-shrink: 0;
        height: 32px;
    }
    
    .timer-container #timer {
        font-size: 0.8em;
        font-weight: 400;
    }
    
    .timer-container #pause-btn .btn-icon {
        width: 14px;
        height: 14px;
    }
    
    #new-game-btn {
        height: 32px;
        padding: 0 8px;
        font-size: 0.9em;
        flex-shrink: 0;
    }
    
    .game-area {
        flex-direction: column;
        padding: 0;
        gap: 5px;
        align-items: center;
        width: 100%;
        box-sizing: border-box;
        margin: 0 auto;
    }
    
    .sudoku-grid {
        width: calc(100vw - 4px);
        height: calc(100vw - 4px);
        max-width: min(400px, calc(100% - 4px));
        max-height: min(400px, calc(100vw - 4px));
        margin: 0 auto;
    }
    
    .cell {
        font-size: 1.5em;
    }
    
    .controls {
        gap: 5px;
        width: calc(100vw - 4px);
        max-width: min(400px, calc(100% - 4px));
        margin: 0 auto;
        min-height: 100px;
    }
    
    /* 移动端游戏结束提示弹窗样式 */
    .game-complete-content, .game-fail-content {
        position: fixed;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        width: 90%;
        max-width: 350px;
        height: auto;
        min-height: 200px;
        background: white;
        padding: 25px;
        border-radius: 15px;
        text-align: center;
        box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
        z-index: 1000;
        display: flex;
        flex-direction: column;
        justify-content: center;
        box-sizing: border-box;
    }
    
    .game-status {
        gap: 10px;
        margin-bottom: 12px;
    }
    
    .number-pad {
        grid-template-columns: repeat(9, 1fr);
        width: calc(100vw - 4px);
        max-width: min(400px, calc(100% - 4px));
        gap: 2px;
        margin: 0 auto;
        margin-top: 12px;
    }
    
    .number-btn {
        padding: 12px 4px;
        font-size: 1.5em;
        width: 100%;
        min-width: 35px;
    }
    
    .icon-buttons {
        grid-template-columns: repeat(4, 1fr);
        width: calc(100vw - 4px);
        max-width: min(400px, calc(100% - 4px));
        gap: 6px;
        margin: 8px auto 0;
    }
    
    .icon-button {
        min-height: 65px;
        padding: 6px 4px;
        font-size: 0.7em;
        width: 100%;
    }
    
    .icon-button .btn-icon {
        width: 24px;
        height: 24px;
    }
}




/* 游戏状态栏样式 */
.game-status-bar {
    background: #f8f8f8;
    border-top: 1px solid #e0e0e0;
    padding: 8px 20px;
    margin-top: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    font-size: 1.0em;
    font-weight: 400;
    color: #666;
    opacity: 1;
}

.status-timer {
    display: flex;
    align-items: center;
    gap: 8px;
}

.status-timer #timer {
    font-family: "Avenir Next", "Avenir", sans-serif;
    font-size: 0.9em;
    font-weight: 500;
    color: #666;
}

.status-timer #pause-btn {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.7;
    transition: opacity 0.2s ease;
}

/* 只在非触摸设备上应用hover效果 */
@media (hover: hover) and (pointer: fine) {
    .status-timer #pause-btn:hover {
        opacity: 1;
        transform: scale(1.05);
    }
}

/* 移动端点击效果 */
.status-timer #pause-btn:active {
    opacity: 1;
    transform: scale(1.02);
}

.status-timer #pause-btn .btn-icon {
    width: 16px;
    height: 16px;
    margin: 0;
}

.status-mistakes {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.9em;
    font-weight: 500;
    color: #666;
}

/* Footer样式 */
.footer {
    background: #f8f8f8;
    border-top: 1px solid #e0e0e0;
    padding: 10px 0;
    margin-top: 0;
    text-align: center;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.footer-links {
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
}

.footer-link {
    color: #888888;
    text-decoration: none;
    font-size: 0.9em;
    font-weight: 400;
    transition: color 0.2s ease;
    background: none;
    border: none;
    cursor: pointer;
    font-family: inherit;
    padding: 0;
}

/* 只在非触摸设备上应用hover效果 */
@media (hover: hover) and (pointer: fine) {
    .footer-link:hover {
        color: #333;
        text-decoration: underline;
    }
    
    .clear-data-btn:hover {
        color: #d32f2f;
        text-decoration: underline;
    }
}

/* 移动端点击效果 */
.footer-link:active {
    color: #333;
}

.clear-data-btn:active {
    color: #d32f2f;
}

.footer-separator {
    color: #ccc;
    font-size: 0.9em;
}

.footer-language-switcher {
    display: inline-block;
}

.footer-language-switcher select {
    border: none;
    background: none;
    color: #888888;
    font-family: inherit;
    font-size: 0.9em;
    font-weight: 400;
    padding: 0;
    margin: 0;
    cursor: pointer;
    outline: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    transition: color 0.2s ease;
}

/* 只在非触摸设备上应用hover效果 */
@media (hover: hover) and (pointer: fine) {
    .footer-language-switcher select:hover {
        color: #333;
    }
}

/* 移动端点击效果 */
.footer-language-switcher select:active {
    color: #333;
}

.footer-language-switcher option {
    font-size: 1em;
    padding: 8px;
}

.footer-copyright {
    color: #c8c8c8;
    font-size: 0.8em;
    font-weight: 400;
    margin: 0;
}

.footer-copyright p {
    margin: 0;
}

.version-info {
    font-size: 0.8em;
    color: #c8c8c8;
    margin-top: 5px !important;
    font-weight: 400;
}

/* 移动端游戏状态栏和Footer样式 */
@media (max-width: 768px) {
    .game-status-bar {
        padding: 6px 15px;
        margin-top: 15px;
        gap: 15px;
        font-size: 1.1em;
        font-weight: 400;
    }
    
    .status-timer #timer {
        font-size: 0.8em;
    }
    
    .status-timer #pause-btn .btn-icon {
        width: 14px;
        height: 14px;
    }
    
    .status-mistakes {
        font-size: 0.8em;
    }
    
    .footer {
        padding: 8px 0;
        margin-top: 0;
    }
    
    .footer-content {
        padding: 0;
    }
    
    .footer-links {
        margin-bottom: 6px;
        gap: 8px;
    }
    
    .footer-link {
        font-size: 0.8em;
        display: inline-block;
        margin: 2px 0;
    }
    
    .footer-separator {
        font-size: 0.8em;
    }
    
    .footer-language-switcher select {
        font-size: 0.8em;
    }
    
    .footer-copyright {
        font-size: 0.75em;
    }
}


