/* =========================================================
   PrivatePhotoSuite — Design System v2
   Aesthetic: Dark editorial-brutalist luxury
   Fonts: Clash Display (display) + DM Sans (body)
   ========================================================= */

@import url('https://api.fontshare.com/v2/css?f[]=clash-display@400,500,600,700&f[]=dm-sans@300,400,500&display=swap');

/* ── Root tokens ──────────────────────────────────────── */
:root {
  --bg:          #0A0A0A;
  --bg2:         #111111;
  --bg3:         #181818;
  --surface:     #1C1C1C;
  --surface2:    #242424;
  --surface3:    #2E2E2E;
  --border:      rgba(255,255,255,.07);
  --border2:     rgba(255,255,255,.13);

  --ink:         #F8F8F8;
  --ink2:        #9A9A9A;
  --ink3:        #555555;

  --lime:        #C8FF00;
  --lime-dim:    rgba(200,255,0,.1);
  --lime-border: rgba(200,255,0,.25);
  --red:         #FF3B30;
  --blue:        #0A84FF;
  --amber:       #FF9F0A;

  --radius-sm:  6px;
  --radius:     10px;
  --radius-lg:  16px;
  --radius-xl:  22px;

  --font-display: 'Clash Display', 'Syne', sans-serif;
  --font-body:    'DM Sans', sans-serif;

  --ease:       cubic-bezier(.4,0,.2,1);
  --transition: .18s var(--ease);
  --shadow:     0 1px 3px rgba(0,0,0,.5), 0 8px 32px rgba(0,0,0,.4);
  --shadow-lg:  0 4px 6px rgba(0,0,0,.6), 0 24px 64px rgba(0,0,0,.5);

  --page-max: 1280px;
  --page-pad: clamp(1.25rem, 5vw, 3rem);
}

/* ── Reset ────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}
a { color: inherit; text-decoration: none; }
button { font-family: var(--font-body); cursor: pointer; border: none; background: none; }
input, select, textarea { font-family: var(--font-body); }
img { display: block; max-width: 100%; }
p { color: var(--ink2); line-height: 1.7; }
h1,h2,h3,h4,h5,h6 { font-family: var(--font-display); color: var(--ink); line-height: 1.1; }

/* ── Layout ───────────────────────────────────────────── */
.page-wrap { max-width: var(--page-max); margin: 0 auto; padding: 0 var(--page-pad); }
.hidden { display: none !important; }
.flex { display: flex; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.gap-1 { gap: .5rem; }
.gap-2 { gap: 1rem; }
.gap-3 { gap: 1.5rem; }
.mt-1 { margin-top: .5rem; }
.mt-2 { margin-top: 1rem; }
.mb-2 { margin-bottom: 1rem; }
.w-full { width: 100%; }

/* ── Navigation ───────────────────────────────────────── */
#site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10,10,10,.9);
  backdrop-filter: blur(24px) saturate(160%);
  -webkit-backdrop-filter: blur(24px) saturate(160%);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 0 var(--page-pad);
  height: 62px;
  display: flex;
  align-items: center;
  gap: 2rem;
}
.nav-logo { display: flex; align-items: center; gap: .6rem; flex-shrink: 0; }
.nav-logo-mark {
  width: 32px; height: 32px;
  background: var(--lime);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.nav-logo-mark svg { width: 16px; height: 16px; color: #000; }
.nav-logo-text {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: .975rem;
  letter-spacing: -.02em;
  color: var(--ink);
}
.nav-logo-text em { font-style: normal; color: var(--lime); }

.nav-links { display: flex; align-items: center; gap: .1rem; flex: 1; }
.nav-link {
  padding: .42rem .85rem;
  border-radius: var(--radius-sm);
  font-size: .85rem;
  font-weight: 500;
  color: var(--ink2);
  transition: color var(--transition), background var(--transition);
  white-space: nowrap;
}
.nav-link:hover { color: var(--ink); background: var(--surface); }
.nav-link.active { color: var(--ink); }

/* Mega dropdown */
.nav-dropdown { position: relative; }
.nav-dropdown-trigger {
  display: flex; align-items: center; gap: .3rem;
  padding: .42rem .85rem;
  border-radius: var(--radius-sm);
  font-size: .85rem;
  font-weight: 500;
  color: var(--ink2);
  cursor: pointer;
  transition: color var(--transition), background var(--transition);
  user-select: none;
}
.nav-dropdown-trigger svg { width: 13px; height: 13px; transition: transform .2s; }
.nav-dropdown:hover .nav-dropdown-trigger { color: var(--ink); background: var(--surface); }
.nav-dropdown:hover .nav-dropdown-trigger svg { transform: rotate(180deg); }

.nav-mega {
  position: absolute;
  top: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%) translateY(-6px);
  background: var(--bg2);
  border: 1px solid var(--border2);
  border-radius: var(--radius-xl);
  padding: 1rem;
  width: 640px;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  pointer-events: none;
  transition: opacity .15s, transform .15s;
}
.nav-dropdown:hover .nav-mega {
  opacity: 1;
  pointer-events: all;
  transform: translateX(-50%) translateY(0);
}
.nav-mega-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: .2rem;
}
.nav-mega-item {
  display: flex; align-items: center; gap: .65rem;
  padding: .6rem .7rem;
  border-radius: var(--radius-sm);
  transition: background var(--transition);
}
.nav-mega-item:hover { background: var(--surface); }
.nav-mega-icon {
  width: 30px; height: 30px;
  background: var(--surface2);
  border-radius: 7px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  color: var(--lime);
}
.nav-mega-icon svg { width: 14px; height: 14px; }
.nav-mega-name { font-size: .78rem; font-weight: 600; color: var(--ink); line-height: 1.2; }
.nav-mega-sub { font-size: .68rem; color: var(--ink3); }

.nav-mega-section { padding: .35rem .7rem .25rem; font-size: .65rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--ink3); }

.nav-cta { margin-left: auto; }

/* Mobile nav */
.nav-mobile-btn {
  display: none;
  align-items: center; justify-content: center;
  width: 38px; height: 38px;
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--ink);
  margin-left: auto;
}
.mobile-panel {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 200;
  background: var(--bg);
  overflow-y: auto;
  padding: 0 var(--page-pad) 2rem;
}
.mobile-panel.open { display: block; }
.mobile-panel-head {
  height: 62px;
  display: flex; align-items: center; justify-content: space-between;
  border-bottom: 1px solid var(--border);
  margin-bottom: 1rem;
}
.mobile-section { font-size: .65rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--ink3); padding: 1.25rem 0 .5rem; }
.mobile-link {
  display: flex; align-items: center; gap: .75rem;
  padding: .8rem 0;
  font-size: .9rem;
  font-weight: 500;
  color: var(--ink2);
  border-bottom: 1px solid var(--border);
}
.mobile-link svg { width: 16px; height: 16px; color: var(--lime); }

@media (max-width: 860px) {
  .nav-links, .nav-cta { display: none; }
  .nav-mobile-btn { display: flex; }
}

/* ── Buttons ──────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  padding: .65rem 1.4rem;
  border-radius: var(--radius-sm);
  font-size: .85rem;
  font-weight: 600;
  letter-spacing: -.01em;
  transition: all var(--transition);
  cursor: pointer;
  white-space: nowrap;
  text-decoration: none;
  line-height: 1;
}
.btn svg { width: 15px; height: 15px; flex-shrink: 0; }

.btn-primary {
  background: var(--lime);
  color: #000;
  border: 1.5px solid var(--lime);
}
.btn-primary:hover {
  background: #d9ff1a;
  border-color: #d9ff1a;
  transform: translateY(-1px);
  box-shadow: 0 6px 24px rgba(200,255,0,.3);
}

.btn-ghost {
  background: transparent;
  color: var(--ink2);
  border: 1.5px solid var(--border2);
}
.btn-ghost:hover { border-color: var(--ink3); color: var(--ink); background: var(--surface); }

.btn-dark {
  background: var(--surface2);
  color: var(--ink);
  border: 1.5px solid var(--border2);
}
.btn-dark:hover { background: var(--surface3); border-color: var(--ink3); }

.btn-danger { background: var(--red); color: #fff; border: 1.5px solid var(--red); }
.btn-danger:hover { background: #ff5247; }

.btn-sm { padding: .42rem .85rem; font-size: .78rem; }
.btn-lg { padding: .85rem 1.9rem; font-size: .95rem; }
.btn-xl { padding: 1rem 2.4rem; font-size: 1rem; letter-spacing: -.02em; }

/* ── USP strip (on every page) ────────────────────────── */
.usp-strip {
  background: var(--bg2);
  border-bottom: 1px solid var(--border);
  padding: .65rem var(--page-pad);
  display: flex; align-items: center; justify-content: center;
  gap: clamp(1rem, 4vw, 3.5rem);
  flex-wrap: wrap;
  overflow: hidden;
}
.usp-item {
  display: flex; align-items: center; gap: .5rem;
  font-size: .75rem;
  font-weight: 600;
  color: var(--ink3);
  white-space: nowrap;
}
.usp-item-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--lime); flex-shrink: 0; }
.usp-item strong { color: var(--ink2); }

/* ── Tool page hero header ────────────────────────────── */
.tool-header {
  padding: 2.5rem 0 2rem;
  border-bottom: 1px solid var(--border);
}
.tool-badge {
  display: inline-flex; align-items: center; gap: .35rem;
  background: var(--lime-dim);
  border: 1px solid var(--lime-border);
  border-radius: 99px;
  padding: .28rem .8rem;
  font-size: .68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .09em;
  color: var(--lime);
  margin-bottom: .9rem;
}
.tool-header h1 {
  font-size: clamp(1.75rem, 4vw, 2.6rem);
  letter-spacing: -.04em;
  margin-bottom: .5rem;
}
.tool-tagline { font-size: .95rem; color: var(--ink2); max-width: 520px; margin-bottom: 1.1rem; }
.tool-usp-row { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.tool-usp-chip {
  display: flex; align-items: center; gap: .4rem;
  padding: .3rem .8rem;
  background: var(--surface);
  border: 1px solid var(--border2);
  border-radius: 99px;
  font-size: .72rem;
  font-weight: 600;
  color: var(--ink2);
}
.tool-usp-chip::before { content: ''; width: 5px; height: 5px; border-radius: 50%; background: var(--lime); flex-shrink: 0; }

/* ── Tool card (main interface) ───────────────────────── */
.tool-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  overflow: hidden;
  margin: 2rem 0;
}
.tool-card-body {
  padding: 1.75rem;
  border-bottom: 1px solid var(--border);
}
.tool-card-body:last-child { border-bottom: none; }
.editor-actions {
  padding: 1.25rem 1.75rem;
  display: flex; align-items: center; gap: .75rem; flex-wrap: wrap;
  background: var(--surface);
}

/* ── Upload zone ──────────────────────────────────────── */
.upload-zone {
  border: 1.5px dashed var(--border2);
  border-radius: var(--radius-lg);
  padding: 3.5rem 2rem;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition);
  position: relative;
  background: var(--bg3);
}
.upload-zone::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: var(--radius-lg);
  background: radial-gradient(ellipse 50% 35% at 50% 0%, rgba(200,255,0,.05), transparent);
  pointer-events: none;
}
.upload-zone:hover, .upload-zone.drag-over {
  border-color: var(--lime);
  background: rgba(200,255,0,.04);
}
.upload-zone__input { display: none; }
.upload-zone__icon {
  width: 52px; height: 52px;
  background: var(--surface2);
  border: 1px solid var(--border2);
  border-radius: 13px;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 1.25rem;
  color: var(--lime);
  transition: border-color var(--transition), background var(--transition);
}
.upload-zone:hover .upload-zone__icon { border-color: var(--lime-border); background: var(--lime-dim); }
.upload-zone__icon svg { width: 22px; height: 22px; }
.upload-zone__title {
  font-family: var(--font-display);
  font-size: 1.1rem; font-weight: 600;
  color: var(--ink);
  margin-bottom: .4rem;
}
.upload-zone__sub { font-size: .82rem; color: var(--ink3); margin-bottom: 1.1rem; }
.upload-zone__chips { display: flex; gap: .4rem; justify-content: center; flex-wrap: wrap; margin-bottom: 1.1rem; }
.upload-zone__chip {
  padding: .25rem .65rem;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 99px;
  font-size: .7rem; font-weight: 600; color: var(--ink3);
}
.upload-zone__privacy {
  font-size: .72rem; color: var(--ink3);
  display: flex; align-items: center; justify-content: center; gap: .4rem;
}
.upload-zone__privacy::before {
  content: ''; width: 5px; height: 5px; background: var(--lime); border-radius: 50%;
}

/* ── Form elements ────────────────────────────────────── */
.form-group { margin-bottom: 1.2rem; }
.form-label {
  display: block;
  font-size: .68rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .08em;
  color: var(--ink3);
  margin-bottom: .45rem;
}
.form-input, .form-select {
  width: 100%;
  padding: .6rem .85rem;
  background: var(--surface);
  border: 1.5px solid var(--border2);
  border-radius: var(--radius-sm);
  font-size: .875rem;
  color: var(--ink);
  transition: border-color var(--transition), box-shadow var(--transition);
  outline: none;
}
.form-input:focus, .form-select:focus {
  border-color: var(--lime);
  box-shadow: 0 0 0 3px rgba(200,255,0,.1);
}
.form-select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23555' d='M6 8L0 0h12z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right .85rem center;
  padding-right: 2.2rem;
  cursor: pointer;
}
textarea.form-input { resize: vertical; min-height: 80px; }

/* Toggle buttons */
.toggle-group {
  display: flex;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--border2);
  overflow: hidden;
}
.toggle-btn {
  flex: 1;
  padding: .48rem .65rem;
  font-size: .76rem; font-weight: 600;
  color: var(--ink3);
  background: transparent;
  transition: all var(--transition);
  white-space: nowrap;
  border: none; cursor: pointer;
}
.toggle-btn + .toggle-btn { border-left: 1px solid var(--border2); }
.toggle-btn.active { background: var(--lime); color: #000; }
.toggle-btn:hover:not(.active) { background: var(--surface); color: var(--ink); }

/* Sliders */
.slider-row { display: flex; align-items: center; gap: .75rem; }
.slider-row input[type="range"] {
  flex: 1; height: 3px;
  -webkit-appearance: none; appearance: none;
  background: var(--surface3); border-radius: 2px; outline: none; cursor: pointer;
}
.slider-row input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 15px; height: 15px;
  border-radius: 50%; background: var(--lime); cursor: pointer;
  box-shadow: 0 0 0 3px rgba(200,255,0,.2);
}
.slider-val { font-size: .78rem; font-weight: 700; color: var(--lime); min-width: 28px; text-align: right; font-family: var(--font-display); }

/* File list */
.file-list { display: flex; flex-direction: column; gap: .4rem; }
.file-item {
  display: flex; align-items: center; gap: .7rem;
  padding: .55rem .7rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}
.file-thumb { width: 34px; height: 34px; object-fit: cover; border-radius: 5px; flex-shrink: 0; }
.file-info { flex: 1; min-width: 0; }
.file-name { font-size: .78rem; font-weight: 600; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.file-size { font-size: .68rem; color: var(--ink3); }
.file-remove { padding: .25rem; border-radius: 4px; color: var(--ink3); background: none; border: none; cursor: pointer; transition: all var(--transition); }
.file-remove:hover { color: var(--red); background: rgba(255,59,48,.1); }

/* Savings badge */
.savings-badge {
  padding: .18rem .55rem;
  background: rgba(200,255,0,.12);
  border: 1px solid var(--lime-border);
  border-radius: 99px;
  font-size: .68rem; font-weight: 700; color: var(--lime);
}

/* Capacity bar */
.capacity-bar-wrap { display: flex; align-items: center; gap: .7rem; margin-bottom: 1rem; }
.capacity-bar { flex: 1; height: 3px; background: var(--surface3); border-radius: 2px; overflow: hidden; }
.capacity-bar-fill { height: 100%; background: var(--lime); border-radius: 2px; transition: width .3s; }
.capacity-label { font-size: .72rem; color: var(--ink3); font-weight: 600; white-space: nowrap; }

/* ── SEO content ──────────────────────────────────────── */
.seo-content { max-width: 680px; padding: 3rem 0 5rem; border-top: 1px solid var(--border); margin-top: 2rem; }
.seo-content h2 { font-size: 1.15rem; margin-bottom: .7rem; margin-top: 1.75rem; letter-spacing: -.025em; }
.seo-content h2:first-child { margin-top: 0; }
.seo-content p { font-size: .875rem; margin-bottom: .7rem; }

/* FAQ */
.faq-accordion { display: flex; flex-direction: column; gap: .4rem; }
.faq-accordion details {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.faq-accordion summary {
  padding: .8rem 1rem;
  font-size: .85rem; font-weight: 600;
  cursor: pointer; list-style: none;
  display: flex; align-items: center; justify-content: space-between;
  color: var(--ink);
  user-select: none;
}
.faq-accordion summary::after { content: '+'; font-size: 1rem; color: var(--lime); font-family: var(--font-display); }
.faq-accordion details[open] summary::after { content: '−'; }
.faq-accordion details p { padding: 0 1rem .9rem; font-size: .82rem; }

/* ── Breadcrumb ───────────────────────────────────────── */
.breadcrumb { padding: 1.25rem 0 0; }
.breadcrumb ol { display: flex; flex-wrap: wrap; gap: .3rem; align-items: center; list-style: none; }
.breadcrumb li { font-size: .72rem; color: var(--ink3); }
.breadcrumb li a { color: var(--ink3); transition: color var(--transition); }
.breadcrumb li a:hover { color: var(--lime); }
.breadcrumb li + li::before { content: '/'; margin-right: .3rem; }

/* ── Toast ────────────────────────────────────────────── */
#toast-container { position: fixed; bottom: 1.5rem; right: 1.5rem; z-index: 9999; display: flex; flex-direction: column-reverse; gap: .5rem; }
.toast {
  display: flex; align-items: center; gap: .55rem;
  padding: .65rem 1rem;
  border-radius: var(--radius);
  font-size: .78rem; font-weight: 600;
  box-shadow: var(--shadow-lg);
  animation: slideUp .2s var(--ease);
  min-width: 200px; max-width: 320px;
}
.toast-success { background: var(--lime); color: #000; }
.toast-error { background: #160808; border: 1px solid rgba(255,59,48,.35); color: var(--red); }
.toast-info { background: var(--surface2); border: 1px solid var(--border2); color: var(--ink); }
@keyframes slideUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

/* ── Cookie banner ────────────────────────────────────── */
.cookie-banner {
  position: fixed; bottom: 1.5rem; left: 1.5rem;
  z-index: 9998; max-width: 360px;
  background: var(--bg2);
  border: 1px solid var(--border2);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  box-shadow: var(--shadow-lg);
  display: none;
}
.cookie-banner.visible { display: block; animation: slideUp .25s var(--ease); }
.cookie-banner p { font-size: .78rem; margin-bottom: 1rem; }
.cookie-banner-actions { display: flex; gap: .5rem; }

/* ── Footer ───────────────────────────────────────────── */
#site-footer { border-top: 1px solid var(--border); margin-top: 4rem; }
.footer-inner {
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 3rem var(--page-pad) 2rem;
  display: grid;
  grid-template-columns: 1.5fr repeat(3, 1fr);
  gap: 3rem;
}
.footer-tagline { font-size: .8rem; color: var(--ink3); line-height: 1.65; max-width: 210px; margin: .75rem 0 1rem; }
.footer-usp-list { display: flex; flex-direction: column; gap: .35rem; }
.footer-usp-item { display: flex; align-items: center; gap: .45rem; font-size: .72rem; font-weight: 600; color: var(--ink3); }
.footer-usp-item::before { content: ''; width: 4px; height: 4px; border-radius: 50%; background: var(--lime); flex-shrink: 0; }
.footer-col-title { font-size: .62rem; font-weight: 700; text-transform: uppercase; letter-spacing: .12em; color: var(--ink3); margin-bottom: .85rem; }
.footer-links { display: flex; flex-direction: column; gap: .45rem; }
.footer-links a { font-size: .8rem; color: var(--ink3); transition: color var(--transition); }
.footer-links a:hover { color: var(--lime); }
.footer-bottom {
  max-width: var(--page-max); margin: 0 auto;
  padding: 1.1rem var(--page-pad);
  border-top: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .5rem;
}
.footer-bottom p { font-size: .72rem; color: var(--ink3); }
@media (max-width: 768px) { .footer-inner { grid-template-columns: 1fr 1fr; gap: 2rem; } }
@media (max-width: 480px) { .footer-inner { grid-template-columns: 1fr; } }

/* ── Spinner ──────────────────────────────────────────── */
.spinner { width: 30px; height: 30px; border: 2.5px solid var(--surface3); border-top-color: var(--lime); border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Tab group ────────────────────────────────────────── */
.tab-group { display: flex; border-bottom: 1px solid var(--border); }
.tab-btn {
  padding: .55rem 1rem;
  font-size: .78rem; font-weight: 600;
  color: var(--ink3);
  background: none; border: none;
  border-bottom: 2px solid transparent;
  cursor: pointer; margin-bottom: -1px;
  transition: all var(--transition); white-space: nowrap;
}
.tab-btn.active { color: var(--lime); border-bottom-color: var(--lime); }
.tab-btn:hover:not(.active) { color: var(--ink); }

/* ── Editor layout ────────────────────────────────────── */
.editor-layout { display: grid; grid-template-columns: 270px 1fr; }
.editor-sidebar { border-right: 1px solid var(--border); padding: 1.25rem; overflow-y: auto; max-height: 600px; }
.editor-main { background: var(--bg3); display: flex; align-items: center; justify-content: center; padding: 1.5rem; min-height: 280px; }
.sidebar-section { margin-bottom: 1.4rem; }
.sidebar-section-label { font-size: .62rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--ink3); margin-bottom: .65rem; }
@media (max-width: 640px) {
  .editor-layout { grid-template-columns: 1fr; }
  .editor-sidebar { border-right: none; border-bottom: 1px solid var(--border); max-height: none; }
}

/* ── Compare slider ───────────────────────────────────── */
.compare-wrap { position: relative; display: inline-block; overflow: hidden; border-radius: var(--radius); user-select: none; touch-action: none; }
.compare-wrap canvas { display: block; }
.compare-line { position: absolute; top: 0; bottom: 0; width: 2px; background: var(--lime); pointer-events: none; }
.compare-handle {
  position: absolute; top: 50%;
  width: 34px; height: 34px;
  background: var(--lime); border-radius: 50%;
  transform: translate(-50%, -50%);
  display: flex; align-items: center; justify-content: center;
  pointer-events: none; color: #000;
  box-shadow: 0 2px 12px rgba(200,255,0,.4);
}

/* ── Badge compat ─────────────────────────────────────── */
.badge {
  display: inline-flex; align-items: center; gap: .3rem;
  padding: .28rem .7rem;
  border-radius: 99px;
  font-size: .68rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .07em;
}
.badge--edit    { background: rgba(10,132,255,.12); border: 1px solid rgba(10,132,255,.28); color: var(--blue); }
.badge--convert { background: rgba(255,159,10,.1); border: 1px solid rgba(255,159,10,.25); color: var(--amber); }
.badge--privacy { background: var(--lime-dim); border: 1px solid var(--lime-border); color: var(--lime); }
.badge--create  { background: rgba(255,59,48,.1); border: 1px solid rgba(255,59,48,.22); color: var(--red); }
.badge--utility { background: var(--surface2); border: 1px solid var(--border2); color: var(--ink2); }

/* trust-chip compat */
.trust-chip { display: inline-flex; align-items: center; gap: .35rem; padding: .28rem .65rem; background: var(--surface); border: 1px solid var(--border2); border-radius: 99px; font-size: .7rem; font-weight: 600; color: var(--ink2); }
.trust-chips { display: flex; flex-wrap: wrap; gap: .45rem; }
.chip { padding: .22rem .6rem; background: var(--surface2); border: 1px solid var(--border); border-radius: 99px; font-size: .68rem; font-weight: 600; color: var(--ink3); }

/* ── Tool grid (all-tools page) ───────────────────────── */
.tools-category { margin-bottom: 3rem; }
.tools-category-label {
  display: flex; align-items: center; gap: .75rem;
  margin-bottom: 1rem;
  font-size: .65rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .12em;
  color: var(--ink3);
}
.tools-category-label::after { content: ''; flex: 1; height: 1px; background: var(--border); }
.tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  overflow: hidden;
}
.tool-tile {
  background: var(--bg2);
  padding: 1.35rem;
  display: flex; flex-direction: column; gap: .65rem;
  text-decoration: none;
  position: relative;
  transition: background var(--transition);
}
.tool-tile::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 80% at 0% 0%, rgba(200,255,0,.05), transparent 60%);
  opacity: 0;
  transition: opacity var(--transition);
}
.tool-tile:hover { background: var(--surface); }
.tool-tile:hover::after { opacity: 1; }
.tool-tile-icon {
  width: 38px; height: 38px;
  border: 1px solid var(--border2);
  border-radius: 9px;
  display: flex; align-items: center; justify-content: center;
  background: var(--surface2);
  color: var(--lime);
  position: relative; z-index: 1;
  transition: border-color var(--transition);
}
.tool-tile:hover .tool-tile-icon { border-color: var(--lime-border); }
.tool-tile-icon svg { width: 16px; height: 16px; }
.tool-tile-name { font-family: var(--font-display); font-size: .85rem; font-weight: 600; color: var(--ink); line-height: 1.25; position: relative; z-index: 1; }
.tool-tile-desc { font-size: .72rem; color: var(--ink3); line-height: 1.5; flex: 1; position: relative; z-index: 1; }
.tool-tile-arrow { font-size: .68rem; font-weight: 700; color: var(--ink3); position: relative; z-index: 1; letter-spacing: .02em; transition: color var(--transition); }
.tool-tile:hover .tool-tile-arrow { color: var(--lime); }

/* ── Responsive ───────────────────────────────────────── */
@media (max-width: 640px) {
  .tool-card-body { padding: 1.25rem; }
  .editor-actions { padding: 1rem 1.25rem; }
  .upload-zone { padding: 2.5rem 1.25rem; }
  .tool-header h1 { font-size: 1.7rem; }
}
