/* Ventra Toast — shared notification component
 * Used by index.html (sponsor form) and register.html (registration form).
 * Vanilla CSS, no deps. Brand-aligned with pink-500 primary palette.
 */

.toast-stack {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: calc(100vw - 32px);
  width: 380px;
  pointer-events: none;
}

@media (max-width: 640px) {
  .toast-stack {
    top: 12px;
    right: 12px;
    left: 12px;
    width: auto;
    max-width: none;
  }
}

.toast {
  pointer-events: auto;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  background: #fff;
  color: #1a1a1a;
  border-radius: 10px;
  border-left: 4px solid #EC008C;
  box-shadow: 0 12px 32px rgba(0, 0, 0, .14), 0 2px 6px rgba(0, 0, 0, .08);
  font-family: 'Be Vietnam Pro', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  transform: translateX(110%);
  opacity: 0;
  transition: transform .28s cubic-bezier(.2, .9, .3, 1.2), opacity .2s;
  will-change: transform, opacity;
}

@media (max-width: 640px) {
  .toast {
    transform: translateY(-120%);
  }
}

.toast.is-shown {
  transform: translateX(0);
  opacity: 1;
}

@media (max-width: 640px) {
  .toast.is-shown {
    transform: translateY(0);
  }
}

.toast.is-leaving {
  transform: translateX(110%);
  opacity: 0;
}

@media (max-width: 640px) {
  .toast.is-leaving {
    transform: translateY(-120%);
  }
}

.toast__icon {
  flex: 0 0 22px;
  width: 22px;
  height: 22px;
  margin-top: 1px;
}

.toast__body {
  flex: 1;
  min-width: 0;
  word-break: break-word;
}

.toast__title {
  font-weight: 700;
  margin-bottom: 2px;
  font-size: 14px;
}

.toast__msg {
  color: #4a4a4a;
  font-size: 13.5px;
}

.toast__close {
  flex: 0 0 24px;
  width: 24px;
  height: 24px;
  border: 0;
  background: transparent;
  color: #9a9a9a;
  cursor: pointer;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  transition: background .15s, color .15s;
  margin-top: -2px;
}

.toast__close:hover {
  background: rgba(0, 0, 0, .06);
  color: #1a1a1a;
}

.toast__close:focus-visible {
  outline: 2px solid #EC008C;
  outline-offset: 1px;
}

/* Variants */
.toast--success {
  border-left-color: #10B981;
}
.toast--success .toast__icon { color: #10B981; }

.toast--error {
  border-left-color: #EF4444;
}
.toast--error .toast__icon { color: #EF4444; }

.toast--warning {
  border-left-color: #F59E0B;
}
.toast--warning .toast__icon { color: #F59E0B; }

.toast--info {
  border-left-color: #3B82F6;
}
.toast--info .toast__icon { color: #3B82F6; }

/* Subtle progress bar for auto-dismiss */
.toast__progress {
  position: absolute;
  left: 0;
  bottom: 0;
  height: 2px;
  background: currentColor;
  opacity: .35;
  transform-origin: left center;
}

.toast {
  position: relative;
  overflow: hidden;
}
