/* Silverposy design system
   Colors and type are defined once here; components below use these tokens.
   Blue and green are taken from the Silverposy wordmark. */

@font-face {
  font-family: "Atkinson Hyperlegible";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/atkinson-hyperlegible-latin-400-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Atkinson Hyperlegible";
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/atkinson-hyperlegible-latin-400-italic.woff2") format("woff2");
}
@font-face {
  font-family: "Atkinson Hyperlegible";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/atkinson-hyperlegible-latin-700-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Nunito Sans";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/nunito-sans-latin-700-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Nunito Sans";
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url("/assets/fonts/nunito-sans-latin-800-normal.woff2") format("woff2");
}

:root {
  --ivory: #FAF7F0;
  --white: #FFFFFF;
  --charcoal: #262A2F;      /* body text */
  --blue: #304B69;          /* muted blue, from the wordmark */
  --blue-dark: #233A54;
  --blue-soft: #E8EEF4;
  --sage: #566D3D;          /* sage green, from the wordmark */
  --sage-soft: #E9EEE1;
  --rule: #DDD6C8;
  --focus: #B5651D;

  --font-body: "Atkinson Hyperlegible", "Lato", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  --font-head: "Nunito Sans", "Lato", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;

  --text: 1.25rem;          /* 20px body */
  --h1: 3rem;               /* 48px */
  --h2: 2rem;               /* 32px */
  --h3: 1.5rem;             /* 24px */
  --nav: 1.125rem;          /* 18px */
  --leading: 1.6;

  --wrap: 72rem;
  --narrow: 46rem;
  --gutter: clamp(1rem, 4vw, 2.5rem);
  --section: clamp(3.5rem, 8vw, 6rem);
  --radius: 14px;
}

@media (max-width: 40rem) {
  :root {
    --h1: 2.25rem;          /* 36px */
    --h2: 1.75rem;          /* 28px */
    --h3: 1.375rem;
  }
}

/* ---------- Base ---------- */

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--ivory);
  color: var(--charcoal);
  font-family: var(--font-body);
  font-size: var(--text);
  line-height: var(--leading);
}

h1, h2, h3 {
  margin: 0;
  color: var(--blue-dark);
  font-family: var(--font-head);
  font-weight: 800;
  line-height: 1.2;
}
h1 { font-size: var(--h1); }
h2 { font-size: var(--h2); }
h3 { font-size: var(--h3); font-weight: 700; }

p, ul, ol { margin: 0; }
p + p { margin-top: 1em; }
h2 + p, h3 + p { margin-top: 0.75rem; }

img { max-width: 100%; height: auto; display: block; }

a { color: var(--blue); text-decoration-thickness: 2px; text-underline-offset: 0.18em; }
a:hover { color: var(--blue-dark); }

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

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.narrow { max-width: var(--narrow); }

.skip-link {
  position: absolute;
  left: 1rem;
  top: -10rem;
  padding: 0.75rem 1.25rem;
  background: var(--blue-dark);
  color: var(--white);
  font-weight: 700;
  z-index: 10;
}
.skip-link:focus { top: 1rem; }

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* ---------- Header ---------- */

.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--rule);
}

.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 2rem;
  padding-top: 1rem;
  padding-bottom: 1rem;
}

.logo { display: block; }
.logo img { width: 220px; }

.site-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 0.5rem;
  list-style: none;
  padding: 0;
}

.site-nav a {
  display: block;
  padding: 0.6rem 0.9rem;
  border-radius: 999px;
  color: var(--charcoal);
  font-size: var(--nav);
  font-weight: 700;
  text-decoration: none;
}
.site-nav a:hover { background: var(--blue-soft); color: var(--blue-dark); }
.site-nav a[aria-current="page"] {
  background: var(--blue);
  color: var(--white);
}

@media (max-width: 52rem) {
  .header-inner { justify-content: center; }
  .site-nav ul { justify-content: center; }
}

@media (max-width: 40rem) {
  .logo img { width: 180px; }
  .site-nav a { padding: 0.55rem 0.7rem; }
}

/* ---------- Buttons ---------- */

.buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 2rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3.5rem;
  padding: 0.85rem 1.75rem;
  border: 2px solid var(--blue);
  border-radius: 999px;
  background: var(--blue);
  color: var(--white);
  font-family: var(--font-body);
  font-size: 1.25rem;       /* 20px */
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
}
.btn:hover { background: var(--blue-dark); border-color: var(--blue-dark); color: var(--white); }

.btn-quiet { background: transparent; color: var(--blue); }
.btn-quiet:hover { background: var(--blue-soft); color: var(--blue-dark); }

/* ---------- Store links ---------- */

.stores {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 1rem;
  margin-top: 1.5rem;
}

.store {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-height: 5rem;
  padding: 1rem 1.5rem;
  border-radius: var(--radius);
  background: var(--charcoal);
  color: var(--white);
  text-decoration: none;
}
a.store:hover { background: var(--blue-dark); color: var(--white); }

.store-label {
  font-family: var(--font-head);
  font-size: 1.375rem;
  font-weight: 800;
}
.store-device { font-size: 1.125rem; }

.store-pending {
  margin: 0;
  background: var(--white);
  border: 2px dashed var(--rule);
  color: var(--charcoal);
}
.store-soon {
  margin-top: 0.35rem;
  color: var(--sage);
  font-size: 1.125rem;
  font-weight: 700;
}

/* ---------- Screenshots ---------- */

.shot {
  margin: 0;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--white);
  box-shadow: 0 6px 28px rgba(35, 58, 84, 0.14);
}

.shot-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 4 / 3;
  padding: 1.5rem;
  border: 3px dashed #C9D3DE;
  background: var(--blue-soft);
  box-shadow: none;
  text-align: center;
}
.shot-placeholder.shot-tall { aspect-ratio: 1 / 2; max-width: 16rem; }
.shot-placeholder p {
  color: var(--blue);
  font-size: 1.125rem;
  font-weight: 700;
}

/* ---------- Hero ---------- */

.hero {
  padding: clamp(2.5rem, 6vw, 5rem) 0 var(--section);
  background: var(--ivory);
}

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

.hero .lead {
  margin-top: 1.25rem;
  font-size: 1.375rem;
}
.hero .lead + p { margin-top: 1rem; }

@media (max-width: 52rem) {
  .hero-inner { grid-template-columns: 1fr; }
}

/* ---------- Sections ---------- */

.section { padding: var(--section) 0; }
.section-white { background: var(--white); }
.section-sage { background: var(--sage-soft); }

.section-title { margin-bottom: 1rem; }
.section-intro { max-width: var(--narrow); margin-bottom: 2.5rem; }

.eyebrow {
  margin-bottom: 0.5rem;
  color: var(--sage);
  font-family: var(--font-head);
  font-size: 1.125rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* Text beside a screenshot */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}
.split + .split { margin-top: var(--section); }
.split-flip > :first-child { order: 2; }

@media (max-width: 52rem) {
  .split { grid-template-columns: 1fr; }
  .split-flip > :first-child { order: 0; }
}

/* Short points with a check mark */
.points {
  list-style: none;
  padding: 0;
  margin-top: 1.5rem;
}
.points li {
  position: relative;
  padding-left: 2.25rem;
}
.points li + li { margin-top: 0.85rem; }
.points li::before {
  content: "";
  position: absolute;
  left: 0.2rem;
  top: 0.35em;
  width: 0.75rem;
  height: 1.2rem;
  border: solid var(--sage);
  border-width: 0 4px 4px 0;
  transform: rotate(40deg);
}

/* A quoted example, e.g. a Home screen message */
.example {
  margin: 1.75rem 0 0;
  padding: 1.25rem 1.5rem;
  border-left: 6px solid var(--sage);
  border-radius: 0 var(--radius) var(--radius) 0;
  background: var(--white);
  font-size: 1.375rem;
}

/* Smaller cards for the supporting features */
.extras {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
  gap: 1.25rem;
  list-style: none;
  padding: 0;
}
.extras li {
  padding: 1.5rem;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  background: var(--white);
}
.extras h3 { margin-bottom: 0.4rem; }

/* Two apps side by side */
.duo {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  list-style: none;
  padding: 0;
}
.duo li {
  padding: 1.75rem;
  border-radius: var(--radius);
  background: var(--white);
  border: 1px solid var(--rule);
}
.duo h3 { margin-bottom: 0.5rem; }
@media (max-width: 52rem) {
  .duo { grid-template-columns: 1fr; }
}

/* Numbered steps */
.steps {
  list-style: none;
  padding: 0;
  counter-reset: step;
}
.steps > li {
  position: relative;
  padding: 0 0 0 4rem;
  counter-increment: step;
}
.steps > li + li { margin-top: 2rem; }
.steps > li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  background: var(--blue);
  color: var(--white);
  font-family: var(--font-head);
  font-weight: 800;
}
.steps h3 { margin-bottom: 0.35rem; }

/* Clearly marked text still to be written */
.placeholder {
  padding: 1rem 1.25rem;
  border: 2px dashed #C9D3DE;
  border-radius: var(--radius);
  background: var(--blue-soft);
  color: var(--blue);
  font-weight: 700;
}
* + .placeholder { margin-top: 1rem; }

/* Price */
.price-card {
  max-width: var(--narrow);
  padding: 2rem;
  border-radius: var(--radius);
  background: var(--white);
  border: 1px solid var(--rule);
}
.price {
  color: var(--blue-dark);
  font-family: var(--font-head);
  font-size: var(--h1);
  font-weight: 800;
  line-height: 1.2;
}

/* Help: questions and answers */
.faq { max-width: var(--narrow); }
.faq h3 { margin-top: 2rem; }
.faq h3:first-child { margin-top: 0; }
.faq p { margin-top: 0.4rem; }

/* Page heading for inner pages */
.page-head {
  padding: clamp(2.5rem, 6vw, 4.5rem) 0 clamp(1rem, 3vw, 2rem);
}
.page-head p {
  max-width: var(--narrow);
  margin-top: 1rem;
  font-size: 1.375rem;
}

.cta {
  text-align: center;
}
.cta p { max-width: var(--narrow); margin: 1rem auto 0; }
.cta .buttons { justify-content: center; }
.cta .stores { max-width: 56rem; margin-left: auto; margin-right: auto; text-align: left; }

/* ---------- Footer ---------- */

.site-footer {
  padding: 3rem 0;
  background: var(--blue-dark);
  color: var(--white);
}
.site-footer a { color: var(--white); }
.footer-inner > * + * { margin-top: 1.25rem; }
.footer-line { max-width: var(--narrow); font-size: 1.375rem; }
.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  list-style: none;
  padding: 0;
  font-size: var(--nav);
}
.footer-nav a { font-weight: 700; }
.footer-nav a[aria-current="page"] { text-decoration: none; }
.footer-legal { color: #D6DEE8; font-size: 1.125rem; }

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; }
}
