* { box-sizing: border-box; }
body {
  margin: 0; font-family: 'Segoe UI', Arial, sans-serif;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  min-height: 100vh; display: flex; flex-direction: column;
  align-items: center; justify-content: flex-start; padding: 20px;
}
.container {
  background: #fff; border-radius: 16px; max-width: 700px; width: 100%;
  padding: 32px; box-shadow: 0 20px 60px rgba(0,0,0,0.3); margin: 0 auto 16px;
}
h1 { text-align: center; color: #333; margin-top: 0; font-size: 26px; }
p.subtitle { text-align: center; color: #595959; margin-bottom: 24px; }
.dropzone {
  border: 3px dashed #764ba2; border-radius: 12px; padding: 40px 20px;
  text-align: center; cursor: pointer; background: #f7f5fb; transition: 0.2s;
}
.dropzone.dragover { background: #ece6f7; border-color: #667eea; }
.dropzone strong { color: #764ba2; font-size: 18px; }
.dropzone span { display: block; color: #595959; margin-top: 8px; font-size: 14px; }
input[type=file] { display: none; }
.opt-row { margin-top: 20px; display: flex; align-items: center; gap: 12px; justify-content: center; flex-wrap: wrap; }
.opt-row label { font-size: 14px; color: #333; font-weight: 600; }
.opt-row select, .opt-row input[type=text] {
  padding: 8px 12px; border-radius: 6px; border: 1px solid #ccc; font-size: 14px;
}
.slider-wrap { margin-top: 20px; }
.slider-wrap label { font-size: 14px; color: #333; font-weight: 600; display: block; margin-bottom: 8px; }
.slider-wrap input[type=range] { width: 100%; accent-color: #764ba2; }
.slider-labels { display: flex; justify-content: space-between; font-size: 12px; color: #595959; margin-top: 4px; }
#resultList { display: flex; flex-direction: column; gap: 10px; margin-top: 20px; }
.result-item {
  display: flex; align-items: center; gap: 12px; background: #f7f5fb;
  border-radius: 8px; padding: 10px 12px;
}
.result-item .info { flex: 1; font-size: 13px; color: #333; word-break: break-all; }
.result-item .info .sizes { color: #595959; font-size: 12px; }
.result-item .sizes .saved { color: #1f7a3d; font-weight: 600; }
.result-item .num {
  background: #764ba2; color: #fff; width: 26px; height: 26px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; flex-shrink: 0;
}
.result-item img { width: 50px; height: 50px; object-fit: cover; border-radius: 6px; }
.result-item .remove {
  background: #eee; border: none; border-radius: 6px; width: 30px; height: 30px;
  cursor: pointer; font-size: 14px; color: #555;
}
.result-item .remove:hover { background: #ddd; }
a.download-btn {
  background: linear-gradient(135deg, #667eea, #764ba2); color: #fff; text-decoration: none;
  padding: 8px 14px; border-radius: 6px; font-size: 13px; font-weight: 600; white-space: nowrap;
}
.actions { display: flex; gap: 12px; margin-top: 20px; }
button.primary, button.secondary {
  flex: 1; padding: 14px; border: none; border-radius: 8px;
  font-size: 16px; font-weight: 600; cursor: pointer; transition: 0.2s;
}
button.primary { background: linear-gradient(135deg, #667eea, #764ba2); color: #fff; }
button.primary:disabled { opacity: 0.5; cursor: not-allowed; }
button.primary:hover:not(:disabled) { opacity: 0.9; }
button.secondary { background: #eee; color: #333; }
button.secondary:hover { background: #ddd; }
.status { text-align: center; margin-top: 14px; font-size: 14px; color: #595959; min-height: 20px; }
.container h2 { color: #333; font-size: 20px; margin-top: 0; }
.container h3 { color: #333; font-size: 17px; margin-top: 22px; }
.container .body-text { color: #595959; font-size: 14px; line-height: 1.7; }

#consentOverlay {
  position: fixed; inset: 0; background: rgba(20, 15, 35, 0.75);
  display: flex; align-items: center; justify-content: center; z-index: 1000; padding: 20px;
}
#consentOverlay.hidden { display: none; }
.consent-box { background: #fff; border-radius: 14px; max-width: 460px; width: 100%; padding: 28px; box-shadow: 0 20px 60px rgba(0,0,0,0.4); }
.consent-box p { font-size: 14px; color: #555; line-height: 1.6; }
.consent-box a { color: #764ba2; font-weight: 600; text-decoration: none; }
.consent-box a:hover { text-decoration: underline; }
.consent-checkbox { display: flex; align-items: flex-start; gap: 10px; margin: 18px 0; font-size: 14px; color: #333; cursor: pointer; }
.consent-checkbox input { margin-top: 3px; width: 18px; height: 18px; cursor: pointer; flex-shrink: 0; display: inline-block; }
#continueBtn {
  width: 100%; padding: 13px; border: none; border-radius: 8px; font-size: 16px; font-weight: 600;
  background: linear-gradient(135deg, #667eea, #764ba2); color: #fff; cursor: pointer; opacity: 0.5; transition: 0.2s;
}
#continueBtn:not(:disabled) { opacity: 1; }
#continueBtn:disabled { cursor: not-allowed; }
#continueBtn:not(:disabled):hover { opacity: 0.9; }
#mainContent.blurred { filter: blur(6px); pointer-events: none; user-select: none; }

.brand-head { display: flex; align-items: center; justify-content: center; gap: 10px; margin-bottom: 14px; }
.brand-head img { width: 36px; height: 36px; border-radius: 9px; }
.brand-head span { color: #fff; font-size: 20px; font-weight: 800; letter-spacing: 0.3px; }

.site-nav {
  width: 100%; max-width: 760px; margin: 0 auto 16px; background: rgba(255,255,255,0.12);
  border-radius: 14px; padding: 12px; display: flex; flex-wrap: wrap; gap: 8px; justify-content: center;
}
.site-nav a {
  color: #fff; text-decoration: none; font-size: 14px; font-weight: 700; padding: 9px 15px;
  border-radius: 24px; background: rgba(255,255,255,0.2); border: 2px solid rgba(255,255,255,0.3);
  transition: 0.2s; white-space: nowrap; box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}
.site-nav a:hover { background: rgba(255,255,255,0.35); transform: translateY(-1px); }
.site-nav a.active { background: #fff; color: #764ba2; border-color: #fff; box-shadow: 0 4px 14px rgba(0,0,0,0.25); }
.page-foot { text-align: center; font-size: 13px; margin-top: 10px; padding-bottom: 20px; }
.page-foot a { color: #fff; margin: 0 8px; text-decoration: underline; }
