/* ═══════════════════════════════════════════════════════════════
   RemoveVocals — Audio Toolkit
   Premium, modern design inspired by Linear, Vercel, Raycast
   ═══════════════════════════════════════════════════════════════ */

/* Font loaded via <link> in HTML head for faster rendering */

:root {
  --bg:           #17171e;
  --bg-deep:      #121119;
  --surface:      #1e1e28;
  --surface-2:    #272836;
  --surface-3:    #2f2f42;
  --border:       #2c2d36;
  --border-focus: #665dc3;

  --text:         #eee;
  --text-2:       #d8d8e2;
  --text-muted:   #a8a8b8;
  --icon:         #706f7b;

  --purple:       #665dc3;
  --purple-2:     #7c6dd8;
  --purple-light: #8b5cf6;
  --red:          #ff424d;
  --green:        #4fb071;
  --yellow:       #eed409;
  --blue:         #6c8bd5;
  --orange:       #f4812e;

  --radius:       10px;
  --radius-lg:    16px;
  --radius-pill:  32px;
  --transition:   0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  position: relative;
  font-feature-settings: 'cv05' 1, 'cv06' 1;
}

/* Animated mesh gradient background */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(ellipse at 20% 50%, rgba(102, 93, 195, 0.08) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 20%, rgba(139, 92, 246, 0.06) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 80%, rgba(79, 176, 113, 0.04) 0%, transparent 50%);
  animation: meshShift 20s ease-in-out infinite alternate;
}

@keyframes meshShift {
  0% { transform: scale(1) translate(0, 0); }
  50% { transform: scale(1.1) translate(-2%, 3%); }
  100% { transform: scale(1) translate(2%, -2%); }
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; }

/* ─── FORM INPUTS (dark theme) ─────────────────────────────── */
input[type="text"],
input[type="number"],
input[type="email"],
input[type="search"],
input[type="url"],
input[type="tel"],
select,
textarea {
  background: var(--bg-deep);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 8px;
  padding: 8px 12px;
  font-size: 14px;
  outline: none;
  transition: border-color var(--transition);
}
input[type="text"]:focus,
input[type="number"]:focus,
select:focus,
textarea:focus {
  border-color: var(--purple);
  box-shadow: 0 0 0 2px rgba(102,93,195,.15);
}
input[type="text"]::placeholder,
input[type="number"]::placeholder {
  color: var(--icon);
}

select {
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23909090' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  padding-right: 32px;
}

/* ─── CUSTOM CHECKBOX ─────────────────────────────────────── */
input[type="checkbox"] {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  border: 1.5px solid var(--border);
  border-radius: 4px;
  background: var(--bg-deep);
  cursor: pointer;
  position: relative;
  flex-shrink: 0;
  transition: all var(--transition);
}
input[type="checkbox"]:checked {
  background: var(--purple);
  border-color: var(--purple);
}
input[type="checkbox"]:checked::after {
  content: '';
  position: absolute;
  left: 5px;
  top: 2px;
  width: 5px;
  height: 9px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

/* ─── SVG ICON SIZING ─────────────────────────────────────── */
.icon-sm svg { width: 16px; height: 16px; }
.icon-md svg { width: 20px; height: 20px; }
.icon-lg svg { width: 24px; height: 24px; }
.icon-xl svg { width: 36px; height: 36px; }
.upload-zone .icon svg { width: 48px; height: 48px; opacity: .45; }
.btn-play svg { width: 16px; height: 16px; }
.tool-card .ic svg { width: 24px; height: 24px; }

/* ─── TOPBAR / NAV ─────────────────────────────────────────── */
.topbar {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  height: 56px;
  padding: 0 20px;
  background: rgba(23, 23, 30, 0.7);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(102, 93, 195, 0.15);
}

.topbar .logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 18px;
  color: var(--text);
  text-decoration: none;
  margin-right: 32px;
  flex-shrink: 0;
}
.topbar .logo svg { width: 26px; height: 26px; }

.topbar-nav {
  display: flex;
  align-items: center;
  gap: 2px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  flex: 1;
}
.topbar-nav::-webkit-scrollbar { display: none; }

.topbar-nav a {
  padding: 8px 14px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
  white-space: nowrap;
  transition: color var(--transition), background var(--transition);
  position: relative;
}
.topbar-nav a:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.05);
}
.topbar-nav a.active {
  color: var(--purple);
  background: rgba(102, 93, 195, 0.1);
  position: relative;
}
.topbar-nav a.active::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 50%;
  transform: translateX(-50%);
  width: 4px;
  height: 4px;
  background: var(--purple);
  border-radius: 50%;
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  flex-shrink: 0;
}

.hamburger {
  display: none;
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 22px;
  padding: 6px;
}

/* ─── MOBILE MENU ──────────────────────────────────────────── */
.mobile-overlay {
  display: none;
  position: fixed;
  inset: 56px 0 0 0;
  background: var(--bg);
  z-index: 99;
  flex-direction: column;
  padding: 12px;
  overflow-y: auto;
}
.mobile-overlay.open { display: flex; }
.mobile-overlay a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border-radius: var(--radius);
  color: var(--text-muted);
  font-size: 15px;
  transition: all var(--transition);
}
.mobile-overlay a:hover,
.mobile-overlay a.active {
  color: var(--text);
  background: var(--surface);
}

/* ─── PAGE LAYOUT ──────────────────────────────────────────── */
/* ─── PAGE LAYOUT ──────────────────────────────────────────── */

.page {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 48px 20px 80px;
  min-height: calc(100vh - 56px);
  text-align: center;
}

.page-title {
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 800;
  text-align: center;
  margin-bottom: 10px;
  letter-spacing: -0.03em;
  line-height: 1.15;
  max-width: 720px;
}

.page-subtitle {
  font-size: 16px;
  color: var(--text-muted);
  text-align: center;
  margin-bottom: 36px;
  max-width: 520px;
  line-height: 1.6;
}

/* ─── UPLOAD AREA ──────────────────────────────────────────── */
.upload-card {
  width: 100%;
  max-width: 620px;
  background: rgba(30, 30, 40, 0.6);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(102, 93, 195, 0.2);
  border-radius: var(--radius-lg);
  padding: 32px;
  text-align: center;
}

.upload-zone {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 24px;
  border: 2px dashed rgba(102, 93, 195, 0.3);
  border-radius: var(--radius);
  cursor: pointer;
  transition: all var(--transition);
  min-height: 180px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.upload-zone::before {
  content: '';
  position: absolute;
  width: 60px;
  height: 60px;
  background: radial-gradient(circle, rgba(102, 93, 195, 0.2) 0%, transparent 70%);
  border-radius: 50%;
  animation: orbFloat 8s ease-in-out infinite;
  pointer-events: none;
}

@keyframes orbFloat {
  0%, 100% { transform: translate(0, 0); opacity: 0.5; }
  50% { transform: translate(10px, -10px); opacity: 0.8; }
}

.upload-zone:hover,
.upload-zone.dragover {
  border-color: var(--purple);
  background: rgba(102, 93, 195, 0.08);
}

.upload-zone.dragover {
  animation: pulse 0.5s ease;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.02); }
}
.upload-zone .icon { margin-bottom: 12px; line-height: 1; }
.upload-zone p { color: var(--text-muted); font-size: 14px; }
.upload-zone p:first-of-type { margin-bottom: 4px; }
.upload-zone .hint { font-size: 13px; color: var(--icon); margin-top: 8px; }

.choose-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 16px;
  padding: 8px 28px;
  border-radius: var(--radius-pill);
  border: none;
  background: linear-gradient(135deg, #665dc3, #7c6dd8);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  transition: all var(--transition);
  cursor: pointer;
}
.choose-btn:hover {
  transform: scale(1.02);
  box-shadow: 0 4px 20px rgba(102, 93, 195, 0.3);
}
.choose-btn:active {
  transform: scale(0.98);
}

.upload-formats {
  margin-top: 16px;
  font-size: 13px;
  color: var(--text-muted);
  padding-top: 16px;
  border-top: 1px solid var(--border);
  text-align: center;
}
.upload-formats strong { color: var(--text-2); }

.file-input { display: none; }

/* ─── WORKSPACE (appears after upload) ─────────────────────── */
.workspace {
  width: 100%;
  max-width: 800px;
  margin: 0 auto;
}

.card {
  background: rgba(30, 30, 40, 0.6);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(102, 93, 195, 0.15);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 12px;
  transition: all var(--transition);
}

.card:hover {
  background: rgba(30, 30, 40, 0.8);
  border-color: rgba(102, 93, 195, 0.25);
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}
.card-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: .4px;
}

/* ─── WAVEFORM ─────────────────────────────────────────────── */
/* Waveform wrapper with seek support */
.wf-wrap {
  position: relative;
  width: 100%;
  height: 80px;
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
}

.wf-wrap::before,
.wf-wrap::after {
  content: '';
  position: absolute;
  top: 0;
  width: 40px;
  height: 100%;
  z-index: 1;
  pointer-events: none;
}

.wf-wrap::before {
  left: 0;
  background: linear-gradient(to right, var(--surface), transparent);
}

.wf-wrap::after {
  right: 0;
  background: linear-gradient(to left, var(--surface), transparent);
}

canvas.waveform {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(18, 17, 25, 0.8) 0%, rgba(30, 30, 40, 0.6) 100%);
}
.wf-head {
  position: absolute;
  top: 0; bottom: 0;
  left: 0;
  width: 2px;
  background: #fff;
  pointer-events: none;
  z-index: 2;
  transition: none;
  box-shadow: 0 0 6px rgba(255,255,255,.4);
}
.wf-hover {
  position: absolute;
  top: 0; bottom: 0;
  left: -1px;
  width: 1px;
  background: rgba(255,255,255,.3);
  pointer-events: none;
  z-index: 1;
  opacity: 0;
  transition: opacity .15s;
}
.wf-wrap:hover .wf-hover { opacity: 1; }
.wf-time-tip {
  position: absolute;
  top: 4px;
  left: 0;
  transform: translateX(-50%);
  background: rgba(0,0,0,.8);
  color: #fff;
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 4px;
  pointer-events: none;
  z-index: 3;
  opacity: 0;
  transition: opacity .15s;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.wf-wrap:hover .wf-time-tip { opacity: 1; }

/* ─── CONTROLS ─────────────────────────────────────────────── */
.controls {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 16px;
  flex-wrap: wrap;
}

.btn-play {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  background: var(--purple);
  color: #fff;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
  flex-shrink: 0;
}
.btn-play:hover { background: var(--purple-2); transform: scale(1.05); }

.time {
  font-size: 13px;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
  min-width: 80px;
}

/* ─── BUTTONS ──────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 20px;
  border-radius: var(--radius-pill);
  border: none;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  white-space: nowrap;
}
.btn:disabled { opacity: 0.35; pointer-events: none; }

.btn-primary {
  background: linear-gradient(135deg, #665dc3, #7c6dd8);
  color: #fff;
}
.btn-primary:hover {
  transform: scale(1.02);
  box-shadow: 0 4px 20px rgba(102, 93, 195, 0.3);
}
.btn-primary:active {
  transform: scale(0.98);
}

.btn-outline {
  background: transparent;
  color: var(--text);
  border: 1.5px solid rgba(102, 93, 195, 0.3);
}
.btn-outline:hover {
  border-color: var(--purple);
  color: var(--purple);
  background: rgba(102, 93, 195, 0.05);
}

.btn-ghost {
  background: rgba(39, 40, 54, 0.6);
  color: var(--text-2);
  border: none;
}
.btn-ghost:hover {
  background: rgba(47, 47, 66, 0.8);
  color: var(--text);
}

.btn-sm { padding: 6px 14px; font-size: 13px; }

.btn-icon {
  width: 36px;
  height: 36px;
  padding: 0;
  border-radius: 50%;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
}
.btn-icon:hover { background: var(--surface-3); color: var(--text); border-color: var(--purple); }

.btn-danger { background: var(--red); color: #fff; }
.btn-success { background: var(--green); color: #fff; }

/* ─── SLIDER ───────────────────────────────────────────────── */
input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 4px;
  border-radius: 2px;
  background: var(--surface-3);
  outline: none;
}
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--purple);
  cursor: pointer;
  border: 2px solid var(--bg);
}
input[type="range"]::-moz-range-thumb {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--purple);
  cursor: pointer;
  border: 2px solid var(--bg);
}

.range-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 10px 0;
}
.range-row label {
  font-size: 13px;
  color: var(--text-muted);
  min-width: 80px;
  flex-shrink: 0;
}
.range-row input[type="range"] { flex: 1; }
.range-row .val {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  min-width: 55px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

/* ─── PROGRESS ─────────────────────────────────────────────── */
.progress {
  width: 100%;
  height: 3px;
  background: var(--surface-3);
  border-radius: 2px;
  overflow: hidden;
  margin: 12px 0;
}
.progress-bar {
  height: 100%;
  background: var(--purple);
  border-radius: 2px;
  width: 0%;
  transition: width .3s;
}
.progress-text {
  font-size: 13px;
  color: var(--text-muted);
  text-align: center;
}

/* ─── INFO STATS ───────────────────────────────────────────── */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
  margin: 16px 0;
}
.stat {
  background: var(--bg-deep);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  text-align: center;
}
.stat .number {
  font-size: 26px;
  font-weight: 700;
  color: var(--purple);
  line-height: 1.2;
}
.stat .label {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: .5px;
  margin-top: 4px;
}

/* ─── RESULTS GRID ─────────────────────────────────────────── */
.results {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 12px;
}

/* ─── TRACK LIST ───────────────────────────────────────────── */
.track-list { display: flex; flex-direction: column; gap: 6px; margin: 12px 0; }
.track-item {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--bg-deep);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 14px;
  cursor: grab;
  transition: border-color var(--transition);
}
.track-item:hover { border-color: var(--purple); }
.track-item.dragging { opacity: .5; }
.track-num { font-size: 13px; color: var(--text-muted); min-width: 20px; }
.track-name { flex: 1; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.track-dur { font-size: 13px; color: var(--text-muted); font-variant-numeric: tabular-nums; }
.track-rm {
  background: none;
  border: none;
  color: var(--icon);
  font-size: 16px;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 4px;
  transition: all var(--transition);
}
.track-rm:hover { color: var(--red); background: rgba(255,66,77,.1); }

/* ─── TOGGLE GROUP ─────────────────────────────────────────── */
.toggle-group {
  display: inline-flex;
  background: var(--bg-deep);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 3px;
}
.toggle-btn {
  padding: 6px 16px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  border-radius: 6px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition);
}
.toggle-btn.active { background: var(--purple); color: #fff; }
.toggle-btn:hover:not(.active) { color: var(--text); }

/* ─── CHECKBOX ─────────────────────────────────────────────── */
.check-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 6px 0;
}
.check-row input[type="checkbox"] {
  width: 18px;
  height: 18px;
}
.check-row label {
  font-size: 14px;
  color: var(--text-2);
  cursor: pointer;
}

/* ─── PRESETS ──────────────────────────────────────────────── */
.presets {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin: 8px 0;
}

/* ─── RECORDING ────────────────────────────────────────────── */
.rec-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--red);
  animation: recPulse 1s infinite;
}
@keyframes recPulse { 0%,100% { opacity: 1; } 50% { opacity: .3; } }

.rec-timer {
  font-size: 32px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  text-align: center;
  margin: 16px 0;
}

/* ─── CHROMA BAR CHART ─────────────────────────────────────── */
canvas.chroma {
  display: block;
  width: 100%;
  height: 120px;
  border-radius: 8px;
  background: var(--bg-deep);
}

/* ─── FOOTER ───────────────────────────────────────────────── */
.footer {
  text-align: center;
  padding: 32px 20px;
  border-top: 1px solid rgba(102, 93, 195, 0.1);
  color: var(--icon);
  font-size: 12px;
  margin-top: auto;
  font-weight: 500;
  letter-spacing: 0.3px;
}
.footer-rich {
  border-top: 1px solid rgba(102, 93, 195, 0.15);
  padding: 48px 20px 24px;
  margin-top: auto;
}
.footer-grid {
  max-width: 960px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1.2fr;
  gap: 32px;
}
.footer-col {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 16px;
  color: #fff;
  margin-bottom: 4px;
}
.footer-tagline {
  color: var(--text-muted);
  font-size: 12px;
  line-height: 1.6;
  margin: 0;
}
.footer-col h4 {
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  margin: 0 0 4px;
  letter-spacing: 0.02em;
}
.footer-col a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 12px;
  transition: color 0.2s;
  font-weight: 500;
}
.footer-col a:hover {
  color: var(--purple);
}
.footer-info {
  color: var(--text-muted);
  font-size: 12px;
  line-height: 1.6;
  margin: 0;
}
.footer-bottom {
  max-width: 960px;
  margin: 32px auto 0;
  padding-top: 20px;
  border-top: 1px solid rgba(102, 93, 195, 0.08);
  text-align: center;
}
.footer-bottom p {
  color: var(--icon);
  font-size: 11px;
  margin: 0;
  font-weight: 500;
}
@media (max-width: 768px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 24px; }
}
@media (max-width: 480px) {
  .footer-grid { grid-template-columns: 1fr; gap: 20px; }
}

/* ─── RELATED TOOLS ───────────────────────────────────────── */
.related-tools {
  text-align: left;
}
.related-tools h2 {
  font-size: clamp(18px, 2.5vw, 22px);
  font-weight: 800;
  margin-bottom: 16px;
  color: #fff;
}
.related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.related-card {
  background: rgba(30, 30, 40, 0.6);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(102, 93, 195, 0.15);
  border-radius: 12px;
  padding: 20px;
  text-decoration: none;
  transition: all 0.3s;
}
.related-card:hover {
  border-color: rgba(102, 93, 195, 0.35);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(102, 93, 195, 0.1);
}
.related-card h3 {
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  margin: 0 0 6px;
}
.related-card p {
  font-size: 12px;
  color: var(--text-muted);
  margin: 0;
  line-height: 1.5;
}
@media (max-width: 640px) {
  .related-grid { grid-template-columns: 1fr; }
}

/* ─── AD PLACEHOLDER ───────────────────────────────────────── */
.ad-slot {
  max-width: 728px;
  width: 100%;
  margin: 16px auto;
  min-height: 0;
}

/* ─── UTILITY ──────────────────────────────────────────────── */
.hidden { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }
.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.text-sm { font-size: 13px; }
.mt-8 { margin-top: 8px; }
.mt-12 { margin-top: 12px; }
.mt-16 { margin-top: 16px; }
.mb-12 { margin-bottom: 12px; }
.gap-8 { gap: 8px; }
.flex { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.flex-wrap { flex-wrap: wrap; }

/* ─── SEO FAQ SECTION ──────────────────────────────────────── */
.seo-faq { max-width: 800px; margin: 48px auto 0; padding: 0 20px; text-align: left; }
.seo-faq h2 { font-size: 24px; font-weight: 800; margin-bottom: 20px; color: var(--text); text-align: center; letter-spacing: -0.02em; }
.seo-faq details { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; margin-bottom: 8px; overflow: hidden; }
.seo-faq summary { padding: 14px 18px; cursor: pointer; font-weight: 600; font-size: 14px; color: var(--text); list-style: none; display: flex; align-items: center; justify-content: space-between; transition: all var(--transition); }
.seo-faq summary:hover { background: var(--surface-2); }
.seo-faq summary::after { content: '+'; color: var(--purple); font-size: 18px; transition: transform .2s ease; }
.seo-faq details[open] summary { background: var(--surface-2); }
.seo-faq details[open] summary::after { transform: rotate(45deg); }
.seo-faq p { padding: 0 18px 14px; color: var(--text-muted); font-size: 13px; line-height: 1.6; margin: 0; }
.seo-faq details[open] p { padding: 0 18px 14px; }

/* ─── CUSTOM SCROLLBAR ─────────────────────────────────────── */
::-webkit-scrollbar {
  width: 6px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: rgba(102, 93, 195, 0.4);
  border-radius: 3px;
}

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

/* ─── SELECTION ────────────────────────────────────────────── */
::selection {
  background: rgba(102, 93, 195, 0.3);
  color: #fff;
}

/* ─── BREADCRUMBS ─────────────────────────────────────────── */
.breadcrumbs {
  max-width: 960px;
  margin: 12px auto 0;
  padding: 0 20px;
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 500;
  text-align: center;
}
.breadcrumbs a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s;
}
.breadcrumbs a:hover {
  color: var(--purple);
}
.breadcrumbs a[aria-current="page"] {
  color: #fff;
  pointer-events: none;
}
.breadcrumbs span {
  margin: 0 6px;
  opacity: 0.5;
}

/* ─── HOW-TO GUIDE ────────────────────────────────────────── */
.how-to-guide {
  text-align: left;
}
.how-to-guide h2 {
  font-size: clamp(18px, 2.5vw, 24px);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
  color: #fff;
}
.how-to-guide p {
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.7;
}

/* ─── TOOL SECTION HEADING ────────────────────────────────── */
.tool-section-heading {
  font-size: 15px;
  font-weight: 500;
  color: var(--text-muted);
  margin: 0 0 12px;
  letter-spacing: 0.02em;
  text-align: center;
  text-transform: uppercase;
  font-size: 12px;
}

/* ─── ACCESSIBILITY - Skip Link ────────────────────────────── */
.skip-link {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}
.skip-link:focus-visible {
  position: fixed;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: auto;
  height: auto;
  clip: auto;
  margin: 0;
  overflow: visible;
  white-space: normal;
  background: var(--purple);
  color: #fff;
  padding: 12px 24px;
  border-radius: 0 0 8px 8px;
  z-index: 10000;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}

/* ─── ACCESSIBILITY - Focus Indicators ────────────────────────── */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--purple);
  outline-offset: 2px;
}

/* ─── ACCESSIBILITY - Reduced Motion ────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ─── ACCESSIBILITY - High Contrast Mode ────────────────────── */
@media (prefers-contrast: more) {
  :root {
    --border: #555;
  }
  .btn, .upload-card, .card {
    border-width: 2px;
  }
}

/* ─── RESPONSIVE ───────────────────────────────────────────── */
@media (max-width: 640px) {
  .topbar-nav { display: none; }
  .hamburger { display: block; }
  .page { padding: 32px 16px 60px; }
  .page-title { font-size: 24px; letter-spacing: -0.02em; }
  .upload-card { padding: 20px; }
  .card { padding: 18px; }
  .results { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr 1fr; }
  .controls { gap: 8px; }
  .seo-faq { padding: 0 16px; margin: 32px auto 0; }
  .related-grid { grid-template-columns: 1fr; }
}
