/* Panth — Reset + Componentes base do Design System */

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font-ui);
  background: var(--bg-page);
  color: var(--text-primary);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; }
:focus-visible {
  outline: 2px solid var(--panth-dourado);
  outline-offset: 2px;
}

/* ── Badge ── */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-ui);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: var(--radius-pill);
  white-space: nowrap;
}
.badge-active {
  background: var(--panth-verde-profundo);
  color: var(--panth-bege);
}
.badge-active::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--panth-dourado-claro);
}
.badge-beta {
  background: rgba(150, 106, 59, 0.1);
  color: var(--panth-dourado);
  border: 1px solid rgba(150, 106, 59, 0.25);
}

/* ── Botão ── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-ui);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.3px;
  padding: 12px 20px;
  border-radius: var(--radius-sm);
  border: none;
  transition: background var(--motion-fast), color var(--motion-fast),
    box-shadow var(--motion-fast), transform var(--motion-fast);
}
.btn:active { transform: translateY(1px); }

.btn-primary {
  background: var(--panth-verde-profundo);
  color: var(--panth-bege);
}
.btn-primary:hover {
  background: #123028;
  box-shadow: var(--shadow-gold);
}

.btn-ghost {
  background: transparent;
  color: var(--text-muted);
  border: 1.5px solid var(--border-color-strong);
}
.btn-ghost:hover {
  border-color: var(--panth-dourado-claro);
  color: var(--panth-dourado);
  background: rgba(219, 176, 125, 0.08);
}

/* ── Modal ── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(18, 32, 26, 0.55);
  backdrop-filter: blur(3px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-5);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--motion-base);
  z-index: 100;
}
.modal-overlay.is-open {
  opacity: 1;
  pointer-events: auto;
}
.modal {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-modal);
  max-width: 460px;
  width: 100%;
  padding: var(--space-8);
  position: relative;
  transform: translateY(14px) scale(0.98);
  opacity: 0;
  transition: transform var(--motion-base), opacity var(--motion-base);
}
.modal-overlay.is-open .modal {
  transform: translateY(0) scale(1);
  opacity: 1;
}
.modal-close {
  position: absolute;
  top: var(--space-4);
  right: var(--space-4);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  background: var(--bg-surface-muted);
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  line-height: 1;
  transition: background var(--motion-fast), color var(--motion-fast);
}
.modal-close:hover {
  background: var(--panth-bege);
  color: var(--panth-verde-profundo);
}
.modal-badge { margin-bottom: var(--space-4); }
.modal-title {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 700;
  line-height: 1.15;
  color: var(--panth-verde-profundo);
  margin: 0 0 var(--space-3);
}
.modal-body {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-secondary);
  margin: 0 0 var(--space-8);
}
.modal-actions { display: flex; justify-content: flex-end; }

/* ── Toast ── */
.toast-container {
  position: fixed;
  top: var(--space-4);
  right: var(--space-4);
  z-index: 1000;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  max-width: 360px;
}
.toast {
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-sm);
  background: var(--bg-surface);
  color: var(--text-primary);
  box-shadow: var(--shadow-modal);
  font-family: var(--font-ui);
  font-size: 14px;
  line-height: 1.4;
  border-left: 4px solid var(--panth-verde-profundo);
  cursor: pointer;
  animation: toast-in var(--motion-base);
}
.toast-error { border-left-color: #B83232; }
.toast-info { border-left-color: var(--panth-dourado); }
.toast.toast-out { animation: toast-out var(--motion-base) forwards; }
@keyframes toast-in {
  from { transform: translateX(16px); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}
@keyframes toast-out {
  from { transform: translateX(0); opacity: 1; }
  to { transform: translateX(16px); opacity: 0; }
}
