/* ===========================================
   Watermark Module Styles
   =========================================== */

/* --- Upload Area --- */
#wm-upload-area {
  margin: 8px 12px;
  padding: 16px 8px;
  border: 1px dashed #2A2A2A;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.2s;
  text-align: center;
}
#wm-upload-area:hover {
  border-color: #3A3A3A;
  background: rgba(255,255,255,0.01);
}
#wm-upload-area span {
  font-size: 11px;
  color: #666;
}
#wm-upload-area input[type="file"] {
  display: none;
}

/* --- Image List --- */
#wm-image-list {
  flex: 1;
  overflow-y: auto;
  padding: 0 8px;
}
#wm-image-list .image-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.15s;
  border: 1px solid transparent;
}
#wm-image-list .image-item:hover {
  background: rgba(255,255,255,0.03);
}
#wm-image-list .image-item.active {
  border-color: #00D4FF;
  background: rgba(0,212,255,0.05);
}
#wm-image-list .image-item.selected {
  background: rgba(0,212,255,0.03);
}
#wm-image-list .image-item .thumb {
  width: 48px;
  height: 48px;
  border-radius: 4px;
  overflow: hidden;
  flex-shrink: 0;
  background: #1a1a1a;
}
#wm-image-list .image-item .thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
#wm-image-list .image-item .info {
  flex: 1;
  min-width: 0;
}
#wm-image-list .image-item .name {
  font-size: 11px;
  color: #aaa;
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
#wm-image-list .image-item {
  position: relative;
}
#wm-image-list .image-item .delete-btn {
  position: absolute;
  top: -4px;
  right: -4px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #FF4444;
  border: 1.5px solid #1A1A1A;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.2s, transform 0.15s;
  z-index: 2;
  padding: 0;
}
#wm-image-list .image-item .delete-btn:hover {
  transform: scale(1.1);
  background: #FF6666;
}
#wm-image-list .image-item:hover .delete-btn {
  opacity: 1;
}

/* --- Preview Area --- */
#wm-preview-area {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
#wm-empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  color: #555;
}
#wm-empty-state p {
  font-size: 13px;
  color: #666;
}

/* --- Function Tabs --- */
#wm-func-tabs {
  display: flex;
  gap: 4px;
  padding: 0 12px;
  margin-bottom: 8px;
}
#wm-func-tabs .tab {
  flex: 1;
  text-align: center;
  padding: 6px 0;
  font-size: 11px;
  color: #888;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.15s;
  background: rgba(255,255,255,0.03);
}
#wm-func-tabs .tab.active {
  color: #00D4FF;
  background: rgba(0,212,255,0.1);
}

/* --- Type Tabs --- */
#wm-type-tabs {
  display: flex;
  gap: 4px;
}
#wm-type-tabs .tab {
  flex: 1;
  text-align: center;
  padding: 5px 0;
  font-size: 11px;
  color: #888;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.15s;
  background: rgba(255,255,255,0.03);
}
#wm-type-tabs .tab.active {
  color: #00D4FF;
  background: rgba(0,212,255,0.1);
}

/* --- Layout Tabs --- */
#wm-layout-tabs {
  display: flex;
  gap: 4px;
}
#wm-layout-tabs .tab {
  flex: 1;
  text-align: center;
  padding: 5px 0;
  font-size: 11px;
  color: #888;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.15s;
  background: rgba(255,255,255,0.03);
}
#wm-layout-tabs .tab.active {
  color: #00D4FF;
  background: rgba(0,212,255,0.1);
}

/* --- Position Grid (九宫格) --- */
#wm-position-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  max-width: 140px;
}
#wm-position-grid .pos-cell {
  width: 40px;
  height: 28px;
  border: 1px solid #333;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.15s;
  background: rgba(255,255,255,0.02);
}
#wm-position-grid .pos-cell:hover {
  border-color: #555;
  background: rgba(255,255,255,0.05);
}
#wm-position-grid .pos-cell.active {
  border-color: #00D4FF;
  background: rgba(0,212,255,0.15);
}

/* --- Watermark Image Upload --- */
#wm-watermark-upload {
  padding: 12px 8px;
  border: 1px dashed #2A2A2A;
  border-radius: 6px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
}
#wm-watermark-upload:hover {
  border-color: #3A3A3A;
  background: rgba(255,255,255,0.01);
}
#wm-watermark-upload span {
  font-size: 11px;
  color: #666;
}
#wm-watermark-upload input[type="file"] {
  display: none;
}

/* --- Region List (去除水印选区) --- */
#wm-region-list {
  max-height: 120px;
  overflow-y: auto;
}
#wm-region-hint {
  font-size: 11px;
  color: #666;
  margin: 4px 0;
}

/* --- Progress Bar --- */
#wm-progress-bar {
  height: 4px;
  background: #1a1a1a;
  border-radius: 2px;
  overflow: hidden;
  margin: 8px 0 4px;
}
#wm-progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #00D4FF, #0099CC);
  border-radius: 2px;
  transition: width 0.3s;
}
#wm-progress-text {
  font-size: 11px;
  color: #888;
  text-align: center;
}
