
/* ═══════════════════════════════════════════════════════════════════════════
   DevFix — app-snapshot.css
   Estilos exclusivos do módulo Code Snapshot & Change Diff (prefixo sn-)
   Não compartilha nenhuma classe com outros módulos.
═══════════════════════════════════════════════════════════════════════════ */

/* ── Painel raiz ─────────────────────────────────────────────────────────── */
.sn-panel {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.sn-page-header {
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 4px;
}

.sn-page-header .tags-header-left {
  flex: 1;
  min-width: 0;
}

.sn-page-header .tags-title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

/* Largura da coluna à esquerda (sem cap artificial em ch — evita 2 linhas com botão à direita) */
.sn-page-header .tags-subtitle {
  display: block;
  margin-top: 8px;
  font-size: 0.88rem;
  line-height: 1.4;
  color: var(--text-secondary);
  font-style: normal;
  font-weight: 400;
  max-width: none;
  width: 100%;
  box-sizing: border-box;
}

.sn-new-badge {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: var(--warning-soft, #fffbeb);
  color: var(--warning, #d97706);
  border: 1px solid rgba(217, 119, 6, 0.35);
  padding: 2px 8px;
  border-radius: var(--r-pill);
  font-style: normal;
}

[data-theme="dark"] .sn-new-badge {
  background: rgba(217, 119, 6, 0.15);
  color: #f6ad55;
}

.sn-page-header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
  margin-top: 2px;
}


@media (max-width: 640px) {
  .sn-page-header {
    flex-direction: column;
    align-items: stretch;
  }
  .sn-page-header-actions {
    margin-top: 12px;
    justify-content: space-between;
    flex-wrap: wrap;
    width: 100%;
  }
  .sn-header-btn {
    width: 100%;
    justify-content: center;
  }
}

/* ── Cabeçalho ───────────────────────────────────────────────────────────── */
.sn-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.sn-header-left {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.sn-header-icon {
  flex-shrink: 0;
  margin-top: 4px;
  color: #f6ad55;
}

.sn-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0 0 4px 0;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.sn-beta-badge {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  background: linear-gradient(135deg, #d97706, #f6ad55);
  color: #1A1A1A;
  padding: 2px 8px;
  border-radius: 20px;
  vertical-align: middle;
}

.sn-subtitle {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin: 0;
}

/* ── Botão principal ─────────────────────────────────────────────────────── */
.sn-btn-new {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: var(--accent);
  color: var(--text-on-accent);
  border: none;
  border-radius: 8px;
  padding: 9px 18px;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.18s, transform 0.12s, box-shadow 0.18s;
  white-space: nowrap;
  flex-shrink: 0;
  box-shadow: 0 2px 8px var(--accent-glow);
}

.sn-btn-new:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px var(--accent-glow);
}

.sn-btn-new:active {
  transform: translateY(0);
}

/* ── Aviso de login ──────────────────────────────────────────────────────── */
.sn-login-notice {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(246, 173, 85, 0.08);
  border: 1px solid rgba(246, 173, 85, 0.25);
  border-radius: 8px;
  padding: 12px 16px;
  font-size: 0.88rem;
  color: var(--text-secondary);
}

.sn-link {
  color: #f6ad55;
  text-decoration: none;
  font-weight: 600;
}

.sn-link:hover {
  text-decoration: underline;
}

/* ── Formulário (cartão claro, padrão Heartbeat / API) ─────────────────── */
.sn-form-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.sn-form-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  background: var(--bg-raised);
  border-bottom: 1px solid var(--border);
}

.sn-form-title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-primary);
}

.sn-form-close {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 1rem;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 4px;
  transition: background 0.15s, color 0.15s;
}

.sn-form-close:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

.sn-form-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.sn-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.sn-field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

@media (max-width: 560px) {
  .sn-field-row {
    grid-template-columns: 1fr;
  }
}

.sn-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-secondary);
  letter-spacing: 0.02em;
}

.sn-optional {
  font-weight: 400;
  opacity: 0.65;
}

.sn-input {
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  padding: 10px 12px;
  font-size: 0.9rem;
  color: var(--text-primary);
  font-family: inherit;
  transition: border-color 0.15s, box-shadow 0.15s;
  width: 100%;
  box-sizing: border-box;
}

.sn-input::placeholder {
  color: var(--text-muted);
}

.sn-input:hover {
  border-color: rgba(15, 16, 32, 0.12);
}

[data-theme="dark"] .sn-input:hover {
  border-color: rgba(255, 255, 255, 0.12);
}

.sn-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

/* Grid de checkpoints */
.sn-checkpoints-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 8px;
}

.sn-cp-item {
  display: flex;
  align-items: center;
  gap: 9px;
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  padding: 10px 12px;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
  user-select: none;
}

.sn-cp-item:hover {
  border-color: rgba(217, 119, 6, 0.35);
  background: var(--bg-hover);
}

.sn-cp-item.sn-cp-checked {
  border-color: rgba(217, 119, 6, 0.5);
  background: var(--warning-soft, #fffbeb);
}

[data-theme="dark"] .sn-cp-item.sn-cp-checked {
  background: rgba(217, 119, 6, 0.12);
}

.sn-cp-checkbox {
  width: 16px;
  height: 16px;
  border: 2px solid var(--border);
  border-radius: 3px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, border-color 0.15s;
}

.sn-cp-checked .sn-cp-checkbox {
  background: var(--warning, #d97706);
  border-color: var(--warning, #d97706);
}

.sn-cp-checkbox-mark {
  display: none;
  color: #F5F5F7;
  font-size: 10px;
  line-height: 1;
}

.sn-cp-checked .sn-cp-checkbox-mark {
  display: block;
}

.sn-cp-label {
  font-size: 0.82rem;
  color: var(--text-secondary);
}

.sn-cp-checked .sn-cp-label {
  color: var(--text-primary);
}

/* Ações do formulário */
.sn-form-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  padding-top: 8px;
}

.sn-btn-cancel {
  background: none;
  border: 1px solid var(--border);
  border-radius: 7px;
  padding: 8px 18px;
  font-size: 0.875rem;
  color: var(--text-secondary);
  cursor: pointer;
  transition: background 0.15s;
}

.sn-btn-cancel:hover {
  background: var(--bg-hover);
}

/* Com .btn.btn-primary no HTML — só refina espaçamento */
.sn-btn-save {
  min-width: 160px;
}

.sn-btn-save:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

/* ── Toast ───────────────────────────────────────────────────────────────── */
.sn-toast {
  padding: 12px 18px;
  border-radius: 8px;
  font-size: 0.875rem;
  font-weight: 500;
  animation: snFadeIn 0.2s ease;
}

.sn-toast-ok {
  background: rgba(56, 161, 105, .12);
  border: 1px solid rgba(56, 161, 105, .3);
  color: #68d391;
}

.sn-toast-err {
  background: rgba(229, 62, 62, .10);
  border: 1px solid rgba(229, 62, 62, .3);
  color: #fc8181;
}

@keyframes snFadeIn {
  from {
    opacity: 0;
    transform: translateY(-4px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ── Estados ─────────────────────────────────────────────────────────────── */
.sn-loading {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 32px 0;
  color: var(--text-muted);
  font-size: 0.875rem;
}

.sn-spinner {
  width: 20px;
  height: 20px;
  border: 2px solid var(--border);
  border-top-color: #d97706;
  border-radius: 50%;
  animation: snSpin 0.7s linear infinite;
  flex-shrink: 0;
}

@keyframes snSpin {
  to {
    transform: rotate(360deg);
  }
}

.sn-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 52px 0;
  color: var(--text-muted);
  text-align: center;
}


.sn-empty p {
  margin: 0;
  font-size: 0.9rem;
}

.sn-empty-hint {
  font-size: 0.82rem;
  opacity: 0.7;
  margin: 0;
}

.sn-empty-icon {
  opacity: 0.35;
}

/* ── Cards de snapshot ───────────────────────────────────────────────────── */
#snList {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.sn-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  transition: border-color 0.15s;
}

.sn-card:hover {
  border-color: rgba(246, 173, 85, 0.3);
}

.sn-card-head {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 18px 20px 14px;
}

.sn-card-status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-top: 6px;
  flex-shrink: 0;
}

.sn-card-status-dot.sn-s-ok {
  background: #38a169;
}

.sn-card-status-dot.sn-s-changed {
  background: #d97706;
  animation: snPulse 1.4s ease-in-out infinite;
}

.sn-card-status-dot.sn-s-error {
  background: #e53e3e;
}

.sn-card-status-dot.sn-s-new {
  background: #4a5568;
}

@keyframes snPulse {

  0%,
  100% {
    opacity: 1
  }

  50% {
    opacity: .35
  }
}

.sn-card-info {
  flex: 1;
  min-width: 0;
}

.sn-card-url {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0 0 4px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sn-card-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin: 0 0 8px;
}

.sn-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.sn-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  border-radius: 20px;
  padding: 3px 10px;
  text-transform: uppercase;
}

.sn-status-pill.sn-s-ok {
  background: rgba(56, 161, 105, .12);
  color: #68d391;
  border: 1px solid rgba(56, 161, 105, .25);
}

.sn-status-pill.sn-s-changed {
  background: rgba(217, 119, 6, .12);
  color: #f6ad55;
  border: 1px solid rgba(217, 119, 6, .25);
}

.sn-status-pill.sn-s-error {
  background: rgba(229, 62, 62, .12);
  color: #fc8181;
  border: 1px solid rgba(229, 62, 62, .25);
}

.sn-status-pill.sn-s-new {
  background: rgba(74, 85, 104, .15);
  color: #a0aec0;
  border: 1px solid rgba(74, 85, 104, .3);
}

.sn-meta-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.75rem;
  color: var(--text-muted);
  background: rgba(255, 255, 255, .04);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 2px 10px;
}

.sn-card-actions {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}

.sn-action-btn {
  background: none;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 5px 10px;
  font-size: 0.78rem;
  color: var(--text-muted);
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}

.sn-action-btn:hover {
  background: rgba(255, 255, 255, .06);
  color: var(--text-primary);
  border-color: rgba(255, 255, 255, .2);
}

.sn-action-btn.sn-action-del:hover {
  background: rgba(229, 62, 62, .1);
  color: #fc8181;
  border-color: rgba(229, 62, 62, .3);
}

.sn-action-btn.sn-action-run {
  border-color: rgba(217, 119, 6, .4);
  color: #f6ad55;
}

.sn-action-btn.sn-action-run:hover {
  background: rgba(217, 119, 6, .1);
  border-color: rgba(217, 119, 6, .6);
}

.sn-action-btn:disabled {
  opacity: .5;
  cursor: not-allowed;
}

/* Tabela de checkpoints */
.sn-cp-table {
  border-top: 1px solid var(--border);
}

.sn-cp-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, .04);
  font-size: 0.83rem;
  cursor: pointer;
  transition: background 0.12s;
}

.sn-cp-row:last-child {
  border-bottom: none;
}

.sn-cp-row:hover {
  background: rgba(255, 255, 255, .03);
}

.sn-cp-row.sn-cp-changed {
  background: rgba(217, 119, 6, .04);
}

.sn-cp-row.sn-cp-changed:hover {
  background: rgba(217, 119, 6, .08);
}

.sn-cp-row-icon {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}

.sn-cp-icon-ok {
  background: #38a169;
}

.sn-cp-icon-changed {
  background: #d97706;
}

.sn-cp-icon-error {
  background: #e53e3e;
}

.sn-cp-icon-first {
  background: #4a5568;
}

.sn-cp-row-name {
  flex: 1;
  color: var(--text-secondary);
}

.sn-cp-row.sn-cp-changed .sn-cp-row-name {
  color: #f6ad55;
  font-weight: 600;
}

.sn-cp-row-hash {
  font-family: var(--font-mono, monospace);
  font-size: 0.72rem;
  color: var(--text-muted);
}

.sn-cp-row-badge {
  font-size: 0.7rem;
  font-weight: 700;
  padding: 1px 8px;
  border-radius: 20px;
}

.sn-cpb-changed {
  background: rgba(217, 119, 6, .15);
  color: #f6ad55;
  border: 1px solid rgba(217, 119, 6, .3);
}

.sn-cpb-ok {
  background: rgba(56, 161, 105, .1);
  color: #68d391;
  border: 1px solid rgba(56, 161, 105, .25);
}

.sn-cpb-first {
  background: rgba(74, 85, 104, .15);
  color: #a0aec0;
  border: 1px solid rgba(74, 85, 104, .3);
}

.sn-cpb-error {
  background: rgba(229, 62, 62, .1);
  color: #fc8181;
  border: 1px solid rgba(229, 62, 62, .25);
}

.sn-cp-row-arrow {
  color: var(--text-muted);
  font-size: 0.8rem;
  opacity: 0;
  transition: opacity 0.15s;
}

.sn-cp-row:hover .sn-cp-row-arrow {
  opacity: 1;
}

/* Resultado de run inline */
.sn-run-result {
  margin: 0 20px 14px;
  background: rgba(0, 0, 0, .2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 16px;
  font-size: 0.83rem;
  color: var(--text-secondary);
  animation: snFadeIn .2s ease;
}

.sn-run-ok {
  border-color: rgba(56, 161, 105, .3);
}

.sn-run-changed {
  border-color: rgba(217, 119, 6, .4);
}

.sn-run-error {
  border-color: rgba(229, 62, 62, .3);
}

/* ── Modal de Diff ───────────────────────────────────────────────────────── */
.sn-diff-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .7);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  animation: snFadeIn .2s ease;
}

.sn-diff-modal {
  background: var(--bg-surface, #1a1b23);
  border: 1px solid var(--border);
  border-radius: 14px;
  width: 100%;
  max-width: 860px;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.sn-diff-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px 20px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
  gap: 12px;
}

.sn-diff-head-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

#snDiffTitle {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
}

.sn-diff-meta {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-family: var(--font-mono, monospace);
}

.sn-diff-close {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 1.1rem;
  cursor: pointer;
  padding: 2px 7px;
  border-radius: 4px;
  flex-shrink: 0;
  transition: color 0.15s;
}

.sn-diff-close:hover {
  color: var(--text-primary);
}

/* Tabs dentro do modal de diff */
.sn-diff-tabs-bar {
  display: flex;
  gap: 4px;
  padding: 10px 16px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
  flex-wrap: wrap;
}

.sn-diff-tab-btn {
  background: none;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 5px 12px;
  font-size: 0.78rem;
  color: var(--text-muted);
  cursor: pointer;
  transition: background .15s, color .15s, border-color .15s;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.sn-diff-tab-btn:hover {
  background: rgba(255, 255, 255, .05);
  color: var(--text-primary);
}

.sn-diff-tab-btn.sn-dtab-active {
  background: rgba(217, 119, 6, .1);
  color: #f6ad55;
  border-color: rgba(217, 119, 6, .4);
  font-weight: 600;
}

.sn-diff-tab-btn .sn-dtab-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
}

.sn-diff-tab-btn .sn-dtab-dot.sn-dtab-changed {
  background: #d97706;
}

.sn-diff-tab-btn .sn-dtab-dot.sn-dtab-ok {
  background: #38a169;
}

.sn-diff-tab-btn .sn-dtab-dot.sn-dtab-error {
  background: #e53e3e;
}

.sn-diff-tab-btn .sn-dtab-dot.sn-dtab-first {
  background: #4a5568;
}

.sn-diff-body {
  flex: 1;
  overflow-y: auto;
  padding: 0;
}

/* Diff viewer */
.sn-diff-viewer {
  font-family: var(--font-mono, 'JetBrains Mono', monospace);
  font-size: 0.78rem;
  line-height: 1.55;
}


.sn-diff-stats {
  display: flex;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  font-size: 0.8rem;
  flex-wrap: wrap;
}

.sn-diff-stat-add {
  color: #68d391;
}

.sn-diff-stat-del {
  color: #fc8181;
}

.sn-diff-stat-eq {
  color: var(--text-muted);
}

.sn-diff-no-change {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 36px;
  color: var(--text-muted);
  font-size: 0.875rem;
  text-align: center;
  font-family: inherit;
}

.sn-diff-info-box {
  padding: 16px 20px;
  font-size: 0.83rem;
  color: var(--text-muted);
  font-family: inherit;
}

/* Tabela de linhas do diff */
.sn-diff-table {
  width: 100%;
  border-collapse: collapse;
}

.sn-diff-line {
  display: flex;
  align-items: stretch;
}

.sn-diff-line:hover {
  background: rgba(255, 255, 255, .02);
}

.sn-diff-line-num {
  width: 48px;
  min-width: 48px;
  padding: 1px 8px;
  text-align: right;
  font-size: 0.72rem;
  color: rgba(255, 255, 255, .2);
  user-select: none;
  border-right: 1px solid rgba(255, 255, 255, .06);
  flex-shrink: 0;
}

.sn-diff-line-sign {
  width: 20px;
  min-width: 20px;
  padding: 1px 4px;
  text-align: center;
  flex-shrink: 0;
  font-weight: 700;
}

.sn-diff-line-content {
  flex: 1;
  padding: 1px 8px;
  white-space: pre;
  overflow-x: auto;
  word-break: break-all;
}

/* Tipos de linha */
.sn-line-add {
  background: rgba(56, 161, 105, 0.12);
}

.sn-line-add .sn-diff-line-sign {
  color: #68d391;
}

.sn-line-add .sn-diff-line-content {
  color: #c6f6d5;
}

.sn-line-add .sn-diff-line-num {
  background: rgba(56, 161, 105, .06);
}

.sn-line-del {
  background: rgba(229, 62, 62, 0.1);
}

.sn-line-del .sn-diff-line-sign {
  color: #fc8181;
}

.sn-line-del .sn-diff-line-content {
  color: #fed7d7;
}

.sn-line-del .sn-diff-line-num {
  background: rgba(229, 62, 62, .06);
}

.sn-line-eq .sn-diff-line-sign {
  color: rgba(255, 255, 255, .15);
}

.sn-line-eq .sn-diff-line-content {
  color: rgba(255, 255, 255, .45);
}

/* Separador de blocos colapsados */
.sn-diff-collapse {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 8px;
  background: rgba(255, 255, 255, .03);
  border-top: 1px solid rgba(255, 255, 255, .06);
  border-bottom: 1px solid rgba(255, 255, 255, .06);
  font-size: 0.72rem;
  color: rgba(255, 255, 255, .25);
  cursor: pointer;
  user-select: none;
}

.sn-diff-collapse:hover {
  color: rgba(255, 255, 255, .5);
  background: rgba(255, 255, 255, .05);
}

/* Responsivo */
@media (max-width: 600px) {
  .sn-card-head {
    flex-wrap: wrap;
  }

  .sn-card-actions {
    flex-wrap: wrap;
  }

  .sn-diff-modal {
    max-height: 96vh;
    border-radius: 10px;
  }
}

/* ── Ajustes tema claro (reforço) ───────────────────────────────────────── */
:root .sn-form-close:hover {
  background: rgba(0, 0, 0, 0.05);
}

:root .sn-meta-chip {
  background: var(--bg-raised);
  color: var(--text-secondary);
}

:root .sn-action-btn:hover {
  background: rgba(0, 0, 0, 0.04);
  color: var(--text-primary);
  border-color: rgba(0, 0, 0, 0.15);
}

:root .sn-cp-row {
  border-bottom-color: var(--border);
}

:root .sn-cp-row:hover {
  background: rgba(0, 0, 0, 0.02);
}

:root .sn-cp-row.sn-cp-changed {
  background: rgba(217, 119, 6, 0.05);
}

:root .sn-cp-row.sn-cp-changed:hover {
  background: rgba(217, 119, 6, 0.09);
}

:root .sn-run-result {
  background: var(--bg-raised);
}

:root .sn-diff-modal {
  background: var(--bg-surface);
}

:root .sn-diff-line:hover {
  background: rgba(0, 0, 0, 0.02);
}

:root .sn-diff-line-num {
  color: var(--text-muted);
  border-right-color: var(--border);
}

:root .sn-diff-tab-btn:hover {
  background: rgba(0, 0, 0, 0.04);
}

:root .sn-line-add .sn-diff-line-content {
  color: #166534;
}

:root .sn-line-add .sn-diff-line-num {
  background: rgba(22, 101, 52, 0.06);
}

:root .sn-line-del .sn-diff-line-content {
  color: #991b1b;
}

:root .sn-line-del .sn-diff-line-num {
  background: rgba(153, 27, 27, 0.06);
}

:root .sn-line-eq .sn-diff-line-sign {
  color: var(--text-muted);
}

:root .sn-line-eq .sn-diff-line-content {
  color: var(--text-secondary);
}

:root .sn-diff-collapse {
  background: var(--bg-raised);
  border-top-color: var(--border);
  border-bottom-color: var(--border);
  color: var(--text-muted);
}

:root .sn-diff-collapse:hover {
  color: var(--text-secondary);
  background: var(--bg-hover);
}

[data-theme="dark"] .sn-cp-item {
  background: var(--bg-raised);
}

[data-theme="dark"] .sn-meta-chip {
  background: rgba(255, 255, 255, 0.04);
}

[data-theme="dark"] .sn-diff-line-num {
  color: rgba(255, 255, 255, 0.2);
  border-right-color: rgba(255, 255, 255, 0.06);
}

[data-theme="dark"] .sn-line-add .sn-diff-line-content {
  color: #c6f6d5;
}

[data-theme="dark"] .sn-line-del .sn-diff-line-content {
  color: #fed7d7;
}

[data-theme="dark"] .sn-line-eq .sn-diff-line-sign {
  color: rgba(255, 255, 255, 0.15);
}

[data-theme="dark"] .sn-line-eq .sn-diff-line-content {
  color: rgba(255, 255, 255, 0.45);
}
