/*
 * Passetta marketing design system — visual language modeled on koalify.io
 * (Lexend Deca, ink navy #2D3E50, signal orange #FF4800, pill buttons,
 * circle-blob illustrations, dark navy footer). Shared by every marketing
 * page under public/ except the scanner PWA (/scan), which is an app shell,
 * not a marketing page.
 *
 * Light-only on purpose: the reference design has no dark mode, and the
 * public-page E2E audits for invisible text under the default color scheme.
 */

:root {
  --ink: #2d3e50;
  --ink-soft: #5a6b7c;
  --accent: #ff4800;
  /* Foreground variant of the brand orange: #ff4800 only reaches 3.40:1 on
   * white, so any sub-large text (links, button fills at 15px) uses this
   * darker step, which clears WCAG AA at 5.04:1. #ff4800 stays for large
   * display text (hero accent) and decorative fills. */
  --accent-text: #cc3a00;
  --accent-down: #b33300;
  --bg: #ffffff;
  --bg-soft: #fcfcfa;
  --teal: #1f93a8;
  --line: #e6e9ed;
  --maxw: 1140px;
  --pill: 999px;
  /* Buttons follow hubspot.com's own primary CTA, measured 2026-08-13:
     #ff4800 on white, 8px radius, 16px/500, sentence case, normal tracking,
     12px 24px padding. Visitors arrive from HubSpot; a control that looks
     like HubSpot's reads as native there. */
  --btn-radius: 8px;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  background: var(--bg);
  color: var(--ink);
  font-family:
    "Lexend Deca",
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  font-size: 16px;
  line-height: 1.65;
}

a {
  color: var(--accent-text);
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: #fff;
  color: var(--ink);
  padding: 10px 18px;
  border-radius: 0 0 10px 0;
  font-weight: 600;
  text-decoration: none;
}

.skip-link:focus {
  left: 0;
}

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

.section--dark :focus-visible,
.site-footer :focus-visible {
  outline-color: #fff;
}

h1,
h2,
h3 {
  line-height: 1.18;
  letter-spacing: -0.01em;
}

.accent {
  color: var(--accent);
}

.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-top: 14px;
  padding-bottom: 14px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 20px;
  text-decoration: none;
  color: var(--ink);
  flex-shrink: 0;
}

/* The same artwork the tab icon and the HubSpot app logo use — /brand/icon.svg
   carries its own amber fill and corner radius, so this rule only sizes it. A
   plain gradient disc here used to be the one place the wordmark appeared
   without the P. */
.brand-mark {
  width: 30px;
  height: 30px;
  background: url("/brand/icon.svg") center / contain no-repeat;
  display: inline-block;
  flex-shrink: 0;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 26px;
  font-size: 15px;
  font-weight: 500;
}

.site-nav a:not(.btn) {
  text-decoration: none;
  color: var(--ink);
}

.site-nav a:not(.btn):hover {
  color: var(--accent-text);
}

.site-nav .btn {
  margin-left: 6px;
}

@media (max-width: 760px) {
  .site-nav a:not(.btn) {
    display: none;
  }
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--btn-radius);
  font-weight: 500;
  font-size: 16px;
  text-decoration: none;
  white-space: nowrap;
  border: 2px solid var(--accent);
  transition:
    background 0.15s,
    color 0.15s;
}

@media (max-width: 420px) {
  .site-nav .btn {
    padding: 10px 16px;
    font-size: 14px;
  }
}

/* `--accent-text` stays the darkened #cc3a00 everywhere it is *text* on white
   — at body size #ff4800 is 3.4:1 and fails AA. As a button fill behind white
   it is the brand orange: hubspot.com and koalify.io both ship #ff4800 there
   at the same 3.4:1. */
.btn-primary {
  background: var(--accent);
  color: #fff;
}

.btn-primary:hover {
  background: var(--accent-text);
  border-color: var(--accent-text);
}

.btn-outline {
  background: transparent;
  color: var(--accent-text);
}

.btn-outline:hover {
  background: var(--accent);
  color: #fff;
}

/* On dark navy sections the outline button reads white. */
.section--dark .btn-outline {
  border-color: #fff;
  color: #fff;
}

.section--dark .btn-outline:hover {
  background: #fff;
  color: var(--ink);
}

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

.section {
  padding: 88px 0;
}

.section--soft {
  background: var(--bg-soft);
}

.section--dark {
  background: var(--ink);
  color: #fff;
}

.section--dark a:not(.btn) {
  color: #ffb08c;
}

.section-title {
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 700;
  text-align: center;
  margin: 0 0 12px;
}

.section-lede {
  text-align: center;
  color: var(--ink-soft);
  max-width: 62ch;
  margin: 0 auto 56px;
}

.section--dark .section-lede {
  color: rgba(255, 255, 255, 0.75);
}

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

.hero {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 48px;
  align-items: center;
  /* Longhand on purpose: the hero element also carries .container, and the
   * `padding: 72px 0 88px` shorthand was wiping .container's 24px gutters. */
  padding-top: 72px;
  padding-bottom: 88px;
}

@media (max-width: 860px) {
  .hero {
    grid-template-columns: 1fr;
    padding-top: 40px;
  }
}

.hero h1 {
  font-size: clamp(40px, 5.5vw, 60px);
  font-weight: 700;
  line-height: 1.15;
  margin: 0 0 20px;
}

.hero .lede {
  font-size: 18px;
  color: var(--ink-soft);
  max-width: 50ch;
  margin: 0 0 32px;
}

.hero .actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 22px;
}

.hero .reassure {
  font-size: 14px;
  color: var(--ink-soft);
}

/* pass-card mockup floating on blob shapes */

.hero-visual {
  position: relative;
  min-height: 520px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-visual .blob {
  position: absolute;
  border-radius: 50%;
}

.hero-visual .blob--orange {
  width: 340px;
  height: 340px;
  background: var(--accent);
  opacity: 0.16;
  top: 0;
  right: -4%;
}

.hero-visual .blob--teal {
  width: 170px;
  height: 170px;
  background: var(--teal);
  opacity: 0.25;
  bottom: 4%;
  left: 0;
}

.pass-card {
  position: relative;
  transform: rotate(-4deg);
  border-radius: 24px;
  padding: 28px;
  background-color: var(--ink);
  background-image: linear-gradient(165deg, #22303f 0%, var(--ink) 55%, #3c5168 100%);
  color: #fff;
  width: 320px;
  aspect-ratio: 340 / 460;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 24px 48px -20px rgba(45, 62, 80, 0.45);
}

.pass-card .org {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: rgba(255, 255, 255, 0.72);
}

.pass-card .name {
  font-size: 22px;
  font-weight: 700;
  margin-top: 6px;
}

.pass-card .pill {
  margin-top: 10px;
  display: inline-block;
  padding: 4px 14px;
  border-radius: var(--pill);
  background: var(--accent);
  font-size: 12px;
  font-weight: 600;
  width: fit-content;
}

.pass-card .qr {
  align-self: center;
  width: 128px;
  height: 128px;
  border-radius: 12px;
  background: repeating-conic-gradient(#2d3e50 0% 25%, #ffffff 0% 50%) 0 0 / 16px 16px;
  border: 6px solid #fff;
}

.pass-card .caption {
  text-align: center;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.8);
  margin-top: 8px;
}

/* ---------- numbered steps ---------- */

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

@media (max-width: 860px) {
  .steps {
    grid-template-columns: 1fr;
  }
}

.step .step-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  font-size: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

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

.step p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 15px;
}

/* ---------- alternating feature rows ---------- */

.feature-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}

@media (max-width: 860px) {
  .feature-row {
    grid-template-columns: 1fr;
  }
  .feature-row .feature-visual {
    order: -1;
  }
}

.feature-row h2 {
  font-size: clamp(26px, 3.4vw, 36px);
  font-weight: 700;
  margin: 0 0 16px;
}

.feature-row p {
  color: var(--ink-soft);
  margin: 0 0 26px;
}

.feature-row .actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.feature-visual {
  display: flex;
  align-items: center;
  justify-content: center;
}

.feature-visual .circle {
  position: relative;
  width: min(380px, 80vw);
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--teal);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Mocks overhang their disc (reference treatment) instead of sitting
 * bullseye-centred; flat on small screens where the offset would clip. */
.feature-visual .mock {
  position: relative;
  transform: translate(-34px, 18px);
}

.feature-row--flip .feature-visual .mock {
  transform: translate(34px, -18px);
}

@media (max-width: 860px) {
  .feature-visual .mock,
  .feature-row--flip .feature-visual .mock {
    transform: none;
  }
}

/* small UI mockup cards that sit on the circles */

.mock {
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 18px 40px -18px rgba(45, 62, 80, 0.5);
  padding: 18px 20px;
  width: min(300px, 70vw);
  font-size: 13px;
}

.mock .mock-title {
  font-weight: 700;
  font-size: 14px;
  margin-bottom: 10px;
}

.mock .mock-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-top: 1px solid var(--line);
  color: var(--ink-soft);
}

.mock .mock-row strong {
  color: var(--ink);
  font-weight: 600;
}

.mock .tag {
  display: inline-block;
  padding: 2px 10px;
  border-radius: var(--pill);
  font-size: 11px;
  font-weight: 700;
}

.mock .tag--ok {
  background: rgba(61, 220, 132, 0.18);
  color: #0c7a43;
}

.mock .tag--accent {
  background: rgba(255, 72, 0, 0.08);
  color: var(--accent-text);
}

/* ---------- security / dark section ---------- */

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

@media (max-width: 860px) {
  .security-grid {
    grid-template-columns: 1fr;
  }
}

.security-item h3 {
  font-size: 17px;
  margin: 0 0 8px;
}

.security-item p {
  margin: 0;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.75);
}

/* ---------- FAQ ---------- */

.eyebrow {
  text-align: center;
  color: var(--accent-text);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0 0 6px;
}

.faq {
  max-width: 820px;
  margin: 0 auto;
  display: grid;
  gap: 20px;
}

.faq details {
  background: #fff;
  border: 0;
  border-radius: 10px;
  padding: 0 26px;
  box-shadow: 0 1px 2px rgba(45, 62, 80, 0.05);
}

.faq summary {
  cursor: pointer;
  list-style: none;
  font-weight: 600;
  font-size: 17px;
  padding: 22px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

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

.faq summary::after {
  content: "\25be";
  color: var(--accent-text);
  font-size: 16px;
  font-weight: 400;
  flex-shrink: 0;
  transition: transform 0.15s;
}

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

.faq details p {
  margin: 0 0 18px;
  color: var(--ink-soft);
  font-size: 15px;
}

/* ---------- CTA band ---------- */

.cta-band {
  text-align: center;
}

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

/* ---------- content pages (docs, support, legal) ---------- */

.page-hero {
  background: var(--bg-soft);
  padding: 64px 0 56px;
}

/* Align the hero's text edge with the 820px prose column below it. */
.page-hero .container {
  max-width: 868px;
}

.page-hero h1 {
  font-size: clamp(34px, 4.5vw, 52px);
  font-weight: 700;
  margin: 0 0 12px;
}

.page-hero .lede {
  color: var(--ink-soft);
  font-size: 18px;
  max-width: 62ch;
  margin: 0;
}

.prose {
  max-width: 820px;
  margin: 0 auto;
  padding: 56px 24px 88px;
}

.prose h2 {
  font-size: 26px;
  margin: 44px 0 12px;
}

.prose h3 {
  font-size: 19px;
  margin: 28px 0 8px;
}

.prose p,
.prose li {
  color: var(--ink-soft);
}

.prose li {
  margin-bottom: 6px;
}

.prose strong {
  color: var(--ink);
}

.prose code {
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 1px 6px;
  font-size: 14px;
}

.prose .card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 22px 26px;
}

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

.site-footer {
  background: var(--ink);
  color: rgba(255, 255, 255, 0.72);
  padding: 64px 0 40px;
  font-size: 14px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 48px;
}

@media (max-width: 860px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.site-footer .brand {
  color: #fff;
  margin-bottom: 12px;
}

.footer-col h4 {
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin: 0 0 14px;
}

.footer-col a {
  display: block;
  color: rgba(255, 255, 255, 0.72);
  text-decoration: none;
  padding: 4px 0;
}

.footer-col a:hover {
  color: #fff;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 13px;
}

.footer-bottom a {
  color: rgba(255, 255, 255, 0.72);
}
