/* Toasts (layouts/_toasts + public/js/toast.js). Own file: app, auth, marketing and editor pages all load it. */
.toasts { position: fixed; top: 84px; right: 20px; z-index: 2147483000; display: flex; flex-direction: column; gap: 10px; width: min(380px, calc(100vw - 32px)); pointer-events: none; }
.toast { position: relative; overflow: hidden; isolation: isolate; pointer-events: auto; display: flex; align-items: center; gap: 12px; padding: 13px 12px 15px 13px; border-radius: 14px; color: #0f172a; border: 1px solid transparent;
  /* Two backgrounds: a white-to-tint fill inside, a two-colour gradient showing through the border. */
  background: linear-gradient(135deg, #fff 35%, var(--toast-tint)) padding-box, linear-gradient(135deg, var(--toast-c), var(--toast-c2)) border-box;
  box-shadow: 0 18px 40px -14px var(--toast-glow), 0 4px 12px -6px rgba(15, 23, 42, .12); font-size: 14.5px; line-height: 1.45; font-weight: 500; text-align: left; opacity: 0; transform: translateX(24px) scale(.98); transition: opacity .3s ease, transform .35s cubic-bezier(.2, .8, .2, 1); }
/* A soft colour glow behind the icon. */
.toast::before { content: ""; position: absolute; z-index: -1; left: -90px; top: 50%; width: 240px; height: 240px; opacity: .75; transform: translateY(-50%); border-radius: 50%; background: radial-gradient(circle closest-side, var(--toast-glow), rgba(255, 255, 255, 0) 100%); pointer-events: none; }
.toast.toast-in { opacity: 1; transform: none; }
.toast.toast-out { opacity: 0; transform: translateX(24px) scale(.98); }
/* Success is green, info wears the brand (indigo #4f46e5 to the logo's cyan), error and warning keep red and amber,
   so each kind reads at a glance. Literal colours: this file loads on pages without app.css. */
.toast-success { --toast-c: #16a34a; --toast-c2: #10b981; --toast-tint: #ecfdf5; --toast-glow: rgba(22, 163, 74, .26); }
.toast-info { --toast-c: #4f46e5; --toast-c2: #06b6d4; --toast-tint: #eef2ff; --toast-glow: rgba(79, 70, 229, .28); }
.toast-error { --toast-c: #dc2626; --toast-c2: #db2777; --toast-tint: #fff1f2; --toast-glow: rgba(220, 38, 38, .26); }
.toast-warning { --toast-c: #f59e0b; --toast-c2: #ea580c; --toast-tint: #fffbeb; --toast-glow: rgba(234, 88, 12, .26); }
/* The icon's white mark on a round gradient badge (the svg's own shape is made see-through). */
.toast-icon { flex: none; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; color: transparent; background: linear-gradient(135deg, var(--toast-c), var(--toast-c2)); box-shadow: 0 6px 14px -4px var(--toast-glow), inset 0 1px 0 rgba(255, 255, 255, .35); }
.toast-icon svg { width: 22px; height: 22px; }
.toast-msg { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.toast-close { flex: none; display: flex; border: 0; background: none; color: #94a3b8; cursor: pointer; padding: 2px; border-radius: 6px; }
.toast-close svg { width: 16px; height: 16px; }
.toast-close:hover { color: #0f172a; background: rgba(15, 23, 42, .06); }
.toast-close:focus-visible { outline: 2px solid var(--toast-c); outline-offset: 2px; }
.toast-bar { position: absolute; left: 0; bottom: 0; height: 3px; width: 100%; background: linear-gradient(90deg, var(--toast-c), var(--toast-c2)); opacity: .85; transform-origin: left; animation: toast-life linear forwards; }
.toast-paused .toast-bar { animation-play-state: paused; }
@keyframes toast-life { from { transform: scaleX(1); } to { transform: scaleX(0); } }
@media (max-width: 600px) { .toasts { top: auto; bottom: 16px; right: 16px; } }
@media (prefers-reduced-motion: reduce) { .toast { transition: opacity .2s; transform: none !important; } .toast-bar { animation: none; } }

/* A field named by a validation error: outlined until the visitor changes it. */
input[aria-invalid="true"], select[aria-invalid="true"], textarea[aria-invalid="true"] { border-color: #dc2626 !important; box-shadow: 0 0 0 3px rgba(220, 38, 38, .16) !important; }
/* Field messages in place of the browser's validation bubbles (public/js/validate.js). */
.fv-msg { display: flex; align-items: flex-start; gap: 6px; margin: 6px 0 2px; color: #dc2626; font-size: 13.5px; font-weight: 500; line-height: 1.4; text-align: left; animation: fv-in .2s ease both; }
.fv-msg svg { flex: none; margin-top: 2px; }
.fv-msg.fv-out { animation: fv-out .18s ease both; }
@keyframes fv-in { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
@keyframes fv-out { to { opacity: 0; transform: translateY(-4px); } }
@media (prefers-reduced-motion: reduce) { .fv-msg, .fv-msg.fv-out { animation: none; } }
