/* ============================================================
   WATERMARK TOOL - Page Specific Styles
   Only styles unique to watermark page (shared styles in global.css)
   ============================================================ */

/* Page Header - Watermark specific eyebrow styling */
.page-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: .72rem;
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-light);
  border: 1px solid var(--accent-muted);
  padding: 4px 12px;
  border-radius: 100px;
  margin-bottom: 12px;
}

.page-header h1 {
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -.02em;
  margin-bottom: 8px;
}

.page-header p {
  font-size: .9rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 28px;
}

/* DROPZONE */
.dropzone {
  background: var(--bg-dropzone);
  border: 2px dashed var(--border);
  border-radius: var(--radius-xl);
  padding: 48px 24px;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  position: relative;
}

.dropzone.drag-over {
  border-color: var(--accent);
  background: var(--accent-light);
  box-shadow: 0 0 0 4px var(--accent-muted);
}

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

.dropzone-icon {
  width: 64px;
  height: 64px;
  background: var(--accent-light);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
  border: 1px solid var(--accent-muted);
}

.dropzone-icon i {
  font-size: 28px;
  color: var(--accent);
}

.dropzone-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.dropzone-sub {
  font-size: .85rem;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.upload-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: var(--bg-card);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-md);
  font-size: .9rem;
  font-weight: 500;
  color: var(--text-primary);
  transition: var(--transition);
}

.upload-btn:hover {
  border-color: var(--accent);
  background: var(--accent-light);
}

.upload-btn i {
  font-size: 16px;
  color: var(--accent);
}

/* FILE CARD */
.file-card {
  background: var(--bg-card);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px 18px;
  display: none;
  align-items: center;
  gap: 14px;
  margin-top: 18px;
  box-shadow: var(--shadow-sm);
}

.file-card.visible {
  display: flex;
}

.fc-icon {
  width: 42px;
  height: 42px;
  background: var(--accent-light);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--accent-muted);
  flex-shrink: 0;
}

.fc-icon i {
  font-size: 20px;
  color: var(--accent);
}

.fc-meta {
  flex: 1;
  min-width: 0;
}

.fc-name {
  font-size: .88rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 2px;
}

.fc-info {
  font-size: .75rem;
  color: var(--text-muted);
}

.fc-remove {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1.5px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: var(--transition);
  flex-shrink: 0;
}

.fc-remove:hover {
  border-color: var(--error);
  color: var(--error);
  background: var(--error-light);
}

.fc-remove i {
  font-size: 13px;
}

/* SECTION CARD - Options panel */
.section-card {
  background: var(--bg-card);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px 20px;
  margin-top: 14px;
  box-shadow: var(--shadow-sm);
  display: none;
}

.section-card.visible {
  display: block;
}

.section-title {
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--text-secondary);
  margin-bottom: 16px;
}

/* OPTION SECTIONS - Grouped layout */
.opt-section {
  margin-bottom: 24px;
}

.opt-section:last-of-type {
  margin-bottom: 0;
}

.opt-section-title {
  font-size: .65rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 12px;
  padding-left: 2px;
}

/* OPTION ROW - Base styles */
.opt-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}

.opt-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.opt-row:first-child {
  padding-top: 0;
}

/* COMPACT ROW - For color, size, rotation */
.opt-row.compact {
  padding: 8px 0;
  min-height: 44px;
}

/* SLIDER ROW - Full width slider */
.opt-row.slider-row {
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
  padding: 10px 0;
}

.slider-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.opt-label-group {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.opt-label {
  font-size: .85rem;
  font-weight: 500;
  color: var(--text-primary);
}

.opt-sub {
  font-size: .7rem;
  color: var(--text-muted);
  line-height: 1.3;
}

/* TYPE TABS - Unique to watermark */
.type-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
}

.type-tab {
  flex: 1;
  padding: 10px 16px;
  border-radius: var(--radius-md);
  border: 2px solid var(--border);
  background: var(--bg-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: .85rem;
  font-weight: 600;
  color: var(--text-secondary);
  transition: var(--transition);
  cursor: pointer;
}

.type-tab:hover {
  border-color: var(--border-hover);
}

.type-tab.active {
  border-color: var(--accent);
  background: var(--accent-light);
  color: var(--accent);
}

/* TEXT INPUT - Watermark specific */
.text-input-wrap {
  margin-bottom: 16px;
}

.text-input-label {
  font-size: .78rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 6px;
  display: block;
}

.wm-text-input {
  width: 100%;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  border: 1.5px solid var(--border);
  background: var(--bg-secondary);
  color: var(--text-primary);
  font-size: 1rem;
  font-weight: 600;
  outline: none;
  transition: var(--transition);
  letter-spacing: .02em;
}

.wm-text-input:focus {
  border-color: var(--accent);
}

.wm-text-input::placeholder {
  color: var(--text-muted);
  font-weight: 400;
}

/* QUICK PRESETS */
.preset-row {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.preset-chip {
  padding: 5px 12px;
  border-radius: 100px;
  border: 1.5px solid var(--border);
  font-size: .78rem;
  font-weight: 500;
  color: var(--text-secondary);
  background: var(--bg-secondary);
  transition: var(--transition);
  cursor: pointer;
}

.preset-chip:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-light);
}

/* IMAGE DROPZONE - Watermark specific for logo upload */
.img-dropzone {
  border: 2px dashed var(--border);
  border-radius: var(--radius-md);
  padding: 28px 16px;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  position: relative;
  margin-bottom: 16px;
  display: none;
}

.img-dropzone.visible {
  display: block;
}

.img-dropzone.drag-over {
  border-color: var(--accent);
  background: var(--accent-light);
}

.img-dropzone input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  width: 100%;
  height: 100%;
}

.img-dropzone p {
  font-size: .85rem;
  color: var(--text-muted);
}

.img-dropzone strong {
  display: block;
  font-size: .9rem;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.img-preview-wrap {
  display: none;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.img-preview-wrap.visible {
  display: flex;
}

.img-thumb {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-sm);
  object-fit: contain;
  border: 1.5px solid var(--border);
  background: var(--bg-secondary);
}

.img-preview-info {
  flex: 1;
}

.img-preview-name {
  font-size: .85rem;
  font-weight: 600;
  margin-bottom: 2px;
}

.img-preview-size {
  font-size: .75rem;
  color: var(--text-muted);
}

.img-remove {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1.5px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: var(--transition);
  flex-shrink: 0;
}

.img-remove:hover {
  border-color: var(--error);
  color: var(--error);
  background: var(--error-light);
}

/* PILL GROUPS */
.pill-group {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.pill {
  padding: 6px 14px;
  border-radius: 100px;
  border: 1.5px solid var(--border);
  font-size: .8rem;
  font-weight: 500;
  color: var(--text-secondary);
  background: var(--bg-secondary);
  transition: var(--transition);
  cursor: pointer;
}

.pill:hover {
  border-color: var(--border-hover);
}

.pill.active {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-light);
}

/* RANGE SLIDER WITH VALUE */
.range-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.range-val {
  font-size: .82rem;
  font-weight: 600;
  color: var(--accent);
  min-width: 36px;
  text-align: right;
  flex-shrink: 0;
}

/* LAYER TOGGLE - Unique to watermark */
.layer-group {
  display: flex;
  gap: 8px;
}

.layer-btn {
  flex: 1;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--border);
  background: var(--bg-secondary);
  font-size: .8rem;
  font-weight: 500;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: var(--transition);
  cursor: pointer;
}

.layer-btn:hover {
  border-color: var(--border-hover);
}

.layer-btn.active {
  border-color: var(--accent);
  background: var(--accent-light);
  color: var(--accent);
}

/* LIVE PREVIEW - Page mock with watermark overlay */
.preview-wrap {
  margin-top: 18px;
}

.preview-label {
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 10px;
}

.page-mock {
  width: 100%;
  max-width: 260px;
  aspect-ratio: 3/4;
  background: #fff;
  border-radius: 6px;
  box-shadow: var(--shadow-md);
  margin: 0 auto;
  position: relative;
  border: 1px solid var(--border);
  overflow: hidden;
}

[data-theme="dark"] .page-mock {
  background: #2a2724;
}

.page-mock-lines {
  position: absolute;
  inset: 14px;
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.mock-line {
  height: 5px;
  background: var(--border);
  border-radius: 3px;
}

.mock-line.s60 {
  width: 60%;
}

.mock-line.s80 {
  width: 80%;
}

.mock-line.s70 {
  width: 70%;
}

/* Watermark preview layer */
.wm-preview-layer {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.wm-preview-text {
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
  white-space: nowrap;
  transition: all .25s ease;
  font-family: var(--font-body);
}

.wm-preview-img {
  max-width: 60%;
  max-height: 60%;
  object-fit: contain;
  transition: all .25s ease;
  display: none;
}

/* BOTTOM BAR */
.bottom-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 90;
  background: var(--bg-primary);
  border-top: 1px solid var(--border);
  padding: 12px 20px;
  display: none;
  backdrop-filter: blur(16px);
}

.bottom-bar.visible {
  display: block;
}

.bottom-bar-inner {
  max-width: 720px;
  margin: 0 auto;
}

.process-btn {
  width: 100%;
  height: 52px;
  background: var(--accent);
  color: #fff;
  border-radius: var(--radius-md);
  font-size: .95rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: var(--transition);
  box-shadow: 0 4px 16px rgba(146, 57, 223, 0.3);
  cursor: pointer;
}

.process-btn:hover {
  background: var(--accent-hover);
}

.process-btn:active {
  transform: scale(.98);
}

.process-btn:disabled {
  background: var(--bg-secondary);
  color: var(--text-muted);
  box-shadow: none;
  cursor: not-allowed;
}

/* Fix icon buttons for Font Awesome */
.fc-remove i,
.img-remove i {
  font-size: 13px;
}

/* Responsive */
@media (max-width: 600px) {
  .type-tabs {
    flex-direction: column;
  }

  .layer-group {
    flex-direction: column;
  }
}
