/* Layout and brand colours */
:root {
  --ink: #142b49;
  --paper: #f7faff;
  --muted: #425873;
  --line: #d1dfea;
  --accent: #91e7ff;
  --width: 1200px;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 1rem/1.55 "Helvetica Neue", Arial, sans-serif;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-underline-offset: .22em; }
a:hover { text-decoration: underline; }
:focus-visible { outline: 3px solid #2697d9; outline-offset: 4px; }
.wrap { width: min(var(--width), 90%); margin-inline: auto; }
h1, h2, h3, p { margin: 0 0 .6em; }
h1, h2, h3 { line-height: 1.04; letter-spacing: -.055em; }
h1 { font-size: clamp(2.8rem, 6.5vw, 6.5rem); }
h2 { font-size: clamp(2rem, 4.4vw, 4.3rem); }
h3 { font-size: 1.65rem; }
.band { padding-block: clamp(3rem, 6vw, 6rem); }
.lead { max-width: 55ch; font-size: clamp(1.06rem, 1.5vw, 1.3rem); }
.kicker { font: bold .76rem/1.4 monospace; text-transform: uppercase; letter-spacing: .13em; margin-bottom: 1rem; }
.skip { position: absolute; left: -100vw; }
.skip:focus { left: 1rem; top: .5rem; background: white; z-index: 3; padding: .5rem; }

.button {
  display: inline-flex;
  padding: .85rem 1.25rem;
  background: var(--accent);
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
  border-radius: .35rem;
}
.button:hover { background: #b8f1ff; }

/* Product cards, photography and directory */
.heading { justify-content: space-between; align-items: baseline; margin-bottom: 1.6rem; }
.heading h2 { margin: 0; }
.grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 1.2rem; }
.card { min-width: 0; background: white; border: 1px solid var(--line); border-radius: .75rem; overflow: hidden; }
.cover { display: block; overflow: hidden; background: #37423c; }
.cover img { width: 100%; height: auto; aspect-ratio: 2.35; object-fit: cover; }
.card-body { padding: 1.3rem; }
.card-title { display: flex; align-items: center; gap: .65rem; margin-bottom: .65rem; }
.card-title img { width: 38px; height: 38px; }
.card-title h3 { margin: 0; }
.card-title a { text-decoration: none; }
.card p { color: var(--muted); }
.card .actions { gap: 1rem; font-size: .9rem; }
.feature { background: #22312e; color: #f7f8ef; }
.feature .kicker { color: var(--accent); }
.split { display: grid; grid-template-columns: 1fr 1.35fr; gap: clamp(2rem,6vw,6rem); align-items: start; }
.feature article { border-top: 1px solid #66736c; padding: 1.3rem 0 .8rem; }
.feature article p { color: #d4ddd6; max-width: 62ch; }
.directory { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 0 2rem; }
.directory li { padding: 1rem 0; border-bottom: 1px solid var(--line); }
.directory a { font-weight: 650; }
details { margin-top: 1.5rem; border-block-start: 1px solid var(--line); padding-top: 1rem; }
summary { cursor: pointer; font-weight: bold; }
.directory small { display: block; color: var(--muted); }
.product { background: var(--ink); color: white; }
.product .split { align-items: center; grid-template-columns: 1.2fr 1fr; }
.product .visual { background: #354740; padding: 2rem; border-radius: 1rem; }
.product .visual img { height: clamp(230px,33vw,400px); width: 100%; object-fit: contain; }
.gallery { display: flex; gap: 1rem; overflow-x: auto; padding: .5rem .25rem 1rem; scroll-snap-type: x proximity; }
.gallery a { flex: 0 0 clamp(145px,20vw,225px); scroll-snap-align: start; }
.gallery img { width: 100%; height: auto; border-radius: .35rem; }
blockquote { margin: 1.2rem 0; padding-left: 1rem; border-left: 3px solid var(--line); }
.prose { max-width: 780px; padding-block: 3rem 4rem; overflow-wrap: anywhere; }
.prose h1 { font-size: clamp(2.5rem,5vw,4rem); }
.prose h2 { font-size: 1.65rem; margin-top: 1.65rem; }
.prose hr { max-width: 100%; border: 0; border-top: 1px solid var(--line); margin-left: 0; }
.prose li { margin-bottom: .55rem; }
.languages { display: flex; flex-wrap: wrap; gap: .5rem 1rem; margin-bottom: 1.6rem; }
@media (max-width: 750px) {
  .grid, .split, .product .split { grid-template-columns: 1fr; }
  .directory { grid-template-columns: 1fr; }
  .product .visual { padding: 1rem; }
}

/* Shared page shell. Short help pages fill the viewport. */
body { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }
main { flex: 1 0 auto; min-width: 0; }
.top { background: white; border-bottom: 1px solid var(--line); }
.top-inner, .primary-nav, .wordmark, .actions, .heading { display: flex; align-items: center; flex-wrap: wrap; gap: 1rem; }
.top-inner { justify-content: space-between; padding-block: 1rem; }
.wordmark { width: fit-content; gap: .5rem; font-weight: 800; font-size: 1.6rem; letter-spacing: -.07em; text-decoration: none; }
.brand-mark { width: 2.3rem; height: 2.3rem; flex: none; }
.primary-nav a, .hero .actions a { text-decoration: none; font-weight: 650; }
.primary-nav a:hover, .hero .actions a:hover { text-decoration: underline; }
.primary-nav a:last-child { background: #e3efff; color: #14478c; border-radius: 2rem; padding: .5rem 1rem; }
.site-foot { color: #e4f2ff; background: linear-gradient(110deg,#0b2949,#123f6e 72%,#175072); padding: 3rem 0; }
.foot-grid { display: grid; grid-template-columns: 1.4fr repeat(3,1fr); gap: 2rem; }
.foot-grid h2 { font-size: 1rem; letter-spacing: 0; }
.foot-grid p { margin-top: .65rem; color: #bfd9f0; }
.foot-grid a:not(.wordmark) { display: block; width: fit-content; margin: .4rem 0; }
.hero { background: linear-gradient(115deg,#e7f4ff,#f4f8ff 65%,#daf1ef); }
.hero-grid { display: grid; grid-template-columns: 0.9fr 1.2fr; align-items: center; gap: 2rem; padding-block: clamp(2rem,4vw,4rem); }
.hero h1 { font-size: clamp(4rem,7.6vw,7.8rem); line-height: .94; margin-bottom: .25em; }
.hero em { color: #185dc3; font-style: normal; }
.hero .kicker { color: #245a82; }
.hero .actions a { border-radius: 1.5rem; background: #1758a9; color: white; padding: .65rem .95rem; }
.photo-strip,.collection-photos { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: .45rem; }
.photo-strip img { height: clamp(250px,34vw,480px); width: 100%; object-fit: cover; border-radius: 1.1rem; }
.photo-strip img:nth-child(2) { transform: translateY(.8rem); }
.collection-photos { margin: 1.5rem 0 3rem; }
.collection-photos img { width: 100%; height: clamp(100px,18vw,230px); object-fit: cover; object-position: center 39%; border-radius: .8rem; }
.cover img { aspect-ratio: 1.9; object-position: center 37%; }
.card { box-shadow: 0 6px 22px #1e52750b; }
.card .actions a, .story a,.help-layout aside a { color: #144e99; }
.product { background: linear-gradient(100deg,#0d3866 20%,#0a4169c9 55%,#133a4e4a),var(--sport-photo) center 40% / cover; }
.product .visual { background: transparent; }
.feature { background: #175984; }
.feature article p { color: white; }
.stories { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.story { display: grid; grid-template-columns: 1.45fr 1fr; gap: .7rem; align-items: center; border-radius: 1rem; overflow: hidden; padding: clamp(1.1rem,2.1vw,2rem); }
.story figure { margin: 0; }
.story img { max-height: 285px; width: auto; margin: auto; border: 4px solid #203a50; border-radius: 14px; box-shadow: 0 8px 14px #263e4a30; }
.story h3 { font-size: clamp(1.4rem,2vw,2rem); }
.story.running { background: #ffebdf; }
.story.cycling { background: #dfedff; }
.story.pedometer { background: #dff4e6; }
.story a { font-weight: 650; }
.help-hub { padding-block: 2rem 4rem; }
.help-banner { border-radius: 1rem; padding: clamp(2rem,5vw,4.5rem); color: white; background: linear-gradient(90deg,#0b3b64 15%,#124475bb 65%,#165b692b),url('../images/editorial/cycling.webp') center 32% / cover; }
.help-banner h1 { margin: 0; }
.help-layout { display: grid; grid-template-columns: 1.45fr 1fr; gap: clamp(1.5rem,4vw,4rem); margin-top: 2.5rem; }
.help-layout h2 { font-size: clamp(1.6rem,3vw,2.5rem); }
.help-layout details { padding: .9rem 1rem; margin: .55rem 0; background: white; border: 1px solid var(--line); border-radius: .65rem; }
.help-layout details p { margin: .65rem 0 .2rem; }
.help-layout aside a { display: block; margin: .75rem 0; }
@media (max-width: 850px) {
  .stories { grid-template-columns: 1fr; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 680px) {
  .hero-grid, .help-layout { grid-template-columns: 1fr; }
  .photo-strip img { height: clamp(160px,44vw,285px); }
  .primary-nav { font-size: .91rem; gap: .8rem; }
  .hero .actions { gap: .45rem; }
  .story { grid-template-columns: 1.55fr 1fr; }
}
@media (max-width: 450px) {
  .foot-grid { grid-template-columns: 1fr; gap: 1.2rem; }
  .primary-nav { width: 100%; justify-content: space-between; gap: .35rem; flex-wrap: wrap; }
}

.story figcaption { margin-top: .55rem; text-align: center; font-size: .78rem; color: #385065; }

/* Home: one landscape sets the scene. Activity portraits identify the apps below. */
.outdoor-lead {
  background: linear-gradient(90deg,rgba(7,27,36,.84),rgba(8,31,44,.33) 52%,transparent 78%),
              url('../images/editorial/mountain-workout.webp') center 55% / cover;
  color: white;
}
.outdoor-lead .wrap { padding-block: clamp(3.8rem, 6vw, 6rem); }
.outdoor-lead h1 { font-size: clamp(4.5rem, 8.2vw, 8rem); line-height: .88; margin: 0 0 .23em; }
.outdoor-lead p:not(.kicker) { max-width: 30ch; font-size: 1.18rem; }
.lead-link { display: inline-block; padding: .72rem 1.1rem; border-radius: .5rem; background: #d4f373; color: #132b30; font-weight: 700; text-decoration: none; }
.shelf { padding-block: clamp(2.4rem,4.5vw,4.3rem); }
.shelf + .shelf { border-top: 1px solid var(--line); }
.shelf h2 { font-size: clamp(2rem,3.6vw,3.3rem); }
.app-tiles { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: clamp(.8rem,1.6vw,1.45rem); }
.app-tile { background: white; border: 1px solid #d6e1ea; border-radius: 1rem; overflow: hidden; display: flex; flex-direction: column; min-width: 0; }
.app-media { display: block; overflow: hidden; }
.home .app-media img { width: 100%; aspect-ratio: 1.82; object-fit: cover; object-position: 50% 35%; }
.home.compact .app-media img { aspect-ratio: 1.75; object-position: center 42%; }
.tile-info { display: flex; flex-direction: column; flex: 1; padding: clamp(1rem,1.8vw,1.65rem); }
.app-type { text-transform: uppercase; letter-spacing: .09em; font: 700 .72rem/1.5 Arial,sans-serif; color: #47647a; }
.tile-info h3 { margin-bottom: .4rem; font-size: clamp(1.8rem,3vw,2.7rem); }
.tile-info h3 a { text-decoration: none; }
.tile-info > p:not(.app-type) { color: var(--muted); }
.tile-links { display: flex; flex-wrap: wrap; gap: .5rem 1rem; padding-top: .6rem; margin-top: auto; }
.tile-links a { font-size: .9rem; color: #164d83; }
.tile-links a:first-child { font-weight: bold; }
.app-tiles.compact { grid-template-columns: repeat(4,minmax(0,1fr)); }
.compact .tile-info h3 { font-size: 1.4rem; }
.compact .tile-info { padding: 1rem; }
.workout-insights { background: #113e51; color: white; padding: clamp(3rem,6vw,6rem) 0; }
.insights-grid { display: grid; grid-template-columns: 1fr 1.4fr; gap: 3rem; }
.insights-grid .kicker { color: #ccec88; }
.insight-links { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; }
.insight-links a { color: white; text-decoration: none; border-top: 1px solid #80a0ac; padding: 1rem 0; }
.insight-links strong, .insight-links span { display: block; }
.insight-links strong { font-size: 1.15rem; }
.insight-links span { margin-top: .4rem; color: #d2e8eb; }
.insight-links a:hover strong, .tile-info a:hover { text-decoration: underline; }

/* Activity catalog: the app icon anchors every card. */
.catalog-head, .utility-lead {
  padding: clamp(2.5rem,5vw,5rem) 0;
  background: linear-gradient(110deg,#e3f3ec,#edf4fc 68%,#f3effb);
}
.catalog-head h1, .utility-lead h1 { font-size: clamp(3rem,6vw,5.8rem); }
.catalog-head h1 { margin-bottom: .22em; }
.catalog-head p { color: var(--muted); font-size: 1.15rem; }
.catalog-head nav { display: flex; flex-wrap: wrap; gap: .65rem; margin-top: 1.5rem; }
.catalog-head nav a {
  border: 1px solid #b5c9d2;
  border-radius: 2rem;
  padding: .5rem 1rem;
  background: #fff;
  text-decoration: none;
  font-weight: 650;
}
.catalog-head nav a:hover, .catalog-head nav a:focus-visible { background: #d5ebe9; }
.primary-nav a[aria-current="page"] { text-decoration: underline; text-underline-offset: .35em; }
.catalog .app-tile { padding: clamp(1rem,1.8vw,1.6rem); }
.catalog .app-media { width: fit-content; border-radius: .8rem; margin-bottom: 1rem; }
.catalog .app-media img { width: 4rem; height: 4rem; object-fit: contain; border-radius: .8rem; }
.catalog .tile-info { padding: 0; }
.catalog .running { background: linear-gradient(145deg,#e5f1ff,#fff 74%); }
.catalog .cycling { background: linear-gradient(145deg,#ffebe6,#fff 74%); }
.catalog .pedometer { background: linear-gradient(145deg,#e2f5ec,#fff 74%); }
.catalog .tile-links { align-items: center; border-top: 1px solid var(--line); padding-top: 1rem; }
.catalog .tile-links a:first-child { color: var(--ink); text-decoration: none; }
.catalog .tile-links a:first-child:hover { text-decoration: underline; }
.metric-tags { display: flex; flex-wrap: wrap; gap: .4rem; padding: 0; margin: .25rem 0 1.25rem; list-style: none; }
.metric-tags li { border: 1px solid #ccdae4; background: #ffffffc9; border-radius: 2rem; padding: .22rem .65rem; font-size: .82rem; }
.catalog.compact { grid-template-columns: repeat(auto-fit,minmax(min(100%,200px),1fr)); }
.catalog.compact .app-media img, .scale-symbol { width: 3rem; height: 3rem; border-radius: .65rem; }
.scale-symbol { display: grid; place-items: center; color: white; background: #277974; font-weight: 800; }
.secondary-apps { margin: 0 auto 3rem; color: #456078; }
.utility-notes { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 2rem; }
.product-running { background: linear-gradient(115deg,#10375e,#1e64a4); }
.product-cycling { background: linear-gradient(115deg,#482832,#9b433a); }
.product-pedometer { background: linear-gradient(115deg,#123f43,#1c7462); }

/* The same question, answer and optional full-guide pattern in every language. */
.help-banner {
  background: linear-gradient(90deg,#123e51ed,#17445bb8 50%,#183d4a24),
              url('../images/editorial/help-trail.webp') center 55% / cover;
}
.guide-collection { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); align-items: start; gap: 2rem; margin-top: 2.5rem; }
.guide-group { background: white; border: 1px solid var(--line); border-radius: 1rem; padding: clamp(1rem,2vw,1.8rem); }
.guide-group h2 { font-size: clamp(1.5rem,2.5vw,2.2rem); }
.guide-group details { margin: 0; padding: .85rem 0; scroll-margin-top: 1rem; }
.guide-group summary { line-height: 1.45; }
.guide-group details p { margin: .7rem 0 0; color: var(--muted); }
.guide-group details a { color: #17528a; font-weight: 600; }
@media(max-width: 920px) {
  .app-tiles.compact { grid-template-columns: repeat(3,minmax(0,1fr)); }
}
@media(max-width: 700px) {
  .app-tiles, .guide-collection, .insights-grid { grid-template-columns: 1fr; }
  .app-tiles.compact, .insight-links { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .outdoor-lead { background-position: 60% center; }
  .guide-collection { gap: 1rem; }
}
@media(max-width: 400px) {
  .app-tiles.compact, .insight-links, .utility-notes { grid-template-columns: 1fr; }
}

/* Interactive report preview. Native radio inputs also support keyboard navigation. */
.report-switch {
  min-width: 0;
  margin: 0;
  padding: clamp(1.2rem,3vw,2.6rem);
  border: 1px solid #c9dae3;
  border-radius: 1rem;
  background: linear-gradient(120deg,#eef7f5,#e4effc);
}
.report-switch legend { padding: 0 .5rem; color: #456074; font-weight: 600; }
.report-switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.report-switch label {
  display: inline-block;
  margin: .2rem .3rem .3rem 0;
  border: 1px solid #adc4d0;
  border-radius: 2rem;
  background: white;
  padding: .5rem 1rem;
  cursor: pointer;
}
.report-switch input:checked + label { background: #17465a; color: white; border-color: #17465a; }
.report-switch input:focus-visible + label { outline: 3px solid #2279bd; outline-offset: 3px; }
.report-panel { display: none; align-items: center; grid-template-columns: 1.2fr 1fr; gap: 1.5rem; margin-top: 1.3rem; }
#view-overview:checked ~ #panel-overview,
#view-splits:checked ~ #panel-splits,
#view-graphs:checked ~ #panel-graphs,
#view-climbs:checked ~ #panel-climbs,
#view-details:checked ~ #panel-details { display: grid; }
.report-explanation { max-width: 35ch; }
.report-explanation h3 { font-size: clamp(1.6rem,3.6vw,3.2rem); }
.report-screen { display: block; width: min(100%,185px); justify-self: center; }
.report-screen img { width: 100%; height: auto; border: 4px solid #274052; border-radius: .9rem; }
@media(max-width: 560px) {
  .report-panel { grid-template-columns: 1fr; }
  .report-switch label { padding: .45rem .65rem; }
  .report-screen { width: min(100%,165px); }
}

/* A shared navy header and a photo-backed stage for the three outdoor trackers. */
.top { color: #f6fbff; background: #101e37; border-color: #263952; position: relative; z-index: 5; }
.top .primary-nav a:last-child { background: #263e60; color: #f3f8ff; }
.top .wordmark { color: white; }
.skip:focus { z-index: 8; }
.outdoor-lead {
  overflow: hidden;
  background: linear-gradient(100deg, #101e37f5 8%, #122544eb 44%, #14385dbb),
              url('../images/editorial/mountain-workout.webp') center 52% / cover;
}
.outdoor-lead > .wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: clamp(1rem, 4vw, 4rem);
  padding-block: clamp(2.8rem, 5vw, 5rem);
}
.landing-copy { position: relative; z-index: 1; }
.landing-copy .kicker { color: #bfe78c; }
.outdoor-lead .lead-link { border-radius: 2rem; }
.tracker-stack {
  position: relative;
  width: min(100%, 500px);
  aspect-ratio: 1.34;
  justify-self: center;
  background: radial-gradient(ellipse, #80d8e24f, transparent 69%);
}
.tracker-stack img {
  position: absolute;
  width: 36%;
  height: auto;
  top: 50%;
  border: clamp(3px,.4vw,6px) solid #142136;
  border-radius: clamp(10px,1.45vw,21px);
  transform: translate(-50%,-50%) rotate(var(--angle)) scale(var(--scale));
  box-shadow: 0 17px 28px #05122466;
}
.stack-left { left: 22%; --angle: -12deg; --scale: .89; }
.stack-center { left: 50%; --angle: -2deg; --scale: 1; z-index: 2; }
.stack-right { left: 79%; --angle: 12deg; --scale: .89; }
.app-tile { border-radius: 1.2rem; box-shadow: 0 4px 18px #162c4509; }
.site-foot { background: linear-gradient(110deg,#101e37,#143652); }
.shot-viewer {
  box-sizing: border-box;
  width: min(94vw,650px);
  max-height: 94vh;
  max-height: 94dvh;
  margin: auto;
  color: #f5faff;
  background: #14233d;
  border: 1px solid #47607b;
  border-radius: 1rem;
  padding: .8rem 1rem;
}
.shot-viewer::backdrop { background: #081323de; }
.viewer-top,.viewer-nav { display: flex; align-items: center; justify-content: space-between; gap: .8rem; }
.viewer-nav { justify-content: center; }
.shot-viewer button { cursor: pointer; font: inherit; color: white; border: 1px solid #7186a0; border-radius: 2rem; background: #233d5a; min-height: 44px; min-width: 44px; padding: .45rem .85rem; }
.viewer-image { width: auto; height: auto; max-height: 65vh; max-height: 65dvh; max-width: 100%; margin: .65rem auto; object-fit: contain; }
@media (max-width: 680px) {
  .outdoor-lead > .wrap { grid-template-columns: 1fr; gap: 1.5rem; }
  .tracker-stack { width: min(85%,320px); }
}
@media (prefers-reduced-motion: no-preference) {
  @keyframes screen-arrival {
    from { opacity: 0; translate: 0 16px; }
    to { opacity: 1; translate: 0 0; }
  }
  .tracker-stack img { animation: screen-arrival .55s ease-out backwards; }
  .tracker-stack .stack-center { animation-delay: .09s; }
  .tracker-stack .stack-right { animation-delay: .16s; }
  .report-panel, .shot-viewer[open] { animation: screen-arrival .22s ease-out; }
  .app-tile,.lead-link,.install,.gallery a { transition: transform .22s ease, box-shadow .22s ease; }
  @media (hover:hover) and (pointer:fine) {
    .app-tile:hover { transform: translateY(-5px); box-shadow: 0 14px 35px #13314c1f; }
    .lead-link:hover,.install:hover,.gallery a:hover { transform: translateY(-2px); }
  }
}

/* Body metrics is a compact pair beneath the strength collection. */
.app-tiles.metric-pair { grid-template-columns: repeat(2,minmax(0,1fr)); }
.metric-pair .app-tile { display: grid; grid-template-columns: minmax(95px,34%) 1fr; }
.metric-pair.home .app-media img { height: 100%; aspect-ratio: auto; object-fit: cover; }
.report-jump { display: inline-block; color: white; margin: .65rem 0 .65rem 1rem; font-weight: 650; }
@media(max-width: 750px) {
  .app-tiles.metric-pair { grid-template-columns: 1fr; }
}
@media(max-width: 440px) {
  .report-jump { margin-left: 0; display: block; width: fit-content; }
}

.ride-intro { max-width: 60ch; color: var(--muted); margin-bottom: 1.5rem; }
#workout-report .report-screen { width: min(100%, 232px); }
