/* ==========================================================================
   BareNOC Waitlist — styles.css
   Custom layer on top of Tailwind: glow effects, micro-interactions,
   animations, and accessibility helpers.
   ========================================================================== */

/* ---------- Base ---------- */
html {
  scroll-behavior: smooth;
}

body {
  background-color: #f8fafc;
}

::selection {
  background: rgba(99, 102, 241, 0.35);
  color: #fff;
}

/* Thin dark scrollbar */
::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: #f1f5f9; }
::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 8px;
  border: 2px solid #f1f5f9;
}
::-webkit-scrollbar-thumb:hover { background: #94a3b8; }


/* ---------- Hero blueprint grid ---------- */
.hero-grid {
  background-image:
    linear-gradient(to right, rgba(15, 23, 42, 0.07) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(15, 23, 42, 0.07) 1px, transparent 1px);
  background-size: 56px 56px;
}

/* ---------- Primary CTA button ---------- */
.btn-primary {
  background: linear-gradient(135deg, #6366f1 0%, #7c3aed 55%, #4f46e5 100%);
  background-size: 150% 150%;
  box-shadow:
    0 8px 24px -8px rgba(99, 102, 241, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.18);
}

.btn-primary:hover {
  background-position: 90% 50%;
  box-shadow:
    0 12px 32px -8px rgba(99, 102, 241, 0.7),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
  transform: translateY(-1px);
}

.btn-primary:active { transform: translateY(0) scale(0.98); }

.btn-primary:disabled {
  cursor: not-allowed;
  opacity: 0.8;
  transform: none;
}

/* Shine sweep on hover */
.btn-primary::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, 0.35) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform 0.7s ease;
}
.btn-primary:hover::after { transform: translateX(120%); }

/* ---------- Email input ---------- */
.input { transition: background-color 0.25s ease, box-shadow 0.25s ease; }
.input:focus { background-color: rgba(99, 102, 241, 0.04); }

/* ---------- Dashboard mock ---------- */
.mock-tilt {
  transform: perspective(1400px) rotateX(5deg);
  transform-origin: top center;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.mock-tilt:hover { transform: perspective(1400px) rotateX(0deg) translateY(-4px); }

.chart-bar {
  flex: 1;
  border-radius: 3px 3px 1px 1px;
  background: linear-gradient(to top, rgba(99, 102, 241, 0.25), rgba(99, 102, 241, 0.85));
  transition: filter 0.3s ease;
}
.chart-bar:hover { filter: brightness(1.35); }
.chart-bar-live {
  background: linear-gradient(to top, rgba(34, 211, 238, 0.3), rgba(34, 211, 238, 0.95));
  animation: pulse-bar 1.6s ease-in-out infinite;
}

@keyframes pulse-bar {
  0%, 100% { box-shadow: 0 0 6px rgba(34, 211, 238, 0.25); }
  50%      { box-shadow: 0 0 14px rgba(34, 211, 238, 0.55); }
}

/* ---------- Floating badges ---------- */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-10px); }
}
.animate-float        { animation: float 6s ease-in-out infinite; }
.animate-float-delayed{ animation: float 7s ease-in-out 1.4s infinite; }
.animate-float-slow   { animation: float 8s ease-in-out 0.6s infinite; }

/* ---------- Pulsing "live" dot ---------- */
@keyframes pulse-dot {
  0%   { transform: scale(1);   opacity: 0.8; }
  70%  { transform: scale(2.6); opacity: 0; }
  100% { transform: scale(2.6); opacity: 0; }
}
.pulse-dot { animation: pulse-dot 1.8s ease-out infinite; }

/* ---------- Logo marquee ---------- */
@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
.marquee-track {
  animation: marquee 28s linear infinite;
  will-change: transform;
}
.marquee:hover .marquee-track { animation-play-state: paused; }

/* ---------- Scroll reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 0.7s ease,
    transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
  transition-delay: var(--d, 0ms);
}
.reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* Success checkmark draw */
@keyframes draw { to { stroke-dashoffset: 0; } }
.check-path {
  stroke-dasharray: 42;
  stroke-dashoffset: 42;
  animation: draw 0.55s 0.25s ease forwards;
}

/* ---------- Feature cards ---------- */
.feature-card {
  background-image: radial-gradient(600px circle at var(--mx, 50%) var(--my, 0%), rgba(99, 102, 241, 0.08), transparent 45%);
}
@media (hover: hover) {
  .feature-card:hover { box-shadow: 0 24px 48px -24px rgba(15, 23, 42, 0.15); }
}

/* ---------- Focus visibility (keyboard users) ---------- */
a:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: 2px solid #818cf8;
  outline-offset: 3px;
  border-radius: 6px;
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
  .marquee-track { animation: none; }
}

/* ---------- Header: frosted on scroll (light) ---------- */
.header-scrolled {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
}

/* ==========================================================================
   Wiki / Docs content (generated by scripts/build_wiki.py)
   ========================================================================== */
.wiki-content { color: #1e293b; }

.wiki-h1 {
  margin-top: 0;
  font-size: 2rem;
  line-height: 1.15;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #0f172a;
}
.wiki-h2 {
  margin-top: 2.5rem;
  font-size: 1.4rem;
  line-height: 1.3;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: #0f172a;
  scroll-margin-top: 6rem;
}
.wiki-h3 {
  margin-top: 2rem;
  font-size: 1.125rem;
  line-height: 1.35;
  font-weight: 600;
  color: #0f172a;
  scroll-margin-top: 6rem;
}

.wiki-content .wiki-p {
  margin: 1rem 0;
  font-size: 0.95rem;
  line-height: 1.75;
  color: #334155;
}

.wiki-content a {
  color: #4f46e5;
  text-decoration: underline;
  text-decoration-color: #c7d2fe;
  text-underline-offset: 2px;
}
.wiki-content a:hover { color: #4338ca; }

.wiki-content code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.85em;
  background: #eef2ff;
  color: #3730a3;
  padding: 0.12em 0.38em;
  border-radius: 6px;
  white-space: nowrap;
}
.wiki-content pre code {
  white-space: pre;
  background: transparent;
  color: inherit;
  padding: 0;
}

.wiki-pre,
.wiki-content pre.mermaid {
  margin: 1.25rem 0;
  overflow-x: auto;
  border-radius: 0.75rem;
  background: #0f172a;
  color: #e2e8f0;
  padding: 1rem 1.25rem;
  font-size: 0.82rem;
  line-height: 1.6;
}
.wiki-content pre.mermaid {
  background: #f8fafc;
  color: #1e293b;
  border: 1px solid #e2e8f0;
}

.wiki-blockquote {
  margin: 1.25rem 0;
  border-left: 4px solid #818cf8;
  border-radius: 0 0.75rem 0.75rem 0;
  background: rgba(238, 242, 255, 0.6);
  padding: 0.75rem 1rem;
}
.wiki-blockquote p {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.65;
  color: #334155;
}

.wiki-content .wiki-ul,
.wiki-content .wiki-ol {
  margin: 1rem 0;
  padding-left: 1.4rem;
  font-size: 0.95rem;
  line-height: 1.7;
  color: #334155;
}
.wiki-content .wiki-ul { list-style: disc; }
.wiki-content .wiki-ul .wiki-ul { list-style: circle; margin: 0.25rem 0; }
.wiki-content .wiki-ol { list-style: decimal; }
.wiki-content .wiki-ol .wiki-ol { list-style: lower-alpha; margin: 0.25rem 0; }
.wiki-content li { margin: 0.35rem 0; }

.wiki-content table {
  border-collapse: collapse;
}
.wiki-content th {
  font-weight: 600;
  text-align: left;
  white-space: nowrap;
}
.wiki-content td {
  vertical-align: top;
}

/* Mermaid diagram centering inside docs */
.wiki-content pre.mermaid { text-align: center; }
.wiki-content pre.mermaid svg { max-width: 100%; height: auto; }

@media (prefers-reduced-motion: reduce) {
  .wiki-content pre.mermaid { display: none; }
}
