:root {
  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --bg-dark: #0b1329;
  --card-bg: #151f38;
  --border: #2a3756;
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --accent: #38bdf8;
  --success: #22c55e;
  --danger: #ef4444;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
}

body {
  background-color: var(--bg-dark);
  color: var(--text-main);
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 24px 16px;
}

.app-container {
  width: 100%;
  max-width: 820px;
}

.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 12px;
}

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

.brand-logo {
  width: 52px;
  height: 52px;
  display: block;
  filter: drop-shadow(0 6px 18px rgba(56, 189, 248, 0.25));
}

.logo h1 {
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: -0.5px;
}

.subtitle {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.badge-free {
  background: rgba(34, 197, 94, 0.12);
  color: var(--success);
  border: 1px solid rgba(34, 197, 94, 0.3);
  padding: 6px 14px;
  border-radius: 9999px;
  font-size: 0.8rem;
  font-weight: 600;
}

.wizard-card {
  background-color: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 32px;
  box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.6);
}

.connected-account-badge {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  background: rgba(37, 99, 235, 0.15);
  border: 1px solid rgba(56, 189, 248, 0.4);
  color: #38bdf8;
  padding: 10px 16px;
  border-radius: 10px;
  margin-bottom: 20px;
  font-size: 0.9rem;
  font-weight: 500;
}
.connected-account-badge.hidden {
  display: none !important;
}

.badge-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-badge-logout {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #fca5a5;
  padding: 5px 12px;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}
.btn-badge-logout:hover {
  background: rgba(239, 68, 68, 0.35);
  color: #ffffff;
  border-color: #ef4444;
}

/* Abas Horizontais */
.horizontal-tabs-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(11, 19, 41, 0.6);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 8px 12px;
  margin-bottom: 32px;
  gap: 6px;
}

.tab-step-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 0.88rem;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.tab-step-btn.active {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.tab-step-btn.disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.tab-step-btn:not(.disabled):hover:not(.active) {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-main);
}

.step-badge {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
}

.tab-arrow {
  color: var(--border);
  font-size: 1.2rem;
  user-select: none;
}

/* Painéis de Etapa */
.step-content {
  display: none;
}

.step-content.active {
  display: block;
}

.panel-header {
  margin-bottom: 24px;
}

.panel-header h2 {
  font-size: 1.35rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.desc {
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.5;
}

/* Provedores */
.provider-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-bottom: 28px;
}

.provider-card {
  border: 2px solid var(--border);
  border-radius: 12px;
  padding: 18px 20px;
  cursor: pointer;
  position: relative;
  transition: all 0.2s ease;
  background: rgba(11, 19, 41, 0.3);
}

.provider-card:hover {
  border-color: rgba(56, 189, 248, 0.4);
  background: rgba(56, 189, 248, 0.03);
}

.provider-card.selected {
  border-color: var(--accent);
  background: rgba(56, 189, 248, 0.08);
}

.provider-card.provider-unavailable {
  opacity: 0.52;
  cursor: not-allowed;
  border-style: dashed;
}

.provider-availability-note {
  color: #fbbf24 !important;
  font-size: 0.76rem !important;
  margin: 10px 0 0 !important;
}

.provider-card input[type="radio"] {
  position: absolute;
  top: 20px;
  right: 20px;
  accent-color: var(--accent);
}

.provider-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
}

.provider-icon {
  font-size: 1.6rem;
}

.provider-header h3 {
  font-size: 1.05rem;
  font-weight: 600;
  display: inline-block;
  margin-right: 8px;
}

.tag-rec {
  background: var(--primary);
  color: #fff;
  font-size: 0.7rem;
  padding: 2px 8px;
  border-radius: 4px;
  font-weight: 600;
  vertical-align: middle;
}

.provider-card p {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 12px;
  line-height: 1.4;
}

.provider-features {
  list-style: none;
  font-size: 0.8rem;
  color: var(--success);
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

/* Formulários */
.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 6px;
}

.form-control {
  width: 100%;
  background: #0b1329;
  border: 1px solid var(--border);
  color: #fff;
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 0.95rem;
  transition: border-color 0.2s;
}

.form-control:focus {
  outline: none;
  border-color: var(--accent);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.input-with-button {
  display: flex;
  gap: 8px;
}

.hint {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 5px;
  display: block;
}

.validation-error {
  margin-top: 6px;
  font-size: 0.82rem;
  color: #f87171;
  font-weight: 500;
}

.validation-error.hidden {
  display: none;
}

/* Migration Card */
.migration-card {
  background: rgba(11, 19, 41, 0.6);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 18px;
  margin-bottom: 24px;
}

.migration-toggle-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.migration-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
}

.migration-title input {
  accent-color: var(--primary);
}

.migration-sub {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-top: 4px;
  margin-left: 24px;
}

.badge-optional {
  background: rgba(148, 163, 184, 0.15);
  color: var(--text-muted);
  border: 1px solid var(--border);
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.75rem;
}

.migration-fields {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px dashed var(--border);
}

.migration-fields.hidden {
  display: none;
}

.migration-mode-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 10px;
}

@media (max-width: 640px) {
  .migration-mode-tabs {
    grid-template-columns: 1fr;
  }
}

.mig-tab-btn {
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 12px 14px;
  text-align: left;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  gap: 4px;
  color: #f8fafc;
}

.mig-tab-btn:hover {
  border-color: #38bdf8;
  background: rgba(56, 189, 248, 0.08);
}

.mig-tab-btn.active {
  border-color: #38bdf8;
  background: rgba(56, 189, 248, 0.15);
  box-shadow: 0 0 14px rgba(56, 189, 248, 0.2);
}

.mig-tab-title {
  font-weight: 600;
  font-size: 0.92rem;
  color: #38bdf8;
}

.mig-tab-sub {
  font-size: 0.78rem;
  color: #94a3b8;
  line-height: 1.3;
}

.mongo-test-feedback {
  margin-top: 10px;
  padding: 12px;
  border-radius: 8px;
  font-size: 0.85rem;
  line-height: 1.4;
}

.mongo-test-feedback.hidden {
  display: none;
}

.mongo-test-feedback.success {
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.3);
  color: #4ade80;
}

.mongo-test-feedback.error {
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #f87171;
}

/* Botões & Linhas de Ação */
.actions-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.mt-12 {
  margin-top: 12px;
}

.btn {
  padding: 11px 22px;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
}

.btn-primary:hover {
  background: var(--primary-hover);
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.4);
}

.btn-secondary {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-main);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.05);
}

.btn-sm {
  padding: 7px 14px;
  font-size: 0.82rem;
  background: var(--border);
  color: #fff;
}

.btn-sm:hover {
  background: #3b4d75;
}

.btn-accent {
  background: #0284c7;
  color: #fff;
}

.btn-accent:hover {
  background: #0369a1;
}

.btn-large {
  width: 100%;
  padding: 14px 24px;
  font-size: 1.05rem;
  border-radius: 10px;
}

/* Resumo & Deploy */
.summary-box {
  background: rgba(11, 19, 41, 0.6);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 18px 20px;
  margin-bottom: 24px;
}

.summary-item {
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
  font-size: 0.9rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.summary-item:last-child {
  border-bottom: none;
}

.sum-label {
  color: var(--text-muted);
}

.sum-val {
  font-weight: 600;
  color: var(--accent);
}

.provider-login-guide {
  background: rgba(56, 189, 248, 0.07);
  border: 1px solid rgba(56, 189, 248, 0.25);
  border-radius: 12px;
  padding: 18px 20px;
  margin-bottom: 20px;
}

.provider-login-guide h3 {
  font-size: 0.98rem;
  margin-bottom: 10px;
}

.provider-login-guide ol {
  margin-left: 20px;
  color: var(--text-muted);
  font-size: 0.84rem;
  line-height: 1.65;
}

.provider-login-guide p {
  margin-top: 10px;
  color: var(--accent);
  font-size: 0.8rem;
}

.provider-login-guide code {
  color: #fff;
}

.deploy-action-box {
  margin-bottom: 24px;
}

.deploy-progress-area {
  margin-top: 24px;
}

.deploy-progress-area.hidden {
  display: none;
}

.progress-bar-container {
  width: 100%;
  height: 8px;
  background: var(--border);
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 16px;
}

.progress-bar {
  height: 100%;
  width: 10%;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  transition: width 0.4s ease;
}

.terminal-box {
  background: #070d1d;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 16px;
  font-family: monospace;
  font-size: 0.85rem;
  color: #38bdf8;
  height: 160px;
  overflow-y: auto;
  margin-bottom: 24px;
}

.log-line {
  margin-bottom: 6px;
}

/* Resultado Final - Exclusivo pós-deploy */
.result-box.hidden {
  display: none;
}

.success-banner {
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.3);
  border-radius: 12px;
  padding: 18px;
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}

.success-icon {
  font-size: 2.2rem;
}

.info-card {
  background: #0b1329;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 18px;
  margin-bottom: 20px;
}

.info-item {
  margin-bottom: 14px;
}

.info-item:last-child {
  margin-bottom: 0;
}

.copy-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #151f38;
  border: 1px solid var(--border);
  padding: 10px 14px;
  border-radius: 8px;
  margin-top: 6px;
}

.copy-box a, .copy-box span {
  color: var(--accent);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 500;
  word-break: break-all;
}

.save-creds-card {
  background: rgba(11, 19, 41, 0.6);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 16px 18px;
  margin-bottom: 24px;
}

.save-creds-card h4 {
  font-size: 0.95rem;
  margin-bottom: 4px;
}

.save-creds-card p {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.save-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* Guias de Conexão */
.setup-guides {
  background: #0b1329;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 18px;
  margin-bottom: 24px;
}

.setup-guides h4 {
  font-size: 0.95rem;
  margin-bottom: 14px;
}

.guide-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}

.tab-btn {
  background: #151f38;
  color: var(--text-muted);
  border: 1px solid var(--border);
  padding: 7px 14px;
  border-radius: 6px;
  font-size: 0.82rem;
  cursor: pointer;
  transition: all 0.2s;
}

.tab-btn.active {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}

.guide-content {
  display: none;
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.6;
}

.guide-content.active {
  display: block;
}

.guide-content code {
  background: #151f38;
  color: var(--accent);
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 0.82rem;
  display: inline-block;
  margin-top: 6px;
}

.ssl-notice-card {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  background: rgba(234, 179, 8, 0.12);
  border: 1px solid rgba(234, 179, 8, 0.35);
  border-radius: 12px;
  padding: 16px 20px;
  margin-top: 16px;
  color: #fef08a;
  font-size: 0.88rem;
  line-height: 1.45;
}
.ssl-notice-card .notice-icon { font-size: 1.3rem; line-height: 1; flex-shrink: 0; }
.ssl-notice-card strong { color: #fef08a; font-weight: 600; }
.ssl-notice-card p { margin-top: 4px; color: #cbd5e1; font-size: 0.84rem; margin-bottom: 0; }
.ssl-notice-card code { background: rgba(0, 0, 0, 0.3); padding: 2px 6px; border-radius: 4px; color: #fef08a; }

.final-open-action {
  margin-top: 16px;
}

.footer {
  margin-top: 32px;
  padding: 20px;
  background: rgba(11, 19, 41, 0.4);
  border: 1px solid var(--border);
  border-radius: 12px;
}

.footer-content {
  max-width: 740px;
  margin: 0 auto;
  text-align: center;
}

.footer-license {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.footer-legal-links {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-bottom: 12px;
  font-size: 0.8rem;
}

.footer-legal-links a {
  color: var(--accent);
  text-decoration: none;
}

.footer-legal-links a:hover {
  text-decoration: underline;
}

.footer-disclaimer {
  font-size: 0.78rem;
  color: #7e8c9f;
  line-height: 1.5;
  text-align: justify;
}

.footer-disclaimer strong {
  color: #fca5a5;
}

/* Deploy Wait Banner & Dynamic Tips */
.deploy-wait-banner {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.35);
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 0.85rem;
  color: #fef3c7;
  margin-bottom: 15px;
}

.deploy-wait-banner strong {
  color: #fbbf24;
  display: block;
  margin-bottom: 2px;
}

.deploy-wait-banner p {
  margin: 0;
  font-size: 0.8rem;
  color: #fde68a;
}

.deploy-wait-icon {
  font-size: 1.4rem;
  flex-shrink: 0;
  animation: pulse 1.8s infinite ease-in-out;
}

.deploy-dynamic-tip {
  font-size: 0.83rem;
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid rgba(56, 189, 248, 0.2);
  border-radius: 6px;
  padding: 8px 12px;
  text-align: center;
  transition: all 0.3s ease;
}

/* Banner de Otimização Inteligente para Nuvem */
.migration-opt-banner {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.25);
  border-radius: 8px;
  padding: 10px 12px;
  font-size: 0.82rem;
  color: #d1fae5;
}

.migration-opt-banner-title {
  color: #34d399;
  font-weight: 700;
  display: block;
  margin-bottom: 4px;
}

.migration-opt-banner strong {
  color: #34d399;
  display: inline;
}

.migration-opt-banner p {
  margin: 0;
  font-size: 0.78rem;
  color: #a7f3d0;
  line-height: 1.4;
}

.mig-opt-icon {
  font-size: 1.2rem;
  flex-shrink: 0;
  margin-top: 1px;
}
.migration-strategy-panel {
  min-inline-size: 0;
  margin-inline: 0;
  padding: 1.25rem;
  border: 1px solid rgba(56, 189, 248, 0.25);
  border-radius: 1rem;
  background: linear-gradient(145deg, rgba(14, 25, 47, 0.92), rgba(9, 16, 32, 0.78));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.migration-strategy-panel legend {
  display: block;
  inline-size: 100%;
  padding: 0;
}

.strategy-kicker {
  display: block;
  margin-block-end: 0.25rem;
  color: #38bdf8;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.strategy-title {
  display: block;
  color: #f8fafc;
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  font-weight: 800;
  line-height: 1.3;
}

.strategy-intro {
  max-inline-size: 68ch;
  margin-block: 0.5rem 1rem;
  color: #aebdd2;
  font-size: 0.86rem;
  line-height: 1.55;
}

.migration-choice-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}

.migration-choice {
  position: relative;
  display: grid !important;
  grid-template-columns: auto 1fr;
  gap: 0.75rem;
  min-block-size: 13rem;
  margin: 0 !important;
  padding: 1rem !important;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 0.875rem;
  background: rgba(15, 23, 42, 0.72);
  cursor: pointer;
  transition: border-color 160ms ease, background-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.migration-choice:hover {
  border-color: rgba(125, 211, 252, 0.62);
  background: rgba(20, 34, 58, 0.9);
  transform: translateY(-1px);
}

.migration-choice:has(input:checked) {
  border-color: #22d3ee;
  background: linear-gradient(145deg, rgba(8, 145, 178, 0.18), rgba(15, 23, 42, 0.9));
  box-shadow: 0 0 0 1px rgba(34, 211, 238, 0.22), 0 12px 28px rgba(2, 132, 199, 0.15);
}

.migration-choice-progressive:has(input:checked) {
  border-color: #a78bfa;
  background: linear-gradient(145deg, rgba(124, 58, 237, 0.16), rgba(15, 23, 42, 0.9));
  box-shadow: 0 0 0 1px rgba(167, 139, 250, 0.2), 0 12px 28px rgba(109, 40, 217, 0.14);
}

.migration-choice input {
  inline-size: 1.2rem;
  block-size: 1.2rem;
  margin-block-start: 0.15rem;
  accent-color: #22d3ee;
}

.migration-choice-progressive input {
  accent-color: #a78bfa;
}

.migration-choice:focus-within {
  outline: 3px solid rgba(125, 211, 252, 0.72);
  outline-offset: 3px;
}

.migration-choice-body,
.migration-choice-heading,
.migration-choice-heading > span:last-child {
  display: flex;
  min-inline-size: 0;
}

.migration-choice-body {
  flex-direction: column;
  gap: 0.7rem;
}

.migration-choice-heading {
  align-items: flex-start;
  gap: 0.65rem;
}

.migration-choice-heading > span:last-child {
  flex: 1;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
}

.migration-choice-heading strong {
  color: #f8fafc;
  font-size: 0.94rem;
  line-height: 1.35;
}

.migration-choice-icon {
  display: grid;
  place-items: center;
  inline-size: 2rem;
  block-size: 2rem;
  flex: 0 0 2rem;
  border: 1px solid rgba(56, 189, 248, 0.3);
  border-radius: 0.625rem;
  background: rgba(56, 189, 248, 0.1);
}

.migration-choice-progressive .migration-choice-icon {
  border-color: rgba(167, 139, 250, 0.35);
  background: rgba(139, 92, 246, 0.12);
}

.choice-badge {
  padding: 0.18rem 0.5rem;
  border: 1px solid rgba(34, 211, 238, 0.35);
  border-radius: 999px;
  background: rgba(6, 182, 212, 0.12);
  color: #67e8f9;
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.choice-badge.secondary {
  border-color: rgba(167, 139, 250, 0.35);
  background: rgba(139, 92, 246, 0.12);
  color: #c4b5fd;
}

.migration-choice-copy {
  color: #cbd5e1;
  font-size: 0.81rem;
  line-height: 1.55;
}

.migration-choice-detail {
  color: #94a3b8;
  font-size: 0.75rem;
  line-height: 1.45;
}

.migration-choice-detail > span {
  color: #4ade80;
  font-weight: 800;
}

.choice-selected {
  margin-block-start: auto;
  color: #67e8f9;
  font-size: 0.72rem;
  font-weight: 800;
  opacity: 0;
}

.migration-choice-progressive .choice-selected {
  color: #c4b5fd;
}

.migration-choice:has(input:checked) .choice-selected {
  opacity: 1;
}

.migration-integrity-note {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  margin-block-start: 0.9rem;
  padding: 0.75rem 0.9rem;
  border: 1px solid rgba(74, 222, 128, 0.28);
  border-radius: 0.75rem;
  background: rgba(34, 197, 94, 0.08);
  color: #bbf7d0;
  font-size: 0.78rem;
  line-height: 1.5;
}

.integrity-icon {
  font-size: 1.15rem;
}

.worker-limit-alert {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-block: 1.25rem;
  padding: 1.15rem;
  border: 1px solid rgba(251, 146, 60, 0.48);
  border-radius: 1rem;
  background: linear-gradient(145deg, rgba(124, 45, 18, 0.3), rgba(30, 20, 24, 0.78));
  box-shadow: 0 14px 34px rgba(124, 45, 18, 0.16);
}

.worker-limit-alert:focus {
  outline: 3px solid rgba(251, 146, 60, 0.62);
  outline-offset: 3px;
}

.worker-limit-alert.hidden {
  display: none;
}

.worker-limit-icon {
  display: grid;
  place-items: center;
  inline-size: 2.6rem;
  block-size: 2.6rem;
  flex: 0 0 2.6rem;
  border-radius: 0.75rem;
  background: rgba(249, 115, 22, 0.18);
  font-size: 1.3rem;
}

.worker-limit-eyebrow {
  color: #fdba74;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.worker-limit-content h3 {
  margin-block: 0.2rem 0.45rem;
  color: #fff7ed;
  font-size: 1rem;
}

.worker-limit-content p {
  max-inline-size: 72ch;
  color: #fed7aa;
  font-size: 0.82rem;
  line-height: 1.55;
}

.worker-limit-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-block-start: 0.85rem;
}

.btn-danger-soft {
  border: 1px solid rgba(251, 146, 60, 0.45);
  background: rgba(194, 65, 12, 0.22);
  color: #ffedd5;
}

.btn-danger-soft:hover {
  border-color: #fb923c;
  background: rgba(194, 65, 12, 0.36);
}

.worker-inventory {
  container-type: inline-size;
  margin-block-start: 1rem;
  padding: 1rem;
  border: 1px solid rgba(56, 189, 248, 0.32);
  border-radius: 1rem;
  background: linear-gradient(145deg, rgba(8, 47, 73, 0.2), rgba(15, 23, 42, 0.76));
}

.worker-inventory:focus {
  outline: 3px solid rgba(125, 211, 252, 0.7);
  outline-offset: 3px;
}

.worker-inventory-heading {
  display: flex;
  align-items: flex-start;
  gap: 0.8rem;
}

.worker-inventory-icon {
  display: grid;
  place-items: center;
  inline-size: 2.5rem;
  block-size: 2.5rem;
  flex: 0 0 2.5rem;
  border-radius: 0.75rem;
  background: rgba(14, 165, 233, 0.14);
}

.worker-inventory-eyebrow {
  color: #7dd3fc;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.worker-inventory h4 {
  margin-block: 0.15rem 0.3rem;
  color: #f8fafc;
  font-size: 1rem;
}

.worker-inventory-heading p,
.worker-inventory-status,
.worker-inventory-footnote {
  color: #aebdd2;
  font-size: 0.8rem;
  line-height: 1.55;
}

.worker-inventory-status {
  margin-block-start: 0.8rem;
  padding: 0.65rem 0.75rem;
  border-radius: 0.65rem;
  background: rgba(2, 6, 23, 0.3);
}

.existing-worker-fieldset {
  min-inline-size: 0;
  margin-block-start: 0.9rem;
  padding: 0;
  border: 0;
}

.existing-worker-fieldset legend {
  margin-block-end: 0.65rem;
  color: #e2e8f0;
  font-size: 0.8rem;
  font-weight: 800;
}

.existing-worker-list {
  display: grid;
  gap: 0.55rem;
}

.existing-worker-choice {
  display: grid !important;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.75rem;
  min-block-size: 3.75rem;
  margin: 0 !important;
  padding: 0.75rem 0.85rem !important;
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 0.75rem;
  background: rgba(15, 23, 42, 0.72);
  cursor: pointer;
  transition: border-color 160ms ease, background-color 160ms ease, box-shadow 160ms ease;
}

.existing-worker-choice:hover {
  border-color: rgba(125, 211, 252, 0.58);
  background: rgba(20, 34, 58, 0.9);
}

.existing-worker-choice:has(input:checked) {
  border-color: #22d3ee;
  background: rgba(8, 145, 178, 0.14);
  box-shadow: 0 0 0 1px rgba(34, 211, 238, 0.18);
}

.existing-worker-choice:focus-within {
  outline: 3px solid rgba(125, 211, 252, 0.72);
  outline-offset: 2px;
}

.existing-worker-choice input {
  inline-size: 1.2rem;
  block-size: 1.2rem;
  accent-color: #06b6d4;
}

.existing-worker-choice-body {
  display: grid;
  min-inline-size: 0;
  gap: 0.15rem;
}

.existing-worker-choice-body strong {
  color: #f8fafc;
  overflow-wrap: anywhere;
}

.worker-release-tags {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
}

.worker-release-badge,
.worker-deploy-badge {
  inline-size: fit-content;
  padding: 0.16rem 0.45rem;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 999px;
  font-size: 0.64rem !important;
  font-weight: 800;
  line-height: 1.3;
}

.worker-deploy-badge {
  background: rgba(14, 116, 144, 0.14);
  border-color: rgba(34, 211, 238, 0.34);
  color: #a5f3fc;
  font-weight: 700;
}

.worker-release-badge.is-current,
.worker-release-badge.is-newer {
  border-color: rgba(52, 211, 153, 0.42);
  background: rgba(5, 150, 105, 0.16);
  color: #a7f3d0;
}

.worker-release-badge.needs-update {
  border-color: rgba(251, 191, 36, 0.5);
  background: rgba(217, 119, 6, 0.16);
  color: #fde68a;
}

.worker-release-badge.is-unknown {
  background: rgba(71, 85, 105, 0.2);
  color: #cbd5e1;
}

.existing-worker-choice-body .existing-worker-meta {
  color: #7c8da6;
  font-size: 0.66rem;
}

.create-second-choice {
  border-style: dashed;
  border-color: rgba(52, 211, 153, 0.38);
  background: rgba(6, 78, 59, 0.13);
}

.create-second-choice:hover,
.create-second-choice:has(input:checked) {
  border-color: #34d399;
  background: rgba(5, 150, 105, 0.15);
}

.existing-worker-choice-body span {
  color: #94a3b8;
  font-size: 0.72rem;
}

.existing-worker-selected {
  color: #67e8f9;
  font-size: 0.7rem;
  font-weight: 800;
  opacity: 0;
}

.existing-worker-choice:has(input:checked) .existing-worker-selected {
  opacity: 1;
}

.worker-inventory-footnote {
  margin-block-start: 0.8rem;
  padding-block-start: 0.8rem;
  border-block-start: 1px solid rgba(148, 163, 184, 0.18);
}

.worker-inventory-footnote a {
  color: #7dd3fc;
  font-weight: 700;
}

.worker-inventory-actions {
  margin-block-start: 0.75rem;
}

@container (max-width: 31rem) {
  .existing-worker-choice {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .existing-worker-selected {
    grid-column: 2;
  }
}

#site-name[readonly] {
  border-color: rgba(34, 211, 238, 0.36);
  background: rgba(8, 145, 178, 0.08);
  color: #cffafe;
  cursor: not-allowed;
}

.cleanup-workers-banner {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  margin-block: 1rem;
  padding: 1rem;
  border: 1px solid rgba(251, 146, 60, 0.42);
  border-radius: 0.9rem;
  background: rgba(124, 45, 18, 0.18);
  color: #ffedd5;
}

.cleanup-workers-icon {
  font-size: 1.3rem;
}

.cleanup-workers-banner p {
  margin-block: 0.35rem 0.65rem;
  color: #fed7aa;
  font-size: 0.82rem;
  line-height: 1.55;
}

.cleanup-workers-banner ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-block-end: 0.8rem;
  padding: 0;
  list-style: none;
}

.cleanup-workers-banner li {
  padding: 0.3rem 0.55rem;
  border: 1px solid rgba(251, 146, 60, 0.32);
  border-radius: 999px;
  background: rgba(124, 45, 18, 0.26);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.72rem;
}

.migration-overlap-note {
  margin-block-start: 0.55rem;
  color: #dbeafe;
  font-size: 0.78rem;
  line-height: 1.5;
}

.migration-result-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-block-start: 0.8rem;
}

@media (max-width: 720px) {
  .migration-choice-grid {
    grid-template-columns: 1fr;
  }

  .migration-choice {
    min-block-size: auto;
  }

  .worker-limit-alert {
    flex-direction: column;
  }

  .existing-worker-choice {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .existing-worker-selected {
    grid-column: 2;
  }

  .cleanup-workers-banner {
    flex-direction: column;
  }

  .migration-result-actions .btn {
    inline-size: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .migration-choice {
    transition: none;
  }

  .migration-choice:hover {
    transform: none;
  }

  .existing-worker-choice {
    transition: none;
  }
}
