/* ────────────────────────────────────────────────────────────────────────────
   Toastr — skin Arena Retrô
   Carregado após plataforma/assets/css/components/toastr.css
   Usa os design tokens de public/site/assets/css/site.css
──────────────────────────────────────────────────────────────────────────── */

/* Posição do container */
#toast-container.toast-top-right {
  top: 20px;
  right: 20px;
}

/* ── Toast base ── */
#toast-container > div {
  position: relative;
  padding: 14px 36px 14px 54px;
  width: 300px;
  max-width: calc(100vw - 40px);
  border-radius: 0px;
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  box-shadow: 0 8px 24px rgba(8, 15, 28, .10), 0 2px 6px rgba(8, 15, 28, .06);
  color: var(--color-text);
  opacity: 1;
  font-family: var(--font-body);
  font-size: 13px;
  line-height: 1.5;
  margin: 0 0 8px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  overflow: hidden;
}

[data-theme="dark"] #toast-container > div {
  box-shadow: 0 8px 24px rgba(0, 0, 0, .28), 0 2px 6px rgba(0, 0, 0, .14);
}

#toast-container > div:hover {
  box-shadow: 0 12px 36px rgba(8, 15, 28, .16), 0 4px 10px rgba(8, 15, 28, .08);
  opacity: 1;
  cursor: pointer;
}

[data-theme="dark"] #toast-container > div:hover {
  box-shadow: 0 12px 36px rgba(0, 0, 0, .36), 0 4px 10px rgba(0, 0, 0, .18);
}

/* ── Remover ícones brancos originais do Toastr ── */
#toast-container > .toast-success,
#toast-container > .toast-error,
#toast-container > .toast-info,
#toast-container > .toast-warning {
  background-image: none !important;
  background-color: var(--color-surface);
}

/* ── Área do ícone via ::before (tint + SVG colorido) ── */
#toast-container > div::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 44px;
  border-radius: 0px;
  background-position: center center;
  background-repeat: no-repeat;
  background-size: 18px 18px;
}

/* Success — checkmark verde */
#toast-container > .toast-success {
  border-left: 3px solid #22c55e;
}
#toast-container > .toast-success::before {
  background-color: rgba(34, 197, 94, .12);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2322c55e' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E");
}

/* Error — X vermelho */
#toast-container > .toast-error {
  border-left: 3px solid #ef4444;
}
#toast-container > .toast-error::before {
  background-color: rgba(239, 68, 68, .12);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ef4444' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cline x1='18' y1='6' x2='6' y2='18'/%3E%3Cline x1='6' y1='6' x2='18' y2='18'/%3E%3C/svg%3E");
}

/* Info — círculo dourado */
#toast-container > .toast-info {
  border-left: 3px solid #f5c518;
}
#toast-container > .toast-info::before {
  background-color: rgba(245, 197, 24, .12);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23f5c518' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cline x1='12' y1='16' x2='12' y2='12'/%3E%3Cline x1='12' y1='8' x2='12.01' y2='8'/%3E%3C/svg%3E");
}

/* Warning — triângulo âmbar */
#toast-container > .toast-warning {
  border-left: 3px solid #f59e0b;
}
#toast-container > .toast-warning::before {
  background-color: rgba(245, 158, 11, .12);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23f59e0b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10.29 3.86L1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0z'/%3E%3Cline x1='12' y1='9' x2='12' y2='13'/%3E%3Cline x1='12' y1='17' x2='12.01' y2='17'/%3E%3C/svg%3E");
}

/* ── Tipografia ── */
.toast-title {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: 2px;
  line-height: 1.4;
}

.toast-message {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 400;
  color: var(--color-text-soft);
  word-break: normal;
  white-space: normal;
  line-height: 1.5;
}

.toast-message a,
.toast-message label {
  color: var(--color-primary-dk);
}

.toast-message a:hover {
  color: var(--color-primary);
  text-decoration: underline;
}

/* ── Botão fechar ── */
.toast-close-button {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-text-soft);
  text-shadow: none;
  opacity: 0.5;
  position: absolute;
  right: 8px !important;
  top: 4px !important;
  line-height: 1;
}

.toast-close-button:hover,
.toast-close-button:focus {
  color: var(--color-text);
  opacity: 0.8;
}

button.toast-close-button {
  background: transparent;
  border: 0;
  cursor: pointer;
  padding: 0;
}

/* ── Progress bar ── */
.toast-progress {
  height: 3px;
  opacity: 0.65;
  bottom: -2px;
}

#toast-container > .toast-success .toast-progress { background-color: #22c55e; }
#toast-container > .toast-error   .toast-progress { background-color: #ef4444; }
#toast-container > .toast-info    .toast-progress { background-color: var(--color-primary); }
#toast-container > .toast-warning .toast-progress { background-color: #f59e0b; }

/* ── Mobile ── */
@media (max-width: 480px) {
  #toast-container.toast-top-right {
    top: 16px;
    right: 16px;
    left: 16px;
  }

  #toast-container > div {
    width: 100%;
    max-width: 100%;
    padding: 12px 32px 12px 50px;
    font-size: 13px;
  }
}
