/* =================================================================
   Vertex App Studios Inc. — site styles
   ================================================================= */

/* ---- Design tokens ---------------------------------------------- */
:root {
  --bg: #FAF9F6;
  --bg-soft: #F2F0EB;
  --surface: #FFFFFF;
  --ink: #16131F;
  --ink-soft: #3B3650;
  --muted: #6E6880;
  --line: #E7E3DC;
  --accent: #4B3FD8;
  --accent-ink: #3E34C9;
  --teal: #16B5C4;
  --teal-ink: #0E8C99;

  --grad: linear-gradient(120deg, #1E3FE6 0%, #5B3FE0 52%, #8B3FE8 100%);
  --grad-soft: linear-gradient(135deg, rgba(30,63,230,.12), rgba(139,63,232,.12));

  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-display: "Bricolage Grotesque", "Segoe UI", var(--font-body);

  --radius: 18px;
  --radius-lg: 26px;
  --shadow-sm: 0 1px 3px rgba(22,19,31,.06), 0 6px 18px rgba(22,19,31,.05);
  --shadow-md: 0 8px 30px rgba(22,19,31,.10);
  --shadow-lg: 0 24px 60px rgba(60,42,120,.18);

  --container: 1140px;
  --ease: cubic-bezier(.22,.61,.36,1);
}

/* ---- Reset ------------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }
h1, h2, h3, h4, h5 { margin: 0; line-height: 1.15; font-family: var(--font-display); font-weight: 700; letter-spacing: -.02em; }
p { margin: 0; }
ul { margin: 0; }

:focus-visible { outline: 3px solid rgba(122,91,224,.55); outline-offset: 2px; border-radius: 6px; }

/* ---- Layout helpers --------------------------------------------- */
.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: 1.4rem; }
.section-pad { padding-block: clamp(4rem, 8vw, 7rem); }
.section-pad-sm { padding-block: clamp(2.5rem, 5vw, 4.5rem); }
.measure { max-width: 720px; }
.measure.center { margin-inline: auto; text-align: center; }
.center { text-align: center; }

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}
.grid { display: grid; gap: 1.4rem; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

/* ---- Typography ------------------------------------------------- */
.display { font-size: clamp(2.6rem, 6vw, 4.6rem); line-height: 1.04; }
.section-title { font-size: clamp(1.9rem, 3.6vw, 2.9rem); }
.lead { font-size: clamp(1.1rem, 1.6vw, 1.3rem); color: var(--ink-soft); }
.grad-text {
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
}
.eyebrow {
  display: inline-flex; align-items: center; gap: .5rem;
  font-size: .78rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: var(--accent-ink);
}
.eyebrow::before {
  content: ""; width: 22px; height: 2px; border-radius: 2px; background: var(--grad);
}
.eyebrow[style*="center"]::before, .measure.center .eyebrow::before { display: none; }

/* ---- Buttons ---------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  padding: .85rem 1.4rem; border-radius: 999px; border: 1px solid transparent;
  font-weight: 600; font-size: 1rem; line-height: 1; white-space: nowrap;
  transition: transform .18s var(--ease), box-shadow .25s var(--ease), background .2s, color .2s, border-color .2s;
}
.btn svg { width: 18px; height: 18px; }
.btn-sm { padding: .6rem 1.05rem; font-size: .9rem; }
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn-primary { background: var(--grad); color: #fff; box-shadow: 0 8px 22px rgba(108,69,214,.28); }
.btn-primary:hover { box-shadow: 0 12px 30px rgba(108,69,214,.38); }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: #2a2438; }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent-ink); background: #fff; }
.btn-row { display: flex; flex-wrap: wrap; gap: .8rem; }

/* ---- Header / nav ----------------------------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(250,249,246,.78);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 68px; }
.brand { display: inline-flex; align-items: center; gap: .55rem; font-family: var(--font-display); font-weight: 700; font-size: 1.05rem; letter-spacing: -.01em; }
.brand .mark { width: 28px; height: 28px; }
.nav-links { display: flex; align-items: center; gap: 1.6rem; }
.nav-links a { font-size: .95rem; font-weight: 500; color: var(--ink-soft); position: relative; transition: color .2s; }
.nav-links a:hover { color: var(--ink); }
.nav-links a[aria-current="page"] { color: var(--accent-ink); }
.nav-links a[aria-current="page"]::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -8px; height: 2px; border-radius: 2px; background: var(--grad);
}
.nav-right { display: flex; align-items: center; gap: .7rem; }

.nav-toggle {
  display: none; width: 42px; height: 42px; border: 1px solid var(--line); border-radius: 12px;
  background: #fff; position: relative; padding: 0;
}
.nav-toggle span {
  position: absolute; left: 11px; right: 11px; height: 2px; background: var(--ink); border-radius: 2px;
  transition: transform .25s var(--ease), opacity .2s;
}
.nav-toggle span:nth-child(1) { top: 15px; }
.nav-toggle span:nth-child(2) { bottom: 15px; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { transform: translateY(-6px) rotate(-45deg); }

.mobile-nav {
  display: none; flex-direction: column; gap: .25rem;
  padding: .8rem 1.4rem 1.4rem;
  background: rgba(250,249,246,.98);
  border-bottom: 1px solid var(--line);
  position: sticky; top: 68px; z-index: 49;
}
.mobile-nav.open { display: flex; }
.mobile-nav a { padding: .75rem .25rem; font-weight: 500; color: var(--ink-soft); border-bottom: 1px solid var(--line); }
.mobile-nav a:last-of-type { border-bottom: none; }
.mobile-nav a.btn { margin-top: .6rem; color: #fff; border: none; justify-content: center; }
.mobile-nav a.btn-primary { color: #fff; }

/* ---- Decorative blobs ------------------------------------------- */
.hero, .page-hero, .cta-band { position: relative; overflow: hidden; }
.blob {
  position: absolute; border-radius: 50%; filter: blur(70px); opacity: .5; pointer-events: none; z-index: 0;
}
.blob-a { width: 460px; height: 460px; background: radial-gradient(circle, #6E7BF5, transparent 70%); top: -160px; left: -120px; }
.blob-b { width: 420px; height: 420px; background: radial-gradient(circle, #9B6BF0, transparent 70%); bottom: -180px; right: -100px; }
.blob-c { width: 380px; height: 380px; background: radial-gradient(circle, #45C6D6, transparent 70%); top: -120px; right: -80px; }

/* ---- Hero ------------------------------------------------------- */
.hero { padding-block: clamp(3.5rem, 8vw, 6.5rem); }
.hero-inner, .page-hero .container { position: relative; z-index: 1; }
.page-hero { padding-block: clamp(3rem, 6vw, 5rem); }

/* ---- Cards ------------------------------------------------------ */
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: clamp(1.4rem, 2.5vw, 2rem); box-shadow: var(--shadow-sm);
}
.card-hover { transition: transform .25s var(--ease), box-shadow .3s var(--ease), border-color .3s; }
.card-hover:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: #d9d3ea; }
.card h3 { font-size: 1.2rem; margin-bottom: .4rem; }
.card p { color: var(--muted); font-size: .96rem; }

.icon {
  width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center;
  background: var(--grad-soft); color: var(--accent-ink); margin-bottom: 1rem;
}
.icon svg { width: 24px; height: 24px; }

/* ---- Product cards ---------------------------------------------- */
.product-card {
  display: flex; flex-direction: column; gap: 1rem;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: clamp(1.6rem, 3vw, 2.2rem); box-shadow: var(--shadow-sm);
  transition: transform .25s var(--ease), box-shadow .3s var(--ease);
}
.product-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.pc-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.pc-head h3 { font-size: 1.6rem; }
.one-liner { color: var(--ink-soft); font-size: 1.05rem; }
.feat { list-style: none; padding: 0; display: grid; gap: .55rem; }
.feat li { position: relative; padding-left: 1.6rem; color: var(--ink-soft); font-size: .96rem; }
.feat li::before {
  content: ""; position: absolute; left: 0; top: .5em; width: 8px; height: 8px; border-radius: 50%;
  background: var(--grad);
}

/* ---- Badges ----------------------------------------------------- */
.badge {
  display: inline-flex; align-items: center; gap: .45rem;
  padding: .35rem .75rem; border-radius: 999px; font-size: .78rem; font-weight: 700;
  border: 1px solid var(--line); background: #fff;
}
.badge .dot { width: 8px; height: 8px; border-radius: 50%; }
.badge-live { color: #1c7a4d; border-color: rgba(28,122,77,.25); background: rgba(28,122,77,.08); }
.badge-live .dot { background: #1fae6c; box-shadow: 0 0 0 0 rgba(31,174,108,.6); animation: pulse 2s infinite; }
.badge-soon { color: var(--accent-ink); border-color: rgba(122,91,224,.25); background: rgba(122,91,224,.08); }
.badge-soon .dot { background: var(--accent); }
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(31,174,108,.5); }
  70% { box-shadow: 0 0 0 7px rgba(31,174,108,0); }
  100% { box-shadow: 0 0 0 0 rgba(31,174,108,0); }
}

/* ---- Principles ------------------------------------------------- */
.principles {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: clamp(1.6rem, 3vw, 2.2rem); box-shadow: var(--shadow-sm);
}
.principle-list { list-style: none; padding: 0; display: grid; gap: 1.4rem; }
.principle-list li { display: flex; gap: 1rem; align-items: flex-start; }
.principle-list strong { display: block; margin-bottom: .15rem; }
.principle-list span span { color: var(--muted); font-size: .95rem; }
.check {
  flex: none; width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center;
  background: var(--grad); color: #fff;
}
.check svg { width: 16px; height: 16px; }

/* ---- Feature blocks (numbered) ---------------------------------- */
.feature {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.6rem; box-shadow: var(--shadow-sm);
  transition: transform .25s var(--ease), box-shadow .3s var(--ease);
}
.feature:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.feature .num {
  display: inline-block; font-family: var(--font-display); font-weight: 700; font-size: 1.1rem;
  color: var(--accent-ink); margin-bottom: .7rem;
}
.feature h4 { font-size: 1.15rem; margin-bottom: .4rem; }
.feature p { color: var(--muted); font-size: .95rem; }

/* ---- Phone mockups ---------------------------------------------- */
.split-media { display: flex; justify-content: center; }
.mockup {
  position: relative; width: 280px; max-width: 100%; aspect-ratio: 9 / 18.5;
  background: linear-gradient(160deg, #1d1830, #2c2347);
  border-radius: 40px; padding: 14px; box-shadow: var(--shadow-lg);
}
.notch {
  position: absolute; top: 16px; left: 50%; transform: translateX(-50%);
  width: 92px; height: 22px; background: #100c1c; border-radius: 0 0 14px 14px; z-index: 2;
}
.screen {
  height: 100%; border-radius: 28px; background: var(--bg); padding: 1.4rem 1rem 1rem;
  display: flex; flex-direction: column; gap: .8rem; overflow: hidden;
}
.screen .top small { color: var(--accent-ink); font-weight: 700; font-size: .68rem; letter-spacing: .06em; text-transform: uppercase; }
.screen .top h5 { font-size: 1.1rem; margin-top: .15rem; }
.mock-card { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: .9rem; box-shadow: var(--shadow-sm); }
.mock-bar { height: 8px; border-radius: 6px; background: var(--bg-soft); margin-top: 8px; }
.mock-bar.fill { background: var(--grad); }
.mock-ring {
  width: 76px; height: 76px; border-radius: 50%; margin: 0 auto .4rem;
  display: grid; place-items: center;
  background: conic-gradient(#16B5C4 0 84%, var(--bg-soft) 84% 100%);
}
.mock-ring span {
  width: 58px; height: 58px; border-radius: 50%; background: #fff; display: grid; place-items: center;
  font-family: var(--font-display); font-weight: 700; font-size: 1.3rem; color: var(--ink);
}
.mockup-mini { flex-wrap: wrap; }
.mock-pill {
  display: inline-block; padding: .4rem .7rem; border-radius: 999px; font-size: .76rem; font-weight: 600;
  background: var(--grad-soft); color: var(--accent-ink); border: 1px solid rgba(122,91,224,.18);
}

/* ---- CTA band --------------------------------------------------- */
.cta-band {
  text-align: center; color: #fff; border-radius: var(--radius-lg);
  padding: clamp(2.5rem, 5vw, 4rem) clamp(1.4rem, 4vw, 3rem);
  background: linear-gradient(125deg, #1B36D6, #4B3FD4 52%, #8438E4);
  box-shadow: var(--shadow-lg);
}
.cta-band .section-title { color: #fff; }
.cta-band .lead { color: rgba(255,255,255,.9); }
.cta-band .blob { opacity: .35; }
.cta-band > :not(.blob) { position: relative; z-index: 1; }
.cta-band .btn-ghost { border-color: rgba(255,255,255,.5); color: #fff; }
.cta-band .btn-ghost:hover { background: #fff; color: var(--accent-ink); }

/* ---- Forms ------------------------------------------------------ */
.form-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: clamp(1.4rem, 3vw, 2rem); box-shadow: var(--shadow-sm); width: 100%; }
.field { display: flex; flex-direction: column; gap: .4rem; margin-bottom: 1rem; }
.field label { font-size: .85rem; font-weight: 600; color: var(--ink-soft); }
.field input, .field select, .field textarea,
.waitlist-form input {
  width: 100%; padding: .8rem .95rem; border: 1px solid var(--line); border-radius: 12px;
  background: #fff; color: var(--ink); font: inherit; transition: border-color .2s, box-shadow .2s;
}
.field textarea { min-height: 120px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus,
.waitlist-form input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(122,91,224,.15); }
.form-note { margin-top: .8rem; font-size: .85rem; color: var(--muted); text-align: center; }

.waitlist-form { display: flex; gap: .6rem; flex-wrap: wrap; position: relative; }
.waitlist-form input { flex: 1 1 220px; }

.form-success {
  display: none; align-items: center; gap: .6rem; margin-top: 1rem;
  padding: .85rem 1.1rem; border-radius: 12px; font-weight: 600; font-size: .95rem;
  background: rgba(31,174,108,.1); color: #1c7a4d; border: 1px solid rgba(31,174,108,.25);
}
.form-success.show { display: flex; }
.form-success svg { width: 20px; height: 20px; flex: none; }

/* ---- Contact tiles ---------------------------------------------- */
.contact-tile {
  display: flex; align-items: center; gap: 1rem;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1rem 1.2rem; box-shadow: var(--shadow-sm); transition: transform .2s var(--ease), border-color .2s;
}
a.contact-tile:hover { transform: translateY(-2px); border-color: var(--accent); }
.contact-tile .ic { flex: none; width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: var(--grad-soft); color: var(--accent-ink); }
.contact-tile .ic svg { width: 22px; height: 22px; }
.contact-tile small { display: block; color: var(--muted); font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; }
.contact-tile strong { font-size: .98rem; word-break: break-word; }

/* ---- FAQ -------------------------------------------------------- */
.faq-group h3 { font-size: 1.2rem; margin-bottom: 1rem; color: var(--accent-ink); }
.faq { border: 1px solid var(--line); border-radius: 14px; background: var(--surface); margin-bottom: .8rem; overflow: hidden; }
.faq button {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 1rem 1.1rem; background: none; border: none; text-align: left; font-weight: 600; color: var(--ink);
}
.faq .chev { flex: none; width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; background: var(--grad-soft); color: var(--accent-ink); transition: transform .3s var(--ease); }
.faq .chev svg { width: 16px; height: 16px; }
.faq button[aria-expanded="true"] .chev { transform: rotate(45deg); }
.faq .answer { max-height: 0; overflow: hidden; transition: max-height .35s var(--ease); }
.faq .answer p { padding: 0 1.1rem 1.1rem; color: var(--muted); font-size: .95rem; }

/* ---- Legal / prose ---------------------------------------------- */
.legal-meta { color: var(--muted); font-size: .95rem; }
.prose { max-width: 760px; margin-inline: auto; color: var(--ink-soft); }
.prose h2 { font-size: 1.45rem; margin: 2.4rem 0 .8rem; scroll-margin-top: 90px; }
.prose p { margin-bottom: 1rem; }
.prose ul { padding-left: 1.2rem; margin-bottom: 1rem; display: grid; gap: .5rem; }
.prose a { color: var(--accent-ink); text-decoration: underline; text-underline-offset: 2px; }
.toc {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.2rem 1.4rem; margin-bottom: 2rem; box-shadow: var(--shadow-sm);
}
.toc h4 { font-size: .82rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); margin-bottom: .7rem; }
.toc ul { list-style: none; padding: 0; columns: 2; gap: 1.5rem; }
.toc a { color: var(--ink-soft); text-decoration: none; font-size: .92rem; line-height: 2; }
.toc a:hover { color: var(--accent-ink); }
.disclaimer { font-size: .9rem; color: var(--muted); margin-top: 1.4rem; padding-top: 1.2rem; border-top: 1px solid var(--line); }

/* ---- Footer ----------------------------------------------------- */
.site-footer { background: var(--bg-soft); border-top: 1px solid var(--line); padding-block: clamp(2.5rem, 5vw, 4rem) 1.6rem; margin-top: 2rem; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 2rem; }
.footer-grid > div:first-child p { color: var(--muted); font-size: .95rem; margin-top: .9rem; max-width: 320px; }
.footer-grid .brand { margin-bottom: .4rem; }
.footer-col h4 { font-size: .82rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); margin-bottom: .9rem; }
.footer-col a { display: block; color: var(--ink-soft); font-size: .95rem; padding: .25rem 0; transition: color .2s; }
.footer-col a:hover { color: var(--accent-ink); }
.footer-mail { color: var(--accent-ink); }
.footer-mail:hover { text-decoration: underline; }
.footer-bottom {
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .8rem;
  margin-top: 2.5rem; padding-top: 1.4rem; border-top: 1px solid var(--line);
  color: var(--muted); font-size: .88rem;
}
.footer-bottom a:hover { color: var(--accent-ink); }

/* ---- Reveal / load animations ----------------------------------- */
[data-reveal] { opacity: 0; transform: translateY(22px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
[data-reveal].in { opacity: 1; transform: none; }
[data-load] { opacity: 0; transform: translateY(16px); animation: loadIn .7s var(--ease) forwards; }
[data-load="1"] { animation-delay: .05s; }
[data-load="2"] { animation-delay: .15s; }
[data-load="3"] { animation-delay: .25s; }
[data-load="4"] { animation-delay: .35s; }
[data-load="5"] { animation-delay: .45s; }
@keyframes loadIn { to { opacity: 1; transform: none; } }

/* ---- Responsive ------------------------------------------------- */
@media (max-width: 920px) {
  .nav-links { display: none; }
  .nav-toggle { display: block; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
  .split { grid-template-columns: 1fr; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-grid > div:first-child { grid-column: 1 / -1; }
  .toc ul { columns: 1; }
  .nav-right .btn-primary { display: none; }
}
@media (max-width: 480px) {
  .grid-4 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
}

/* ---- Reduced motion --------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; scroll-behavior: auto; }
  [data-reveal], [data-load] { opacity: 1; transform: none; }
}
