:root {
  color-scheme: light;
  --ink: #121826;
  --muted: #667085;
  --chrome: rgba(255, 255, 255, 0.92);
  --line: #d8dee8;
  --accent: #1f4f7a;
  --surface: #f4f6f9;
  --shadow: 0 22px 55px rgba(18, 24, 38, 0.16);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 66px;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--surface);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
}

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

.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 58px;
  padding: 10px 18px;
  border-bottom: 1px solid rgba(216, 222, 232, 0.82);
  background: var(--chrome);
  backdrop-filter: blur(16px);
}

.brand {
  display: grid;
  gap: 1px;
  color: inherit;
  text-decoration: none;
}

.brand strong {
  font-size: 15px;
  line-height: 1.15;
}

.brand span {
  color: var(--muted);
  font-size: 12px;
}

.toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
}

.counter {
  min-width: 58px;
  color: #344054;
  font-size: 13px;
  font-weight: 700;
  text-align: center;
}

.control {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 7px 11px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: #263246;
  background: #fff;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}

.control.primary {
  border-color: var(--accent);
  color: #fff;
  background: var(--accent);
}

.deck {
  display: grid;
  gap: 16px;
  padding-top: 74px;
  padding-bottom: 108px;
}

.slide-page {
  display: grid;
  padding: 0 24px;
  place-items: center;
  scroll-margin-top: 70px;
}

.slide-page > img,
.slide-shell {
  width: min(100%, 1380px, calc((100vh - 126px) * 16 / 9));
  aspect-ratio: 16 / 9;
  border: 1px solid rgba(18, 24, 38, 0.08);
  background: #fff;
  box-shadow: var(--shadow);
}

.slide-page > img {
  object-fit: contain;
}

.slide-shell {
  position: relative;
  overflow: hidden;
}

.slide-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.motion {
  position: absolute;
  z-index: 2;
  display: block;
  max-width: none;
  border: 0;
  background: #000;
  object-fit: cover;
}

.motion-flight-evidence {
  left: 5.25%;
  top: 25.25%;
  width: 49.85%;
  height: 50.35%;
}

.motion-map {
  left: 7.95%;
  top: 24.25%;
  width: 31.95%;
  height: 44.95%;
}

.motion-localization {
  left: 53.1%;
  top: 26.4%;
  width: 45.65%;
  height: 43.85%;
}

.motion-navigation {
  left: 5.62%;
  top: 27.2%;
  width: 47.55%;
  height: 43.8%;
}

.motion-obstacle {
  left: 59.1%;
  top: 28.55%;
  width: 39.9%;
  height: 39.85%;
}

.thumbs {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 25;
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 10px 16px 13px;
  border-top: 1px solid rgba(216, 222, 232, 0.86);
  background: var(--chrome);
  backdrop-filter: blur(16px);
}

.thumbs a {
  flex: 0 0 auto;
  width: 96px;
  border: 2px solid transparent;
  border-radius: 7px;
  background: #fff;
  box-shadow: 0 6px 16px rgba(18, 24, 38, 0.12);
}

.thumbs a.active {
  border-color: var(--accent);
}

.thumbs img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 5px;
}

@media (max-width: 700px) {
  html {
    scroll-padding-top: 86px;
  }

  .topbar {
    align-items: stretch;
    flex-direction: column;
    gap: 8px;
    min-height: 88px;
  }

  .toolbar {
    justify-content: space-between;
  }

  .control {
    min-height: 36px;
    padding: 7px 10px;
  }

  .deck {
    gap: 12px;
    padding-top: 88px;
    padding-bottom: 94px;
  }

  .slide-page {
    padding: 0 10px;
    scroll-margin-top: 94px;
  }

  .slide-page > img,
  .slide-shell {
    width: 100%;
    max-height: none;
    box-shadow: 0 12px 30px rgba(18, 24, 38, 0.16);
  }

  .thumbs {
    gap: 7px;
    padding: 9px 10px 11px;
  }

  .thumbs a {
    width: 82px;
  }
}
