﻿/* ============================================================
   FVR — Fast Visual Rendering
   Dark, minimal, tech-driven
   ============================================================ */

:root {
  --neon: #22d3ee;
  --lime: #a3e635;
  --volt: #fbbf24;
  --ink-950: #08080c;
  --ink-900: #0c0f16;
  --ink-800: #1a1f2a;
  --ink-700: #2a3140;
  --surface: rgba(18, 22, 32, 0.7);
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.16);
  --text: #e8ebf0;
  --muted: #8595a9;
  --radius: 18px;
  --radius-sm: 12px;
}

* { -webkit-tap-highlight-color: transparent; }
html { scroll-behavior: smooth; color-scheme: dark; }

body {
  background: var(--ink-950);
  color: var(--text);
  font-family: 'Inter', system-ui, sans-serif;
  min-height: 100vh;
  overflow-x: hidden;
  letter-spacing: -0.005em;
}

/* ============================================================
   BACKGROUND SCENE
   ============================================================ */

.bg-scene {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
  background: radial-gradient(ellipse at top, #0c1018 0%, #06060a 60%, #040408 100%);
}

.bg-aurora {
  position: absolute;
  inset: -20%;
  background:
    radial-gradient(900px 700px at 15% 10%, rgba(34,211,238,0.10), transparent 60%),
    radial-gradient(800px 600px at 85% 20%, rgba(163,230,53,0.07), transparent 60%),
    radial-gradient(1000px 800px at 50% 100%, rgba(34,211,238,0.06), transparent 60%);
  animation: auroraMove 24s ease-in-out infinite alternate;
  will-change: transform;
}
@keyframes auroraMove {
  0%   { transform: translate3d(0,0,0) scale(1); }
  50%  { transform: translate3d(-3%, 2%, 0) scale(1.06); }
  100% { transform: translate3d(2%, -2%, 0) scale(1); }
}

.bg-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(circle at center, black 20%, transparent 70%);
  -webkit-mask-image: radial-gradient(circle at center, black 20%, transparent 70%);
  animation: gridMove 40s linear infinite;
  will-change: background-position;
}
@keyframes gridMove {
  0%   { background-position: 0 0, 0 0; }
  100% { background-position: 48px 48px, 48px 48px; }
}

.bg-scanlines {
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    rgba(255,255,255,0.015) 0px,
    rgba(255,255,255,0.015) 1px,
    transparent 1px,
    transparent 3px
  );
  opacity: 0.5;
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.35;
  will-change: transform;
  pointer-events: none;
}
.orb-1 {
  width: 500px; height: 500px;
  top: -10%; left: -10%;
  background: radial-gradient(circle at 30% 30%, #22d3ee, #0891b2 45%, transparent 70%);
  animation: orbMove1 26s ease-in-out infinite alternate;
}
.orb-2 {
  width: 400px; height: 400px;
  bottom: -10%; right: -5%;
  background: radial-gradient(circle at 40% 40%, #a3e635, #65a30d 50%, transparent 72%);
  animation: orbMove2 30s ease-in-out infinite alternate;
}
.orb-3 {
  width: 380px; height: 380px;
  top: 40%; left: 40%;
  background: radial-gradient(circle at 50% 50%, #fbbf24, #d97706 50%, transparent 72%);
  opacity: 0.18;
  animation: orbMove3 22s ease-in-out infinite alternate;
}
@keyframes orbMove1 {
  0%   { transform: translate3d(0,0,0) scale(1); }
  50%  { transform: translate3d(140px, 90px, 0) scale(1.15); }
  100% { transform: translate3d(-60px, 160px, 0) scale(1.05); }
}
@keyframes orbMove2 {
  0%   { transform: translate3d(0,0,0) scale(1); }
  50%  { transform: translate3d(-120px, -80px, 0) scale(1.2); }
  100% { transform: translate3d(-40px, -160px, 0) scale(1); }
}
@keyframes orbMove3 {
  0%   { transform: translate3d(0,0,0) scale(1); }
  50%  { transform: translate3d(80px, -80px, 0) scale(1.15); }
  100% { transform: translate3d(-70px, 60px, 0) scale(1.05); }
}

.particles { position: absolute; inset: 0; overflow: hidden; }
.particle {
  position: absolute;
  width: 2px; height: 2px;
  border-radius: 50%;
  background: #67e8f9;
  box-shadow: 0 0 8px #22d3ee, 0 0 3px #67e8f9;
  opacity: 0;
  animation: particleFloat linear infinite;
  will-change: transform, opacity;
}
@keyframes particleFloat {
  0%   { transform: translate3d(0, 100vh, 0) scale(0.5); opacity: 0; }
  10%  { opacity: 0.9; }
  90%  { opacity: 0.9; }
  100% { transform: translate3d(var(--x, 40px), -20vh, 0) scale(1); opacity: 0; }
}

.particle:nth-child(1)  { left: 6%;  animation-duration: 22s; animation-delay: 0s;   --x: 30px;  background:#22d3ee; }
.particle:nth-child(2)  { left: 15%; animation-duration: 18s; animation-delay: 2s;   --x: -40px; background:#a3e635; }
.particle:nth-child(3)  { left: 24%; animation-duration: 26s; animation-delay: 4s;   --x: 60px;  background:#22d3ee; }
.particle:nth-child(4)  { left: 33%; animation-duration: 20s; animation-delay: 1s;   --x: -30px; background:#fbbf24; }
.particle:nth-child(5)  { left: 44%; animation-duration: 24s; animation-delay: 6s;   --x: 50px;  background:#22d3ee; }
.particle:nth-child(6)  { left: 55%; animation-duration: 19s; animation-delay: 3s;   --x: -60px; background:#a3e635; }
.particle:nth-child(7)  { left: 64%; animation-duration: 28s; animation-delay: 5s;   --x: 40px;  background:#22d3ee; }
.particle:nth-child(8)  { left: 72%; animation-duration: 21s; animation-delay: 7s;   --x: -50px; background:#67e8f9; }
.particle:nth-child(9)  { left: 81%; animation-duration: 25s; animation-delay: 0.5s; --x: 30px;  background:#a3e635; }
.particle:nth-child(10) { left: 89%; animation-duration: 23s; animation-delay: 2.5s; --x: -40px; background:#22d3ee; }
.particle:nth-child(11) { left: 94%; animation-duration: 17s; animation-delay: 4.5s; --x: 70px;  background:#67e8f9; }
.particle:nth-child(12) { left: 2%;  animation-duration: 27s; animation-delay: 1.5s; --x: -30px; background:#22d3ee; }

@media (max-width: 768px) {
  .orb-1, .orb-2, .orb-3 { filter: blur(70px); opacity: 0.25; }
  .orb-1 { width: 300px; height: 300px; }
  .orb-2 { width: 260px; height: 260px; }
  .orb-3 { display: none; }
  .particle:nth-child(n+7) { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .orb, .particle, .bg-aurora, .bg-grid { animation: none !important; }
}

/* ============================================================
   TYPE
   ============================================================ */
.h-display {
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 0.95;
}
.text-gradient {
  background: linear-gradient(135deg, #a5f3fc 0%, #22d3ee 45%, #a3e635 100%);
  background-size: 200% 200%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: gradientShift 8s ease infinite;
}
.text-gradient-2 {
  background: linear-gradient(135deg, #fbbf24 0%, #a3e635 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
@keyframes gradientShift {
  0%,100% { background-position: 0% 50%; }
  50%     { background-position: 100% 50%; }
}

.mono { font-family: ui-monospace, "SF Mono", Menlo, monospace; }

/* ============================================================
   SURFACES
   ============================================================ */
.glass {
  background: var(--surface);
  backdrop-filter: blur(20px) saturate(150%);
  -webkit-backdrop-filter: blur(20px) saturate(150%);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.card {
  position: relative;
  background: var(--surface);
  backdrop-filter: blur(20px) saturate(150%);
  -webkit-backdrop-filter: blur(20px) saturate(150%);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  transition: transform .4s cubic-bezier(.2,.8,.2,1),
              border-color .35s ease,
              box-shadow .35s ease;
}
.card:hover {
  transform: translateY(-4px);
  border-color: rgba(34,211,238,0.3);
  box-shadow: 0 30px 70px -30px rgba(34,211,238,0.4);
}
.card-lift { transition: transform .35s ease, border-color .35s ease, box-shadow .35s ease; }
.card-lift:hover {
  transform: translateY(-4px);
  border-color: var(--border-strong);
  box-shadow: 0 20px 50px -20px rgba(0,0,0,0.6);
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .55rem;
  padding: .85rem 1.5rem;
  border-radius: 12px;
  font-weight: 600;
  font-size: .9rem;
  letter-spacing: -0.01em;
  transition: all .25s cubic-bezier(.2,.8,.2,1);
  cursor: pointer;
  border: none;
  text-decoration: none;
  white-space: nowrap;
  position: relative;
  overflow: hidden;
}
.btn > svg,
.btn > i[data-lucide] {
  flex-shrink: 0;
  display: inline-block;
}
.btn-primary {
  background: linear-gradient(135deg, #22d3ee 0%, #06b6d4 100%);
  color: #06232b;
  box-shadow: 0 10px 30px -10px rgba(34,211,238,0.6);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 45px -12px rgba(34,211,238,0.85);
  filter: brightness(1.08);
}
.btn-secondary {
  background: linear-gradient(135deg, #a3e635 0%, #65a30d 100%);
  color: #14250a;
  box-shadow: 0 10px 30px -10px rgba(163,230,53,0.55);
}
.btn-secondary:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 45px -12px rgba(163,230,53,0.85);
}
.btn-ghost {
  background: rgba(255,255,255,0.04);
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-ghost:hover {
  background: rgba(255,255,255,0.08);
  border-color: var(--border-strong);
  transform: translateY(-2px);
}
.btn-lg {
  padding: 1.1rem 2rem;
  font-size: 1rem;
  border-radius: 14px;
}
.btn-block { width: 100%; }

/* ============================================================
   BADGES / TAGS
   ============================================================ */
.tag {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .45rem .9rem;
  border-radius: 999px;
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .02em;
  text-transform: uppercase;
  background: rgba(34,211,238,0.1);
  color: #67e8f9;
  border: 1px solid rgba(34,211,238,0.2);
}
.tag-lime {
  background: rgba(163,230,53,0.1);
  color: #bef264;
  border-color: rgba(163,230,53,0.25);
}
.tag-volt {
  background: rgba(251,191,36,0.1);
  color: #fcd34d;
  border-color: rgba(251,191,36,0.25);
}

.dot-live {
  display: inline-block;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #a3e635;
  box-shadow: 0 0 10px #a3e635;
  animation: pulseLive 2s infinite;
}
@keyframes pulseLive {
  0%,100% { transform: scale(1); opacity: 1; }
  50%     { transform: scale(1.3); opacity: .6; }
}

.glow-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #22d3ee;
  box-shadow: 0 0 12px #22d3ee, 0 0 4px #22d3ee;
}

/* ============================================================
   INPUTS
   ============================================================ */
input, textarea, select {
  width: 100%;
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 14px;
  padding: .85rem 1.05rem;
  font-size: .92rem;
  line-height: 1.6;
  transition: background-color .25s ease, border-color .25s ease, box-shadow .25s ease;
  font-family: inherit;
  outline: none;
  appearance: none;
  -webkit-appearance: none;
}
input:hover, textarea:hover, select:hover {
  border-color: rgba(255,255,255,0.16);
  background: rgba(255,255,255,0.045);
}
input:focus, textarea:focus, select:focus {
  border-color: var(--neon);
  background: rgba(34,211,238,0.05);
  box-shadow: 0 0 0 4px rgba(34,211,238,0.14);
}
input::placeholder, textarea::placeholder { color: #64748b; }
textarea { min-height: 130px; resize: vertical; border-radius: 18px; padding: 1rem 1.15rem; }
select { cursor: pointer; padding-inline-end: 2.75rem;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%2367e8f9' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><polyline points='6 9 12 15 18 9'/></svg>");
  background-repeat: no-repeat;
  background-position: right 0.9rem center;
  background-size: 16px;
}
select option { background: #0f1219; color: #e8ebf0; }
input[type="checkbox"], input[type="radio"] {
  width: 18px !important; height: 18px !important; padding: 0 !important;
  accent-color: var(--neon); cursor: pointer; vertical-align: middle; flex-shrink: 0;
}
input[type="checkbox"].toggle-switch {
  width: 44px !important;
  height: 24px !important;
  appearance: none;
  background: rgba(255,255,255,0.1);
  border-radius: 24px;
  position: relative;
  cursor: pointer;
  transition: background .3s ease;
  border: 1px solid rgba(255,255,255,0.1);
}
input[type="checkbox"].toggle-switch::before {
  content: "";
  position: absolute;
  width: 18px; height: 18px;
  border-radius: 50%;
  background: #fff;
  top: 2px;
  left: 2px;
  transition: transform .3s ease;
}
input[type="checkbox"].toggle-switch:checked {
  background: linear-gradient(135deg, #22d3ee, #06b6d4);
  border-color: transparent;
}
input[type="checkbox"].toggle-switch:checked::before {
  transform: translateX(20px);
  background: #06232b;
}

/* ============================================================
   SCROLLBAR
   ============================================================ */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: #0a0d14; }
::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #22d3ee, #0e7490);
  border-radius: 10px;
  border: 2px solid #0a0d14;
}
::-webkit-scrollbar-thumb:hover { background: #67e8f9; }

::selection { background: rgba(34,211,238,0.35); color: #fff; }

/* ============================================================
   ANIMATIONS
   ============================================================ */
@keyframes fadeUp   { from { opacity:0; transform: translateY(20px); } to { opacity:1; transform: translateY(0); } }
@keyframes fadeIn   { from { opacity:0; } to { opacity:1; } }
@keyframes scaleIn  { from { opacity:0; transform: scale(.95); } to { opacity:1; transform: scale(1); } }
@keyframes slideDown{ from { opacity:0; transform: translateY(-10px); } to { opacity:1; transform: translateY(0); } }
@keyframes slideLeft{ from { opacity:0; transform: translateX(40px); } to { opacity:1; transform: translateX(0); } }
@keyframes floatY   { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes pulseGlow{ 0%,100% { box-shadow: 0 0 0 0 rgba(34,211,238,0.6); } 50% { box-shadow: 0 0 0 14px rgba(34,211,238,0); } }
@keyframes marquee  { from { transform: translateX(0); } to { transform: translateX(-50%); } }

.animate-fade-up   { animation: fadeUp .7s cubic-bezier(.2,.8,.2,1) both; }
.animate-fade-in   { animation: fadeIn .6s ease both; }
.animate-scale-in  { animation: scaleIn .5s cubic-bezier(.2,.8,.2,1) both; }
.animate-slide-down{ animation: slideDown .35s ease both; }
.animate-slide-left{ animation: slideLeft .4s cubic-bezier(.2,.8,.2,1) both; }
.animate-float     { animation: floatY 5s ease-in-out infinite; }
.animate-pulse-glow{ animation: pulseGlow 2.5s ease-in-out infinite; }

.delay-1 { animation-delay: .1s; }
.delay-2 { animation-delay: .2s; }
.delay-3 { animation-delay: .3s; }
.delay-4 { animation-delay: .4s; }
.delay-5 { animation-delay: .5s; }
.delay-6 { animation-delay: .6s; }

/* ============================================================
   LAYOUT
   ============================================================ */
.container-x {
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: 1.5rem;
}
@media (min-width: 768px) {
  .container-x { padding-inline: 2rem; }
}
@media (min-width: 1280px) {
  .container-x { padding-inline: 2.5rem; }
}

.line-clamp-2 { display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; }
.line-clamp-3 { display:-webkit-box; -webkit-line-clamp:3; -webkit-box-orient:vertical; overflow:hidden; }
.line-clamp-4 { display:-webkit-box; -webkit-line-clamp:4; -webkit-box-orient:vertical; overflow:hidden; }

.noise-overlay { position: relative; }
.noise-overlay::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.03;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='100' height='100'><filter id='n'><feTurbulence baseFrequency='0.9' numOctaves='3'/></filter><rect width='100' height='100' filter='url(%23n)'/></svg>");
}

.modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(20px) saturate(120%);
  -webkit-backdrop-filter: blur(20px) saturate(120%);
  z-index: 50;
  animation: fadeIn .25s ease;
}

/* ============================================================
   NAVIGATION LINKS
   ============================================================ */
.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.6rem 0.9rem;
  border-radius: 10px;
  color: #b0bac8;
  text-decoration: none;
  transition: all .2s ease;
  font-weight: 500;
  white-space: nowrap;
}
.nav-link:hover {
  background: rgba(255,255,255,0.05);
  color: #ffffff;
}

.mobile-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  border-radius: 0.75rem;
  color: #cbd5e1;
  text-decoration: none;
  transition: background-color .15s ease;
  white-space: nowrap;
}
.mobile-link:hover {
  background: rgba(255,255,255,0.05);
  color: #ffffff;
}
.mobile-link > span {
  min-width: 0;
}

/* ============================================================
   DASHBOARD / PANEL SIDEBAR LINKS
   ============================================================ */
.dash-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 0.85rem;
  border-radius: 0.75rem;
  color: #cbd5e1;
  text-decoration: none;
  transition: all .15s ease;
  font-size: 0.875rem;
  line-height: 1;
  white-space: nowrap;
  position: relative;
  overflow: hidden;
  text-overflow: ellipsis;
}
.dash-link > svg,
.dash-link > i[data-lucide] {
  flex-shrink: 0;
  width: 1rem;
  height: 1rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.dash-link > span:not(.badge-count) {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}
.dash-link:hover {
  background: rgba(255,255,255,0.04);
  color: #ffffff;
}
.dash-link.active {
  background: linear-gradient(90deg, rgba(34,211,238,0.15) 0%, rgba(34,211,238,0.05) 100%);
  color: #ffffff;
  border: 1px solid rgba(34,211,238,0.25);
}
.dash-link.active::before {
  content: "";
  position: absolute;
  inset-inline-start: -3px;
  top: 20%; bottom: 20%;
  width: 3px;
  border-radius: 3px;
  background: linear-gradient(180deg, #22d3ee, #a3e635);
  box-shadow: 0 0 12px #22d3ee;
}

.badge-count {
  flex-shrink: 0;
  margin-inline-start: auto;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  background: rgba(34,211,238,0.15);
  color: #67e8f9;
  font-size: 0.65rem;
  font-weight: 700;
  line-height: 1.2;
}
.badge-count-warn {
  background: rgba(251,191,36,0.15);
  color: #fcd34d;
}

/* ============================================================
   FILTER CHIPS
   ============================================================ */
.filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 0.9rem;
  border-radius: 999px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  color: #8595a9;
  font-size: 0.75rem;
  font-weight: 600;
  text-decoration: none;
  transition: all .2s ease;
  white-space: nowrap;
}
.filter-chip:hover {
  background: rgba(255,255,255,0.06);
  color: #ffffff;
  border-color: rgba(255,255,255,0.16);
}
.filter-chip.active {
  background: rgba(34,211,238,0.15);
  border-color: rgba(34,211,238,0.4);
  color: #67e8f9;
}

/* ============================================================
   GATEWAY OPTION (Payment)
   ============================================================ */
.gateway-option {
  padding: 0.85rem;
  border-radius: 14px;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.08);
  text-align: center;
  cursor: pointer;
  transition: all .25s ease;
  color: #ffffff;
}
.gateway-option:hover {
  background: rgba(255,255,255,0.05);
  border-color: rgba(255,255,255,0.16);
}

/* ============================================================
   REDUCED MOTION
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

/* ============================================================
   RTL SUPPORT (kept minimal — most styles are logical)
   ============================================================ */
[dir="rtl"] body {
  font-family: 'Cairo', 'Inter', system-ui, sans-serif;
}
[dir="rtl"] select {
  background-position: left 0.9rem center;
}