/* Vocabuddy 自定义样式 */

/* 警告框容器样式 */
#alertContainer {
    position: fixed !important;
    top: 20px !important;
    right: 20px !important;
    z-index: 10000 !important;
    max-width: 400px;
}

/* 全局样式 */
:root {
    --primary-color: #007bff;
    --secondary-color: #6c757d;
    --success-color: #28a745;
    --info-color: #17a2b8;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --light-color: #f8f9fa;
    --dark-color: #343a40;
    
    --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-success: linear-gradient(135deg, #56ab2f 0%, #a8e6cf 100%);
    --gradient-warning: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --gradient-info: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    
    --shadow-sm: 0 2px 4px rgba(0,0,0,0.1);
    --shadow-md: 0 4px 6px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 15px rgba(0,0,0,0.1);
    --shadow-xl: 0 20px 25px rgba(0,0,0,0.15);
    
    --border-radius: 8px;
    --border-radius-lg: 12px;
    --border-radius-xl: 16px;
}

* {
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}

/* 导航栏样式 */
.navbar {
    background: var(--gradient-primary) !important;
    box-shadow: var(--shadow-md);
    padding: 1rem 0;
}

/* 移动端导航栏优化 */
@media (max-width: 991.98px) {
    .navbar {
        padding: 0.5rem 1rem;
    }
    
    .navbar-brand {
        font-size: 1.25rem !important;
        display: flex;
        align-items: center;
        padding: 0.25rem 0;
        flex: 1;
        margin-right: 0;
    }
    
    .navbar-toggler {
        padding: 0.25rem 0.5rem;
        font-size: 1rem;
        line-height: 1;
        border: 1px solid rgba(255,255,255,0.3);
        border-radius: 0.25rem;
        margin-left: auto;
        order: 2;
    }
    
    .navbar-toggler:focus {
        box-shadow: none;
    }
    
    .navbar-nav .nav-link {
        padding: 0.75rem 1rem !important;
        margin: 0.25rem 0;
        text-align: left;
        display: flex;
        align-items: center;
    }
    
    .navbar-nav .nav-link i {
        margin-right: 0.5rem;
        width: 16px;
    }
    
    .navbar-collapse {
        margin-top: 0.5rem;
    }
    
    /* 移动端导航栏展开时显示文字 */
    .navbar-collapse.show .nav-text {
        display: inline !important;
    }
    
    /* 确保导航栏容器正确布局 */
    .navbar > .container-fluid {
        display: flex;
        align-items: center;
        justify-content: space-between;
    }
}

/* 自定义导航条断点 - 基于实际内容宽度 */
@media (max-width: 619.98px) {
    .navbar:not(.navbar-expand) .navbar-toggler {
        display: block;
        margin-left: auto;
    }
    
    .navbar:not(.navbar-expand) .navbar-collapse {
        display: none !important;
    }
    
    .navbar:not(.navbar-expand) .navbar-collapse.show {
        display: block !important;
    }
    
    .navbar-expand-custom {
        flex-wrap: nowrap;
        justify-content: space-between;
    }
    
    .navbar-expand-custom .navbar-brand {
        flex: 1;
        margin-right: 0;
    }
    
    .navbar-expand-custom .navbar-nav {
        flex-direction: column;
        width: 100%;
    }
    
    .navbar-expand-custom .navbar-nav .nav-link {
        padding: 0.75rem 1rem;
        text-align: left;
        border-bottom: 1px solid rgba(255,255,255,0.1);
    }
    
    .navbar-expand-custom .navbar-nav .nav-link:last-child {
        border-bottom: none;
    }
    
    .navbar-expand-custom .navbar-collapse {
        display: none !important;
        width: 100%;
        margin-top: 0.5rem;
    }
    
    .navbar-expand-custom .navbar-collapse.show {
        display: block !important;
    }
    
    .navbar-expand-custom .navbar-toggler {
        display: block;
        margin-left: auto;
        order: 2;
    }
    
    /* 确保导航栏容器正确布局 */
    .navbar-expand-custom > .container-fluid {
        display: flex;
        align-items: center;
        justify-content: space-between;
        flex-wrap: wrap;
    }
}

@media (min-width: 620px) {
    .navbar-expand-custom {
        flex-wrap: nowrap;
        justify-content: flex-start;
    }
    
    .navbar-expand-custom .navbar-nav {
        flex-direction: row;
    }
    
    .navbar-expand-custom .navbar-nav .nav-link {
        padding-right: 0.5rem;
        padding-left: 0.5rem;
    }
    
    .navbar-expand-custom .navbar-collapse {
        display: flex !important;
        flex-basis: auto;
    }
    
    .navbar-expand-custom .navbar-toggler {
        display: none;
    }
}

.navbar-brand {
    font-weight: 700;
    font-size: 1.5rem;
    color: white !important;
}

.navbar-nav .nav-link {
    color: rgba(255,255,255,0.9) !important;
    font-weight: 500;
    margin: 0 0.5rem;
    padding: 0.5rem 1rem !important;
    border-radius: var(--border-radius);
    transition: all 0.3s ease;
}

.navbar-nav .nav-link:hover {
    color: white !important;
    background-color: rgba(255,255,255,0.1);
    transform: translateY(-1px);
}

.navbar-nav .nav-link.active {
    color: white !important;
    background-color: rgba(255,255,255,0.2);
}

/* 用户头像样式 */
.user-avatar {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255,255,255,0.2);
    color: white;
    transition: all 0.3s ease;
}

.user-avatar:hover {
    background: rgba(255,255,255,0.3);
    transform: scale(1.1);
}

.user-avatar i {
    font-size: 1.2rem;
}

/* 用户菜单下拉框样式 */
#userMenu {
    position: relative;
}

#userMenu .dropdown-toggle {
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius);
    transition: all 0.3s ease;
}

#userMenu .dropdown-toggle:hover {
    background-color: rgba(255,255,255,0.1);
}

#userMenu .dropdown-menu {
    min-width: 200px;
    margin-top: 0.5rem;
    position: absolute !important;
    z-index: 1050;
}

#userMenu .dropdown-item.text-danger:hover {
    background-color: #f8d7da;
    color: #721c24 !important;
}

.dropdown-menu {
    border: none;
    box-shadow: var(--shadow-lg);
    border-radius: var(--border-radius-lg);
    padding: 0.5rem 0;
}

.dropdown-item {
    padding: 0.75rem 1.5rem;
    transition: all 0.2s ease;
}

.dropdown-item:hover {
    background-color: #f8f9fa;
    transform: translateX(5px);
}

/* 卡片样式 */
.card {
    border: none;
    border-radius: var(--border-radius-xl);
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
    overflow: hidden;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.card-header {
    border-bottom: none;
    font-weight: 600;
    padding: 1.5rem;
}

.card-body {
    padding: 1.5rem;
}

/* 移动端卡片优化 */
@media (max-width: 767.98px) {
    .card {
        margin-bottom: 1rem;
        border-radius: var(--border-radius);
    }
    
    .card:hover {
        transform: none;
    }
    
    .card-header {
        padding: 1rem;
        font-size: 1rem;
    }
    
    .card-body {
        padding: 1rem;
    }
}

/* 按钮样式 */
.btn {
    border-radius: var(--border-radius);
    font-weight: 500;
    padding: 0.75rem 1.5rem;
    transition: all 0.3s ease;
    border: none;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.btn:hover::before {
    left: 100%;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-primary {
    background: var(--gradient-primary);
}

.btn-success {
    background: var(--gradient-success);
}

.btn-warning {
    background: var(--gradient-warning);
}

.btn-info {
    background: var(--gradient-info);
}

.btn-lg {
    padding: 1rem 2rem;
    font-size: 1.1rem;
    border-radius: var(--border-radius-lg);
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

/* 表单样式 */
.form-control {
    border: 2px solid #e9ecef;
    border-radius: var(--border-radius);
    padding: 0.75rem 1rem;
    transition: all 0.3s ease;
    font-size: 1rem;
    max-width: 100%;
    display: block;
    margin: 0 auto;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(0,123,255,0.25);
    transform: translateY(-1px);
}

/* 移动端表单和按钮优化 */
@media (max-width: 767.98px) {
    .btn {
        padding: 0.75rem 1.25rem;
        font-size: 0.9rem;
        width: 100%;
        margin-bottom: 0.5rem;
    }
    
    .btn:hover {
        transform: none;
    }
    
    .btn-lg {
        padding: 1rem 1.5rem;
        font-size: 1rem;
    }
    
    .form-control {
        font-size: 16px; /* 防止iOS缩放 */
        padding: 1rem;
    }
    
    .form-control:focus {
        transform: none;
    }
    
    .d-grid.gap-2.d-md-flex {
        gap: 0.5rem !important;
    }
    
    .d-grid.gap-2.d-md-flex .btn {
        margin: 0;
    }
}

/* 复习页面输入框样式 - 只有底部边框 */
.review-input {
    border: none !important;
    border-bottom: 2px solid #e9ecef !important;
    border-radius: 0 !important;
    padding: 1rem 0.5rem;
    background: transparent !important;
    transition: all 0.3s ease;
    font-size: 1.25rem;
    outline: none;
    box-shadow: none !important;
    max-width: 100%;
    display: block;
    margin: 0 auto;
}

.review-input:focus {
    border: none !important;
    border-bottom: 2px solid var(--primary-color) !important;
    box-shadow: 0 2px 0 0 rgba(0,123,255,0.25) !important;
    transform: none;
    background: transparent !important;
}

/* 练习页面输入框样式 - 只有底部边框 */
.practice-input {
    border: none !important;
    border-bottom: 2px solid #e9ecef !important;
    border-radius: 0 !important;
    padding: 1rem 0.5rem;
    background: transparent !important;
    transition: all 0.3s ease;
    font-size: 1.25rem;
    outline: none;
    box-shadow: none !important;
    max-width: 100%;
    display: block;
    margin: 0 auto;
}

.practice-input:focus {
    border: none !important;
    border-bottom: 2px solid var(--primary-color) !important;
    box-shadow: 0 2px 0 0 rgba(0,123,255,0.25) !important;
    transform: none;
    background: transparent !important;
}

.form-label {
    font-weight: 600;
    color: #495057;
    margin-bottom: 0.5rem;
}

.input-group {
    box-shadow: var(--shadow-sm);
    border-radius: var(--border-radius);
    overflow: hidden;
}

/* 进度条样式 */
.progress {
    height: 10px;
    border-radius: 5px;
    background-color: #e9ecef;
    overflow: hidden;
}

.progress-bar {
    background: var(--gradient-primary);
    transition: width 0.6s ease;
}

/* 徽章样式 */
.badge {
    font-weight: 500;
    padding: 0.5rem 0.75rem;
    border-radius: var(--border-radius);
}

/* 警告框样式 */
.alert {
    border: none;
    border-radius: var(--border-radius-lg);
    padding: 1rem 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow-sm);
}

.alert-success {
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    color: #155724;
}

.alert-danger {
    background: linear-gradient(135deg, #f8d7da 0%, #f5c6cb 100%);
    color: #721c24;
}

.alert-warning {
    background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
    color: #856404;
}

.alert-info {
    background: linear-gradient(135deg, #d1ecf1 0%, #bee5eb 100%);
    color: #0c5460;
}

/* 模态框样式 */
.modal.show {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.modal.show .modal-dialog {
    margin: 0 !important;
    width: 90% !important;
    max-width: 500px !important;
}

.modal-content {
    border: none;
    border-radius: var(--border-radius-xl);
    box-shadow: var(--shadow-xl);
    width: 100% !important;
}

.modal-header {
    border-bottom: 1px solid #e9ecef;
    padding: 1.5rem;
}

.modal-body {
    padding: 1.5rem;
}

.modal-footer {
    border-top: 1px solid #e9ecef;
    padding: 1.5rem;
}

/* 列表组样式 */
.list-group-item {
    border: none;
    border-bottom: 1px solid #e9ecef;
    padding: 1rem 1.5rem;
    transition: all 0.2s ease;
}

.list-group-item:hover {
    background-color: #f8f9fa;
    transform: translateX(5px);
}

.list-group-item:last-child {
    border-bottom: none;
}

/* 加载动画 */
.spinner-border {
    width: 2rem;
    height: 2rem;
}

.spinner-border-sm {
    width: 1rem;
    height: 1rem;
}

/* 自定义动画 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

.fade-in {
    animation: fadeIn 0.6s ease-out;
}

.slide-in-left {
    animation: slideInLeft 0.6s ease-out;
}

.slide-in-right {
    animation: slideInRight 0.6s ease-out;
}

.pulse {
    animation: pulse 2s infinite;
}

/* 响应式设计 */
/* 在726px以上显示左侧主导航文字 */
@media (min-width: 727px) {
    /* 在726px以上显示左侧主导航文字 */
    .navbar-nav.me-auto .nav-link .nav-text {
        display: inline !important;
    }
}

@media (max-width: 726px) {
    .container {
        padding: 0 1rem;
    }
    
    .card {
        margin-bottom: 1rem;
    }
    
    .btn {
        width: 100%;
        margin-bottom: 0.5rem;
    }
    
    .navbar-nav {
        text-align: center;
    }
    
    /* 小屏幕下只隐藏左侧主导航的文字，保留图标 */
    .navbar-nav.me-auto .nav-link .nav-text {
        display: none !important;
    }
    
    /* 折叠菜单展开时显示图标和文字 */
    .navbar-collapse.show .navbar-nav.me-auto .nav-link .nav-text {
        display: inline !important;
    }
    
    .navbar-nav .nav-link {
        padding: 0.5rem 0.75rem !important;
        margin: 0 0.25rem;
    }
    

}

@media (max-width: 576px) {
    .container {
        padding: 0 0.5rem;
    }
    
    .card-body {
        padding: 1rem;
    }
    
    .btn {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
    
    h1 {
        font-size: 1.75rem;
    }
    
    h2 {
        font-size: 1.5rem;
    }
}

/* 特殊效果 */
.glass-effect {
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

.gradient-text {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.shadow-hover {
    transition: box-shadow 0.3s ease;
}

.shadow-hover:hover {
    box-shadow: var(--shadow-xl);
}

/* 工具类 */
.text-gradient {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.bg-gradient {
    background: var(--gradient-primary) !important;
    color: white !important;
}

.bg-gradient-primary {
    background: var(--gradient-primary) !important;
}

.bg-gradient-success {
    background: var(--gradient-success) !important;
}

.bg-gradient-warning {
    background: var(--gradient-warning) !important;
}

.bg-gradient-info {
    background: var(--gradient-info) !important;
}

.rounded-xl {
    border-radius: var(--border-radius-xl) !important;
}

.rounded-lg {
    border-radius: var(--border-radius-lg) !important;
}

.shadow-sm {
    box-shadow: var(--shadow-sm) !important;
}

.shadow-md {
    box-shadow: var(--shadow-md) !important;
}

.shadow-lg {
    box-shadow: var(--shadow-lg) !important;
}

.shadow-xl {
    box-shadow: var(--shadow-xl) !important;
}

/* 页脚样式 */
.footer {
    background: var(--gradient-primary);
    color: white;
    padding: 3rem 0 2rem;
    margin-top: 4rem;
}

.footer h5 {
    color: white;
    margin-bottom: 1rem;
}

.footer a {
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer a:hover {
    color: white;
}

.footer .social-links a {
    display: inline-block;
    width: 40px;
    height: 40px;
    line-height: 40px;
    text-align: center;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
    margin-right: 0.5rem;
    transition: all 0.3s ease;
}

.footer .social-links a:hover {
    background: rgba(255,255,255,0.2);
    transform: translateY(-2px);
}

/* 特色功能卡片 */
.feature-card {
    text-align: center;
    padding: 2rem;
    border-radius: var(--border-radius-xl);
    background: white;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
    height: 100%;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
}

.feature-card .icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: white;
}

.feature-card h4 {
    margin-bottom: 1rem;
    color: #333;
}

.feature-card p {
    color: #666;
    line-height: 1.6;
}

/* 统计数字 */
.stat-number {
    font-size: 3rem;
    font-weight: 700;
    line-height: 1;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 1.1rem;
    color: #666;
    font-weight: 500;
}

/* 练习页面样式 */
.practice-header {
    background: var(--gradient-primary);
    color: white;
    padding: 2rem;
    border-radius: var(--border-radius-xl);
    margin-bottom: 2rem;
    box-shadow: var(--shadow-md);
}

.practice-header h2 {
    color: white;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.practice-header .text-muted {
    color: rgba(255, 255, 255, 0.8) !important;
}

.practice-header .btn-outline-secondary {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
    color: white;
    font-weight: 500;
}

.practice-header .btn-outline-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.5);
    color: white;
    transform: translateY(-1px);
}

/* 移动端练习头部优化 */
@media (max-width: 767.98px) {
    .practice-header {
        padding: 1rem 1.25rem;
        margin-bottom: 1rem;
        border-radius: var(--border-radius);
    }
    
    .practice-header h2 {
        font-size: 1.25rem;
        margin-bottom: 0.25rem;
    }
    
    .practice-header .btn-outline-secondary {
        padding: 0.375rem 0.75rem;
        font-size: 0.875rem;
    }
    
    .practice-header .d-flex {
        gap: 0.5rem;
    }
}

/* 复习页面样式优化 */
.review-header {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    padding: 2.5rem;
    border-radius: 20px;
    margin-bottom: 2rem;
    box-shadow: 0 15px 35px rgba(40, 167, 69, 0.2);
    position: relative;
    overflow: hidden;
}

.review-header::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    pointer-events: none;
}

.review-header h2 {
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* 移动端复习头部优化 */
@media (max-width: 767.98px) {
    .review-header {
        padding: 1rem 1.25rem;
        margin-bottom: 1rem;
        border-radius: var(--border-radius);
    }
    
    .review-header h2 {
        font-size: 1.25rem;
        margin-bottom: 0.25rem;
    }
    
    .review-header .btn-outline-secondary {
        padding: 0.375rem 0.75rem;
        font-size: 0.875rem;
    }
    
    .review-header .d-flex {
        gap: 0.5rem;
    }
}

.review-card {
    border: none;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.08);
    min-height: 500px;
    background: linear-gradient(145deg, #ffffff 0%, #f8f9fa 100%);
    position: relative;
    overflow: hidden;
}

.review-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #28a745, #20c997, #17a2b8);
}

.review-card .card-body {
    padding: 3rem;
}

/* 单词含义区域优化 */
.word-meaning {
    position: relative;
    margin-bottom: 2rem;
}

.word-meaning .border {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%) !important;
    border: 3px solid transparent !important;
    background-clip: padding-box;
    box-shadow: 0 8px 25px rgba(40, 167, 69, 0.15);
    position: relative;
    overflow: hidden;
}

.word-meaning .border::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, #28a745, #20c997);
    margin: -3px;
    border-radius: inherit;
    z-index: -1;
}

.word-meaning h3 {
    font-size: 3rem !important;
    font-weight: 700 !important;
    color: #2d5a3d !important;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
    letter-spacing: -0.02em;
    line-height: 1.2;
}

/* 发音、熟练度和艾宾浩斯提示合并行样式 */
#pronunciation-section {
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%) !important;
    border-radius: 15px !important;
    padding: 1.5rem !important;
    margin-top: 1rem !important;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05) !important;
    border: 1px solid rgba(0,0,0,0.05) !important;
}

#pronunciation-section .btn-outline-primary {
    border: none !important;
    color: #007bff !important;
    background: transparent !important;
    font-weight: 600 !important;
    transition: all 0.3s ease !important;
    font-size: 1.1rem !important;
}

#pronunciation-section .btn-outline-primary:hover {
    background: #007bff !important;
    color: white !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.3) !important;
}

#pronunciation-section .proficiency-badge {
    font-size: 0.9rem !important;
    padding: 0.5rem 1rem !important;
}

#pronunciation-section small {
    font-size: 0.85rem !important;
    font-weight: 500 !important;
}

/* 统计信息卡片优化 */
.review-card .row.mb-4 .col-3 {
    margin-bottom: 1rem;
}

.review-card .row.mb-4 .text-center {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border-radius: 15px;
    padding: 1.5rem 1rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    border: 1px solid rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

.review-card .row.mb-4 .text-center:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

.review-card .h5 {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

/* 熟练度标签优化 */
.proficiency-badge {
    font-size: 1rem;
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    border: none;
}

.proficiency-badge.unknown {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
    color: white;
}

.proficiency-badge.learning {
    background: linear-gradient(135deg, #ffc107 0%, #e0a800 100%);
    color: #212529;
}

.proficiency-badge.familiar {
    background: linear-gradient(135deg, #17a2b8 0%, #138496 100%);
    color: white;
}

.proficiency-badge.mastered {
    background: linear-gradient(135deg, #28a745 0%, #1e7e34 100%);
    color: white;
}

/* 输入区域优化 */
.input-area {
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    border-radius: 20px;
    padding: 2rem;
    margin-top: 2rem;
    box-shadow: inset 0 2px 10px rgba(0,0,0,0.05);
}

.input-area .form-label {
    font-size: 1.1rem;
    font-weight: 600;
    color: #495057;
    margin-bottom: 1rem;
}

.input-area input {
    font-size: 1.6rem;
    padding: 1.5rem 1rem;
    border-radius: 15px;
    border: 3px solid #e9ecef;
    transition: all 0.3s ease;
    background: white;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.input-area input:focus {
    border-color: #28a745;
    box-shadow: 0 0 0 0.3rem rgba(40,167,69,.15), 0 8px 25px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}

/* 按钮组优化 */
.input-area .btn {
    padding: 1rem 2.5rem;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 15px;
    margin: 0.5rem;
    box-shadow: 0 6px 20px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.input-area .btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.input-area .btn-success {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    border: none;
}

.input-area .btn-outline-secondary {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border: 2px solid #dee2e6;
    color: #6c757d;
}

.input-area .btn-outline-secondary:hover {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-color: #adb5bd;
    color: #495057;
}

/* 详细信息区域优化 */
#wordDetails .card {
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    border: 1px solid rgba(0,0,0,0.05);
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.08);
}

#wordDetails h6 {
    font-size: 1rem;
    font-weight: 700;
    color: #495057;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 1rem;
}

#wordDetails .badge {
    background: linear-gradient(135deg, #6c757d 0%, #5a6268 100%);
    color: white;
    font-weight: 600;
    padding: 0.4rem 0.8rem;
    border-radius: 8px;
}

/* 艾宾浩斯提示优化 */
#ebbinghausHint {
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%);
    border: 2px solid rgba(23, 162, 184, 0.2);
    border-radius: 15px;
    padding: 1.5rem;
    margin: 1.5rem 0;
}

#ebbinghausHint .fa-brain {
    font-size: 1.2rem;
    color: #17a2b8;
}

/* 完成状态优化 */
#completionState .card {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border-radius: 25px;
    box-shadow: 0 25px 50px rgba(0,0,0,0.1);
    overflow: hidden;
    position: relative;
}

#completionState .card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 6px;
    background: linear-gradient(90deg, #28a745, #20c997, #17a2b8, #ffc107);
}

#completionState .fa-medal {
    color: #ffc107;
    text-shadow: 0 4px 8px rgba(255, 193, 7, 0.3);
    margin-bottom: 2rem;
}

#completionState h3 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

#completionState .border {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border: 2px solid rgba(0,0,0,0.05) !important;
    border-radius: 15px;
    padding: 2rem 1rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

#completionState .border:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

#completionState h4 {
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

/* 响应式优化 */
@media (max-width: 768px) {
    .review-header {
        padding: 2rem 1.5rem;
    }
    
    .review-card .card-body {
        padding: 2rem 1.5rem;
    }
    
    .word-meaning h3 {
        font-size: 2.2rem !important;
    }
    
    .input-area {
        padding: 1.5rem;
    }
    
    .input-area input {
        font-size: 1.3rem;
        padding: 1.2rem 0.8rem;
    }
    
    .input-area .btn {
        padding: 0.8rem 2rem;
        font-size: 1rem;
        margin: 0.3rem;
    }
}

/* 通用移动端优化 */
@media (max-width: 767.98px) {
    /* 页面标题优化 */
    h1 {
        font-size: 1.75rem;
    }
    
    h2 {
        font-size: 1.5rem;
    }
    
    h3 {
        font-size: 1.25rem;
    }
    
    /* 间距优化 */
    .mt-4 {
        margin-top: 1.5rem !important;
    }
    
    .mb-4 {
        margin-bottom: 1.5rem !important;
    }
    
    .py-5 {
        padding-top: 2rem !important;
        padding-bottom: 2rem !important;
    }
    
    /* 文字大小优化 */
    .lead {
        font-size: 1rem;
    }
    
    .display-4 {
        font-size: 2rem;
    }
    
    /* 图片响应式 */
    img {
        max-width: 100%;
        height: auto;
    }
    
    /* 表格响应式 */
    .table-responsive {
        font-size: 0.875rem;
    }
    
    /* 模态框优化 */
    .modal-dialog {
        margin: 1rem;
    }
    
    /* 下拉菜单优化 */
    .dropdown-menu {
        width: 100%;
        max-width: none;
    }
    
    /* 徽章优化 */
    .badge {
        font-size: 0.75rem;
        padding: 0.375rem 0.5rem;
    }
    
    /* 进度条优化 */
    .progress {
        height: 0.75rem;
    }
    
    /* 分页优化 */
    .pagination {
        justify-content: center;
    }
    
    .page-link {
        padding: 0.5rem 0.75rem;
        font-size: 0.875rem;
    }
}

/* 英雄区域 */
.hero {
    background: var(--gradient-primary);
    color: white;
    padding: 6rem 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 100" fill="%23ffffff" opacity="0.1"><polygon points="1000,100 1000,0 0,100"/></svg>') no-repeat;
    background-size: cover;
}

.hero .container {
    position: relative;
    z-index: 1;
}

.hero h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

@media (max-width: 768px) {
    .hero {
        padding: 4rem 0;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .hero p {
        font-size: 1.1rem;
    }
}

/* 学习模式单词列表布局修复 */
#wordsList {
    flex-wrap: wrap !important;
    margin: 0 -0.75rem !important;
}

#wordsList.card-mode {
    display: flex !important;
}

#wordsList .word-card-wrapper {
    padding: 0 0.75rem !important;
}

/* 修复btn-close按钮点击后的focus边框问题 */
.btn-close:focus {
    outline: none !important;
    box-shadow: none !important;
    border: none !important;
}

.btn-close:focus-visible {
    outline: none !important;
    box-shadow: none !important;
    border: none !important;
}

/* 学习面板容器样式 */
.study-panel-container {
    background: white;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
    overflow: hidden;
    margin-bottom: 2rem;
}

/* 模式切换标签样式 */
.mode-tabs {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 1.5rem 1.5rem 0;
    border-bottom: 1px solid #dee2e6;
    text-align: center;
}

.mode-tabs .btn-group {
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.mode-tabs .btn {
    flex: 1;
    min-width: 80px;
    padding: 0.8rem 1rem;
    font-size: 0.9rem;
    font-weight: 500;
    border: none;
    background: white;
    color: #6c757d;
    transition: all 0.3s ease;
    position: relative;
}

.mode-tabs .btn:hover {
    background: #f8f9fa;
    color: #495057;
    transform: translateY(-1px);
}

.mode-tabs .btn-check:checked + .btn {
    background: var(--bs-primary);
    color: white;
    box-shadow: 0 2px 8px rgba(0, 123, 255, 0.3);
    transform: translateY(-2px);
}

.mode-tabs .btn-outline-warning.btn-check:checked + .btn {
    background: var(--bs-warning);
    color: #212529;
    box-shadow: 0 2px 8px rgba(255, 193, 7, 0.3);
}

.mode-tabs .btn-outline-success.btn-check:checked + .btn {
    background: var(--bs-success);
    color: white;
    box-shadow: 0 2px 8px rgba(40, 167, 69, 0.3);
}

/* 面板内容样式 */
.panel-content {
    padding: 1.5rem;
}

.panel-content .alert {
    border: none;
    border-radius: var(--border-radius);
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow-sm);
    background: linear-gradient(135deg, #d1ecf1 0%, #bee5eb 100%);
}

/* 字典卡片在面板中的样式优化 */
.panel-content .dictionary-card {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: var(--border-radius);
    transition: all 0.3s ease;
    height: 100%;
}

.panel-content .dictionary-card:hover {
    border-color: #007bff;
    box-shadow: 0 8px 25px rgba(0, 123, 255, 0.15);
}

/* 字典网格间距优化 */
.panel-content #dictionariesGrid {
    margin-top: 0;
}

.panel-content #dictionariesGrid .col-12,
.panel-content #dictionariesGrid .col-md-6,
.panel-content #dictionariesGrid .col-lg-4 {
    margin-bottom: 1rem;
}

/* 确保在小屏幕上也能显示完整文字 */
@media (min-width: 576px) {
    .mode-tabs .btn {
        min-width: 100px;
        padding: 0.9rem 1.2rem;
        font-size: 1rem;
    }
    
    .mode-tabs {
        padding: 2rem 2rem 0;
    }
    
    .panel-content {
        padding: 2rem;
    }
}

/* 移除响应式隐藏，始终显示完整文字 */
.mode-tabs .btn span {
    display: inline !important;
}

.mode-tabs .btn .d-sm-none {
    display: none !important;
}

/* 复习统计区域字体优化 */
.review-card .row .h5 {
    font-size: 1rem !important;
}

.review-card .row .text-muted {
    font-size: 0.75rem !important;
}

/* 复习完成页面统计区域字体优化 */
#completionState .row h4 {
    font-size: 1.1rem !important;
}

#completionState .row .text-muted {
    font-size: 0.75rem !important;
}

/* PC端大屏幕最大宽度限制 */
@media (min-width: 1400px) {
    main.container-fluid {
        max-width: 1296px;
        margin: 0 auto;
    }
    
    footer .container-fluid {
        max-width: 1296px;
        margin: 0 auto;
    }
    
    /* 导航栏内容最大宽度限制 */
    .navbar .container-fluid {
        max-width: 1296px;
        margin: 0 auto;
    }
}

/* 修复iPad模式下下拉菜单宽度问题 */
@media (max-width: 768px) {
    .form-select {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box;
    }
    
    /* 确保下拉选项不会超出容器宽度 */
    .form-select option {
        max-width: 100%;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
}

@media (min-width: 1600px) {
    main.container-fluid {
        max-width: 1296px;
        margin: 0 auto;
    }
    
    footer .container-fluid {
        max-width: 1296px;
        margin: 0 auto;
    }
    
    /* 导航栏内容最大宽度限制 */
    .navbar .container-fluid {
        max-width: 1296px;
        margin: 0 auto;
    }
}