:root {
  --tr-showcase-radius: 24px;
}

.tr-world-showcase,
.tr-resource-showcase {
  scroll-margin-top: 28px;
}

.tr-world-showcase {
  margin: 74px 0 64px;
}

.tr-world-intro {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(310px, 0.85fr);
  align-items: center;
  gap: clamp(32px, 6vw, 78px);
  overflow: hidden;
  padding: clamp(38px, 6vw, 72px);
  border: 1px solid var(--tr-border);
  border-radius: var(--tr-showcase-radius);
  background:
    radial-gradient(circle at 91% 20%, color-mix(in srgb, var(--tr-secondary) 18%, transparent), transparent 30%),
    radial-gradient(circle at 8% 92%, color-mix(in srgb, var(--tr-primary) 21%, transparent), transparent 34%),
    linear-gradient(145deg, #111722, #090e15);
  box-shadow: 0 28px 82px rgba(0, 0, 0, 0.3);
}

.tr-world-intro::before {
  content: "EARTH";
  position: absolute;
  z-index: -1;
  right: -0.04em;
  bottom: -0.25em;
  color: rgba(255, 255, 255, 0.022);
  font-family: Impact, Haettenschweiler, "Arial Narrow Bold", sans-serif;
  font-size: clamp(9rem, 24vw, 20rem);
  line-height: 1;
  letter-spacing: 0.015em;
}

.tr-world-intro h2,
.tr-resource-intro h2 {
  margin: 0;
  color: #fff;
  font-size: clamp(2.35rem, 5.7vw, 5rem);
  line-height: 0.98;
  letter-spacing: -0.045em;
}

.tr-world-intro h2 span {
  color: var(--tr-primary);
}

.tr-world-intro-copy > p:not(.tr-eyebrow),
.tr-resource-intro > div > p:not(.tr-eyebrow) {
  max-width: 760px;
  margin: 22px 0 0;
  color: var(--tr-muted);
  font-size: 1.06rem;
  line-height: 1.72;
}

.tr-world-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 11px;
  margin-top: 29px;
}

.tr-world-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 11px;
}

.tr-world-facts span {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 118px;
  padding: 21px;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.045);
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.035);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

.tr-world-facts span:nth-child(2),
.tr-world-facts span:nth-child(3) {
  border-color: color-mix(in srgb, var(--tr-secondary) 24%, var(--tr-border));
}

.tr-world-facts strong {
  color: var(--tr-secondary);
  font-size: clamp(1.35rem, 3vw, 2.1rem);
  line-height: 1;
}

.tr-world-facts span:nth-child(2n + 1) strong {
  color: var(--tr-primary);
}

.tr-world-facts small {
  margin-top: 8px;
  color: var(--tr-muted);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.tr-gallery-shell {
  overflow: hidden;
  margin-top: 20px;
  padding: 25px 0 18px;
  border: 1px solid var(--tr-border);
  border-radius: var(--tr-showcase-radius);
  background:
    linear-gradient(rgba(255, 255, 255, 0.018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.018) 1px, transparent 1px),
    #0b1018;
  background-size: 34px 34px, 34px 34px, auto;
  box-shadow: 0 25px 72px rgba(0, 0, 0, 0.25);
}

.tr-gallery-toolbar,
.tr-gallery-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  padding-right: clamp(20px, 4vw, 42px);
  padding-left: clamp(20px, 4vw, 42px);
}

.tr-gallery-kicker {
  margin: 0 0 5px;
  color: var(--tr-secondary) !important;
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.tr-gallery-toolbar h3 {
  margin: 0;
  color: #fff;
  font-size: clamp(1.45rem, 3.5vw, 2.45rem);
  letter-spacing: -0.025em;
}

.tr-gallery-controls {
  display: flex;
  align-items: center;
  gap: 7px;
}

.tr-gallery-controls button,
.tr-gallery-edge,
.tr-gallery-expand,
.tr-lightbox-close {
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(17, 23, 34, 0.86);
  color: #fff;
  cursor: pointer;
  transition: transform 0.16s ease, border-color 0.16s ease, background 0.16s ease;
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

.tr-gallery-controls button {
  width: 42px;
  height: 42px;
  border-radius: 10px;
}

.tr-gallery-controls button:hover,
.tr-gallery-expand:hover,
.tr-lightbox-close:hover {
  border-color: var(--tr-secondary);
  background: color-mix(in srgb, var(--tr-secondary) 15%, #111722);
  color: #fff;
  transform: translateY(-2px);
}

.tr-gallery-counter {
  min-width: 73px;
  color: #788397;
  font-variant-numeric: tabular-nums;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-align: center;
}

.tr-gallery-counter strong {
  color: var(--tr-primary);
}

.tr-gallery-viewport {
  position: relative;
  overflow: hidden;
  margin-top: 21px;
  padding: 2px clamp(20px, 6vw, 76px) 10px;
  touch-action: pan-y;
}

.tr-gallery-viewport:focus-visible {
  outline: 2px solid var(--tr-secondary);
  outline-offset: -4px;
}

.tr-gallery-track {
  position: relative;
  width: min(100%, 1100px);
  aspect-ratio: 16 / 9;
  margin: 0 auto;
}

.tr-gallery-slide {
  position: absolute;
  isolation: isolate;
  inset: 0;
  overflow: hidden;
  width: 100%;
  height: 100%;
  margin: 0;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 19px;
  background: #080b10;
  box-shadow: 0 22px 55px rgba(0, 0, 0, 0.34);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateX(18px) scale(0.992);
  transition: opacity 0.42s ease, transform 0.42s ease, visibility 0s linear 0.42s;
}

.tr-gallery-slide.is-active {
  border-color: color-mix(in srgb, var(--tr-primary) 44%, rgba(255, 255, 255, 0.13));
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: scale(1);
  transition-delay: 0s;
}

.tr-resource-tile::after {
  content: "";
  position: absolute;
  z-index: 1;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, transparent 48%, rgba(5, 8, 13, 0.2) 62%, rgba(5, 8, 13, 0.94) 100%);
}

.tr-gallery-slide img,
.tr-resource-tile img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease, filter 0.6s ease;
}

.tr-resource-tile:hover img {
  filter: saturate(1.08) contrast(1.025);
  transform: scale(1.022);
}

.tr-gallery-slide img {
  filter: none;
}

.tr-gallery-slide figcaption {
  position: absolute;
  z-index: 2;
  right: clamp(18px, 3vw, 34px);
  bottom: clamp(17px, 3vw, 32px);
  left: clamp(18px, 3vw, 34px);
  display: grid;
  grid-template-columns: auto 1fr;
  column-gap: 13px;
  align-items: center;
  width: fit-content;
  max-width: calc(100% - clamp(36px, 6vw, 68px));
  padding: 11px 15px 11px 11px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
  background: rgba(5, 8, 13, 0.72);
  color: #fff;
  text-shadow: 0 3px 18px rgba(0, 0, 0, 0.9);
  -webkit-backdrop-filter: blur(9px);
  backdrop-filter: blur(9px);
}

.tr-gallery-slide figcaption span {
  grid-row: 1 / span 2;
  display: grid;
  place-items: center;
  width: 39px;
  height: 39px;
  border: 1px solid color-mix(in srgb, var(--tr-primary) 62%, rgba(255, 255, 255, 0.2));
  border-radius: 50%;
  background: rgba(7, 10, 15, 0.64);
  color: var(--tr-primary);
  font-size: 0.72rem;
  font-weight: 900;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

.tr-gallery-slide figcaption strong {
  font-size: clamp(1.15rem, 2.5vw, 1.85rem);
  line-height: 1.1;
}

.tr-gallery-slide figcaption small {
  margin-top: 4px;
  color: #c6cedb;
  font-size: clamp(0.7rem, 1.4vw, 0.87rem);
}

.tr-gallery-expand {
  position: absolute;
  z-index: 3;
  top: 16px;
  right: 16px;
  width: 43px;
  height: 43px;
  border-radius: 11px;
}

.tr-gallery-edge {
  position: absolute;
  z-index: 4;
  top: 50%;
  width: 52px;
  height: 72px;
  border-radius: 14px;
  font-size: 1.2rem;
  transform: translateY(-50%);
}

.tr-gallery-edge--prev {
  left: 16px;
}

.tr-gallery-edge--next {
  right: 16px;
}

.tr-gallery-edge:hover {
  border-color: var(--tr-secondary);
  background: rgba(10, 15, 22, 0.94);
  color: #fff;
  transform: translateY(-50%) scale(1.05);
}

.tr-gallery-footer {
  margin-top: 8px;
}

.tr-gallery-footer p {
  margin: 0;
  color: #7f899a;
  font-size: 0.75rem;
}

.tr-gallery-footer p i {
  margin-right: 5px;
  color: var(--tr-secondary);
}

.tr-gallery-progress {
  overflow: hidden;
  flex: 1;
  max-width: 520px;
  height: 3px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}

.tr-gallery-progress > span {
  display: block;
  width: calc(100% / 19);
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--tr-primary), var(--tr-secondary));
  box-shadow: 0 0 18px color-mix(in srgb, var(--tr-primary) 46%, transparent);
  transition: width 0.32s ease;
}

.tr-resource-showcase {
  margin: 64px 0 78px;
  padding: clamp(28px, 5vw, 54px);
  border: 1px solid var(--tr-border);
  border-radius: var(--tr-showcase-radius);
  background:
    radial-gradient(circle at 8% 8%, color-mix(in srgb, var(--tr-secondary) 10%, transparent), transparent 30%),
    linear-gradient(145deg, #101620, #0a0f17);
  box-shadow: 0 25px 72px rgba(0, 0, 0, 0.24);
}

.tr-resource-intro {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(300px, 0.85fr);
  align-items: end;
  gap: clamp(28px, 5vw, 65px);
  margin-bottom: 27px;
}

.tr-resource-intro h2 {
  font-size: clamp(2rem, 4.5vw, 3.8rem);
}

.tr-resource-pills {
  display: grid;
  gap: 8px;
}

.tr-resource-pills span {
  display: grid;
  grid-template-columns: 34px auto 1fr;
  align-items: center;
  gap: 9px;
  min-height: 52px;
  padding: 10px 14px;
  border: 1px solid var(--tr-border);
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.035);
  color: var(--tr-muted);
  font-size: 0.78rem;
}

.tr-resource-pills i {
  color: var(--tr-primary);
  font-size: 1rem;
  text-align: center;
}

.tr-resource-pills span:nth-child(even) i {
  color: var(--tr-secondary);
}

.tr-resource-pills strong {
  color: #fff;
  font-size: 0.9rem;
}

.tr-resource-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-auto-rows: clamp(190px, 21vw, 260px);
  gap: 10px;
}

.tr-resource-tile {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-width: 0;
  min-height: 0;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  background: #080b10;
  color: #fff;
  cursor: zoom-in;
  font: inherit;
  text-align: left;
}

.tr-resource-tile:hover {
  border-color: color-mix(in srgb, var(--tr-secondary) 48%, var(--tr-border));
}

.tr-resource-tile--featured {
  grid-column: span 2;
  grid-row: span 2;
}

.tr-resource-tile--wide {
  grid-column: span 2;
}

.tr-resource-tile--end {
  grid-column: 1 / -1;
}

.tr-resource-tile > span {
  position: absolute;
  z-index: 2;
  right: 16px;
  bottom: 15px;
  left: 16px;
  display: flex;
  flex-direction: column;
  gap: 3px;
  text-shadow: 0 3px 14px rgba(0, 0, 0, 0.9);
}

.tr-resource-tile small {
  color: var(--tr-secondary);
  font-size: 0.66rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.tr-resource-tile strong {
  font-size: 1rem;
  line-height: 1.15;
}

.tr-resource-tile--featured strong,
.tr-resource-tile--end strong {
  font-size: clamp(1.15rem, 2.4vw, 1.75rem);
}

.tr-media-lightbox {
  position: fixed;
  z-index: 1000000;
  inset: 0;
  display: grid;
  place-items: center;
  padding: clamp(16px, 4vw, 48px);
  background: rgba(3, 5, 8, 0.92);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}

.tr-media-lightbox[hidden] {
  display: none !important;
}

.tr-media-lightbox figure {
  overflow: hidden;
  width: min(1500px, 96vw);
  max-height: 91vh;
  margin: 0;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 18px;
  background: #080b10;
  box-shadow: 0 35px 100px rgba(0, 0, 0, 0.68);
}

.tr-media-lightbox img {
  display: block;
  width: 100%;
  max-height: calc(91vh - 58px);
  object-fit: contain;
}

.tr-media-lightbox figcaption {
  min-height: 54px;
  padding: 16px 20px;
  color: #fff;
  font-weight: 850;
}

.tr-lightbox-close {
  position: fixed;
  z-index: 2;
  top: 22px;
  right: 22px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
}

body.tr-lightbox-open {
  overflow: hidden;
}

.tr-tour-intro::after {
  content: "07";
}

@media (max-width: 990px) {
  .tr-world-intro,
  .tr-resource-intro {
    grid-template-columns: 1fr;
  }

  .tr-world-facts {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .tr-world-facts span {
    min-height: 104px;
    padding: 17px;
  }

  .tr-resource-pills {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .tr-resource-pills span {
    grid-template-columns: 28px auto 1fr;
    line-height: 1.35;
  }
}

@media (max-width: 768px) {
  :root {
    --tr-showcase-radius: 17px;
  }

  .tr-world-showcase {
    margin-top: 52px;
  }

  .tr-world-intro,
  .tr-resource-showcase {
    padding: 31px 24px;
  }

  .tr-world-actions,
  .tr-world-actions .tr-button {
    width: 100%;
  }

  .tr-world-facts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .tr-gallery-toolbar {
    align-items: flex-end;
  }

  .tr-gallery-controls {
    flex-wrap: wrap;
    justify-content: flex-end;
  }

  .tr-gallery-counter {
    width: 100%;
    text-align: right;
  }

  .tr-gallery-viewport {
    padding-right: 18px;
    padding-left: 18px;
  }

  .tr-gallery-footer {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  .tr-gallery-progress {
    width: 100%;
    max-width: none;
  }

  .tr-resource-pills {
    grid-template-columns: 1fr;
  }

  .tr-resource-pills span {
    grid-template-columns: 32px auto 1fr;
  }

  .tr-resource-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-auto-rows: 220px;
  }

  .tr-resource-tile--featured,
  .tr-resource-tile--wide,
  .tr-resource-tile--end {
    grid-column: span 2;
  }

  .tr-resource-tile--featured {
    grid-row: span 2;
  }
}

@media (max-width: 560px) {
  .tr-world-intro,
  .tr-resource-showcase {
    padding: 28px 20px;
  }

  .tr-world-intro h2,
  .tr-resource-intro h2 {
    font-size: clamp(2rem, 12vw, 3.15rem);
  }

  .tr-world-facts span {
    min-height: 94px;
    padding: 14px;
  }

  .tr-world-facts strong {
    font-size: 1.3rem;
  }

  .tr-gallery-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .tr-gallery-controls {
    justify-content: flex-start;
  }

  .tr-gallery-counter {
    width: auto;
    margin-right: auto;
    text-align: left;
  }

  .tr-gallery-slide {
    border-radius: 14px;
  }

  .tr-gallery-slide figcaption {
    right: 14px;
    bottom: 13px;
    left: 14px;
    column-gap: 9px;
  }

  .tr-gallery-slide figcaption span {
    width: 32px;
    height: 32px;
  }

  .tr-gallery-slide figcaption small {
    display: none;
  }

  .tr-gallery-expand {
    top: 10px;
    right: 10px;
    width: 38px;
    height: 38px;
  }

  .tr-gallery-edge {
    width: 42px;
    height: 58px;
    border-radius: 11px;
  }

  .tr-gallery-edge--prev {
    left: 10px;
  }

  .tr-gallery-edge--next {
    right: 10px;
  }

  .tr-resource-grid {
    grid-template-columns: 1fr;
    grid-auto-rows: 230px;
  }

  .tr-resource-tile--featured,
  .tr-resource-tile--wide,
  .tr-resource-tile--end {
    grid-column: span 1;
    grid-row: span 1;
  }

  .tr-resource-tile--featured {
    min-height: 330px;
  }

  .tr-lightbox-close {
    top: 12px;
    right: 12px;
  }
}
