/* 新增：背景生成2.0功能标签样式 */
.feature-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 4px;
}

.feature-new-tag {
    display: inline-block;
    padding: 2px 6px;
    font-size: 10px;
    font-weight: bold;
    color: #2ecc71;
    background-color: rgba(46, 204, 113, 0.2);
    border-radius: 3px;
}

.feature-text-tag {
    display: inline-block;
    padding: 2px 6px;
    font-size: 10px;
    font-weight: bold;
    color: white;
    background-color: #ff6b6b;
    border-radius: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* AI灵魂助手 - 暗色主题 */
.soul-assistant-container {
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

.dark-theme {
    background-color: #121212;
    color: #e0e0e0;
}

.section-title {
    font-size: 16px;
    font-weight: 500;
    margin-bottom: 12px;
    color: #e0e0e0;
}

/* 上传区域样式 */
.upload-area {
    margin-bottom: 30px;
}

.upload-dropzone {
    border: 1px dashed rgba(255, 255, 255, 0.3);
    border-radius: 8px;
    padding: 40px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    background-color: rgba(255, 255, 255, 0.05);
    position: relative;
    min-height: 200px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.upload-dropzone:hover {
    border-color: rgba(255, 255, 255, 0.5);
    background-color: rgba(255, 255, 255, 0.08);
}

.upload-icon {
    margin-bottom: 16px;
    color: rgba(255, 255, 255, 0.7);
}

.upload-text {
    font-size: 16px;
    margin-bottom: 8px;
    color: rgba(255, 255, 255, 0.9);
}

.upload-subtext {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
}

.drag-over {
    border-color: #9f7fff;
    background-color: rgba(159, 127, 255, 0.1);
}

/* 预览容器 */
.preview-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 8px;
    overflow: hidden;
}

.image-preview {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background-color: rgba(0, 0, 0, 0.5);
    padding: 5px;
}

.remove-button {
    position: absolute;
    top: 5px;
    right: 5px;
    width: 24px;
    height: 24px;
    background-color: rgba(0, 0, 0, 0.6);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    transition: background-color 0.3s ease;
}

.remove-button:hover {
    background-color: rgba(0, 0, 0, 0.8);
}

/* 提示词区域 */
.prompt-area {
    margin-bottom: 30px;
}

.prompt-area textarea {
    width: 100%;
    background-color: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: #e0e0e0;
    padding: 12px;
    resize: vertical;
    font-size: 14px;
    min-height: 100px;
}

.prompt-area textarea:focus {
    outline: none;
    border-color: #9f7fff;
    box-shadow: 0 0 0 2px rgba(159, 127, 255, 0.2);
}

.prompt-hint {
    margin-top: 8px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
}

/* 滑块区域 */
.slider-container {
    margin-bottom: 30px;
}

.slider-labels {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.7);
}

.slider-value {
    background-color: rgba(255, 255, 255, 0.1);
    padding: 2px 6px;
    border-radius: 4px;
    color: #9f7fff;
}

.custom-slider {
    -webkit-appearance: none;
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 2px;
    outline: none;
}

.custom-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #9f7fff;
    cursor: pointer;
    border: 2px solid rgba(255, 255, 255, 0.8);
}

.custom-slider::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #9f7fff;
    cursor: pointer;
    border: 2px solid rgba(255, 255, 255, 0.8);
}

/* 选择器样式 */
.aspect-ratio-selector, .quantity-selector {
    margin-bottom: 30px;
}

/* 修改为仅保留quantity-selector */
.quantity-selector {
    margin-bottom: 30px;
}

.custom-select {
    width: 100%;
    background-color: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: #e0e0e0;
    padding: 10px 12px;
    font-size: 14px;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='rgba(255, 255, 255, 0.5)' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 16px;
}

.custom-select:focus {
    outline: none;
    border-color: #9f7fff;
    box-shadow: 0 0 0 2px rgba(159, 127, 255, 0.2);
}

/* 按钮样式 */
.action-buttons {
    margin-bottom: 30px;
    display: flex;
    justify-content: center;
}

.primary-button {
    background-color: #9f7fff;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease;
    width: 100%;
}

.primary-button:hover {
    background-color: #8a68f0;
}

/* 加载状态 */
.loading-status {
    display: none;
    flex-direction: column;
    align-items: center;
    padding: 30px;
    background-color: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    margin-bottom: 30px;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(159, 127, 255, 0.3);
    border-top-color: #9f7fff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 16px;
}

.loading-text {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 结果区域 */
.results-container {
    margin-top: 30px;
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 16px;
    margin-top: 16px;
}

.result-item {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    background-color: rgba(255, 255, 255, 0.05);
}

.result-image-container {
    position: relative;
}

.result-image {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
    transition: transform 0.2s ease;
}

.result-actions {
    position: absolute;
    bottom: 10px;
    left: 10px;
    right: 10px;
    display: flex;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.result-image-container:hover .result-actions {
    opacity: 1;
}

.action-button {
    background-color: rgba(0, 0, 0, 0.7);
    border: none;
    border-radius: 4px;
    color: white;
    padding: 6px 12px;
    font-size: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 4px;
    transition: background-color 0.2s ease;
}

.action-button:hover {
    background-color: rgba(0, 0, 0, 0.9);
}

.download-button svg {
    margin-right: 4px;
}

.no-results {
    grid-column: 1 / -1;
    text-align: center;
    padding: 30px;
    color: rgba(255, 255, 255, 0.6);
    background-color: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .results-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }
}

/* OCR工具样式 */
.ocr-form {
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
}

.ocr-upload-section {
    margin-bottom: 24px;
}

/* 添加水平布局 */
.ocr-horizontal-layout {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
}

.ocr-upload-column {
    flex: 1;
    min-width: 300px;
}

.ocr-options-column {
    flex: 1;
    min-width: 300px;
}

.ocr-preview-container {
    margin-top: 16px;
    width: 100%;
    height: 200px;
    border-radius: 8px;
    overflow: hidden;
    background-color: rgba(0, 0, 0, 0.2);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ocr-preview-image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.ocr-preview-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.6);
    font-size: 14px;
}

.ocr-preview-placeholder svg {
    width: 48px;
    height: 48px;
    margin-bottom: 12px;
    opacity: 0.5;
}

.ocr-upload-type-selector {
    margin-bottom: 16px;
}

.ocr-radio-group {
    display: flex;
    gap: 16px;
}

.ocr-radio {
    display: flex;
    align-items: center;
    cursor: pointer;
}

.ocr-radio input {
    margin-right: 8px;
}

.ocr-radio-text {
    font-size: 14px;
}

.ocr-upload-zone {
    border: 2px dashed rgba(255, 255, 255, 0.3);
    border-radius: 8px;
    padding: 30px;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    background-color: rgba(0, 0, 0, 0.2);
}

.ocr-upload-zone:hover, .ocr-upload-zone.drag-active {
    border-color: #7c3aed;
    background-color: rgba(124, 58, 237, 0.1);
}

.ocr-upload-zone svg {
    width: 48px;
    height: 48px;
    margin-bottom: 16px;
    color: rgba(255, 255, 255, 0.7);
}

.ocr-upload-zone p {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
}

.ocr-upload-label {
    color: #7c3aed;
    cursor: pointer;
    text-decoration: underline;
}

.ocr-file-input {
    display: none;
}

.ocr-file-details {
    margin-top: 16px;
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: 8px;
    padding: 12px;
}

.ocr-file-info {
    display: flex;
    align-items: center;
}

.ocr-file-icon {
    width: 40px;
    height: 40px;
    background-color: rgba(0, 0, 0, 0.3);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
}

.ocr-file-icon svg {
    width: 24px;
    height: 24px;
    color: rgba(255, 255, 255, 0.8);
}

.ocr-file-metadata {
    flex: 1;
}

.ocr-file-name {
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 4px;
    word-break: break-all;
}

.ocr-file-meta {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
}

.ocr-upload-url-section {
    margin-top: 16px;
}

.ocr-url-input-wrapper {
    position: relative;
}

.ocr-url-input {
    width: 100%;
    padding: 12px 40px 12px 12px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    background-color: rgba(0, 0, 0, 0.2);
    color: #fff;
    font-size: 14px;
    transition: all 0.3s ease;
}

.ocr-url-input:focus {
    border-color: #7c3aed;
    outline: none;
}

.ocr-url-input-icon {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(255, 255, 255, 0.5);
}

.ocr-options-section {
    margin-bottom: 24px;
}

.ocr-options-title {
    font-size: 16px;
    margin-bottom: 16px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.9);
}

.ocr-options-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

.ocr-option {
    margin-bottom: 16px;
}

.ocr-option-label {
    display: block;
    font-size: 14px;
    margin-bottom: 8px;
    color: rgba(255, 255, 255, 0.7);
}

.ocr-select, .ocr-password-input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    background-color: rgba(0, 0, 0, 0.2);
    color: #fff;
    font-size: 14px;
    transition: all 0.3s ease;
}

.ocr-select:focus, .ocr-password-input:focus {
    border-color: #7c3aed;
    outline: none;
}

.ocr-button-container {
    margin-top: 24px;
    text-align: center;
}

.ocr-submit-button {
    background-color: #7c3aed;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    position: relative;
}

.ocr-submit-button:hover {
    background-color: #6d28d9;
    transform: translateY(-1px);
}

.ocr-btn-icon {
    display: flex;
    align-items: center;
}

.ocr-loading-spinner {
    display: none;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: ocr-spin 1s linear infinite;
    margin-left: 8px;
}

.ocr-submit-button.loading .ocr-loading-spinner {
    display: block;
}

.ocr-submit-button.loading .ocr-btn-icon {
    display: none;
}

@keyframes ocr-spin {
    to { transform: rotate(360deg); }
}

.ocr-progress-section {
    margin-top: 32px;
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: 8px;
    padding: 16px;
}

.ocr-progress-title {
    font-size: 16px;
    margin-bottom: 16px;
    font-weight: 500;
}

.ocr-progress-bar-container {
    height: 8px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 8px;
}

.ocr-progress-bar {
    height: 100%;
    background-color: #7c3aed;
    border-radius: 4px;
    transition: width 0.3s ease;
}

.ocr-progress-info {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.7);
}

.ocr-inline-progress {
    opacity: 0;
    height: 0;
    overflow: hidden;
    margin-top: 16px;
    transition: opacity 0.3s ease, height 0.3s ease;
}

.ocr-inline-progress.active {
    opacity: 1;
    height: auto;
}

.ocr-inline-progress-status {
    font-size: 14px;
    margin-bottom: 8px;
    color: rgba(255, 255, 255, 0.8);
}

.ocr-inline-progress-bar-container {
    height: 6px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 6px;
}

.ocr-inline-progress-bar {
    height: 100%;
    background-color: #7c3aed;
    border-radius: 3px;
    transition: width 0.3s ease;
}

.ocr-inline-progress-text {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.7);
    text-align: right;
}

.ocr-result-section {
    margin-top: 32px;
}

.ocr-result-title {
    font-size: 16px;
    margin-bottom: 16px;
    font-weight: 500;
}

.ocr-result-card {
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: 8px;
    padding: 16px;
    display: flex;
    align-items: center;
}

.ocr-result-icon {
    width: 48px;
    height: 48px;
    background-color: rgba(124, 58, 237, 0.2);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 16px;
}

.ocr-result-icon svg {
    width: 24px;
    height: 24px;
    color: #7c3aed;
}

.ocr-result-info {
    flex: 1;
}

.ocr-result-link {
    color: #7c3aed;
    font-size: 14px;
    text-decoration: none;
    display: block;
    margin-bottom: 4px;
    word-break: break-all;
}

.ocr-result-link:hover {
    text-decoration: underline;
}

.ocr-result-time {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
}

.ocr-result-actions {
    display: flex;
    gap: 8px;
}

.ocr-action-button {
    background-color: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    padding: 8px 12px;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.9);
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.ocr-action-button:hover {
    background-color: rgba(0, 0, 0, 0.4);
    border-color: rgba(255, 255, 255, 0.2);
}

.ocr-action-button svg {
    width: 14px;
    height: 14px;
}

.ocr-download-btn:hover {
    color: #7c3aed;
}

.ocr-save-btn:hover {
    color: #10b981;
}

.ocr-alert {
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
}

.alert-success {
    background-color: rgba(16, 185, 129, 0.2);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: rgba(16, 185, 129, 0.9);
}

.alert-danger {
    background-color: rgba(239, 68, 68, 0.2);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: rgba(239, 68, 68, 0.9);
}

.alert-info {
    background-color: rgba(59, 130, 246, 0.2);
    border: 1px solid rgba(59, 130, 246, 0.3);
    color: rgba(59, 130, 246, 0.9);
}

.ocr-completion-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.ocr-completion-overlay.show {
    opacity: 1;
    visibility: visible;
}

.ocr-completion-content {
    text-align: center;
}

.ocr-completion-icon {
    width: 80px;
    height: 80px;
    background-color: rgba(16, 185, 129, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
}

.ocr-completion-icon svg {
    color: #10b981;
}

.ocr-completion-text {
    font-size: 24px;
    font-weight: 600;
    color: #fff;
}

/* 响应式样式 */
@media (max-width: 768px) {
    .ocr-options-grid {
        grid-template-columns: 1fr;
    }
    
    .ocr-result-card {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .ocr-result-icon {
        margin-right: 0;
        margin-bottom: 16px;
    }
    
    .ocr-result-actions {
        margin-top: 16px;
        width: 100%;
    }
    
    .ocr-action-button {
        flex: 1;
        justify-content: center;
    }
} 