/* ═══════════════════════════════════════════════════
   FrameFit — Image Resizer · style.css
   ImgTry brand theme · Inter · brand teal #42B5A4
   Tokens kept consistent with the ImgTry tool suite
   (see simple-img-rename) so every tool reads as one product.
═══════════════════════════════════════════════════ */

/* ── TOKENS ── */
:root {
  --bg-base:        #f5f5fa;
  --bg-card:        #ffffff;
  --bg-panel:       #ffffff;
  --bg-surface:     #f5f5fa;
  --bg-hover:       #ececf4;
  --bg-input:       #ffffff;

  --border:         #e4e4ee;
  --border-strong:  #c4c4d4;
  --border-focus:   rgba(66,181,164,0.5);
  --border-active:  #42b5a4;

  --accent:         #42b5a4;
  --accent-light:   #2e8577;
  --accent-glow:    rgba(66,181,164,0.22);
  --accent-grad:    linear-gradient(135deg, #42b5a4 0%, #2e8577 100%);

  --gold:           #f0b429;
  --green:          #1e8e5a;
  --red:            #c0392b;

  --text-primary:   #1a1a22;
  --text-secondary: #55555f;
  --text-muted:     #8a8a96;
  --text-accent:    #2e8577;

  --radius-sm:      8px;
  --radius-md:      14px;
  --radius-lg:      20px;
  --radius-xl:      24px;

  --shadow-card:    0 16px 40px rgba(26,26,34,0.10), 0 4px 12px rgba(26,26,34,0.06);
  --shadow-glow:    0 0 20px rgba(66,181,164,0.18);

  --font-display:   'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-body:      'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --transition:     0.2s cubic-bezier(0.4,0,0.2,1);
}

/* ── RESET ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--bg-base);
  color: var(--text-primary);
  min-height: 100vh;
  font-size: 14px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ── APP WRAPPER ── */
.app-wrapper {
  max-width: 980px;
  margin: 0 auto;
  padding: 32px 20px 60px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* ════════════════════════════════
   HEADER
════════════════════════════════ */
.app-header {
  text-align: center;
  max-width: 620px;
  margin: 0 auto;
}

.app-header__title {
  font-weight: 800;
  font-size: clamp(1.65rem, 5.5vw, 2.4rem);
  letter-spacing: -0.9px;
  color: var(--text-primary);
  margin: 0 0 8px;
}

.app-header__title strong {
  font-weight: 900;
  color: var(--accent);
}

.app-header__subtitle {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-secondary);
  line-height: 1.6;
  margin: 0;
}

.app-header__subtitle a {
  color: var(--text-accent);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: rgba(66,181,164,0.35);
  text-underline-offset: 2px;
}

.app-header__subtitle a:hover { text-decoration-color: currentColor; }

.app-header__note {
  font-size: 12.5px;
  font-weight: 500;
  color: var(--text-muted);
  line-height: 1.5;
  margin: 8px 0 0;
}

/* ════════════════════════════════
   STEP BAR
════════════════════════════════ */
.step-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: 16px 24px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
}

.step {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  transition: color var(--transition);
  padding: 6px 12px;
  border-radius: 99px;
  cursor: default;
  white-space: nowrap;
}

.step.active {
  color: var(--text-primary);
  background: var(--bg-surface);
}

.step.done {
  color: var(--green);
}

.step-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--text-muted);
  transition: background var(--transition), box-shadow var(--transition);
}

.step.active .step-dot {
  background: var(--accent);
  box-shadow: 0 0 8px var(--accent-glow);
}

.step.done .step-dot {
  background: var(--green);
}

.step-line {
  flex: 1;
  height: 1px;
  background: var(--border);
  min-width: 20px;
  max-width: 60px;
}

/* ════════════════════════════════
   MAIN CARD
════════════════════════════════ */
.main-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-card);
  overflow: hidden;
}

/* ════════════════════════════════
   PANELS
════════════════════════════════ */
.panel {
  padding: 36px 40px;
  animation: panelIn 0.3s ease;
}

@keyframes panelIn {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

.panel.hidden { display: none !important; }
.hidden { display: none !important; }

.panel-head {
  margin-bottom: 28px;
}

.panel-title {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.panel-sub {
  font-size: 13px;
  color: var(--text-secondary);
}

.panel-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

/* ════════════════════════════════
   DROPZONE (matches the ImgTry
   brand pattern — a focal pill
   button, not a bordered box)
════════════════════════════════ */
.dropzone {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 44px 24px;
  border-radius: var(--radius-xl);
  cursor: pointer;
  text-align: center;
}

.dropzone__ring {
  position: absolute;
  inset: 0;
  border-radius: var(--radius-xl);
  border: 1.5px dashed transparent;
  box-shadow: 0 0 0 0 rgba(66,181,164,0);
  transition: box-shadow 0.25s ease, border-color 0.25s ease;
  pointer-events: none;
}

.dropzone.drag-over .dropzone__ring {
  border-color: rgba(66,181,164,0.45);
  box-shadow: 0 0 0 8px rgba(66,181,164,0.08);
}

.dropzone__button {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  height: 56px;
  padding: 0 32px;
  border-radius: 9999px;
  background: var(--accent);
  border: 1.5px solid var(--accent);
  color: #fff;
  font-weight: 700;
  font-size: 16px;
  letter-spacing: -0.1px;
  box-shadow: 0 2px 10px rgba(66,181,164,0.28);
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, border-color 0.18s ease;
}

.dropzone__icon { width: 20px; height: 20px; flex-shrink: 0; color: #fff; }

.dropzone:hover .dropzone__button {
  transform: translateY(-2px);
  background: var(--accent-light);
  border-color: var(--accent-light);
  box-shadow: 0 14px 32px rgba(66,181,164,0.28);
}

.dropzone:active .dropzone__button {
  transform: translateY(0) scale(0.98);
  box-shadow: 0 6px 16px rgba(66,181,164,0.24);
}

.dropzone.drag-over .dropzone__button {
  transform: translateY(-2px);
  background: var(--accent-light);
  border-color: var(--accent-light);
  box-shadow: 0 14px 32px rgba(66,181,164,0.32);
}

/* fading hairline divider */
.dropzone__divider {
  display: flex;
  align-items: center;
  gap: 16px;
  width: 100%;
  max-width: 300px;
  margin-top: 26px;
  color: var(--text-muted);
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.2px;
}

.dropzone__divider::before,
.dropzone__divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--border));
}

.dropzone__divider::after {
  background: linear-gradient(to left, transparent, var(--border));
}

.dropzone__trust {
  display: flex;
  align-items: center;
  gap: 7px;
  margin: 20px 0 0;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-secondary);
}

.dropzone__trust svg { width: 15px; height: 15px; color: var(--accent); flex-shrink: 0; }

@media (min-width: 640px) {
  .dropzone { padding: 56px 24px; }
  .dropzone__button { height: 60px; padding: 0 36px; font-size: 16.5px; }
}

/* ── selected-file confirmation row ── */
.upload-confirm {
  display: flex;
  align-items: center;
  gap: 13px;
  max-width: 420px;
  margin: 24px auto 0;
  padding: 8px 16px 8px 8px;
  background: var(--bg-surface);
  border: 1.5px solid var(--border-strong);
  border-radius: 9999px;
  text-align: left;
}

.upload-confirm__thumb {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid var(--border-strong);
  background: #fff;
}

.upload-confirm__info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.upload-confirm__info strong {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.upload-confirm__meta {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-muted);
}

.upload-confirm__change {
  flex-shrink: 0;
  background: none;
  border: none;
  color: var(--text-accent);
  font-weight: 700;
  font-size: 13px;
  text-decoration: underline;
  text-decoration-color: var(--accent-glow);
  text-underline-offset: 2px;
  cursor: pointer;
  padding: 4px 2px;
}

.upload-confirm__change:hover { text-decoration-color: currentColor; }

/* ════════════════════════════════
   PLATFORM TABS
════════════════════════════════ */
.platform-tabs {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.ptab {
  padding: 7px 16px;
  border-radius: 99px;
  border: 1.5px solid var(--border-strong);
  background: var(--bg-surface);
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition);
  font-family: var(--font-body);
}

.ptab:hover {
  border-color: var(--accent);
  color: var(--text-primary);
}

.ptab.active {
  background: var(--accent-grad);
  border-color: transparent;
  color: #fff;
  box-shadow: 0 2px 12px var(--accent-glow);
}

/* ════════════════════════════════
   PRESET GRID
════════════════════════════════ */
.preset-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.preset-card {
  background: var(--bg-surface);
  border: 1.5px solid var(--border-strong);
  border-radius: var(--radius-md);
  padding: 16px 14px;
  cursor: pointer;
  transition: all var(--transition);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  text-align: center;
}

.preset-card:hover {
  border-color: var(--accent);
  background: var(--bg-hover);
  transform: translateY(-2px);
  box-shadow: 0 4px 16px var(--accent-glow);
}

.preset-card.selected {
  border-color: var(--accent);
  background: rgba(66,181,164,0.1);
  box-shadow: 0 0 0 1px var(--accent), 0 4px 16px var(--accent-glow);
}

.preset-visual {
  display: flex;
  align-items: center;
  justify-content: center;
}

.preset-rect {
  background: var(--bg-hover);
  border: 1.5px solid var(--border);
  border-radius: 4px;
  transition: border-color var(--transition);
}

.preset-card.selected .preset-rect,
.preset-card:hover .preset-rect {
  border-color: var(--accent);
  background: rgba(66,181,164,0.15);
}

.preset-name {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.3;
}

.preset-dims {
  font-size: 11px;
  color: var(--text-muted);
  font-family: 'Courier New', monospace;
}

/* custom size */
.custom-size {
  background: var(--bg-surface);
  border: 1.5px solid var(--border-strong);
  border-radius: var(--radius-md);
  padding: 20px;
  margin-bottom: 16px;
}

.custom-row {
  display: flex;
  align-items: flex-end;
  gap: 12px;
}

.custom-x {
  font-size: 18px;
  color: var(--text-muted);
  padding-bottom: 8px;
}

.custom-hint {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 10px;
}

/* selected badge */
.selected-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: rgba(30,142,90,0.08);
  border: 1px solid rgba(30,142,90,0.2);
  border-radius: var(--radius-sm);
  margin-top: 4px;
  color: var(--green);
  font-size: 13px;
  font-weight: 500;
}

.selected-badge svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

/* ════════════════════════════════
   ADJUST LAYOUT
════════════════════════════════ */
.adjust-layout {
  display: grid;
  grid-template-columns: 1fr 260px;
  gap: 24px;
  align-items: start;
}

/* Canvas area */
.canvas-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.canvas-outer {
  width: 100%;
  aspect-ratio: 1;
  max-height: 500px;
  background:
    repeating-conic-gradient(#ffffff 0% 25%, #e8e8f0 0% 50%)
    0 0 / 20px 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: grab;
}

.canvas-outer:active { cursor: grabbing; }

.canvas-outer canvas {
  display: block;
  max-width: 100%;
  max-height: 100%;
  touch-action: none;
}

/* crop overlay canvas */
.canvas-outer #cropCanvas {
  position: absolute;
  top: 0; left: 0;
  pointer-events: none;
}

.canvas-dims {
  font-size: 11px;
  color: var(--text-muted);
  font-family: 'Courier New', monospace;
  background: var(--bg-surface);
  padding: 4px 12px;
  border-radius: 99px;
  border: 1px solid var(--border);
}

/* Controls sidebar */
.controls-sidebar {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

/* ════════════════════════════════
   CONTROL GROUPS
════════════════════════════════ */
.ctrl-group {
  background: var(--bg-surface);
  border: 1.5px solid var(--border-strong);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ctrl-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
}

.ctrl-val {
  font-size: 11px;
  font-weight: 700;
  color: var(--accent-light);
  font-family: 'Courier New', monospace;
  margin-left: auto;
  text-transform: none;
  letter-spacing: 0;
}

.ctrl-hint {
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.4;
}

/* background toggle */
.bg-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}

.bgtab {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--border-strong);
  background: var(--bg-hover);
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition);
  font-family: var(--font-body);
}

.bgtab:hover { border-color: var(--accent); color: var(--text-primary); }

.bgtab.active {
  background: rgba(66,181,164,0.15);
  border-color: var(--accent);
  color: var(--text-primary);
}

.bgtab-icon {
  width: 16px;
  height: 16px;
  border-radius: 3px;
  border: 1.5px solid currentColor;
  flex-shrink: 0;
}

.bgtab-white { background: #fff; border-color: #aaa; }
.bgtab-blur  {
  background: linear-gradient(135deg, #42b5a455, #2e857755);
  border-color: #2e857788;
}
.bgtab-color {
  background: linear-gradient(135deg, #42b5a4, #2e8577);
}
.bgtab-transparent {
  background: repeating-conic-gradient(#ffffff 0% 25%, #d8d8e4 0% 50%) 0 0 / 8px 8px;
}

/* ── colour picker row ── */
.color-picker-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

#bgColorInput {
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1.5px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: none;
  cursor: pointer;
  flex-shrink: 0;
}
#bgColorInput::-webkit-color-swatch-wrapper { padding: 3px; }
#bgColorInput::-webkit-color-swatch { border: none; border-radius: 6px; }
#bgColorInput::-moz-color-swatch    { border: none; border-radius: 6px; }

.color-hex-input {
  flex: 1;
  height: 40px;
  padding: 0 12px;
  border: 1.5px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--bg-input);
  color: var(--text-primary);
  font-size: 13px;
  font-weight: 700;
  font-family: var(--font-body);
  text-transform: uppercase;
  letter-spacing: 0.3px;
}
.color-hex-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

/* zoom buttons */
.zoom-btns {
  display: flex;
  gap: 6px;
}

.flip-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}

.crop-actions {
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  gap: 6px;
  align-items: stretch;
}

.crop-actions .btn-icon { width: auto; height: auto; aspect-ratio: 1; }

/* ════════════════════════════════
   SLIDERS
════════════════════════════════ */
.slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 4px;
  border-radius: 99px;
  background: var(--bg-hover);
  outline: none;
  cursor: pointer;
  position: relative;
}

.slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--accent-grad);
  cursor: pointer;
  box-shadow: 0 0 8px var(--accent-glow);
  transition: transform var(--transition), box-shadow var(--transition);
  border: 2px solid var(--bg-card);
}

.slider::-webkit-slider-thumb:hover {
  transform: scale(1.2);
  box-shadow: 0 0 16px var(--accent-glow);
}

.slider::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: linear-gradient(135deg, #42b5a4, #2e8577);
  cursor: pointer;
  border: 2px solid var(--bg-card);
}

/* quality slider gradient track */
.slider-quality {
  background: linear-gradient(to right, #c0392b 0%, #f0b429 40%, #1e8e5a 75%, #42b5a4 100%);
}

.quality-marks {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  color: var(--text-muted);
  padding: 0 2px;
}

/* ════════════════════════════════
   EXPORT LAYOUT
════════════════════════════════ */
.export-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 28px;
  align-items: start;
}

.export-preview-wrap {
  position: relative;
  background:
    repeating-conic-gradient(#ffffff 0% 25%, #e8e8f0 0% 50%)
    0 0 / 20px 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 280px;
}

.export-preview-wrap canvas {
  max-width: 100%;
  max-height: 400px;
  display: block;
}

.export-preview-label {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 10px;
  color: var(--text-muted);
  background: var(--bg-card);
  padding: 3px 10px;
  border-radius: 99px;
  border: 1px solid var(--border);
}

.export-controls {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* format buttons */
.format-row {
  display: flex;
  gap: 6px;
}

.fmt-btn {
  flex: 1;
  padding: 8px 4px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--border-strong);
  background: var(--bg-hover);
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  font-family: var(--font-body);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.fmt-btn.disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.fmt-btn.disabled:hover { border-color: var(--border-strong); color: var(--text-secondary); }

.fmt-btn:hover { border-color: var(--accent); color: var(--text-primary); }

.fmt-btn.active {
  background: rgba(66,181,164,0.15);
  border-color: var(--accent);
  color: var(--text-primary);
}

/* quality badge */
.quality-badge {
  font-size: 10px;
  padding: 2px 8px;
  border-radius: 99px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  background: rgba(30,142,90,0.12);
  color: var(--green);
  border: 1px solid rgba(30,142,90,0.2);
  transition: all var(--transition);
}

.quality-badge.medium {
  background: rgba(240,180,41,0.12);
  color: var(--gold);
  border-color: rgba(240,180,41,0.2);
}

.quality-badge.low {
  background: rgba(192,57,43,0.12);
  color: var(--red);
  border-color: rgba(192,57,43,0.2);
}

/* size estimate */
.size-estimate {
  background: var(--bg-surface);
  border: 1.5px solid var(--border-strong);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.size-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.size-label {
  font-size: 12px;
  color: var(--text-secondary);
}

.size-val {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-primary);
  font-family: 'Courier New', monospace;
}

.size-output { color: var(--accent-light); }

/* filename */
.filename-row {
  display: flex;
  align-items: center;
  gap: 0;
}

.filename-input {
  flex: 1;
  background: var(--bg-input);
  border: 1.5px solid var(--border-strong);
  border-right: none;
  border-radius: var(--radius-sm) 0 0 var(--radius-sm);
  color: var(--text-primary);
  font-size: 13px;
  font-family: var(--font-body);
  padding: 9px 12px;
  outline: none;
  transition: border-color var(--transition);
}

.filename-input:focus { border-color: var(--border-focus); }

.filename-ext {
  background: var(--bg-hover);
  border: 1.5px solid var(--border-strong);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 9px 12px;
  font-size: 12px;
  color: var(--text-secondary);
  font-weight: 600;
  white-space: nowrap;
}

/* ════════════════════════════════
   BUTTONS
════════════════════════════════ */
/* primary */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 12px 24px;
  background: var(--accent-grad);
  border: none;
  border-radius: 9999px;
  color: #fff;
  font-size: 15.5px;
  font-weight: 800;
  font-family: var(--font-body);
  cursor: pointer;
  transition: opacity var(--transition), box-shadow var(--transition), transform var(--transition);
  box-shadow: 0 4px 16px var(--accent-glow);
  white-space: nowrap;
}

.btn-primary:hover:not(:disabled) {
  opacity: 0.92;
  transform: translateY(-1px);
  box-shadow: 0 8px 24px var(--accent-glow);
}

.btn-primary:disabled {
  opacity: 0.35;
  cursor: not-allowed;
  transform: none;
}

.btn-arrow { transition: transform var(--transition); }
.btn-primary:hover .btn-arrow { transform: translateX(3px); }

/* next full width */
.btn-next {
  width: 100%;
  justify-content: center;
  margin-top: 20px;
}

/* ghost */
.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 48px;
  padding: 10px 20px;
  background: #fff;
  border: 1.5px solid var(--border-strong);
  border-radius: 9999px;
  color: var(--text-primary);
  font-size: 15.5px;
  font-weight: 800;
  font-family: var(--font-body);
  cursor: pointer;
  transition: all var(--transition);
}

.btn-ghost:hover {
  border-color: var(--text-secondary);
  color: var(--text-primary);
  background: var(--bg-hover);
}

.btn-full { width: 100%; justify-content: center; }

/* secondary */
.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 12px;
  background: var(--bg-hover);
  border: 1.5px solid var(--border-strong);
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 500;
  font-family: var(--font-body);
  cursor: pointer;
  transition: all var(--transition);
}

.btn-secondary:hover {
  border-color: var(--accent);
  color: var(--text-primary);
  background: rgba(66,181,164,0.08);
}

.btn-half { flex: 1; }

/* accent */
.btn-accent {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 14px;
  background: rgba(66,181,164,0.15);
  border: 1px solid var(--accent);
  border-radius: var(--radius-sm);
  color: var(--accent-light);
  font-size: 12px;
  font-weight: 600;
  font-family: var(--font-body);
  cursor: pointer;
  transition: all var(--transition);
}

.btn-accent:hover { background: rgba(66,181,164,0.25); }

/* icon button */
.btn-icon {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--border-strong);
  background: var(--bg-hover);
  color: var(--text-secondary);
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
  font-family: var(--font-body);
}

.btn-icon:hover {
  border-color: var(--accent);
  color: var(--text-primary);
  background: rgba(66,181,164,0.1);
}

/* download button */
.btn-download {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 52px;
  padding: 15px;
  background: var(--accent-grad);
  border: none;
  border-radius: 9999px;
  color: #fff;
  font-size: 15.5px;
  font-weight: 800;
  font-family: var(--font-body);
  cursor: pointer;
  transition: opacity var(--transition), transform var(--transition), box-shadow var(--transition);
  box-shadow: 0 4px 20px var(--accent-glow);
  letter-spacing: 0.01em;
}

.btn-download svg { width: 20px; height: 20px; }

.btn-download:hover {
  opacity: 0.92;
  transform: translateY(-2px);
  box-shadow: 0 8px 28px var(--accent-glow);
}

.btn-startover {
  font-size: 12px;
  color: var(--text-muted);
  border-color: transparent;
  margin-top: 4px;
}

.btn-startover:hover { color: var(--red); border-color: rgba(192,57,43,0.3); background: rgba(192,57,43,0.05); }

/* ════════════════════════════════
   INPUT GROUPS
════════════════════════════════ */
.input-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.input-group label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.input-group input {
  background: var(--bg-input);
  border: 1.5px solid var(--border-strong);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 14px;
  font-family: var(--font-body);
  padding: 9px 12px;
  outline: none;
  transition: border-color var(--transition);
  width: 100%;
}

.input-group input:focus { border-color: var(--border-focus); }

/* ════════════════════════════════
   TOAST
════════════════════════════════ */
.toast {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%) translateY(16px) scale(0.96);
  background: var(--text-primary);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 16px;
  padding: 13px 20px 13px 15px;
  display: flex;
  align-items: center;
  gap: 11px;
  font-size: 13.5px;
  font-weight: 600;
  color: #fff;
  box-shadow: 0 12px 32px rgba(0,0,0,0.24), 0 2px 8px rgba(0,0,0,0.14);
  opacity: 0;
  transition: opacity 0.22s cubic-bezier(0.16,1,0.3,1), transform 0.22s cubic-bezier(0.16,1,0.3,1);
  pointer-events: none;
  z-index: 999;
  max-width: 90vw;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0) scale(1);
}

.toast.hidden { display: none; }

.toast-icon {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(255,255,255,0.16);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
}

/* ════════════════════════════════
   SCROLLBAR
════════════════════════════════ */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--bg-base); }
::-webkit-scrollbar-thumb { background: var(--bg-surface); border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

/* ════════════════════════════════
   RESPONSIVE
════════════════════════════════ */
@media (max-width: 720px) {
  .app-wrapper { padding: 16px 12px 48px; }
  .panel { padding: 24px 20px; }
  .step { font-size: 11px; padding: 5px 8px; }
  .step-line { min-width: 10px; max-width: 30px; }

  .adjust-layout,
  .export-layout {
    grid-template-columns: 1fr;
  }

  .controls-sidebar { order: -1; }

  .preset-grid {
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  }

  .panel-title { font-size: 18px; }
}

@media (max-width: 480px) {
  .platform-tabs { gap: 4px; }
  .ptab { padding: 6px 10px; font-size: 12px; }
  .panel-actions { flex-direction: column-reverse; gap: 10px; }
  .panel-actions .btn-ghost,
  .panel-actions .btn-primary { width: 100%; justify-content: center; }
}

/* ── reduced motion ── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
/* ════════════════════════════════
   SEO / ABOUT CONTENT SECTION
════════════════════════════════ */
.info-section {
  max-width: 760px;
  margin: 12px auto 0;
  padding: 32px 24px 8px;
  border-top: 1px solid var(--border);
}

.info-section__title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 19px;
  letter-spacing: -0.3px;
  color: var(--text-primary);
  margin: 28px 0 10px;
}

.info-section__title:first-child { margin-top: 0; }

.info-section__text {
  font-size: 14.5px;
  color: var(--text-secondary);
  line-height: 1.7;
  margin: 0 0 4px;
}

.info-section__list {
  list-style: none;
  display: grid;
  gap: 8px;
  margin: 4px 0 0;
  padding: 0;
}

.info-section__list li {
  font-size: 14.5px;
  color: var(--text-secondary);
  line-height: 1.6;
  padding: 10px 14px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}

.info-section__list strong { color: var(--text-primary); }

.faq { display: flex; flex-direction: column; gap: 8px; margin-top: 4px; }

.faq__item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
}

.faq__item summary {
  font-weight: 700;
  font-size: 14.5px;
  color: var(--text-primary);
  cursor: pointer;
  list-style: none;
}

.faq__item summary::-webkit-details-marker { display: none; }

.faq__item summary::after {
  content: "+";
  float: right;
  font-weight: 800;
  color: var(--accent);
}

.faq__item[open] summary::after { content: "\2212"; }

.faq__item p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-top: 8px;
}

@media (max-width: 480px) {
  .info-section { padding: 24px 16px 8px; }
  .info-section__title { font-size: 17px; }
}
