﻿@import url("modules/mapa/css/base.css");
@import url("modules/mapa/css/layout.css");
@import url("modules/mapa/css/controls.css");
@import url("modules/mapa/css/toolbar.css");
@import url("modules/mapa/css/modals.css");
@import url("modules/mapa/css/responsive.css");

.app-shell {
  --totem-safe-area-padding: 0px;
  --totem-safe-area-top: 0px;
  --totem-safe-area-right: 0px;
  --totem-safe-area-bottom: 0px;
  --totem-safe-area-left: 0px;
  min-height: 100vh;
  min-height: 100dvh;
  overflow: hidden;
  background: #0750d8;
  font-family: "Google Sans", Arial, sans-serif;
}

.app-shell--totem {
  background: #000000;
}

.map-stage {
  position: fixed;
  inset: var(--totem-safe-area-top) var(--totem-safe-area-right) var(--totem-safe-area-bottom) var(--totem-safe-area-left);
  z-index: 1;
  background: #0c4d93;
  opacity: 0;
  pointer-events: none;
  transition: opacity 280ms ease;
}

.map-stage.is-active {
  opacity: 1;
  pointer-events: auto;
}

.map-stage.is-loading #top-right-container,
.map-stage.is-loading #top-center-container,
.map-stage.is-loading #bottom-right-container,
.map-stage.is-loading #mobile-drawer,
.map-stage.is-loading #mobile-menu-backdrop {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.map-stage.is-loading #top-right-container,
.map-stage.is-loading #top-center-container,
.map-stage.is-loading #bottom-right-container {
  transform: translateY(10px);
}

.map-stage[hidden] {
  display: none !important;
}

.history-modal {
  position: fixed;
  inset: var(--totem-safe-area-top) var(--totem-safe-area-right) var(--totem-safe-area-bottom) var(--totem-safe-area-left);
  z-index: 42;
  opacity: 0;
  pointer-events: none;
  transition: opacity 220ms ease;
}

.history-modal[hidden] {
  display: none !important;
}

.history-modal.is-open {
  opacity: 1;
  pointer-events: auto;
}

.history-modal__backdrop {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at top left, rgba(53, 147, 255, 0.28), transparent 28%),
    rgba(2, 11, 28, 0.72);
  backdrop-filter: blur(10px);
}

.history-modal__panel {
  position: relative;
  width: 100%;
  height: 100%;
  background: #03152f;
  color: #f4f8ff;
  overflow: hidden;
}

.history-modal__header {
  position: relative;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px clamp(18px, 3vw, 34px) 12px;
  background: linear-gradient(180deg, rgba(3, 21, 47, 0.94), rgba(3, 21, 47, 0.16));
}

.history-modal__header-copy {
  display: grid;
  gap: 4px;
}

.history-modal__eyebrow {
  font-size: 0.82rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #7cb6ff;
}

.history-modal__header strong {
  font-size: clamp(1.2rem, 2.4vw, 1.8rem);
  line-height: 1.1;
}

.history-modal__close {
  min-height: 46px;
  padding: 0 16px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  cursor: pointer;
}

.history-modal__nav {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  max-width: min(82vw, 720px);
}

.history-modal__nav-item {
  min-height: 52px;
  padding: 0 20px;
  border: 1px solid rgba(173, 216, 255, 0.2);
  border-radius: 999px;
  background: rgba(6, 22, 46, 0.36);
  color: #eef5ff;
  text-align: center;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease, box-shadow 180ms ease;
  backdrop-filter: blur(12px);
  cursor: pointer;
}

.history-modal__nav-item.is-active {
  background: linear-gradient(135deg, rgba(39, 145, 255, 0.56), rgba(81, 192, 255, 0.24));
  border-color: rgba(186, 233, 255, 0.58);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.24);
  transform: translateY(-2px) scale(1.02);
}

.history-modal__nav-label {
  font-size: 0.95rem;
  font-weight: 700;
  white-space: nowrap;
}

.history-modal__stage {
  position: absolute;
  inset: 0;
  overflow: hidden;
  background:
    radial-gradient(circle at top center, rgba(58, 136, 255, 0.22), transparent 28%),
    linear-gradient(160deg, #061835 0%, #0a2855 42%, #07162f 100%);
}

.history-modal__visual,
.history-modal__overlay,
.history-modal__story {
  position: absolute;
  inset: 0;
}

.history-modal__visual {
  background:
    linear-gradient(180deg, rgba(2, 12, 29, 0.28), rgba(2, 12, 29, 0.72)),
    linear-gradient(145deg, rgba(44, 113, 255, 0.28), rgba(7, 23, 47, 0.18) 34%, rgba(12, 34, 70, 0.82));
  background-size: cover;
  background-position: center center;
  transform: scale(1.04) translate3d(0, 0, 0);
  filter: saturate(1.08);
}

.history-modal__visual[data-has-image="false"] {
  background:
    radial-gradient(circle at top center, rgba(70, 157, 255, 0.34), transparent 24%),
    linear-gradient(145deg, rgba(37, 113, 242, 0.42), rgba(5, 22, 45, 0.48) 36%, rgba(5, 22, 45, 0.94));
}

.history-modal__overlay {
  background:
    radial-gradient(circle at center, rgba(10, 34, 74, 0.08), rgba(2, 12, 29, 0.52) 70%),
    linear-gradient(180deg, rgba(2, 12, 29, 0.34) 0%, rgba(2, 12, 29, 0.2) 18%, rgba(2, 12, 29, 0.72) 52%, rgba(2, 12, 29, 0.98) 100%);
}

.history-modal__selector-shell {
  position: absolute;
  top: calc(clamp(92px, 11vh, 128px) + var(--totem-safe-area-top));
  left: 0;
  right: 0;
  z-index: 4;
  display: grid;
  grid-template-columns: minmax(54px, 84px) minmax(0, 1fr) minmax(54px, 84px);
  align-items: center;
  gap: clamp(10px, 1.8vw, 22px);
  padding: 0 clamp(10px, 2vw, 24px);
}

.history-modal__audio-toggle {
  position: absolute;
  top: calc(clamp(332px, 39vh, 458px) + var(--totem-safe-area-top));
  right: calc(clamp(14px, 2.4vw, 28px) + var(--totem-safe-area-right));
  z-index: 4;
  min-height: 42px;
  padding: 0 12px;
  border: 1px solid rgba(196, 231, 255, 0.3);
  border-radius: 999px;
  background: rgba(4, 18, 39, 0.32);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  backdrop-filter: blur(12px);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.22);
  cursor: pointer;
  font-size: 0.9rem;
}

.history-modal__audio-toggle.is-muted {
  background: rgba(115, 27, 36, 0.4);
  border-color: rgba(255, 188, 192, 0.28);
}

.history-modal__audio-toggle .material-symbols-outlined {
  font-size: 22px;
}

.history-modal__selector-shell,
.history-modal__audio-toggle,
.history-modal__story-head,
.history-modal__crawl-viewport,
.history-modal__side-control,
.history-modal__nav-item {
  backface-visibility: hidden;
  transform: translateZ(0);
}

.history-modal__side-control {
  width: clamp(52px, 5vw, 72px);
  height: clamp(52px, 5vw, 72px);
  border: 1px solid rgba(196, 231, 255, 0.3);
  border-radius: 999px;
  background: rgba(4, 18, 39, 0.32);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  justify-self: center;
  backdrop-filter: blur(12px);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.22);
  cursor: pointer;
}

.history-modal__side-control .material-symbols-outlined {
  font-size: 38px;
}

.history-modal__story {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  grid-template-rows: auto 1fr;
  justify-items: center;
  padding:
    calc(clamp(168px, 19vh, 220px) + var(--totem-safe-area-top))
    clamp(10px, 2.8vw, 24px)
    calc(clamp(28px, 4vh, 42px) + var(--totem-safe-area-bottom));
}

.history-modal__story::before {
  content: none;
}

.history-modal__story-head {
  position: relative;
  z-index: 1;
  width: min(96vw, 760px);
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 8px;
}

.history-modal__story-kicker {
  font-size: 0.86rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #9dd2ff;
}

.history-modal__story-title {
  margin: 0;
  width: 100%;
  font-size: clamp(2.35rem, 5vw, 3.95rem);
  line-height: 0.96;
  font-weight: 700;
  text-align: center;
  text-shadow: 0 12px 34px rgba(0, 0, 0, 0.44);
}

.history-modal__story-subtitle {
  max-width: 760px;
  margin: 0;
  color: rgba(238, 245, 255, 0.9);
  font-size: clamp(1.08rem, 2.2vw, 1.42rem);
  line-height: 1.42;
  text-align: center;
}

.history-modal__crawl-viewport {
  position: relative;
  z-index: 1;
  width: min(96vw, 780px);
  min-height: 0;
  overflow: hidden;
  margin-top: clamp(22px, 4vh, 34px);
  perspective: 520px;
  mask-image: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.85) 12%, rgba(0, 0, 0, 0.96) 70%, transparent 100%);
  touch-action: none;
  user-select: none;
  cursor: grab;
}

.history-modal__crawl-viewport.is-dragging {
  cursor: grabbing;
}

.history-modal__crawl {
  --history-crawl-duration: 28000ms;
  width: 100%;
  padding: 44% 0 0;
  will-change: transform;
  transform-origin: center bottom;
  animation: history-crawl-up var(--history-crawl-duration) linear forwards;
}

.history-modal__crawl[data-mode="manual"] {
  animation: none !important;
}

.history-modal__crawl p {
  margin: 0 0 30px;
  font-size: clamp(3.15rem, 5.2vw, 4.15rem);
  line-height: 1.5;
  color: rgba(249, 252, 255, 0.96);
  text-align: left;
  text-wrap: pretty;
  text-shadow: 0 5px 18px rgba(0, 0, 0, 0.68);
}

#history-modal-stage[data-history-id="dores-do-rio-preto-sede"] .history-modal__story {
  padding:
    calc(clamp(182px, 21vh, 246px) + var(--totem-safe-area-top))
    clamp(10px, 2.8vw, 24px)
    calc(clamp(18px, 3vh, 28px) + var(--totem-safe-area-bottom));
}

#history-modal-stage[data-history-id="dores-do-rio-preto-sede"] .history-modal__story-head {
  width: min(96vw, 800px);
}

#history-modal-stage[data-history-id="dores-do-rio-preto-sede"] .history-modal__crawl-viewport {
  width: min(96vw, 800px);
  margin-top: clamp(24px, 4vh, 36px);
}

@keyframes history-crawl-up {
  from {
    transform: rotateX(10deg) translateY(8%);
  }
  to {
    transform: rotateX(10deg) translateY(-112%);
  }
}


.news-gallery-links {
  display: none !important;
}

.glightbox-container .gslide-description,
.glightbox-container .gdesc-inner,
.glightbox-container .gslide-title,
.glightbox-container .gslide-desc {
  display: none !important;
}

.glightbox-container.glightbox-clean .gclose,
.glightbox-container.glightbox-clean .gprev,
.glightbox-container.glightbox-clean .gnext {
  position: absolute;
  width: 72px;
  height: 72px;
  margin: 0;
  border-radius: 999px !important;
  background: #e2efff !important;
  border: 1px solid #8bb5f1;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.22);
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
  color: #0a4fd8 !important;
  overflow: hidden;
  opacity: 1 !important;
  visibility: visible !important;
  pointer-events: auto !important;
}

.glightbox-container.glightbox-clean .gprev.glightbox-button-hidden,
.glightbox-container.glightbox-clean .gnext.glightbox-button-hidden,
.glightbox-container.glightbox-clean .gclose.glightbox-button-hidden {
  display: inline-flex !important;
  opacity: 1 !important;
  visibility: visible !important;
  pointer-events: auto !important;
}

.glightbox-container.glightbox-clean .gclose {
  top: calc(max(16px, env(safe-area-inset-top, 0px) + 8px) + var(--totem-safe-area-top, 0px));
  right: calc(max(16px, env(safe-area-inset-right, 0px) + 8px) + var(--totem-safe-area-right, 0px));
}

.glightbox-container.glightbox-clean .gprev,
.glightbox-container.glightbox-clean .gnext {
  --glightbox-control-shift: -50%;
  top: 50%;
  transform: translateY(-50%);
}

.glightbox-container.glightbox-clean .gprev {
  left: calc(max(16px, env(safe-area-inset-left, 0px) + 8px) + var(--totem-safe-area-left, 0px));
}

.glightbox-container.glightbox-clean .gnext {
  right: calc(max(16px, env(safe-area-inset-right, 0px) + 8px) + var(--totem-safe-area-right, 0px));
}

.glightbox-container.glightbox-clean .gclose:hover,
.glightbox-container.glightbox-clean .gprev:hover,
.glightbox-container.glightbox-clean .gnext:hover,
.glightbox-container.glightbox-clean .gclose:focus,
.glightbox-container.glightbox-clean .gprev:focus,
.glightbox-container.glightbox-clean .gnext:focus {
  transform: translateY(var(--glightbox-control-shift, 0)) scale(1.06);
  background: #f1f7ff !important;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.26);
}

.glightbox-container.glightbox-clean .gclose:hover,
.glightbox-container.glightbox-clean .gclose:focus {
  transform: scale(1.06);
}

.glightbox-container.glightbox-clean .gclose svg,
.glightbox-container.glightbox-clean .gprev svg,
.glightbox-container.glightbox-clean .gnext svg {
  display: none !important;
}

.glightbox-container.glightbox-clean .gclose::before,
.glightbox-container.glightbox-clean .gprev::before,
.glightbox-container.glightbox-clean .gnext::before {
  font-family: "Material Symbols Outlined";
  font-size: 34px;
  line-height: 1;
  color: #3a78d6;
  font-variation-settings: 'FILL' 0, 'wght' 500, 'GRAD' 0, 'opsz' 24;
}

.glightbox-container.glightbox-clean .gclose::before {
  content: "close";
}

.glightbox-container.glightbox-clean .gprev::before {
  content: "chevron_left";
}

.glightbox-container.glightbox-clean .gnext::before {
  content: "chevron_right";
}

.glightbox-container .gslide-image img {
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
  max-height: none !important;
  object-fit: contain;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.glightbox-container .gslide-image,
.glightbox-container .gslide-media {
  width: 100% !important;
  height: 100% !important;
}

.glightbox-news-counter {
  position: absolute;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  min-height: 34px;
  padding: 0 14px;
  border-radius: 999px;
  background: #e8eefb;
  border: 1px solid #9eb9e8;
  color: #214d91;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: "Google Sans", Arial, sans-serif;
  font-size: 0.86rem;
  font-weight: 600;
  letter-spacing: 0;
  z-index: 999999;
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.2);
}

@media (max-width: 768px) {
  .glightbox-container.glightbox-clean .gclose,
  .glightbox-container.glightbox-clean .gprev,
  .glightbox-container.glightbox-clean .gnext {
    width: 58px;
    height: 58px;
  }

  .glightbox-container.glightbox-clean .gclose {
    top: calc(max(12px, env(safe-area-inset-top, 0px) + 6px) + var(--totem-safe-area-top, 0px));
    right: calc(max(12px, env(safe-area-inset-right, 0px) + 6px) + var(--totem-safe-area-right, 0px));
  }

  .glightbox-container.glightbox-clean .gprev {
    left: calc(max(10px, env(safe-area-inset-left, 0px) + 6px) + var(--totem-safe-area-left, 0px));
  }

  .glightbox-container.glightbox-clean .gnext {
    right: calc(max(10px, env(safe-area-inset-right, 0px) + 6px) + var(--totem-safe-area-right, 0px));
  }

  .glightbox-container.glightbox-clean .gclose::before,
  .glightbox-container.glightbox-clean .gprev::before,
  .glightbox-container.glightbox-clean .gnext::before {
    font-size: 28px;
  }
}

@media (max-width: 480px), (max-height: 520px) {
  .glightbox-container.glightbox-clean .gclose,
  .glightbox-container.glightbox-clean .gprev,
  .glightbox-container.glightbox-clean .gnext {
    width: 52px;
    height: 52px;
    background: #e2efff !important;
  }

  .glightbox-container.glightbox-clean .gprev {
    left: calc(max(8px, env(safe-area-inset-left, 0px) + 4px) + var(--totem-safe-area-left, 0px));
  }

  .glightbox-container.glightbox-clean .gnext {
    right: calc(max(8px, env(safe-area-inset-right, 0px) + 4px) + var(--totem-safe-area-right, 0px));
  }

  .glightbox-container.glightbox-clean .gclose::before,
  .glightbox-container.glightbox-clean .gprev::before,
  .glightbox-container.glightbox-clean .gnext::before {
    font-size: 24px;
  }
}

.totem-home {
  --home-blue-deep: #063fb7;
  --home-blue: #075fe8;
  --home-blue-soft: #18a5df;
  --home-cyan: #34c3de;
  --home-ink: #073170;
  --home-line: rgba(229, 249, 255, 0.72);
  position: fixed;
  inset: 0;
  z-index: 20;
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding:
    calc(clamp(28px, 6vw, 84px) + var(--totem-safe-area-top))
    calc(clamp(28px, 6vw, 84px) + var(--totem-safe-area-right))
    calc(clamp(28px, 6vw, 84px) + var(--totem-safe-area-bottom))
    calc(clamp(28px, 6vw, 84px) + var(--totem-safe-area-left));
  color: #ffffff;
  overflow: hidden;
  background:
    linear-gradient(155deg, rgba(52, 195, 222, 0.22) 0 14%, transparent 15%),
    radial-gradient(circle at 82% 18%, rgba(255, 255, 255, 0.14), transparent 24%),
    linear-gradient(180deg, var(--home-blue) 0%, var(--home-blue-deep) 58%, #06479d 100%);
  isolation: isolate;
  transition: opacity 260ms ease, transform 260ms ease;
}

.totem-home::before,
.totem-home::after {
  content: "";
  position: absolute;
  z-index: -2;
  border-radius: 999px;
  filter: blur(34px);
  opacity: 0.42;
  pointer-events: none;
}

.totem-home::before {
  width: min(62vw, 620px);
  height: min(62vw, 620px);
  left: -12vw;
  top: 18vh;
  background: rgba(45, 211, 226, 0.6);
  animation: totemHomeFloatA 5.8s ease-in-out infinite alternate;
}

.totem-home::after {
  width: min(54vw, 540px);
  height: min(54vw, 540px);
  right: -14vw;
  bottom: 8vh;
  background: rgba(255, 255, 255, 0.34);
  animation: totemHomeFloatB 6.2s ease-in-out infinite alternate;
}

.totem-home.is-leaving {
  opacity: 0;
  transform: scale(1.015);
  pointer-events: none;
}

.totem-home__pattern {
  position: absolute;
  inset: 0;
  z-index: -1;
  filter: blur(0.4px);
  pointer-events: none;
  animation: totemPatternDrift 6.2s ease-in-out infinite alternate;
}

.totem-home__pattern::before,
.totem-home__pattern::after {
  content: "";
  position: absolute;
  width: min(54vw, 560px);
  aspect-ratio: 1;
  border: 2px solid rgba(255, 255, 255, 0.54);
  border-radius: 50%;
}

.totem-home__pattern::before {
  left: -22vw;
  bottom: -20vw;
  filter: blur(2px);
  box-shadow:
    28px -18px 0 -2px rgba(255, 255, 255, 0.18),
    56px -36px 0 -2px rgba(255, 255, 255, 0.15),
    84px -54px 0 -2px rgba(255, 255, 255, 0.12);
}

.totem-home__pattern::after {
  right: -26vw;
  bottom: -24vw;
  filter: blur(2px);
  box-shadow:
    -30px -18px 0 -2px rgba(255, 255, 255, 0.2),
    -60px -36px 0 -2px rgba(255, 255, 255, 0.16),
    -90px -54px 0 -2px rgba(255, 255, 255, 0.13);
}

.totem-home__line {
  position: absolute;
  display: block;
  height: 128px;
  opacity: 0.46;
  filter: blur(0.7px);
  transform-origin: center;
}

.totem-home__line::before,
.totem-home__line::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(135deg, transparent 0 40%, var(--home-line) 40.4% 42%, transparent 42.4%),
    linear-gradient(45deg, transparent 0 55%, var(--home-line) 55.4% 57%, transparent 57.4%);
}

.totem-home__line--top {
  top: -8px;
  left: 8vw;
  width: min(22vw, 250px);
  animation: totemWaveLineTop 4.6s ease-in-out infinite alternate;
}

.totem-home__line--bottom {
  right: 10vw;
  bottom: 5vh;
  width: min(26vw, 320px);
  transform: rotate(8deg) scale(0.78);
  animation: totemWaveLineBottom 5.1s ease-in-out infinite alternate;
}

.totem-home__icon {
  position: absolute;
  color: rgba(255, 255, 255, 0.72);
  font-size: clamp(700px, 92vw, 1200px);
  line-height: 1;
  filter: blur(0.2px);
}

.totem-home__icon--water {
  left: 1vw;
  bottom: 1vh;
  transform: rotate(-8deg);
  animation: totemIconFloatB 4.7s ease-in-out infinite alternate;
}

.totem-home__icon--route {
  right: 2vw;
  bottom: 1vh;
  animation: totemIconFloatC 4.2s ease-in-out infinite alternate;
}

.totem-home__icon--city {
  top: 16vh;
  left: 1vw;
  font-size: clamp(520px, 64vw, 820px);
  opacity: 0.22;
  animation: totemIconFloatD 5.1s ease-in-out infinite alternate;
}

.totem-home__icon--plane {
  top: 6vh;
  left: 24vw;
  font-size: clamp(420px, 50vw, 720px);
  opacity: 0.3;
  animation: totemIconFloatE 3.8s ease-in-out infinite alternate;
}

.totem-home__icon--compass {
  right: 8vw;
  bottom: 2vh;
  font-size: clamp(500px, 60vw, 820px);
  opacity: 0.24;
  animation: totemIconFloatF 4.4s ease-in-out infinite alternate;
}

.totem-home__icon--mid-left {
  top: 41vh;
  left: 2vw;
  font-size: clamp(260px, 28vw, 420px);
  opacity: 0.24;
  animation: totemIconFloatG 4.9s ease-in-out infinite alternate;
}

.totem-home__icon--mid-right {
  top: 43vh;
  right: 2vw;
  font-size: clamp(280px, 30vw, 440px);
  opacity: 0.22;
  animation: totemIconFloatH 5.2s ease-in-out infinite alternate;
}

.totem-home__content {
  width: min(100%, 760px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  transform: none;
}

.totem-home__weather {
  position: absolute;
  top: calc(clamp(24px, 3vw, 42px) + var(--totem-safe-area-top));
  right: calc(clamp(24px, 3vw, 42px) + var(--totem-safe-area-right));
  width: min(29vw, 320px);
  min-width: 250px;
  padding: 0;
  color: #ffffff;
  display: grid;
  gap: 6px;
  --animate-duration: 760ms;
  --animate-delay: 460ms;
  opacity: 0.52;
}

.totem-home__weather-head,
.totem-home__weather-body,
.totem-home__weather-meta {
  display: flex;
  align-items: center;
}

.totem-home__weather-head {
  justify-content: space-between;
  gap: 12px;
}

.totem-home__weather-kicker {
  display: none;
  color: rgba(255, 255, 255, 0.56);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.totem-home__weather-location {
  display: none;
}

.totem-home__weather-body {
  justify-content: flex-end;
  gap: 0;
}

.totem-home__weather-main {
  min-width: 0;
  display: grid;
  justify-items: end;
}

.totem-home__weather-temp {
  font-size: clamp(2rem, 3.2vw, 2.55rem);
  font-weight: 800;
  line-height: 0.92;
  letter-spacing: -0.03em;
  color: rgba(255, 255, 255, 0.66);
  text-shadow: 0 4px 18px rgba(5, 20, 64, 0.12);
}

.totem-home__weather-summary {
  margin-top: 2px;
  color: rgba(255, 255, 255, 0.58);
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.28;
  text-align: right;
}

.totem-home__weather-meta {
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 6px;
}

.totem-home__weather-chip {
  min-height: auto;
  padding: 0;
  border-radius: 0;
  background: transparent;
  border: 0;
  color: rgba(255, 255, 255, 0.48);
  display: inline-flex;
  align-items: center;
  font-size: 0.72rem;
  font-weight: 600;
}

.totem-home__weather-updated {
  display: none;
}

.totem-home__weather[data-state="loading"] .totem-home__weather-temp,
.totem-home__weather[data-state="loading"] .totem-home__weather-summary,
.totem-home__weather[data-state="loading"] .totem-home__weather-chip,
.totem-home__weather[data-state="loading"] .totem-home__weather-updated {
  opacity: 0.88;
}

.totem-home__weather[data-state="loading"] .totem-home__weather-temp,
.totem-home__weather[data-state="loading"] .totem-home__weather-summary,
.totem-home__weather[data-state="loading"] .totem-home__weather-chip {
  position: relative;
  color: transparent;
  overflow: hidden;
}

.totem-home__weather[data-state="loading"] .totem-home__weather-temp::after,
.totem-home__weather[data-state="loading"] .totem-home__weather-summary::after,
.totem-home__weather[data-state="loading"] .totem-home__weather-chip::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0.08));
  transform: translateX(-100%);
  animation: totemWeatherShimmer 1.2s ease-in-out infinite;
}

.totem-home__weather[data-state="error"] {
  opacity: 0.56;
}

.totem-home__eyebrow {
  margin: 0 0 12px;
  color: rgba(255, 255, 255, 0.82);
  font-size: clamp(1.6rem, 3.8vw, 2.4rem);
  font-weight: 700;
  text-transform: uppercase;
  --animate-duration: 620ms;
  --animate-delay: 120ms;
}

.totem-home__eyebrow--attention {
  animation: totemEyebrowAttention 920ms cubic-bezier(0.22, 0.61, 0.36, 1);
}

.totem-home__title {
  margin: 14px 0 0;
  color: #ffffff;
  font-size: clamp(3.4rem, 11vw, 7.8rem);
  font-weight: 800;
  line-height: 0.92;
  --animate-duration: 760ms;
  --animate-delay: 220ms;
}

.totem-home__title--attention {
  animation: totemTitleAttention 960ms cubic-bezier(0.22, 0.61, 0.36, 1);
}

.totem-home__subtitle {
  width: min(100%, 620px);
  margin: clamp(46px, 6.8vw, 72px) 0 0;
  color: rgba(255, 255, 255, 0.86);
  font-size: clamp(1.1rem, 2.5vw, 1.55rem);
  font-weight: 500;
  line-height: 1.36;
  min-height: calc(clamp(1.1rem, 2.5vw, 1.55rem) * 2.9);
  display: grid;
  place-items: center;
  overflow: hidden;
}

.totem-home__pager--subtitle {
  position: static;
  transform: none;
  margin-top: 14px;
  justify-content: center;
  --animate-duration: 520ms;
  --animate-delay: 540ms;
}

.totem-home__subtitle-line {
  margin: 0;
  max-width: 100%;
  text-wrap: balance;
  will-change: transform, opacity;
}

.totem-home__subtitle-line--enter {
  animation: totemSubtitleEnter 560ms cubic-bezier(0.22, 0.61, 0.36, 1) both;
}

.totem-home__subtitle-line--exit {
  animation: totemSubtitleExit 520ms cubic-bezier(0.55, 0.06, 0.68, 0.19) both;
}

.totem-home__actions {
  width: min(100%, 760px);
  margin-top: clamp(24px, 3.8vh, 40px);
  display: grid;
  gap: clamp(18px, 2.4vw, 22px);
  --animate-duration: 620ms;
  --animate-delay: 620ms;
}

.totem-home__primary,
.totem-home__secondary {
  min-height: clamp(92px, 10.4vh, 118px);
  border: 0;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  text-decoration: none;
  text-align: center;
  cursor: pointer;
  touch-action: manipulation;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.totem-home__primary {
  width: 100%;
  padding: 0 clamp(24px, 5vw, 54px);
  background: #ffffff;
  color: var(--home-ink);
  box-shadow: 0 24px 52px rgba(4, 29, 95, 0.34);
  font-size: clamp(1.75rem, 4.4vw, 2.7rem);
  font-weight: 800;
  text-transform: uppercase;
  text-align: center;
  --animate-duration: 720ms;
  --animate-delay: 760ms;
}

.totem-home__primary .material-symbols-outlined {
  width: clamp(66px, 9vw, 88px);
  height: clamp(66px, 9vw, 88px);
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--home-cyan);
  color: #ffffff;
  font-size: clamp(38px, 5.8vw, 52px);
}

.totem-home__button-icon--spin {
  animation: totemButtonIconSpin 900ms cubic-bezier(0.22, 0.61, 0.36, 1);
}

.totem-home__button-icon--jump {
  animation: totemButtonIconJump 900ms cubic-bezier(0.22, 0.61, 0.36, 1);
}

.totem-home__button-icon--grow {
  animation: totemButtonIconGrow 900ms cubic-bezier(0.22, 0.61, 0.36, 1);
}

.totem-home__secondary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(14px, 2.2vw, 22px);
  margin-top: clamp(8px, 1.4vh, 12px);
}

.totem-home__secondary {
  padding: 0 clamp(18px, 3vw, 34px);
  border: 2px solid rgba(255, 255, 255, 0.72);
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22), 0 16px 32px rgba(3, 27, 80, 0.18);
  font-size: clamp(1.05rem, 2.15vw, 1.42rem);
  font-weight: 750;
  line-height: 1.16;
  text-align: center;
}

.totem-home__secondary:nth-child(1) {
  --animate-duration: 540ms;
  --animate-delay: 920ms;
}

.totem-home__secondary:nth-child(2) {
  --animate-duration: 540ms;
  --animate-delay: 1020ms;
}

.totem-home__secondary:nth-child(3) {
  --animate-duration: 540ms;
  --animate-delay: 1120ms;
}

.totem-home__secondary:nth-child(4) {
  --animate-duration: 540ms;
  --animate-delay: 1220ms;
}

.totem-home__secondary .material-symbols-outlined {
  flex: 0 0 auto;
  color: #bdf7ff;
  font-size: clamp(36px, 5vw, 50px);
}

.totem-home__secondary-text {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  text-align: center;
  line-height: 1.08;
}

.totem-home__secondary-title {
  font-size: inherit;
  font-weight: 750;
}

.totem-home__secondary-subtitle {
  font-size: 0.68em;
  font-weight: 600;
  opacity: 0.88;
  letter-spacing: 0.02em;
}

.totem-home__primary:hover,
.totem-home__primary:focus-visible,
.totem-home__secondary:hover,
.totem-home__secondary:focus-visible {
  transform: translateY(-2px);
}

.totem-home__primary:focus-visible,
.totem-home__secondary:focus-visible {
  outline: 4px solid rgba(255, 255, 255, 0.72);
  outline-offset: 5px;
}

.totem-home__secondary:hover,
.totem-home__secondary:focus-visible {
  background: rgba(255, 255, 255, 0.2);
  color: #ffffff;
}

.totem-home__pager {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.totem-home__pager span {
  width: clamp(7px, 0.9vw, 10px);
  height: clamp(7px, 0.9vw, 10px);
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.46);
  opacity: 0.82;
}

.totem-home__pager .is-active {
  background: rgba(255, 255, 255, 0.85);
  border-color: rgba(255, 255, 255, 0.85);
}

@keyframes totemHomeFloatA {
  from {
    transform: translate3d(-10vw, -5vh, 0) scale(0.88);
  }
  to {
    transform: translate3d(18vw, 10vh, 0) scale(1.14);
  }
}

@keyframes totemHomeFloatB {
  from {
    transform: translate3d(8vw, 8vh, 0) scale(0.94);
  }
  to {
    transform: translate3d(-16vw, -10vh, 0) scale(1.2);
  }
}

@keyframes totemPatternDrift {
  from {
    transform: translate3d(-4vw, 2vh, 0);
  }
  to {
    transform: translate3d(4vw, -3vh, 0);
  }
}

@keyframes totemWaveLineTop {
  from {
    transform: translate3d(-3vw, 1vh, 0) rotate(-8deg) scale(0.82);
  }
  to {
    transform: translate3d(4vw, 3vh, 0) rotate(6deg) scale(1.12);
  }
}

@keyframes totemWaveLineBottom {
  from {
    transform: translate3d(2vw, -2vh, 0) rotate(1deg) scale(0.66);
  }
  to {
    transform: translate3d(-4vw, 3vh, 0) rotate(14deg) scale(0.9);
  }
}

@keyframes totemIconFloatB {
  from {
    transform: translate3d(0, 0, 0) rotate(-14deg) scale(0.96);
  }
  to {
    transform: translate3d(2vw, -2vh, 0) rotate(-3deg) scale(1.04);
  }
}

@keyframes totemIconFloatC {
  from {
    transform: translate3d(0, 0, 0) rotate(-5deg) scale(0.96);
  }
  to {
    transform: translate3d(-2vw, 2vh, 0) rotate(6deg) scale(1.05);
  }
}

@keyframes totemIconFloatD {
  from {
    transform: translate3d(-1vw, -1vh, 0) rotate(-4deg) scale(0.96);
  }
  to {
    transform: translate3d(2vw, 2vh, 0) rotate(4deg) scale(1.04);
  }
}

@keyframes totemIconFloatE {
  from {
    transform: translate3d(-2vw, 1vh, 0) rotate(-12deg) scale(0.96);
  }
  to {
    transform: translate3d(3vw, -2vh, 0) rotate(3deg) scale(1.05);
  }
}

@keyframes totemIconFloatF {
  from {
    transform: translate3d(1vw, 1vh, 0) rotate(-8deg) scale(0.96);
  }
  to {
    transform: translate3d(-2vw, -2vh, 0) rotate(5deg) scale(1.04);
  }
}

@keyframes totemIconFloatG {
  from {
    transform: translate3d(0, 0, 0) rotate(-5deg) scale(0.96);
  }
  to {
    transform: translate3d(2vw, 2vh, 0) rotate(5deg) scale(1.06);
  }
}

@keyframes totemIconFloatH {
  from {
    transform: translate3d(0, 0, 0) rotate(6deg) scale(0.96);
  }
  to {
    transform: translate3d(-2vw, -2vh, 0) rotate(-4deg) scale(1.05);
  }
}

@keyframes totemWeatherShimmer {
  to {
    transform: translateX(100%);
  }
}

@keyframes totemSubtitleEnter {
  from {
    opacity: 0;
    transform: translate3d(62px, 0, 0);
  }
  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

@keyframes totemTitleAttention {
  0%,
  100% {
    transform: translate3d(0, 0, 0) scale(1);
    text-shadow: 0 0 0 rgba(255, 255, 255, 0);
  }
  24% {
    transform: translate3d(-4px, 0, 0) scale(1.015);
    text-shadow: 0 8px 20px rgba(255, 255, 255, 0.14);
  }
  52% {
    transform: translate3d(4px, 0, 0) scale(1.02);
    text-shadow: 0 12px 26px rgba(255, 255, 255, 0.18);
  }
  74% {
    transform: translate3d(-2px, 0, 0) scale(1.01);
    text-shadow: 0 6px 16px rgba(255, 255, 255, 0.1);
  }
}

@keyframes totemEyebrowAttention {
  0%,
  100% {
    transform: translate3d(0, 0, 0) scale(1);
    letter-spacing: 0;
    opacity: 1;
  }
  30% {
    transform: translate3d(-6px, 0, 0) scale(1.04);
    letter-spacing: 0.04em;
    opacity: 0.92;
  }
  60% {
    transform: translate3d(6px, 0, 0) scale(1.06);
    letter-spacing: 0.06em;
    opacity: 1;
  }
}

@keyframes totemButtonIconSpin {
  0%,
  100% {
    transform: rotate(0deg) scale(1);
  }
  35% {
    transform: rotate(20deg) scale(1.08);
  }
  65% {
    transform: rotate(-18deg) scale(1.12);
  }
}

@keyframes totemButtonIconJump {
  0%,
  100% {
    transform: translateY(0) scale(1);
  }
  35% {
    transform: translateY(-10px) scale(1.06);
  }
  60% {
    transform: translateY(0) scale(1.1);
  }
}

@keyframes totemButtonIconGrow {
  0%,
  100% {
    transform: scale(1);
    filter: brightness(1);
  }
  45% {
    transform: scale(1.22);
    filter: brightness(1.15);
  }
  70% {
    transform: scale(1.08);
    filter: brightness(1.08);
  }
}

@keyframes totemSubtitleExit {
  from {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
  to {
    opacity: 0;
    transform: translate3d(-62px, 0, 0);
  }
}

.global-session-exit-btn {
  position: static;
  z-index: 1;
  min-height: var(--ui-action-btn-height);
  padding: 0 16px;
  border-radius: 25px;
  border: 1px solid rgba(0, 0, 0, 0.14);
  background: #ffffff;
  color: #202124;
  font-family: "Google Sans", Roboto, Arial, sans-serif;
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.00625rem;
  line-height: 1.25rem;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  box-shadow: 0 1px 5px rgba(0, 0, 0, 0.2);
}

.global-session-exit-btn[hidden] {
  display: none !important;
}

#top-right-container .global-session-exit-btn {
  margin-top: 12px;
  min-width: 210px;
  justify-content: center;
}

.global-session-exit-btn:hover,
.global-session-exit-btn:focus {
  background: #f8f9fa;
  color: #202124;
}

@media (orientation: portrait) {
  .totem-home {
    padding:
      calc(clamp(34px, 6vw, 76px) + var(--totem-safe-area-top))
      calc(clamp(22px, 5vw, 56px) + var(--totem-safe-area-right))
      calc(clamp(34px, 6vw, 76px) + var(--totem-safe-area-bottom))
      calc(clamp(22px, 5vw, 56px) + var(--totem-safe-area-left));
    align-items: center;
  }

  .totem-home__content {
    width: 100%;
    min-height: auto;
    justify-content: center;
    transform: none;
  }

  .totem-home__weather {
    top: calc(clamp(18px, 3vw, 28px) + var(--totem-safe-area-top));
    right: calc(clamp(18px, 3vw, 28px) + var(--totem-safe-area-right));
    width: min(42vw, 300px);
    min-width: 230px;
  }

  .totem-home__actions {
    margin-top: clamp(24px, 4vh, 56px);
  }
}

@media (max-width: 720px) {
  .totem-home {
    padding:
      calc(22px + var(--totem-safe-area-top))
      calc(16px + var(--totem-safe-area-right))
      calc(26px + var(--totem-safe-area-bottom))
      calc(16px + var(--totem-safe-area-left));
    justify-content: flex-start;
  }

  .totem-home__weather {
    display: none !important;
  }

  .totem-home__icon {
    font-size: clamp(340px, 96vw, 620px);
    opacity: 0.16;
  }

  .totem-home__content {
    width: 100%;
    max-width: 560px;
    min-height: 100%;
    justify-content: flex-start;
    padding-top: 28px;
  }

  .totem-home__eyebrow {
    margin-bottom: 10px;
    font-size: clamp(1rem, 4.4vw, 1.3rem);
    letter-spacing: 0.08em;
  }

  .totem-home__title {
    font-size: clamp(2.35rem, 12.5vw, 3.6rem);
    line-height: 0.94;
  }

  .totem-home__subtitle {
    width: min(100%, 500px);
    margin-top: 22px;
    min-height: 3.2em;
    font-size: clamp(0.98rem, 4.3vw, 1.12rem);
    line-height: 1.42;
  }

  .totem-home__pager--subtitle {
    margin-top: 10px;
  }

  .totem-home__actions {
    width: 100%;
    margin-top: 20px;
    gap: 14px;
  }

  .totem-home__primary {
    min-height: 76px;
    padding: 12px 18px;
    border-radius: 24px;
    justify-content: center;
    font-size: clamp(1.2rem, 5.8vw, 1.55rem);
    line-height: 1.08;
  }

  .totem-home__primary .material-symbols-outlined {
    width: 56px;
    height: 56px;
    font-size: 30px;
  }

  .totem-home__secondary-grid {
    grid-template-columns: 1fr;
    gap: 12px;
    margin-top: 0;
  }

  .totem-home__secondary {
    min-height: 74px;
    padding: 12px 14px;
    border-radius: 22px;
    justify-content: center;
    text-align: center;
    font-size: 1rem;
    gap: 12px;
  }

  .totem-home__secondary .material-symbols-outlined {
    font-size: 30px;
  }

  .totem-home__icon--route {
    right: -2vw;
    bottom: 2vh;
  }

  .totem-home__icon--water {
    left: 0vw;
    bottom: 2vh;
  }

  .totem-home__icon--city {
    left: 0vw;
    top: 24vh;
    font-size: clamp(420px, 86vw, 620px);
  }

  .totem-home__icon--plane {
    top: 8vh;
    left: 20vw;
    font-size: clamp(320px, 66vw, 470px);
  }

  .totem-home__icon--compass {
    right: 4vw;
    bottom: 2vh;
    font-size: clamp(420px, 82vw, 620px);
  }

  .totem-home__icon--mid-left {
    top: 46vh;
    left: 1vw;
    font-size: clamp(220px, 42vw, 320px);
  }

  .totem-home__icon--mid-right {
    top: 48vh;
    right: 1vw;
    font-size: clamp(220px, 42vw, 320px);
  }
}

@media (max-width: 480px) {
  .totem-home {
    padding:
      calc(18px + var(--totem-safe-area-top))
      calc(14px + var(--totem-safe-area-right))
      calc(22px + var(--totem-safe-area-bottom))
      calc(14px + var(--totem-safe-area-left));
  }

  .totem-home__content {
    padding-top: 18px;
  }

  .totem-home__subtitle {
    margin-top: 18px;
    min-height: 3.4em;
    font-size: 0.96rem;
  }

  .totem-home__primary {
    min-height: 72px;
    padding: 12px 16px;
    font-size: 1.08rem;
    gap: 12px;
  }

  .totem-home__primary .material-symbols-outlined {
    width: 50px;
    height: 50px;
    font-size: 27px;
  }

  .totem-home__secondary {
    min-height: 70px;
    padding: 12px;
    font-size: 0.95rem;
  }

  .totem-home__secondary-title {
    font-size: 0.98rem;
  }

  .totem-home__secondary-subtitle {
    font-size: 0.72rem;
  }
}

@media (max-width: 768px) {
  .history-modal__header {
    align-items: flex-start;
    gap: 10px;
    padding: 12px 14px 8px;
  }

  .history-modal__header-copy {
    width: 100%;
  }

  .history-modal__eyebrow {
    font-size: 0.72rem;
    letter-spacing: 0.14em;
  }

  .history-modal__header strong {
    font-size: clamp(0.96rem, 4.2vw, 1.18rem);
    line-height: 1.06;
  }

  .history-modal__close {
    min-height: 38px;
    padding: 0 10px;
    font-size: 0.84rem;
    align-self: flex-end;
  }

  .history-modal__selector-shell {
    top: calc(68px + var(--totem-safe-area-top));
    grid-template-columns: 1fr;
    gap: 8px;
    padding: 0 12px;
  }

  .history-modal__side-control {
    display: none;
  }

  .history-modal__nav {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
    width: 100%;
    max-width: none;
  }

  .history-modal__nav-item {
    min-height: 48px;
    padding: 8px 6px;
    border-radius: 14px;
  }

  .history-modal__nav-label {
    font-size: 0.7rem;
    line-height: 1.08;
    white-space: normal;
    text-wrap: balance;
  }

  .history-modal__audio-toggle {
    top: calc(124px + var(--totem-safe-area-top));
    right: calc(12px + var(--totem-safe-area-right));
    min-height: 36px;
    padding: 0 9px;
    font-size: 0.78rem;
  }

  .history-modal__story {
    padding:
      calc(168px + var(--totem-safe-area-top))
      16px
      calc(20px + var(--totem-safe-area-bottom));
  }

  .history-modal__story-head {
    width: min(100%, 100vw - 32px);
    gap: 4px;
  }

  .history-modal__story-kicker {
    font-size: 0.72rem;
    letter-spacing: 0.14em;
  }

  .history-modal__story-title {
    font-size: clamp(1.42rem, 6.6vw, 2rem);
    line-height: 1;
  }

  .history-modal__story-subtitle {
    width: 100%;
    max-width: none;
    font-size: clamp(0.86rem, 3.5vw, 0.98rem);
    line-height: 1.34;
  }

  .history-modal__crawl-viewport {
    width: min(100%, 100vw - 32px);
    margin-top: 10px;
    perspective: none;
    mask-image: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.94) 7%, rgba(0, 0, 0, 0.98) 82%, transparent 100%);
  }

  .history-modal__crawl {
    width: 100%;
    padding-top: 18%;
    transform-origin: center top;
    animation-name: history-crawl-up-mobile;
    animation-duration: calc(var(--history-crawl-duration) * 1.22);
  }

  .history-modal__crawl p {
    margin-bottom: 18px;
    padding: 0 6px;
    font-size: clamp(1.08rem, 4.6vw, 1.34rem);
    line-height: 1.38;
    text-wrap: pretty;
  }

  #history-modal-stage[data-history-id="dores-do-rio-preto-sede"] .history-modal__story {
    padding:
      calc(168px + var(--totem-safe-area-top))
      16px
      calc(20px + var(--totem-safe-area-bottom));
  }

  #history-modal-stage[data-history-id="dores-do-rio-preto-sede"] .history-modal__story-head,
  #history-modal-stage[data-history-id="dores-do-rio-preto-sede"] .history-modal__crawl-viewport {
    width: min(100%, 100vw - 32px);
  }
}

@media (max-width: 480px) {
  .history-modal__header {
    padding: 10px 12px 6px;
  }

  .history-modal__selector-shell {
    top: calc(62px + var(--totem-safe-area-top));
    padding: 0 10px;
  }

  .history-modal__nav {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .history-modal__nav-item {
    min-height: 44px;
    padding: 8px 6px;
  }

  .history-modal__nav-label {
    font-size: 0.68rem;
  }

  .history-modal__audio-toggle {
    top: calc(114px + var(--totem-safe-area-top));
    right: calc(10px + var(--totem-safe-area-right));
  }

  .history-modal__story {
    padding:
      calc(156px + var(--totem-safe-area-top))
      18px
      calc(18px + var(--totem-safe-area-bottom));
  }

  .history-modal__story-head,
  .history-modal__crawl-viewport,
  #history-modal-stage[data-history-id="dores-do-rio-preto-sede"] .history-modal__story-head,
  #history-modal-stage[data-history-id="dores-do-rio-preto-sede"] .history-modal__crawl-viewport {
    width: min(100%, 100vw - 36px);
  }

  .history-modal__story-title {
    font-size: clamp(1.28rem, 6.8vw, 1.7rem);
  }

  .history-modal__story-subtitle {
    font-size: 0.82rem;
  }

  .history-modal__crawl {
    padding-top: 14%;
    animation-duration: calc(var(--history-crawl-duration) * 1.3);
  }

  .history-modal__crawl p {
    padding: 0 8px;
    font-size: clamp(0.98rem, 4.7vw, 1.18rem);
    line-height: 1.34;
  }

  #history-modal-stage[data-history-id="dores-do-rio-preto-sede"] .history-modal__story {
    padding:
      calc(156px + var(--totem-safe-area-top))
      18px
      calc(18px + var(--totem-safe-area-bottom));
  }
}

@keyframes history-crawl-up-mobile {
  from {
    transform: translateY(4%);
  }
  to {
    transform: translateY(-104%);
  }
}

@media (max-height: 680px) and (orientation: landscape) {
  .totem-home__weather {
    top: calc(16px + var(--totem-safe-area-top));
    right: calc(16px + var(--totem-safe-area-right));
    width: min(26vw, 280px);
    gap: 4px;
  }

  .totem-home__content {
    transform: none;
  }

  .totem-home__actions {
    margin-top: 28px;
  }

  .totem-home__primary {
    min-height: 88px;
    padding: 0 42px;
    gap: 22px;
  }

  .totem-home__primary .material-symbols-outlined {
    width: 74px;
    height: 74px;
    font-size: 40px;
  }

  .totem-home__subtitle {
    display: none;
  }

  .totem-home__pager--subtitle {
    margin-top: 12px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .totem-home,
  .map-stage,
  .totem-home__primary,
  .totem-home__secondary {
    transition: none;
  }

  .totem-home::before,
  .totem-home::after {
    animation: none;
  }

  .totem-home__pattern,
  .totem-home__line,
  .totem-home__icon {
    animation: none;
  }
}
