:root {
  --bg: #1a1a2e;
  --bg-soft: #22223f;
  --accent: #e94560;
  --accent-soft: rgba(233, 69, 96, 0.15);
  --text: #f2f2f7;
  --text-muted: #b8b8c8;
  --max-width: 1080px;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

img,
svg {
  max-width: 100%;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

/* Language toggling: show/hide based on html[data-lang] */
[data-lang="en"] .sr,
[data-lang="sr"] .en {
  display: none;
}

/* Header */
header.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(26, 26, 46, 0.9);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 14px;
  padding-bottom: 14px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.15rem;
  text-decoration: none;
}

.brand img {
  width: 32px;
  height: 32px;
  border-radius: 8px;
}

.lang-switch {
  display: flex;
  gap: 4px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 999px;
  padding: 4px;
}

.lang-switch button {
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.85rem;
  padding: 6px 12px;
  border-radius: 999px;
  cursor: pointer;
}

.lang-switch button[aria-current="true"] {
  background: var(--accent);
  color: #fff;
}

/* Hero */
.hero {
  position: relative;
  overflow: hidden;
  padding: 72px 0 56px;
  text-align: center;
}

.hero .container {
  position: relative;
  z-index: 1;
}

/* Hero background: equalizer bars pulsing like a heartbeat */
.hero-viz {
  position: absolute;
  inset: 0;
  z-index: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 6px;
  padding-bottom: 12px;
  opacity: 0.32;
  -webkit-mask-image: linear-gradient(to top, black 0%, black 50%, transparent 95%);
  mask-image: linear-gradient(to top, black 0%, black 50%, transparent 95%);
}

.hero-viz .bar {
  --h: 8;
  --hb-delay: 0s;
  --hb-amp: 1;
  --noise-dur: 3s;
  --noise-delay: 0s;
  width: 8px;
  height: calc(var(--h) * 1%);
  border-radius: 4px 4px 0 0;
  background: linear-gradient(to top, var(--accent), var(--accent-soft));
  /* height = quiet, unsynced "noise floor" idle hiss; transform = the sharp heartbeat spike on top of it */
  animation:
    bar-noise var(--noise-dur) ease-in-out infinite,
    heartbeat 4s ease-in-out infinite;
  animation-delay: var(--noise-delay), var(--hb-delay);
  transform-origin: bottom center;
}

/* Idle state: each bar drifts slowly around its own tiny --h baseline, out of
   sync with the others (different --noise-dur/--noise-delay per bar) — reads
   as quiet ambient hiss, never rising far above the noise floor. */
@keyframes bar-noise {
  0%,
  100% {
    height: calc(var(--h) * 1%);
  }
  22% {
    height: calc(var(--h) * 1.6%);
  }
  48% {
    height: calc(var(--h) * 0.6%);
  }
  74% {
    height: calc(var(--h) * 1.3%);
  }
}

/* Pulse rides on --hb-amp (1 at center, tapering toward the edges) so the
   middle bars spike up high on the beat while outer bars lag and barely move. */
@keyframes heartbeat {
  0% {
    transform: scaleY(1);
  }
  8% {
    transform: scaleY(calc(1 + 5 * var(--hb-amp)));
  }
  16% {
    transform: scaleY(1);
  }
  26% {
    transform: scaleY(calc(1 + 3 * var(--hb-amp)));
  }
  36% {
    transform: scaleY(1);
  }
  100% {
    transform: scaleY(1);
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-viz .bar {
    animation: none;
  }
}

.hero h1 {
  font-size: clamp(2rem, 5vw, 3.2rem);
  line-height: 1.15;
  margin: 0 0 20px;
}

.hero .lede {
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  color: var(--text-muted);
  max-width: 640px;
  margin: 0 auto 32px;
}

.btn-primary {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  padding: 14px 32px;
  border-radius: 999px;
  box-shadow: 0 8px 24px var(--accent-soft);
}

.btn-primary:active {
  transform: translateY(1px);
}

/* Sections */
section {
  padding: 56px 0;
}

section h2 {
  font-size: clamp(1.5rem, 3vw, 2.1rem);
  text-align: center;
  margin: 0 0 12px;
}

.section-lede {
  text-align: center;
  color: var(--text-muted);
  max-width: 680px;
  margin: 0 auto 36px;
}

.claim {
  text-align: center;
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--accent);
  margin-top: 28px;
}

/* Language pills */
.lang-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}

.lang-pills span {
  background: var(--bg-soft);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 0.9rem;
}

/* Feature cards (how it works) */
.feature-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

@media (min-width: 768px) {
  .feature-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.feature-card {
  background: var(--bg-soft);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 28px;
}

.feature-card .icon {
  font-size: 1.8rem;
  margin-bottom: 12px;
}

.feature-card h3 {
  margin: 0 0 8px;
  font-size: 1.15rem;
}

.feature-card p {
  margin: 0;
  color: var(--text-muted);
}

/* Audience section */
.audience-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

@media (min-width: 768px) {
  .audience-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.audience-grid > div {
  background: var(--bg-soft);
  border-radius: 16px;
  padding: 24px;
  text-align: center;
}

.audience-grid .icon {
  font-size: 2rem;
  margin-bottom: 8px;
}

.benefits {
  list-style: none;
  margin: 36px auto 0;
  padding: 0;
  max-width: 560px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.benefits li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.benefits li::before {
  content: "\2713";
  color: var(--accent);
  font-weight: 700;
  flex-shrink: 0;
}

/* CTA band */
.cta-band {
  text-align: center;
  background: linear-gradient(135deg, var(--bg-soft), var(--bg));
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.cta-band h2 {
  margin-bottom: 24px;
}

/* Footer */
footer.site-footer {
  padding: 32px 0 48px;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.85rem;
}

footer.site-footer p {
  margin: 4px 0;
}

@media (max-width: 480px) {
  .hero {
    padding: 48px 0 40px;
  }

  .hero-viz {
    gap: 4px;
    opacity: 0.22;
  }

  .hero-viz .bar:nth-child(even) {
    display: none;
  }

  section {
    padding: 40px 0;
  }

  .feature-card,
  .audience-grid > div {
    padding: 20px;
  }
}

/* Legal pages (privacy policy, data deletion) */
.legal {
  padding: 48px 0 64px;
}

.legal .container {
  max-width: 760px;
}

.legal h1 {
  font-size: clamp(1.8rem, 4vw, 2.4rem);
  margin: 0 0 8px;
}

.legal .meta {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin: 0 0 40px;
}

.legal h2 {
  font-size: 1.3rem;
  text-align: left;
  margin: 40px 0 12px;
}

.legal p,
.legal li {
  color: var(--text-muted);
  line-height: 1.7;
}

.legal ul {
  margin: 0 0 16px;
  padding-left: 20px;
}

.legal li {
  margin-bottom: 6px;
}

a.inline-link {
  color: var(--accent);
  text-decoration: underline;
}

.legal .back-link {
  display: inline-block;
  margin-bottom: 32px;
  color: var(--text-muted);
  font-size: 0.9rem;
  text-decoration: none;
}

.legal .back-link:hover {
  color: var(--text);
}
