/* ══════════════════════════════════════════════════════════════════════════════
   Base64 Image Codec — styles.css
   Dark futuristic theme: deep navy/purple bg, teal + violet accents
   ══════════════════════════════════════════════════════════════════════════════ */

/* ── CSS Variables ─────────────────────────────────────────────────────────── */
:root {
  --bg: #0a0a14;
  --surface: #10101e;
  --surface2: #14142a;
  --surface3: #1c1c32;
  --border: rgba(124, 106, 255, .18);
  --border2: rgba(124, 106, 255, .28);

  --accent: #7c6aff;
  --accent-glow: rgba(124, 106, 255, .35);
  --teal: #6affdb;
  --teal-glow: rgba(106, 255, 219, .28);
  --amber: #ffb86a;
  --red: #ff6a8a;

  --text: #eeeef5;
  --muted: #b8b8d0;
  --muted2: #7878a0;

  --mono: 'Space Mono', monospace;
  --sans: 'Syne', sans-serif;

  --radius: 18px;
  --radius-sm: 10px;
  --shadow: 0 8px 40px rgba(0, 0, 0, .55);
  --shadow-sm: 0 4px 20px rgba(0, 0, 0, .35);
}

/* ── Reset & Base ──────────────────────────────────────────────────────────── */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.65;
  min-height: 100vh;
  overflow-x: hidden;
}

/* ── Orb background decorations ───────────────────────────────────────────── */
.orb {
  position: fixed;
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
  filter: blur(120px);
  opacity: .15;
}

.orb-a {
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(82, 60, 204, 0.7) 0%, transparent 70%);
  top: -200px;
  left: -200px;
  animation: orbFloat 18s ease-in-out infinite alternate;
}

.orb-b {
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, #6affdb 0%, transparent 70%);
  top: 40%;
  right: -180px;
  animation: orbFloat 22s ease-in-out infinite alternate-reverse;
}

.orb-c {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, #a08fff 0%, transparent 70%);
  bottom: 10%;
  left: 30%;
  animation: orbFloat 26s ease-in-out infinite alternate;
}

@keyframes orbFloat {
  from {
    transform: translateY(0) scale(1);
  }

  to {
    transform: translateY(40px) scale(1.08);
  }
}

/* ── Layout wrapper ────────────────────────────────────────────────────────── */
.wrap {
  position: relative;
  z-index: 1;
  max-width: 760px;
  margin: 0 auto;
  padding: 48px 20px 80px;
}

/* ── Header ────────────────────────────────────────────────────────────────── */
header {
  text-align: center;
  margin-bottom: 44px;
}

.eyebrow {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--teal);
  margin-bottom: 12px;
}

h1 {
  font-family: var(--sans);
  font-size: clamp(2.4rem, 7vw, 4rem);
  font-weight: 800;
  line-height: 1.05;
  background: linear-gradient(135deg, #fff 30%, #a08fff 70%, #6affdb);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 16px;
}

.tagline {
  color: var(--muted);
  font-size: .95rem;
  line-height: 1.7;
}

/* ── Step indicator ────────────────────────────────────────────────────────── */
.steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-bottom: 36px;
}

.step-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.step-num {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 2px solid var(--border2);
  background: var(--surface2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 700;
  color: var(--muted2);
  transition: all .3s ease;
}

.step-num.active {
  border-color: var(--accent);
  background: rgba(124, 106, 255, .18);
  color: #fff;
  box-shadow: 0 0 18px var(--accent-glow);
}

.step-num.done {
  border-color: var(--teal);
  background: rgba(106, 255, 219, .12);
  color: var(--teal);
  box-shadow: 0 0 14px var(--teal-glow);
}

.step-label {
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--muted2);
}

.step-line {
  width: 80px;
  height: 2px;
  background: var(--border);
  margin-bottom: 22px;
  transition: background .4s ease;
}

.step-line.done {
  background: linear-gradient(90deg, var(--teal), var(--accent));
  box-shadow: 0 0 8px var(--teal-glow);
}

/* ── Card ──────────────────────────────────────────────────────────────────── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
  margin-bottom: 28px;
}

.card-shine {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg,
      rgba(255, 255, 255, .03) 0%,
      transparent 50%,
      rgba(124, 106, 255, .04) 100%);
  pointer-events: none;
}

.card-body {
  padding: 32px 28px;
}

@media(max-width:580px) {
  .card-body {
    padding: 22px 16px;
  }
}

/* ── Section divider ───────────────────────────────────────────────────────── */
.section-divide {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 8px 0 24px;
}

.section-divide::before,
.section-divide::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border2), transparent);
}

.section-divide span {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--muted2);
  white-space: nowrap;
}

/* ── slabel ────────────────────────────────────────────────────────────────── */
.slabel {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--muted2);
  margin-bottom: 14px;
}

/* ── Proxy notice ──────────────────────────────────────────────────────────── */
.proxy-notice {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: rgba(255, 184, 106, .08);
  border: 1px solid rgba(255, 184, 106, .22);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  font-size: .82rem;
  color: var(--muted);
  margin-bottom: 18px;
  line-height: 1.55;
}

.proxy-notice strong {
  color: var(--amber);
}

/* ── URL row ───────────────────────────────────────────────────────────────── */
.url-row {
  display: flex;
  gap: 8px;
  margin-bottom: 6px;
}

.url-inp {
  flex: 1;
  background: var(--surface2);
  border: 1px solid var(--border2);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--mono);
  font-size: 12px;
  padding: 10px 14px;
  outline: none;
  transition: border-color .2s;
}

.url-inp::placeholder {
  color: var(--muted2);
}

.url-inp:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

/* ── OR divider ────────────────────────────────────────────────────────────── */
.or-div {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 16px 0;
  color: var(--muted2);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.or-div::before,
.or-div::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

/* ── Drop zones ────────────────────────────────────────────────────────────── */
.drop-zone,
.decode-drop {
  border: 2px dashed var(--border2);
  border-radius: 14px;
  padding: 44px 24px;
  text-align: center;
  cursor: pointer;
  transition: all .3s ease;
  background: var(--surface2);
  position: relative;
}

.drop-zone:hover,
.drop-zone.over,
.decode-drop:hover,
.decode-drop.over {
  border-color: var(--accent);
  background: rgba(124, 106, 255, .05);
}

.drop-zone:focus-within,
.decode-drop:focus-within {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.drop-zone input,
.decode-drop input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  width: 100%;
  height: 100%;
}

.drop-icon {
  width: 60px;
  height: 60px;
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(124, 106, 255, .18), rgba(106, 255, 219, .1));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  margin: 0 auto 14px;
}

.drop-zone h3,
.decode-drop h3 {
  font-family: var(--sans);
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--text);
}

.drop-zone p,
.decode-drop p {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--muted2);
  letter-spacing: .5px;
}

.instant-badge {
  display: inline-block;
  margin-top: 12px;
  padding: 4px 12px;
  background: rgba(106, 255, 219, .1);
  border: 1px solid rgba(106, 255, 219, .25);
  border-radius: 100px;
  font-family: var(--mono);
  font-size: 10px;
  color: var(--teal);
  letter-spacing: 1px;
}

/* ── Size warning ──────────────────────────────────────────────────────────── */
.size-warn {
  margin-top: 10px;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--amber);
  display: none;
  padding: 8px 12px;
  background: rgba(255, 184, 106, .07);
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 184, 106, .18);
}

/* ── Image preview strip ───────────────────────────────────────────────────── */
.img-strip {
  display: none;
  margin-top: 18px;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface3);
}

.img-strip img {
  width: 100%;
  max-height: 260px;
  object-fit: contain;
  display: block;
  background: var(--surface3);
}

.img-strip-foot {
  display: flex;
  justify-content: space-between;
  padding: 8px 14px;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--muted2);
  border-top: 1px solid var(--border);
  flex-wrap: wrap;
  gap: 4px;
}

/* ── Save section ──────────────────────────────────────────────────────────── */
.save-section {
  display: none;
  margin-top: 24px;
}

/* ── Big save block ────────────────────────────────────────────────────────── */
.big-save {
  border: 1px solid var(--border2);
  border-radius: 14px;
  overflow: hidden;
  background: var(--surface2);
}

.big-save-head {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 18px 20px;
  background: linear-gradient(135deg, rgba(124, 106, 255, .1), rgba(106, 255, 219, .07));
  border-bottom: 1px solid var(--border);
}

.big-save-icon {
  font-size: 24px;
  flex-shrink: 0;
}

.big-save-title {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 1rem;
  color: var(--text);
  margin-bottom: 3px;
}

.big-save-sub {
  font-size: .82rem;
  color: var(--muted);
}

.big-save-body {
  padding: 18px 20px;
  font-size: .88rem;
  color: var(--muted);
  line-height: 1.7;
}

.big-save-body p {
  margin-bottom: 16px;
}

.big-save-body strong {
  color: var(--text);
}

/* ── Action cards ──────────────────────────────────────────────────────────── */
.action-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 16px;
}

@media(max-width:520px) {
  .action-cards {
    grid-template-columns: 1fr;
  }
}

.ac {
  border: 1px solid var(--border2);
  border-radius: 12px;
  padding: 16px;
  cursor: pointer;
  background: var(--surface3);
  transition: all .25s ease;
}

.ac:hover {
  border-color: var(--accent);
  background: rgba(124, 106, 255, .08);
  transform: translateY(-4px);
  box-shadow: 0 10px 30px rgba(106, 255, 219, 0.15);
}

.ac.done {
  border-color: var(--teal);
  background: rgba(106, 255, 219, .07);
}

.ac-teal {
  border-color: rgba(106, 255, 219, .2);
}

.ac-teal:hover {
  border-color: var(--teal);
  background: rgba(106, 255, 219, .07);
}

.ac-icon {
  font-size: 22px;
  margin-bottom: 8px;
}

.ac-title {
  font-family: var(--sans);
  font-weight: 700;
  font-size: .92rem;
  margin-bottom: 6px;
  color: var(--text);
}

.ac-desc {
  font-size: .8rem;
  color: var(--muted2);
  line-height: 1.55;
  margin-bottom: 10px;
}

.ac-badge {
  display: inline-block;
  padding: 4px 10px;
  background: rgba(106, 255, 219, .1);
  border: 1px solid rgba(106, 255, 219, .22);
  border-radius: 100px;
  font-family: var(--mono);
  font-size: 10px;
  color: var(--teal);
  letter-spacing: .8px;
}

/* ── Decoded result ────────────────────────────────────────────────────────── */
.decoded-result {
  display: none;
  margin-top: 18px;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(106, 255, 219, .25);
  background: var(--surface3);
}

.decoded-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: rgba(106, 255, 219, .07);
  border-bottom: 1px solid rgba(106, 255, 219, .15);
  font-family: var(--mono);
  font-size: 11px;
  color: var(--teal);
}

.decoded-result img {
  width: 100%;
  max-height: 320px;
  object-fit: contain;
  display: block;
  background: var(--surface3);
}

.decoded-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--muted2);
  border-top: 1px solid var(--border);
  flex-wrap: wrap;
  gap: 8px;
}

/* ── Paste area ────────────────────────────────────────────────────────────── */
.paste-area {
  width: 100%;
  height: 120px;
  background: var(--surface2);
  border: 1px solid var(--border2);
  border-radius: var(--radius-sm);
  color: var(--accent);
  font-family: var(--mono);
  font-size: 11px;
  padding: 12px;
  resize: vertical;
  outline: none;
  transition: border-color .2s;
  margin-top: 12px;
  word-break: break-all;
}

.paste-area:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.paste-area::placeholder {
  color: var(--muted2);
}

/* ── Alerts ────────────────────────────────────────────────────────────────── */
.alert {
  display: none;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-family: var(--mono);
  font-size: 11px;
  line-height: 1.55;
  margin-top: 10px;
}

.alert-ok {
  background: rgba(106, 255, 219, .09);
  border: 1px solid rgba(106, 255, 219, .25);
  color: var(--teal);
}

.alert-err {
  background: rgba(255, 106, 138, .09);
  border: 1px solid rgba(255, 106, 138, .25);
  color: var(--red);
}

.alert-warn {
  background: rgba(255, 184, 106, .09);
  border: 1px solid rgba(255, 184, 106, .25);
  color: var(--amber);
}

/* ── Buttons ───────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 11px 22px;
  border-radius: var(--radius-sm);
  border: none;
  font-family: var(--sans);
  font-size: .88rem;
  font-weight: 700;
  cursor: pointer;
  transition: all .2s ease;
  white-space: nowrap;
  text-decoration: none;
}

.btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent), #a08fff);
  color: #fff;
  box-shadow: 0 4px 18px var(--accent-glow);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #9080ff, #b8a8ff);
  transform: translateY(-1px);
  box-shadow: 0 6px 24px var(--accent-glow);
}

.btn-teal {
  background: rgba(106, 255, 219, .12);
  color: var(--teal);
  border: 1px solid rgba(106, 255, 219, .3);
}

.btn-teal:hover {
  background: rgba(106, 255, 219, .2);
  border-color: var(--teal);
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  color: var(--muted2);
  border: 1px solid var(--border2);
}

.btn-ghost:hover {
  color: var(--text);
  border-color: var(--muted2);
}

.btn-sm {
  padding: 7px 14px;
  font-size: .8rem;
}

.row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 14px;
}

/* ── Dots ──────────────────────────────────────────────────────────────────── */
.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.dot-g {
  background: var(--teal);
  box-shadow: 0 0 6px var(--teal-glow);
}

.dot-p {
  background: var(--accent);
  box-shadow: 0 0 6px var(--accent-glow);
}

/* ── Advanced / Dev panel toggle ───────────────────────────────────────────── */
.adv-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  margin-bottom: 2px;
  transition: border-color .2s;
  user-select: none;
}

.adv-toggle:hover {
  border-color: var(--border2);
}

.adv-toggle:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.adv-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.adv-icon {
  font-size: 20px;
}

.adv-label {
  font-family: var(--sans);
  font-weight: 700;
  font-size: .92rem;
  color: var(--text);
}

.adv-sub {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--muted2);
  margin-top: 2px;
  letter-spacing: .5px;
}

.adv-arr {
  font-size: 13px;
  color: var(--muted2);
  transition: transform .3s ease;
}

.adv-arr.open {
  transform: rotate(180deg);
}

/* ── Advanced panel body ───────────────────────────────────────────────────── */
.adv-panel {
  max-height: 0;
  overflow: hidden;
  transition: max-height .4s ease;
  background: var(--surface);
  border: 1px solid var(--border);
  border-top: none;
  border-radius: 0 0 var(--radius) var(--radius);
  margin-bottom: 28px;
}

.adv-panel.open {
  max-height: 1200px;
}

.adv-inner {
  padding: 24px 24px 28px;
}

/* ── Raw box / snippet box ─────────────────────────────────────────────────── */
.raw-box,
.snip-box {
  background: var(--surface3);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--accent);
  max-height: 100px;
  overflow: hidden;
  word-break: break-all;
  position: relative;
  line-height: 1.6;
}

.fade {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 40px;
  background: linear-gradient(transparent, var(--surface3));
  pointer-events: none;
}

/* ── Snippet tabs ──────────────────────────────────────────────────────────── */
.snip-tabs {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.snip-btn {
  padding: 6px 14px;
  border-radius: 100px;
  border: 1px solid var(--border2);
  background: var(--surface2);
  color: var(--muted2);
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .8px;
  cursor: pointer;
  transition: all .2s;
}

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

.snip-btn.active {
  background: rgba(124, 106, 255, .15);
  border-color: var(--accent);
  color: #fff;
}

.snip-btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* ── Stats row ─────────────────────────────────────────────────────────────── */
.stat-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

@media(max-width:520px) {
  .stat-row {
    grid-template-columns: repeat(2, 1fr);
  }
}

.stat {
  background: var(--surface3);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px;
  text-align: center;
}

.stat .lbl {
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--muted2);
  margin-bottom: 4px;
}

.stat .val {
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 700;
  color: var(--accent);
}

/* ── Copy flash ────────────────────────────────────────────────────────────── */
.copy-flash {
  position: absolute;
  inset: 0;
  background: rgba(106, 255, 219, .12);
  border-radius: var(--radius-sm);
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s;
}

.copy-flash.pop {
  opacity: 1;
  transition: none;
}

/* ── Toast ─────────────────────────────────────────────────────────────────── */
.toast {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--surface3);
  border: 1px solid var(--teal);
  border-radius: 100px;
  padding: 10px 22px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--teal);
  box-shadow: 0 8px 32px rgba(0, 0, 0, .5), 0 0 20px var(--teal-glow);
  opacity: 0;
  transition: all .35s cubic-bezier(.34, 1.56, .64, 1);
  pointer-events: none;
  z-index: 9999;
  white-space: nowrap;
}

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

.toast.err {
  border-color: var(--red);
  color: var(--red);
  box-shadow: 0 8px 32px rgba(0, 0, 0, .5), 0 0 20px rgba(255, 106, 138, .25);
}

/* ── Floating download button ──────────────────────────────────────────────── */
#floatingDownload {
  display: none;
  position: fixed;
  bottom: 80px;
  right: 24px;
  z-index: 999;
  background: linear-gradient(135deg, var(--accent), #a08fff);
  color: #fff;
  border: none;
  border-radius: 100px;
  padding: 12px 22px;
  font-family: var(--sans);
  font-weight: 700;
  font-size: .88rem;
  cursor: pointer;
  box-shadow: 0 6px 28px var(--accent-glow);
  transition: all .2s ease;
  animation: pulseBtn 2.5s ease-in-out infinite;
}

#floatingDownload:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 36px var(--accent-glow);
}

@keyframes pulseBtn {

  0%,
  100% {
    box-shadow: 0 6px 28px var(--accent-glow);
  }

  50% {
    box-shadow: 0 6px 44px rgba(124, 106, 255, .7);
  }
}

/* ── Image Converter ───────────────────────────────────────────────────────── */
.conv-drop {
  border: 2px dashed var(--border2);
  border-radius: 14px;
  padding: 44px 24px;
  text-align: center;
  cursor: pointer;
  transition: all .3s ease;
  background: var(--surface2);
  position: relative;
}

.conv-drop:hover,
.conv-drop.over {
  border-color: var(--accent);
  background: rgba(124, 106, 255, .05);
}

.conv-drop:focus-within {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

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

.conv-drop .drop-icon {
  background: linear-gradient(135deg, rgba(124, 106, 255, .18), rgba(106, 255, 219, .1));
}

.conv-fmt-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.conv-fmt-btn {
  padding: 8px 22px;
  border-radius: 100px;
  border: 1px solid var(--border2);
  background: var(--surface2);
  color: var(--muted2);
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all .2s ease;
}

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

.conv-fmt-btn.active {
  background: rgba(124, 106, 255, .15);
  border-color: var(--accent);
  color: #fff;
  box-shadow: 0 0 14px var(--accent-glow);
}

.conv-fmt-btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.conv-quality-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
}

.conv-quality-label {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--muted2);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  white-space: nowrap;
}

.conv-quality-row input[type=range] {
  flex: 1;
  accent-color: var(--accent);
}

.conv-quality-val {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--teal);
  min-width: 36px;
  text-align: right;
}

.conv-preview-wrap {
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border);
  margin-bottom: 16px;
}

.conv-preview-head {
  padding: 10px 14px;
  background: rgba(124, 106, 255, .07);
  border-bottom: 1px solid var(--border);
  font-family: var(--mono);
  font-size: 11px;
  color: var(--muted2);
  display: flex;
  align-items: center;
  gap: 8px;
}

.conv-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 4px;
}

@media(max-width:580px) {
  .conv-actions {
    flex-direction: column;
  }

  .conv-fmt-row {
    gap: 6px;
  }
}

/* ── Scrollbar styling ─────────────────────────────────────────────────────── */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: var(--surface);
}

::-webkit-scrollbar-thumb {
  background: var(--border2);
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--accent);
}

/* ── Selection ─────────────────────────────────────────────────────────────── */
::selection {
  background: rgba(124, 106, 255, .35);
  color: #fff;
}

/* ── SPA Views ─────────────────────────────────────────────────────────────── */
.view {
  display: none;
}

.view.active {
  display: block;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ═════════ HERO FINAL FIX ═════════ */

.hero {
  min-height: 85vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 20px 20px;
  margin-bottom: -40px;
}

.hero-content {
  max-width: 900px;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero h1 {
  font-size: 52px;
  line-height: 1.2;
  margin-bottom: 20px;
}

.accent {
  color: var(--teal);
  -webkit-text-fill-color: var(--teal);
}

.hero-sub {
  font-size: 16px;
  color: var(--muted);
  margin-bottom: 25px;
}

.hero-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.hero-actions button {
  background: var(--teal);
  color: #000;
  border: none;
  padding: 12px 18px;
  border-radius: 10px;
  font-weight: bold;
  cursor: pointer;
}

.hero-actions .secondary {
  background: transparent;
  color: var(--teal);
  border: 1px solid var(--teal);
}

.hero-trust {
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 20px;
}

.hero-steps {
  display: flex;
  gap: 16px;
  margin-bottom: 10px;
  flex-wrap: wrap;
  justify-content: center;
}

.hero-steps .step {
  background: rgba(255, 255, 255, 0.03);
  padding: 8px 12px;
  border-radius: 10px;
  font-size: 13px;
  color: var(--muted);
}

.hero-steps span {
  background: var(--teal);
  color: #000;
  padding: 3px 6px;
  border-radius: 6px;
  margin-right: 6px;
}

.hero-example {
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 15px;
}

.scroll-down {
  font-size: 12px;
  color: var(--muted);
  opacity: 0.7;
  animation: bounce 1.5s infinite;
}

@keyframes bounce {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(6px);
  }
}

/* smooth transition */
.hero-divider {
  height: 1px;
  width: 60%;
  margin: 20px auto;
  background: linear-gradient(to right, transparent, var(--border), transparent);
  opacity: 0.5;
}

.hero-fade {
  height: 80px;
  width: 100%;
  background: linear-gradient(to bottom,
      rgba(10, 10, 15, 0) 0%,
      rgba(10, 10, 15, 1) 100%);
}

/* mobile */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 32px;
  }
}

.action-section {
  margin-top: -40px;
  padding-top: 40px;
}

.section-title {
  text-align: center;
  font-size: 18px;
  margin-bottom: 20px;
  color: var(--muted);
}

/* ── Password input ───────────────────────────────────────────────────────── */
.password-section {
  position: relative;
}

.password-inp {
  background: var(--surface2) !important;
  border: 1px solid rgba(255, 184, 106, .22) !important;
  transition: border-color .2s, box-shadow .2s;
}

.password-inp:focus {
  border-color: var(--amber) !important;
  box-shadow: 0 0 0 3px rgba(255, 184, 106, .18) !important;
}

.password-inp::placeholder {
  color: var(--muted2);
}

.password-warn {
  margin-top: 6px;
  font-family: var(--mono);
  font-size: 10px;
  color: var(--amber);
  opacity: .75;
  letter-spacing: .3px;
  line-height: 1.4;
}