/* ===========================================================
   voicer — shared stylesheet
   Dark gradient theme · responsive · reduced-motion aware
   =========================================================== */

:root {
  /* core palette */
  --bg:           #07070d;
  --bg-2:         #0c0c16;
  --surface:      rgba(255, 255, 255, 0.035);
  --surface-2:    rgba(255, 255, 255, 0.06);
  --border:       rgba(255, 255, 255, 0.09);
  --border-soft:  rgba(255, 255, 255, 0.05);

  --text:         #f3f3fa;
  --text-soft:    #b7b8c9;
  --text-dim:     #7e7f95;

  /* gradient accents */
  --violet:  #8b5cf6;
  --indigo:  #6366f1;
  --cyan:    #22d3ee;
  --magenta: #ec4899;
  --teal:    #2dd4bf;

  --grad-primary: linear-gradient(120deg, #8b5cf6 0%, #6366f1 38%, #22d3ee 72%, #2dd4bf 100%);
  --grad-warm:    linear-gradient(120deg, #8b5cf6 0%, #ec4899 100%);
  --grad-text:    linear-gradient(100deg, #c4b5fd 0%, #67e8f9 55%, #5eead4 100%);

  --glow-violet: 0 0 40px rgba(139, 92, 246, 0.35);
  --glow-cyan:   0 0 40px rgba(34, 211, 238, 0.30);

  --radius:    18px;
  --radius-sm: 12px;
  --maxw:      1180px;

  --shadow: 0 20px 60px -20px rgba(0, 0, 0, 0.7);

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  position: relative;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

/* ---------- animated background ---------- */
.bg-layer {
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(900px 600px at 12% -8%, rgba(139, 92, 246, 0.22), transparent 60%),
    radial-gradient(800px 600px at 92% 4%, rgba(34, 211, 238, 0.16), transparent 60%),
    radial-gradient(700px 700px at 50% 110%, rgba(45, 212, 191, 0.12), transparent 60%),
    var(--bg);
}
/* slow drifting mesh */
.bg-mesh {
  position: fixed;
  inset: -20%;
  z-index: -2;
  background:
    radial-gradient(40% 40% at 30% 30%, rgba(139, 92, 246, 0.16), transparent 60%),
    radial-gradient(35% 35% at 70% 60%, rgba(34, 211, 238, 0.13), transparent 60%),
    radial-gradient(30% 30% at 50% 80%, rgba(236, 72, 153, 0.10), transparent 60%);
  filter: blur(20px);
  animation: meshDrift 26s ease-in-out infinite alternate;
}
@keyframes meshDrift {
  0%   { transform: translate3d(0,0,0) scale(1); }
  50%  { transform: translate3d(3%, -2%, 0) scale(1.08); }
  100% { transform: translate3d(-3%, 2%, 0) scale(1.04); }
}
/* floating particle canvas sits here */
#particles {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.6;
}
/* subtle grid overlay */
.bg-grid {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(circle at 50% 30%, #000 0%, transparent 75%);
  -webkit-mask-image: radial-gradient(circle at 50% 30%, #000 0%, transparent 75%);
}

/* ---------- layout helpers ---------- */
.container { width: 80%; max-width: 1600px; margin-inline: auto; padding-inline: 0; }
section { padding: 96px 0; position: relative; }
.section-tag {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 0.78rem; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--cyan);
  padding: 6px 14px; border-radius: 999px;
  background: rgba(34, 211, 238, 0.08);
  border: 1px solid rgba(34, 211, 238, 0.2);
  margin-bottom: 20px;
}
.section-head { max-width: 680px; margin-bottom: 56px; }
.section-head.center { margin-inline: auto; text-align: center; }

h1, h2, h3 { line-height: 1.12; font-weight: 700; letter-spacing: -0.02em; }
h1 { font-size: clamp(2.4rem, 6vw, 4.4rem); }
h2 { font-size: clamp(1.9rem, 4vw, 3rem); }
h3 { font-size: 1.25rem; }
p  { color: var(--text-soft); }
.lead { font-size: clamp(1.05rem, 2vw, 1.25rem); color: var(--text-soft); }

.grad-text {
  background: var(--grad-text);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 9px;
  font-weight: 600; font-size: 0.97rem;
  padding: 13px 26px; border-radius: 999px;
  border: 1px solid transparent; cursor: pointer;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), background .25s;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px) scale(.99); }
.btn-primary {
  color: #0a0a12;
  background: var(--grad-primary);
  background-size: 180% 180%;
  box-shadow: 0 10px 30px -8px rgba(99, 102, 241, 0.55);
  animation: btnShift 6s ease infinite;
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 16px 40px -8px rgba(99, 102, 241, 0.7); }
@keyframes btnShift { 0%,100%{background-position:0% 50%} 50%{background-position:100% 50%} }
.btn-ghost {
  color: var(--text);
  background: var(--surface-2);
  border-color: var(--border);
  backdrop-filter: blur(8px);
}
.btn-ghost:hover { background: rgba(255,255,255,0.1); transform: translateY(-2px); }
.btn-lg { padding: 16px 32px; font-size: 1.02rem; }

/* ---------- navbar ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  transition: background .3s, border-color .3s, backdrop-filter .3s;
  border-bottom: 1px solid transparent;
}
.nav.scrolled {
  background: rgba(7, 7, 13, 0.72);
  backdrop-filter: blur(16px) saturate(140%);
  border-bottom-color: var(--border-soft);
}
.nav-inner {
  width: 80%; max-width: 1600px; margin-inline: auto;
  padding: 16px 0;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.brand { display: flex; align-items: center; gap: 11px; font-weight: 700; font-size: 1.15rem; letter-spacing: -0.02em; }
.brand .logo {
  width: 34px; height: 34px; border-radius: 10px;
  background: var(--grad-primary); background-size: 160% 160%;
  display: grid; place-items: center;
  box-shadow: var(--glow-violet);
  animation: btnShift 7s ease infinite;
  position: relative; flex: none;
}
.brand .logo span {
  display: flex; align-items: center; gap: 2.5px; height: 15px;
}
.brand .logo i {
  width: 2.5px; border-radius: 2px; background: #0a0a12;
  animation: bars 1.1s ease-in-out infinite;
}
.brand .logo i:nth-child(1){height:6px;  animation-delay:0s}
.brand .logo i:nth-child(2){height:14px; animation-delay:.15s}
.brand .logo i:nth-child(3){height:9px;  animation-delay:.3s}
.brand .logo i:nth-child(4){height:13px; animation-delay:.45s}
@keyframes bars { 0%,100%{transform:scaleY(.5)} 50%{transform:scaleY(1)} }

.nav-links { display: flex; align-items: center; gap: 6px; list-style: none; flex-wrap: nowrap; }
.nav-links a {
  color: var(--text-soft); font-size: 0.94rem; font-weight: 500;
  padding: 8px 14px; border-radius: 10px; transition: color .2s, background .2s;
  white-space: nowrap;
}
.nav-links a:hover { color: var(--text); background: var(--surface); }
.nav-links a.active { color: var(--text); }
.nav-links a.active::after {
  content: ""; display: block; height: 2px; margin-top: 4px; border-radius: 2px;
  background: var(--grad-primary);
}
.nav-cta { display: flex; align-items: center; gap: 12px; }

.nav-toggle {
  display: none; width: 42px; height: 42px; border-radius: 11px;
  background: var(--surface-2); border: 1px solid var(--border);
  cursor: pointer; position: relative;
}
.nav-toggle span {
  position: absolute; left: 11px; right: 11px; height: 2px; border-radius: 2px;
  background: var(--text); transition: transform .3s var(--ease), opacity .2s;
}
.nav-toggle span:nth-child(1){ top: 15px; }
.nav-toggle span:nth-child(2){ top: 21px; }
.nav-toggle span:nth-child(3){ top: 27px; }
.nav-toggle.open span:nth-child(1){ transform: translateY(6px) rotate(45deg); }
.nav-toggle.open span:nth-child(2){ opacity: 0; }
.nav-toggle.open span:nth-child(3){ transform: translateY(-6px) rotate(-45deg); }

/* ---------- cards / grids ---------- */
.grid { display: grid; gap: 22px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  position: relative;
  overflow: hidden;
  transition: transform .35s var(--ease), border-color .35s, background .35s;
}
.card::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(420px circle at var(--mx,50%) var(--my,0%), rgba(139,92,246,0.14), transparent 45%);
  opacity: 0; transition: opacity .35s;
}
.card:hover { transform: translateY(-5px); border-color: rgba(255,255,255,0.18); background: var(--surface-2); }
.card:hover::before { opacity: 1; }
.card .ico {
  width: 50px; height: 50px; border-radius: 13px; margin-bottom: 18px;
  display: grid; place-items: center; font-size: 1.4rem;
  background: linear-gradient(135deg, rgba(139,92,246,0.22), rgba(34,211,238,0.18));
  border: 1px solid var(--border);
}
.card h3 { margin-bottom: 9px; }
.card p { font-size: 0.96rem; }

/* reveal on scroll */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

/* ---------- footer ---------- */
.footer {
  border-top: 1px solid var(--border-soft);
  padding: 60px 0 36px;
  margin-top: 40px;
  background: linear-gradient(180deg, transparent, rgba(139,92,246,0.04));
}
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 32px; margin-bottom: 44px; }
.footer h4 { font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.12em; color: var(--text-dim); margin-bottom: 16px; }
.footer ul { list-style: none; display: grid; gap: 10px; }
.footer a { color: var(--text-soft); font-size: 0.93rem; transition: color .2s; }
.footer a:hover { color: var(--cyan); }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding-top: 26px; border-top: 1px solid var(--border-soft);
  color: var(--text-dim); font-size: 0.88rem; flex-wrap: wrap;
}
.footer .brand { margin-bottom: 14px; }
.footer .muted { max-width: 320px; font-size: 0.93rem; }

/* ---------- misc ---------- */
.pill-row { display: flex; flex-wrap: wrap; gap: 10px; }
.pill {
  font-size: 0.85rem; color: var(--text-soft);
  padding: 7px 15px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--border);
}
.divider { height: 1px; background: var(--border-soft); margin: 0; border: 0; }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  /* Below this, even the tightened desktop nav spacing (see the 901-1320px
     tier below) can't fit 9 links + the CTA on one row without wrapping or
     overflowing — switch to the hamburger menu instead. */
  .nav-inner { width: 90%; }
  .nav-links, .nav-cta .btn { display: none; }
  .nav-toggle { display: block; }
  .nav-links.open {
    display: flex; flex-direction: column; align-items: stretch; gap: 4px;
    position: absolute; top: 72px; left: 16px; right: 16px;
    background: rgba(12, 12, 22, 0.96); backdrop-filter: blur(18px);
    border: 1px solid var(--border); border-radius: 16px;
    padding: 14px; box-shadow: var(--shadow);
  }
  .nav-links.open a { padding: 13px 16px; font-size: 1rem; }
  .nav-links.open a.active::after { display: none; }
}
/* Between the hamburger breakpoint and a roomy desktop width, the full-width
   nav-links + CTA no longer fit at their default spacing — since they no
   longer wrap (see .nav-links a above), they'd overflow instead. Reclaim
   space here instead of letting that happen. */
@media (max-width: 1320px) and (min-width: 901px) {
  .nav-inner { width: 94%; gap: 10px; }
  .nav-links { gap: 0; }
  .nav-links a { padding: 8px 9px; font-size: 0.88rem; }
  .nav-cta .btn { padding: 10px 18px; font-size: 0.92rem; }
}
@media (max-width: 760px) {
  section { padding: 72px 0; }
  .container { width: 90%; }
}
@media (max-width: 560px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .container { padding-inline: 18px; }
}

/* ---------- reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}
