/* Secure Chat — shared site styles (matches the app + download page). */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

:root {
  --bg: #0E0608;
  --bg2: #1B0F12;
  --green: #1FAE63;
  --green-glow: rgba(31, 174, 99, 0.15);
  --text: #F0EDED;
  --muted: #8A7E80;
  --card: rgba(27, 15, 18, 0.8);
  --border: rgba(255, 255, 255, 0.06);
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* ---- animated background ---- */
.blob {
  position: fixed;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.3;
  pointer-events: none;
  z-index: 0;
}
.blob-1 {
  width: 400px; height: 400px;
  background: var(--green);
  top: -100px; left: -100px;
  animation: float1 12s ease-in-out infinite;
}
.blob-2 {
  width: 350px; height: 350px;
  background: #521121;
  bottom: -80px; right: -80px;
  animation: float2 14s ease-in-out infinite;
}
.blob-3 {
  width: 260px; height: 260px;
  background: #123d26;
  top: 45%; left: 60%;
  opacity: 0.18;
  animation: float3 18s ease-in-out infinite;
}
@keyframes float1 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(60px, 80px) scale(1.08); }
}
@keyframes float2 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-50px, -60px) scale(1.1); }
}
@keyframes float3 {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(-70px, 50px); }
}

.page { position: relative; z-index: 1; max-width: 960px; margin: 0 auto; padding: 0 24px; }

/* ---- nav ---- */
nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 22px 0;
}
.brand {
  display: flex; align-items: center; gap: 10px;
  font-weight: 700; font-size: 18px; color: var(--text); text-decoration: none;
}
.brand img {
  width: 34px; height: 34px; border-radius: 10px;
  box-shadow: 0 4px 18px var(--green-glow), 0 0 0 1px rgba(255,255,255,0.05);
}
nav .links { display: flex; gap: 22px; align-items: center; }
nav .links a { position: relative; color: var(--muted); text-decoration: none; font-size: 14.5px; transition: color .15s; }
nav .links a:not(.btn)::after {
  content: ''; position: absolute; left: 0; bottom: -5px;
  width: 0; height: 2px; border-radius: 2px;
  background: var(--green); transition: width .22s ease;
}
nav .links a:not(.btn):hover { color: var(--text); }
nav .links a:not(.btn):hover::after { width: 100%; }

/* hamburger — mobile only */
.menu-btn {
  display: none;
  width: 42px; height: 42px;
  border: 1px solid var(--border); border-radius: 12px;
  background: var(--card); color: var(--text);
  align-items: center; justify-content: center;
  cursor: pointer;
}
.menu-btn svg { width: 20px; height: 20px; }
.mobile-menu {
  display: none;
  flex-direction: column; gap: 4px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 10px;
  margin-bottom: 18px;
  backdrop-filter: blur(16px);
}
.mobile-menu.open { display: flex; animation: menuIn .22s ease-out; }
.mobile-menu a {
  color: var(--text); text-decoration: none; font-size: 15.5px;
  padding: 12px 14px; border-radius: 10px;
}
.mobile-menu a:active { background: rgba(255,255,255,0.06); }
.mobile-menu a.accent { color: var(--green); font-weight: 700; }
@keyframes menuIn {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: none; }
}

/* ---- buttons ---- */
.btn {
  position: relative; overflow: hidden;
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--green); color: #fff;
  padding: 13px 26px; border-radius: 12px;
  font-weight: 600; font-size: 15.5px; text-decoration: none;
  box-shadow: 0 4px 30px var(--green-glow);
  transition: transform .15s, box-shadow .15s;
}
.btn svg { width: 18px; height: 18px; }
.btn::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(105deg, transparent 40%, rgba(255,255,255,0.3) 50%, transparent 60%);
  transform: translateX(-130%);
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 6px 34px var(--green-glow); }
.btn:hover::after { transition: transform .6s ease; transform: translateX(130%); }
.btn:active { transform: translateY(0); }

/* ---- hero ---- */
.hero { text-align: center; padding: 56px 0 48px; }
.hero .app-icon {
  width: 96px; height: 96px; border-radius: 24px;
  margin: 0 auto 28px; display: block;
  box-shadow: 0 12px 48px var(--green-glow), 0 0 0 1px rgba(255,255,255,0.05);
  animation: heroIn .7s ease-out backwards, iconFloat 5s 1s ease-in-out infinite;
}
.hero h1 {
  font-size: clamp(32px, 6vw, 52px); font-weight: 800; letter-spacing: -0.02em;
  animation: heroIn .7s .1s ease-out backwards;
}
.hero h1 .accent { color: var(--green); }
.hero p {
  color: var(--muted); font-size: 17.5px; line-height: 1.65;
  max-width: 620px; margin: 18px auto 30px;
  animation: heroIn .7s .2s ease-out backwards;
}
.hero .cta-row {
  display: flex; gap: 12px; justify-content: center; flex-wrap: wrap;
  animation: heroIn .7s .3s ease-out backwards;
}
.hero .hint {
  margin-top: 14px; color: var(--muted); font-size: 13px;
  animation: heroIn .7s .4s ease-out backwards;
}
@keyframes heroIn {
  from { opacity: 0; transform: translateY(22px); }
  to { opacity: 1; transform: none; }
}
@keyframes iconFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

/* ---- sections & cards ---- */
section { padding: 40px 0; }
section h2 { font-size: 26px; font-weight: 700; margin-bottom: 22px; }
section h3 { font-size: 17px; font-weight: 700; margin-bottom: 8px; }

.grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 16px;
}
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 22px;
  backdrop-filter: blur(12px);
  transition: transform .2s ease, border-color .2s ease;
}
.card:hover { transform: translateY(-3px); border-color: rgba(31, 174, 99, 0.22); }
.card .icon {
  width: 44px; height: 44px; border-radius: 12px;
  background: var(--green-glow);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 14px;
  transition: transform .2s ease;
}
.card:hover .icon { transform: scale(1.1) rotate(-3deg); }
.card .icon svg { width: 22px; height: 22px; color: var(--green); }
.card p { color: var(--muted); font-size: 14.5px; line-height: 1.6; }

/* ---- scroll reveal ---- */
.reveal {
  opacity: 0; transform: translateY(26px);
  transition: opacity .65s ease, transform .65s cubic-bezier(.16, .84, .44, 1);
}
.reveal.in { opacity: 1; transform: none; }
.grid .reveal:nth-child(2) { transition-delay: .07s; }
.grid .reveal:nth-child(3) { transition-delay: .14s; }
.grid .reveal:nth-child(4) { transition-delay: .21s; }
.grid .reveal:nth-child(5) { transition-delay: .28s; }
.grid .reveal:nth-child(6) { transition-delay: .35s; }

/* ---- prose pages (terms / privacy) ---- */
.prose { max-width: 760px; margin: 0 auto; padding: 30px 0 60px; }
.prose h1 { font-size: clamp(26px, 5vw, 34px); font-weight: 800; margin: 26px 0 6px; }
.prose .updated { color: var(--muted); font-size: 14px; margin-bottom: 34px; }
.prose h2 { font-size: 20px; font-weight: 700; margin: 32px 0 10px; }
.prose p, .prose li { color: #C9C2C4; font-size: 15.5px; line-height: 1.75; }
.prose ul { padding-left: 22px; margin: 10px 0; }
.prose a { color: var(--green); }

/* ---- footer ---- */
footer {
  border-top: 1px solid var(--border);
  margin-top: 40px; padding: 30px 0 40px;
  display: flex; flex-direction: column; gap: 14px;
  align-items: center; text-align: center;
}
footer img { width: 28px; height: 28px; border-radius: 8px; opacity: .9; }
footer .links { display: flex; gap: 22px; flex-wrap: wrap; justify-content: center; }
footer a { color: var(--muted); text-decoration: none; font-size: 14px; }
footer a:hover { color: var(--text); }
footer .fine { color: var(--muted); font-size: 13px; line-height: 1.6; max-width: 520px; }

/* ---- mobile ---- */
@media (max-width: 700px) {
  .page { padding: 0 18px; }
  nav { padding: 16px 0; }
  nav .links { display: none; }
  .menu-btn { display: inline-flex; }
  .hero { padding: 28px 0 36px; }
  .hero .app-icon { width: 78px; height: 78px; border-radius: 20px; margin-bottom: 20px; }
  .hero p { font-size: 16px; }
  .hero .btn { padding: 14px 28px; }
  section { padding: 28px 0; }
  section h2 { font-size: 22px; }
  .grid { grid-template-columns: 1fr; }
  .card { padding: 18px; }
  .prose { padding: 16px 0 48px; }
  .prose p, .prose li { font-size: 15px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .blob, .hero .app-icon { animation: none; }
  .reveal { transition: none; opacity: 1; transform: none; }
  .btn::after { display: none; }
}
