/* Hot potato — timed toast with visible countdown */
.phx-hot-potato {
  position: fixed;
  top: 20px;
  left: 50%;
  z-index: 10050;
  width: min(420px, calc(100vw - 32px));
  transform: translate(-50%, -12px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 220ms ease, transform 220ms ease;
}

.phx-hot-potato.is-open {
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, 0);
}

.phx-hot-potato__card {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px 16px;
  border-radius: 14px;
  background: #0f5c4f;
  color: #f3faf7;
  box-shadow: 0 12px 32px rgba(8, 40, 32, 0.35);
  overflow: hidden;
  font-family: "Vazirmatn", Tahoma, sans-serif;
}

.phx-hot-potato__icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.18);
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
}

.phx-hot-potato__body {
  flex: 1;
  min-width: 0;
  text-align: right;
}

.phx-hot-potato__title {
  margin: 0 0 4px;
  font-size: 15px;
  font-weight: 800;
  line-height: 1.4;
}

.phx-hot-potato__sub {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.55;
  color: rgba(243, 250, 247, 0.88);
}

.phx-hot-potato__timer-wrap {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding-top: 2px;
}

.phx-hot-potato__ring {
  position: relative;
  width: 34px;
  height: 34px;
}

.phx-hot-potato__ring svg {
  width: 34px;
  height: 34px;
  transform: rotate(-90deg);
}

.phx-hot-potato__ring-bg {
  fill: none;
  stroke: rgba(255, 255, 255, 0.22);
  stroke-width: 3.5;
}

.phx-hot-potato__ring-fg {
  fill: none;
  stroke: #a7f3d0;
  stroke-width: 3.5;
  stroke-linecap: round;
  stroke-dasharray: 100;
  stroke-dashoffset: 0;
  transition: stroke-dashoffset 100ms linear;
}

.phx-hot-potato__ring-num {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: 11px;
  font-weight: 800;
  color: #ecfdf5;
}

.phx-hot-potato__timer-label {
  font-size: 10px;
  color: rgba(243, 250, 247, 0.7);
}

.phx-hot-potato__progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 3px;
  background: rgba(255, 255, 255, 0.15);
  overflow: hidden;
}

.phx-hot-potato__progress-bar {
  height: 100%;
  width: 100%;
  transform-origin: right center;
  background: #a7f3d0;
  transform: scaleX(1);
}

.phx-hot-potato__close {
  position: absolute;
  top: 6px;
  left: 6px;
  width: 26px;
  height: 26px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: rgba(236, 253, 245, 0.85);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
}

.phx-hot-potato__close:hover {
  background: rgba(255, 255, 255, 0.14);
}

@media (prefers-reduced-motion: reduce) {
  .phx-hot-potato,
  .phx-hot-potato__ring-fg {
    transition: none;
  }
}
