/* ==========================================================================
   AccuAvail — custom styles layered on top of Tailwind (CDN, utility-first).
   Design tokens mirror the Tailwind config in index.html.
   ========================================================================== */

:root {
  --bg-primary: #080D18;
  --bg-secondary: #0D1524;
  --card: #111C2E;
  --card-elevated: #16243A;
  --accent: #4C5FE0;
  --accent-2: #EC0A8A;
  --text-primary: #F8FAFC;
  --text-secondary: #CBD5E1;
  --border: #263449;
  --success: #22C55E;
  --warning: #F59E0B;
}

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg-primary);
  color: var(--text-primary);
  font-family: 'Inter', 'Manrope', sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  font-feature-settings: 'tnum' 1, 'cv11' 1;
  overflow-x: hidden;
  position: relative;
}

/* Fixed, left-aligned watermark of the brand image — desktop only, sits
   behind all page content and doesn't scroll with it. */
@media (min-width: 1024px) {
  body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image: url('../img/nothing-is-assumed.png');
    background-size: cover;
    background-position: left center;
    background-repeat: no-repeat;
    opacity: 0.15;
    filter: brightness(1.6) saturate(1.2);
    z-index: -1;
    pointer-events: none;
  }
}

/* Headings use Manrope for a distinct, confident display voice;
   body copy stays on Inter for small-size screen legibility. */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Manrope', 'Inter', sans-serif;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

p {
  line-height: 1.65;
}

/* Subtle scanline / grid texture used behind hero, kept very faint */
.bg-grid {
  background-image:
    linear-gradient(to right, rgba(148, 163, 184, 0.06) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(148, 163, 184, 0.06) 1px, transparent 1px);
  background-size: 40px 40px;
}

.text-gradient {
  background: linear-gradient(90deg, #F8FAFC 0%, var(--accent-2) 55%, var(--accent) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ---- Nav ----
   Light panel (rather than dark/transparent) so the logo's dark wordmark
   and tagline stay legible against the page's very dark background. */
#site-nav {
  background-color: rgba(248, 250, 252, 0.94);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
  transition: background-color 300ms ease, backdrop-filter 300ms ease, border-color 300ms ease, box-shadow 300ms ease;
}
#site-nav.nav-scrolled {
  background-color: rgba(248, 250, 252, 0.98);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-color: rgba(15, 23, 42, 0.1);
  box-shadow: 0 8px 30px -10px rgba(0,0,0,0.25);
}

#mobile-menu {
  max-height: 0;
  overflow: hidden;
  transition: max-height 320ms ease;
}
#mobile-menu.open {
  max-height: 480px;
}

/* ---- Reveal on scroll ---- */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 650ms cubic-bezier(.22,.61,.36,1), transform 650ms cubic-bezier(.22,.61,.36,1);
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}
.reveal-delay-1 { transition-delay: 90ms; }
.reveal-delay-2 { transition-delay: 180ms; }
.reveal-delay-3 { transition-delay: 270ms; }
.reveal-delay-4 { transition-delay: 360ms; }

/* ---- Cards ---- */
.panel-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
}
.panel-card-elevated {
  background: var(--card-elevated);
  border: 1px solid var(--border);
  border-radius: 16px;
}

.hover-card {
  transition: transform 300ms ease, border-color 300ms ease, box-shadow 300ms ease;
}
.hover-card:hover {
  transform: translateY(-4px);
  border-color: rgba(76, 95, 224, 0.45);
  box-shadow: 0 20px 40px -24px rgba(76, 95, 224, 0.35);
}

/* ---- Buttons ---- */
.btn-primary {
  background: linear-gradient(135deg, #4C5FE0, #2563EB);
  color: #F8FAFC;
  box-shadow: 0 10px 30px -10px rgba(76,95,224,0.55);
  transition: transform 220ms ease, box-shadow 220ms ease, filter 220ms ease;
}
.btn-primary:hover {
  transform: translateY(-2px);
  filter: brightness(1.08);
  box-shadow: 0 16px 36px -10px rgba(76,95,224,0.7);
}
.btn-secondary {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-primary);
  transition: border-color 220ms ease, background-color 220ms ease, transform 220ms ease;
}
.btn-secondary:hover {
  border-color: rgba(76,95,224,0.6);
  background-color: rgba(76,95,224,0.08);
  transform: translateY(-2px);
}

/* ---- Hero mockup ---- */
.mockup-shell {
  border: 1px solid var(--border);
  background: linear-gradient(180deg, #0F1A2C 0%, #0B1220 100%);
  border-radius: 20px;
  box-shadow: 0 40px 80px -30px rgba(0,0,0,0.6);
}

.doc-card {
  opacity: 0;
  transform: translateX(-12px);
  animation: doc-in 560ms ease forwards;
}
.doc-card:nth-child(1) { animation-delay: 0.2s; }
.doc-card:nth-child(2) { animation-delay: 0.55s; }
.doc-card:nth-child(3) { animation-delay: 0.9s; }
.doc-card:nth-child(4) { animation-delay: 1.25s; }

@keyframes doc-in {
  from { opacity: 0; transform: translateX(-12px); }
  to { opacity: 1; transform: translateX(0); }
}

.pulse-dot {
  box-shadow: 0 0 0 0 rgba(236, 10, 138, 0.6);
  animation: pulse-ring 2.2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}
@keyframes pulse-ring {
  0% { box-shadow: 0 0 0 0 rgba(236, 10, 138, 0.55); }
  70% { box-shadow: 0 0 0 8px rgba(236, 10, 138, 0); }
  100% { box-shadow: 0 0 0 0 rgba(236, 10, 138, 0); }
}

.scan-line {
  position: absolute;
  left: 8%;
  right: 8%;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent-2), transparent);
  animation: scan-move 2.6s ease-in-out infinite;
  opacity: 0.85;
}
@keyframes scan-move {
  0% { top: 14%; opacity: 0; }
  10% { opacity: 0.9; }
  90% { opacity: 0.9; }
  100% { top: 82%; opacity: 0; }
}

.progress-fill {
  width: 0%;
  animation: progress-grow 2.4s ease-in-out infinite;
}
@keyframes progress-grow {
  0% { width: 8%; }
  50% { width: 92%; }
  100% { width: 8%; }
}

.flow-line {
  stroke-dasharray: 6 6;
  animation: dash-move 2s linear infinite;
}
@keyframes dash-move {
  to { stroke-dashoffset: -24; }
}

.flow-line-glow {
  filter: drop-shadow(0 0 6px rgba(76,95,224,0.55));
}

.typing-caret::after {
  content: '|';
  animation: caret-blink 1s steps(1) infinite;
  color: var(--accent-2);
}
@keyframes caret-blink {
  50% { opacity: 0; }
}

/* ---- Workflow connector (How it works), desktop horizontal layout only ---- */
@media (min-width: 1024px) {
  .connector-line {
    position: relative;
  }
  .connector-line::after {
    content: '';
    position: absolute;
    top: 28px;
    left: 100%;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, var(--accent), transparent);
  }
}

/* ---- Tabs ---- */
.tab-btn {
  color: var(--text-secondary);
  border-bottom: 2px solid transparent;
  transition: color 200ms ease, border-color 200ms ease;
}
.tab-btn.active {
  color: var(--text-primary);
  border-color: var(--accent-2);
}
.tab-panel {
  display: none;
}
.tab-panel.active {
  display: block;
}

/* ---- Marquee / logo-less customer strip ---- */
.chip {
  border: 1px solid var(--border);
  background: rgba(255,255,255,0.02);
}

/* ---- Floating demo CTA ---- */
#floating-cta {
  opacity: 0;
  transform: translateY(16px);
  pointer-events: none;
  transition: opacity 280ms ease, transform 280ms ease;
}
#floating-cta.show {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

/* ---- Utility ---- */
.max-w-content {
  max-width: 1280px;
}

::selection {
  background: rgba(76,95,224,0.35);
}

.border-dim { border-color: var(--border); }

@media (max-width: 768px) {
  .flow-line-glow { display: none; }
}
