/* Toasts: the single floating presentation for transient feedback across public, account and admin surfaces (js/notices.js).
   Bottom right, one under the other (newest last), colored by kind with the site tokens, so dark mode follows the theme.
   The server-rendered region ([data-notice-stack]) uses the same placement, so a notice is readable even before the script runs. */
.notice-stack[hidden],.hc-toasts[hidden]{display:none!important}
.notice-stack,.notice-stack[popover],.hc-toasts,.hc-toasts[popover]{position:fixed;inset:auto max(1.25rem,env(safe-area-inset-right)) max(1.25rem,env(safe-area-inset-bottom)) auto;top:auto;left:auto;transform:none;z-index:2147483000;width:min(25rem,calc(100% - 2rem));max-height:calc(100dvh - 2.5rem);margin:0;padding:0;border:0;background:transparent;color:var(--text,#1c2129);display:flex;flex-direction:column;justify-content:flex-end;gap:.6rem;overflow:auto;overscroll-behavior:contain;pointer-events:none;box-sizing:border-box}
.notice-stack:empty,.hc-toasts:empty{display:none}
.notice-stack::backdrop,.hc-toasts::backdrop{background:transparent;pointer-events:none}

/* One toast. --toast is the kind color; tint, icon and timer bar come from it. Content stays as the page wrote it
   (scripts may rewrite the text), so the icon is a pseudo-element and links/buttons/code keep their place. */
.hc-toasts .notice,.notice-stack .notice{--toast:var(--ok,#166534);--toast-soft:var(--ok-soft,#ecfdf3);--toast-icon:"\2713";position:relative;display:block;flex:none;min-height:3.4rem;margin:0;padding:.95rem 2.9rem 1rem 3.35rem;border:1px solid color-mix(in srgb,var(--toast) 32%,var(--border,#d9dde3));border-radius:14px;background:var(--surface,#fff) linear-gradient(90deg,var(--toast-soft),var(--surface,#fff) 75%);color:var(--text,#1c2129);font-family:inherit;font-size:.92rem;font-weight:500;line-height:1.45;text-align:left;box-shadow:0 12px 32px rgb(0 0 0 / 16%),0 2px 6px rgb(0 0 0 / 8%);pointer-events:auto;overflow:hidden;overflow-wrap:anywhere;box-sizing:border-box;animation:hc-toast-in .22s ease-out}
.hc-toasts .notice::before,.notice-stack .notice::before{content:var(--toast-icon);position:absolute;left:.85rem;top:.85rem;display:grid;place-items:center;width:1.75rem;height:1.75rem;border-radius:50%;background:var(--toast);color:var(--surface,#fff);font-size:.95rem;font-weight:800;line-height:1}
.hc-toasts .notice:is([data-toast-kind=info],[data-toast=info],.info),.notice-stack .notice:is([data-toast-kind=info],[data-toast=info],.info){--toast:var(--accent,#0066cc);--toast-soft:var(--accent-soft,#edf4fc);--toast-icon:"i"}
.hc-toasts .notice:is([data-toast-kind=warning],[data-toast=warning],.warn,.warning),.notice-stack .notice:is([data-toast-kind=warning],[data-toast=warning],.warn,.warning){--toast:var(--warn,#92400e);--toast-soft:var(--warn-soft,#fffbeb);--toast-icon:"!"}
.hc-toasts .notice:is([data-toast-kind=error],[data-toast=error],.bad,.error),.notice-stack .notice:is([data-toast-kind=error],[data-toast=error],.bad,.error){--toast:var(--danger,#b91c1c);--toast-soft:var(--danger-soft,#fef2f2);--toast-icon:"\2715"}
.hc-toasts .notice[data-toast-kind=success]{--toast:var(--ok,#166534);--toast-soft:var(--ok-soft,#ecfdf3);--toast-icon:"\2713"}
.hc-toasts .notice[hidden],.notice-stack .notice[hidden]{display:none!important}
.hc-toasts .notice a,.notice-stack .notice a{color:inherit;font-weight:650;text-decoration:underline;text-underline-offset:2px}
.hc-toasts .notice :is(button,.button):not(.notice-close),.notice-stack .notice :is(button,.button):not(.notice-close){margin:.4rem .4rem 0 0}
.hc-toasts .notice code,.notice-stack .notice code{font-size:.82em}
.hc-toasts .notice-close,.notice-stack .notice-close{position:absolute;top:.45rem;right:.4rem;display:grid;place-items:center;width:2rem;height:2rem;min-height:0;margin:0;padding:0;border:0;border-radius:9px;background:transparent;color:inherit;font:inherit;font-size:1.3rem;line-height:1;cursor:pointer;opacity:.7}
.hc-toasts .notice-close:hover,.notice-stack .notice-close:hover{background:rgb(127 127 127 / 14%);opacity:1}
.hc-toasts .notice-close:focus-visible,.notice-stack .notice-close:focus-visible{outline:3px solid var(--focus,var(--accent,#1f5fbf));outline-offset:1px;opacity:1}
.hc-toast-timer{position:absolute;left:0;right:0;bottom:0;height:3px;background:var(--toast);opacity:.55;transform-origin:left center;animation:hc-toast-timer linear forwards;animation-duration:var(--toast-duration,8s)}
.notice[data-toast-state=paused] .hc-toast-timer{animation-play-state:paused}
@keyframes hc-toast-in{from{opacity:0;transform:translateY(.6rem) scale(.98)}to{opacity:1;transform:none}}
@keyframes hc-toast-timer{from{transform:scaleX(1)}to{transform:scaleX(0)}}
@media (max-width:640px){.notice-stack,.notice-stack[popover],.hc-toasts,.hc-toasts[popover]{width:auto;left:max(.75rem,env(safe-area-inset-left));right:max(.75rem,env(safe-area-inset-right));bottom:max(.75rem,env(safe-area-inset-bottom))}}
@media (prefers-reduced-motion:reduce){.hc-toasts .notice,.notice-stack .notice{animation:none}.hc-toast-timer{display:none}}
:root[data-reduced-motion=true] .hc-toasts .notice{animation:none}
@media print{.notice-stack,.hc-toasts{display:none!important}}
