/* ============================================================
   Solvence — shared stylesheet
   Mobile-first. Base styles target phones; min-width queries scale up.
   One radius scale, one spacing scale, restrained use of blue.
   ============================================================ */

:root {
  /* Palette (from brief) */
  --background:   #F7FBFF;
  --surface:      #FFFFFF;
  --surface-soft: #EAF5FF;
  --primary:      #1478D4;
  --primary-dark: #0B5FB3;
  --primary-light:#7EC8FF;
  --text-main:    #142033;
  --text-muted:   #5C6B7A;
  --border:       #D8EAF8;
  --accent:       #2FA7FF;

  /* Spacing scale — 8/16/24/32/48/64/96 */
  --s-1: 0.5rem;
  --s-2: 1rem;
  --s-3: 1.5rem;
  --s-4: 2rem;
  --s-6: 3rem;
  --s-8: 4rem;
  --s-12: 6rem;

  /* One radius language */
  --r-sm: 10px;
  --r-md: 16px;
  --r-lg: 22px;
  --r-pill: 999px;

  /* Soft, diffuse shadows only */
  --shadow-sm: 0 1px 2px rgba(20, 32, 51, .04), 0 4px 14px rgba(20, 120, 212, .05);
  --shadow-md: 0 2px 6px rgba(20, 32, 51, .05), 0 16px 40px rgba(20, 120, 212, .09);
  --shadow-cta: 0 8px 22px rgba(20, 120, 212, .28);

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

/* ---------- Reset / base ---------- */
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--text-main);
  background: var(--background);
  line-height: 1.65;
  font-size: 1.0625rem;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { max-width: 100%; display: block; }
a { color: var(--primary-dark); text-decoration: none; }
h1, h2, h3, h4 { color: var(--text-main); line-height: 1.14; margin: 0 0 var(--s-2); letter-spacing: -0.02em; font-weight: 700; }
p { margin: 0 0 var(--s-2); color: var(--text-muted); }
ul { margin: 0; padding: 0; }

/* ---------- Layout ---------- */
.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 var(--s-3); }
.section { padding: var(--s-8) 0; }
.section-tight { padding: var(--s-6) 0; }
.center { text-align: center; }
.eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--primary-dark);
  background: var(--surface-soft);
  border: 1px solid var(--border);
  padding: 0.35rem 0.8rem;
  border-radius: var(--r-pill);
  margin-bottom: var(--s-2);
}
.lead { font-size: 1.15rem; color: var(--text-muted); max-width: 42ch; }
.center .lead { margin-left: auto; margin-right: auto; }
.section-head { max-width: 46ch; margin: 0 auto var(--s-6); }

/* ---------- Type scale (mobile) ---------- */
h1, .h1 { font-size: 2.15rem; }
h2, .h2 { font-size: 1.7rem; }
h3, .h3 { font-size: 1.2rem; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-weight: 600;
  font-size: 1rem;
  padding: 0.85rem 1.5rem;
  border-radius: var(--r-sm);
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .2s var(--ease), box-shadow .2s var(--ease), background .2s var(--ease), filter .2s var(--ease);
  white-space: nowrap;
}
.btn:active { transform: translateY(0) scale(.985); }
.btn-primary {
  background: linear-gradient(180deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: #fff;
  box-shadow: var(--shadow-cta);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 14px 32px rgba(20,120,212,.38); color:#fff; filter: brightness(1.06); }
.btn-ghost {
  background: var(--surface);
  color: var(--primary-dark);
  border-color: var(--border);
  box-shadow: var(--shadow-sm);
}
.btn-ghost:hover { transform: translateY(-2px); border-color: var(--primary-light); box-shadow: var(--shadow-md); }
.btn-block { width: 100%; }
.btn-lg { padding: 1rem 1.7rem; font-size: 1.05rem; }

/* ---------- Header / nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.82);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 0.6rem; font-weight: 700; font-size: 1.2rem; color: var(--text-main); letter-spacing: -0.02em; }
.brand:hover { color: var(--text-main); }
.brand .glyph { width: 30px; height: 30px; flex: none; }
.nav-links { display: none; }
.nav-cta { display: none; }
.nav-toggle {
  display: inline-flex; flex-direction: column; gap: 5px;
  background: none; border: 0; padding: 10px; cursor: pointer; border-radius: var(--r-sm);
}
.nav-toggle span { width: 22px; height: 2px; background: var(--text-main); border-radius: 2px; transition: transform .2s var(--ease), opacity .2s var(--ease); }
.nav.open .nav-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav.open .nav-toggle span:nth-child(2) { opacity: 0; }
.nav.open .nav-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.mobile-menu {
  display: none;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  padding: var(--s-2) var(--s-3) var(--s-3);
}
.mobile-menu.open { display: block; }
.mobile-menu a { display: block; padding: 0.8rem 0.25rem; color: var(--text-main); font-weight: 500; border-bottom: 1px solid var(--surface-soft); }
.mobile-menu a[aria-current="page"] { color: var(--primary-dark); }
.mobile-menu .btn { margin-top: var(--s-2); }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; padding: var(--s-8) 0 var(--s-6); }
.hero::before { /* light blue gradient wash */
  content: ""; position: absolute; inset: 0; z-index: -2;
  background:
    radial-gradient(120% 90% at 50% -10%, var(--surface-soft) 0%, rgba(234,245,255,0) 60%),
    linear-gradient(180deg, #FFFFFF 0%, var(--background) 100%);
}
.hero-net { /* subtle hex/network layer — HERO ONLY, very low opacity */
  position: absolute; inset: 0; z-index: -1; opacity: .45;
  pointer-events: none;
  mask-image: radial-gradient(80% 70% at 50% 20%, #000 0%, transparent 72%);
  -webkit-mask-image: radial-gradient(80% 70% at 50% 20%, #000 0%, transparent 72%);
  animation: netDrift 26s var(--ease) infinite alternate;
}
@keyframes netDrift { from { transform: translate3d(0,0,0) scale(1); } to { transform: translate3d(-14px,10px,0) scale(1.03); } }

/* Animated light-blue glow — slow drift/breathe behind the hero */
.hero::after {
  content: ""; position: absolute; z-index: -2; pointer-events: none;
  top: -22%; right: -8%; width: 68%; height: 130%;
  background: radial-gradient(closest-side,
    rgba(47,167,255,.22) 0%, rgba(126,200,255,.13) 46%, rgba(126,200,255,0) 74%);
  animation: heroGlow 16s var(--ease) infinite alternate;
}
@keyframes heroGlow {
  from { transform: translate3d(0,0,0) scale(1);      opacity: .7; }
  to   { transform: translate3d(-5%,4%,0) scale(1.14); opacity: 1; }
}

/* Floating hexagon/molecular cluster — right of the hero (from the business card) */
.hero-orbit {
  position: absolute; z-index: -1; top: 50%; right: 1%;
  width: min(46vw, 540px); aspect-ratio: 1; transform: translateY(-50%);
  pointer-events: none; opacity: 1;
  -webkit-mask-image: radial-gradient(72% 72% at 62% 46%, #000 52%, transparent 100%);
  mask-image: radial-gradient(72% 72% at 62% 46%, #000 52%, transparent 100%);
}
.hero-inner { max-width: 44ch; }
.center .hero-inner, .hero-inner.center { margin: 0 auto; }
.hero h1 { margin-bottom: var(--s-2); }
.hero .grad { background: linear-gradient(90deg, var(--primary) 0%, var(--accent) 100%); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-cta { display: flex; flex-direction: column; gap: var(--s-1); margin-top: var(--s-3); }
.hero-cta .btn { width: 100%; }
.trust-row { display: flex; flex-wrap: wrap; gap: 0.5rem 1.1rem; margin-top: var(--s-3); font-size: 0.9rem; color: var(--text-muted); }
.trust-row span { display: inline-flex; align-items: center; gap: 0.4rem; }
.trust-row svg { width: 16px; height: 16px; color: var(--primary); }

/* ---------- Cards ---------- */
.grid { display: grid; gap: var(--s-3); }
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: var(--s-3);
  box-shadow: var(--shadow-sm);
  transition: transform .2s var(--ease), box-shadow .2s var(--ease), border-color .2s var(--ease);
}
.card-hover { will-change: transform; }
.card-hover:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); border-color: var(--primary-light); }
.card-hover:hover .ico { transform: translateY(-2px) scale(1.06); background: #E3F1FF; color: var(--primary); border-color: var(--primary-light); }
.card .ico {
  width: 44px; height: 44px; border-radius: var(--r-sm);
  display: grid; place-items: center; margin-bottom: var(--s-2);
  background: var(--surface-soft); border: 1px solid var(--border); color: var(--primary-dark);
  transition: transform .22s var(--ease), background .22s var(--ease), color .22s var(--ease), border-color .22s var(--ease);
}
.card .ico svg { width: 22px; height: 22px; }
.card h3 { margin-bottom: 0.35rem; }
.card p { margin-bottom: 0; font-size: 0.98rem; }

/* ---------- Steps ---------- */
.steps { counter-reset: step; }
.step { position: relative; padding-left: 3.4rem; }
.step::before {
  counter-increment: step; content: counter(step);
  position: absolute; left: 0; top: 0;
  width: 2.4rem; height: 2.4rem; border-radius: var(--r-pill);
  display: grid; place-items: center; font-weight: 700;
  color: #fff; background: linear-gradient(180deg, var(--primary), var(--primary-dark));
  box-shadow: var(--shadow-cta);
}

/* ---------- Pricing ---------- */
.price-card { display: flex; flex-direction: column; will-change: transform; }
.price-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); border-color: var(--primary-light); }
.price-card.featured { border-color: var(--primary); box-shadow: var(--shadow-md); position: relative; }
.price-card.featured:hover { transform: translateY(-9px) scale(1.012); box-shadow: 0 26px 60px rgba(20,120,212,.20); border-color: var(--primary); }
.price-tag { display: inline-block; font-size: 0.75rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color:#fff; background: var(--primary); padding: .3rem .7rem; border-radius: var(--r-pill); position: absolute; top: -.85rem; left: 50%; transform: translateX(-50%); }
.price { display: flex; align-items: baseline; gap: .3rem; margin: var(--s-1) 0 var(--s-2); }
.price .amt { font-size: 2.3rem; font-weight: 700; color: var(--text-main); letter-spacing: -.03em; }
.price .per { color: var(--text-muted); font-size: .95rem; }
.feature-list { margin: var(--s-2) 0 var(--s-3); }
.feature-list li { display: flex; gap: .6rem; align-items: flex-start; padding: .4rem 0; font-size: .97rem; color: var(--text-main); }
.feature-list li::before { content: ""; flex: none; margin-top: .28rem; width: 18px; height: 18px; border-radius: var(--r-pill); background: var(--surface-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%230B5FB3' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E") center/12px no-repeat; border: 1px solid var(--border); }
.price-card .btn { margin-top: auto; }
.pay-note { font-size: .82rem; color: var(--text-muted); text-align: center; margin-top: .7rem; }

/* ---------- CTA band ---------- */
.cta-band {
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
  border-radius: var(--r-lg);
  padding: var(--s-6) var(--s-3);
  text-align: center;
  color: #fff;
  overflow: hidden;
  position: relative;
}
.cta-band h2, .cta-band p { color: #fff; }
.cta-band p { opacity: .9; max-width: 46ch; margin-left: auto; margin-right: auto; }
.cta-band .btn-primary { background: #fff; color: var(--primary-dark); box-shadow: 0 8px 22px rgba(0,0,0,.18); }
.cta-band .btn-primary:hover { color: var(--primary-dark); background:#fff; }

/* ---------- Forms ---------- */
.form-card { max-width: 560px; margin: 0 auto; }
.field { margin-bottom: var(--s-2); }
.field label { display: block; font-weight: 600; font-size: .92rem; margin-bottom: .4rem; color: var(--text-main); }
.field input, .field textarea, .field select {
  width: 100%; font: inherit; color: var(--text-main);
  padding: .8rem .9rem; border: 1px solid var(--border); border-radius: var(--r-sm);
  background: var(--surface); transition: border-color .15s var(--ease), box-shadow .15s var(--ease);
}
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(47,167,255,.18);
}
.field textarea { min-height: 130px; resize: vertical; }

/* ---------- Contact split ---------- */
.contact-meta li { display: flex; gap: .7rem; align-items: flex-start; padding: .55rem 0; color: var(--text-main); font-size: .98rem; }
.contact-meta .ico { width: 38px; height: 38px; flex: none; border-radius: var(--r-sm); display: grid; place-items: center; background: var(--surface-soft); border: 1px solid var(--border); color: var(--primary-dark); }
.contact-meta .ico svg { width: 18px; height: 18px; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--border); background: var(--surface); margin-top: var(--s-8); }
.footer-grid { display: grid; gap: var(--s-4); padding: var(--s-6) 0; }
.footer-brand p { font-size: .95rem; max-width: 32ch; }
.footer-col h4 { font-size: .82rem; text-transform: uppercase; letter-spacing: .08em; color: var(--text-muted); margin-bottom: var(--s-1); }
.footer-col a { display: block; padding: .3rem 0; color: var(--text-main); font-size: .95rem; }
.footer-col a:hover { color: var(--primary-dark); }
.footer-bottom { border-top: 1px solid var(--border); padding: var(--s-3) 0; display: flex; flex-direction: column; gap: .6rem; font-size: .87rem; color: var(--text-muted); }

/* ---------- Misc ---------- */
.tag-list { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: var(--s-2); }
.tag { font-size: .85rem; color: var(--primary-dark); background: var(--surface-soft); border: 1px solid var(--border); padding: .35rem .75rem; border-radius: var(--r-pill); }
.divider { height: 1px; background: var(--border); border: 0; margin: var(--s-6) 0; }
.muted { color: var(--text-muted); }
.stack-2 > * + * { margin-top: var(--s-2); }

/* ============================================================
   Breakpoints — scale up from mobile
   ============================================================ */
@media (min-width: 640px) {
  .hero-cta { flex-direction: row; }
  .hero-cta .btn { width: auto; }
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 900px) {
  h1, .h1 { font-size: 3.2rem; }
  h2, .h2 { font-size: 2.2rem; }
  h3, .h3 { font-size: 1.25rem; }
  .hero { padding: var(--s-12) 0 var(--s-8); }
  .hero-inner { max-width: 34ch; }
  .lead { font-size: 1.2rem; }

  .nav-toggle { display: none; }
  .nav-links { display: flex; align-items: center; gap: var(--s-3); }
  .nav-links a { color: var(--text-muted); font-weight: 500; font-size: .98rem; transition: color .15s var(--ease); }
  .nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--text-main); }
  .nav-cta { display: inline-flex; }

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

  .split { display: grid; grid-template-columns: 1.05fr .95fr; gap: var(--s-8); align-items: center; }
  .contact-split { display: grid; grid-template-columns: .8fr 1.2fr; gap: var(--s-6); align-items: start; }
  .footer-grid { grid-template-columns: 1.6fr 1fr 1fr 1fr; }
  .footer-bottom { flex-direction: row; justify-content: space-between; align-items: center; }
  .cta-band { padding: var(--s-8); }
}

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

/* ============================================================
   Motion — scroll reveal + wave separators
   Progressive enhancement: reveal offsets only apply when JS is on
   (html.js), so no-JS users always see content.
   ============================================================ */
.js .reveal { opacity: 0; transform: translateY(22px); transition: opacity .7s var(--ease), transform .7s var(--ease); will-change: opacity, transform; }
.js .reveal.is-visible { opacity: 1; transform: none; }

/* Soft flowing wave line between sections (echoes the business card) */
.wave-sep {
  height: 74px; border: 0; margin: 0; overflow: hidden; pointer-events: none;
  background-repeat: repeat-x, repeat-x;
  background-position: 0 bottom, 0 bottom;
  background-size: 1200px 100%, 900px 100%;
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='1200' height='74' viewBox='0 0 1200 74' preserveAspectRatio='none'%3E%3Cpath fill='%237EC8FF' fill-opacity='0.30' d='M0 40 C100 12 200 12 300 40 C400 68 500 68 600 40 C700 12 800 12 900 40 C1000 68 1100 68 1200 40 L1200 74 L0 74 Z'/%3E%3C/svg%3E"),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='900' height='74' viewBox='0 0 900 74' preserveAspectRatio='none'%3E%3Cpath fill='%23BFE0FF' fill-opacity='0.35' d='M0 46 C75 22 150 22 225 46 C300 70 375 70 450 46 C525 22 600 22 675 46 C750 70 825 70 900 46 L900 74 L0 74 Z'/%3E%3C/svg%3E");
  animation: wavePan 24s linear infinite;
}
@keyframes wavePan { to { background-position: 1200px bottom, -900px bottom; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .js .reveal { opacity: 1 !important; transform: none !important; }
}

/* Calm the ambient motion on small screens (keep it from feeling busy) */
@media (max-width: 899px) {
  .hero-orbit { display: none; }
  .hero::after { animation: none; opacity: .6; }
  .hero-net { animation: none; }
  .wave-sep { height: 56px; animation-duration: 36s; }
}
