:root {
  color-scheme: light;
  --bg: #eef2ff;
  --panel: #fbfcff;
  --text: #263244;
  --muted: #657084;
  --line: #dfe5f1;
  --blue: #2f7df3;
  --purple: #8e3df0;
  --teal: #14b8a6;
  --orange: #f97316;
  --bad: #dc2626;
  --shadow: 0 14px 32px rgba(56, 72, 112, 0.14);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
}

button,
input,
textarea,
select {
  font: inherit;
}

.page {
  min-height: 100vh;
  padding: 0 16px 44px;
  background: linear-gradient(180deg, #eef2ff 0%, #f4f7ff 100%);
}

.topbar {
  position: relative;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  width: min(848px, 100%);
  margin: 0 auto;
  padding: 6px 0 16px;
}

.site-logo {
  grid-column: 2;
  color: #2b3447;
  font-size: clamp(20px, 3vw, 30px);
  font-weight: 950;
  letter-spacing: 0.08em;
  text-align: center;
}

.top-actions {
  grid-column: 3;
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 8px;
}

.top-link,
.language-select {
  min-height: 38px;
  border: 1px solid #cfd6e6;
  border-radius: 6px;
  background: #ffffff;
  color: #1f2a3d;
  box-shadow: 0 1px 3px rgba(25, 35, 55, 0.12);
}

.top-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px;
  text-decoration: none;
  font-size: 14px;
  font-weight: 800;
}

.language-select {
  padding: 0 12px;
  cursor: pointer;
}

.intro-card,
.service-card,
.status-strip,
.workspace {
  width: min(848px, 100%);
  margin-right: auto;
  margin-left: auto;
}

.intro-card,
.service-card,
.tool {
  border: 1px solid rgba(203, 213, 225, 0.8);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: var(--shadow);
}

.intro-card {
  margin-top: 0;
  padding: 40px 28px 32px;
  text-align: center;
}

.intro-card h1 {
  margin: 0;
  color: #7686ff;
  font-size: clamp(30px, 5vw, 36px);
  font-weight: 900;
  line-height: 1.1;
}

.intro-card p {
  margin: 10px 0 0;
  color: #536075;
  font-size: 17px;
}

.accent-line {
  width: 96px;
  height: 4px;
  margin: 20px auto 0;
  border-radius: 999px;
  background: linear-gradient(90deg, #2f7df3, #9b5df7);
}

.service-card {
  margin-top: 32px;
  padding: 34px 32px 32px;
  text-align: center;
}

.service-card h2 {
  margin: 0;
  color: #263244;
  font-size: clamp(22px, 3vw, 26px);
  line-height: 1.25;
}

.service-card p {
  margin: 16px 0 24px;
  color: var(--muted);
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.service-button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border-radius: 7px;
  color: #ffffff;
  font-weight: 850;
  text-decoration: none;
  box-shadow: 0 10px 20px rgba(64, 97, 170, 0.16);
}

.service-button span {
  font-size: 21px;
  line-height: 1;
}

.service-start {
  background: linear-gradient(135deg, #3b82f6, #8b5cf6);
}

.service-card-check {
  background: linear-gradient(135deg, #3b82f6, #2563eb);
}

.service-batch {
  background: linear-gradient(135deg, #a855f7, #9333ea);
}

.service-account {
  background: linear-gradient(135deg, #14b8a6, #0f9f91);
}

.service-replace {
  background: linear-gradient(135deg, #f97316, #ea580c);
}

.status-strip {
  display: none;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 34px;
}

.status-strip div {
  display: flex;
  min-height: 52px;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.68);
}

.status-strip span {
  color: var(--muted);
  font-size: 13px;
}

.status-strip strong {
  color: #263244;
  text-align: right;
  font-size: 14px;
}

.workspace {
  display: none;
  gap: 18px;
  margin-top: 18px;
  width: min(960px, 100%);
}

body.tools-open .status-strip,
body.tools-open .workspace {
  display: grid;
}

body.tools-open .status-strip {
  display: none;
}

.back-home {
  justify-self: start;
  min-height: 38px;
  border: 1px solid #d6deeb;
  border-radius: 7px;
  padding: 8px 14px;
  background: #ffffff;
  color: #4b5563;
  font-weight: 800;
  cursor: pointer;
}

.tabs {
  display: none;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}

.tab-button {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.74);
  color: var(--muted);
  cursor: pointer;
}

.tab-button.active {
  border-color: #7c8cff;
  background: #ffffff;
  color: #4f60db;
  font-weight: 800;
}

.tools {
  display: grid;
  gap: 18px;
}

.tool {
  display: none;
  overflow: hidden;
}

.tool.active {
  display: block;
}

#card.tool {
  border: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}

#token.tool {
  border: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}

#batch.tool {
  border: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}

#replace.tool {
  border: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}

.recharge-flow {
  border: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}

.flow-hero {
  border: 1px solid rgba(203, 213, 225, 0.8);
  border-radius: 10px;
  padding: 36px 24px 30px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: var(--shadow);
  text-align: center;
}

.flow-hero h2 {
  margin: 0;
  color: #7686ff;
  font-size: clamp(30px, 5vw, 36px);
  font-weight: 900;
}

.flow-hero p {
  margin: 10px 0 0;
  color: #536075;
  font-size: 17px;
}

.stock-alert {
  width: fit-content;
  margin: 26px 0 16px;
  border: 1px solid #6ee7b7;
  border-radius: 999px;
  padding: 7px 14px;
  background: #d1fae5;
  color: #047857;
  font-size: 14px;
  font-weight: 750;
}

.stock-alert.bad {
  border-color: #fecaca;
  background: #fee2e2;
  color: #b91c1c;
}

.flow-card {
  margin-top: 32px;
  border: 1px solid rgba(203, 213, 225, 0.8);
  border-radius: 10px;
  padding: 32px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: var(--shadow);
}

.stepper {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 32px;
  margin-bottom: 32px;
}

.step {
  position: relative;
  display: grid;
  min-height: 76px;
  place-items: center;
  border: 2px solid #cfd6e2;
  border-radius: 7px;
  color: #717b8d;
  font-weight: 850;
}

.step::after {
  content: "";
  position: absolute;
  right: -34px;
  width: 34px;
  height: 3px;
  background: #cfd6e2;
}

.step:last-child::after {
  display: none;
}

.step.active {
  border-color: #3b82f6;
  background: #eaf2ff;
  color: #3b82f6;
}

.step span {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 999px;
  background: #cfd6e2;
  color: #ffffff;
}

.step.active span {
  background: #3b82f6;
}

.step strong {
  font-size: 14px;
}

.flow-step {
  display: none;
  gap: 16px;
}

.flow-step.active {
  display: grid;
}

.flow-step label .field-title {
  color: #334155;
}

.flow-step label .field-title b {
  color: #ef4444;
}

.button.full {
  width: 100%;
}

.button.small {
  width: fit-content;
  min-height: 36px;
  padding: 8px 16px;
}

.button.green {
  background: linear-gradient(135deg, #22c55e, #16a34a);
}

.info-box {
  border: 1px solid #bfdbfe;
  border-radius: 7px;
  padding: 18px;
  background: #eff6ff;
  color: #2563eb;
}

.info-box p {
  margin: 12px 0 0 26px;
}

.mini-steps {
  display: grid;
  gap: 12px;
  color: #263244;
}

.mini-steps div {
  display: flex;
  align-items: center;
  gap: 16px;
}

.warning-text {
  margin: 0;
  color: #d97706;
  font-size: 13px;
}

.hint-text {
  margin: 0;
  color: #8a95a8;
  font-size: 13px;
}

.flow-actions {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) minmax(240px, 2fr);
  gap: 16px;
}

.button.loading {
  gap: 10px;
}

.button.loading::before {
  content: "";
  width: 18px;
  height: 18px;
  border: 3px solid rgba(255, 255, 255, 0.45);
  border-top-color: #ffffff;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

.flow-status {
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  padding: 20px;
  background: rgba(255, 255, 255, 0.78);
}

.flow-status-card {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  border-left: 4px solid #3b82f6;
  border-radius: 8px;
  padding: 16px 18px;
  background: #eff6ff;
  color: #1d4ed8;
}

.flow-status-card strong {
  display: block;
  margin-bottom: 6px;
  color: inherit;
  font-size: 17px;
}

.flow-status-card span {
  color: inherit;
  line-height: 1.45;
}

.flow-status-card.success {
  border-left-color: #22c55e;
  background: #ecfdf3;
  color: #15803d;
}

.flow-status-card.error {
  border-left-color: #ef4444;
  background: #fef2f2;
  color: #b91c1c;
}

.flow-status-icon {
  display: grid;
  width: 22px;
  height: 22px;
  place-items: center;
  border: 2px solid currentColor;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 900;
  line-height: 1;
}

.flow-status-icon.loading {
  border-color: #93c5fd;
  border-top-color: #3b82f6;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.confirm-box {
  border: 1px solid #86efac;
  border-radius: 7px;
  padding: 20px;
  background: rgba(255, 255, 255, 0.72);
}

.confirm-box h3 {
  margin: 0 0 14px;
  color: #263244;
  font-size: 20px;
}

.confirm-box div {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  border-top: 1px solid #e2e8f0;
  padding: 14px 0;
}

.confirm-box div:last-child {
  padding-bottom: 0;
}

.confirm-box span {
  color: #5d687b;
}

.force-line {
  display: flex;
  grid-template-columns: none;
  align-items: flex-start;
  gap: 12px;
  margin: 10px 0;
}

.force-line input {
  width: 18px;
  height: 18px;
  accent-color: #f97316;
}

.force-line small {
  display: block;
  margin-top: 8px;
  color: #f97316;
  line-height: 1.45;
}

.account-checker {
  width: min(672px, 100%);
  margin: 0 auto;
}

.account-heading {
  margin-bottom: 30px;
  text-align: center;
}

.account-heading h2 {
  margin: 0;
  color: #172338;
  font-size: clamp(28px, 4vw, 34px);
  line-height: 1.2;
}

.account-heading p {
  margin: 8px 0 0;
  color: #59657a;
  font-size: 16px;
}

.account-card {
  display: grid;
  gap: 20px;
  border: 1px solid rgba(203, 213, 225, 0.8);
  border-radius: 16px;
  padding: 24px;
  background: #ffffff;
  box-shadow: 0 14px 34px rgba(40, 55, 90, 0.12);
}

.account-card textarea {
  min-height: 126px;
  border-radius: 10px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  line-height: 1.45;
}

.account-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 96px;
  gap: 12px;
}

.account-result {
  display: grid;
  gap: 18px;
  margin-top: 24px;
}

.account-message {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 14px;
  align-items: center;
  border-radius: 14px;
  padding: 20px 26px;
  background: linear-gradient(135deg, #3b82f6 0%, #5046e4 100%);
  color: #ffffff;
  box-shadow: 0 14px 32px rgba(60, 85, 180, 0.18);
}

.account-message::before {
  content: "✓";
  display: grid;
  grid-row: 1 / span 2;
  width: 20px;
  height: 20px;
  place-items: center;
  border: 2px solid rgba(255, 255, 255, 0.9);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 950;
}

.account-message strong {
  display: block;
  font-size: 16px;
}

.account-message span {
  display: block;
  opacity: 0.96;
}

.account-message.bad {
  background: linear-gradient(135deg, #ef4444, #dc2626);
}

.account-message.bad::before {
  content: "!";
}

.subscription-card {
  overflow: hidden;
  border-radius: 14px;
  background: #ffffff;
  box-shadow: 0 14px 32px rgba(40, 55, 90, 0.12);
}

.subscription-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 22px;
  background: linear-gradient(135deg, #22c55e 0%, #0f9f63 100%);
  color: #ffffff;
}

.subscription-head span {
  font-size: 13px;
}

.subscription-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 66px;
  padding: 16px 22px;
  color: #59657a;
}

.subscription-row + .subscription-row {
  border-top: 1px solid #edf2f7;
}

.subscription-row strong {
  border-radius: 999px;
  padding: 6px 12px;
  background: #eef2ff;
  color: #3152d5;
  text-align: right;
  white-space: nowrap;
}

.subscription-row[data-kind="expires"] strong {
  background: #eafbea;
  color: #059669;
}

.batch-recharge {
  width: min(848px, 100%);
  margin: 0 auto;
}

.batch-hero {
  border: 1px solid rgba(203, 213, 225, 0.8);
  border-radius: 10px;
  padding: 34px 24px 30px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: var(--shadow);
  text-align: center;
}

.batch-hero h2 {
  margin: 0;
  color: #7686ff;
  font-size: clamp(30px, 5vw, 36px);
  font-weight: 900;
  line-height: 1.1;
}

.batch-hero p {
  margin: 10px 0 0;
  color: #536075;
  font-size: 17px;
}

.batch-card {
  display: grid;
  gap: 14px;
  margin-top: 32px;
  border: 1px solid rgba(203, 213, 225, 0.8);
  border-radius: 10px;
  padding: 32px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: var(--shadow);
}

.batch-card textarea {
  min-height: 216px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  line-height: 1.45;
}

.batch-hint {
  margin: -2px 0 4px;
  color: #6b7280;
  font-size: 12px;
}

.batch-force {
  margin-top: 8px;
}

.batch-settings {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 12px;
  margin-top: 8px;
}

.batch-settings label {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #4b5563;
  font-weight: 500;
}

.batch-settings input {
  width: 80px;
  min-height: 34px;
  padding: 8px 12px;
  text-align: center;
}

.batch-settings span {
  color: #8a95a8;
  font-size: 12px;
}

.batch-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 118px;
  gap: 12px;
  margin-top: 6px;
}

.batch-result {
  display: grid;
  gap: 18px;
  margin-top: 24px;
}

.batch-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.batch-summary-card {
  border: 1px solid rgba(203, 213, 225, 0.82);
  border-radius: 10px;
  padding: 14px 16px;
  background: #ffffff;
  box-shadow: 0 10px 22px rgba(40, 55, 90, 0.1);
}

.batch-summary-card span {
  display: block;
  color: #6b7280;
  font-size: 12px;
  font-weight: 750;
}

.batch-summary-card strong {
  display: block;
  margin-top: 5px;
  color: #172338;
  font-size: 24px;
  line-height: 1;
}

.batch-table-wrap {
  overflow-x: auto;
  border: 1px solid rgba(203, 213, 225, 0.82);
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 14px 32px rgba(40, 55, 90, 0.12);
}

.batch-table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
}

.batch-table th,
.batch-table td {
  border-bottom: 1px solid #edf2f7;
  padding: 13px 14px;
  text-align: left;
  vertical-align: middle;
}

.batch-table th {
  background: #f8fafc;
  color: #64748b;
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
}

.batch-table td {
  color: #0f172a;
  font-size: 14px;
}

.batch-table tr:last-child td {
  border-bottom: 0;
}

.batch-card-key,
.batch-task-id {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}

.batch-task-id {
  max-width: 180px;
  color: #64748b;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.batch-status {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 5px 10px;
  background: #eef2ff;
  color: #3152d5;
  font-size: 12px;
  font-weight: 850;
  white-space: nowrap;
}

.batch-status.waiting {
  background: #f1f5f9;
  color: #475569;
}

.batch-status.processing {
  background: #dbeafe;
  color: #1d4ed8;
}

.batch-status.completed {
  background: #dcfce7;
  color: #166534;
}

.batch-status.failed {
  background: #fee2e2;
  color: #991b1b;
}

.batch-note {
  color: #64748b;
}

.replace-screen {
  width: min(624px, 100%);
  margin: 0 auto;
}

.replace-hero {
  border: 1px solid rgba(203, 213, 225, 0.8);
  border-radius: 10px;
  padding: 34px 24px 30px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: var(--shadow);
  text-align: center;
}

.replace-hero h2 {
  margin: 0;
  color: #7686ff;
  font-size: clamp(30px, 5vw, 36px);
  font-weight: 900;
  line-height: 1.1;
}

.replace-hero p {
  max-width: 460px;
  margin: 10px auto 0;
  color: #536075;
  font-size: 17px;
  line-height: 1.55;
}

.replace-card,
.replace-success {
  margin-top: 32px;
  border: 1px solid rgba(203, 213, 225, 0.8);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: var(--shadow);
}

.replace-card {
  display: grid;
  gap: 24px;
  padding: 32px;
}

.replace-warning {
  border: 1px solid #facc15;
  border-radius: 7px;
  padding: 18px;
  background: #fffbeb;
  color: #c55a11;
}

.replace-warning strong {
  display: block;
  margin-bottom: 8px;
  color: #b45309;
}

.replace-warning strong::before {
  content: "⚠";
  margin-right: 8px;
  color: #f59e0b;
}

.replace-warning ul {
  margin: 0;
  padding-left: 42px;
  line-height: 1.65;
}

.replace-form {
  display: grid;
  gap: 20px;
}

.replace-submit {
  background: linear-gradient(135deg, #fdba74, #fb923c);
}

.replace-home-link {
  justify-self: center;
  border: 0;
  background: transparent;
  color: #6b7280;
  font-weight: 650;
  cursor: pointer;
}

.replace-error {
  border: 1px solid #fecaca;
  border-radius: 8px;
  padding: 14px 16px;
  background: #fef2f2;
  color: #b91c1c;
  font-weight: 750;
}

.replace-success {
  padding: 56px 32px;
  text-align: center;
}

.replace-success-icon {
  display: grid;
  width: 64px;
  height: 64px;
  place-items: center;
  margin: 0 auto 20px;
  border-radius: 999px;
  background: #d1fae5;
  color: #22c55e;
  font-size: 34px;
  font-weight: 950;
}

.replace-success h3 {
  margin: 0;
  color: #16a34a;
  font-size: 20px;
}

.replace-success p {
  margin: 12px 0 18px;
  color: #536075;
}

.new-card-box {
  display: grid;
  gap: 10px;
  border: 1px solid #d6deeb;
  border-radius: 7px;
  padding: 16px 12px;
  background: rgba(255, 255, 255, 0.78);
  text-align: left;
}

.new-card-box span {
  color: #64748b;
  font-size: 13px;
}

.new-card-box strong {
  color: #1f2937;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  font-size: 16px;
  letter-spacing: 0.04em;
  overflow-wrap: anywhere;
}

.replace-success-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 24px;
}

.replace-success-actions .button {
  min-width: 128px;
}

.card-query {
  width: min(896px, 100%);
  margin: 0 auto;
}

.card-query-heading {
  margin-bottom: 26px;
  text-align: center;
}

.card-query-heading h2 {
  margin: 0;
  color: #172338;
  font-size: clamp(28px, 4vw, 34px);
  line-height: 1.2;
}

.card-query-heading p {
  margin: 10px 0 0;
  color: #334155;
}

.card-query-form,
.card-query-result {
  border: 1px solid rgba(203, 213, 225, 0.82);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow);
}

.card-query-form {
  display: grid;
  gap: 16px;
  padding: 24px;
}

.card-query-form textarea {
  min-height: 210px;
}

.card-query-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.card-query-actions .button {
  min-width: 154px;
}

.button.slate {
  background: #6b7280;
}

.card-query-result {
  margin: 32px auto 0;
  padding: 24px;
}

.card-empty {
  display: grid;
  min-height: 188px;
  place-items: center;
  align-content: center;
  gap: 12px;
  color: #64748b;
  text-align: center;
}

.card-empty strong {
  display: block;
  color: #0f172a;
  font-size: 18px;
}

.card-empty span {
  display: block;
}

.search-mark {
  position: relative;
  width: 42px;
  height: 42px;
  border: 3px solid #9ca3af;
  border-radius: 50%;
}

.search-mark::after {
  content: "";
  position: absolute;
  right: -13px;
  bottom: -9px;
  width: 24px;
  height: 3px;
  border-radius: 999px;
  background: #9ca3af;
  transform: rotate(45deg);
}

.card-result-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}

.card-result-top h3 {
  margin: 0;
  color: #172338;
  font-size: 20px;
}

.copy-all {
  border: 0;
  background: transparent;
  color: #1d4ed8;
  font-weight: 800;
  cursor: pointer;
}

.card-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 26px;
}

.card-filter {
  min-height: 36px;
  border: 0;
  border-radius: 6px;
  padding: 8px 16px;
  background: #f1f3f7;
  color: #334155;
  font-weight: 800;
  cursor: pointer;
}

.card-filter.active {
  background: #3b82f6;
  color: #ffffff;
}

.card-table-wrap {
  overflow-x: auto;
}

.card-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 760px;
}

.card-table th,
.card-table td {
  border-bottom: 1px solid #edf2f7;
  padding: 14px 16px;
  text-align: left;
  vertical-align: middle;
}

.card-table th {
  background: #f8fafc;
  color: #64748b;
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
}

.card-table td {
  color: #0f172a;
  font-size: 14px;
}

.card-code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 5px 10px;
  background: #eef2ff;
  color: #334155;
  font-size: 12px;
  font-weight: 850;
  white-space: nowrap;
}

.status-badge.used {
  background: #f1f5f9;
  color: #334155;
}

.status-badge.normal {
  background: #dcfce7;
  color: #166534;
}

.status-badge.disabled {
  background: #fee2e2;
  color: #991b1b;
}

.status-badge.invalid {
  background: #f3f4f6;
  color: #6b7280;
}

.copy-card {
  border: 0;
  background: transparent;
  color: #1d4ed8;
  font-weight: 800;
  cursor: pointer;
}

.tool-header {
  padding: 22px 24px 0;
  text-align: left;
}

.tool-header h2 {
  margin: 0;
  color: #263244;
  font-size: 24px;
}

.tool-header p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.55;
}

.form {
  display: grid;
  gap: 16px;
  padding: 22px 24px 24px;
}

.grid-two {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

label {
  display: grid;
  gap: 8px;
  color: #334155;
  font-size: 14px;
  font-weight: 750;
  text-align: left;
}

input,
textarea {
  width: 100%;
  border: 1px solid #d6deeb;
  border-radius: 8px;
  padding: 13px 14px;
  background: #ffffff;
  color: #1f2937;
  outline: none;
}

textarea {
  min-height: 140px;
  resize: vertical;
}

input:focus,
textarea:focus {
  border-color: #7c8cff;
  box-shadow: 0 0 0 3px rgba(124, 140, 255, 0.16);
}

.checkline {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
}

.checkline input {
  width: 18px;
  height: 18px;
}

.button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 7px;
  padding: 11px 16px;
  background: linear-gradient(135deg, #3b82f6, #7c3aed);
  color: #ffffff;
  font-weight: 850;
  text-decoration: none;
  cursor: pointer;
}

.button.secondary {
  background: linear-gradient(135deg, #3b82f6, #2563eb);
}

.button.ghost {
  border: 1px solid #d6deeb;
  background: #ffffff;
  color: #64748b;
}

.button:disabled {
  cursor: wait;
  opacity: 0.68;
}

.result {
  display: none;
  margin: 0 24px 24px;
  border: 1px solid #d6deeb;
  border-radius: 8px;
  background: #f8fafc;
  overflow: hidden;
}

.result.visible {
  display: block;
}

.result-title {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 13px 14px;
  border-bottom: 1px solid #d6deeb;
  color: var(--muted);
  font-size: 13px;
}

pre {
  margin: 0;
  padding: 16px;
  overflow: auto;
  color: #1f2937;
  white-space: pre-wrap;
}

.pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 3px 9px;
  background: rgba(20, 184, 166, 0.12);
  color: #0f766e;
  font-weight: 850;
}

.pill.bad {
  background: rgba(220, 38, 38, 0.1);
  color: var(--bad);
}

.footer {
  width: min(848px, 100%);
  margin: 28px auto 0;
  color: #5c677d;
  text-align: center;
  font-size: 14px;
  line-height: 1.6;
}

.footer p {
  margin: 4px 0;
}

@media (max-width: 760px) {
  .topbar {
    grid-template-columns: 1fr;
    gap: 12px;
    padding-top: 12px;
  }

  .site-logo,
  .top-actions {
    grid-column: 1;
    justify-self: center;
  }

  .service-grid,
  .status-strip,
  .grid-two,
  .stepper,
  .flow-actions,
  .account-actions,
  .batch-actions,
  .batch-summary {
    grid-template-columns: 1fr;
  }

  .step::after {
    display: none;
  }
}

@media (max-width: 480px) {
  .page {
    padding-right: 12px;
    padding-left: 12px;
  }

  .intro-card,
  .service-card {
    padding-right: 18px;
    padding-left: 18px;
  }

  .card-query-form,
  .card-query-result {
    padding: 20px 14px;
  }

  .card-query-actions .button {
    width: 100%;
  }

  .batch-card {
    padding: 22px 14px;
  }

  .batch-settings {
    align-items: flex-start;
    flex-direction: column;
  }

  .replace-card,
  .replace-success {
    padding-right: 18px;
    padding-left: 18px;
  }

  .replace-success-actions .button {
    width: 100%;
  }

  .card-result-top {
    align-items: flex-start;
    flex-direction: column;
  }

  .account-checker {
    padding: 22px 12px 24px;
  }

  .account-heading h2 {
    font-size: 26px;
  }

  .top-actions {
    flex-wrap: wrap;
    justify-content: center;
  }
}
