/**
 * ImageStampModal CSS - 이미지 스탬프 업로드 모달 스타일
 */

/* === 모달 오버레이 === */
.image-stamp-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10001; /* PixelEditor3보다 위에 */
    display: flex;
    align-items: center;
    justify-content: center;
}

.image-stamp-modal.hidden {
    display: none;
}

.image-stamp-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
}

/* === 메인 콘텐츠 === */
.image-stamp-modal-content {
    position: relative;
    width: 95%;
    max-width: 1400px;
    height: 90vh;
    max-height: 800px;
    background: #1a1a2e;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 2px solid rgba(78, 205, 196, 0.3);
}

/* === 헤더 === */
.image-stamp-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    background: linear-gradient(135deg, rgba(78, 205, 196, 0.1), rgba(78, 205, 196, 0.05));
    border-bottom: 1px solid rgba(78, 205, 196, 0.2);
}

.image-stamp-modal-header h2 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: #4ecdc4;
}

.image-stamp-modal-actions {
    display: flex;
    gap: 12px;
    align-items: center;
}

.image-stamp-btn {
    padding: 8px 16px;
    background: rgba(78, 205, 196, 0.1);
    border: 1px solid rgba(78, 205, 196, 0.3);
    border-radius: 8px;
    color: #fff;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 6px;
}

.image-stamp-btn:hover {
    background: rgba(78, 205, 196, 0.2);
    border-color: rgba(78, 205, 196, 0.5);
}

.image-stamp-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.image-stamp-btn-primary {
    background: rgba(78, 205, 196, 0.2);
    border-color: rgba(78, 205, 196, 0.5);
}

.image-stamp-btn-primary:hover:not(:disabled) {
    background: rgba(78, 205, 196, 0.3);
    border-color: #4ecdc4;
}

.image-stamp-close {
    width: 32px;
    height: 32px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 8px;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.image-stamp-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* === 본문 === */
.image-stamp-modal-body {
    flex: 1;
    display: flex;
    gap: 24px;
    padding: 24px;
    overflow: hidden;
}

/* === Stage (좌측) === */
.image-stamp-stage-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.image-stamp-stage {
    position: relative;
    background: #0a0a0a;
    border: 2px solid rgba(78, 205, 196, 0.3);
    border-radius: 8px;
    overflow: hidden;
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

#image-stamp-static-canvas,
#image-stamp-dynamic-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    cursor: move;
}

#image-stamp-dynamic-canvas {
    cursor: move;
}

.image-stamp-zoom-controls {
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: center;
    padding: 8px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 8px;
}

.image-stamp-zoom-btn {
    width: 32px;
    height: 32px;
    background: rgba(78, 205, 196, 0.1);
    border: 1px solid rgba(78, 205, 196, 0.3);
    border-radius: 6px;
    color: #fff;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.image-stamp-zoom-btn:hover {
    background: rgba(78, 205, 196, 0.2);
    border-color: rgba(78, 205, 196, 0.5);
}

.image-stamp-zoom-value {
    min-width: 60px;
    text-align: center;
    color: #fff;
    font-size: 14px;
    font-weight: 500;
}

/* === Tool Panel (우측) === */
.image-stamp-tool-panel {
    width: 300px;
    display: flex;
    flex-direction: column;
    gap: 24px;
    overflow-y: auto;
    padding-right: 8px;
}

.image-stamp-section {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.image-stamp-section h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: #fff;
    border-bottom: 1px solid rgba(78, 205, 196, 0.2);
    padding-bottom: 8px;
}

/* === 파일 업로드 === */
.image-stamp-section input[type="file"] {
    display: none;
}

/* === 투명도 프리셋 === */
.image-stamp-presets {
    display: flex;
    gap: 8px;
}

.image-stamp-preset-btn {
    flex: 1;
    padding: 8px;
    background: rgba(78, 205, 196, 0.1);
    border: 1px solid rgba(78, 205, 196, 0.3);
    border-radius: 6px;
    color: #fff;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.image-stamp-preset-btn:hover {
    background: rgba(78, 205, 196, 0.2);
    border-color: rgba(78, 205, 196, 0.5);
}

/* === 슬라이더 === */
.image-stamp-section input[type="range"] {
    width: 100%;
    height: 4px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 2px;
    appearance: none;
    cursor: pointer;
}

.image-stamp-section input[type="range"]::-webkit-slider-thumb {
    appearance: none;
    width: 16px;
    height: 16px;
    background: #4ecdc4;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.image-stamp-section input[type="range"]::-moz-range-thumb {
    width: 16px;
    height: 16px;
    background: #4ecdc4;
    border-radius: 50%;
    cursor: pointer;
    border: none;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* === 체크박스 === */
.image-stamp-section label {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #fff;
    font-size: 14px;
    cursor: pointer;
}

.image-stamp-section input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

/* === 스크롤바 스타일 === */
.image-stamp-tool-panel::-webkit-scrollbar {
    width: 8px;
}

.image-stamp-tool-panel::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 4px;
}

.image-stamp-tool-panel::-webkit-scrollbar-thumb {
    background: rgba(78, 205, 196, 0.3);
    border-radius: 4px;
}

.image-stamp-tool-panel::-webkit-scrollbar-thumb:hover {
    background: rgba(78, 205, 196, 0.5);
}

