:root {
  --bg: #0a0a0d;
  --bg-alt: #101116;
  --surface: #17181f;
  --surface-2: #1e2029;
  --border: #2a2c36;
  --text: #f4f5f7;
  --text-dim: #b3b7c4;
  --text-dimmer: #878b99;
  --green: #34d058;
  --green-dim: #22a344;
  --red: #ff453a;
  --yellow: #ffd60a;
  --max-width: 1120px;
  --radius: 16px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

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

img { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; }

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

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 10, 13, 0.75);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: -0.01em;
}

.brand-icon {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  flex-shrink: 0;
  transition: transform 0.4s ease;
}

.brand:hover .brand-icon {
  transform: rotate(180deg);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 24px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 1rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, opacity 0.15s ease, background 0.15s ease, box-shadow 0.2s ease;
  white-space: nowrap;
}

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

.btn-primary {
  background: var(--green);
  color: #06130a;
  box-shadow: 0 0 0 rgba(52, 208, 88, 0);
}
.btn-primary:hover {
  background: #40dc64;
  box-shadow: 0 4px 24px -4px rgba(52, 208, 88, 0.45);
}

.btn-secondary {
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}
.btn-secondary:hover { background: var(--surface); }

.btn-small {
  padding: 9px 18px;
  font-size: 0.92rem;
}

.btn-store-disabled {
  background: var(--surface);
  color: var(--text-dimmer);
  border-color: var(--border);
  cursor: not-allowed;
  gap: 12px;
}
.btn-store-disabled:hover { transform: none; }

.btn-store-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.2;
}

.btn-store-label {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-dim);
}

.btn-store-status {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--text-dimmer);
}

/* Hero */
.hero {
  padding: 80px 0 48px;
  overflow: hidden;
  position: relative;
}

.hero-glow {
  position: absolute;
  width: 520px;
  height: 520px;
  border-radius: 50%;
  filter: blur(110px);
  pointer-events: none;
  opacity: 0.14;
}

.hero-glow--red {
  background: var(--red);
  top: -180px;
  left: -140px;
  animation: drift-a 14s ease-in-out infinite alternate;
}

.hero-glow--green {
  background: var(--green);
  top: -60px;
  right: -160px;
  animation: drift-b 18s ease-in-out infinite alternate;
}

@keyframes drift-a {
  from { transform: translate(0, 0) scale(1); }
  to   { transform: translate(70px, 50px) scale(1.15); }
}

@keyframes drift-b {
  from { transform: translate(0, 0) scale(1.1); }
  to   { transform: translate(-80px, 60px) scale(0.95); }
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 56px;
  align-items: center;
  position: relative;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--green);
  margin: 0 0 14px;
}

.eyebrow-light { color: var(--green); }

.rotator {
  display: inline-block;
  background-image: linear-gradient(92deg, #ffc51a, var(--green));
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.rotator.swap {
  opacity: 0;
  transform: translateY(12px);
}

.hero-copy h1 {
  font-size: clamp(2.6rem, 5.2vw, 3.8rem);
  line-height: 1.06;
  letter-spacing: -0.02em;
  margin: 0 0 20px;
}

.grad {
  background: linear-gradient(92deg, var(--red) 0%, var(--yellow) 48%, var(--green) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.h1-line {
  display: block;
  white-space: nowrap;
}

.grad-the {
  background-image: linear-gradient(92deg, var(--red), #ff8f1f);
}

.hero-sub {
  color: var(--text-dim);
  font-size: 1.16rem;
  max-width: 46ch;
  margin: 0 0 28px;
}

/* Rolling buffer demo */
.buffer-demo {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 340px;
  margin: 0 0 30px;
}

.buffer-track {
  display: block;
  height: 8px;
  border-radius: 999px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  overflow: hidden;
  position: relative;
}

.buffer-fill {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, var(--green-dim) 30%, var(--green));
  transform-origin: left;
  animation: buffer-roll 3.6s cubic-bezier(0.4, 0, 0.4, 1) infinite;
}

@keyframes buffer-roll {
  0%   { transform: translateX(-100%); }
  70%  { transform: translateX(0); }
  85%  { transform: translateX(0); opacity: 1; }
  100% { transform: translateX(0); opacity: 0; }
}

.buffer-label {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: var(--text-dimmer);
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.hero-note {
  margin: 18px 0 0;
  font-size: 0.95rem;
  color: var(--text-dimmer);
}

.hero-art {
  display: flex;
  justify-content: center;
}

/* Phone frame */
.phone-frame {
  width: 100%;
  max-width: 300px;
  border-radius: 40px;
  border: 6px solid #2b2d38;
  background: #000;
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(255,255,255,0.03);
  overflow: hidden;
}

.phone-frame--float {
  animation: phone-float 6s ease-in-out infinite;
}

@keyframes phone-float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-12px); }
}

.phone-frame img {
  width: 100%;
  height: auto;
}

.phone-frame--small {
  max-width: 240px;
  border-radius: 32px;
  border-width: 5px;
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.feature-card:hover .phone-frame--small {
  transform: translateY(-8px);
  box-shadow: 0 40px 70px -24px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(255,255,255,0.05);
}

/* Sections */
.section {
  padding: 88px 0;
}

.section-alt {
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.section-title {
  font-size: clamp(1.8rem, 3.4vw, 2.5rem);
  letter-spacing: -0.02em;
  margin: 0 0 12px;
  text-align: center;
}

.section-sub {
  color: var(--text-dim);
  text-align: center;
  max-width: 52ch;
  margin: 0 auto 64px;
  font-size: 1.12rem;
}

/* Feature grid */
.feature-grid {
  display: flex;
  flex-direction: column;
  gap: 96px;
}

.feature-card--media {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 48px;
  align-items: center;
}

.feature-card--reverse {
  direction: rtl;
}
.feature-card--reverse > * {
  direction: ltr;
}

.feature-media {
  display: flex;
  justify-content: center;
}

.feature-copy h3 {
  font-size: 1.6rem;
  margin: 0 0 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  letter-spacing: -0.01em;
}

.feature-copy p {
  color: var(--text-dim);
  font-size: 1.08rem;
  margin: 0;
  max-width: 48ch;
}

.pro-chip {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #06130a;
  background: var(--green);
  padding: 3px 10px;
  border-radius: 999px;
}

/* Save triggers */
.section--compact {
  padding: 60px 0;
}

.section-sub--tight {
  margin-bottom: 36px;
}

.trigger-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.trigger {
  display: grid;
  grid-template-columns: auto 1fr;
  column-gap: 15px;
  row-gap: 2px;
  align-items: center;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 18px;
  transition: transform 0.3s ease, border-color 0.3s ease;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.trigger:hover {
  transform: translateY(-4px);
  border-color: rgba(52, 208, 88, 0.4);
}

.trigger:active {
  transform: scale(0.98);
}

.trigger-icon {
  grid-row: 1 / 3;
  width: 46px;
  height: 46px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--green);
  background: rgba(52, 208, 88, 0.1);
  border: 1px solid rgba(52, 208, 88, 0.25);
}

.trigger-icon svg {
  width: 23px;
  height: 23px;
}

.trigger h3 {
  margin: 0;
  font-size: 1rem;
  letter-spacing: -0.01em;
  align-self: end;
}

.trigger p {
  margin: 0;
  color: var(--text-dim);
  font-size: 0.88rem;
  line-height: 1.4;
}

/* Trigger icon animations */
.trigger-icon svg * {
  transform-box: fill-box;
  transform-origin: center;
}

.t-rotate .ph {
  animation: phone-turn 8s ease-in-out infinite;
}
@keyframes phone-turn {
  0%, 40%, 100% { transform: rotate(0deg); }
  6%, 11%       { transform: rotate(-90deg); }
  17%           { transform: rotate(0deg); }
  25%, 30%      { transform: rotate(90deg); }
  36%           { transform: rotate(0deg); }
}

.t-bell .bell {
  transform-origin: 50% 12%;
  animation: bell-jingle 7s ease-in-out infinite;
}
.t-bell .slash {
  stroke: var(--red);
  opacity: 0;
  animation: slash-blink 7s ease-in-out infinite;
}
@keyframes bell-jingle {
  0%, 14%, 100% { transform: rotate(0deg); }
  2%  { transform: rotate(16deg); }
  4%  { transform: rotate(-13deg); }
  6%  { transform: rotate(10deg); }
  8%  { transform: rotate(-7deg); }
  10% { transform: rotate(4deg); }
  12% { transform: rotate(-2deg); }
}
@keyframes slash-blink {
  0%, 22%, 52%, 100% { opacity: 0; }
  26%, 48%           { opacity: 1; }
}

.t-island .pill {
  animation: island-pop 6s ease-in-out infinite;
}
@keyframes island-pop {
  0%, 55%, 100% { transform: scale(1); }
  10%, 42%      { transform: scale(1.55, 1.25); }
}

.t-cc .k1 { animation: knob-a 6s ease-in-out infinite; }
.t-cc .k2 { animation: knob-b 6s ease-in-out infinite; }
@keyframes knob-a {
  0%, 60%, 100% { transform: translateX(0); }
  12%, 45%      { transform: translateX(6px); }
}
@keyframes knob-b {
  0%, 60%, 100% { transform: translateX(0); }
  14%, 45%      { transform: translateX(-6px); }
}

.t-voice .w1, .t-voice .w2, .t-voice .w3, .t-voice .w4 {
  animation: voice-wave 5s ease-in-out infinite;
}
.t-voice .w2 { animation-delay: 0.12s; }
.t-voice .w3 { animation-delay: 0.24s; }
.t-voice .w4 { animation-delay: 0.36s; }
@keyframes voice-wave {
  0%, 30%, 100% { transform: scaleY(1); }
  5%  { transform: scaleY(0.45); }
  10% { transform: scaleY(1.25); }
  15% { transform: scaleY(0.55); }
  20% { transform: scaleY(1.15); }
  25% { transform: scaleY(0.8); }
}

.t-widget .wg { animation: wg-pop 6s ease-in-out infinite; }
.t-widget .wg2 { animation-delay: 0.35s; }
.t-widget .wg4 { animation-delay: 0.7s; }
.t-widget .wg3 { animation-delay: 1.05s; }
@keyframes wg-pop {
  0%, 12%, 100% { transform: scale(1); }
  6%            { transform: scale(1.22); }
}

/* How it works */
.steps {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 24px;
}

.step {
  flex: 1;
  max-width: 260px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  text-align: center;
  transition: transform 0.3s ease, border-color 0.3s ease;
}

.step:hover {
  transform: translateY(-6px);
  border-color: rgba(52, 208, 88, 0.4);
}

.step-num {
  width: 38px;
  height: 38px;
  margin: 0 auto 16px;
  border-radius: 50%;
  background: var(--green);
  color: #06130a;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.05rem;
}

.step h3 {
  margin: 0 0 8px;
  font-size: 1.25rem;
}

.step p {
  margin: 0;
  color: var(--text-dim);
  font-size: 1rem;
}

.step-arrow {
  color: var(--text-dimmer);
  font-size: 1.5rem;
  align-self: center;
  padding-top: 40px;
  animation: arrow-nudge 2.2s ease-in-out infinite;
}

@keyframes arrow-nudge {
  0%, 100% { transform: translateX(0); opacity: 0.6; }
  50%      { transform: translateX(6px); opacity: 1; }
}

/* Pro panel */
.pro-panel {
  border-radius: 24px;
  padding: 56px;
  background: linear-gradient(160deg, var(--surface-2), var(--surface) 60%);
  border: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}

.pro-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 85% 15%, rgba(52, 208, 88, 0.18), transparent 55%),
    radial-gradient(circle at 10% 90%, rgba(255, 69, 58, 0.10), transparent 45%);
  pointer-events: none;
  animation: pro-glow 8s ease-in-out infinite alternate;
}

@keyframes pro-glow {
  from { opacity: 0.7; }
  to   { opacity: 1; }
}

.pro-panel-copy {
  position: relative;
  max-width: 60ch;
}

.pro-panel h2 {
  font-size: clamp(1.8rem, 3.2vw, 2.4rem);
  margin: 0 0 14px;
  letter-spacing: -0.02em;
}

.pro-panel-sub {
  color: var(--text-dim);
  font-size: 1.1rem;
  margin: 0 0 28px;
}

.pro-list {
  list-style: none;
  margin: 0 0 36px;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.pro-list li {
  position: relative;
  padding-left: 28px;
  color: var(--text);
  font-size: 1.05rem;
}

.pro-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--green);
  font-weight: 800;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 40px 0;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
}

.footer-links a {
  color: var(--text-dim);
  font-size: 0.95rem;
  transition: color 0.15s ease;
}

.footer-links a:hover {
  color: var(--text);
}

.footer-copy {
  margin: 0;
  color: var(--text-dimmer);
  font-size: 0.9rem;
}

/* Scroll reveal */
@media (prefers-reduced-motion: no-preference) {
  html.js .reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s ease, transform 0.6s ease;
  }
  html.js .reveal.in {
    opacity: 1;
    transform: none;
  }
  html.js .reveal-delay-1.in { transition-delay: 0.12s; }
  html.js .reveal-delay-2.in { transition-delay: 0.24s; }
  html.js .reveal-delay-3.in { transition-delay: 0.36s; }
}

@media (prefers-reduced-motion: reduce) {
  .hero-glow,
  .buffer-fill,
  .phone-frame--float,
  .step-arrow,
  .pro-panel::before,
  .trigger-icon svg,
  .trigger-icon svg * {
    animation: none !important;
  }
  html { scroll-behavior: auto; }
}

/* Responsive */
@media (max-width: 860px) {
  .hero-inner {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .hero-sub { margin-left: auto; margin-right: auto; }
  .buffer-demo { margin-left: auto; margin-right: auto; text-align: center; }
  .cta-row { justify-content: center; }
  .hero-art { margin-top: 16px; }

  .feature-card--media,
  .feature-card--reverse {
    grid-template-columns: 1fr;
    direction: ltr;
    text-align: center;
  }
  .feature-copy p { margin-left: auto; margin-right: auto; }
  .feature-copy h3 { justify-content: center; }

  .trigger-grid { grid-template-columns: repeat(2, 1fr); }

  .steps {
    flex-direction: column;
    align-items: stretch;
  }
  .step { max-width: none; }
  .step-arrow {
    transform: rotate(90deg);
    padding: 0;
    align-self: center;
    animation: none;
  }

  .pro-panel { padding: 36px 24px; }
}

@media (max-width: 520px) {
  .hero { padding: 48px 0 24px; }
  .section { padding: 64px 0; }
  .trigger-grid { grid-template-columns: 1fr; }
  .cta-row { flex-direction: column; align-items: stretch; }
  .btn { padding: 14px 20px; }
}
