.toast-container {
  position: fixed;
  z-index: 9999999999999999;
  pointer-events: none;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
}

.toast-container .toast-top-left {
  top: 20px;
  left: 20px;
  right: auto;
  bottom: auto;
  --stack-offset: 0px;
}

.toast-container .toast-top-middle {
  top: 20px;
  left: 50%;
  right: auto;
  bottom: auto;
  --stack-offset: 0px;
}

.toast-container .toast-top-right {
  top: 20px;
  right: 20px;
  left: auto;
  bottom: auto;
  --stack-offset: 0px;
}

.toast-container .toast-bottom-left {
  bottom: 20px;
  left: 20px;
  right: auto;
  top: auto;
  --stack-offset: 0px;
}

.toast-container .toast-bottom-middle {
  bottom: 20px;
  left: 50%;
  right: auto;
  top: auto;
  --stack-offset: 0px;
}

.toast-container .toast-bottom-right {
  bottom: 20px;
  right: 20px;
  left: auto;
  top: auto;
  --stack-offset: 0px;
}

.toast {
  position: absolute;
  min-width: 300px;
  max-width: 500px;
  padding: 16px;
  margin-bottom: 12px;
  border-radius: 16px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 12px;
  font-family:
    'yekan-bakh',
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    Roboto,
    Oxygen,
    Ubuntu,
    Cantarell,
    sans-serif;
  font-size: 14px;
  line-height: 1.5;
  transition:
    transform 0.3s ease,
    opacity 0.3s ease;
  opacity: 0;
  background-color: #fff;
  color: #000;
}

/* .toast-default-styles.toast-success {
  background-color: #10b981;
  color: #ffffff;
}

.toast-default-styles.toast-error {
  background-color: #ef4444;
  color: #ffffff;
}

.toast-default-styles.toast-warning {
  background-color: #f59e0b;
  color: #ffffff;
} */

.toast-content {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
}

.toast-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  font-size: 18px;
  font-weight: bold;
}

.toast-default-styles.toast-success .toast-icon svg path {
  fill: #00bba7;
}

.toast-default-styles.toast-error .toast-icon svg path {
  fill: #f44336;
}

.toast-default-styles.toast-warning .toast-icon svg path {
  fill: #f0b100;
}

.toast-message {
  flex: 1;
  word-wrap: break-word;
}

.toast-close {
  background: none;
  border: none;
  color: inherit;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
  padding: 0;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  opacity: 0.8;
  transition: opacity 0.2s ease;
  border-radius: 4px;
}

.toast-close:hover {
  opacity: 1;
  background-color: rgba(0, 0, 0, 0.1);
}

.toast-default-styles.toast-success .toast-close:hover,
.toast-default-styles.toast-error .toast-close:hover,
.toast-default-styles.toast-warning .toast-close:hover {
  background-color: rgba(255, 255, 255, 0.2);
}

.toast-top-left {
  transform: translateX(-100%) translateY(var(--stack-offset, 0px));
}

.toast-top-middle {
  transform: translateX(-50%) translateY(calc(-100% + var(--stack-offset, 0px)));
}

.toast-top-right {
  transform: translateX(100%) translateY(var(--stack-offset, 0px));
}

.toast-bottom-left {
  transform: translateX(-100%) translateY(calc(-1 * var(--stack-offset, 0px)));
}

.toast-bottom-middle {
  transform: translateX(-50%) translateY(calc(100% - var(--stack-offset, 0px)));
}

.toast-bottom-right {
  transform: translateX(100%) translateY(calc(-1 * var(--stack-offset, 0px)));
}

/* Enter state */
.toast-enter.toast-top-left {
  transform: translateX(0) translateY(var(--stack-offset, 0px));
  opacity: 1;
}

.toast-enter.toast-top-middle {
  transform: translateX(-50%) translateY(var(--stack-offset, 0px));
  opacity: 1;
}

.toast-enter.toast-top-right {
  transform: translateX(0) translateY(var(--stack-offset, 0px));
  opacity: 1;
}

.toast-enter.toast-bottom-left {
  transform: translateX(0) translateY(calc(-1 * var(--stack-offset, 0px)));
  opacity: 1;
}

.toast-enter.toast-bottom-middle {
  transform: translateX(-50%) translateY(calc(-1 * var(--stack-offset, 0px)));
  opacity: 1;
}

.toast-enter.toast-bottom-right {
  transform: translateX(0) translateY(calc(-1 * var(--stack-offset, 0px)));
  opacity: 1;
}

/* Exit animations */
.toast-exit.toast-top-left {
  transform: translateX(-100%) translateY(var(--stack-offset, 0px));
  opacity: 0;
}

.toast-exit.toast-top-middle {
  transform: translateX(-50%) translateY(calc(-100% + var(--stack-offset, 0px)));
  opacity: 0;
}

.toast-exit.toast-top-right {
  transform: translateX(100%) translateY(var(--stack-offset, 0px));
  opacity: 0;
}

.toast-exit.toast-bottom-left {
  transform: translateX(-100%) translateY(calc(-1 * var(--stack-offset, 0px)));
  opacity: 0;
}

.toast-exit.toast-bottom-middle {
  transform: translateX(-50%) translateY(calc(100% - var(--stack-offset, 0px)));
  opacity: 0;
}

.toast-exit.toast-bottom-right {
  transform: translateX(100%) translateY(calc(-1 * var(--stack-offset, 0px)));
  opacity: 0;
}

/* Responsive adjustments */
@media (max-width: 640px) {
  .toast {
    min-width: calc(100vw - 40px);
    max-width: calc(100vw - 40px);
  }

  .toast-container .toast-top-left,
  .toast-container .toast-top-right,
  .toast-container .toast-bottom-left,
  .toast-container .toast-bottom-right {
    left: 20px;
    right: 20px;
  }

  .toast-container .toast-top-middle,
  .toast-container .toast-bottom-middle {
    left: 20px;
    right: 20px;
  }

  .toast-top-middle {
    transform: translateY(calc(-100% + var(--stack-offset, 0px)));
  }

  .toast-bottom-middle {
    transform: translateY(calc(100% - var(--stack-offset, 0px)));
  }

  .toast-enter.toast-top-middle {
    transform: translateY(var(--stack-offset, 0px));
  }

  .toast-enter.toast-bottom-middle {
    transform: translateY(calc(-1 * var(--stack-offset, 0px)));
  }

  .toast-exit.toast-top-middle {
    transform: translateY(calc(-100% + var(--stack-offset, 0px)));
  }

  .toast-exit.toast-bottom-middle {
    transform: translateY(calc(100% - var(--stack-offset, 0px)));
  }
}
