/* ShortLink Pro - shared runtime styles */
:root {
  --slp-radius: 1rem;
  --slp-radius-sm: 0.65rem;
  --slp-font: 'Segoe UI', system-ui, -apple-system, 'Helvetica Neue', Arial, sans-serif;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--slp-font);
  -webkit-font-smoothing: subpixel-antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
}

.mode-light .glow-text {
  text-shadow: none;
}

/* Flash / toast container */
#flash-container {
  position: fixed;
  top: 1rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  width: min(92vw, 360px);
  pointer-events: none;
}

.slp-toast {
  padding: 0.8rem 1.1rem;
  border-radius: 12px;
  text-align: center;
  font-weight: 600;
  font-size: 0.9rem;
  opacity: 0;
  transform: translateY(-8px);
  transition: all 0.3s ease;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.18);
  pointer-events: auto;
}

.slp-toast.show {
  opacity: 1;
  transform: translateY(0);
}

.slp-toast-success { background: #10b981; color: #fff; }
.slp-toast-error { background: #ef4444; color: #fff; }

/* Reveal-on-scroll */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.in {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  .reveal { transition: none; opacity: 1; transform: none; }
}

/* Back to top */
#back-to-top {
  position: fixed;
  bottom: 1.2rem;
  right: 1.2rem;
  z-index: 1500;
  width: 44px;
  height: 44px;
  border: none;
  border-radius: 12px;
  display: grid;
  place-items: center;
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.3s ease;
  cursor: pointer;
  background: var(--slp-accent, #6366f1);
  color: #fff;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}

#back-to-top.show {
  opacity: 1;
  transform: none;
}

/* Mode buttons */
[data-mode-btn] {
  border-radius: 999px;
}
/* Highlight the selected mode so the toggle shows its state.
   NOTE the specificity: the theme files paint .btn-ghost with
   ".mode-light.theme-nebula .btn-ghost" / ".theme-nebula.home-page .btn-ghost"
   / ".mode-dark .panel-topbar .btn-ghost" (all 0-3-0), which beat the plain
   0-2-0 "[data-mode-btn].active" and silently removed the feedback in light
   mode, on the homepage and in the panels (app.css also loads before
   panel.css). "body .btn-group ..." raises it to 0-3-1 so the active state
   wins the cascade in every mode; var(--slp-accent) follows the palette. */
body .btn-group [data-mode-btn].active {
  border-color: var(--slp-accent, #6366f1);
  color: var(--slp-accent, #6366f1);
}

/* Language & theme dropdown toggles */
.locale-menu .dropdown-menu { min-width: 220px; }

/* Glow text */
.glow-text {
  text-shadow: 0 0 24px var(--slp-glow, rgba(99, 102, 241, 0.55));
}

/* Gradient text */
.gradient-text {
  background: linear-gradient(120deg, var(--slp-accent, #6366f1), var(--slp-accent-2, #ec4899));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Shimmer underline / loading bar */
.slp-loader {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0;
  z-index: 3000;
  background: linear-gradient(90deg, #6366f1, #ec4899, #f59e0b);
  transition: width 0.3s ease;
}

@media (min-width: 768px) {
  .reveal.reveal-left { transform: translateX(-24px); }
  .reveal.reveal-right { transform: translateX(24px); }
  .reveal.reveal-left.in, .reveal.reveal-right.in { transform: none; }
}

/* ---------- Soft badge chip ----------
   payment-proofs / payout-rates / footer / member-dashboard markup uses
   `badge rounded-pill text-bg-secondary-s translucent`, but neither of those
   two extra classes was ever defined in a stylesheet. Bootstrap's .badge
   hard-codes white text and expects its background from a `text-bg-*`
   utility, so the badge painted white text straight onto the page background
   and disappeared in light mode (dark mode masked it). Defined here because
   app.css is the last sheet in partials/head, so the colour beats .badge's
   0-1-0 `color:#fff` on source order alone. */
.text-bg-secondary-s {
  color: #4b5563;
  background-color: rgba(108, 117, 125, 0.13);
  border: 1px solid rgba(108, 117, 125, 0.16);
}
.mode-dark .text-bg-secondary-s {
  color: #ccd3f2;
  background-color: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.14);
}
.translucent { opacity: 0.9; }