html.nova-modal-open,
html.nova-modal-open body {
  overflow: hidden;
}

html.nova-guest-limit-active,
html.nova-guest-limit-active body {
  overflow: hidden;
}

html.nova-guest-limit-active #bottomNav {
  z-index: var(--z-raised, 10);
}

html.nova-guest-limit-active .nova-dialog-overlay {
  z-index: var(--z-raised, 10);
}

.nova-guest-limit-overlay {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal, 500);
  display: grid;
  place-items: center;
  padding: clamp(16px, 3vw, 30px);
  pointer-events: none;
}

.nova-guest-limit-backdrop {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: auto;
  background:
    radial-gradient(900px 420px at 12% 8%, rgba(20, 184, 166, 0.2), transparent 60%),
    radial-gradient(760px 360px at 88% 14%, rgba(59, 130, 246, 0.2), transparent 62%), rgba(8, 10, 20, 0.72);
  backdrop-filter: blur(9px) saturate(1.1);
  -webkit-backdrop-filter: blur(9px) saturate(1.1);
}

.nova-guest-limit-card {
  position: relative;
  z-index: 1;
  pointer-events: auto;
  width: min(620px, 100%);
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: linear-gradient(160deg, rgba(16, 24, 39, 0.88), rgba(15, 23, 42, 0.78));
  box-shadow:
    0 30px 70px rgba(2, 6, 23, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.14);
  padding: clamp(20px, 3.8vw, 34px);
  display: grid;
  gap: 12px;
  color: #e9eef7;
  animation: fadeUp var(--motion-180) var(--motion-ease) both;
}

.nova-guest-limit-chip {
  justify-self: start;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
  color: #b9f5ed;
  background: rgba(20, 184, 166, 0.2);
  border: 1px solid rgba(94, 234, 212, 0.38);
  border-radius: 999px;
  padding: 5px 10px;
}

.nova-guest-limit-title {
  margin: 0;
  font-size: clamp(22px, 4.4vw, 34px);
  line-height: 1.08;
  font-weight: 700;
}

.nova-guest-limit-text {
  margin: 0;
  color: rgba(233, 238, 247, 0.9);
  font-size: clamp(14px, 2.1vw, 17px);
  line-height: 1.55;
}

.nova-guest-limit-reset {
  margin: 0;
  color: rgba(233, 238, 247, 0.72);
  font-size: 12px;
}

.nova-guest-limit-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 4px;
}

.nova-guest-limit-actions .btn {
  min-width: clamp(220px, 34vw, 320px);
  justify-content: center;
}

@media (max-width: 640px) {
  .nova-guest-limit-actions {
    justify-content: center;
  }

  .nova-guest-limit-actions .btn {
    width: min(100%, 340px);
  }
}

.nova-toast-host {
  position: fixed;
  top: 14px;
  top: calc(14px + env(safe-area-inset-top));
  right: 14px;
  right: calc(14px + env(safe-area-inset-right));
  z-index: var(--z-toast, 600);
  display: grid;
  gap: 6px;
  width: min(340px, calc(100vw - 28px));
  pointer-events: none;
}

@media (max-width: 900px) {
  .nova-toast-host {
    top: auto;
    left: 8px;
    left: calc(8px + env(safe-area-inset-left));
    right: 8px;
    right: calc(8px + env(safe-area-inset-right));
    bottom: 10px;
    bottom: calc(10px + env(safe-area-inset-bottom));
    width: auto;
    max-width: none;
  }

  html:has(#bottomNav) .nova-toast-host {
    bottom: calc(var(--mobile-bottom-nav-body-offset, 92px) + 10px + env(safe-area-inset-bottom));
  }

  .nova-toast {
    animation: slideUp var(--motion-120) var(--motion-ease) both;
  }

  .nova-toast-leave {
    transform: translateY(4px);
  }
}

.nova-toast {
  pointer-events: auto;
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: var(--toast-bg);
  border: 1px solid var(--toast-border);
  box-shadow: var(--shadow-lg);
  animation: fadeUp var(--motion-120) var(--motion-ease) both;
}

.nova-toast::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--primary);
  margin-top: 5px;
  flex-shrink: 0;
}

.nova-toast--success::before {
  background: var(--green);
}

.nova-toast--error::before {
  background: var(--red);
}

.nova-toast--warning::before {
  background: var(--color-warning);
}

.nova-toast-body {
  font-size: 12px;
  line-height: 1.4;
  flex: 1;
}

.nova-toast-close {
  border: 1px solid var(--border);
  background: var(--surface-soft);
  color: var(--muted);
  width: 24px;
  height: 24px;
  border-radius: 6px;
  cursor: pointer;
  display: grid;
  place-items: center;
  padding: 0;
  flex-shrink: 0;
  font-size: 12px;
}

.nova-toast-close:hover {
  background: var(--surface-muted);
  color: var(--ink);
}

.nova-toast-leave {
  opacity: 0;
  transform: translateY(-4px);
}

.nova-dialog-overlay {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal, 500);
  background: var(--overlay);
  display: grid;
  place-items: center;
  padding: 16px;
}

.nova-dialog {
  width: min(440px, 100%);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 18px;
  display: grid;
  gap: 10px;
  animation: fadeUp var(--motion-120) var(--motion-ease) both;
}

.nova-dialog-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nova-dialog-title {
  font-weight: 700;
  font-size: 16px;
}

.nova-dialog-body {
  display: grid;
  gap: 8px;
  font-size: 13px;
  line-height: 1.5;
}

.nova-dialog-message {
  color: var(--muted);
  font-size: 12px;
}

.nova-dialog-input {
  width: 100%;
}

.nova-dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
}

.nova-progress-message {
  color: var(--muted);
  font-size: 12px;
}

.nova-progress-percent {
  font-weight: 700;
  font-size: 13px;
  color: var(--primary);
}

.nova-progress-track {
  height: 8px;
  border-radius: 999px;
  overflow: hidden;
  background: var(--surface-soft);
  border: 1px solid var(--border);
}

.nova-progress-bar {
  height: 100%;
  width: 0%;
  background: var(--primary);
  border-radius: 999px;
  transition: width 0.12s linear;
}

.nova-progress-bar::after {
  display: none;
}

.nova-progress-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  align-items: start;
}

.nova-progress-stat {
  background: var(--surface-soft);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 8px;
  display: grid;
  gap: 2px;
}

.nova-progress-stat-label {
  font-size: 12px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 700;
}

.nova-progress-stat-value {
  font-size: 12px;
  font-weight: 700;
}

.nova-progress-detail {
  font-size: 12px;
  color: var(--muted);
}

@media (max-width: 768px), (pointer: coarse) {
  .nova-toast-close {
    min-width: 44px;
    min-height: 44px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .nova-guest-limit-card,
  .nova-toast,
  .nova-dialog {
    animation-name: none;
    transition-property: none;
  }

  .nova-toast-leave {
    transform: none;
  }
}
