/* ============================================================
   Stream 0x — shared design system (logo, buttons, badges)
   Deep Dark Blue + Electric Blue + Yellow accent + White/Gray
   Fonts: Inter (Latin) + Hind Siliguri (Bangla)
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=Hind+Siliguri:wght@300;400;500;600;700&display=swap');

:root {
  --s0x-bg: #070B1A;
  --s0x-bg-2: #0A1128;
  --s0x-card: #0D1630;
  --s0x-card-2: #131E42;
  --s0x-muted: #16213F;
  --s0x-border: #24407F;
  --s0x-foreground: #F8FAFC;
  --s0x-muted-fg: #94A3B8;
  --s0x-blue: #2563EB;
  --s0x-blue-2: #3B82F6;
  --s0x-blue-3: #60A5FA;
  --s0x-dark-blue: #1D4ED8;
  --s0x-yellow: #FACC15;
  --s0x-yellow-2: #FDE047;
  --s0x-red: #EF4444;
  --s0x-green: #22C55E;
  --s0x-amber: #F59E0B;
  --s0x-danger: #EF4444;
  --s0x-cyan: #60A5FA;
  --s0x-indigo: #3B82F6;
  --s0x-violet: #FACC15;
  --s0x-pink: #FDE047;
  --s0x-grad: linear-gradient(120deg, #3B82F6 0%, #60A5FA 45%, #FACC15 100%);
  --s0x-grad-blue: linear-gradient(120deg, #1D4ED8 0%, #2563EB 55%, #3B82F6 100%);
  --s0x-grad-yellow: linear-gradient(120deg, #FACC15 0%, #FDE047 100%);
  --s0x-grad-2: linear-gradient(120deg, #2563EB 0%, #1D4ED8 100%);
  --s0x-font-bangla: 'Hind Siliguri', 'Inter', sans-serif;
  --s0x-font-latin: 'Inter', 'Hind Siliguri', sans-serif;
  --s0x-radius: 16px;
  --s0x-radius-sm: 10px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--s0x-font-bangla);
  background:
    radial-gradient(1200px 600px at 80% -10%, rgba(37, 99, 235, 0.10), transparent 60%),
    radial-gradient(900px 500px at -10% 20%, rgba(250, 204, 21, 0.05), transparent 55%),
    var(--s0x-bg);
  color: var(--s0x-foreground);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
img, svg { display: inline-block; }
::selection { background: rgba(59, 130, 246, 0.45); color: #fff; }

/* ---------- Stream 0x animated logo ---------- */
.s0x-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  flex-shrink: 0;
}

.s0x-mark {
  position: relative;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background:
    radial-gradient(120% 120% at 20% 20%, rgba(96, 165, 250, 0.25), transparent 55%),
    radial-gradient(120% 120% at 85% 85%, rgba(250, 204, 21, 0.22), transparent 55%),
    linear-gradient(150deg, rgba(37, 99, 235, 0.45), rgba(10, 17, 40, 0.95));
  border: 1px solid rgba(59, 130, 246, 0.45);
  box-shadow:
    0 0 18px rgba(37, 99, 235, 0.40),
    inset 0 0 14px rgba(96, 165, 250, 0.15);
  animation: s0xMarkGlow 3.5s ease-in-out infinite;
}

.s0x-mark::before {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: 13px;
  background: conic-gradient(from var(--s0x-angle, 0deg),
    #60A5FA, #2563EB, #3B82F6, #FACC15, #FDE047, #60A5FA);
  z-index: -1;
  filter: blur(3px);
  opacity: 0.55;
  animation: s0xSpin 6s linear infinite;
}

@property --s0x-angle {
  syntax: '<angle>';
  initial-value: 0deg;
  inherits: false;
}

@keyframes s0xSpin {
  to { --s0x-angle: 360deg; }
}

@keyframes s0xMarkGlow {
  0%, 100% { box-shadow: 0 0 16px rgba(37, 99, 235, 0.35), inset 0 0 14px rgba(96, 165, 250, 0.12); }
  50% { box-shadow: 0 0 30px rgba(59, 130, 246, 0.60), inset 0 0 18px rgba(250, 204, 21, 0.18); }
}

.s0x-mark svg { position: relative; z-index: 1; }

.s0x-wave {
  stroke-dasharray: 28;
  stroke-dashoffset: 28;
  animation: s0xWave 2.4s ease-in-out infinite;
}

@keyframes s0xWave {
  0% { stroke-dashoffset: 28; opacity: 0.35; }
  50% { stroke-dashoffset: 0; opacity: 1; }
  100% { stroke-dashoffset: -28; opacity: 0.35; }
}

.s0x-particle {
  opacity: 0;
  animation: s0xParticle 3.2s ease-in-out infinite;
}

.s0x-particle.p2 { animation-delay: 0.8s; }
.s0x-particle.p3 { animation-delay: 1.6s; }

@keyframes s0xParticle {
  0% { opacity: 0; transform: translateY(4px); }
  45% { opacity: 0.95; }
  100% { opacity: 0; transform: translateY(-4px); }
}

.s0x-pulse-dot {
  transform-origin: center;
  animation: s0xPulseDot 2.2s ease-out infinite;
}

@keyframes s0xPulseDot {
  0% { transform: scale(0.6); opacity: 0.9; }
  100% { transform: scale(1.6); opacity: 0; }
}

.s0x-word {
  font-family: var(--s0x-font-latin);
  font-weight: 800;
  font-size: 1.45rem;
  letter-spacing: -0.02em;
  color: var(--s0x-foreground);
  white-space: nowrap;
}

.s0x-word em {
  font-style: normal;
  background: var(--s0x-grad);
  background-size: 220% 220%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: s0xGradientMove 5s ease-in-out infinite;
}

@keyframes s0xGradientMove {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

.s0x-logo.lg .s0x-mark { width: 74px; height: 74px; border-radius: 20px; }
.s0x-logo.lg .s0x-mark::before { border-radius: 21px; }
.s0x-logo.lg .s0x-word { font-size: 2.3rem; }
.s0x-logo.lg .s0x-mark svg { width: 52px; height: 52px; }

/* Static fallback when animations are disabled or unsupported */
@media (prefers-reduced-motion: reduce) {
  .s0x-mark, .s0x-mark::before, .s0x-wave, .s0x-particle,
  .s0x-pulse-dot, .s0x-word em {
    animation: none !important;
  }
  .s0x-wave { stroke-dashoffset: 0; opacity: 1; }
  .s0x-particle { opacity: 1; }
  html { scroll-behavior: auto; }
}

/* ---------- Shared buttons ---------- */
.s0x-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.7rem;
  border: none;
  border-radius: 12px;
  font-family: var(--s0x-font-bangla);
  font-weight: 600;
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.25s ease, background 0.25s ease, border-color 0.25s ease;
  min-height: 44px;
}

.s0x-btn:focus-visible {
  outline: 3px solid var(--s0x-blue-3);
  outline-offset: 2px;
}

.s0x-btn-primary {
  background: var(--s0x-grad-blue);
  background-size: 180% 180%;
  color: #fff;
  box-shadow: 0 8px 24px rgba(37, 99, 235, 0.40);
}
.s0x-btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(59, 130, 246, 0.55);
  background-position: 100% 50%;
}

.s0x-btn-yellow {
  background: var(--s0x-grad-yellow);
  color: #1E293B;
  box-shadow: 0 8px 24px rgba(250, 204, 21, 0.30);
}
.s0x-btn-yellow:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(250, 204, 21, 0.45);
}

.s0x-btn-green {
  background: linear-gradient(120deg, #16A34A, #22C55E);
  color: #04120a;
  box-shadow: 0 8px 24px rgba(34, 197, 94, 0.30);
}
.s0x-btn-green:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(34, 197, 94, 0.45); }

.s0x-btn-ghost {
  background: rgba(37, 99, 235, 0.12);
  border: 1px solid var(--s0x-border);
  color: var(--s0x-foreground);
}
.s0x-btn-ghost:hover { background: rgba(37, 99, 235, 0.24); border-color: var(--s0x-blue-2); }

.s0x-btn-danger {
  background: rgba(239, 68, 68, 0.14);
  border: 1px solid rgba(239, 68, 68, 0.5);
  color: #fca5a5;
}
.s0x-btn-danger:hover { background: rgba(239, 68, 68, 0.28); }

.s0x-btn-sm { padding: 0.5rem 1rem; font-size: 0.9rem; min-height: 38px; }
.s0x-btn:disabled { opacity: 0.55; cursor: not-allowed; transform: none !important; }

/* ---------- Shared cards / badges ---------- */
.s0x-card {
  background: linear-gradient(160deg, var(--s0x-card), var(--s0x-card-2));
  border: 1px solid var(--s0x-border);
  border-radius: var(--s0x-radius);
}

.s0x-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.3rem 0.8rem;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.3;
}

.s0x-badge.active { background: rgba(34, 197, 94, 0.16); color: #4ade80; border: 1px solid rgba(34, 197, 94, 0.4); }
.s0x-badge.pending { background: rgba(245, 158, 11, 0.16); color: #fbbf24; border: 1px solid rgba(245, 158, 11, 0.4); }
.s0x-badge.rejected { background: rgba(239, 68, 68, 0.16); color: #f87171; border: 1px solid rgba(239, 68, 68, 0.4); }
.s0x-badge.expired { background: rgba(225, 29, 72, 0.16); color: #fb7185; border: 1px solid rgba(225, 29, 72, 0.4); }
.s0x-badge.deleted { background: rgba(148, 163, 184, 0.16); color: #cbd5e1; border: 1px solid rgba(148, 163, 184, 0.4); }

.s0x-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--s0x-border), transparent);
  border: none;
}

.s0x-gradient-text {
  background: var(--s0x-grad);
  background-size: 220% 220%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: s0xGradientMove 6s ease-in-out infinite;
}

.s0x-scroll-reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}
.s0x-scroll-reveal.s0x-visible { opacity: 1; transform: translateY(0); }

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