/* =====================================================================
   Spryly — shared styles (v6)
   Type: Archivo (expanded, heavy) for display, Figtree for text.
   Color: each card type owns a color, and sections take it over.
     contact = green · story = blue · event = indigo · data = violet
     connections = orange · brand blue for everything else
   ===================================================================== */

:root {
  --cloud:   #f5f7fb;
  --white:   #ffffff;
  --ink:     #0a1630;
  --ink-2:   #33405a;
  --ink-3:   #66728a;
  --line:    rgba(10, 22, 48, .10);
  --line-2:  rgba(10, 22, 48, .18);

  --brand:   #1d5fa6;   /* Spryly blue, a richer cut of the logo color */
  --logo:    #336699;
  --lemon:   #ffd84d;

  /* Card-type colors: bright for chips, deep for full-bleed fields */
  --contact: #16b26b;  --contact-deep: #0c6b44;
  --story:   #2f7fd8;  --story-deep:   #134a86;
  --event:   #5b5bf6;  --event-deep:   #2f2fb8;
  --data:    #9a5cff;  --data-deep:    #5a24c2;
  --connect: #ff6a3d;  --connect-deep: #b83a14;

  /* Legacy aliases used by generated pages */
  --t-contact: var(--contact); --t-event: var(--event); --t-story: var(--story);
  --t-video: var(--connect);   --t-data: var(--data);   --t-copy: var(--lemon);
  --paper: var(--cloud); --card: var(--white); --rule: var(--line); --rule-2: var(--line-2);
  --ink-soft: var(--ink-2); --ink-mute: var(--ink-3); --spryly: var(--brand); --spryly-2: var(--brand);
  --on-dark: #eef3fb; --on-dark-mute: #a9b6cc;

  --f-display: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --f-body: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  --f-mono: ui-monospace, "SF Mono", Menlo, monospace;

  --wrap: 1240px;
  --gutter: clamp(16px, 4vw, 48px);
  --r-sm: 12px; --r: 20px; --r-lg: 32px;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --spring: cubic-bezier(.34, 1.45, .64, 1);
  --shadow: 0 1px 2px rgba(10,22,48,.06), 0 8px 24px -8px rgba(10,22,48,.14);
  --shadow-xl: 0 40px 80px -30px rgba(10,22,48,.45), 0 12px 28px -12px rgba(10,22,48,.25);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 84px; }
body {
  margin: 0; background: var(--cloud); color: var(--ink);
  font: 400 18px/1.6 var(--f-body);
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  overflow-x: clip;
}
img, svg, video { display: block; max-width: 100%; }
a { color: inherit; }
p { margin: 0 0 1em; }
h1, h2, h3, h4 { margin: 0; font-family: var(--f-display); font-weight: 800; line-height: 1; letter-spacing: -.02em; font-stretch: 112%; }
::selection { background: var(--lemon); color: var(--ink); }
:focus-visible { outline: 3px solid var(--lemon); outline-offset: 3px; border-radius: 6px; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--ink); color: #fff; padding: 10px 14px; border-radius: 8px; text-decoration: none; }
.skip:focus { top: 12px; }

/* ---------- Type ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font: 700 13px/1 var(--f-body); letter-spacing: .14em; text-transform: uppercase;
  color: var(--dot, var(--brand));
}
.eyebrow::before { content: ""; width: 18px; height: 3px; border-radius: 2px; background: currentColor; }
.h-xl { font-size: clamp(48px, 8.4vw, 128px); line-height: .9; letter-spacing: -.035em; font-stretch: 118%; }
.h-lg { font-size: clamp(36px, 5.2vw, 72px); line-height: .95; letter-spacing: -.03em; }
.h-md { font-size: clamp(26px, 2.8vw, 38px); line-height: 1.05; }
.lede { font-size: clamp(19px, 1.7vw, 23px); line-height: 1.5; color: var(--ink-2); max-width: 58ch; }
.mono { font-family: var(--f-mono); }

/* ---------- Buttons ---------- */
.btn {
  --bg: var(--ink); --fg: #fff;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 54px; padding: 0 26px; border-radius: 999px;
  background: var(--bg); color: var(--fg); border: 2px solid var(--bg);
  font: 700 17px/1 var(--f-body); text-decoration: none; white-space: nowrap; cursor: pointer;
  transition: transform .3s var(--spring), box-shadow .3s, background .2s, color .2s;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 14px 28px -12px rgba(10,22,48,.5); }
.btn svg { width: 18px; height: 18px; transition: transform .3s var(--ease); }
.btn:hover svg { transform: translateX(4px); }
.btn--ghost { --bg: transparent; --fg: var(--ink); border-color: var(--line-2); }
.btn--ghost:hover { background: var(--white); }
.btn--light { --bg: #fff; --fg: var(--ink); }
.btn--lemon { --bg: var(--lemon); --fg: var(--ink); }
.btn--sm { min-height: 42px; padding: 0 18px; font-size: 15px; }

/* ---------- Nav ---------- */
.nav { position: sticky; top: 0; z-index: 60; transition: background .3s, box-shadow .3s; }
.nav.is-stuck { background: rgba(245, 247, 251, .86); backdrop-filter: saturate(1.5) blur(16px); -webkit-backdrop-filter: saturate(1.5) blur(16px); box-shadow: 0 1px 0 var(--line); }
.nav__in { display: flex; align-items: center; gap: 28px; height: 76px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--logo); }
.brand svg { width: 34px; height: 38px; }
.brand span { font: 800 26px/1 var(--f-display); font-stretch: 105%; letter-spacing: -.03em; }
.nav__links { display: flex; gap: 2px; }
.nav__links a { padding: 10px 14px; border-radius: 999px; text-decoration: none; font-weight: 600; font-size: 16px; color: var(--ink-2); transition: background .2s, color .2s; }
.nav__links a:hover, .nav__links a[aria-current="page"] { background: rgba(10,22,48,.06); color: var(--ink); }
.nav__cta { margin-left: auto; display: flex; gap: 10px; align-items: center; }
.nav__menu { display: none; margin-left: auto; width: 46px; height: 46px; border-radius: 14px; border: 1px solid var(--line-2); background: var(--white); align-items: center; justify-content: center; cursor: pointer; }
.nav__menu span, .nav__menu span::before, .nav__menu span::after { display: block; width: 18px; height: 2px; background: var(--ink); border-radius: 2px; position: relative; transition: transform .25s var(--ease), background .2s; }
.nav__menu span::before, .nav__menu span::after { content: ""; position: absolute; left: 0; }
.nav__menu span::before { top: -6px; } .nav__menu span::after { top: 6px; }
.nav.is-open .nav__menu span { background: transparent; }
.nav.is-open .nav__menu span::before { transform: translateY(6px) rotate(45deg); }
.nav.is-open .nav__menu span::after { transform: translateY(-6px) rotate(-45deg); }
@media (max-width: 960px) {
  .nav__menu { display: inline-flex; }
  .nav__links, .nav__cta { display: none; }
  .nav.is-open { background: var(--cloud); }
  .nav.is-open .nav__links { display: flex; flex-direction: column; position: absolute; left: 0; right: 0; top: 76px; padding: 8px var(--gutter) 24px; background: var(--cloud); box-shadow: 0 1px 0 var(--line); }
  .nav.is-open .nav__links a { font-size: 22px; font-family: var(--f-display); font-weight: 800; padding: 12px 6px; }
}

/* ---------- Sections ---------- */
.section { padding: clamp(80px, 11vw, 160px) 0; position: relative; }
.section--tight { padding: clamp(56px, 7vw, 100px) 0; }
.section--white { background: var(--white); }
.section--dark { background: var(--ink); color: var(--on-dark); }
.section--dark .lede { color: var(--on-dark-mute); }
.section--dark .eyebrow { color: var(--lemon); }
.head { display: grid; gap: 20px; max-width: 820px; margin-bottom: clamp(40px, 5vw, 72px); }
.head--center { margin-inline: auto; text-align: center; justify-items: center; }

/* ---------- Lists & frames ---------- */
.ticks { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 12px; }
.ticks li { position: relative; padding-left: 34px; line-height: 1.45; }
.ticks li::before {
  content: ""; position: absolute; left: 0; top: 1px; width: 22px; height: 22px; border-radius: 50%;
  background: var(--c, var(--contact)) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5.5 12.5l4 4L18.5 7.5'/%3E%3C/svg%3E") center / 13px no-repeat;
}
.phone { position: relative; aspect-ratio: 1206 / 2622; background: #0b0f16; border-radius: 15% / 7%; padding: 3.2%; box-shadow: var(--shadow-xl), inset 0 0 0 2px #2b3446; }
.phone img { width: 100%; height: 100%; object-fit: cover; object-position: top; border-radius: 12.5% / 5.8%; background: #f2f4f7; }

/* ---------- Compare table ---------- */
.compare-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; border-radius: var(--r-lg); background: var(--white); box-shadow: var(--shadow); }
.compare { width: 100%; min-width: 820px; border-collapse: collapse; font-size: 16px; color: var(--ink); }
.compare th, .compare td { padding: 16px 14px; text-align: center; border-bottom: 1px solid var(--line); }
.compare thead th { font: 800 17px/1.2 var(--f-display); font-stretch: 105%; background: var(--white); position: sticky; top: 0; }
.compare thead th small { display: block; font: 500 12px/1.3 var(--f-body); color: var(--ink-3); margin-top: 4px; font-stretch: 100%; }
.compare tbody th { text-align: left; font-weight: 600; }
.compare tbody th small { display: block; font-weight: 400; color: var(--ink-3); font-size: 14px; }
.compare td { color: var(--ink-3); }
.compare .us { background: rgba(29, 95, 166, .07); color: var(--ink); font-weight: 700; }
.compare thead .us { background: var(--brand); color: #fff; border-radius: 16px 16px 0 0; }
.compare .grp th { text-align: left; font: 800 13px/1 var(--f-body); letter-spacing: .12em; text-transform: uppercase; color: var(--brand); padding-top: 30px; }
.y, .n, .p { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; font-weight: 800; font-size: 14px; }
.y { background: var(--contact); color: #fff; }
.n { background: transparent; color: #b6bfce; }
.p { background: rgba(255, 216, 77, .4); color: #6b5300; }
.compare__note { margin-top: 18px; font-size: 14px; color: var(--ink-3); max-width: 92ch; }
.section--dark .compare__note { color: var(--on-dark-mute); }
.compare__note a { color: inherit; }

/* ---------- Pricing ---------- */
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; align-items: stretch; }
.plan { background: var(--white); border-radius: var(--r-lg); padding: 34px; box-shadow: var(--shadow); display: flex; flex-direction: column; position: relative; }
.plan--hot { background: var(--brand); color: #fff; box-shadow: var(--shadow-xl); transform: translateY(-10px); }
.plan--hot .alt, .plan--hot .price small { color: rgba(255,255,255,.75); }
.plan--hot .ticks li::before { background-color: var(--lemon); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230a1630' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5.5 12.5l4 4L18.5 7.5'/%3E%3C/svg%3E"); }
.plan__flag { position: absolute; top: -14px; left: 34px; background: var(--lemon); color: var(--ink); font: 800 12px/1 var(--f-body); letter-spacing: .1em; text-transform: uppercase; padding: 8px 12px; border-radius: 99px; }
.plan h3 { font-size: 28px; }
.plan .price { margin: 20px 0 6px; font: 800 60px/1 var(--f-display); font-stretch: 112%; letter-spacing: -.04em; }
.plan .price small { font: 600 17px/1 var(--f-body); letter-spacing: 0; color: var(--ink-3); }
.plan .alt { font-size: 15px; color: var(--ink-3); min-height: 1.5em; }
.plan .ticks { margin: 26px 0 30px; }
.plan .btn { margin-top: auto; }
@media (max-width: 960px) { .plans { grid-template-columns: 1fr; } .plan--hot { transform: none; } }

/* ---------- Blog cards ---------- */
.posts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.post { display: flex; flex-direction: column; background: var(--white); border-radius: var(--r-lg); overflow: hidden; text-decoration: none; box-shadow: var(--shadow); transition: transform .4s var(--spring), box-shadow .4s; }
.post:hover { transform: translateY(-6px); box-shadow: var(--shadow-xl); }
.post__img { aspect-ratio: 16 / 10; overflow: hidden; background: #e6ebf2; }
.post__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .9s var(--ease); }
.post:hover .post__img img { transform: scale(1.05); }
.post__body { padding: 22px 24px 26px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.post__meta, .post__date { font: 700 12px/1 var(--f-body); letter-spacing: .12em; text-transform: uppercase; color: var(--brand); }
.post h3 { font-size: 23px; line-height: 1.1; }
.post p { color: var(--ink-2); font-size: 16px; margin: 0; }
@media (max-width: 960px) { .posts { grid-template-columns: 1fr; } }

/* ---------- CTA ---------- */
.cta { text-align: center; }
.cta__box { position: relative; overflow: hidden; background: var(--brand); color: #fff; border-radius: 40px; padding: clamp(56px, 9vw, 120px) var(--gutter); }
.cta__box h2 { color: #fff; }
.cta__box .lede { color: rgba(255,255,255,.82); margin: 20px auto 0; }
.cta__qrs { position: absolute; inset: 0; pointer-events: none; }
.cta__qrs i { position: absolute; width: 120px; aspect-ratio: 1; border: 16px solid currentColor; border-radius: 30px; opacity: .9; }
.cta__qrs i::after { content: ""; position: absolute; inset: 22%; background: currentColor; border-radius: 12px; }
.cta__qrs i:nth-child(1) { left: -40px; top: -40px; color: var(--contact); }
.cta__qrs i:nth-child(2) { right: -30px; top: 50px; color: var(--lemon); transform: rotate(12deg); }
.cta__qrs i:nth-child(3) { left: 7%; bottom: -54px; color: var(--connect); transform: rotate(-10deg); }
.cta__qrs i:nth-child(4) { right: 9%; bottom: -44px; color: var(--data); transform: rotate(8deg); }
.stores { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 36px; position: relative; }
.stores a { display: inline-flex; transition: transform .3s var(--spring); }
.stores a:hover { transform: translateY(-3px); }
.stores img { height: 54px; width: auto; }
.webapp { display: inline-flex; align-items: center; gap: 10px; height: 54px; padding: 0 20px; border-radius: 12px; background: #fff; color: var(--ink); text-decoration: none; font-weight: 700; }
.webapp svg { width: 22px; height: 22px; }

/* ---------- Footer ---------- */
.footer { padding: 80px 0 36px; }
.footer__grid { display: grid; grid-template-columns: 1.5fr repeat(3, 1fr); gap: 36px; }
.footer__grid p { color: var(--ink-2); font-size: 16px; max-width: 34ch; margin-top: 16px; }
.footer h4 { font: 800 13px/1 var(--f-body); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 16px; }
.footer nav { display: grid; gap: 10px; }
.footer nav a { text-decoration: none; font-size: 16px; font-weight: 500; }
.footer nav a:hover { color: var(--brand); }
.footer__base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; margin-top: 64px; padding-top: 24px; border-top: 1px solid var(--line); font-size: 14px; color: var(--ink-3); }
.footer__base a { color: inherit; }
@media (max-width: 820px) { .footer__grid { grid-template-columns: 1fr 1fr; } .footer__grid > div:first-child { grid-column: 1 / -1; } }

/* ---------- Long-form pages ---------- */
.page-head { padding: clamp(56px, 8vw, 120px) 0 clamp(32px, 4vw, 56px); }
.page-head .lede { margin-top: 18px; }
.prose { max-width: 720px; font-size: 19px; line-height: 1.7; }
.prose h2 { font-size: clamp(26px, 2.8vw, 34px); margin: 2em 0 .6em; }
.prose h3 { font-size: 22px; margin: 1.6em 0 .5em; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin: .35em 0; }
.prose a { color: var(--brand); text-underline-offset: 3px; }
.prose img { border-radius: var(--r); margin: 1.6em 0; box-shadow: var(--shadow); }
.prose hr { border: 0; border-top: 1px solid var(--line-2); margin: 2.4em 0; }
.prose blockquote { margin: 1.4em 0; padding: 16px 22px; border-left: 4px solid var(--brand); background: var(--white); border-radius: 0 14px 14px 0; }
.prose code { font-family: var(--f-mono); font-size: .86em; background: #e7ecf3; padding: 2px 6px; border-radius: 6px; }
.paper { background: var(--white); border-radius: var(--r-lg); padding: clamp(26px, 5vw, 68px); box-shadow: var(--shadow); }
.steps { counter-reset: s; list-style: none; padding: 0; display: grid; gap: 14px; }
.steps > li { counter-increment: s; position: relative; padding: 20px 22px 20px 72px; background: var(--cloud); border-radius: 18px; }
.steps > li::before { content: counter(s); position: absolute; left: 20px; top: 17px; width: 36px; height: 36px; border-radius: 50%; background: var(--brand); color: #fff; display: grid; place-items: center; font: 800 16px/1 var(--f-display); }
.callout { display: flex; gap: 14px; padding: 20px 22px; border-radius: 18px; background: #fff4ef; border: 1px solid #ffd2c2; font-size: 17px; }

/* ---------- Reveal ---------- */
.rv { opacity: 0; transform: translateY(28px); transition: opacity .9s var(--ease), transform .9s var(--ease); transition-delay: var(--d, 0s); }
.rv.is-visible { opacity: 1; transform: none; }
.no-js .rv { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  .rv { opacity: 1; transform: none; }
}
