/* public/assets/css/tools/image/watermark-camera.css */

.wmc-wrapper {
    padding: 32px;
}

.wmc-header {
    text-align: center;
    margin-bottom: 32px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border-color);
}

.wmc-title {
    margin: 0 0 10px 0;
    font-size: 1.6rem;
    color: var(--text-main);
}

.wmc-subtitle {
    margin: 0;
    color: var(--text-muted);
    font-size: 1rem;
}

.wmc-container {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
}

/* 左侧控制区 */
.wmc-controls {
    flex: 1;
    min-width: 300px;
    background: var(--bg-body);
    padding: 24px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
}

.wmc-form-group {
    margin-bottom: 20px;
}

.wmc-form-group label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-main);
}

.wmc-file-upload {
    position: relative;
    width: 100%;
    height: 120px;
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-md);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: var(--bg-surface);
    cursor: pointer;
    transition: var(--transition);
}

.wmc-file-upload:hover {
    border-color: var(--primary-color);
    background: rgba(0, 102, 204, 0.05);
}

.wmc-file-upload input[type="file"] {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.wmc-upload-icon {
    font-size: 28px;
    margin-bottom: 8px;
}

.wmc-upload-text {
    font-size: 0.9rem;
    color: var(--text-muted);
    pointer-events: none;
}

.wmc-file-name {
    font-size: 0.85rem;
    color: var(--primary-color);
    margin-top: 8px;
    font-weight: 600;
    display: none;
    word-break: break-all;
    text-align: center;
    padding: 0 10px;
}

.wmc-input {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-sizing: border-box;
    font-size: 0.95rem;
    background: var(--bg-surface);
    color: var(--text-main);
    transition: 0.2s ease;
}

.wmc-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

/* iOS 风格分段控制器 */
.wmc-segmented {
    display: flex;
    background: var(--border-color);
    padding: 4px;
    border-radius: var(--radius-md);
}

.wmc-segmented label {
    flex: 1;
    margin: 0;
    cursor: pointer;
    position: relative;
}

.wmc-segmented input {
    display: none;
}

.wmc-segmented span {
    display: block;
    text-align: center;
    padding: 8px 0;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-muted);
    border-radius: 6px;
    transition: 0.2s ease;
    z-index: 2;
    position: relative;
}

.wmc-segmented input:checked + span {
    background: var(--bg-surface);
    color: var(--primary-color);
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
    font-weight: bold;
}

.wmc-btn-primary {
    width: 100%;
    padding: 14px;
    background: var(--primary-color);
    color: #fff;
    border: none;
    border-radius: var(--radius-md);
    font-size: 1.05rem;
    font-weight: bold;
    cursor: pointer;
    margin-top: 10px;
    transition: 0.2s;
    display: none;
}

.wmc-btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0, 102, 204, 0.3);
}

/* 右侧预览区 */
.wmc-preview {
    flex: 1.5;
    min-width: 300px;
    background: var(--bg-body);
    padding: 24px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.wmc-canvas-container {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    background: var(--bg-surface);
    border-radius: var(--radius-md);
    overflow: hidden;
    position: relative;
    min-height: 400px;
    border: 1px dashed var(--border-color);
}

#wmcCanvas {
    max-width: 100%;
    max-height: 65vh;
    object-fit: contain;
    display: block;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

.wmc-empty-state {
    position: absolute;
    text-align: center;
    color: var(--text-muted);
    pointer-events: none;
}

.wmc-empty-state svg {
    width: 64px;
    height: 64px;
    fill: var(--border-color);
    margin-bottom: 12px;
}

/* 响应式适配 */
@media (max-width: 768px) {
    .wmc-container { flex-direction: column; }
    .wmc-preview { order: -1; padding: 16px; } /* 手机端优先展示画布 */
    .wmc-controls { padding: 16px; }
    .wmc-wrapper { padding: 16px; }
}