:root {
  --bg: #080b12;
  --panel: rgba(18, 23, 36, 0.9);
  --panel-strong: #111725;
  --border: rgba(255, 255, 255, 0.09);
  --text: #f1f4fa;
  --muted: #8e99aa;
  --cyan: #23f4ee;
  --pink: #ff3e75;
  --blue: #6277ff;
  --green: #2ee59d;
  --green-bg: rgba(46, 229, 157, 0.075);
  --green-border: rgba(46, 229, 157, 0.33);
  --red: #ff5b75;
  --red-bg: rgba(255, 67, 96, 0.075);
  --red-border: rgba(255, 91, 117, 0.34);
  --yellow: #ffc86d;
  --yellow-bg: rgba(255, 190, 72, 0.08);
  --shadow: 0 18px 55px rgba(0, 0, 0, 0.3);
  --select-width: 48px;
  --index-width: 58px;
  --status-width: 104px;
  --account-width: 220px;
}

* { box-sizing: border-box; }
html { color-scheme: dark; }
body {
  min-width: 360px;
  min-height: 100vh;
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: 0.46; }
a { color: inherit; }
.hidden, [hidden] { display: none !important; }

.ambient {
  position: fixed;
  z-index: -1;
  width: 520px;
  height: 520px;
  border-radius: 50%;
  opacity: 0.11;
  filter: blur(95px);
  pointer-events: none;
}
.ambient-one { top: -240px; left: -220px; background: var(--cyan); }
.ambient-two { top: 180px; right: -230px; background: #7d52ff; }

.topbar {
  position: sticky;
  z-index: 30;
  top: 0;
  display: flex;
  min-height: 78px;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border-bottom: 1px solid var(--border);
  background: rgba(8, 11, 18, 0.88);
  padding: 10px 30px;
  backdrop-filter: blur(16px);
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: inherit;
  text-decoration: none;
}
.brand-mark {
  display: grid;
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 13px;
  background: linear-gradient(140deg, var(--cyan), var(--blue) 46%, var(--pink));
  box-shadow: 0 8px 25px rgba(50, 222, 236, 0.2);
}
.brand-mark span {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 10px;
  background: #0d111b;
  font-size: 12px;
  font-weight: 950;
}
.brand strong { display: block; font-size: 16px; letter-spacing: -0.02em; }
.brand small { display: block; margin-top: 3px; color: var(--muted); font-size: 11px; }
.topbar-actions { display: flex; align-items: center; gap: 9px; }
.topbar-link,
.topbar-button {
  min-height: 36px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.025);
  color: #c2cad6;
  padding: 8px 11px;
  font-size: 11px;
  font-weight: 720;
  text-decoration: none;
}
.topbar-link:hover,
.topbar-button:hover { border-color: rgba(98, 119, 255, 0.38); background: rgba(98, 119, 255, 0.1); color: white; }
.connection-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.025);
  color: #aab3c1;
  padding: 7px 11px;
  font-size: 10px;
  letter-spacing: 0.04em;
}
.connection-badge i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #7b8492;
}
.connection-badge.checking i { animation: badge-pulse 1s ease-in-out infinite; }
.connection-badge.online { border-color: var(--green-border); color: #8be2b8; }
.connection-badge.online i { background: var(--green); box-shadow: 0 0 10px var(--green); }
.connection-badge.locked { border-color: var(--red-border); color: #ff9aac; }
.connection-badge.locked i { background: var(--red); }
@keyframes badge-pulse { 50% { opacity: 0.35; } }

.panel {
  border: 1px solid var(--border);
  border-radius: 20px;
  background: var(--panel);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
}
.eyebrow { color: #8ea0ff; font-size: 10px; font-weight: 850; letter-spacing: 0.14em; }

.auth-shell {
  display: grid;
  width: min(100% - 28px, 880px);
  min-height: calc(100vh - 79px);
  margin: 0 auto;
  place-items: center;
  padding: 42px 0 72px;
}
.auth-card {
  display: grid;
  width: 100%;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 24px 26px;
  padding: clamp(28px, 6vw, 52px);
}
.auth-symbol {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border: 1px solid rgba(98, 119, 255, 0.34);
  border-radius: 18px;
  background: rgba(98, 119, 255, 0.11);
  color: #b7c0ff;
  font-size: 28px;
  font-weight: 900;
}
.auth-copy h1 { margin: 8px 0 10px; font-size: clamp(34px, 7vw, 58px); letter-spacing: -0.055em; line-height: 1; }
.auth-copy p { max-width: 610px; margin: 0; color: var(--muted); font-size: 14px; line-height: 1.65; }
.auth-form {
  display: grid;
  grid-column: 1 / -1;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  margin-top: 10px;
}
.auth-form > label { grid-column: 1 / -1; color: #b7bfcc; font-size: 12px; font-weight: 750; }
.auth-input-wrap,
.input-wrap {
  display: flex;
  align-items: center;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #0b0f18;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.auth-input-wrap:focus-within,
.input-wrap:focus-within { border-color: rgba(35, 244, 238, 0.52); box-shadow: 0 0 0 3px rgba(35, 244, 238, 0.07); }
.auth-input-wrap input,
.input-wrap input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: white;
  padding: 12px 13px;
}
input::placeholder,
textarea::placeholder { color: #596477; }
.icon-button {
  align-self: stretch;
  border: 0;
  border-left: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.025);
  color: #a7b0bd;
  padding: 0 13px;
  font-size: 11px;
}
.icon-button:hover { background: rgba(255, 255, 255, 0.065); color: white; }
.form-status { grid-column: 1 / -1; min-height: 18px; margin: 2px 0 0; color: var(--muted); font-size: 12px; }
.form-status.error { color: #ff9aac; }
.form-status.loading { color: #aab5ff; }
.remember-note {
  grid-column: 1 / -1;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.022);
  padding: 14px 16px;
}
.remember-note strong { font-size: 12px; }
.remember-note p { margin: 5px 0 0; color: var(--muted); font-size: 11px; line-height: 1.55; }

.page-shell { width: min(96%, 1560px); margin: 24px auto 60px; }
.hero {
  position: relative;
  display: flex;
  min-height: 235px;
  align-items: center;
  justify-content: space-between;
  gap: 38px;
  overflow: hidden;
  padding: 38px 42px;
}
.hero::after {
  position: absolute;
  top: -170px;
  right: -100px;
  width: 310px;
  height: 310px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 50%;
  box-shadow: 0 0 0 45px rgba(255, 255, 255, 0.015), 0 0 0 90px rgba(255, 255, 255, 0.01);
  content: "";
}
.hero h1 { max-width: 850px; margin: 11px 0 12px; font-size: clamp(36px, 4.5vw, 62px); letter-spacing: -0.055em; line-height: 0.98; }
.hero h1 em { color: #a6afbd; font-style: normal; }
.hero p { max-width: 720px; margin: 0; color: var(--muted); font-size: 13px; line-height: 1.65; }
.hero p code,
.guide-item code { color: #8ef8e7; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.hero-stats {
  z-index: 1;
  display: grid;
  min-width: 390px;
  grid-template-columns: repeat(3, minmax(110px, 1fr));
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 18px;
}
.hero-stats div { border-right: 1px solid var(--border); background: rgba(255, 255, 255, 0.025); padding: 20px 17px; text-align: center; }
.hero-stats div:last-child { border-right: 0; }
.hero-stats strong { display: block; font-size: 28px; }
.hero-stats span { color: var(--muted); font-size: 10px; letter-spacing: 0.08em; text-transform: uppercase; }

.workspace-grid { display: grid; grid-template-columns: minmax(0, 1fr) 320px; align-items: start; gap: 20px; margin-top: 20px; }
.controls-panel,
.guide-panel { padding: 25px; }
.guide-panel { position: sticky; top: 98px; }
.section-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.section-heading > div { display: flex; align-items: center; gap: 10px; }
.section-heading h2 { margin: 0; font-size: 14px; }
.token-heading > div { align-items: flex-start; }
.token-heading p { margin: 4px 0 0; color: var(--muted); font-size: 11px; }
.step {
  display: grid;
  width: 29px;
  height: 29px;
  flex: 0 0 auto;
  place-items: center;
  border: 1px solid rgba(98, 119, 255, 0.25);
  border-radius: 9px;
  background: rgba(98, 119, 255, 0.12);
  color: #aeb8ff;
  font-size: 10px;
  font-weight: 800;
}
.text-button { border: 0; background: transparent; color: #8fa1ff; padding: 6px; font-size: 11px; text-decoration: none; }
.text-button:hover { color: white; }

.token-list { display: grid; gap: 9px; margin-top: 16px; }
.token-item {
  display: grid;
  grid-template-columns: 154px minmax(0, 1fr);
  align-items: center;
  gap: 8px 13px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: rgba(8, 12, 20, 0.52);
  padding: 11px 12px;
}
.token-item[data-configured="true"] { border-color: rgba(46, 229, 157, 0.2); }
.token-label { min-width: 0; }
.token-label b { display: block; font-size: 11px; letter-spacing: 0.04em; }
.token-saved-state { display: block; overflow: hidden; margin-top: 4px; color: #718094; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.token-item[data-configured="true"] .token-saved-state { color: #78d9aa; }
.token-controls { display: flex; min-width: 0; gap: 8px; }
.input-wrap.grow { min-width: 0; flex: 1 1 auto; }
.token-limit {
  display: flex;
  min-width: 0;
  grid-column: 2;
  align-items: flex-start;
  gap: 7px;
  color: var(--muted);
  font-size: 10.5px;
  line-height: 1.45;
}
.token-limit i,
.inline-status i {
  width: 7px;
  height: 7px;
  flex: 0 0 auto;
  margin-top: 4px;
  border-radius: 50%;
  background: #707b8c;
}
.token-limit.ready { color: #9ba6b6; }
.token-limit.ready i { background: #718094; }
.token-limit.checking { color: #adb7ff; }
.token-limit.checking i { background: #8fa1ff; animation: badge-pulse 0.9s ease-in-out infinite; }
.token-limit.success { color: #7fe3b3; }
.token-limit.success i { background: var(--green); }
.token-limit.error { color: #ff9aac; }
.token-limit.error i { background: var(--red); }
.token-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 9px; margin-top: 13px; }
.inline-status { display: inline-flex; align-items: flex-start; gap: 7px; margin-left: 3px; color: var(--muted); font-size: 11px; }
.inline-status.success { color: #7fe3b3; }
.inline-status.success i { background: var(--green); }
.inline-status.warning { color: var(--yellow); }
.inline-status.warning i { background: var(--yellow); }
.inline-status.error { color: #ff9aac; }
.inline-status.error i { background: var(--red); }
.limit-disclaimer { margin: 11px 0 0; color: #778397; font-size: 10.5px; line-height: 1.55; }
.divider { height: 1px; margin: 28px 0; background: var(--border); }
.account-heading { margin-bottom: 12px; }
.counter { color: var(--muted); font-size: 12px; }
.counter.limit { color: var(--red); font-weight: 750; }

.textarea-wrap { overflow: hidden; border: 1px solid var(--border); border-radius: 16px; background: #0b0f18; transition: border-color 0.2s, box-shadow 0.2s; }
.textarea-wrap:focus-within { border-color: rgba(35, 244, 238, 0.55); box-shadow: 0 0 0 3px rgba(35, 244, 238, 0.08); }
.line-hint { display: flex; height: 34px; align-items: center; border-bottom: 1px solid var(--border); background: rgba(255, 255, 255, 0.018); color: #6f7c8f; padding: 0 15px; font-size: 10px; font-weight: 800; letter-spacing: 0.12em; }
textarea { width: 100%; min-height: 290px; max-height: 620px; resize: vertical; border: 0; outline: 0; background: transparent; color: #eef2f9; padding: 15px; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; line-height: 1.65; }
.parser-status { margin-top: 9px; color: var(--muted); font-size: 11px; }
.parser-status.detected { color: #75e8b0; }
.parser-status.warning { color: #ffbd7b; }
.parser-status.error { color: #ff8da0; font-weight: 700; line-height: 1.5; }
.actions { display: flex; gap: 10px; margin-top: 16px; }

.button {
  border: 1px solid transparent;
  border-radius: 12px;
  color: white;
  padding: 12px 16px;
  font-weight: 750;
  white-space: nowrap;
  transition: transform 0.15s, background 0.15s, border-color 0.15s;
}
.button:active:not(:disabled) { transform: translateY(1px); }
.button-primary { flex: 1; background: linear-gradient(100deg, #5269ff, #7b5cff); box-shadow: 0 10px 28px rgba(94, 91, 255, 0.2); letter-spacing: 0.02em; }
.button-primary:hover { background: linear-gradient(100deg, #6278ff, #896aff); }
.button-secondary { border-color: rgba(98, 119, 255, 0.35); background: rgba(98, 119, 255, 0.11); color: #cbd2ff; }
.button-secondary:hover { background: rgba(98, 119, 255, 0.18); }
.button-ghost { border-color: var(--border); background: rgba(255, 255, 255, 0.025); color: #bac3d0; }
.button-ghost:hover { background: rgba(255, 255, 255, 0.055); }
.button.compact { flex: 0 0 auto; border-radius: 10px; box-shadow: none; padding: 9px 11px; font-size: 11px; }
.clear-token { color: #ff91a2; }
.button-icon { margin-right: 7px; }
.cost-note { margin: 12px 0 0; color: #6f7b8e; font-size: 11px; }

.guide-panel > .eyebrow { display: block; margin-bottom: 18px; }
.guide-item { display: flex; gap: 12px; border-bottom: 1px solid var(--border); padding: 13px 0; }
.guide-icon { display: grid; width: 34px; height: 34px; flex: 0 0 auto; place-items: center; border-radius: 10px; font-weight: 900; }
.success-guide .guide-icon { border: 1px solid var(--green-border); background: var(--green-bg); color: var(--green); }
.error-guide .guide-icon { border: 1px solid var(--red-border); background: var(--red-bg); color: var(--red); }
.copy-guide .guide-icon { border: 1px solid rgba(98, 119, 255, 0.3); background: rgba(98, 119, 255, 0.1); color: #aab5ff; }
.pipe-guide .guide-icon { border: 1px solid rgba(35, 244, 238, 0.28); background: rgba(35, 244, 238, 0.08); color: var(--cyan); font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.limit-guide .guide-icon { border: 1px solid rgba(255, 190, 72, 0.3); background: rgba(255, 190, 72, 0.09); color: var(--yellow); }
.guide-item strong { font-size: 13px; }
.guide-item p { margin: 3px 0 0; color: var(--muted); font-size: 12px; line-height: 1.45; }
.privacy-box { margin-top: 20px; border: 1px solid var(--border); border-radius: 14px; background: rgba(255, 255, 255, 0.025); padding: 15px; }
.privacy-box strong { font-size: 12px; }
.privacy-box p { margin: 6px 0 0; color: var(--muted); font-size: 11px; line-height: 1.55; }

.progress-panel { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 15px 18px; margin-top: 20px; padding: 20px 23px; }
.spinner { width: 36px; height: 36px; border: 3px solid rgba(255, 255, 255, 0.09); border-top-color: var(--cyan); border-right-color: var(--pink); border-radius: 50%; animation: spin 0.85s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.progress-copy { display: flex; flex-direction: column; }
.progress-title-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.progress-copy strong { font-size: 14px; }
.progress-title-row b { color: #e8ebff; font-size: 18px; font-variant-numeric: tabular-nums; }
.progress-copy > span { margin-top: 3px; color: var(--muted); font-size: 12px; }
.progress-track { grid-column: 1 / -1; height: 9px; overflow: hidden; border-radius: 99px; background: rgba(255, 255, 255, 0.06); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.025); }
.progress-track div { width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--cyan), var(--blue), var(--pink)); box-shadow: 0 0 18px rgba(98, 119, 255, 0.38); transition: width 0.35s ease; }
.progress-meta { display: flex; grid-column: 1 / -1; align-items: center; gap: 9px; color: var(--muted); font-size: 11px; }
.progress-meta > span { border: 1px solid var(--border); border-radius: 999px; background: rgba(255, 255, 255, 0.022); padding: 5px 8px; }
.progress-meta #progressPercent { min-width: 52px; color: white; font-weight: 850; text-align: center; }
.progress-meta #progressBatch { margin-right: auto; }
.progress-result.success { border-color: var(--green-border); background: var(--green-bg); color: #7fe3b3; }
.progress-result.error { border-color: var(--red-border); background: var(--red-bg); color: #ff9aac; }
.progress-result b { color: white; }

.results-section { margin-top: 20px; }
.results-toolbar { display: flex; align-items: center; gap: 12px; padding: 18px 21px; }
.results-title h2 { margin: 3px 0 0; font-size: 19px; }
.summary-chips { display: flex; gap: 8px; margin-left: auto; }
.summary-chip { border: 1px solid var(--border); border-radius: 999px; color: var(--muted); padding: 7px 10px; font-size: 11px; }
.summary-chip b { margin-right: 3px; color: white; }
.success-chip { border-color: var(--green-border); background: var(--green-bg); color: #7fe3b3; }
.error-chip { border-color: var(--red-border); background: var(--red-bg); color: #ff9aac; }
.duplicate-notice { margin: 12px 3px; color: #d7b86d; font-size: 12px; }

.table-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 12px; padding: 12px; }
.filter-tools { display: flex; gap: 9px; }
.search-box,
.select-box { display: flex; height: 40px; align-items: center; overflow: hidden; border: 1px solid var(--border); border-radius: 10px; background: #0c111b; }
.search-box span,
.select-box span { color: #758195; padding-left: 11px; font-size: 10px; font-weight: 800; letter-spacing: 0.08em; }
.search-box input,
.select-box select { height: 100%; border: 0; outline: 0; background: transparent; color: #e9edf5; padding: 0 11px; font-size: 11px; }
.search-box input { width: 210px; }
.select-box select { min-width: 135px; }
.selection-info { color: var(--muted); font-size: 11px; white-space: nowrap; }
.selection-info b { color: white; }
.bulk-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 7px; margin-left: auto; }

.table-panel { overflow: hidden; margin-top: 12px; border-radius: 16px; }
.table-scroll { position: relative; width: 100%; max-height: 680px; overflow: auto; }
.result-table { width: max-content; min-width: 100%; border-collapse: separate; border-spacing: 0; table-layout: fixed; font-size: 11px; }
.result-table th,
.result-table td { border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); padding: 9px 10px; vertical-align: middle; }
.result-table th:last-child,
.result-table td:last-child { border-right: 0; }
.result-table thead th { position: sticky; z-index: 8; background: #151c2a; color: #b7c0ce; font-size: 9px; letter-spacing: 0.055em; text-align: center; text-transform: uppercase; }
.result-table thead .group-row th { top: 0; height: 38px; }
.result-table thead .column-row th { top: 38px; height: 38px; background: #111824; }
.video-group { color: #9da9ff !important; }
.result-table tbody tr { --row-bg: #101622; }
.result-table tbody tr.row-success { --row-bg: #0d1c1a; }
.result-table tbody tr.row-error { --row-bg: #20131a; }
.result-table tbody td { background: var(--row-bg); color: #d5dbe5; }
.result-table tbody tr:hover td { filter: brightness(1.14); }
.result-table tbody tr[hidden] { display: none; }
.result-table tbody tr.live-arrival { animation: live-row-arrival 0.48s ease-out; }
@keyframes live-row-arrival {
  0% { opacity: 0.25; transform: translateY(-5px); }
  55% { opacity: 1; }
  100% { opacity: 1; transform: translateY(0); }
}
.sticky-col { position: sticky; z-index: 5; }
thead .sticky-col { z-index: 14 !important; }
.col-select { left: 0; width: var(--select-width); min-width: var(--select-width); max-width: var(--select-width); text-align: center; }
.col-index { left: var(--select-width); width: var(--index-width); min-width: var(--index-width); max-width: var(--index-width); color: #8e9aad !important; text-align: center; }
.col-status { left: calc(var(--select-width) + var(--index-width)); width: var(--status-width); min-width: var(--status-width); max-width: var(--status-width); text-align: center; }
.col-account { left: calc(var(--select-width) + var(--index-width) + var(--status-width)); width: var(--account-width); min-width: var(--account-width); max-width: var(--account-width); box-shadow: 7px 0 12px rgba(0, 0, 0, 0.14); }
.col-followers { width: 112px; min-width: 112px; }
.link-cell { width: 260px; min-width: 260px; max-width: 260px; }
.number-cell { width: 88px; min-width: 88px; text-align: right; font-variant-numeric: tabular-nums; }
.date-cell { width: 125px; min-width: 125px; color: #9ba6b6 !important; white-space: nowrap; }
.col-note { width: 240px; min-width: 240px; max-width: 240px; }
.col-note span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.col-actions { width: 152px; min-width: 152px; }
.empty-cell { width: 260px; min-width: 260px; color: #606a79 !important; text-align: center; }
.account-cell { min-width: 0; }
.account-cell strong { display: block; overflow: hidden; color: #f1f4f8; text-overflow: ellipsis; white-space: nowrap; }
.account-cell a,
.account-cell span { display: block; overflow: hidden; margin-top: 3px; color: #93a4ff; text-decoration: none; text-overflow: ellipsis; white-space: nowrap; }
.account-cell a:hover { text-decoration: underline; }
.status-pill { display: inline-flex; min-width: 72px; align-items: center; justify-content: center; border-radius: 999px; padding: 5px 7px; font-size: 9px; font-weight: 900; letter-spacing: 0.04em; }
.status-pill.success { border: 1px solid var(--green-border); background: var(--green-bg); color: #72e6b0; }
.status-pill.error { border: 1px solid var(--red-border); background: var(--red-bg); color: #ff8da0; }
.follower-value { color: #f3f5fb !important; font-size: 12px; font-weight: 800; }
.link-content { display: flex; min-width: 0; align-items: center; gap: 7px; }
.link-content a { min-width: 0; flex: 1; overflow: hidden; color: #b6c2ff; text-decoration: none; text-overflow: ellipsis; white-space: nowrap; }
.link-content a:hover { color: white; text-decoration: underline; }
.cell-copy { border: 1px solid var(--border); border-radius: 7px; background: rgba(255, 255, 255, 0.035); color: #c4cbd6; padding: 5px 7px; font-size: 9px; white-space: nowrap; }
.cell-copy:hover:not(:disabled) { background: rgba(255, 255, 255, 0.09); color: white; }
.row-actions { display: flex; gap: 5px; }
.request-error { background: var(--red-bg) !important; color: #ff9aac !important; padding: 28px !important; text-align: center; }
.empty-filter { background: #101622; color: var(--muted); padding: 32px; text-align: center; }
.table-tip { margin: 9px 3px 0; color: #6f7b8e; font-size: 11px; }
.result-table input[type="checkbox"] { width: 16px; height: 16px; accent-color: #6f72ff; }
.table-scroll::-webkit-scrollbar { width: 12px; height: 12px; }
.table-scroll::-webkit-scrollbar-track { background: #0a0e16; }
.table-scroll::-webkit-scrollbar-thumb { border: 3px solid #0a0e16; border-radius: 999px; background: #30394a; }
.table-scroll::-webkit-scrollbar-thumb:hover { background: #465268; }

.menu-trigger span { margin-left: 4px; color: #8f9aab; font-size: 10px; }
.menu-trigger[aria-expanded="true"] { border-color: rgba(98, 119, 255, 0.5); background: rgba(98, 119, 255, 0.17); color: white; }
.video-copy-menu {
  position: fixed;
  z-index: 80;
  width: 286px;
  border: 1px solid rgba(145, 158, 255, 0.28);
  border-radius: 15px;
  background: rgba(15, 20, 31, 0.98);
  box-shadow: 0 22px 65px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.025) inset;
  padding: 8px;
  backdrop-filter: blur(18px);
}
.video-copy-menu-head { margin-bottom: 5px; border-bottom: 1px solid var(--border); padding: 9px 10px 10px; }
.video-copy-menu-head strong { display: block; color: #f3f5fb; font-size: 12px; }
.video-copy-menu-head span { display: block; margin-top: 3px; color: var(--muted); font-size: 10px; }
.video-copy-option { display: flex; width: 100%; min-height: 54px; align-items: center; justify-content: space-between; gap: 14px; border: 0; border-radius: 10px; background: transparent; color: #e9edf7; padding: 8px 10px; text-align: left; }
.video-copy-option:hover:not(:disabled),
.video-copy-option:focus-visible:not(:disabled) { outline: 0; background: rgba(98, 119, 255, 0.14); }
.video-copy-option + .video-copy-option { margin-top: 2px; }
.video-copy-option > span { display: flex; min-width: 0; flex-direction: column; }
.video-copy-option b { font-size: 12px; }
.video-copy-option small { margin-top: 3px; color: var(--muted); font-size: 10px; }
.video-copy-option em { min-width: 58px; flex: 0 0 auto; border: 1px solid rgba(98, 119, 255, 0.24); border-radius: 999px; background: rgba(98, 119, 255, 0.09); color: #bdc6ff; padding: 5px 7px; font-size: 9px; font-style: normal; font-weight: 800; text-align: center; }
.video-copy-option:disabled { opacity: 0.38; }

.toast {
  position: fixed;
  z-index: 90;
  bottom: 26px;
  left: 50%;
  max-width: min(90vw, 640px);
  border-radius: 12px;
  background: #f1f4fa;
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.38);
  color: #10141d;
  opacity: 0;
  padding: 11px 15px;
  font-size: 12px;
  font-weight: 700;
  pointer-events: none;
  text-align: center;
  transform: translate(-50%, 20px);
  transition: opacity 0.2s, transform 0.2s;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.error { background: #ffdde3; color: #7c1628; }

@media (max-width: 1120px) {
  .workspace-grid { grid-template-columns: 1fr; }
  .guide-panel { position: static; }
  .hero { align-items: flex-start; flex-direction: column; }
  .hero-stats { width: 100%; min-width: 0; grid-template-columns: repeat(3, 1fr); }
  .bulk-actions { width: 100%; justify-content: flex-start; margin-left: 0; }
}

@media (max-width: 760px) {
  .page-shell { width: min(100% - 18px, 1560px); margin-top: 12px; }
  .topbar { min-height: 68px; padding: 10px 13px; }
  .brand small,
  .connection-badge span,
  .topbar-link { display: none; }
  .connection-badge { width: 30px; height: 30px; justify-content: center; padding: 0; }
  .hero { padding: 25px 20px; }
  .hero h1 { font-size: 36px; }
  .hero-stats strong { font-size: 22px; }
  .controls-panel,
  .guide-panel { padding: 18px; }
  .token-heading { align-items: flex-start; flex-direction: column; }
  .token-item { grid-template-columns: 1fr; }
  .token-controls { grid-column: 1; }
  .token-limit { grid-column: 1; }
  .token-label { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
  .token-saved-state { margin-top: 0; }
  .actions,
  .results-toolbar { flex-wrap: wrap; }
  .actions .button { flex: 1 1 100%; }
  .summary-chips { order: 4; width: 100%; margin-left: 0; }
  .filter-tools { width: 100%; flex-direction: column; }
  .search-box,
  .select-box { width: 100%; }
  .search-box input { width: 100%; }
  .bulk-actions .button { flex: 1 1 auto; }
  .auth-form { grid-template-columns: 1fr; }
  .auth-form .button { width: 100%; }
  :root { --account-width: 190px; }
}

@media (max-width: 520px) {
  .brand-mark { width: 36px; height: 36px; }
  .brand-mark span { width: 29px; height: 29px; font-size: 10px; }
  .brand strong { font-size: 14px; }
  .topbar-button { max-width: 130px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .auth-card { grid-template-columns: 1fr; gap: 18px; padding: 24px 20px; }
  .auth-symbol { width: 48px; height: 48px; }
  .auth-copy { grid-column: 1; }
  .auth-copy h1 { font-size: 39px; }
  .hero-stats div { padding: 15px 8px; }
  .token-controls { flex-wrap: wrap; }
  .token-controls .input-wrap { flex-basis: 100%; }
  .token-controls .clear-token { width: 100%; }
  .progress-meta { flex-wrap: wrap; }
  .progress-meta #progressBatch { width: 100%; margin-right: 0; }
}

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