/* 亚光黑色系主题样式 */

/* 配色方案定义 */
:root {
    /* 主色调 - 亚光黑色系 */
    --bg-primary: #0a0a0a;           /* 主背景 - 深黑 */
    --bg-secondary: #1a1a1a;         /* 次要背景 - 炭黑 */
    --bg-tertiary: #2a2a2a;          /* 第三背景 - 深灰 */
    --bg-card: #1e1e1e;              /* 卡片背景 - 亚光黑 */
    --bg-hover: #333333;             /* 悬停背景 */
    
    /* 文字颜色 */
    --text-primary: #ffffff;          /* 主要文字 - 纯白 */
    --text-secondary: #cccccc;        /* 次要文字 - 浅灰 */
    --text-muted: #888888;            /* 弱化文字 - 中灰 */
    --text-accent: #64ffda;           /* 强调文字 - 青色 */
    
    /* 边框颜色 */
    --border-primary: #333333;        /* 主要边框 */
    --border-secondary: #444444;      /* 次要边框 */
    --border-accent: #64ffda;         /* 强调边框 */
    
    /* 按钮颜色 */
    --btn-primary-bg: linear-gradient(135deg, #1a1a1a 0%, #2a2a2a 100%);
    --btn-primary-hover: linear-gradient(135deg, #2a2a2a 0%, #3a3a3a 100%);
    --btn-accent-bg: linear-gradient(135deg, #64ffda 0%, #4fd3b8 100%);
    --btn-accent-hover: linear-gradient(135deg, #4fd3b8 0%, #3bb89f 100%);
    
    /* 阴影效果 */
    --shadow-light: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-medium: 0 4px 16px rgba(0, 0, 0, 0.4);
    --shadow-heavy: 0 8px 32px rgba(0, 0, 0, 0.5);
    --shadow-glow: 0 0 20px rgba(100, 255, 218, 0.3);
}

/* 全局背景重置 */
body {
    background: var(--bg-primary) !important;
    color: var(--text-primary) !important;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* 主容器 */
.main-container {
    background: var(--bg-primary) !important;
}

/* 侧边栏主题 */
.sidebar {
    background: var(--bg-secondary) !important;
    border-right: 1px solid var(--border-primary) !important;
    box-shadow: var(--shadow-medium) !important;
}

.logo-section {
    background: var(--bg-tertiary) !important;
    border-bottom: 1px solid var(--border-primary) !important;
}

.logo {
    color: var(--text-primary) !important;
}

.logo i {
    color: var(--text-accent) !important;
}

.category-title {
    color: var(--text-secondary) !important;
    background: var(--bg-tertiary) !important;
    border-bottom: 1px solid var(--border-primary) !important;
}

.category-title i {
    color: var(--text-accent) !important;
}

.tool-item {
    color: var(--text-secondary) !important;
    border-bottom: 1px solid var(--border-primary) !important;
    transition: all 0.3s ease !important;
}

.tool-item:hover {
    background: var(--bg-hover) !important;
    color: var(--text-primary) !important;
    transform: translateX(4px) !important;
}

.tool-item.active {
    background: var(--bg-hover) !important;
    color: var(--text-accent) !important;
    border-left: 3px solid var(--text-accent) !important;
}

.tool-item i {
    color: var(--text-accent) !important;
}

/* 顶部导航主题 */
.top-nav {
    background: var(--bg-secondary) !important;
    border-bottom: 1px solid var(--border-primary) !important;
    box-shadow: var(--shadow-medium) !important;
}

.page-title {
    color: var(--text-primary) !important;
}

.version-tag {
    background: var(--bg-tertiary) !important;
    color: var(--text-accent) !important;
    border: 1px solid var(--border-accent) !important;
}

.breadcrumb {
    color: var(--text-muted) !important;
}

/* 按钮主题 */
.btn-primary {
    background: var(--btn-accent-bg) !important;
    color: var(--bg-primary) !important;
    border: none !important;
    box-shadow: var(--shadow-light) !important;
    transition: all 0.3s ease !important;
}

.btn-primary:hover {
    background: var(--btn-accent-hover) !important;
    box-shadow: var(--shadow-glow) !important;
    transform: translateY(-2px) !important;
}

.btn-secondary {
    background: var(--btn-primary-bg) !important;
    color: var(--text-primary) !important;
    border: 1px solid var(--border-secondary) !important;
    box-shadow: var(--shadow-light) !important;
}

.btn-secondary:hover {
    background: var(--btn-primary-hover) !important;
    border-color: var(--border-accent) !important;
    box-shadow: var(--shadow-medium) !important;
}

/* 工作区主题 */
.workspace {
    background: var(--bg-primary) !important;
}

.image-operation-area {
    background: var(--bg-primary) !important;
}

.image-processing-area {
    background: var(--bg-card) !important;
    border: 1px solid var(--border-primary) !important;
    box-shadow: var(--shadow-medium) !important;
    border-radius: 12px !important;
}

/* 上传区域动态背景 */
.upload-section {
    position: relative !important;
    overflow: hidden !important;
    background: var(--bg-card) !important;
    border-radius: 0 !important;
}

.upload-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, 
        rgba(100, 255, 218, 0.05) 0%, 
        rgba(26, 26, 26, 0.95) 25%, 
        rgba(42, 42, 42, 0.9) 50%, 
        rgba(26, 26, 26, 0.95) 75%, 
        rgba(100, 255, 218, 0.05) 100%);
    background-size: 400% 400%;
    animation: gradientShift 8s ease-in-out infinite;
    z-index: 1;
}

/* 动态图片拼凑背景 */
.upload-section::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(circle at 20% 30%, rgba(100, 255, 218, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(100, 255, 218, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 40% 80%, rgba(100, 255, 218, 0.06) 0%, transparent 50%),
        linear-gradient(135deg, 
            rgba(30, 30, 30, 0.8) 0%, 
            rgba(42, 42, 42, 0.9) 25%, 
            rgba(26, 26, 26, 0.95) 50%, 
            rgba(42, 42, 42, 0.9) 75%, 
            rgba(30, 30, 30, 0.8) 100%);
    /* background-size: 500px 500px, 400px 400px, 350px 350px, 100% 100%; */
    background-size: 300px 300px, 250px 250px, 200px 200px, 100% 100%;
    background-position: 0% 0%, 100% 100%, 50% 50%, 0% 0%;
    animation: 
        floatingImages1 12s linear infinite,
        floatingImages2 15s linear infinite,
        floatingImages3 18s linear infinite;
    z-index: 2;
}

.upload-container {
    position: relative !important;
    z-index: 3 !important;
    background: rgba(26, 26, 26, 0.8) !important;
    backdrop-filter: blur(10px) !important;
    border: 1px solid var(--border-primary) !important;
    border-radius: 12px !important;
    padding: 40px !important;
    margin: 1px !important;
    box-shadow: var(--shadow-heavy) !important;
}

.upload-title {
    color: var(--text-primary) !important;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5) !important;
}

.upload-subtitle {
    color: var(--text-secondary) !important;
}

.upload-icon-wrapper {
    margin-bottom: 20px !important;
}

.upload-main-icon {
    color: var(--text-accent) !important;
    font-size: 48px !important;
    filter: drop-shadow(0 0 10px rgba(100, 255, 218, 0.3)) !important;
}

.feature-item {
    background: var(--bg-tertiary) !important;
    border: 1px solid var(--border-secondary) !important;
    color: var(--text-secondary) !important;
    border-radius: 8px !important;
    padding: 12px 16px !important;
    transition: all 0.3s ease !important;
}

.feature-item:hover {
    background: var(--bg-hover) !important;
    border-color: var(--border-accent) !important;
    color: var(--text-primary) !important;
    transform: translateY(-2px) !important;
    box-shadow: var(--shadow-light) !important;
}

.feature-item i {
    color: var(--text-accent) !important;
}

.btn-upload-primary {
    background: var(--btn-accent-bg) !important;
    color: var(--bg-primary) !important;
    border: none !important;
    padding: 14px 28px !important;
    border-radius: 8px !important;
    font-weight: 600 !important;
    box-shadow: var(--shadow-medium) !important;
    transition: all 0.3s ease !important;
}

.btn-upload-primary:hover {
    background: var(--btn-accent-hover) !important;
    box-shadow: var(--shadow-glow) !important;
    transform: translateY(-2px) !important;
}

.upload-tips {
    color: var(--text-muted) !important;
    font-size: 14px !important;
}

/* 属性面板主题 */
.properties-panel {
    background: var(--bg-secondary) !important;
    border-left: 1px solid var(--border-primary) !important;
    box-shadow: var(--shadow-medium) !important;
}

.panel-section {
    border-bottom: 1px solid var(--border-primary) !important;
}

.panel-title {
    color: var(--text-primary) !important;
}

.control-label {
    color: var(--text-secondary) !important;
}

.form-select {
    background: var(--bg-tertiary) !important;
    color: var(--text-primary) !important;
    border: 1px solid var(--border-secondary) !important;
}

.form-select:focus {
    border-color: var(--border-accent) !important;
    box-shadow: 0 0 0 3px rgba(100, 255, 218, 0.2) !important;
}

/* 滑块控件主题 */
.slider {
    background: var(--bg-tertiary) !important;
}

.slider::-webkit-slider-thumb {
    background: var(--btn-accent-bg) !important;
    box-shadow: var(--shadow-light) !important;
}

.slider::-moz-range-thumb {
    background: var(--btn-accent-bg) !important;
    box-shadow: var(--shadow-light) !important;
}

.slider-value {
    background: var(--bg-tertiary) !important;
    color: var(--text-primary) !important;
    border: 1px solid var(--border-secondary) !important;
}

/* 动画定义 */
@keyframes gradientShift {
    0%, 100% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
}

@keyframes floatingImages1 {
    0% {
        background-position: 0% 0%, 100% 100%, 50% 50%, 0% 0%;
    }
    100% {
        background-position: 100% 100%, 0% 0%, 150% 150%, 0% 0%;
    }
}

@keyframes floatingImages2 {
    0% {
        background-position: 100% 0%, 0% 100%, 25% 75%, 0% 0%;
    }
    100% {
        background-position: 0% 100%, 100% 0%, 125% 175%, 0% 0%;
    }
}

@keyframes floatingImages3 {
    0% {
        background-position: 50% 100%, 150% 50%, 75% 25%, 0% 0%;
    }
    100% {
        background-position: 150% 0%, 50% 150%, 175% 125%, 0% 0%;
    }
}

/* 响应式调整 */
@media (max-width: 768px) {
    .upload-container {
        margin: 10px !important;
        padding: 20px !important;
    }
    
    .upload-main-icon {
        font-size: 36px !important;
    }
}

/* 美颜参数面板主题 */
.beauty-panel {
    background: var(--bg-secondary) !important;
    border: 1px solid var(--border-primary) !important;
    box-shadow: var(--shadow-heavy) !important;
}

.beauty-panel .panel-header {
    background: linear-gradient(135deg, var(--bg-tertiary) 0%, var(--bg-secondary) 100%) !important;
    color: var(--text-primary) !important;
    border-bottom: 1px solid var(--border-primary) !important;
}

.beauty-panel .panel-title {
    color: var(--text-primary) !important;
}

.beauty-panel .panel-title i {
    color: var(--text-accent) !important;
}

.beauty-panel .panel-subtitle {
    color: var(--text-secondary) !important;
}

.beauty-panel .panel-content {
    background: var(--bg-secondary) !important;
}

/* 参数组样式 */
.parameter-group {
    background: var(--bg-tertiary) !important;
    border: 1px solid var(--border-secondary) !important;
}

.group-header {
    border-bottom: 1px solid var(--border-secondary) !important;
}

.group-header i {
    color: var(--text-accent) !important;
}

.group-title {
    color: var(--text-primary) !important;
}

.parameter-label {
    color: var(--text-secondary) !important;
}

.parameter-value {
    background: var(--btn-accent-bg) !important;
    color: var(--bg-primary) !important;
}

/* 美颜滑块样式 */
.beauty-slider {
    background: var(--bg-tertiary) !important;
    border: 1px solid var(--border-secondary) !important;
}

.beauty-slider::-webkit-slider-thumb {
    background: linear-gradient(135deg, var(--btn-accent-bg) 0%, var(--text-accent) 100%) !important;
    box-shadow: 0 2px 8px rgba(100, 255, 218, 0.4) !important;
    border: 2px solid var(--bg-primary) !important;
}

.beauty-slider::-webkit-slider-thumb:hover {
    box-shadow: 0 4px 12px rgba(100, 255, 218, 0.6) !important;
}

.beauty-slider::-moz-range-thumb {
    background: linear-gradient(135deg, var(--btn-accent-bg) 0%, var(--text-accent) 100%) !important;
    box-shadow: 0 2px 8px rgba(100, 255, 218, 0.4) !important;
    border: 2px solid var(--bg-primary) !important;
}

.beauty-slider::-moz-range-thumb:hover {
    box-shadow: 0 4px 12px rgba(100, 255, 218, 0.6) !important;
}

/* 滑块轨道进度效果 */
.beauty-slider::-webkit-slider-track {
    background: var(--bg-tertiary) !important;
    border: 1px solid var(--border-secondary) !important;
    border-radius: 4px !important;
}

.beauty-slider::-moz-range-track {
    background: var(--bg-tertiary) !important;
    border: 1px solid var(--border-secondary) !important;
    border-radius: 4px !important;
}

.parameter-tips {
    color: var(--text-muted) !important;
}

/* 预设方案样式 */
.preset-section {
    background: var(--bg-tertiary) !important;
    border: 1px solid var(--border-secondary) !important;
}

.preset-header {
    border-bottom: 1px solid var(--border-secondary) !important;
}

.preset-header i {
    color: var(--text-accent) !important;
}

.preset-header span {
    color: var(--text-primary) !important;
}

.preset-btn {
    background: var(--bg-secondary) !important;
    border: 1px solid var(--border-secondary) !important;
    color: var(--text-secondary) !important;
}

.preset-btn:hover {
    background: var(--bg-hover) !important;
    border-color: var(--border-accent) !important;
    color: var(--text-primary) !important;
}

.preset-btn.active {
    background: var(--btn-accent-bg) !important;
    border-color: var(--text-accent) !important;
    color: var(--bg-primary) !important;
}

/* 面板操作按钮 */
.panel-actions {
    background: var(--bg-secondary) !important;
    border-top: 1px solid var(--border-primary) !important;
}

.btn-process-beauty {
    background: var(--btn-accent-bg) !important;
    color: var(--bg-primary) !important;
    border: none !important;
    box-shadow: var(--shadow-medium) !important;
}

.btn-process-beauty:hover {
    background: var(--btn-accent-hover) !important;
    box-shadow: var(--shadow-glow) !important;
}

.btn-process-beauty:disabled {
    background: var(--bg-tertiary) !important;
    color: var(--text-muted) !important;
    box-shadow: none !important;
}

/* 滚动条主题 */
::-webkit-scrollbar {
    width: 8px;
    background: var(--bg-secondary);
}

::-webkit-scrollbar-track {
    background: var(--bg-tertiary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: var(--bg-hover);
    border-radius: 4px;
    border: 1px solid var(--border-primary);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-accent);
}

/* 模态框主题 */
.modal-overlay {
    background: rgba(0, 0, 0, 0.8) !important;
    backdrop-filter: blur(10px) !important;
}

.modal, .modal-content {
    background: var(--bg-card) !important;
    border: 1px solid var(--border-primary) !important;
    box-shadow: var(--shadow-heavy) !important;
}

.modal-header {
    background: var(--bg-secondary) !important;
    border-bottom: 1px solid var(--border-primary) !important;
    color: var(--text-primary) !important;
}

.modal-body {
    background: var(--bg-card) !important;
    color: var(--text-primary) !important;
}

/* 表单元素主题 */
.form-input {
    background: var(--bg-tertiary) !important;
    color: var(--text-primary) !important;
    border: 1px solid var(--border-secondary) !important;
}

.form-input:focus {
    border-color: var(--border-accent) !important;
    box-shadow: 0 0 0 3px rgba(100, 255, 218, 0.2) !important;
}

/* 状态栏主题 */
.status-bar {
    background: var(--bg-secondary) !important;
    color: var(--text-secondary) !important;
    border-top: 1px solid var(--border-primary) !important;
}

/* 加载遮罩主题 */
.loading-overlay {
    background: rgba(10, 10, 10, 0.9) !important;
    backdrop-filter: blur(10px) !important;
}

.loading-text {
    color: var(--text-primary) !important;
}

.spinner {
    border-color: var(--bg-tertiary) !important;
    border-top-color: var(--text-accent) !important;
}

/* 图片预览区域主题 */
.image-preview {
    background: var(--bg-card) !important;
}

.image-controls {
    background: rgba(26, 26, 26, 0.9) !important;
    backdrop-filter: blur(10px) !important;
    border: 1px solid var(--border-primary) !important;
}

/* 工具提示主题 */
.tooltip::after {
    background: var(--bg-tertiary) !important;
    color: var(--text-primary) !important;
    border: 1px solid var(--border-primary) !important;
}

/* 通知样式主题 */
.notification-item {
    background: var(--bg-tertiary) !important;
    border-left-color: var(--text-accent) !important;
    color: var(--text-primary) !important;
}

.notification-item.unread {
    background: var(--bg-hover) !important;
    border-left-color: var(--text-accent) !important;
}

/* 高级视觉效果 */
.upload-section {
    position: relative;
}

.upload-section::before {
    animation-duration: 12s;
}

/* 增强的悬停效果 */
.feature-item:hover,
.tool-item:hover,
.btn-primary:hover,
.btn-secondary:hover {
    filter: brightness(1.1) !important;
}

/* 焦点状态 */
*:focus {
    outline: 2px solid var(--text-accent) !important;
    outline-offset: 2px !important;
}

/* 选择状态 */
::selection {
    background: var(--text-accent) !important;
    color: var(--bg-primary) !important;
}