/* Intrace Solutions — Ledger Design System Stylesheet
   Crafted with Pitch-black canvas, hairline white borders, and vibrant Intrace Azure/Royal Blue accents.
   Replaces all emerald/green tints with professional, high-trust enterprise cobalt & cyan blue tones. */

:root {
  --color-brand-lit: #38bdf8;
  --color-brand-primary: #0070d8;
  --color-brand-soft: #60a5fa;
  --color-brand-dark: #1d4ed8;
  --color-mint: #38bdf8; /* Replaced green mint with luminous azure cyan */
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  --font-geist: 'Geist', 'Inter', sans-serif;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background-color: #000000;
  color: #cbd5e1;
  overflow-x: hidden;
}

.font-geist {
  font-family: 'Geist', 'Inter', sans-serif !important;
}

/* Custom Scrollbar */
.custom-scrollbar::-webkit-scrollbar { width: 6px; height: 6px; }
.custom-scrollbar::-webkit-scrollbar-track { background: transparent; }
.custom-scrollbar::-webkit-scrollbar-thumb { background: #1e293b; border-radius: 9999px; }
.custom-scrollbar::-webkit-scrollbar-thumb:hover { background: #334155; }

/* Marquee Animations */
@keyframes marquee-rtl {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}
@keyframes marquee-ltr {
  0% { transform: translateX(-50%); }
  100% { transform: translateX(0); }
}
.animate-marquee-rtl { animation: marquee-rtl 25s linear infinite; }
.animate-marquee-ltr { animation: marquee-ltr 25s linear infinite; }
.animate-marquee-rtl:hover, .animate-marquee-ltr:hover { animation-play-state: paused; }

/* Fade & Slide Animation */
@keyframes fadeSlideIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.animate-on-scroll {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}
.animate-on-scroll.animate {
  opacity: 1;
  transform: translateY(0);
}

/* Entrance Sequence Animation */
@keyframes animationIn {
  0% {
    opacity: 0;
    transform: translateY(30px);
    filter: blur(8px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0px);
  }
}

/* Gradient Borders Utility */
[style*="--border-gradient"]::before {
  content: "";
  position: absolute;
  inset: 0;
  padding: 1px;
  border-radius: var(--border-radius-before, inherit);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  background: var(--border-gradient);
  pointer-events: none;
}

/* 3D Perspective Utilities */
.perspective-none { perspective: none !important; }
.perspective-dramatic { perspective: 100px !important; }
.perspective-near { perspective: 300px !important; }
.perspective-normal { perspective: 500px !important; }
.perspective-midrange { perspective: 800px !important; }
.perspective-distant { perspective: 1200px !important; }
.transform-style-preserve-3d { transform-style: preserve-3d !important; }
.transform-style-flat { transform-style: flat !important; }

/* ==========================================================================
   SHINY CTA BUTTON (Enterprise Intrace Blue Edition)
   Spinning conic border beam in Royal Blue & Electric Cyan
   ========================================================================== */
@property --gradient-angle { syntax: "<angle>"; initial-value: 0deg; inherits: false; }
@property --gradient-angle-offset { syntax: "<angle>"; initial-value: 0deg; inherits: false; }
@property --gradient-percent { syntax: "<percentage>"; initial-value: 20%; inherits: false; }
@property --gradient-shine { syntax: "<color>"; initial-value: #38bdf8; inherits: false; }

.shiny-cta {
  --gradient-angle: 0deg;
  --gradient-angle-offset: 0deg;
  --gradient-percent: 20%;
  --gradient-shine: #38bdf8;
  position: relative;
  overflow: hidden;
  border-radius: 9999px;
  padding: 1.15rem 2.25rem;
  font-size: 1.05rem;
  line-height: 1.2;
  font-weight: 500;
  color: #ffffff;
  background: linear-gradient(#05070d, #05070d) padding-box,
              conic-gradient(from calc(var(--gradient-angle) - var(--gradient-angle-offset)),
                             transparent 0%,
                             #1d4ed8 6%,
                             var(--gradient-shine) 16%,
                             #2563eb 28%,
                             transparent 38%,
                             transparent 100%) border-box;
  border: 2px solid transparent;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08), 0 0 25px rgba(37, 99, 235, 0.25);
  outline: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  cursor: pointer;
  isolation: isolate;
  font-family: 'Geist', sans-serif;
  z-index: 0;
  animation: border-spin 3s linear infinite;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  text-decoration: none;
}

@keyframes border-spin {
  to { --gradient-angle: 360deg; }
}

.shiny-cta:hover {
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.15), 0 0 35px rgba(56, 189, 248, 0.45);
  transform: translateY(-1px);
}
.shiny-cta:active {
  transform: translateY(1px);
}

/* Button Utilities */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: 'Geist', sans-serif;
  font-weight: 500;
  border-radius: 9999px;
  padding: 0.75rem 1.5rem;
  font-size: 0.95rem;
  transition: all 0.2s ease;
  cursor: pointer;
  text-decoration: none;
}
.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
}
.btn-primary {
  background: #0070d8;
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0 4px 14px rgba(0, 112, 216, 0.35);
}
.btn-primary:hover {
  background: #2563eb;
  box-shadow: 0 6px 20px rgba(37, 99, 235, 0.5);
  transform: translateY(-1px);
}
.btn-ghost {
  background: rgba(255, 255, 255, 0.04);
  color: #cbd5e1;
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(56, 189, 248, 0.3);
  color: #ffffff;
  transform: translateY(-1px);
}

.btn-secondary-ledger {
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #e2e8f0;
  border-radius: 9999px;
  padding: 1.15rem 2rem;
  font-family: 'Geist', sans-serif;
  font-size: 1rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: all 0.2s ease;
  backdrop-filter: blur(12px);
  text-decoration: none;
}
.btn-secondary-ledger:hover {
  background: rgba(30, 41, 59, 0.8);
  border-color: rgba(56, 189, 248, 0.4);
  color: #ffffff;
  transform: translateY(-1px);
}

/* ==========================================================================
   GLASS CARDS (Ledger Standard)
   ========================================================================== */
.glass-card, .glass-panel {
  background: rgba(10, 11, 14, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1.5rem;
  padding: 2rem;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.7);
  transition: border-color 0.3s ease, box-shadow 0.3s ease, transform 0.2s ease;
  position: relative;
  overflow: hidden;
}
.glass-card:hover, .glass-panel:hover {
  border-color: rgba(56, 189, 248, 0.3);
  box-shadow: 0 25px 50px -15px rgba(0, 0, 0, 0.8), 0 0 25px rgba(37, 99, 235, 0.12);
}
.glass-card.glow {
  border-color: rgba(56, 189, 248, 0.25);
  box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.7), 0 0 20px rgba(56, 189, 248, 0.1);
}

/* Typography Helpers */
.gradient-text {
  background: linear-gradient(135deg, #60a5fa 0%, #38bdf8 50%, #93c5fd 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  display: inline-block;
}
.t-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #38bdf8;
  margin-bottom: 0.5rem;
}
.t-h2 {
  font-family: 'Geist', sans-serif;
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 300;
  letter-spacing: -0.03em;
  color: #ffffff;
  line-height: 1.15;
}
.t-h3 {
  font-family: 'Geist', sans-serif;
  font-size: 1.35rem;
  font-weight: 500;
  color: #ffffff;
  letter-spacing: -0.01em;
  margin-top: 0.25rem;
}
.t-lead {
  font-size: 1.1rem;
  line-height: 1.65;
  color: #94a3b8;
  font-weight: 300;
}

/* Grids */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

/* Shimmer Ring (.ds-ring) */
.ds-ring {
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.4), transparent 60%);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}
.ds-ring.is-accent {
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.6), rgba(56, 189, 248, 0.6) 50%, transparent);
}

/* ==========================================================================
   METRIC & CHART ANIMATIONS (Looping Volume Bars)
   ========================================================================== */
@keyframes barCycle {
  0% { transform: scaleY(0); opacity: 0; }
  20% { transform: scaleY(1); opacity: 1; }
  80% { transform: scaleY(1); opacity: 1; }
  95% { transform: scaleY(0); opacity: 0; }
  100% { transform: scaleY(0); opacity: 0; }
}

.animate-bar-loop {
  transform-origin: bottom;
  animation: barCycle 6s cubic-bezier(0.33, 1, 0.68, 1) infinite;
}

/* Telemetry Pulse Dots */
.pulse-dot {
  position: relative;
  display: inline-flex;
  height: 8px;
  width: 8px;
  border-radius: 9999px;
}
.pulse-dot.azure .pulse-dot-core, .pulse-dot.mint .pulse-dot-core { background-color: #38bdf8; }
.pulse-dot.azure .pulse-dot-ring, .pulse-dot.mint .pulse-dot-ring { background-color: #38bdf8; }

.pulse-dot-core {
  position: relative;
  display: inline-flex;
  border-radius: 9999px;
  height: 8px;
  width: 8px;
}
.pulse-dot-ring {
  position: absolute;
  inset: 0;
  border-radius: 9999px;
  animation: pulsePing 2s cubic-bezier(0, 0, 0.2, 1) infinite;
  opacity: 0.75;
}
@keyframes pulsePing {
  75%, 100% { transform: scale(2.5); opacity: 0; }
}

/* Audio Waveform Container */
.waveform-container {
  display: flex;
  align-items: center;
  gap: 3.5px;
  height: 36px;
  flex: 1;
}
.wave-bar {
  width: 3px;
  border-radius: 9999px;
  background: rgba(56, 189, 248, 0.3);
  height: 8px;
  transition: height 0.15s ease, background-color 0.2s ease;
}
.wave-bar.active {
  background: #38bdf8;
  box-shadow: 0 0 10px rgba(56, 189, 248, 0.6);
  animation: waveDance 1.2s ease-in-out infinite alternate;
}
@keyframes waveDance {
  0% { height: 6px; }
  100% { height: 28px; }
}

/* Transcript Bubble */
.transcript-item {
  padding: 0.85rem 1rem;
  border-radius: 0.85rem;
  margin-bottom: 0.75rem;
  font-size: 0.875rem;
  line-height: 1.5;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(0, 0, 0, 0.4);
  transition: all 0.25s ease;
}
.transcript-item.agent {
  border-color: rgba(56, 189, 248, 0.25);
  background: rgba(14, 165, 233, 0.08);
}
.transcript-item.caller {
  border-color: rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.03);
}

/* Dropdown Language Menu */
.lang-dropdown-wrapper {
  position: relative;
}
.lang-btn {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #e2e8f0;
  padding: 0.4rem 0.85rem;
  border-radius: 9999px;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.2s ease;
}
.lang-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(56, 189, 248, 0.3);
}
.lang-dropdown-menu {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  width: 140px;
  background: rgba(10, 11, 14, 0.96);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 1rem;
  padding: 0.4rem;
  box-shadow: 0 20px 40px rgba(0,0,0,0.8);
  backdrop-filter: blur(16px);
  z-index: 60;
}
.lang-dropdown-menu.open { display: block; }
.lang-opt {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 0.5rem 0.85rem;
  border-radius: 0.65rem;
  border: none;
  background: transparent;
  color: #cbd5e1;
  font-family: 'Geist', sans-serif;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.15s ease;
}
.lang-opt:hover {
  background: rgba(56, 189, 248, 0.15);
  color: #ffffff;
}

/* Mobile Drawer */
.mobile-nav-drawer {
  display: none;
  position: fixed;
  top: 5.5rem;
  left: 1.25rem;
  right: 1.25rem;
  background: rgba(10, 11, 14, 0.96);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 1.5rem;
  padding: 1.5rem;
  box-shadow: 0 30px 60px rgba(0,0,0,0.9);
  backdrop-filter: blur(24px);
  z-index: 99;
  flex-direction: column;
  gap: 1rem;
}
.mobile-nav-drawer.open { display: flex; }
.mobile-nav-link {
  font-family: 'Geist', sans-serif;
  font-size: 1.1rem;
  color: #cbd5e1;
  padding: 0.5rem 0.75rem;
  border-radius: 0.5rem;
  cursor: pointer;
  transition: color 0.2s ease, background-color 0.2s ease;
}
.mobile-nav-link:hover, .mobile-nav-link.active {
  color: #38bdf8;
  background: rgba(255, 255, 255, 0.05);
}
.nav-link {
  transition: color 0.2s ease;
}
.nav-link.active {
  color: #38bdf8 !important;
}

.section-spacing {
  padding-top: clamp(4rem, 8vw, 7rem);
  padding-bottom: clamp(4rem, 8vw, 7rem);
}
.wrap {
  width: 100%;
  max-width: 1340px;
  margin-left: auto;
  margin-right: auto;
  padding-left: clamp(1rem, 4vw, 2.5rem);
  padding-right: clamp(1rem, 4vw, 2.5rem);
}

/* ROI Range Slider & Presets */
#roi-fleet-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 8px;
  border-radius: 9999px;
  background: linear-gradient(to right, #38bdf8 0%, #2563eb var(--slider-fill, 20%), rgba(255, 255, 255, 0.1) var(--slider-fill, 20%), rgba(255, 255, 255, 0.1) 100%);
  outline: none;
  cursor: pointer;
}

#roi-fleet-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #ffffff;
  border: 3px solid #2563eb;
  box-shadow: 0 0 16px rgba(56, 189, 248, 0.8), 0 2px 6px rgba(0, 0, 0, 0.6);
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

#roi-fleet-slider::-webkit-slider-thumb:hover {
  transform: scale(1.15);
  box-shadow: 0 0 22px rgba(56, 189, 248, 1), 0 2px 8px rgba(0, 0, 0, 0.8);
}

#roi-fleet-slider::-moz-range-thumb {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #ffffff;
  border: 3px solid #2563eb;
  box-shadow: 0 0 16px rgba(56, 189, 248, 0.8);
  cursor: pointer;
}

/* Preset Buttons */
.roi-preset-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.35rem 0.85rem;
  border-radius: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
  color: #94a3b8;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  cursor: pointer;
  position: relative;
  z-index: 20;
  pointer-events: auto;
  user-select: none;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.roi-preset-btn:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(56, 189, 248, 0.4);
}

.roi-preset-btn.active {
  color: #38bdf8 !important;
  background: rgba(30, 58, 138, 0.55) !important;
  border-color: rgba(56, 189, 248, 0.7) !important;
  box-shadow: 0 0 16px rgba(56, 189, 248, 0.4), inset 0 0 8px rgba(56, 189, 248, 0.2) !important;
  font-weight: 600;
}

/* Scale Ticks */
.roi-tick-btn {
  background: transparent;
  border: none;
  color: #64748b;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  cursor: pointer;
  position: relative;
  z-index: 20;
  pointer-events: auto;
  user-select: none;
  transition: color 0.2s ease;
  padding: 0;
}

.roi-tick-btn:hover, .roi-tick-btn.active {
  color: #38bdf8 !important;
}

.roi-tick-btn .tick-line {
  display: block;
  width: 1px;
  height: 6px;
  background: rgba(255, 255, 255, 0.2);
  margin: 0 auto 4px auto;
  transition: background 0.2s ease, height 0.2s ease;
}

.roi-tick-btn:hover .tick-line, .roi-tick-btn.active .tick-line {
  background: #38bdf8;
  height: 8px;
}
