/* ================================================================
main-quests.css
   游戏任务系统 统一样式表 (主线/支线/日常/悬赏/神域悬赏 全兼容)
   整体风格：暗黑低饱和 + 渐变质感 + 状态区分明确 + 全屏幕响应式适配
   状态规则：通用4种核心状态 - available(可接) | in-progress(进行中) | completed(可领奖) | reward-collected(已领奖)
   2026-01-09 整合优化 | 无冗余代码 | 所有样式统一规范 | 无冲突覆盖
================================================================ */

/* 公共动画 - 抽离复用 全局生效 */
@keyframes pulse-glow {
    0%,100% {
        box-shadow: 0 0 20px rgba(245,158,11,0.2);
    }
    50% {
        box-shadow: 0 0 30px rgba(245,158,11,0.4);
    }
}

@keyframes bounce {
    0%,100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-2px);
    }
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

/* 全局通用样式 - 所有任务共用 优先级最高 避免重复定义 */
.quest-name {
    font-size: 18px;
    font-weight: 700;
    color: #e2e8f0;
    margin-bottom: 8px;
}

.quest-description {
    color: #94a3b8;
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 16px;
}

.quest-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.quest-card-body {
    margin-bottom: 20px;
    flex: 1;
}

.quest-status-indicator {
    font-size: 14px;
    font-weight: 500;
    padding: 4px 10px;
    border-radius: 6px;
}

.reward-collected-text {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.2);
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    color: #10b981;
    margin-top: 8px;
}

.accepted-marker {
    color: #f59e0b;
    font-size: 1.2em;
}

.collected-marker {
    color: gold;
    font-size: 1.2em;
}

.reward-collected {
    opacity: 0.7;
}

.quest-progress {
    margin-top: 10px;
    padding: 8px 12px;
    background: rgba(30, 41, 59, 0.4);
    border-radius: 8px;
    font-size: 12px;
    color: #94a3b8;
}

.quest-progress span {
    color: #3b82f6;
    font-weight: 600;
}

/* 通用按钮样式 - 所有任务卡片按钮统一 抽离复用 无重复 */
.btn-small {
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.btn-small.btn-primary {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: white;
}

.btn-small.btn-primary:hover:not(:disabled) {
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.btn-small.btn-success {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
}

.btn-small.btn-success:hover {
    background: linear-gradient(135deg, #059669, #047857);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.3);
}

.btn-small.btn-warning {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
}

.btn-small.btn-danger {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
}

.btn-small.btn-secondary {
    background: rgba(30, 41, 59, 0.8);
    color: #94a3b8;
    border: 1px solid rgba(148, 163, 184, 0.2);
}

.btn-small.btn-secondary:hover {
    background: rgba(59, 130, 246, 0.1);
    color: #60a5fa;
    border-color: rgba(59, 130, 246, 0.3);
}

.btn-small.btn-disabled {
    background: rgba(148, 163, 184, 0.2);
    color: #94a3b8;
    cursor: not-allowed;
}

.btn-small:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none !important;
}

.btn-medium {
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 10px;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-medium.btn-primary {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: white;
}

.btn-medium.btn-primary:hover:not(:disabled) {
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

/* 通用空状态/加载状态/错误状态 - 所有任务模块共用 统一视觉 */
.loading-state {
    text-align: center;
    padding: 60px 20px;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(59, 130, 246, 0.3);
    border-top: 3px solid #3b82f6;
    border-radius: 50%;
    margin: 0 auto 20px;
    animation: spin 1s linear infinite;
}

.loading-spinner.large {
    width: 50px;
    height: 50px;
    border: 3px solid rgba(34, 197, 94, 0.3);
    border-top: 3px solid #10b981;
}

.empty-state, .quest-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    text-align: center;
    background: rgba(30, 41, 59, 0.6);
    border-radius: 16px;
    border: 2px dashed rgba(148, 163, 184, 0.3);
}

.empty-icon {
    font-size: 64px;
    color: #94a3b8;
    margin-bottom: 20px;
    opacity: 0.5;
}

.empty-title {
    font-size: 18px;
    font-weight: 600;
    color: #94a3b8;
    margin-bottom: 12px;
}

.empty-description {
    font-size: 14px;
    color: #64748b;
    max-width: 400px;
    margin: 0 auto 20px;
    line-height: 1.6;
}

.error-state, .quest-error-state, .bounty-error-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    text-align: center;
    background: rgba(239, 68, 68, 0.05);
    border-radius: 16px;
    border: 2px solid rgba(239, 68, 68, 0.2);
}

.error-icon {
    font-size: 64px;
    color: #ef4444;
    margin-bottom: 20px;
}

.error-title {
    font-size: 18px;
    font-weight: 600;
    color: #ef4444;
    margin-bottom: 12px;
}

.error-description {
    font-size: 14px;
    color: #fca5a5;
    max-width: 400px;
    margin: 0 auto 20px;
    line-height: 1.6;
}

/* 通用标签徽章样式 - 所有任务类型的角标/计数统一 */
.tab-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    background: linear-gradient(135deg, #ef4444, #dc2626);
    border-radius: 10px;
    font-size: 11px;
    font-weight: 700;
    color: white;
    margin-left: 6px;
}

.tab-badge.has-items {
    background: linear-gradient(135deg, #10b981, #059669);
    animation: pulse 2s infinite;
}

.count-badge {
    padding: 2px 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    font-size: 12px;
    font-weight: 600;
    color: white;
}

/* 通用任务卡片操作按钮组 - 所有任务卡片底部按钮布局统一 */
.quest-action-buttons, .bounty-action-buttons, .task-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    justify-content: space-between;
    width: 100%;
}

.quest-action-buttons .btn-small, .bounty-action-buttons .btn-small {
    flex: 1;
    min-width: 70px;
    margin: 2px;
    padding: 4px 6px;
    font-size: 12px;
    gap: 3px;
}

/* ================================================================
   一级/二级标签页 容器样式 (任务系统顶部切换标签 - 全局唯一)
================================================================ */
.sub-tabs-container {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.sub-tabs {
    display: flex;
    gap: 4px;
    padding: 16px 24px;
    background: rgba(30, 41, 59, 0.4);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    overflow-x: auto;
}

.sub-tab-btn {
    padding: 10px 20px;
    background: rgba(30, 41, 59, 0.3);
    border: 1px solid rgba(148, 163, 184, 0.1);
    border-radius: 10px;
    color: #94a3b8;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 8px;
}

.sub-tab-btn:hover {
    background: rgba(59, 130, 246, 0.1);
    border-color: rgba(59, 130, 246, 0.3);
    color: #60a5fa;
}

.sub-tab-btn.active {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    border-color: #3b82f6;
    color: white;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.2);
}

.sub-content {
    flex: 1;
    overflow-y: auto;
    padding: 24px;
}

.sub-tab-pane {
    display: none;
    height: 100%;
}

.sub-tab-pane.active {
    display: block;
}

/* ================================================================
   任务列表通用布局 (网格/容器) - 所有任务模块共用
================================================================ */
.tasks-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 16px;
    padding: 20px;
}

.list-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.list-stats {
    display: flex;
    gap: 24px;
}

.stat-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.stat-label {
    font-size: 13px;
    color: #94a3b8;
}

.stat-value {
    font-size: 18px;
    font-weight: 700;
    color: #e2e8f0;
}

.stat-value.success {
    color: #10b981;
}

.stat-value.danger {
    color: #ef4444;
}

.list-actions {
    display: flex;
    gap: 12px;
}

/* ================================================================
   【1】主线任务 特有样式 (main-quests.css)
   风格：沉稳深蓝 + 弱渐变 + 已接任务橙色高亮脉冲特效
================================================================ */
.main-quest-card {
    background: rgba(30, 41, 59, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 20px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    min-height: 200px;
    display: flex;
    flex-direction: column;
}

.main-quest-card:hover {
    background: rgba(30, 41, 59, 0.8);
    border-color: rgba(59, 130, 246, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

/* 主线任务4种核心状态 - 左侧竖线区分 */
.main-quest-card.available, .main-quest-card.in-progress {
    border-left: 4px solid #3b82f6;
}

.main-quest-card.completed {
    border-left: 4px solid #10b981;
}

.main-quest-card.reward-collected {
    border-left: 4px solid #94a3b8;
}

/* 主线特有：已接任务高亮+呼吸发光特效 */
.main-quest-card.accepted-highlight {
    border: 2px solid #f59e0b;
    box-shadow: 0 0 20px rgba(245, 158, 11, 0.2);
    animation: pulse-glow 2s infinite;
}

/* 主线任务徽章 */
.quest-type-badge.main-quest-badge {
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 600;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(59, 130, 246, 0.15);
    color: #60a5fa;
}

/* 主线卡片顶部渐变分割线 */
.main-quest-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(59, 130, 246, 0.3), transparent);
}

.main-quest-card.completed::before {
    background: linear-gradient(90deg, transparent, rgba(16, 185, 129, 0.3), transparent);
}

.main-quest-card.reward-collected::before {
    background: linear-gradient(90deg, transparent, rgba(148, 163, 184, 0.3), transparent);
}

/* 主线任务头部+统计面板 */
.main-quests-header {
    margin-bottom: 20px;
}

.main-quests-header .panel-header {
    display: flex;
    align-items: center;
    padding: 16px 20px;
    background: rgba(30, 41, 59, 0.8);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.main-quests-header .panel-title {
    font-size: 18px;
    font-weight: 700;
    color: #e2e8f0;
    margin-left: 12px;
}

.main-quests-header .panel-icon {
    font-size: 24px;
    color: #10b981;
}

.main-quests-header .panel-actions {
    display: flex;
    gap: 8px;
}

/* ================================================================
   【2】支线任务 特有样式 (side-quests.css)
   风格：深紫渐变 + 高透背景 + 状态底色弱区分 + 简洁无冗余
================================================================ */
.side-quest-card {
    background: rgba(30, 41, 59, 0.8);
    border-radius: 16px;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
    margin-bottom: 16px;
    position: relative;
}

.side-quest-card.available {
    border-left: 4px solid #3b82f6;
}

.side-quest-card.in-progress {
    border-left: 4px solid #f59e0b;
    background: rgba(245, 158, 11, 0.05);
}

.side-quest-card.completed {
    border-left: 4px solid #10b981;
    background: rgba(16, 185, 129, 0.05);
}

.side-quest-card.reward-collected {
    border-left: 4px solid #94a3b8;
    background: rgba(148, 163, 184, 0.05);
    opacity: 0.7;
}

.side-quest-card.accepted-highlight {
    box-shadow: 0 0 20px rgba(245, 158, 11, 0.2);
}

/* 支线任务徽章-紫渐变主视觉 */
.side-quest-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    color: white;
}

/* 支线任务状态指示器-右上角悬浮图标 */
.side-quest-card .quest-status-indicator {
    position: absolute;
    top: 16px;
    right: 16px;
    font-size: 20px;
    padding: 0;
}

.side-quest-card .quest-status-indicator.available {
    color: #3b82f6;
}

.side-quest-card .quest-status-indicator.in-progress {
    color: #f59e0b;
}

.side-quest-card .quest-status-indicator.completed {
    color: #10b981;
}

.side-quest-card .quest-status-indicator.reward-collected {
    color: #94a3b8;
}

/* 支线任务头部+统计面板 */
.side-quests-header {
    margin-bottom: 20px;
}

.side-quests-header .panel-header {
    display: flex;
    align-items: center;
    padding: 16px 20px;
    background: rgba(30, 41, 59, 0.8);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.side-quests-header .panel-title {
    font-size: 18px;
    font-weight: 700;
    color: #e2e8f0;
    margin-left: 12px;
}

.side-quests-header .panel-icon {
    font-size: 24px;
    color: #10b981;
}

.side-quests-header .panel-actions {
    display: flex;
    gap: 8px;
}

/* ================================================================
   【3】日常任务 特有样式 (daily-quests.css)
   风格：生机绿渐变 + 梯度背景 + 副本信息角标 + 统计面板专属
================================================================ */
.daily-quest-card {
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.1), rgba(30, 41, 59, 0.8));
    border: 1px solid rgba(34, 197, 94, 0.2);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 16px;
    transition: all 0.3s ease;
    position: relative;
}

.daily-quest-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(34, 197, 94, 0.15);
    border-color: rgba(34, 197, 94, 0.3);
}

/* 日常任务4种状态区分-背景+边框双渐变 */
.daily-quest-card.available {
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.08), rgba(30, 41, 59, 0.8));
    border: 1px solid rgba(34, 197, 94, 0.15);
}

.daily-quest-card.in-progress {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.08), rgba(30, 41, 59, 0.8));
    border: 1px solid rgba(245, 158, 11, 0.2);
    border-left: 4px solid #f59e0b;
}

.daily-quest-card.completed {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.08), rgba(30, 41, 59, 0.8));
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-left: 4px solid #3b82f6;
}

.daily-quest-card.reward-collected {
    background: linear-gradient(135deg, rgba(148, 163, 184, 0.08), rgba(30, 41, 59, 0.8));
    border: 1px solid rgba(148, 163, 184, 0.15);
    opacity: 0.7;
}

/* 日常特有：已接任务左侧渐变竖线 */
.daily-quest-card.accepted-highlight {
    position: relative;
    overflow: hidden;
}

.daily-quest-card.accepted-highlight::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(to bottom, #10b981, #3b82f6);
    border-radius: 16px 0 0 16px;
}

/* 日常任务徽章-绿渐变主视觉 */
.daily-quest-badge {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

/* 日常任务头部+统计面板 */
.daily-quests-header {
    margin-bottom: 20px;
}

.daily-quests-header .panel-header {
    display: flex;
    align-items: center;
    padding: 16px 20px;
    background: rgba(30, 41, 59, 0.8);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.daily-quests-header .panel-title {
    font-size: 18px;
    font-weight: 700;
    color: #e2e8f0;
    margin-left: 12px;
}

.daily-quests-header .panel-icon {
    font-size: 24px;
    color: #10b981;
}

.daily-quests-header .panel-actions {
    display: flex;
    gap: 8px;
}

/* 日常任务统计卡片 */
.daily-quest-stats {
    margin-bottom: 20px;
    padding: 16px;
    background: rgba(30, 41, 59, 0.8);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.daily-quest-stats .stats-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
}

.daily-quest-stats .stat-card {
    background: rgba(30, 41, 59, 0.6);
    border-radius: 12px;
    padding: 16px;
    text-align: center;
    border: 1px solid rgba(148, 163, 184, 0.1);
    transition: all 0.3s ease;
}

.daily-quest-stats .stat-card:hover {
    transform: translateY(-2px);
    background: rgba(34, 197, 94, 0.1);
    border-color: rgba(34, 197, 94, 0.2);
}

.daily-quest-stats .stat-value {
    font-size: 24px;
    font-weight: 700;
    color: #10b981;
    margin-bottom: 8px;
}

/* 日常任务副本信息角标 */
.daily-quest-card .dungeon-info {
    font-size: 13px;
    color: #60a5fa;
    margin-top: 8px;
    padding: 8px 12px;
    background: rgba(59, 130, 246, 0.1);
    border-radius: 8px;
    border: 1px solid rgba(59, 130, 246, 0.2);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

/* 日常任务专属加载弹窗 */
#daily-quest-loading.loading-container {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

#daily-quest-loading .loading-content {
    text-align: center;
    background: rgba(30, 41, 59, 0.9);
    padding: 30px;
    border-radius: 16px;
    border: 1px solid rgba(34, 197, 94, 0.2);
}

/* ================================================================
   【4】悬赏任务 特有样式 (含神域悬赏)
   风格：深蓝渐变 + 双倍奖励橙标 + 神域悬赏紫调专属 + 剩余次数统计
================================================================ */
/* 悬赏任务分类标签 */
.bounty-type-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    padding: 12px;
    background: rgba(30, 41, 59, 0.4);
    border-radius: 12px;
}

.bounty-type-btn {
    flex: 1;
    padding: 12px 16px;
    background: rgba(30, 41, 59, 0.3);
    border: 1px solid rgba(148, 163, 184, 0.1);
    border-radius: 10px;
    color: #94a3b8;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.bounty-type-btn:hover {
    background: rgba(59, 130, 246, 0.1);
    border-color: rgba(59, 130, 246, 0.3);
    color: #60a5fa;
}

.bounty-type-btn.active {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    border-color: #3b82f6;
    color: white;
}

/* 悬赏剩余次数统计 */
.bounty-remaining-counter {
    margin-bottom: 20px;
    padding: 16px;
    background: rgba(30, 41, 59, 0.6);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.counter-label {
    font-size: 14px;
    color: #94a3b8;
    margin-bottom: 8px;
}

.counter-value {
    font-size: 24px;
    font-weight: 700;
    color: #3b82f6;
}

.counter-value.available {
    color: #10b981;
}

.counter-value.exhausted {
    color: #ef4444;
}

/* 悬赏任务卡片核心样式 */
.bounty-task-card {
    background: rgba(30, 41, 59, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 20px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.bounty-task-card:hover {
    background: rgba(30, 41, 59, 0.8);
    border-color: rgba(59, 130, 246, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

/* 悬赏任务状态区分-左侧竖线 */
.bounty-task-card.divine {
    border-left: 4px solid #8b5cf6;
}

.bounty-task-card.double-reward {
    border-left: 4px solid #f59e0b;
}

.bounty-task-card.completed {
    border-left: 4px solid #10b981;
}

.bounty-task-card.in-progress {
    border-left: 4px solid #3b82f6;
}

/* 悬赏任务徽章 */
.task-type-badge {
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 600;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.task-type-badge.normal-badge {
    background: rgba(59,130,246,0.15);
    color: #60a5fa;
}

.task-type-badge.divine-badge {
    background: rgba(139,92,246,0.15);
    color: #a78bfa;
}

/* 双倍奖励专属徽章 */
.double-reward-badge {
    display: inline-block;
    padding: 4px 10px;
    background: rgba(245,158,11,0.15);
    border-radius: 6px;
    color: #f59e0b;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 16px;
}

/* 悬赏任务进度/奖励列表 */
.task-requirements, .task-rewards {
    margin-bottom: 16px;
    margin-top: 16px;
}

.requirements-label, .rewards-label {
    font-size: 13px;
    color: #94a3b8;
    margin-bottom: 8px;
    display: block;
}

.requirements-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.requirements-list li {
    padding: 8px 12px;
    background: rgba(30,41,59,0.3);
    border-radius: 8px;
    margin-bottom: 6px;
    font-size: 13px;
    color: #cbd5e1;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.requirements-list li.completed {
    background: rgba(34,197,94,0.1);
    color: #10b981;
}

.req-progress {
    font-weight: 600;
    color: #f59e0b;
}

.rewards-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.reward-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: rgba(30,41,59,0.4);
    border-radius: 8px;
    font-size: 13px;
}

.reward-item.coin {
    color: #f59e0b;
}

.reward-item.exp {
    color: #3b82f6;
}

.reward-item.double .reward-count::after {
    content: "×2";
    font-size: 10px;
    color: #f59e0b;
    margin-left: 4px;
}

/* 悬赏统计面板 */
.bounty-stats-summary {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
    padding: 16px;
    background: rgba(30,41,59,0.4);
    border-radius: 12px;
}

.stat-value.completed {
    color: #10b981;
}

.stat-value.double-reward {
    color: #f59e0b;
}

/* ========== 神域悬赏 专属样式 (最高级悬赏) ========== */
.divine-bounty-header {
    margin-bottom: 24px;
    padding: 20px;
    background: linear-gradient(135deg, rgba(139,92,246,0.1), rgba(79,70,229,0.1));
    border-radius: 12px;
    border: 1px solid rgba(139,92,246,0.2);
}

.divine-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
    color: white;
    border-radius: 20px;
    font-weight: 600;
    font-size: 16px;
    margin-bottom: 12px;
}

.divine-tip {
    color: #a78bfa;
    font-size: 14px;
}

.divine-tasks .bounty-task-card {
    border: 1px solid rgba(139,92,246,0.3);
    background: rgba(139,92,246,0.05);
}

.divine-tasks .reward-item.divine {
    background: rgba(139,92,246,0.15);
    color: #a78bfa;
}

/* ================================================================
   批量进度条弹窗 (通用) + 任务卡片通用状态
================================================================ */
.batch-progress-bar {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 400px;
    background: rgba(15, 23, 42, 0.95);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
    z-index: 9998;
    backdrop-filter: blur(10px);
}

.progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.progress-title {
    font-size: 16px;
    font-weight: 600;
    color: #e2e8f0;
}

.progress-close {
    font-size: 24px;
    color: #94a3b8;
    cursor: pointer;
    padding: 0 8px;
    line-height: 1;
}

.progress-close:hover {
    color: #ef4444;
}

.progress-stats {
    display: flex;
    justify-content: space-between;
    margin-bottom: 16px;
    font-size: 14px;
    color: #94a3b8;
}

.progress-actions {
    margin-top: 16px;
    text-align: center;
}

/* ================================================================
   全尺寸响应式适配 (移动端/平板/PC) 无死角兼容
   优先级最低，覆盖所有设备尺寸，所有任务模块共用
================================================================ */
@media (max-width: 768px) {
    .sub-tabs {
        padding: 0 16px;
        overflow-x: auto;
    }

    .sub-tab-btn {
        padding: 8px 14px;
        font-size: 13px;
    }

    .sub-content {
        padding: 16px;
    }

    .tasks-grid, #daily-quest-list .tasks-grid {
        grid-template-columns: 1fr;
        padding: 16px;
        gap: 12px;
    }

    .quest-action-buttons, .bounty-action-buttons, .task-actions {
        flex-direction: column;
    }

    .quest-action-buttons .btn-small, .bounty-action-buttons .btn-small {
        width: 100%;
        min-width: unset;
        padding: 8px 12px;
        font-size: 12px;
    }

    .list-header {
        flex-direction: column;
        gap: 16px;
        align-items: stretch;
    }

    .list-stats {
        justify-content: space-between;
    }

    .bounty-stats-summary, .daily-quest-stats .stats-cards {
        flex-direction: column;
        gap: 12px;
    }

    .batch-progress-bar {
        width: calc(100% - 40px);
        left: 20px;
        right: 20px;
        bottom: 20px;
    }

    .task-header, .task-footer {
        flex-direction: column;
        gap: 12px;
        align-items: stretch;
    }

    .task-rewards {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .main-quest-card, .side-quest-card, .daily-quest-card {
        margin: 0 -20px;
        padding: 16px;
    }

    .quest-name {
        font-size: 16px;
    }

    .quest-description {
        font-size: 13px;
    }
}

/* === Toast 提示消息样式 === */
#toast-container {
    position: fixed;
    top: 0;
    right: 0;
    padding: max(30px, env(safe-area-inset-top, 30px)) 
             max(30px, env(safe-area-inset-right, 30px)) 
             0 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
    z-index: 3000;
    pointer-events: none;
    box-sizing: border-box;
    max-width: 100vw;
    transform: translateZ(0);
    -webkit-transform: translateZ(0);
    contain: layout style paint;
    z-index: 99999;
}

/* 单个提示消息 */
.toast-item {
    pointer-events: auto;
    padding: 16px 24px;
    background: rgba(15, 23, 42, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    box-shadow: 
        0 20px 40px rgba(0, 0, 0, 0.3),
        0 0 0 1px rgba(255, 255, 255, 0.05);
    transform: translateX(100%);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    min-width: 280px;
    max-width: min(400px, calc(100vw - 60px));
    box-sizing: border-box;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

/* 消息显示/隐藏的动画触发 */
.toast-item.show {
    transform: translateX(0);
    opacity: 1;
}

/* 消息内容布局 */
.toast-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.toast-icon {
    font-size: 20px;
    flex-shrink: 0;
}

/* ✅ 你指定的所有配色 完全保留 */
.toast-item.success .toast-icon {
    color: #10b981;
}
.toast-item.error .toast-icon {
    color: #ef4444;
}
.toast-item.warning .toast-icon {
    color: #f59e0b;
}
.toast-item.info .toast-icon {
    color: #3b82f6;
}

.toast-message {
    color: #e2e8f0;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.4;
    word-break: break-word;
}

/* 移动端适配 */
@media (max-width: 768px) {
    #toast-container {
        padding: max(20px, env(safe-area-inset-top, 20px)) 
                 max(20px, env(safe-area-inset-right, 20px)) 
                 0 0;
        gap: 12px;
    }
    
    .toast-item {
        padding: 14px 20px;
        min-width: 260px;
        max-width: calc(100vw - 40px);
    }
    
    .toast-icon {
        font-size: 18px;
    }
    
    .toast-message {
        font-size: 13px;
    }
}

/* 超小屏幕优化 */
@media (max-width: 480px) {
    #toast-container {
        padding: max(16px, env(safe-area-inset-top, 16px)) 
                 max(16px, env(safe-area-inset-right, 16px)) 
                 0 0;
    }
    
    .toast-item {
        padding: 12px 16px;
        min-width: 240px;
        max-width: calc(100vw - 32px);
    }
}

/* 针对 iOS Safari 的优化 */
@supports (-webkit-touch-callout: none) {
    #toast-container {
        position: -webkit-sticky;
    }
}

/* 针对输入法键盘弹出时的优化 */
@media (max-height: 500px) {
    #toast-container {
        padding-top: max(10px, env(safe-area-inset-top, 10px));
        gap: 8px;
    }
    
    .toast-item {
        padding: 10px 16px;
        min-width: 220px;
    }
}

/* ================================================================
   任务系统标签响应式优化
   针对手机端等小屏幕设备的标签布局优化
================================================================ */

/* === 一级标签栏响应式优化 === */
.inventory-tabs {
    display: flex;
    gap: 8px;
    padding: 0 0 12px 0;
    margin-top: 16px;
    overflow-x: auto;
    scrollbar-width: none; /* Firefox隐藏滚动条 */
    -ms-overflow-style: none; /* IE/Edge隐藏滚动条 */
    scroll-behavior: smooth;
}

.inventory-tabs::-webkit-scrollbar {
    display: none; /* Chrome/Safari隐藏滚动条 */
}

/* 一级标签按钮优化 */
.tab-btn {
    padding: 12px 16px;
    background: rgba(30, 41, 59, 0.4);
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 12px;
    color: #94a3b8;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    position: relative;
    overflow: hidden;
    white-space: nowrap;
    flex-shrink: 0; /* 防止标签被压缩 */
}

/* 小屏幕时减少标签内边距和字体 */
@media (max-width: 768px) {
    .inventory-tabs {
        gap: 6px;
        padding-bottom: 10px;
        margin-top: 12px;
    }
    
    .tab-btn {
        padding: 10px 14px;
        font-size: 13px;
        gap: 6px;
    }
    
    .tab-btn span:first-child {
        font-size: 16px;
    }
    
    .tab-badge {
        font-size: 10px;
        padding: 2px 6px;
        min-width: 18px;
        margin-left: 4px;
    }
}

/* 超小屏幕优化 */
@media (max-width: 480px) {
    .inventory-tabs {
        gap: 4px;
        padding-bottom: 8px;
    }
    
    .tab-btn {
        padding: 8px 12px;
        font-size: 12px;
        gap: 4px;
        border-radius: 10px;
    }
    
    .tab-btn span:first-child {
        font-size: 14px;
    }
    
    /* 超小屏幕隐藏部分文字 */
    .tab-btn[data-tab="quest-tab"] .tab-badge,
    .tab-btn[data-tab="daily-tab"] .tab-badge,
    .tab-btn[data-tab="activity-tab"] .tab-badge {
        position: absolute;
        top: -4px;
        right: -4px;
    }
    
    .tab-btn .tab-badge {
        transform: scale(0.9);
    }
}

/* 横向滚动提示（仅在小屏幕显示） */
@media (max-width: 768px) {
    .inventory-tabs-wrapper {
        position: relative;
    }
    
    .inventory-tabs-wrapper::after {
        content: '→';
        position: absolute;
        right: 0;
        top: 50%;
        transform: translateY(-50%);
        color: #94a3b8;
        opacity: 0.5;
        animation: slideHint 2s infinite;
        pointer-events: none;
        z-index: 1;
        background: linear-gradient(to right, transparent, rgba(15, 23, 42, 0.9));
        padding: 0 10px;
        font-size: 18px;
    }
    
    @keyframes slideHint {
        0%, 100% { opacity: 0.3; }
        50% { opacity: 0.7; }
    }
}

/* === 二级标签栏响应式优化 === */
.sub-tabs {
    display: flex;
    gap: 6px;
    padding: 12px 16px;
    background: rgba(30, 41, 59, 0.4);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    overflow-x: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(59, 130, 246, 0.5) transparent;
}

.sub-tab-btn {
    padding: 10px 16px;
    background: rgba(30, 41, 59, 0.3);
    border: 1px solid rgba(148, 163, 184, 0.1);
    border-radius: 10px;
    color: #94a3b8;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

/* 小屏幕二级标签优化 */
@media (max-width: 768px) {
    .sub-tabs {
        padding: 10px 12px;
        gap: 4px;
    }
    
    .sub-tab-btn {
        padding: 8px 12px;
        font-size: 12px;
        gap: 4px;
        border-radius: 8px;
    }
    
    .sub-tab-btn span:first-child {
        font-size: 14px;
    }
}

/* 超小屏幕二级标签优化 */
@media (max-width: 480px) {
    .sub-tabs {
        padding: 8px 10px;
    }
    
    .sub-tab-btn {
        padding: 6px 10px;
        font-size: 11px;
        gap: 3px;
    }
    
    .sub-tab-btn span:first-child {
        font-size: 12px;
    }
}

/* === 悬赏任务类型标签优化 === */
.bounty-type-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    padding: 12px;
    background: rgba(30, 41, 59, 0.4);
    border-radius: 12px;
    overflow-x: auto;
}

.bounty-type-btn {
    flex: 1;
    padding: 10px 14px;
    background: rgba(30, 41, 59, 0.3);
    border: 1px solid rgba(148, 163, 184, 0.1);
    border-radius: 10px;
    color: #94a3b8;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    flex-shrink: 0;
    min-width: 120px;
}

/* 小屏幕悬赏标签优化 */
@media (max-width: 768px) {
    .bounty-type-tabs {
        padding: 10px;
        gap: 6px;
    }
    
    .bounty-type-btn {
        padding: 8px 12px;
        font-size: 12px;
        gap: 4px;
        min-width: 100px;
    }
}

@media (max-width: 480px) {
    .bounty-type-btn {
        min-width: 90px;
        font-size: 11px;
        padding: 6px 10px;
    }
}

/* === 通用优化：任务卡片在小屏幕的显示 === */
@media (max-width: 768px) {
    .quest-list, .bounty-list-container {
        /* padding: 12px; */
    }
    
    .quest-action-buttons, .bounty-action-buttons {
        flex-direction: column;
        gap: 8px;
    }
    
    .quest-action-buttons .btn-small,
    .bounty-action-buttons .btn-small {
        width: 100%;
        margin: 0;
        padding: 10px;
    }
}

/* === 触摸设备优化 === */
@media (hover: none) and (pointer: coarse) {
    .tab-btn,
    .sub-tab-btn,
    .bounty-type-btn {
        min-height: 44px; /* iOS推荐的最小触摸尺寸 */
    }
    
    .tab-btn.active::before,
    .sub-tab-btn.active::before {
        height: 4px;
        bottom: -2px;
    }
    
    /* 增加触摸反馈 */
    .tab-btn:active,
    .sub-tab-btn:active,
    .bounty-type-btn:active {
        transform: scale(0.98);
        background: rgba(59, 130, 246, 0.2);
    }
}

/* === 暗色模式优化 === */
@media (prefers-color-scheme: dark) {
    .tab-btn,
    .sub-tab-btn,
    .bounty-type-btn {
        background: rgba(30, 41, 59, 0.6);
    }
    
    .tab-btn.active,
    .sub-tab-btn.active,
    .bounty-type-btn.active {
        background: linear-gradient(135deg, #3b82f6, #2563eb);
    }
}

/* === 横屏模式优化 === */
@media (max-width: 768px) and (orientation: landscape) {
    .inventory-tabs {
        gap: 4px;
    }
    
    .tab-btn {
        padding: 6px 10px;
        font-size: 11px;
    }
    
    .sub-tabs {
        padding: 6px 8px;
    }
    
    .sub-tab-btn {
        padding: 6px 10px;
        font-size: 11px;
    }
}

/* === 高对比度模式支持 === */
@media (prefers-contrast: high) {
    .tab-btn,
    .sub-tab-btn,
    .bounty-type-btn {
        border-width: 2px;
    }
    
    .tab-btn.active,
    .sub-tab-btn.active,
    .bounty-type-btn.active {
        border-color: #3b82f6;
        border-width: 2px;
    }
}


/* ================================================================
   主线任务操作按钮组响应式优化
   针对手机端等小屏幕设备的按钮布局优化
================================================================ */

/* === 主线任务操作按钮组容器 === */
.main-quests-header .panel-actions {
    display: flex;
    gap: 12px;
    align-items: center;
}

/* === 按钮基础样式优化 === */
.main-quests-header .btn-small {
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 10px;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    white-space: nowrap;
    min-height: 36px;
}

/* 主按钮样式 */
.main-quests-header .btn-primary {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: white;
}

.main-quests-header .btn-primary:hover:not(:disabled) {
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

/* 次要按钮样式 */
.main-quests-header .btn-secondary {
    background: rgba(30, 41, 59, 0.8);
    color: #94a3b8;
    border: 1px solid rgba(148, 163, 184, 0.2);
}

.main-quests-header .btn-secondary:hover {
    background: rgba(59, 130, 246, 0.1);
    color: #60a5fa;
    border-color: rgba(59, 130, 246, 0.3);
}

/* 成功按钮样式 */
.main-quests-header .btn-success {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
}

.main-quests-header .btn-success:hover:not(:disabled) {
    background: linear-gradient(135deg, #059669, #047857);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.3);
}

/* 禁用状态 */
.main-quests-header .btn-small:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none !important;
}

/* === 平板设备优化 (768px以下) === */
@media (max-width: 768px) {
    .main-quests-header .panel-actions {
        gap: 8px;
        flex-wrap: wrap;
        justify-content: flex-start;
    }
    
    .main-quests-header .btn-small {
        padding: 8px 12px;
        font-size: 12px;
        gap: 4px;
        min-height: 34px;
        flex: 1;
        min-width: 0;
    }
    
    /* 调整按钮图标大小 */
    .main-quests-header .btn-small span:first-child {
        font-size: 14px;
    }
}

/* === 手机设备优化 (480px以下) === */
@media (max-width: 480px) {
    .main-quests-header .panel-header {
        flex-direction: column;
        align-items: stretch;
        gap: 16px;
    }
    
    .main-quests-header .panel-actions {
        width: 100%;
        gap: 6px;
    }
    
    /* 按钮组网格布局 */
    .main-quests-header .btn-small {
        padding: 10px 8px;
        font-size: 11px;
        gap: 3px;
        min-height: 40px;
        border-radius: 8px;
    }
    
    /* 一键完成按钮突出显示 */
    .main-quests-header .auto-complete-main-quests-btn {
        order: -1; /* 移到最前面 */
        flex: 2;
        background: linear-gradient(135deg, #f59e0b, #d97706);
        font-weight: 700;
    }
    
    .main-quests-header .auto-complete-main-quests-btn span:first-child {
        font-size: 16px;
        animation: rocketPulse 2s infinite;
    }
    
    @keyframes rocketPulse {
        0%, 100% { transform: scale(1); }
        50% { transform: scale(1.1); }
    }
    
    /* 刷新和手动刷新按钮 */
    .main-quests-header .refresh-main-quest-btn,
    .main-quests-header .btn-secondary {
        flex: 1;
    }
    
    /* 按钮图标更小 */
    .main-quests-header .btn-small span:first-child {
        font-size: 12px;
    }
}

/* === 超小屏幕优化 (360px以下) === */
@media (max-width: 360px) {
    .main-quests-header .btn-small {
        font-size: 10px;
        padding: 8px 6px;
    }
    
    /* 隐藏部分按钮文字，只显示图标 */
    .main-quests-header .btn-small span:not(:first-child) {
        display: none;
    }
    
    .main-quests-header .btn-small {
        gap: 0;
        min-width: 44px; /* 触摸友好尺寸 */
    }
    
    /* 一键完成按钮保留文字 */
    .main-quests-header .auto-complete-main-quests-btn span:not(:first-child) {
        display: inline;
        font-size: 10px;
    }
}

/* === 横屏模式优化 === */
@media (max-width: 768px) and (orientation: landscape) {
    .main-quests-header .panel-actions {
        flex-wrap: nowrap;
    }
    
    .main-quests-header .btn-small {
        flex: none;
        width: auto;
        min-width: 80px;
    }
}

/* === 触摸设备优化 === */
@media (hover: none) and (pointer: coarse) {
    .main-quests-header .btn-small {
        min-height: 44px; /* iOS推荐的最小触摸尺寸 */
        padding: 12px 16px;
    }
    
    /* 增加触摸反馈 */
    .main-quests-header .btn-small:active {
        transform: scale(0.95);
        transition: transform 0.1s ease;
    }
    
    /* 禁用按钮的触摸反馈 */
    .main-quests-header .btn-small:disabled:active {
        transform: none;
    }
}

/* === 暗色模式优化 === */
@media (prefers-color-scheme: dark) {
    .main-quests-header .btn-secondary {
        background: rgba(30, 41, 59, 0.9);
        border-color: rgba(148, 163, 184, 0.3);
    }
    
    .main-quests-header .btn-secondary:hover {
        background: rgba(59, 130, 246, 0.2);
    }
}

/* === 加载状态指示器 === */
.main-quests-header .btn-small.loading {
    position: relative;
    color: transparent;
}

.main-quests-header .btn-small.loading::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top: 2px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.main-quests-header .btn-secondary.loading::after {
    border-color: rgba(148, 163, 184, 0.3);
    border-top-color: #94a3b8;
}

/* === 按钮状态提示 === */
.main-quests-header .btn-small:disabled {
    cursor: not-allowed;
    opacity: 0.6;
}

/* === 悬停提示优化 === */
.main-quests-header .btn-small[title] {
    position: relative;
}

@media (min-width: 769px) {
    .main-quests-header .btn-small[title]:hover::after {
        content: attr(title);
        position: absolute;
        bottom: 100%;
        left: 50%;
        transform: translateX(-50%);
        background: rgba(15, 23, 42, 0.95);
        color: #e2e8f0;
        padding: 6px 12px;
        border-radius: 6px;
        font-size: 12px;
        white-space: nowrap;
        z-index: 1000;
        margin-bottom: 8px;
        border: 1px solid rgba(255, 255, 255, 0.1);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    }
}

/* === 响应式动画 === */
.main-quests-header .btn-small {
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* === 高对比度模式 === */
@media (prefers-contrast: high) {
    .main-quests-header .btn-small {
        border-width: 2px;
    }
    
    .main-quests-header .btn-primary {
        border: 2px solid #1d4ed8;
    }
    
    .main-quests-header .btn-success {
        border: 2px solid #047857;
    }
}

/* === 打印模式隐藏 === */
@media print {
    .main-quests-header .panel-actions {
        display: none;
    }
}



/* 卡片容器 */
.item-card {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.9), rgba(15, 23, 42, 0.95));
    border-radius: 16px;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    animation: fadeIn 0.5s ease;
}

/* 品质边框 */
.item-card-quality-border {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    border-radius: 16px 16px 0 0;
}

/* 卡片头部 */
.item-card-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
}

/* 图标容器 */
.item-icon-container {
    position: relative;
    width: 60px;
    height: 60px;
    flex-shrink: 0;
}

.item-icon {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.9), rgba(15, 23, 42, 0.9));
    padding: 8px;
}

.item-icon-border {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 12px;
    pointer-events: none;
}

/* 品质角标 */
.item-quality-badge {
    position: absolute;
    bottom: -6px;
    right: -6px;
    color: white;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: 700;
    border: 2px solid rgba(15, 23, 42, 0.8);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

/* 信息区域 */
.item-info {
    flex: 1;
}

.item-name {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 4px;
    line-height: 1.3;
}

.item-id {
    font-family: 'Monaco', 'Courier New', monospace;
    font-size: 11px;
    color: #94a3b8;
    margin-bottom: 8px;
    opacity: 0.8;
}

.item-entity-id {
    font-family: 'Monaco', 'Courier New', monospace;
    font-size: 10px;
    color: #64748b;
    margin-bottom: 8px;
    word-break: break-all;
}

.item-quantity {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
}

/* 描述区域 */
.item-description {
    color: #cbd5e1;
    font-size: 13px;
    line-height: 1.5;
    margin-bottom: 16px;
    padding: 12px;
    background: rgba(30, 41, 59, 0.4);
    border-radius: 8px;
    border-left: 3px solid rgba(255, 255, 255, 0.2);
    position: relative;
}

.item-desc-content {
    /* 描述内容容器 */
}

.item-desc-row {
    margin-bottom: 8px;
}

.item-desc-text {
    /* 描述文本 */
}

.item-type-tag {
    position: absolute;
    top: 8px;
    right: 8px;
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 10px;
}

/* 操作按钮区域 */
.item-actions {
    display: flex;
    gap: 10px;
    margin-top: 16px;
}

.inventory-btn {
    flex: 1;
    border: none;
    border-radius: 10px;
    padding: 10px;
    color: white;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* 按钮类型 */
.btn-use {
    background: linear-gradient(135deg, #10b981, #059669);
}

.btn-sell {
    background: linear-gradient(135deg, #f59e0b, #d97706);
}

.btn-detail {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
}

.btn-disassemble, .btn-resolve {
    background: linear-gradient(135deg, #ef4444, #dc2626);
}

/* 悬停效果 */
.inventory-btn:hover {
    transform: translateY(-2px);
}

.btn-use:hover {
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.btn-sell:hover {
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

.btn-detail:hover {
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.btn-disassemble:hover, .btn-resolve:hover {
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

/* 卡片悬停效果 */
.item-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.3);
}

/* 品质等级颜色 */
.item-quality-1 { /* 优秀 - 绿色 */ }
.item-quality-2 { /* 精良 - 蓝色 */ }
.item-quality-3 { /* 史诗 - 紫色 */ }
.item-quality-4 { /* 传说 - 橙色 */ }
.item-quality-5 { /* 邪灵 - 红色 */ }
.item-quality-6 { /* 神器 - 粉色 */ }
.item-quality-7 { /* 上古 - 靛蓝 */ }
.item-quality-8 { /* 灵器 - 青色 */ }
.item-quality-9 { /* 魂器 - 黄绿 */ }
.item-quality-10 { /* 深渊 - 橙红 */ }