/* Signika: a sans for wayfinding and signage. Self-hosted, see fonts/OFL.txt. */
@font-face {
  font-family: "Signika";
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url("/fonts/signika-latin.woff2") format("woff2");
  unicode-range:
    U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC,
    U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212,
    U+2215, U+FEFF, U+FFFD;
}

:root {
  color-scheme: light dark;
  --paper: #ffffff;
  --ink: #000000;
  --steel: #5c6366;
  --rule: #dde1e2;
  --wash: #eff1f1;
  /* Swiss hiking-sign yellow. Only for things that take you somewhere. */
  --sign: #ffcc00;
  --pole-shade: #8e979a;
  --pole-light: #e4e8e9;
  --tip: 52px;
  font-family: "Signika", ui-sans-serif, system-ui, sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

/* Shared: support pages, privacy policies, legal notice */

* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-size: 1.125rem;
  line-height: 1.55;
}
a {
  color: inherit;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}
a:hover {
  text-decoration-thickness: 2px;
}
:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 3px;
}
::selection {
  background: var(--sign);
  color: #000;
}
h1,
h2,
h3 {
  font-weight: 600;
  line-height: 1.12;
  letter-spacing: -0.01em;
  text-wrap: balance;
}
h1 {
  margin: 0 0 0.6em;
  font-size: 2.75rem;
}
h2 {
  margin: 2em 0 0.5em;
  font-size: 1.75rem;
}
h3 {
  margin: 1.6em 0 0.35em;
  font-size: 1.3125rem;
}
p {
  margin: 0 0 1em;
}
h1,
h2,
h3,
p {
  overflow-wrap: break-word;
}
main {
  width: min(100% - 40px, 38rem);
  margin: 0 auto;
  padding: 32px 0 72px;
}
.nav,
.meta,
main footer {
  color: var(--steel);
  font-size: 1rem;
}
.nav {
  margin: 0 0 56px;
}
.nav a,
main footer a {
  display: inline-block;
  padding-block: 10px;
}
.nav a[href="/"] {
  color: var(--ink);
  font-weight: 600;
}
.meta {
  margin-block: -0.4em 2em;
}
main footer {
  margin-top: 72px;
  padding-top: 14px;
  border-top: 1px solid var(--rule);
}
hr {
  margin: 72px 0;
  border: 0;
  border-top: 1px solid var(--rule);
}
code {
  padding: 1px 5px;
  border-radius: 4px;
  background: var(--wash);
  font-size: 0.9em;
  overflow-wrap: anywhere;
}

/* Start page */

.skip-link {
  position: absolute;
  top: 12px;
  left: 24px;
  z-index: 2;
  padding: 10px 20px;
  background: var(--sign);
  color: #000;
  transform: translateY(-180%);
}
.skip-link:focus {
  transform: none;
}
.site-header,
.home,
.site-footer {
  width: min(100% - 64px, 1160px);
  margin-inline: auto;
}
.home {
  padding: 0;
}
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 88px;
}
.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  font-size: 1.375rem;
  font-weight: 600;
  text-decoration: none;
}
/* Twice the favicon's 16-unit grid, so its strokes land on whole pixels. */
.brand-mark {
  width: 32px;
  height: 32px;
}
.site-nav {
  display: flex;
  gap: 28px;
}
.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  text-decoration: none;
}
.site-nav a:hover {
  text-decoration: underline;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: 48px;
  padding-top: 56px;
  border-bottom: 1px solid var(--rule);
}
.hero-text {
  align-self: center;
  max-width: 30rem;
  padding-bottom: 72px;
}
.hero h1 {
  margin-bottom: 28px;
  font-size: clamp(2.75rem, 5.4vw, 4.5rem);
  line-height: 1;
  letter-spacing: -0.02em;
}
.hero-text p {
  font-size: 1.3125rem;
  line-height: 1.5;
}
.hero-text p + p {
  color: var(--steel);
}

/* The signpost: plates on a pole that stands on the hero's bottom rule. */
.signpost {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-content: start;
  row-gap: 12px;
  width: min(100%, 640px);
  justify-self: end;
  padding: 20px 0 96px;
}
.signpost::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 18px;
  margin-left: -9px;
  border-radius: 9px 9px 0 0;
  background: linear-gradient(
    90deg,
    var(--pole-shade),
    var(--pole-light) 45%,
    var(--pole-shade)
  );
}
.signpost-place {
  position: relative;
  grid-column: 1 / -1;
  justify-self: center;
  margin: 0 0 6px;
  padding: 4px 22px;
  border: 2px solid #000;
  border-radius: 4px;
  background: #fff;
  color: #000;
  font-size: clamp(1.25rem, 1.8vw, 1.625rem);
  font-weight: 600;
}
.plate {
  position: relative;
  isolation: isolate;
  margin: 0;
  padding: 10px 0;
  list-style: none;
}
.plate::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: 4px;
  background: var(--sign);
}
.plate-right {
  grid-column: 2;
  margin-left: -26px;
}
.plate-right::before {
  clip-path: polygon(
    0 0,
    calc(100% - var(--tip)) 0,
    100% 50%,
    calc(100% - var(--tip)) 100%,
    0 100%
  );
}
.plate-left {
  grid-column: 1;
  margin-right: -26px;
}
.plate-left::before {
  clip-path: polygon(var(--tip) 0, 100% 0, 100% 100%, var(--tip) 100%, 0 50%);
}
.plate a {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding: 2px 20px;
  color: #000;
  font-size: clamp(1.25rem, 2vw, 1.75rem);
  font-weight: 600;
  line-height: 1.35;
  text-decoration: none;
}
.plate-right a {
  padding-right: var(--tip);
}
.plate-left a {
  padding-left: var(--tip);
}
.plate a span {
  font-weight: 400;
}
.plate a:hover {
  text-decoration: underline;
}
.plate a:focus-visible {
  outline-color: #000;
  outline-offset: -3px;
}
.plate-note {
  position: relative;
  grid-column: 1;
  justify-self: end;
  margin: -6px -26px 0 0;
  padding: 3px 14px;
  border: 2px solid #000;
  border-radius: 4px;
  background: #fff;
  color: #000;
  font-size: 1.0625rem;
}

.app-group {
  padding-top: 56px;
}
.app-group + .app-group {
  margin-top: 104px;
  border-top: 1px solid var(--rule);
}
.app-group h2,
.about h2 {
  margin: 0 0 40px;
  font-size: 1.5rem;
}
.app-list {
  display: grid;
  gap: 64px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.app {
  display: grid;
  grid-template-columns: minmax(0, 6fr) minmax(0, 5fr);
  gap: 56px;
  align-items: center;
}
.app-art {
  grid-column: 2;
  grid-row: 1;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 12px;
}
.app-art svg {
  display: block;
  width: 100%;
  height: 100%;
}
.art-river {
  background: #dceee4;
}
.art-food {
  background: #f4e4d6;
}
.art-cards {
  background: #f4efce;
}
.art-pace {
  background: #e2eaf6;
}
.art-rain {
  background: #d7ecf1;
}
.art-heart {
  background: #f3dfe2;
}
.art-workout {
  background: #e9e3f1;
}
.app-body {
  grid-column: 1;
  grid-row: 1;
  max-width: 34rem;
}
.app-body h3 {
  margin: 0 0 12px;
  font-size: 2.25rem;
  letter-spacing: -0.015em;
}
.app-platforms {
  color: var(--steel);
}
.app-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 28px;
  margin-top: 8px;
}
.app-links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}
/* A small sign: the one action that opens the app. */
.go {
  position: relative;
  isolation: isolate;
  padding: 0 40px 0 18px;
  color: #000;
  font-weight: 600;
  text-decoration: none;
}
.go::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: 3px;
  background: var(--sign);
  clip-path: polygon(
    0 0,
    calc(100% - 22px) 0,
    100% 50%,
    calc(100% - 22px) 100%,
    0 100%
  );
}
.go:hover {
  text-decoration: underline;
}

.about {
  margin-top: 104px;
  padding-top: 56px;
  border-top: 1px solid var(--rule);
}
.about > * {
  max-width: 34rem;
}
.about h2 {
  margin-bottom: 20px;
}

.site-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0 32px;
  margin-top: 112px;
  padding: 16px 0 24px;
  border-top: 1px solid var(--rule);
  color: var(--steel);
  font-size: 1rem;
}
.site-footer p {
  margin: 0;
}
.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0 24px;
}
.site-footer a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

/* The plates swing out from the pole once, when the page opens. */
@media (prefers-reduced-motion: no-preference) {
  .plate,
  .plate-note {
    animation: plate-out 480ms cubic-bezier(0.2, 0.7, 0.2, 1) both;
  }
  .plate-right {
    --from: -28px;
    animation-delay: 120ms;
  }
  .plate-left {
    --from: 28px;
    animation-delay: 220ms;
  }
  .plate-note {
    --from: 0;
    animation-delay: 320ms;
  }
}
@keyframes plate-out {
  from {
    opacity: 0;
    transform: translateX(var(--from));
  }
}

@media (max-width: 960px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 8px;
    padding-top: 40px;
  }
  .hero-text {
    max-width: 36rem;
    padding-bottom: 32px;
  }
  .signpost {
    justify-self: start;
    width: min(100%, 520px);
  }
  .app {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 40px;
  }
}

@media (max-width: 640px) {
  :root {
    --tip: 32px;
  }
  body {
    font-size: 1.0625rem;
  }
  h1 {
    font-size: 2.25rem;
  }
  .site-header,
  .home,
  .site-footer {
    width: calc(100% - 40px);
  }
  .site-header {
    min-height: 72px;
  }
  .site-nav {
    gap: 20px;
  }
  .site-nav a[href^="https:"] {
    display: none;
  }
  .hero {
    padding-top: 24px;
  }
  .hero h1 {
    margin-bottom: 20px;
  }
  .hero-text p {
    font-size: 1.125rem;
  }
  .signpost {
    width: 100%;
    padding-bottom: 64px;
  }
  .plate a {
    gap: 10px;
    padding-inline: 12px;
    font-size: 1.125rem;
  }
  .plate-right a {
    padding-right: var(--tip);
  }
  .plate-left a {
    padding-left: var(--tip);
  }
  .plate-note {
    font-size: 0.9375rem;
  }
  .app-group {
    padding-top: 40px;
  }
  .app-group + .app-group {
    margin-top: 72px;
  }
  .app-group h2 {
    margin-bottom: 28px;
  }
  .app-links {
    column-gap: 20px;
  }
  .app-list {
    gap: 48px;
  }
  .app {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .app-art,
  .app-body {
    grid-column: 1;
    grid-row: auto;
  }
  .app-body h3 {
    font-size: 1.875rem;
  }
  .about {
    margin-top: 72px;
    padding-top: 40px;
  }
  .site-footer {
    margin-top: 72px;
  }
}

/* Too narrow for plates on both sides of the pole. */
@media (max-width: 379px) {
  .plate-right,
  .plate-left,
  .plate-note {
    grid-column: 1 / -1;
    margin-inline: 0;
  }
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #15181a;
    --ink: #eef0ec;
    --steel: #a3abaf;
    --rule: #2d3336;
    --wash: #23292c;
    --pole-shade: #596064;
    --pole-light: #b8bfc2;
  }
  /* Light text on dark looks heavier; a lower grade thins it without reflow. */
  body {
    font-variation-settings: "GRAD" -30;
  }
  .plate,
  .plate-note,
  .signpost-place,
  .go,
  .skip-link {
    font-variation-settings: "GRAD" 0;
  }
}

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