/* MJX Studio site (README, "Izgled"). Every colour is a token below; the Schooliday sky, sun and sea are the app
   icon's. The text is the phone's own system font, which has every letter of every language of the site. */

:root {
  --bg: #fbf8f4;
  --surface: #ffffff;
  --surface-2: #f3eee6;
  --ink: #1b1e3c;
  --ink-2: #4b4f6e;
  --ink-3: #6c708e;
  --line: #e6dfd4;
  --accent: #4a3ec8;
  --accent-2: #d2541f;
  --shadow-1: 0 1px 2px rgb(27 30 60 / 0.05), 0 2px 10px rgb(27 30 60 / 0.06);
  --shadow-2: 0 2px 6px rgb(27 30 60 / 0.08), 0 22px 48px rgb(27 30 60 / 0.14);

  /* Schooliday: the icon's sunset at sea. Fixed in both appearances, like the icon. */
  --sky-top: #3a57d6;
  --sky-violet: #7149c4;
  --sky-rose: #b8489c;
  --sky-ember: #ea6239;
  --sky-glow: #ffa44c;
  --sea-light: #5b40d6;
  --sea: #2c2f8e;
  --sea-deep: #1f2272;
  --sun-core: #fff7d4;
  --sun-mid: #ffd66b;
  --sun-edge: #ffa748;
  --night: #0c0e20;
  --night-top: #2c2f8e;
  --night-mid: #1a1e5c;
  --night-ground: #0b0d26;
  --moon: #fff6d8;

  /* Skypose: the app's Dawn sky, the colours of its 3×3 mesh (img/skypose/sky-dawn draws the whole of it, as the app
     does). Fixed in both appearances, like the app's icon. */
  --dawn-blue: #3e61ab;
  --dawn-violet: #6666aa;
  --dawn-mauve: #9e6b98;
  --dawn-rose: #ba6f92;
  --dawn-coral: #cf7b5e;
  --dawn-amber: #d38a56;
  --dawn-ink: #7b3d6f;
  --dusk-ground: #1b1220;

  /* MJX Studio: the ink of its sign (its yellow is --sun-mid). */
  --studio-top: #1e2146;
  --studio-ground: #111329;

  --on-sky: #ffffff;
  --on-sky-2: rgb(255 255 255 / 0.9);

  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", system-ui, "Segoe UI", Roboto, "Noto Sans", "Helvetica Neue", Arial, sans-serif;
  --radius-s: 12px;
  --radius-m: 20px;
  --radius-l: 28px;
  --wrap: 1120px;
  --gutter: clamp(16px, 4vw, 32px);
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1229;
    --surface: #171b38;
    --surface-2: #1f2449;
    --ink: #f2eff9;
    --ink-2: #c5c2dd;
    --ink-3: #a19ec0;
    --line: #2b305d;
    --accent: #aa9eff;
    --accent-2: #ff9b63;
    --dawn-ink: #ecaad4;
    --shadow-1: 0 1px 2px rgb(0 0 0 / 0.3);
    --shadow-2: 0 2px 6px rgb(0 0 0 / 0.3), 0 22px 48px rgb(0 0 0 / 0.45);
    color-scheme: dark;
  }
}

/* Base */

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 1.0625rem/1.6 var(--font);
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: var(--accent);
  text-decoration-thickness: 0.075em;
  text-underline-offset: 0.18em;
}

h1,
h2,
h3,
p,
figure {
  margin: 0;
}

h1,
h2,
h3 {
  color: var(--ink);
  text-wrap: balance;
}

h1 {
  font-size: clamp(2.5rem, 1.5rem + 4vw, 4.5rem);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -0.035em;
}

h3 {
  font-size: 1.1875rem;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.01em;
}

.section-title {
  font-size: clamp(1.75rem, 1.3rem + 1.6vw, 2.5rem);
  font-weight: 750;
  line-height: 1.1;
  letter-spacing: -0.025em;
}

.lead {
  max-width: 34em;
  font-size: clamp(1.125rem, 1rem + 0.5vw, 1.375rem);
  line-height: 1.5;
  color: var(--ink-2);
  text-wrap: pretty;
}

.eyebrow {
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-2);
}

.wrap {
  width: 100%;
  max-width: calc(var(--wrap) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.wrap.narrow {
  max-width: calc(780px + 2 * var(--gutter));
}

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

.skip-link {
  position: absolute;
  left: var(--gutter);
  top: -100px;
  z-index: 50;
  padding: 10px 16px;
  border-radius: var(--radius-s);
  background: var(--ink);
  color: var(--bg);
}

.skip-link:focus {
  top: 10px;
}

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

/* The language and the phone (head.js, site.js) */

.texts-pending body {
  visibility: hidden;
}

html[data-platform="ios"] [data-only="android"]:not(.platform-stack > *),
html[data-platform="android"] [data-only="ios"]:not(.platform-stack > *) {
  display: none !important;
}

/* Both phones' versions in one place, the hidden one still holding its room, so switching the phone moves nothing. */
.platform-stack {
  display: grid;
}

.platform-stack > * {
  grid-area: 1 / 1;
}

html[data-platform="ios"] .platform-stack > [data-only="android"],
html[data-platform="android"] .platform-stack > [data-only="ios"] {
  visibility: hidden;
}

html[data-platform-fixed] .platform-switch {
  display: none !important;
}

/* A screenshot before site.js gives it its file: an empty screen, never its description. */
img[data-shot]:not([src]) {
  visibility: hidden;
}

html[data-device="ios"] .page-home [data-store="android"],
html[data-device="android"] .page-home [data-store="ios"] {
  display: none;
}

/* Header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  padding-top: env(safe-area-inset-top, 0px);
  background: color-mix(in srgb, var(--bg) 84%, transparent);
  border-bottom: 1px solid color-mix(in srgb, var(--line) 70%, transparent);
  -webkit-backdrop-filter: saturate(1.6) blur(14px);
  backdrop-filter: saturate(1.6) blur(14px);
}

.header-row {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 60px;
}

.brand {
  margin-right: 8px;
  font-size: 1.0625rem;
  font-weight: 800;
  letter-spacing: -0.015em;
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
}

.nav-menu {
  position: relative;
}

.nav-menu summary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--ink-2);
  list-style: none;
  cursor: pointer;
  user-select: none;
}

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

.nav-menu summary:hover,
.nav-menu[open] summary {
  background: var(--surface-2);
  color: var(--ink);
}

.chevron {
  width: 12px;
  height: 12px;
  transition: transform 0.2s ease;
}

.nav-menu[open] .chevron {
  transform: rotate(180deg);
}

.nav-menu-list {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  width: max-content;
  min-width: 260px;
  max-width: calc(100vw - 2 * var(--gutter));
  padding: 8px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow-2);
}

.nav-menu-list a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  color: var(--ink);
  text-decoration: none;
}

.nav-menu-list a:hover {
  background: var(--surface-2);
}

.nav-menu-list img {
  border-radius: 22.37%;
}

.nav-menu-list a > span {
  display: grid;
  line-height: 1.35;
}

.nav-menu-list a > span > span {
  font-size: 0.875rem;
  color: var(--ink-3);
}

.language-picker {
  position: relative;
  display: inline-flex;
  align-items: center;
  margin-left: auto;
  color: var(--ink-2);
}

.language-picker > svg {
  position: absolute;
  left: 11px;
  width: 17px;
  height: 17px;
  pointer-events: none;
}

.language-picker::after {
  content: "";
  position: absolute;
  right: 13px;
  width: 7px;
  height: 7px;
  margin-top: -4px;
  border-right: 1.6px solid currentColor;
  border-bottom: 1.6px solid currentColor;
  transform: rotate(45deg);
  pointer-events: none;
}

.language-picker select {
  max-width: min(46vw, 240px);
  padding: 8px 32px 8px 34px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--ink);
  font: inherit;
  font-size: 0.9375rem;
  font-weight: 600;
  text-overflow: ellipsis;
  -webkit-appearance: none;
  appearance: none;
  cursor: pointer;
}

.language-picker[hidden] {
  display: none;
}

.language-picker select:hover {
  border-color: var(--line);
}

/* Buttons */

.button {
  padding: 10px 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--ink);
  font: inherit;
  font-size: 0.9375rem;
  font-weight: 600;
  cursor: pointer;
}

.button:hover {
  background: var(--surface);
}

/* The gap is a quarter of a badge's height: the clear space Apple and Google ask for around their badges. */
.store-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.store-button {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  min-height: 54px;
  padding: 7px 18px 8px;
  border: 1px solid rgb(255 255 255 / 0.2);
  border-radius: 14px;
  background: var(--night);
  color: #ffffff;
  line-height: 1.12;
  text-decoration: none;
}

.store-button-kicker {
  font-size: 0.75rem;
  opacity: 0.82;
}

.store-button-name {
  font-size: 1.1875rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.store-button--soon {
  background: rgb(12 14 32 / 0.42);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

/* A store's official badge (README, "Prodavnice"): the file as the store gives it, as tall as our button was, so the
   page doesn't move; both badges have the same height. */
.store-button--badge {
  min-height: 0;
  padding: 0;
  border: 0;
  border-radius: 10px;
  background: none;
}

.store-button--badge img {
  display: block;
  width: auto;
  height: 54px;
}

.platform-switch {
  display: inline-flex;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-2);
}

.platform-switch button {
  padding: 8px 18px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--ink-2);
  font: inherit;
  font-size: 0.9375rem;
  font-weight: 650;
  cursor: pointer;
}

.platform-switch button[aria-pressed="true"] {
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-1);
}

/* Home */

.home-hero {
  position: relative;
  padding-block: clamp(64px, 11vw, 140px) clamp(28px, 5vw, 56px);
  /* The lights may spill below the hero and fade there, but never widen the page. */
  overflow-x: clip;
  isolation: isolate;
}

/* Three soft lights in the sunset's colours, drifting slowly behind the title. */
.aurora {
  position: absolute;
  top: -30%;
  right: -12%;
  z-index: -1;
  width: min(80vw, 960px);
  aspect-ratio: 1;
  filter: blur(70px);
  opacity: 0.5;
  /* Fades out before the hero ends, so the lights never stop at an edge. */
  -webkit-mask-image: radial-gradient(closest-side, #000 55%, transparent 100%);
  mask-image: radial-gradient(closest-side, #000 55%, transparent 100%);
}

.aurora span {
  position: absolute;
  border-radius: 50%;
}

.aurora span:nth-child(1) {
  left: 30%;
  top: 22%;
  width: 52%;
  height: 52%;
  background: var(--sky-glow);
  animation: aurora-a 19s ease-in-out infinite alternate;
}

.aurora span:nth-child(2) {
  left: 8%;
  top: 34%;
  width: 46%;
  height: 46%;
  background: var(--sky-rose);
  animation: aurora-b 23s ease-in-out infinite alternate;
}

.aurora span:nth-child(3) {
  left: 44%;
  top: 4%;
  width: 40%;
  height: 40%;
  background: var(--sky-violet);
  animation: aurora-c 27s ease-in-out infinite alternate;
}

@keyframes aurora-a {
  to {
    transform: translate(-14%, 12%) scale(1.15);
  }
}

@keyframes aurora-b {
  to {
    transform: translate(18%, -10%) scale(0.9);
  }
}

@keyframes aurora-c {
  to {
    transform: translate(-10%, 22%) scale(1.2);
  }
}

.home-hero h1 {
  max-width: 11em;
  margin-top: 14px;
}

.home-hero .lead {
  margin-top: 22px;
}

.home-apps {
  padding-top: 16px;
}

/* The title, and at its end the chevrons that change the app (site.js shows them when there's more than one). */
.apps-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

/* Positioned, so they're above the hero's aurora, which reaches down over the title. */
.shelf-paddles {
  position: relative;
  display: flex;
  flex: none;
  gap: 10px;
}

.shelf-paddles[hidden] {
  display: none;
}

.shelf-paddle {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-1);
  cursor: pointer;
  transition: transform 0.2s ease;
}

@media (hover: hover) {
  .shelf-paddle:hover {
    transform: scale(1.06);
  }
}

.shelf-paddle svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* One app at a time, its card as wide as the page's text, as when there was one app. The row is as wide as the page and
   each card sits in a page of its own, so the next one is out of sight and the cards' shadows aren't cut at their sides.
   The cards change by themselves, by the chevrons and by a finger or a trackpad (site.js). The row's own padding gives
   the shadows and the cards' lift room, and is the section's bottom padding. */
.app-shelf {
  container-type: inline-size;
}

.app-cards {
  --edge: max(var(--gutter), (100cqi - var(--wrap)) / 2);
  display: grid;
  grid-auto-columns: 100cqi;
  grid-auto-flow: column;
  padding: 24px 0 clamp(56px, 8vw, 96px);
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.app-cards::-webkit-scrollbar {
  display: none;
}

.app-cards > * {
  margin-inline: var(--edge);
  scroll-snap-align: center;
}

/* Text and picture side by side on a wide card, one above the other on a narrow one. The whole card is the link to the
   app's page (the name's link covers it); real store buttons stay above it. */
.app-card {
  --card-sea: clamp(76px, 9vw, 112px);
  position: relative;
  display: flex;
  flex-wrap: wrap;
  min-height: 440px;
  container: app-card / inline-size;
  overflow: hidden;
  border-radius: var(--radius-l);
  color: var(--on-sky);
  box-shadow: var(--shadow-2);
  isolation: isolate;
  transition: translate 0.4s cubic-bezier(0.2, 0.7, 0.2, 1), box-shadow 0.4s ease;
}

/* Only with a pointer that hovers: a tap on a phone would leave the card lifted. */
@media (hover: hover) {
  .app-card:hover {
    translate: 0 -6px;
    box-shadow: 0 4px 10px rgb(27 30 60 / 0.1), 0 34px 64px rgb(27 30 60 / 0.2);
  }
}

.app-card-link {
  color: inherit;
  text-decoration: none;
}

.app-card-link::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 3;
}

.app-card-link:focus-visible {
  outline: none;
}

.app-card:has(.app-card-link:focus-visible) {
  outline: 3px solid var(--accent);
  outline-offset: 4px;
}

.app-card a.store-button {
  position: relative;
  z-index: 4;
}

.app-card--schooliday {
  background: linear-gradient(180deg, var(--sky-top) 0%, var(--sky-violet) 40%, var(--sky-rose) 66%, var(--sky-ember) 84%, var(--sky-glow) calc(100% - 4px), var(--sea-deep) calc(100% - 4px));
}

/* The sea of the Schooliday page along the whole card, in front of the sun; the text stays above it. */
.card-sea {
  position: absolute;
  inset: auto 0 -2px;
  z-index: -1;
  width: 100%;
  height: var(--card-sea);
}

.card-sea .sea-shore {
  fill: var(--sea-deep);
}

.app-card-art {
  position: relative;
  flex: 1 1 300px;
  min-height: 330px;
}

.scene-sun {
  position: absolute;
  right: 6%;
  top: 14%;
  z-index: -1;
  width: min(62%, 300px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle at 42% 36%, var(--sun-core), var(--sun-mid) 46%, var(--sun-edge) 82%);
  box-shadow: 0 0 90px 34px rgb(255 186 104 / 0.42);
}

/* The app's screen, rising from the bottom of the card. */
.app-card-phone {
  position: absolute;
  left: 50%;
  top: max(56px, 16%);
  width: min(240px, 70%);
  translate: -50% 0;
}

@media (hover: hover) {
  .app-card:hover .app-card-phone {
    top: max(44px, 13%);
  }
}

.app-card-phone {
  transition: top 0.5s cubic-bezier(0.2, 0.7, 0.2, 1);
}

html:not([data-device="android"]) [data-device-only="android"],
html[data-device="android"] [data-device-only="ios"] {
  display: none;
}

.app-card-body {
  display: flex;
  flex: 1 1 340px;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  max-width: 34em;
  padding: clamp(24px, 4vw, 40px) clamp(24px, 4vw, 40px) calc(var(--card-sea) + 14px);
}

.app-icon {
  width: 84px;
  height: 84px;
  border-radius: 22.37%;
  box-shadow: 0 10px 28px rgb(20 10 60 / 0.35);
}

.app-card-name {
  margin-top: 10px;
  font-size: 2.125rem;
  font-weight: 800;
  letter-spacing: -0.035em;
  color: var(--on-sky);
}

.app-card-question {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.app-card-text {
  max-width: 24em;
  color: var(--on-sky-2);
}

.app-card .store-buttons {
  margin-top: 10px;
}

/* Schooliday */

.sd-hero {
  position: relative;
  padding-top: clamp(40px, 7vw, 88px);
  overflow: hidden;
  color: var(--on-sky);
  /* The last pixels are the shore's colour: where a browser rounds the sea's edge differently, no row of sky shows. */
  background: linear-gradient(180deg, var(--sky-top) 0%, var(--sky-violet) 40%, var(--sky-rose) 64%, var(--sky-ember) 82%, var(--sky-glow) 94%, var(--sky-glow) calc(100% - 4px), var(--bg) calc(100% - 4px));
  isolation: isolate;
}

.sd-sky {
  position: absolute;
  inset: 0;
  z-index: -1;
}

.sd-sun {
  position: absolute;
  right: max(2%, calc(50% - 600px));
  bottom: clamp(80px, 9vw, 130px);
  width: clamp(220px, 30vw, 430px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle at 42% 36%, var(--sun-core), var(--sun-mid) 46%, var(--sun-edge) 82%);
  box-shadow: 0 0 150px 56px rgb(255 186 104 / 0.42);
}

.sd-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
  align-items: end;
  gap: clamp(24px, 4vw, 56px);
}

.sd-hero-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding-bottom: clamp(150px, 15vw, 220px);
}

.sd-app {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.sd-app img {
  border-radius: 22.37%;
  box-shadow: 0 6px 18px rgb(20 10 60 / 0.35);
}

.sd-hero h1 {
  margin-top: 22px;
  color: var(--on-sky);
  text-shadow: 0 2px 28px rgb(40 20 90 / 0.22);
}

.sd-hero .lead {
  margin-top: 18px;
  color: var(--on-sky-2);
}

.sd-hero .platform-switch {
  margin-top: 28px;
  border-color: rgb(255 255 255 / 0.24);
  background: rgb(255 255 255 / 0.14);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

.sd-hero .platform-switch button {
  color: var(--on-sky-2);
}

.sd-hero .platform-switch button[aria-pressed="true"] {
  background: #ffffff;
  color: #1b1e3c;
  box-shadow: 0 2px 10px rgb(20 10 60 / 0.22);
}

/* Both stores' buttons in one place (platform-stack, not the row of .store-buttons): the shown one stands where the
   other was. */
.sd-hero .store-buttons {
  display: grid;
  justify-items: start;
  margin-top: 16px;
}

.sd-requirements {
  margin-top: 12px;
  font-size: 0.9375rem;
  color: var(--on-sky-2);
}

.sd-hero-phone {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: center;
  /* Room for the phone's shadow, which the hero would otherwise cut off at its bottom. */
  padding-bottom: clamp(56px, 7vw, 96px);
}

/* The sea reaches a little below the sky's box, so no row of the sky ever shows under it. */
.sd-sea {
  position: absolute;
  inset: auto 0 -2px;
  z-index: 1;
  width: 100%;
  height: clamp(120px, 14vw, 200px);
}

.sea-far {
  fill: var(--sea-light);
}

.sea-near {
  fill: var(--sea);
}

.sea-shore {
  fill: var(--bg);
}

.phone {
  width: min(310px, 74vw);
  padding: 9px;
  border-radius: 52px;
  background: var(--night);
  box-shadow: inset 0 0 0 1px rgb(255 255 255 / 0.1), 0 30px 60px rgb(12 10 45 / 0.38), 0 10px 22px rgb(12 10 45 / 0.25);
}

/* One shape for both phones, so switching between them never changes a size: the iPhone's slightly shorter screen
   fills it by losing 1.6% at each side. It also keeps its shape before its file arrives. */
.phone img {
  width: 100%;
  aspect-ratio: 560 / 1257;
  border-radius: 43px;
  object-fit: cover;
}


/* The six countries: each flag, drawn in the page (simplified at this size), with its name under it. */
.countries {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 20px 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.countries li {
  display: grid;
  align-content: start;
  justify-items: center;
  gap: 12px;
  font-size: 0.875rem;
  font-weight: 650;
  line-height: 1.3;
  text-align: center;
  color: var(--ink);
}

.flag {
  width: min(64px, 100%);
  height: auto;
  aspect-ratio: 3 / 2;
  border-radius: 6px;
  box-shadow: 0 8px 18px rgb(27 30 60 / 0.16), 0 1px 3px rgb(27 30 60 / 0.12);
  transition: translate 0.3s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.countries li:hover .flag {
  translate: 0 -4px;
}

@media (max-width: 600px) {
  .countries {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* A hairline round the flag, so white stripes keep their edge. */
.flag-edge {
  fill: none;
  stroke: color-mix(in srgb, var(--ink) 14%, transparent);
  stroke-width: 0.4;
}

/* The app's screens: the title, the countries, and a carousel with one screen in the middle and the others beside it. */

.sd-screens {
  padding-top: clamp(56px, 8vw, 104px);
  overflow-x: clip;
}

.carousel {
  --slide: clamp(230px, 24vw, 300px);
}

/* Chevrons at the page's left and right edges, level with the middle screen's middle (the track has 30 px above the
   screens and 64 px below): they bring the screen before and after. */
.carousel-arrow {
  position: absolute;
  top: calc(50% - 17px);
  z-index: 2;
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-2);
  cursor: pointer;
  translate: 0 -50%;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.carousel-arrow--prev {
  left: var(--gutter);
}

.carousel-arrow--next {
  right: var(--gutter);
}

.carousel-arrow:hover {
  transform: scale(1.06);
}

.carousel-arrow svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* The stage: a soft sunset glow behind the middle screen, which stays in place while the screens slide. */
.carousel-stage {
  position: relative;
  isolation: isolate;
}

.carousel-stage::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: -1;
  width: min(620px, 110vw);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle, color-mix(in srgb, var(--sky-glow) 42%, transparent), color-mix(in srgb, var(--sky-rose) 14%, transparent) 42%, transparent 68%);
  translate: -50% -50%;
  pointer-events: none;
}

/* The track runs from one edge of the screen to the other, fading out at both, and the first and last screens can
   stand in its middle. */
.carousel-track {
  position: relative;
  display: grid;
  grid-auto-columns: var(--slide);
  grid-auto-flow: column;
  gap: clamp(10px, 3vw, 44px);
  margin: 0;
  padding: 30px calc(50% - var(--slide) / 2) 64px;
  overflow-x: auto;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  list-style: none;
}

.carousel-track::-webkit-scrollbar {
  display: none;
}

.carousel-slide {
  display: grid;
  justify-items: center;
  scroll-snap-align: center;
  scroll-snap-stop: always;
  cursor: pointer;
}

.carousel-slide.is-active {
  cursor: default;
}

.carousel-slide .phone {
  width: 100%;
  box-shadow: inset 0 0 0 1px rgb(255 255 255 / 0.1), 0 18px 34px rgb(12 10 45 / 0.28), 0 6px 14px rgb(12 10 45 / 0.18);
  opacity: 0.5;
  transform: scale(0.84);
  transition: transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1), opacity 0.6s ease;
}

.carousel-slide.is-active .phone {
  opacity: 1;
  transform: none;
}

/* The captions, above the screens, share one place: the tallest one sets its height, so the screens never move. */
.carousel-captions {
  display: grid;
  max-width: calc(36em + 2 * var(--gutter));
  text-align: center;
}

.carousel-caption {
  display: grid;
  grid-area: 1 / 1;
  align-content: start;
  gap: 10px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity 0.35s ease, transform 0.35s ease, visibility 0s 0.35s;
}

.carousel-caption.is-active {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition: opacity 0.45s ease 0.1s, transform 0.45s ease 0.1s;
}

/* „Sve na jednom mestu” and, on a line of its own, the screen's name in the sunset's colours: the first part stays in
   place from one screen to the next. */
.carousel-title {
  font-size: clamp(1.75rem, 1.2rem + 2.2vw, 2.5rem);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.03em;
}

.carousel-title-name {
  display: block;
  width: fit-content;
  margin-inline: auto;
  background: linear-gradient(90deg, var(--sky-rose), var(--sky-ember));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.carousel-caption p {
  font-size: 1.125rem;
  color: var(--ink-2);
}

/* Phones: a finger swipes, and more of the screens beside shows, so it's clear there are more. */
@media (max-width: 560px) {
  .carousel {
    --slide: 60vw;
  }

  .carousel-track {
    gap: 6px;
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
    mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
  }

  .carousel-slide .phone {
    transform: scale(0.88);
  }

  .carousel-arrow {
    width: 44px;
    height: 44px;
  }
}

.sd-features {
  padding-block: clamp(64px, 9vw, 112px);
}

/* The countries' card across the whole row, the four others under it: four in a row, two, or one. */
.features {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-top: 40px;
}

@media (max-width: 1000px) {
  .features {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .features {
    grid-template-columns: minmax(0, 1fr);
  }
}

.feature {
  display: grid;
  align-content: start;
  gap: 10px;
  padding: 26px 24px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-m);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature:hover {
  translate: 0 -4px;
  box-shadow: var(--shadow-2);
}

/* The countries: text on one side and the six flags on the other, on a touch of the sunset; one above the other when
   narrower. */
.feature--countries {
  grid-column: 1 / -1;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 2fr);
  align-items: center;
  gap: 24px 48px;
  padding: 30px 34px;
  background: linear-gradient(115deg, color-mix(in srgb, var(--sky-glow) 14%, var(--surface)), var(--surface) 58%);
}

.feature--countries:hover {
  translate: none;
  box-shadow: none;
}

.feature--countries h3 {
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.feature--countries p {
  margin-top: 8px;
}

@media (max-width: 1000px) {
  .feature--countries {
    grid-template-columns: minmax(0, 1fr);
  }
}

.feature > svg {
  width: 52px;
  height: 52px;
  margin-bottom: 6px;
  padding: 13px;
  border-radius: 16px;
  background: linear-gradient(140deg, var(--tint), color-mix(in srgb, var(--tint) 55%, var(--sky-glow)));
  box-shadow: 0 8px 18px color-mix(in srgb, var(--tint) 35%, transparent);
  fill: none;
  stroke: #ffffff;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.feature p {
  color: var(--ink-2);
}

/* Support: its own page, like the privacy policy, with the questions under the sky. */
.support {
  position: relative;
  z-index: 2;
  padding-block: clamp(8px, 2vw, 20px) clamp(64px, 9vw, 112px);
}

.support .faq {
  margin-top: 0;
}

.faq {
  margin-top: 24px;
  border-top: 1px solid var(--line);
}

.faq details {
  border-bottom: 1px solid var(--line);
}

.faq summary {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 4px;
  font-size: 1.0625rem;
  font-weight: 650;
  line-height: 1.4;
  list-style: none;
  cursor: pointer;
}

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

.faq summary::after {
  content: "";
  flex: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background:
    linear-gradient(var(--ink-2), var(--ink-2)) center / 10px 1.7px no-repeat,
    linear-gradient(var(--ink-2), var(--ink-2)) center / 1.7px 10px no-repeat,
    var(--surface-2);
}

.faq details[open] summary::after {
  background:
    linear-gradient(var(--ink-2), var(--ink-2)) center / 10px 1.7px no-repeat,
    var(--surface-2);
}

.faq .answer {
  max-width: 64ch;
  padding: 0 4px 20px;
  color: var(--ink-2);
}

/* Privacy policy: the Schooliday sky above it, the text in cards and sections below. */

.sd-hero--doc {
  padding-bottom: clamp(128px, 15vw, 210px);
}

.sd-hero--doc .sd-sun {
  right: max(-6%, calc(50% - 640px));
  bottom: clamp(36px, 5vw, 80px);
  width: clamp(170px, 22vw, 320px);
}

.doc-hero-text {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.doc-hero-text .sd-app a {
  color: inherit;
  text-decoration: none;
}

.sd-hero--doc h1 {
  margin-top: 18px;
  font-size: clamp(2.25rem, 1.6rem + 2.6vw, 3.5rem);
}

/* The subtitle of the support and privacy pages: one style, with the room of two lines on both, so going from one page
   to the other moves nothing. */
.doc-lead {
  max-width: 34em;
  min-height: 3em;
  min-height: 2lh;
  margin-top: 14px;
  font-size: clamp(1.0625rem, 1rem + 0.4vw, 1.25rem);
  line-height: 1.5;
  color: var(--on-sky-2);
}

.sd-hero--doc .platform-switch {
  margin-top: 14px;
}

/* Phones: the privacy policy's title takes two lines in most languages, so both pages keep room for two, with the title
   at the bottom of it, and on the narrowest phones three lines for the subtitle. */
@media (max-width: 520px) {
  .sd-hero--doc h1 {
    display: flex;
    align-items: flex-end;
    min-height: 2.04em;
    min-height: 2lh;
  }
}

@media (max-width: 359px) {
  .doc-lead {
    min-height: 4.5em;
    min-height: 3lh;
  }
}

.doc {
  position: relative;
  z-index: 2;
  padding-block: clamp(8px, 2vw, 20px) clamp(64px, 9vw, 112px);
}

/* In the policy the other phone's text is left out, not kept as an empty room: it can be much longer (Google Play's
   purchase library), and an App Store reviewer would see a gap. Only the text below the switch moves. */
.doc .platform-stack {
  display: block;
}

html[data-platform="ios"] .doc .platform-stack > [data-only="android"],
html[data-platform="android"] .doc .platform-stack > [data-only="ios"] {
  display: none;
}

.doc h2 {
  margin-top: 44px;
  padding-top: 26px;
  border-top: 1px solid var(--line);
  font-size: 1.375rem;
  letter-spacing: -0.015em;
  scroll-margin-top: 84px;
}

.doc p,
.doc ul,
.doc ol {
  max-width: 68ch;
  margin: 12px 0 0;
  color: var(--ink-2);
}

.doc ul,
.doc ol {
  padding-left: 1.25em;
}

.doc li + li {
  margin-top: 6px;
}

.doc ul li::marker {
  color: var(--sky-rose);
}

.doc > h2:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

/* Who else gets what: one small card per party. */
.doc-parties {
  display: grid;
  gap: 12px;
  max-width: 68ch;
  margin: 16px 0 0;
}

.doc-parties > div {
  padding: 16px 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius-s);
  background: var(--surface);
}

.doc-parties dt {
  font-weight: 700;
  color: var(--ink);
}

.doc-parties dd {
  margin: 4px 0 0;
  color: var(--ink-2);
}

/* Footer */

/* The footer starts a pixel early, under the section above it, so no thin seam of the page shows between them where a
   browser rounds their edge differently. */
.site-footer {
  position: relative;
  margin-top: -1px;
  padding-block: 29px calc(28px + env(safe-area-inset-bottom, 0px));
  background: var(--night-ground);
  font-size: 0.9375rem;
  color: rgb(255 255 255 / 0.6);
}

.footer-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 24px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
}

.footer-links a {
  color: rgb(255 255 255 / 0.82);
  text-decoration: none;
}

.footer-links a:hover {
  color: #ffffff;
  text-decoration: underline;
}

/* A card too narrow for text and picture side by side (340 + 300 px): the picture goes under the text, with the sea. */

@container app-card (width < 640px) {
  .app-card-body {
    padding-bottom: 8px;
  }

  .app-card-phone {
    width: min(230px, 64%);
  }

  .scene-sun {
    right: 4%;
    top: 4%;
    width: min(56%, 230px);
  }
}

/* Phones */

@media (max-width: 520px) {
  /* The language is a globe button: the menu still shows every language's name. */
  .language-picker::after {
    display: none;
  }

  .language-picker > svg {
    left: 50%;
    width: 20px;
    height: 20px;
    transform: translateX(-50%);
  }

  .language-picker select {
    width: 42px;
    height: 40px;
    padding: 0;
    color: transparent;
  }

  .nav-menu summary {
    padding-inline: 10px;
  }

  /* The menu spans the screen under the header, so it never runs off its side. */
  .nav-menu-list {
    position: fixed;
    top: calc(env(safe-area-inset-top, 0px) + 64px);
    left: var(--gutter);
    right: var(--gutter);
    width: auto;
    min-width: 0;
  }
}

@media (max-width: 860px) {
  .sd-hero-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  /* One column: the text above the phone, everything in it centred. */
  .sd-hero-text {
    align-items: center;
    padding-bottom: 8px;
    text-align: center;
  }

  .sd-hero .store-buttons {
    justify-items: center;
  }

  /* One column: the sun sets behind the phone, below the text. */
  .sd-sun {
    right: -14%;
    bottom: 14%;
    width: min(78vw, 560px);
  }
}

@media (max-width: 640px) {
  .brand {
    margin-right: 0;
  }

}

/* Skypose: its pages under the app's Dawn sky, the home card and the dusk of its contact. The sky is the app's own mesh
   (img/skypose/sky-dawn and its dimmed sky-dusk, drawn by the app's code), stretched to its box as the app stretches it
   to any screen, and drifting slowly, as it does there. */

.sp-sky {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
}

.sp-sky img {
  width: 100%;
  height: 100%;
  object-fit: fill;
  transform-origin: 30% 20%;
  animation: sp-sky-drift 28s ease-in-out infinite alternate;
}

@keyframes sp-sky-drift {
  to {
    transform: scale(1.14) translate(-2%, 1.5%);
  }
}

/* The app's screens are as tall as an iPhone's: the frame takes their shape. Their height is even (560 × 1216, not
   1217): macOS writes an AVIF of an odd height that Chrome can't read (README, "Skypose"). */
.phone--iphone img {
  aspect-ratio: 560 / 1216;
}

.sp-hero {
  position: relative;
  padding-top: clamp(40px, 7vw, 88px);
  overflow: hidden;
  color: var(--on-sky);
  isolation: isolate;
}

/* The page meets the sky in a long arc, like the horizon at dawn; the phone stands in front of it. */
.sp-horizon {
  position: absolute;
  inset: auto 0 -2px;
  z-index: 1;
  width: 100%;
  height: clamp(48px, 7vw, 112px);
}

.sp-horizon path {
  fill: var(--bg);
}

.sp-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  align-items: end;
  gap: clamp(24px, 4vw, 56px);
}

.sp-hero-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding-bottom: clamp(120px, 13vw, 200px);
}

.sp-app {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.sp-app img {
  border-radius: 22.37%;
  box-shadow: 0 6px 18px rgb(30 18 60 / 0.35);
}

.sp-app a {
  color: inherit;
  text-decoration: none;
}

.sp-hero h1 {
  margin-top: 22px;
  color: var(--on-sky);
  text-shadow: 0 2px 28px rgb(40 20 80 / 0.25);
}

.sp-hero .lead {
  margin-top: 18px;
  color: var(--on-sky);
  text-shadow: 0 1px 14px rgb(40 20 80 / 0.25);
}

.sp-hero .store-buttons {
  margin-top: 28px;
}

/* The iPhone | Android switch on the sky, on glass like the chips; the chosen phone white. Both stores' buttons stand
   in one place (platform-stack), so the shown one is where the other was. */
.sp-hero .platform-switch {
  margin-top: 28px;
  border-color: rgb(255 255 255 / 0.3);
  background: rgb(255 255 255 / 0.16);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

.sp-hero .platform-switch button {
  color: var(--on-sky);
}

.sp-hero .platform-switch button[aria-pressed="true"] {
  background: #ffffff;
  color: #1b1e3c;
  box-shadow: 0 2px 10px rgb(40 20 80 / 0.22);
}

.sp-hero .platform-switch + .store-buttons {
  margin-top: 16px;
}

.sp-hero .store-buttons.platform-stack {
  display: grid;
  justify-items: start;
}

.sp-hero--doc .platform-switch {
  margin-top: 16px;
}

.sp-requirements {
  margin-top: 12px;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--on-sky);
  text-shadow: 0 1px 10px rgb(40 20 80 / 0.35);
}

.sp-hero-phone {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: center;
  padding-bottom: clamp(40px, 5vw, 72px);
}

/* Support, privacy, terms and the guide: a lower sky, its title and subtitle. */
.sp-hero--doc {
  padding-bottom: clamp(104px, 13vw, 176px);
}

.sp-hero--doc h1 {
  margin-top: 18px;
  font-size: clamp(2.25rem, 1.6rem + 2.6vw, 3.5rem);
}

.sp-hero--doc .doc-lead {
  color: var(--on-sky);
}

.eyebrow--dawn {
  color: var(--dawn-ink);
}

.sp-text-link {
  display: inline-flex;
  gap: 6px;
  margin-top: 18px;
  font-weight: 700;
  color: var(--accent);
  text-decoration: none;
}

.sp-text-link::after {
  content: "→";
  transition: translate 0.25s ease;
}

.sp-text-link:hover::after,
.sp-teaser:hover .sp-text-link::after {
  translate: 4px 0;
}

/* The guide table: rows and hairlines, without a box around it. */
.sp-table-wrap {
  max-width: 100%;
  margin-top: 28px;
  overflow-x: auto;
}

.sp-table {
  width: 100%;
  min-width: 520px;
  border-collapse: collapse;
  font-size: 1rem;
}

.sp-table th,
.sp-table td {
  padding: 14px 20px 14px 0;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.sp-table tbody tr:last-child > * {
  border-bottom: 0;
}

.sp-table thead th {
  padding-top: 0;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.sp-table tbody th {
  font-weight: 600;
  color: var(--ink);
}

.sp-table td {
  color: var(--ink-2);
}

.doc .sp-table-wrap {
  max-width: 68ch;
}

/* The guide: who wrote it and when, under its subtitle; its questions as small headings. */
.sp-byline {
  margin-top: 4px;
  font-size: 0.9375rem;
  color: var(--on-sky);
  opacity: 0.9;
}

.doc h3 {
  margin-top: 26px;
  font-size: 1.125rem;
}

.sp-guide-shots {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 220px));
  gap: 24px;
  max-width: 68ch;
  margin-top: 24px;
}

.sp-guide-shots figure {
  margin: 0;
}

.sp-guide-shots .phone {
  width: 100%;
}

/* The app's screens: the carousel of the Schooliday page, under a dawn glow, with each screen's name in the sky's
   colours. */
.sp-screens {
  padding-top: clamp(40px, 6vw, 80px);
  overflow-x: clip;
}

.page-skypose .carousel-stage::before {
  background: radial-gradient(circle, color-mix(in srgb, var(--dawn-amber) 34%, transparent), color-mix(in srgb, var(--dawn-blue) 16%, transparent) 42%, transparent 68%);
}

.page-skypose .carousel-title-lead {
  display: block;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dawn-ink);
}

.page-skypose .carousel-title-name {
  margin-top: 8px;
  background-image: linear-gradient(90deg, var(--dawn-blue), var(--dawn-rose) 55%, var(--dawn-amber));
}

/* The landing page after its screens: the run, before and after, the photo day, privacy at dusk, the price and the
   guide (owner, 17. 11. 2026: no cards or tables, a design that flows like the app). Each part is a picture and a few
   words: the photos, the app's sky and its glass. */

.sp-title {
  font-size: clamp(2.25rem, 1.35rem + 3.3vw, 3.75rem);
  font-weight: 800;
  line-height: 1.04;
  letter-spacing: -0.035em;
  color: var(--ink);
  text-wrap: balance;
}

.sp-lead {
  max-width: 32em;
  margin-top: 18px;
  font-size: clamp(1.125rem, 1rem + 0.45vw, 1.375rem);
  line-height: 1.5;
  color: var(--ink-2);
  text-wrap: pretty;
}

/* Glass, as on the app's controls: the sky shows through it, blurred. Light in both appearances, like the sky. */
.sp-glass {
  border: 1px solid rgb(255 255 255 / 0.55);
  background: rgb(255 255 255 / 0.58);
  -webkit-backdrop-filter: blur(22px) saturate(1.7);
  backdrop-filter: blur(22px) saturate(1.7);
  color: #1b1e3c;
  box-shadow: 0 18px 40px -18px rgb(30 18 60 / 0.45);
}

/* Four angles, one run: the four photos of one date. Each angle's name lights up in turn, as the app goes from one to
   the next, and the photos come in one after another as the page scrolls (the motion part, below). */
.sp-run {
  padding-top: clamp(96px, 13vw, 176px);
}

.sp-run-text {
  display: grid;
  justify-items: center;
  text-align: center;
}

.sp-run-angles {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(10px, 1.6vw, 22px);
  margin: clamp(40px, 6vw, 72px) 0 0;
  padding: 0;
  list-style: none;
}

.sp-angle-tile {
  position: relative;
  overflow: hidden;
  border-radius: clamp(18px, 2.4vw, 30px);
  box-shadow: 0 30px 60px -28px rgb(40 24 70 / 0.55);
  isolation: isolate;
}

.sp-angle-tile img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

.sp-angle-name {
  position: absolute;
  bottom: clamp(10px, 1.4vw, 16px);
  left: 50%;
  padding: 6px 14px;
  border: 1px solid rgb(255 255 255 / 0.28);
  border-radius: 999px;
  background: rgb(24 18 40 / 0.34);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  backdrop-filter: blur(14px) saturate(1.4);
  color: #ffffff;
  font-size: clamp(0.8125rem, 0.75rem + 0.2vw, 0.9375rem);
  font-weight: 650;
  white-space: nowrap;
  translate: -50% 0;
  animation: sp-turn 6s ease-in-out infinite;
}

.sp-angle-tile:nth-child(2) .sp-angle-name {
  animation-delay: 1.5s;
}

.sp-angle-tile:nth-child(3) .sp-angle-name {
  animation-delay: 3s;
}

.sp-angle-tile:nth-child(4) .sp-angle-name {
  animation-delay: 4.5s;
}

@keyframes sp-turn {
  0%,
  21% {
    border-color: #ffffff;
    background: #ffffff;
    color: #1b1e3c;
  }

  27%,
  100% {
    border-color: rgb(255 255 255 / 0.28);
    background: rgb(24 18 40 / 0.34);
    color: #ffffff;
  }
}

/* Before and after, with the owner's sample photos, as Skypose's Before & After shows them: the line follows a finger or
   the pointer, the arrow keys move it, and it shows once how it moves when it first comes into view (site.js). */
.sp-change {
  padding-top: clamp(96px, 13vw, 176px);
}

.sp-change-grid {
  display: grid;
  grid-template-columns: minmax(0, 460px) minmax(0, 1fr);
  align-items: center;
  gap: clamp(36px, 7vw, 112px);
}

.sp-compare {
  margin: 0;
}

.sp-compare-stage {
  --split: 50%;
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border-radius: clamp(24px, 3vw, 36px);
  background: #2a2730;
  box-shadow: 0 50px 90px -40px rgb(40 24 70 / 0.6);
  cursor: ew-resize;
  touch-action: pan-y;
  -webkit-user-select: none;
  user-select: none;
  isolation: isolate;
}

.sp-compare-stage picture {
  position: absolute;
  inset: 0;
}

.sp-compare-stage img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
  -webkit-user-drag: none;
}

.sp-compare-before {
  clip-path: inset(0 calc(100% - var(--split)) 0 0);
}

.sp-compare-line {
  position: absolute;
  inset: 0 auto 0 var(--split);
  width: 2px;
  background: #ffffff;
  box-shadow: 0 0 14px rgb(0 0 0 / 0.3);
  translate: -1px 0;
  pointer-events: none;
}

.sp-compare-knob {
  position: absolute;
  top: 50%;
  left: 50%;
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border: 1px solid rgb(255 255 255 / 0.6);
  border-radius: 50%;
  background: rgb(255 255 255 / 0.24);
  -webkit-backdrop-filter: blur(16px) saturate(1.5);
  backdrop-filter: blur(16px) saturate(1.5);
  box-shadow: 0 10px 26px rgb(0 0 0 / 0.28);
  translate: -50% -50%;
}

.sp-compare-knob svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: #ffffff;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.sp-compare-tag {
  position: absolute;
  bottom: 16px;
  padding: 6px 14px;
  border: 1px solid rgb(255 255 255 / 0.28);
  border-radius: 999px;
  background: rgb(24 18 40 / 0.34);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  color: #ffffff;
  font-size: 0.875rem;
  font-weight: 650;
  pointer-events: none;
}

.sp-compare-tag--before {
  left: 16px;
}

.sp-compare-tag--after {
  right: 16px;
}

/* The arrow keys move the line through this slider, there for them and for screen readers only. */
.sp-compare-range {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  pointer-events: none;
}

.sp-compare-stage:has(.sp-compare-range:focus-visible) .sp-compare-knob {
  outline: 3px solid #ffffff;
  outline-offset: 4px;
}


/* The photo day: the reminder and the Photo Day widget, as glass on the sky, in the app's own words. */
.sp-day {
  padding-block: clamp(96px, 13vw, 176px);
}

.sp-day-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  align-items: center;
  gap: clamp(36px, 7vw, 112px);
}

.sp-day-scene {
  position: relative;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  align-items: end;
  justify-items: start;
  gap: 24px;
  min-height: clamp(380px, 38vw, 470px);
  padding: clamp(18px, 2.6vw, 30px);
  overflow: hidden;
  border-radius: clamp(28px, 3.4vw, 40px);
  box-shadow: 0 50px 90px -40px rgb(40 24 70 / 0.55);
  isolation: isolate;
}

.sp-note {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: start;
  gap: 12px;
  justify-self: stretch;
  max-width: 420px;
  padding: 14px 16px;
  border-radius: 24px;
}

.sp-note img {
  border-radius: 22.37%;
}

.sp-note p {
  display: grid;
  line-height: 1.3;
}

.sp-note-app {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  opacity: 0.6;
}

.sp-note strong {
  margin-top: 3px;
  font-size: 1rem;
}

.sp-note p span:last-child {
  font-size: 0.9375rem;
  opacity: 0.85;
}

.sp-note-time {
  font-size: 0.8125rem;
  opacity: 0.55;
}

.sp-widgets {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 190px));
  gap: clamp(12px, 1.6vw, 18px);
}

.sp-widget {
  display: flex;
  flex-direction: column;
  aspect-ratio: 1;
  padding: clamp(12px, 1.2vw, 16px);
  border-radius: clamp(22px, 2.4vw, 28px);
  container-type: inline-size;
}

.sp-widget p {
  line-height: 1.2;
}

.sp-widget-title {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: clamp(0.6875rem, 7.4cqi, 0.8125rem);
  font-weight: 700;
  color: #7b3d6f;
}

.sp-widget-title svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.sp-widget-number {
  margin-top: 8px;
  font-size: clamp(1.75rem, 24cqi, 2.75rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1;
}

/* Measure's number: the weight, a little smaller than Photo Day's count, as in the app. */
.sp-widget-value {
  margin-top: 8px;
  font-size: clamp(1.25rem, 16cqi, 1.875rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.05;
  white-space: nowrap;
}

.sp-widget-unit {
  margin-top: 2px;
  font-size: clamp(0.625rem, 6.8cqi, 0.8125rem);
  font-weight: 600;
  opacity: 0.7;
}

.sp-widget-weeks {
  display: flex;
  gap: 5px;
  margin-top: auto;
}

.sp-widget-weeks i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: rgb(27 30 60 / 0.16);
}

.sp-widget-weeks i.on {
  background: linear-gradient(140deg, #6666aa, #cf7b5e);
}

/* Measure's line: the weight over time, its newest point marked. */
.sp-widget-line {
  display: block;
  width: 100%;
  height: auto;
  margin-top: auto;
  overflow: visible;
}

.sp-widget-line polyline {
  fill: none;
  stroke: #1b1e3c;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.sp-widget-line circle {
  fill: #1b1e3c;
}

.sp-widget-run {
  margin-top: 6px;
  font-size: clamp(0.625rem, 6.4cqi, 0.75rem);
  font-weight: 650;
  opacity: 0.7;
}

/* Privacy at dusk: the same sky dimmed, as the app dims it at night, between two soft edges of the page. The heading
   stays in view beside the promises while they go by, each one lighting up as it reaches the middle of the screen
   (clip, not hidden, so the heading can stick). */
.sp-private {
  position: relative;
  padding-block: clamp(140px, 17vw, 230px);
  overflow: clip;
  background: var(--dusk-ground);
  color: var(--on-sky);
  isolation: isolate;
}

.sp-private::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, rgb(27 18 32 / 0.2), rgb(27 18 32 / 0.62));
}

.sp-edge {
  position: absolute;
  left: 0;
  z-index: 1;
  width: 100%;
  height: clamp(36px, 5vw, 72px);
}

.sp-edge path {
  fill: var(--bg);
}

.sp-edge--top {
  top: -1px;
}

.sp-edge--bottom {
  bottom: -1px;
  transform: scaleY(-1);
}

.sp-private-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  align-items: start;
  gap: clamp(40px, 7vw, 120px);
}

.sp-private-head {
  position: sticky;
  top: clamp(100px, 22vh, 220px);
  display: grid;
  justify-items: start;
}

.sp-private .sp-title {
  color: #ffffff;
}

.sp-private .sp-lead {
  color: rgb(255 255 255 / 0.8);
}

.sp-private-mark {
  width: 64px;
  height: 64px;
  margin-bottom: 24px;
  padding: 16px;
  border: 1px solid rgb(255 255 255 / 0.28);
  border-radius: 50%;
  background: rgb(255 255 255 / 0.12);
  fill: none;
  stroke: #ffffff;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.sp-private-list {
  display: grid;
  gap: clamp(44px, 8vh, 80px);
  margin: 0;
  padding: clamp(8px, 4vh, 48px) 0 0;
  list-style: none;
}

.sp-private-list h3 {
  font-size: clamp(1.75rem, 1.25rem + 1.8vw, 2.625rem);
  font-weight: 750;
  line-height: 1.08;
  letter-spacing: -0.03em;
  color: #ffffff;
}

.sp-private-list p {
  max-width: 30em;
  margin-top: 12px;
  font-size: 1.0625rem;
  color: rgb(255 255 255 / 0.7);
}

.sp-private-more {
  margin-top: 26px;
}

.sp-text-link--light {
  color: #ffffff;
}

/* The plans: the two side by side in one piece of glass, Yearly chosen, as on the app's plan page, without prices (the
   App Store shows each country's; owner, 18. 11. 2026); a soft dawn
   light moves slowly behind it. */
.sp-start {
  position: relative;
  padding-block: clamp(96px, 13vw, 176px) clamp(56px, 8vw, 104px);
  overflow: hidden;
  isolation: isolate;
}

.sp-start::before,
.sp-guide-end::before {
  content: "";
  position: absolute;
  top: 30%;
  left: 50%;
  z-index: -1;
  width: min(940px, 130vw);
  height: 460px;
  background:
    radial-gradient(closest-side at 36% 50%, color-mix(in srgb, var(--dawn-rose) 34%, transparent), transparent),
    radial-gradient(closest-side at 64% 50%, color-mix(in srgb, var(--dawn-blue) 30%, transparent), transparent);
  translate: -50% 0;
  animation: sp-glow 16s ease-in-out infinite alternate;
}

@keyframes sp-glow {
  to {
    transform: translateX(5%) scale(1.08);
  }
}

.sp-start-inner {
  display: grid;
  justify-items: center;
  text-align: center;
}

.sp-start .sp-lead {
  margin-inline: auto;
}

.sp-plans {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  width: min(100%, 540px);
  margin-top: 40px;
  padding: 6px;
  border: 1px solid color-mix(in srgb, var(--line) 80%, transparent);
  border-radius: 30px;
  background: color-mix(in srgb, var(--surface) 55%, transparent);
  -webkit-backdrop-filter: blur(20px) saturate(1.5);
  backdrop-filter: blur(20px) saturate(1.5);
  box-shadow: 0 30px 70px -36px rgb(40 24 70 / 0.5);
}

.sp-plan {
  display: grid;
  justify-items: center;
  gap: 4px;
  padding: 22px 12px;
  border-radius: 24px;
}

.sp-plan--chosen {
  background: var(--surface);
  box-shadow: 0 2px 6px rgb(27 30 60 / 0.06), 0 12px 26px -12px rgb(27 30 60 / 0.25);
}

.sp-plan-name {
  font-size: clamp(1.75rem, 1.4rem + 1.3vw, 2.375rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.035em;
  color: var(--ink);
}

.sp-plan-extra {
  font-size: 0.875rem;
  font-weight: 650;
  color: var(--ink-3);
}

.sp-plan--chosen .sp-plan-extra {
  color: var(--dawn-ink);
}

.sp-start .store-button--soon,
.sp-guide-end .store-button--soon {
  background: var(--night);
}

.sp-start .store-buttons {
  display: grid;
  justify-items: center;
  margin-top: 30px;
}

.sp-start-note {
  max-width: 40em;
  margin-top: 18px;
  font-size: 0.875rem;
  color: var(--ink-3);
}

/* The guide's ending, after the article (owner, 17. 11. 2026: not a box): the app's icon floating on the same soft dawn
   light as the price, the line to take the next photos with it, the store's button and the way to Skypose's page. */
.sp-guide-end {
  position: relative;
  padding-block: clamp(64px, 9vw, 120px) clamp(104px, 14vw, 184px);
  overflow: hidden;
  isolation: isolate;
}

.sp-guide-end-inner {
  display: grid;
  justify-items: center;
  text-align: center;
}

.sp-guide-end-icon {
  width: clamp(88px, 9vw, 112px);
  height: auto;
  margin-bottom: 30px;
  border-radius: 22.37%;
  box-shadow: 0 26px 50px -18px rgb(60 30 90 / 0.55);
  animation: float 7s ease-in-out infinite;
}

.sp-guide-end .sp-title {
  max-width: 14em;
  font-size: clamp(2rem, 1.3rem + 2.6vw, 3.25rem);
}

.sp-guide-end .sp-lead {
  margin-inline: auto;
}

.sp-guide-end .store-buttons {
  display: grid;
  justify-items: center;
  margin-top: 30px;
}

.sp-guide-end .sp-text-link {
  margin-top: 20px;
}

/* The guide: its four angles fanned out like prints on a table, opening a little more under the pointer. */
.sp-teaser-section {
  padding-block: clamp(40px, 6vw, 80px) clamp(72px, 10vw, 128px);
}

.sp-teaser {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
  gap: clamp(32px, 6vw, 96px);
  color: inherit;
  text-decoration: none;
}

.sp-teaser-fan {
  position: relative;
  height: clamp(240px, 26vw, 330px);
}

.sp-teaser-fan picture {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 32%;
  transition: transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.sp-teaser-fan img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 16px;
  box-shadow: 0 22px 40px -16px rgb(30 16 50 / 0.5);
}

.sp-teaser-fan picture:nth-child(1) {
  transform: translate(-150%, -50%) rotate(-9deg);
}

.sp-teaser-fan picture:nth-child(2) {
  transform: translate(-85%, -54%) rotate(-3deg);
}

.sp-teaser-fan picture:nth-child(3) {
  transform: translate(-15%, -52%) rotate(3deg);
}

.sp-teaser-fan picture:nth-child(4) {
  transform: translate(50%, -48%) rotate(9deg);
}

.sp-teaser:hover .sp-teaser-fan picture:nth-child(1) {
  transform: translate(-164%, -52%) rotate(-12deg);
}

.sp-teaser:hover .sp-teaser-fan picture:nth-child(2) {
  transform: translate(-91%, -57%) rotate(-4deg);
}

.sp-teaser:hover .sp-teaser-fan picture:nth-child(3) {
  transform: translate(-9%, -54%) rotate(4deg);
}

.sp-teaser:hover .sp-teaser-fan picture:nth-child(4) {
  transform: translate(64%, -48%) rotate(12deg);
}

.sp-teaser-kicker {
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dawn-ink);
}

.sp-teaser-title {
  margin-top: 10px;
  font-size: clamp(1.75rem, 1.25rem + 2vw, 2.75rem);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

.sp-teaser-lead {
  max-width: 30em;
  margin-top: 14px;
  font-size: 1.125rem;
  color: var(--ink-2);
}

@media (max-width: 860px) {
  .sp-change-grid,
  .sp-day-grid,
  .sp-teaser {
    grid-template-columns: minmax(0, 1fr);
  }

  .sp-change-text {
    order: -1;
  }

  .sp-compare {
    justify-self: center;
    width: min(100%, 460px);
  }

  .sp-private-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .sp-private-head {
    position: static;
  }
}

@media (max-width: 560px) {
  .sp-run-angles {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .sp-day-scene {
    min-height: 400px;
  }

  .sp-teaser-fan {
    height: 220px;
  }
}

/* The parts come in as the page scrolls, driven by the scroll itself (as .reveal): the four photos one after another,
   the reminder from above and the widget from below. */
@supports (animation-timeline: view()) {
  .sp-angle-tile {
    animation: sp-deal linear both;
    animation-timeline: view();
    animation-range: entry 10% cover 32%;
  }

  .sp-angle-tile:nth-child(2) {
    animation-range: entry 16% cover 36%;
  }

  .sp-angle-tile:nth-child(3) {
    animation-range: entry 22% cover 40%;
  }

  .sp-angle-tile:nth-child(4) {
    animation-range: entry 28% cover 44%;
  }

  .sp-note {
    animation: sp-drop linear both;
    animation-timeline: view();
    animation-range: entry 20% cover 42%;
  }

  .sp-widget {
    animation: sp-rise linear both;
    animation-timeline: view();
    animation-range: entry 30% cover 50%;
  }

  .sp-widget:nth-child(2) {
    animation-range: entry 36% cover 56%;
  }

  .sp-private-list li {
    animation: sp-light-up linear both;
    animation-timeline: view();
    animation-range: cover 18% cover 46%;
  }
}

@keyframes sp-light-up {
  from {
    opacity: 0.22;
    transform: translateY(18px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes sp-deal {
  from {
    opacity: 0;
    transform: translateY(70px) rotate(var(--tilt, 0deg)) scale(0.94);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes sp-drop {
  from {
    opacity: 0;
    transform: translateY(-28px) scale(0.96);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes sp-rise {
  from {
    opacity: 0;
    transform: translateY(36px) scale(0.94);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

.sp-faq-section {
  padding-bottom: clamp(64px, 9vw, 112px);
}

.sp-more {
  margin-top: 4px;
}

/* Support: the questions in groups, each with its heading. */
.sp-faq-group {
  margin-top: 48px;
  font-size: 1.375rem;
  letter-spacing: -0.015em;
  scroll-margin-top: 84px;
}

.sp-faq-group:first-child {
  margin-top: 0;
}

.sp-faq-group + .faq {
  margin-top: 12px;
}

.sp-support details {
  scroll-margin-top: 84px;
}

/* The address at the top of support, so nobody has to scroll for it (App Review, guideline 1.5). */
.sp-doc-mail {
  margin-top: 6px;
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--on-sky);
}

.sp-doc-mail a {
  color: inherit;
  text-decoration-thickness: 0.08em;
}

/* For Android, at the top of support, the privacy policy and the terms: it isn't out yet, so they're about iPhone. */
.sp-platform-note {
  margin-top: 8px;
  padding: 14px 18px;
  border: 1px solid color-mix(in srgb, var(--dawn-mauve) 35%, var(--line));
  border-radius: var(--radius-m);
  background: color-mix(in srgb, var(--dawn-mauve) 8%, var(--surface));
  color: var(--ink);
  font-weight: 600;
}

.sp-support-maker {
  max-width: 64ch;
  margin-top: 40px;
  color: var(--ink-2);
}

.sp-support-legal {
  margin-top: 12px;
  color: var(--ink-3);
}

/* The guide: its pictures, the four angles side by side and the app's screens in their frame. */
.sp-guide figure {
  max-width: 68ch;
  margin: 24px 0 0;
}

.sp-guide figcaption {
  margin-top: 10px;
  font-size: 0.9375rem;
  color: var(--ink-3);
}

.sp-angles {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.sp-angles img {
  border-radius: 12px;
}

/* Before and after, side by side, each as big as two of the four angles. */
.sp-angles--pair {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  max-width: 520px;
}

/* The dusk: contact, under the same sky dimmed as the app dims it at night, with the footer as its ground. */
.sp-dusk {
  position: relative;
  padding-block: clamp(96px, 13vw, 170px) clamp(80px, 11vw, 140px);
  overflow: hidden;
  background: var(--dusk-ground);
  color: var(--on-sky);
  isolation: isolate;
}

.sp-dusk::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, transparent 45%, var(--dusk-ground));
}

.sp-dusk-edge {
  position: absolute;
  inset: -1px 0 auto;
  z-index: 1;
  width: 100%;
  height: clamp(36px, 5vw, 72px);
}

.sp-dusk-edge path {
  fill: var(--bg);
}

.sp-dusk-content {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 18px;
  text-align: center;
}

.eyebrow--dusk {
  color: #ffd2ad;
}

.site-footer--skypose {
  background: var(--dusk-ground);
}

/* The home page's card for Skypose: the sky behind it, and the Journal rising from its bottom. Next to Schooliday's sea
   and petals the sky moves a little more than on Skypose's pages (owner, 17. 11. 2026): it drifts, and two soft lights of
   dawn cross it slowly. */
.app-card--skypose {
  background: var(--dawn-mauve);
}

.app-card--skypose .sp-sky img {
  animation: sp-sky-flow 22s ease-in-out infinite alternate;
}

.app-card--skypose .sp-sky::before,
.app-card--skypose .sp-sky::after {
  content: "";
  position: absolute;
  z-index: 1;
  width: 80%;
  aspect-ratio: 1;
  background: radial-gradient(closest-side, rgb(255 196 150 / 0.42), transparent);
  pointer-events: none;
  animation: sp-light 17s ease-in-out infinite alternate;
}

.app-card--skypose .sp-sky::before {
  top: -30%;
  left: -20%;
}

.app-card--skypose .sp-sky::after {
  right: -25%;
  bottom: -35%;
  background: radial-gradient(closest-side, rgb(140 160 255 / 0.36), transparent);
  animation-duration: 23s;
  animation-direction: alternate-reverse;
}

@keyframes sp-sky-flow {
  0% {
    transform: scale(1.12) translate(0, 0);
  }

  50% {
    transform: scale(1.28) translate(-5%, 4%);
  }

  100% {
    transform: scale(1.18) translate(4%, -2%);
  }
}

@keyframes sp-light {
  to {
    transform: translate(34%, 22%) scale(1.15);
  }
}

@media (max-width: 860px) {
  .sp-hero-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  /* One column: the text above the phone, everything in it centred. */
  .sp-hero-text {
    align-items: center;
    padding-bottom: 8px;
    text-align: center;
  }

  .sp-hero .store-buttons {
    justify-content: center;
  }

  .sp-hero .store-buttons.platform-stack {
    justify-items: center;
  }
}

/* Motion. Everything here stops with Reduce Motion (the end of the file). */

/* Sections rise into view as the page scrolls, driven by the scroll itself: a browser without scroll-driven
   animations shows them as they are, so nothing ever stays hidden. */
@supports (animation-timeline: view()) {
  .reveal {
    animation: reveal linear both;
    animation-timeline: view();
    animation-range: entry 0% entry 75%;
  }
}

@keyframes reveal {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

/* Petals drifting down the sky, as in the app's spring themes. */
.petal {
  position: absolute;
  top: -4%;
  left: var(--x);
  width: var(--s);
  height: calc(var(--s) * 0.72);
  border-radius: 80% 0 80% 0;
  background: linear-gradient(135deg, #fff7fb, #ffc4da);
  opacity: 0;
  filter: drop-shadow(0 1px 2px rgb(120 40 90 / 0.22));
  animation: petal-fall var(--d) linear var(--delay) infinite;
  will-change: transform;
}

@keyframes petal-fall {
  0% {
    transform: translate3d(0, -6vh, 0) rotate(0deg);
    opacity: 0;
  }

  8%,
  88% {
    opacity: 0.9;
  }

  100% {
    transform: translate3d(var(--drift), 115vh, 0) rotate(560deg);
    opacity: 0;
  }
}

/* The sun breathes, the sea moves, the phone floats. */
.sd-sun,
.scene-sun {
  animation: sun-breathe 7s ease-in-out infinite;
}

@keyframes sun-breathe {
  50% {
    transform: scale(1.04);
    box-shadow: 0 0 190px 72px rgb(255 186 104 / 0.5);
  }
}

.sea-far {
  animation: sea-drift 48s linear infinite;
}

.sea-near {
  animation: sea-drift 33s linear infinite;
}

.sea-shore {
  animation: sea-drift 62s linear infinite;
}

@keyframes sea-drift {
  to {
    transform: translateX(-1440px);
  }
}

.phone-float {
  animation: float 7s ease-in-out infinite;
}

@keyframes float {
  50% {
    transform: translateY(-12px);
  }
}

/* MJX Studio's contact, on its home page: its ink rising like a sheet, with the sunset's lights and a grid of dots;
   the footer is its ground. The Schooliday pages have the night instead. */

.studio-contact {
  position: relative;
  padding-block: clamp(96px, 13vw, 160px) clamp(80px, 11vw, 132px);
  overflow: hidden;
  border-radius: clamp(28px, 5vw, 56px) clamp(28px, 5vw, 56px) 0 0;
  background: linear-gradient(180deg, var(--studio-top), var(--studio-ground));
  color: var(--on-sky);
  isolation: isolate;
}

.studio-contact::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: radial-gradient(rgb(255 255 255 / 0.13) 1px, transparent 1.6px) 0 0 / 24px 24px;
  -webkit-mask-image: radial-gradient(ellipse 62% 72% at 50% 45%, #000 15%, transparent 75%);
  mask-image: radial-gradient(ellipse 62% 72% at 50% 45%, #000 15%, transparent 75%);
}

/* The lights fade into the ground before the section ends, so it meets the footer without an edge. */
.studio-contact::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  z-index: -1;
  height: 34%;
  background: linear-gradient(180deg, transparent, var(--studio-ground) 85%);
}

.studio-glow {
  position: absolute;
  left: 50%;
  top: 48%;
  z-index: -2;
  width: min(960px, 130vw);
  aspect-ratio: 1.7;
  filter: blur(80px);
  opacity: 0.5;
  translate: -50% -50%;
}

.studio-glow span {
  position: absolute;
  border-radius: 50%;
}

.studio-glow span:nth-child(1) {
  left: 4%;
  top: 22%;
  width: 44%;
  height: 58%;
  background: var(--sky-violet);
  animation: aurora-b 21s ease-in-out infinite alternate;
}

.studio-glow span:nth-child(2) {
  left: 32%;
  top: 30%;
  width: 38%;
  height: 54%;
  background: var(--sky-rose);
  animation: aurora-a 25s ease-in-out infinite alternate;
}

.studio-glow span:nth-child(3) {
  left: 56%;
  top: 12%;
  width: 40%;
  height: 60%;
  background: var(--sky-glow);
  animation: aurora-c 29s ease-in-out infinite alternate;
}

.studio-contact-content {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 18px;
  text-align: center;
}

.eyebrow--studio {
  color: var(--sun-mid);
}

.site-footer--studio {
  background: var(--studio-ground);
}

.site-footer--studio .footer-row {
  justify-content: center;
  text-align: center;
}

/* The night: contact, under the stars, with the footer as its ground. */

.night {
  position: relative;
  padding-block: clamp(96px, 13vw, 170px) clamp(80px, 11vw, 140px);
  overflow: hidden;
  /* The top few pixels stay the page's own colour, under the wave, so no seam shows between them. */
  background: linear-gradient(180deg, transparent 0 6px, var(--night-top) 6px, var(--night-mid) 42%, var(--night-ground) 100%);
  color: var(--on-sky);
  isolation: isolate;
}

.night-edge {
  position: absolute;
  inset: -1px 0 auto;
  width: 100%;
  height: clamp(36px, 5vw, 72px);
}

.night-edge path {
  fill: var(--bg);
}

.night-sky {
  position: absolute;
  inset: 0;
  z-index: -1;
}

.moon {
  position: absolute;
  top: 22%;
  right: max(6%, calc(50% - 560px));
  width: clamp(64px, 8vw, 112px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle at 38% 36%, #fffdf1, var(--moon) 55%, #e9d9a2);
  box-shadow: 0 0 60px 18px rgb(255 240 190 / 0.28), 0 0 160px 60px rgb(160 150 255 / 0.18);
}

.stars {
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(1.6px 1.6px at 8% 18%, #fff 50%, transparent 52%),
    radial-gradient(1.2px 1.2px at 17% 62%, #fff 50%, transparent 52%),
    radial-gradient(1.8px 1.8px at 26% 34%, #fff 50%, transparent 52%),
    radial-gradient(1.1px 1.1px at 34% 78%, #fff 50%, transparent 52%),
    radial-gradient(1.5px 1.5px at 43% 14%, #fff 50%, transparent 52%),
    radial-gradient(1.2px 1.2px at 51% 48%, #fff 50%, transparent 52%),
    radial-gradient(1.7px 1.7px at 59% 26%, #fff 50%, transparent 52%),
    radial-gradient(1.1px 1.1px at 66% 70%, #fff 50%, transparent 52%),
    radial-gradient(1.4px 1.4px at 73% 40%, #fff 50%, transparent 52%),
    radial-gradient(1.2px 1.2px at 81% 82%, #fff 50%, transparent 52%),
    radial-gradient(1.6px 1.6px at 88% 58%, #fff 50%, transparent 52%),
    radial-gradient(1.1px 1.1px at 95% 24%, #fff 50%, transparent 52%);
  opacity: 0.85;
  animation: twinkle 4.5s ease-in-out infinite alternate;
}

.stars--far {
  background-image:
    radial-gradient(1px 1px at 5% 44%, #fff 50%, transparent 52%),
    radial-gradient(1px 1px at 13% 86%, #fff 50%, transparent 52%),
    radial-gradient(1px 1px at 21% 10%, #fff 50%, transparent 52%),
    radial-gradient(1px 1px at 30% 54%, #fff 50%, transparent 52%),
    radial-gradient(1px 1px at 38% 30%, #fff 50%, transparent 52%),
    radial-gradient(1px 1px at 47% 88%, #fff 50%, transparent 52%),
    radial-gradient(1px 1px at 55% 8%, #fff 50%, transparent 52%),
    radial-gradient(1px 1px at 63% 60%, #fff 50%, transparent 52%),
    radial-gradient(1px 1px at 70% 16%, #fff 50%, transparent 52%),
    radial-gradient(1px 1px at 78% 66%, #fff 50%, transparent 52%),
    radial-gradient(1px 1px at 86% 36%, #fff 50%, transparent 52%),
    radial-gradient(1px 1px at 93% 90%, #fff 50%, transparent 52%);
  opacity: 0.55;
  animation-duration: 6.5s;
  animation-delay: -2s;
}

@keyframes twinkle {
  to {
    opacity: 0.25;
  }
}

.night-content {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 18px;
  text-align: center;
}

.eyebrow--night {
  color: var(--sun-mid);
}

.night-title,
.studio-title {
  max-width: 15em;
  font-size: clamp(2rem, 1.3rem + 2.8vw, 3.5rem);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.03em;
  color: var(--on-sky);
}

.mail-button {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  max-width: 100%;
  margin-top: 12px;
  padding: 16px 22px 16px 20px;
  border-radius: 999px;
  background: #ffffff;
  color: #1b1e3c;
  font-size: clamp(1.0625rem, 0.95rem + 0.6vw, 1.375rem);
  font-weight: 750;
  text-decoration: none;
  box-shadow: 0 18px 40px rgb(0 0 0 / 0.35), 0 0 0 6px rgb(255 255 255 / 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.mail-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 26px 56px rgb(0 0 0 / 0.45), 0 0 0 8px rgb(255 255 255 / 0.12);
}

.mail-button span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.mail-icon,
.mail-arrow {
  flex: none;
  width: 24px;
  height: 24px;
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.mail-icon {
  stroke: #4a3ec8;
}

.mail-arrow {
  stroke: currentColor;
  transition: transform 0.25s ease;
}

.mail-button:hover .mail-arrow {
  transform: translateX(4px);
}

/* Narrower screens: the title takes the whole width, so the moon rises above it. */

@media (max-width: 1100px) {
  .night {
    padding-top: clamp(128px, 18vw, 190px);
  }

  .moon {
    top: clamp(44px, 7vw, 72px);
    right: max(20px, 6%);
    width: clamp(48px, 7vw, 72px);
  }
}


/* A page that doesn't exist (404.html, the nearest one for every language): the number in the sunset's colours and the
   way to the app, on the page's own ground, with the studio's footer. */

/* The page is short, so it fills the window and the footer stays at its bottom. */
.page-not-found {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
}

.not-found {
  display: grid;
  flex: 1;
  place-items: center;
  padding-block: clamp(72px, 12vw, 128px);
}

.not-found-content {
  display: grid;
  justify-items: center;
  gap: 28px;
  text-align: center;
}

.not-found-code {
  margin: 0;
  font-size: clamp(6rem, 24vw, 11rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.04em;
  background: linear-gradient(90deg, var(--sky-violet), var(--sky-rose), var(--sky-ember));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.not-found-app {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 20px 12px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-m);
  background: var(--surface);
  color: var(--ink);
  text-align: left;
  text-decoration: none;
}

.not-found-app:hover {
  background: var(--surface-2);
}

.not-found-app img {
  border-radius: 22.37%;
}

.not-found-app > span {
  display: grid;
  line-height: 1.35;
}

.not-found-app > span > span {
  font-size: 0.875rem;
  color: var(--ink-3);
}

@media (prefers-reduced-motion: reduce) {
  .petal {
    display: none;
  }

  .aurora span,
  .studio-glow span,
  .sd-sun,
  .scene-sun,
  .sea-far,
  .sea-near,
  .sea-shore,
  .phone-float,
  .stars,
  .sp-sky img,
  .sp-sky::before,
  .sp-sky::after,
  .sp-angle-tile,
  .sp-angle-name,
  .sp-note,
  .sp-widget,
  .sp-private-list li,
  .sp-start::before,
  .sp-guide-end::before,
  .sp-guide-end-icon {
    animation: none !important;
  }

  .reveal {
    animation: none !important;
  }

  .carousel-slide .phone,
  .carousel-caption,
  .carousel-arrow,
  .feature,
  .flag,
  .mail-button,
  .app-card,
  .app-card-phone,
  .shelf-paddle,
  .sp-teaser-fan picture,
  .sp-text-link::after {
    transition: none;
  }
}
