/* Echoly marketing site — "reading lamp at night" theme.
   Literata (reading-optimized serif) + Be Vietnam Pro (full Vietnamese coverage). */

:root {
  --bg: #14121f;
  --bg-alt: #1b1830;
  --panel: #201d34;
  --paper: #f4ecdd;
  --ink: #ede6d8;
  --ink-dim: #b3a9c4;
  --ink-faint: #8a80a0;
  --amber: #e8a855;
  --amber-soft: #f0c179;
  --amber-dim: rgba(232, 168, 85, 0.16);
  --blue: #a9d9f2;
  --blue-dim: rgba(169, 217, 242, 0.14);
  --line: rgba(244, 236, 221, 0.1);
  --line-strong: rgba(244, 236, 221, 0.2);
  --shadow: rgba(6, 5, 12, 0.55);
  --radius: 18px;
  --radius-sm: 12px;
  --maxw: 1120px;
  --serif: "Literata", "Noto Serif", Georgia, serif;
  --sans: "Be Vietnam Pro", "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='matrix' values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.05 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: 0.5;
  mix-blend-mode: overlay;
}

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

a {
  color: inherit;
}

h1,
h2,
h3,
h4 {
  font-family: var(--serif);
  font-weight: 560;
  color: var(--paper);
  margin: 0 0 0.4em;
  letter-spacing: -0.01em;
}

p {
  margin: 0 0 1em;
  color: var(--ink-dim);
}

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 28px;
  position: relative;
  z-index: 1;
}

/* ---------- header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(14px) saturate(140%);
  background: linear-gradient(to bottom, rgba(20, 18, 31, 0.92), rgba(20, 18, 31, 0.72));
  border-bottom: 1px solid var(--line);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
}

.logo {
  display: flex;
  align-items: baseline;
  gap: 8px;
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 600;
  color: var(--paper);
  text-decoration: none;
}

.logo .dot {
  color: var(--amber);
}

nav.primary-nav {
  display: flex;
  align-items: center;
  gap: 30px;
}

nav.primary-nav a {
  text-decoration: none;
  color: var(--ink-dim);
  font-size: 14.5px;
  font-weight: 500;
  letter-spacing: 0.01em;
  padding: 6px 2px;
  position: relative;
  transition: color 0.2s ease;
}

nav.primary-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 100%;
  bottom: -2px;
  height: 1px;
  background: var(--amber);
  transition: right 0.25s ease;
}

nav.primary-nav a:hover {
  color: var(--paper);
}

nav.primary-nav a:hover::after {
  right: 0;
}

nav.primary-nav a[aria-current="page"] {
  color: var(--amber-soft);
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  padding: 8px 16px;
  font-size: 13px;
  color: var(--ink-dim);
  background: var(--bg-alt);
  white-space: nowrap;
}

.pill .pulse {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--amber);
  box-shadow: 0 0 0 0 rgba(232, 168, 85, 0.6);
  animation: pulse 2.4s infinite;
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(232, 168, 85, 0.55);
  }
  70% {
    box-shadow: 0 0 0 7px rgba(232, 168, 85, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(232, 168, 85, 0);
  }
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  width: 40px;
  height: 40px;
  color: var(--paper);
  cursor: pointer;
}

/* ---------- buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 13px 26px;
  border-radius: 999px;
  font-family: var(--sans);
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn-primary {
  background: linear-gradient(180deg, var(--amber-soft), var(--amber));
  color: #241705;
  box-shadow: 0 10px 30px -8px rgba(232, 168, 85, 0.55);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 36px -6px rgba(232, 168, 85, 0.65);
}

.btn-ghost {
  background: transparent;
  border-color: var(--line-strong);
  color: var(--ink);
}

.btn-ghost:hover {
  border-color: var(--amber-soft);
  color: var(--amber-soft);
}

/* ---------- hero ---------- */

.hero {
  padding: 96px 0 70px;
  position: relative;
}

.hero-glow {
  position: absolute;
  top: -160px;
  right: -120px;
  width: 640px;
  height: 640px;
  background: radial-gradient(circle, var(--amber-dim), transparent 65%);
  filter: blur(10px);
  z-index: 0;
  animation: breathe 8s ease-in-out infinite;
}

@keyframes breathe {
  0%, 100% { opacity: 0.7; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.06); }
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 60px;
  align-items: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 12.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 22px;
  font-weight: 600;
}

.eyebrow::before {
  content: "";
  width: 22px;
  height: 1px;
  background: var(--blue);
}

.hero h1 {
  font-size: clamp(38px, 5vw, 60px);
  line-height: 1.08;
  animation: rise 0.8s ease both;
}

.hero .lede {
  font-size: 18px;
  max-width: 46ch;
  color: var(--ink-dim);
  animation: rise 0.8s ease 0.1s both;
}

.hero-actions {
  display: flex;
  gap: 14px;
  margin-top: 32px;
  flex-wrap: wrap;
  animation: rise 0.8s ease 0.2s both;
}

@keyframes rise {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

/* hero visual: stacked "documents" morphing into a waveform */
.hero-visual {
  position: relative;
  height: 380px;
  animation: rise 0.9s ease 0.15s both;
}

.doc-card {
  position: absolute;
  width: 190px;
  height: 250px;
  border-radius: 16px;
  background: var(--panel);
  border: 1px solid var(--line-strong);
  box-shadow: 0 30px 60px -20px var(--shadow);
  padding: 20px;
}

.doc-card .fmt {
  font-family: var(--serif);
  font-size: 13px;
  color: var(--blue);
  letter-spacing: 0.05em;
}

.doc-card .ln {
  height: 7px;
  border-radius: 4px;
  background: var(--line-strong);
  margin-top: 14px;
}

.doc-card .ln:nth-child(3) { width: 92%; }
.doc-card .ln:nth-child(4) { width: 76%; }
.doc-card .ln:nth-child(5) { width: 84%; }
.doc-card .ln:nth-child(6) { width: 60%; }

.doc-1 { top: 10px; left: 10px; transform: rotate(-9deg); z-index: 1; }
.doc-2 { top: 40px; left: 90px; transform: rotate(4deg); z-index: 2; }

.wave-card {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 250px;
  border-radius: 20px;
  background: linear-gradient(165deg, var(--bg-alt), var(--panel));
  border: 1px solid var(--line-strong);
  box-shadow: 0 40px 80px -24px var(--shadow);
  padding: 22px 22px 26px;
  z-index: 3;
}

.wave-card .fmt {
  font-family: var(--serif);
  font-size: 13px;
  color: var(--amber-soft);
  letter-spacing: 0.05em;
  margin-bottom: 16px;
}

.wave-bars {
  display: flex;
  align-items: flex-end;
  gap: 4px;
  height: 56px;
}

.wave-bars span {
  flex: 1;
  background: linear-gradient(180deg, var(--amber-soft), var(--amber));
  border-radius: 3px;
  animation: bar 1.6s ease-in-out infinite;
}

@keyframes bar {
  0%, 100% { transform: scaleY(0.3); }
  50% { transform: scaleY(1); }
}

.wave-bars span:nth-child(1) { animation-delay: 0s; }
.wave-bars span:nth-child(2) { animation-delay: 0.12s; }
.wave-bars span:nth-child(3) { animation-delay: 0.24s; }
.wave-bars span:nth-child(4) { animation-delay: 0.36s; }
.wave-bars span:nth-child(5) { animation-delay: 0.48s; }
.wave-bars span:nth-child(6) { animation-delay: 0.6s; }
.wave-bars span:nth-child(7) { animation-delay: 0.72s; }
.wave-bars span:nth-child(8) { animation-delay: 0.84s; }
.wave-bars span:nth-child(9) { animation-delay: 0.96s; }
.wave-bars span:nth-child(10) { animation-delay: 1.08s; }

.wave-card .cap {
  margin-top: 14px;
  font-size: 12.5px;
  color: var(--ink-faint);
}

/* ---------- sections ---------- */

section {
  padding: 88px 0;
  position: relative;
}

.section-head {
  max-width: 640px;
  margin-bottom: 48px;
}

.section-head .eyebrow {
  color: var(--amber-soft);
}

.section-head .eyebrow::before {
  background: var(--amber-soft);
}

.divider {
  height: 1px;
  background: var(--line);
  border: none;
  margin: 0;
}

/* feature grid */

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

.feature {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px 26px;
  transition: transform 0.25s ease, border-color 0.25s ease;
}

.feature:hover {
  transform: translateY(-4px);
  border-color: var(--line-strong);
}

.feature .icon {
  width: 40px;
  height: 40px;
  border-radius: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  background: var(--amber-dim);
  color: var(--amber-soft);
}

.feature:nth-child(3n+2) .icon { background: var(--blue-dim); color: var(--blue); }

.feature h3 {
  font-size: 18px;
  margin-bottom: 8px;
}

.feature p {
  font-size: 14.5px;
  margin: 0;
}

/* how it works */

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  position: relative;
}

.step {
  padding: 0 26px;
  position: relative;
}

.step:not(:first-child) {
  border-left: 1px dashed var(--line-strong);
}

.step .num {
  font-family: var(--serif);
  font-size: 15px;
  color: var(--amber-soft);
  border: 1px solid var(--line-strong);
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
}

.step h3 {
  font-size: 18px;
}

.step p {
  font-size: 14.5px;
}

/* plans */

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 22px;
}

.plan {
  border-radius: var(--radius);
  padding: 34px 30px;
  border: 1px solid var(--line);
  background: var(--panel);
}

.plan.premium {
  border-color: rgba(232, 168, 85, 0.4);
  background: linear-gradient(165deg, var(--bg-alt), var(--panel));
  position: relative;
}

.plan.premium::before {
  content: "PREMIUM";
  position: absolute;
  top: 24px;
  right: 24px;
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--amber-soft);
  border: 1px solid rgba(232, 168, 85, 0.4);
  border-radius: 999px;
  padding: 4px 10px;
}

.plan h3 {
  font-size: 22px;
}

.plan .price {
  font-family: var(--serif);
  font-size: 15px;
  color: var(--ink-dim);
  margin-bottom: 20px;
}

.plan ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.plan li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 9px 0;
  border-top: 1px solid var(--line);
  font-size: 14.5px;
  color: var(--ink);
}

.plan li:first-child {
  border-top: none;
}

.plan li .tick {
  color: var(--amber-soft);
  flex-shrink: 0;
}

/* final CTA */

.cta-band {
  border-radius: 28px;
  background: radial-gradient(circle at 20% 20%, var(--amber-dim), transparent 55%), var(--bg-alt);
  border: 1px solid var(--line);
  padding: 64px 56px;
  text-align: center;
}

.cta-band h2 {
  font-size: clamp(28px, 4vw, 38px);
  max-width: 20ch;
  margin: 0 auto 14px;
}

.cta-band p {
  max-width: 46ch;
  margin: 0 auto 28px;
}

.cta-actions {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ---------- footer ---------- */

.site-footer {
  border-top: 1px solid var(--line);
  padding: 56px 0 40px;
  margin-top: 40px;
}

.footer-grid {
  display: flex;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;
}

.footer-brand .logo {
  margin-bottom: 10px;
}

.footer-brand p {
  max-width: 32ch;
  font-size: 14px;
}

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

.footer-col h4 {
  font-family: var(--sans);
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: 14px;
}

.footer-col a {
  display: block;
  text-decoration: none;
  color: var(--ink-dim);
  font-size: 14.5px;
  padding: 5px 0;
}

.footer-col a:hover {
  color: var(--amber-soft);
}

.footer-bottom {
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--ink-faint);
}

/* ---------- inner pages (support / privacy / contact) ---------- */

.page-hero {
  padding: 72px 0 40px;
}

.page-hero .eyebrow { color: var(--blue); }
.page-hero .eyebrow::before { background: var(--blue); }

.page-hero h1 {
  font-size: clamp(32px, 4.5vw, 46px);
}

.content-block {
  max-width: 760px;
}

.content-block h2 {
  font-size: 24px;
  margin-top: 44px;
}

.content-block h2:first-of-type {
  margin-top: 0;
}

.content-block p,
.content-block li {
  color: var(--ink-dim);
  font-size: 15.5px;
}

.content-block ul {
  padding-left: 22px;
}

.content-block li {
  margin-bottom: 8px;
}

.meta-line {
  font-size: 13.5px;
  color: var(--ink-faint);
  margin-bottom: 40px;
}

/* faq */

.faq {
  max-width: 760px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.faq details {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 4px 22px;
}

.faq summary {
  cursor: pointer;
  list-style: none;
  padding: 18px 0;
  font-family: var(--serif);
  font-size: 17px;
  color: var(--paper);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary .chev {
  flex-shrink: 0;
  color: var(--amber-soft);
  transition: transform 0.2s ease;
}

.faq details[open] summary .chev {
  transform: rotate(45deg);
}

.faq .a {
  padding: 0 0 20px;
  color: var(--ink-dim);
  font-size: 14.5px;
}

.faq .a p:last-child { margin-bottom: 0; }

/* contact */

.contact-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 40px;
  max-width: 560px;
  text-align: center;
}

.contact-card .icon-ring {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--amber-dim);
  color: var(--amber-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
}

.contact-card .email {
  font-family: var(--serif);
  font-size: 22px;
  color: var(--paper);
}

.contact-note {
  max-width: 560px;
  font-size: 13.5px;
  color: var(--ink-faint);
  margin-top: 18px;
}

.contact-grid {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

/* ---------- responsive ---------- */

@media (max-width: 880px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-visual { height: 300px; margin-top: 20px; }
  .grid-3 { grid-template-columns: 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; gap: 32px; }
  .step:not(:first-child) { border-left: none; border-top: 1px dashed var(--line-strong); padding-top: 28px; }
  .footer-grid { flex-direction: column; }
  .footer-links { gap: 32px; }
  .cta-band { padding: 44px 24px; }
}

@media (max-width: 720px) {
  nav.primary-nav { display: none; }
  .nav-toggle { display: flex; align-items: center; justify-content: center; }
  body.nav-open nav.primary-nav {
    display: flex;
    position: absolute;
    top: 76px;
    left: 0;
    right: 0;
    background: var(--bg-alt);
    border-bottom: 1px solid var(--line);
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    padding: 16px 28px 24px;
  }
  body.nav-open nav.primary-nav a { padding: 10px 0; }
  .site-header .pill { display: none; }
}
