/*
 * Toastr — PV theme
 */

/* ── Base container ─────────────────────────────────────── */
#toast-container {
  position: fixed;
  z-index: 999999;
}

#toast-container * {
  box-sizing: border-box;
}

#toast-container.toast-center,
#toast-container.toast-top-center,
#toast-container.toast-bottom-center {
  width: 100%;
}
#toast-container.toast-center > div,
#toast-container.toast-top-center > div,
#toast-container.toast-bottom-center > div {
  margin: auto;
}
#toast-container.toast-top-full-width > div,
#toast-container.toast-bottom-full-width > div {
  width: 96%;
  margin: auto;
}

/* ── Position helpers ───────────────────────────────────── */
.toast-top-full-width    { top: 0;      right: 0; width: 100%; }
.toast-bottom-full-width { bottom: 0;   right: 0; width: 100%; }
.toast-top-left          { top: 12px;   left: 12px; }
.toast-top-center        { top: 12px; }
.toast-top-right         { top: 12px;   right: 12px; }
.toast-bottom-right      { right: 12px; bottom: 12px; }
.toast-bottom-center     { bottom: 12px; }
.toast-bottom-left       { bottom: 12px; left: 12px; }
.toast-center            { top: 45%; }

/* ── Toast card ─────────────────────────────────────────── */
#toast-container > div {
  position: relative;
  margin: 0 0 8px;
  padding: 12px 36px 12px 16px;
  width: 320px;
  border-radius: var(--r-sm, 6px);
  border: none;
  background-color: var(--surface-2, #313133);
  background-image: none !important;
  color: #ffffff;
  opacity: 1;
}

#toast-container > :hover {
  opacity: 1;
  cursor: pointer;
}

/* ── Text ───────────────────────────────────────────────── */
.toast-title {
  font-weight: 600;
  font-size: 14px;
  margin-bottom: 4px;
}

.toast-message {
  font-size: 13px;
  opacity: .85;
  word-wrap: break-word;
}

.toast-message a,
.toast-message label {
  color: rgba(255, 255, 255, .9);
  text-decoration: underline;
}

.toast-message a:hover {
  color: #ffffff;
  text-decoration: none;
}

/* ── Close button ───────────────────────────────────────── */
.toast-close-button {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  float: none;
  font-size: 16px;
  font-weight: 400;
  color: #ffffff;
  text-shadow: none;
  opacity: .5;
}

.toast-close-button:hover,
.toast-close-button:focus {
  color: #ffffff;
  opacity: 1;
  text-decoration: none;
  cursor: pointer;
}

button.toast-close-button {
  padding: 0;
  background: transparent;
  border: 0;
  -webkit-appearance: none;
}

/* ── Types ───────────────────────────────────────────────── */

#toast-container > .toast-success {
  background-color: var(--ok, oklch(0.62 0.16 150)) !important;
  background-image: none !important;
  box-shadow: 0 4px 12px oklch(0.62 0.16 150 / 0.35);
}

#toast-container > .toast-error {
  background-color: var(--stop, oklch(0.60 0.20 27)) !important;
  background-image: none !important;
  box-shadow: 0 4px 12px oklch(0.60 0.20 27 / 0.35);
}

#toast-container > .toast-warning,
#toast-container > .toast-Warning {
  background-color: var(--warn, oklch(0.74 0.15 75)) !important;
  background-image: none !important;
  box-shadow: 0 4px 12px oklch(0.74 0.15 75 / 0.35);
}

#toast-container > .toast-info,
#toast-container > .toast-Info {
  background-color: var(--info, oklch(0.62 0.13 235)) !important;
  background-image: none !important;
  box-shadow: 0 4px 12px oklch(0.62 0.13 235 / 0.35);
}

#toast-container > .toast-wait {
  background-color: var(--info, oklch(0.62 0.13 235)) !important;
  background-image: none !important;
  box-shadow: 0 4px 12px oklch(0.62 0.13 235 / 0.35);
}

#toast-container > .toast-danger,
#toast-container > .toast-Danger {
  background-color: var(--stop, oklch(0.60 0.20 27)) !important;
  box-shadow: 0 4px 12px oklch(0.60 0.20 27 / 0.35);
}

#toast-container > .toast-primary,
#toast-container > .toast-Primary {
  background-color: var(--accent, oklch(0.55 0.17 268)) !important;
  box-shadow: 0 4px 12px oklch(0.55 0.17 268 / 0.35);
}

/* ── AngularJS animations ───────────────────────────────── */
:not(.no-enter)#toast-container > div.ng-enter,
:not(.no-leave)#toast-container > div.ng-leave {
  transition: 250ms ease opacity;
}

:not(.no-enter)#toast-container > div.ng-enter.ng-enter-active,
:not(.no-leave)#toast-container > div.ng-leave {
  opacity: 1;
}

:not(.no-leave)#toast-container > div.ng-leave.ng-leave-active,
:not(.no-enter)#toast-container > div.ng-enter {
  opacity: 0;
}

/* ── Responsive ─────────────────────────────────────────── */
@media all and (max-width: 480px) {
  #toast-container > div {
    padding: 10px 32px 10px 14px;
    width: calc(100vw - 24px);
  }
}
