/* ─── 공통 ─── */
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: 'Segoe UI', 'Noto Sans KR', sans-serif; background: #0f0f1a; color: #e0e0e0; min-height: 100vh; }
a { color: #7eb8ff; text-decoration: none; }
a:hover { text-decoration: underline; }

/* ─── 헤더 ─── */
.header { background: #1a1a2e; border-bottom: 1px solid #2a2a40; padding: 16px 0; }
.header-inner { max-width: 1200px; margin: 0 auto; padding: 0 20px; display: flex; align-items: center; justify-content: space-between; }
.logo { font-size: 22px; font-weight: 700; color: #7eb8ff; }
.logo span { color: #ff7eb8; }
.nav { display: flex; gap: 18px; flex-wrap: wrap; }
.nav a { color: #aaa; font-size: 14px; transition: color .2s; }
.nav a:hover, .nav a.active { color: #fff; text-decoration: none; }

/* ─── 메인 ─── */
.container { max-width: 1200px; margin: 0 auto; padding: 40px 20px; }
.hero { text-align: center; padding: 60px 0 40px; }
.hero h1 { font-size: 42px; margin-bottom: 12px; }
.hero h1 span { color: #7eb8ff; }
.hero p { color: #888; font-size: 18px; margin-bottom: 40px; }

/* ─── 도구 카드 ─── */
.tools-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; }
.tool-card { background: #1a1a2e; border: 1px solid #2a2a40; border-radius: 16px; padding: 32px 24px;
  text-align: center; transition: transform .2s, border-color .2s; cursor: pointer; }
.tool-card:hover { transform: translateY(-4px); border-color: #7eb8ff; }
.tool-icon { font-size: 48px; margin-bottom: 16px; }
.tool-card h3 { font-size: 20px; margin-bottom: 8px; color: #fff; }
.tool-card p { color: #888; font-size: 14px; line-height: 1.6; }

/* ─── 도구 페이지 공통 ─── */
.tool-page { max-width: 900px; margin: 0 auto; padding: 40px 20px; }
.tool-page h1 { font-size: 28px; margin-bottom: 8px; }
.tool-page .desc { color: #888; margin-bottom: 30px; }

/* 드롭존 */
.dropzone { border: 2px dashed #3a3a50; border-radius: 16px; padding: 60px 20px; text-align: center;
  cursor: pointer; transition: border-color .2s, background .2s; margin-bottom: 24px; }
.dropzone:hover, .dropzone.dragover { border-color: #7eb8ff; background: rgba(126,184,255,.05); }
.dropzone-icon { font-size: 48px; margin-bottom: 12px; }
.dropzone p { color: #888; }
.dropzone input { display: none; }

/* 옵션 */
.options { background: #1a1a2e; border-radius: 12px; padding: 20px 24px; margin-bottom: 24px;
  display: flex; gap: 20px; flex-wrap: wrap; align-items: center; }
.options label { color: #aaa; font-size: 14px; }
.options input, .options select { background: #2a2a40; border: 1px solid #3a3a50; color: #fff;
  padding: 8px 12px; border-radius: 8px; font-size: 14px; }
.options input[type="range"] { accent-color: #7eb8ff; }

/* 버튼 */
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 12px 28px; border: none;
  border-radius: 10px; font-size: 16px; font-weight: 600; cursor: pointer; transition: background .2s; }
.btn-primary { background: #7eb8ff; color: #0f0f1a; }
.btn-primary:hover { background: #5a9eff; }
.btn-danger { background: #ff5c5c; color: #fff; }
.btn-danger:hover { background: #e04444; }
.btn-success { background: #5cdb95; color: #0f0f1a; }
.btn-success:hover { background: #44c47d; }
.btn:disabled { opacity: .4; cursor: not-allowed; }
.btn-group { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 24px; }

/* 미리보기 */
.preview-area { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 24px; }
.preview-item { position: relative; background: #1a1a2e; border-radius: 10px; padding: 8px;
  border: 1px solid #2a2a40; }
.preview-item img { max-width: 180px; max-height: 140px; border-radius: 6px; display: block; }
.preview-item .info { font-size: 11px; color: #888; margin-top: 4px; text-align: center; }
.preview-item .remove { position: absolute; top: 4px; right: 4px; background: #ff5c5c; color: #fff;
  border: none; border-radius: 50%; width: 22px; height: 22px; cursor: pointer; font-size: 12px; line-height: 22px; }

/* 결과 */
.result-area { background: #1a1a2e; border-radius: 12px; padding: 24px; border: 1px solid #2a2a40; }
.result-item { display: flex; align-items: center; gap: 16px; padding: 12px 0;
  border-bottom: 1px solid #2a2a40; }
.result-item:last-child { border-bottom: none; }
.result-item img { width: 80px; height: 60px; object-fit: cover; border-radius: 6px; }
.result-info { flex: 1; }
.result-info .name { font-size: 14px; color: #fff; }
.result-info .meta { font-size: 12px; color: #888; }
.result-actions { display: flex; gap: 8px; }
.btn-sm { padding: 6px 14px; font-size: 13px; border-radius: 8px; }

/* 중복 그룹 */
.dup-group { background: #1a1a2e; border-radius: 12px; padding: 16px; margin-bottom: 16px;
  border: 1px solid #2a2a40; }
.dup-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.dup-header h3 { font-size: 16px; color: #7eb8ff; }
.dup-images { display: flex; gap: 10px; flex-wrap: wrap; }
.dup-card { background: #2a2a40; border-radius: 10px; padding: 8px; text-align: center; position: relative; }
.dup-card img { width: 150px; height: 110px; object-fit: cover; border-radius: 6px; }
.dup-card .badge { display: inline-block; margin-top: 6px; padding: 2px 10px; border-radius: 10px;
  font-size: 11px; font-weight: 600; }
.badge-keep { background: #5cdb95; color: #0f0f1a; }
.badge-dup { background: #ff5c5c; color: #fff; }
.dup-card .sim { font-size: 11px; color: #888; margin-top: 4px; }

/* 프로그레스 */
.progress-bar { width: 100%; height: 6px; background: #2a2a40; border-radius: 3px; overflow: hidden; margin: 16px 0; }
.progress-fill { height: 100%; background: #7eb8ff; border-radius: 3px; transition: width .3s; width: 0%; }
.status-text { font-size: 13px; color: #888; }

/* 워터마크 옵션 */
.wm-options { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.wm-options label { display: block; color: #aaa; font-size: 13px; margin-bottom: 4px; }
.wm-options input, .wm-options select { width: 100%; }

/* 푸터 */
.footer { text-align: center; padding: 40px 20px; color: #555; font-size: 13px; border-top: 1px solid #1a1a2e; }

/* 광고 영역 */
.ad-space { background: #1a1a2e; border: 1px dashed #2a2a40; border-radius: 12px; padding: 20px;
  text-align: center; color: #444; font-size: 13px; margin: 24px 0; min-height: 90px;
  display: flex; align-items: center; justify-content: center; }

/* 반응형 */
@media (max-width: 768px) {
  .hero h1 { font-size: 28px; }
  .tools-grid { grid-template-columns: 1fr; }
  .header-inner { flex-direction: column; gap: 12px; }
  .wm-options { grid-template-columns: 1fr; }
  .options { flex-direction: column; }
}
