/*
 * What the original's React runtime did with inline styles and conditional rendering, done here
 * and in site.js. site.css next to this file is the original Tailwind build, untouched.
 */

/* Theme toggle: a sun in dark mode, a moon in light mode. */
[data-theme=dark] [data-theme-icon=light],
[data-theme=light] [data-theme-icon=dark] {
  display: none;
}

/* Mobile menu button: the menu icon while closed, a cross while open. */
[data-mobile-toggle][aria-expanded=false] [data-when=open],
[data-mobile-toggle][aria-expanded=true] [data-when=closed] {
  display: none;
}

/* Entrance animations (framer-motion `initial` -> `animate` / `whileInView`). The start state is
   per element in --rv-o / --rv-t; without JavaScript the content is simply shown. */
.js [data-reveal] {
  opacity: var(--rv-o, 1);
  transform: var(--rv-t, none);
}
.js [data-reveal].rv-in {
  opacity: 1;
  transform: none;
  transition: opacity .6s cubic-bezier(.22, 1, .36, 1) var(--rv-d, 0s),
              transform .6s cubic-bezier(.22, 1, .36, 1) var(--rv-d, 0s);
}

/* Hover lifts (framer-motion `whileHover`). */
[data-hover] {
  transition: transform .3s cubic-bezier(.22, 1, .36, 1), border-color .3s, background-color .3s,
              color .3s, box-shadow .3s, opacity .3s;
}
[data-hover=y5]:hover { transform: translateY(-5px); }
[data-hover=y6]:hover { transform: translateY(-6px); }
[data-hover=y8]:hover { transform: translateY(-8px); }
[data-hover=y10]:hover { transform: translateY(-10px); }
[data-hover=y10s102]:hover { transform: translateY(-10px) scale(1.02); }
[data-hover=x5]:hover { transform: translateX(5px); }
[data-hover=s105]:hover { transform: scale(1.05); }
[data-hover=s110y2]:hover { transform: translateY(-2px) scale(1.1); }

/* Menus, dropdowns and tab panes appear the way framer-motion brought them in. */
.nbx-pop {
  animation: nbx-pop .2s ease-out;
}
@keyframes nbx-pop {
  from { opacity: 0; transform: translateY(10px); }
}
.nbx-drop {
  animation: nbx-drop .2s ease-out;
}
@keyframes nbx-drop {
  from { opacity: 0; transform: translateY(-10px); }
}
.nbx-fade {
  animation: nbx-fade .3s ease-out;
}
@keyframes nbx-fade {
  from { opacity: 0; transform: translateY(20px); }
}

/* Endless background motion (framer-motion `repeat: Infinity`). */
[data-loop=blob-a] { animation: nbx-blob-a 25s linear infinite; }
@keyframes nbx-blob-a {
  0%, 100% { transform: scale(1) rotate(0deg); }
  50% { transform: scale(1.3) rotate(180deg); }
}
[data-loop=blob-b] { animation: nbx-blob-b 20s linear infinite; }
@keyframes nbx-blob-b {
  0%, 100% { transform: scale(1.3) rotate(180deg); }
  50% { transform: scale(1) rotate(0deg); }
}
[data-loop=bob-10] { animation: nbx-bob-10 2s ease-in-out infinite; }
@keyframes nbx-bob-10 {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(10px); }
}
[data-loop=bob-12] { animation: nbx-bob-12 2s ease-in-out infinite; }
@keyframes nbx-bob-12 {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(12px); }
}
[data-loop=pulse-a] { animation: nbx-pulse-a 4s ease-in-out infinite; }
@keyframes nbx-pulse-a {
  0%, 100% { transform: scale(1); opacity: .1; }
  50% { transform: scale(1.2); opacity: .2; }
}
[data-loop=pulse-b] { animation: nbx-pulse-b 5s ease-in-out 1s infinite; }
@keyframes nbx-pulse-b {
  0%, 100% { transform: scale(1); opacity: .1; }
  50% { transform: scale(1.3); opacity: .15; }
}
[data-loop=marquee] { animation: nbx-marquee 30s linear infinite; }
@keyframes nbx-marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

@media (prefers-reduced-motion: reduce) {
  .js [data-reveal] { opacity: 1; transform: none; }
  [data-loop], .nbx-pop, .nbx-drop, .nbx-fade { animation: none; }
}

/* Toasts (the original used sonner, dark theme with rich colours). */
.nbx-toasts {
  position: fixed;
  z-index: 100;
  bottom: 24px;
  right: 24px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 356px;
  max-width: calc(100vw - 32px);
  pointer-events: none;
}
[dir=rtl] .nbx-toasts {
  right: auto;
  left: 24px;
}
.nbx-toast {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 16px;
  border-radius: 8px;
  border: 1px solid;
  font-size: 13px;
  line-height: 1.4;
  box-shadow: 0 4px 12px #0000001a;
  pointer-events: auto;
  animation: nbx-toast-in .3s ease-out;
}
.nbx-toast svg {
  flex: none;
  width: 20px;
  height: 20px;
}
.nbx-toast.is-error {
  background: hsl(358, 76%, 10%);
  border-color: hsl(357, 89%, 16%);
  color: hsl(358, 100%, 81%);
}
.nbx-toast.is-success {
  background: hsl(150, 100%, 6%);
  border-color: hsl(147, 100%, 12%);
  color: hsl(150, 86%, 65%);
}
.nbx-toast.is-leaving {
  opacity: 0;
  transform: translateY(8px);
  transition: opacity .2s, transform .2s;
}
@keyframes nbx-toast-in {
  from { opacity: 0; transform: translateY(16px); }
}
@media (max-width: 600px) {
  .nbx-toasts, [dir=rtl] .nbx-toasts {
    left: 16px;
    right: 16px;
    bottom: 16px;
    width: auto;
  }
}
