:root {
  --ink: #111210;
  --paper: #f4f0e8;
  --warm: #d8b678;
  --line: rgba(255, 255, 255, 0.22);
  --font-display: Georgia, "Times New Roman", serif;
  --font-sans: Arial, Helvetica, sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  min-height: 100%;
  margin: 0;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--font-sans), Arial, sans-serif;
}

body {
  overflow: hidden;
}

button {
  color: inherit;
  font: inherit;
}

button:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 4px;
}

[hidden] {
  display: none !important;
}

.intro {
  position: relative;
  width: 100vw;
  height: 100svh;
  min-height: 620px;
  overflow: hidden;
  background: #0b0d0f;
}

.intro-image {
  position: absolute;
  inset: -3%;
  width: 106%;
  height: 106%;
  object-fit: cover;
  object-position: center 44%;
  animation: intro-drift 16s ease-out both;
}

@keyframes intro-drift {
  from { transform: scale(1.08); }
  to { transform: scale(1); }
}

.intro-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(7, 9, 10, 0.92) 0%, rgba(7, 9, 10, 0.64) 38%, rgba(7, 9, 10, 0.08) 72%),
    linear-gradient(0deg, rgba(7, 9, 10, 0.7) 0%, transparent 38%),
    linear-gradient(180deg, rgba(7, 9, 10, 0.5) 0%, transparent 24%);
}

.intro-header,
.tour-header {
  position: absolute;
  z-index: 20;
  top: 0;
  left: 0;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 34px 44px;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 13px;
  line-height: 1;
}

.wordmark-number {
  padding-right: 13px;
  border-right: 1px solid rgba(255, 255, 255, 0.45);
  font-family: var(--font-display), Georgia, serif;
  font-size: 36px;
  letter-spacing: -0.04em;
}

.wordmark-address {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.wordmark-address small {
  color: rgba(255, 255, 255, 0.62);
  font-size: 8px;
  font-weight: 600;
  letter-spacing: 0.28em;
}

.intro-location {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.28em;
  text-transform: uppercase;
}

.intro-copy {
  position: absolute;
  z-index: 5;
  top: 50%;
  left: clamp(32px, 7vw, 120px);
  width: min(680px, 49vw);
  transform: translateY(-46%);
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 20px;
  color: var(--warm);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.3em;
  text-transform: uppercase;
}

.eyebrow::before {
  width: 34px;
  height: 1px;
  background: currentColor;
  content: "";
}

.intro h1 {
  margin: 0;
  font-family: var(--font-display), Georgia, serif;
  font-size: clamp(64px, 8.2vw, 136px);
  font-weight: 500;
  letter-spacing: -0.055em;
  line-height: 0.78;
}

.intro-description {
  max-width: 520px;
  margin: 30px 0 32px 4px;
  color: rgba(255, 255, 255, 0.74);
  font-size: clamp(13px, 1vw, 16px);
  font-weight: 500;
  line-height: 1.75;
}

.start-button {
  display: inline-flex;
  align-items: center;
  gap: 15px;
  min-height: 54px;
  padding: 7px 24px 7px 8px;
  border: 1px solid rgba(255, 255, 255, 0.36);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(14px);
  cursor: pointer;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  transition: background 220ms ease, transform 220ms ease;
}

.start-button:hover {
  background: rgba(255, 255, 255, 0.19);
  transform: translateY(-2px);
}

.start-icon {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border-radius: 50%;
  background: var(--paper);
  color: #111;
  font-size: 11px;
  text-indent: 2px;
}

.intro-hint {
  display: inline-block;
  margin: 0 0 0 15px;
  color: rgba(255, 255, 255, 0.44);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.intro-specs {
  position: absolute;
  z-index: 5;
  right: 44px;
  bottom: 36px;
  display: flex;
  gap: 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(7, 9, 10, 0.2);
  backdrop-filter: blur(10px);
}

.intro-specs span {
  padding: 15px 22px;
  border-right: 1px solid var(--line);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.intro-specs span:last-child {
  border-right: 0;
}

.tour {
  position: relative;
  display: grid;
  width: 100vw;
  height: 100svh;
  min-height: 660px;
  grid-template-rows: minmax(0, 1fr) 114px;
  overflow: hidden;
  isolation: isolate;
  background: #111310;
}

.ambient-background,
.ambient-shade {
  position: absolute;
  z-index: -2;
  inset: -40px;
}

.ambient-background {
  background-position: center;
  background-size: cover;
  filter: blur(38px) saturate(0.7);
  opacity: 0.35;
  transform: scale(1.08);
  transition: background-image 500ms ease;
}

.ambient-shade {
  z-index: -1;
  background:
    radial-gradient(circle at center, transparent 0%, rgba(8, 9, 8, 0.18) 46%, rgba(8, 9, 8, 0.94) 100%),
    rgba(8, 9, 8, 0.62);
}

.tour-header {
  padding: 22px 30px;
  pointer-events: none;
}

.wordmark-button {
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  pointer-events: auto;
  text-align: left;
}

.tour-tools {
  display: flex;
  gap: 8px;
  pointer-events: auto;
}

.tool-button {
  display: flex;
  width: 48px;
  height: 48px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 50%;
  background: rgba(10, 11, 10, 0.34);
  backdrop-filter: blur(14px);
  cursor: pointer;
  transition: background 180ms ease, border-color 180ms ease;
}

.tool-button:hover,
.tool-button.active {
  border-color: rgba(255, 255, 255, 0.64);
  background: rgba(255, 255, 255, 0.14);
}

.tool-button span {
  font-family: Georgia, serif;
  font-size: 15px;
  font-style: italic;
  line-height: 1;
}

.tool-button em {
  font-size: 6px;
  font-style: normal;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.tool-button .fullscreen-icon {
  font-family: Arial, sans-serif;
  font-style: normal;
  transform: rotate(45deg);
}

.tour-stage {
  min-height: 0;
  padding: 78px 32px 18px;
}

.image-frame {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: #161815;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.35);
}

.tour-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  animation: photo-enter 720ms cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

@keyframes photo-enter {
  from { opacity: 0; transform: scale(1.025); }
  to { opacity: 1; transform: scale(1); }
}

.image-vignette {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(3, 4, 3, 0.76) 0%, rgba(3, 4, 3, 0.08) 33%, transparent 56%),
    linear-gradient(0deg, rgba(3, 4, 3, 0.55) 0%, transparent 24%);
  pointer-events: none;
}

.nav-button {
  position: absolute;
  z-index: 3;
  top: 50%;
  display: grid;
  width: 52px;
  height: 52px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 50%;
  background: rgba(8, 9, 8, 0.26);
  backdrop-filter: blur(12px);
  cursor: pointer;
  font-size: 20px;
  transform: translateY(-50%);
  transition: background 180ms ease, transform 180ms ease;
}

.nav-button:hover {
  background: rgba(255, 255, 255, 0.18);
}

.nav-previous {
  left: 20px;
}

.nav-next {
  right: 20px;
}

.room-details {
  position: absolute;
  z-index: 2;
  left: clamp(34px, 6vw, 92px);
  bottom: clamp(32px, 7vh, 88px);
  width: min(500px, 42vw);
  transition: opacity 260ms ease, transform 260ms ease;
}

.room-details.hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
}

.room-details.visible {
  opacity: 1;
  transform: translateY(0);
}

.room-details p {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 11px;
  color: var(--warm);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.28em;
  text-transform: uppercase;
}

.room-details p::before {
  width: 28px;
  height: 1px;
  background: currentColor;
  content: "";
}

.room-details h2 {
  margin: 0;
  font-family: var(--font-display), Georgia, serif;
  font-size: clamp(42px, 5.5vw, 82px);
  font-weight: 500;
  letter-spacing: -0.045em;
  line-height: 0.92;
}

.room-details > span {
  display: block;
  max-width: 430px;
  margin-top: 15px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 12px;
  line-height: 1.65;
}

.photo-count {
  position: absolute;
  right: 30px;
  bottom: 26px;
  display: flex;
  align-items: center;
  gap: 10px;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.photo-count strong {
  font-family: var(--font-display), Georgia, serif;
  font-size: 24px;
  font-weight: 500;
}

.photo-count span {
  width: 32px;
  height: 1px;
  background: rgba(255, 255, 255, 0.42);
}

.photo-count small {
  color: rgba(255, 255, 255, 0.5);
  font-size: 9px;
}

.thumbnail-nav {
  z-index: 4;
  display: flex;
  min-width: 0;
  align-items: center;
  padding: 10px 32px 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(8, 9, 8, 0.68);
  backdrop-filter: blur(20px);
}

.thumbnail-track {
  display: flex;
  width: 100%;
  gap: 10px;
  overflow-x: auto;
  scrollbar-width: none;
}

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

.thumbnail {
  position: relative;
  width: clamp(94px, 11vw, 160px);
  height: 76px;
  flex: 0 0 auto;
  overflow: hidden;
  border: 1px solid transparent;
  border-radius: 1px;
  background: #222;
  cursor: pointer;
  opacity: 0.48;
  padding: 0;
  transition: opacity 180ms ease, border-color 180ms ease, transform 180ms ease;
}

.thumbnail:hover {
  opacity: 0.82;
}

.thumbnail.selected {
  border-color: rgba(255, 255, 255, 0.88);
  opacity: 1;
  transform: translateY(-3px);
}

.thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.thumbnail::after {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.78), transparent 60%);
  content: "";
}

.thumbnail span {
  position: absolute;
  z-index: 1;
  right: 8px;
  bottom: 7px;
  left: 8px;
  overflow: hidden;
  color: #fff;
  font-size: 7px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-align: left;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.tour-progress {
  position: absolute;
  z-index: 5;
  right: 0;
  bottom: 0;
  left: 0;
  height: 2px;
  background: rgba(255, 255, 255, 0.08);
}

.tour-progress span {
  display: block;
  height: 100%;
  background: var(--warm);
  transition: width 380ms ease;
}

@media (max-width: 800px) {
  .intro {
    min-height: 560px;
  }

  .intro-image {
    object-position: 54% center;
  }

  .intro-shade {
    background:
      linear-gradient(0deg, rgba(7, 9, 10, 0.92) 0%, rgba(7, 9, 10, 0.36) 68%, rgba(7, 9, 10, 0.6) 100%),
      linear-gradient(90deg, rgba(7, 9, 10, 0.45), transparent 78%);
  }

  .intro-header,
  .tour-header {
    padding: 20px;
  }

  .intro-location {
    display: none;
  }

  .intro-copy {
    top: auto;
    right: 24px;
    bottom: 108px;
    left: 24px;
    width: auto;
    transform: none;
  }

  .intro h1 {
    font-size: clamp(54px, 18vw, 88px);
    line-height: 0.84;
  }

  .intro-description {
    margin-top: 22px;
    font-size: 12px;
  }

  .intro-hint {
    display: block;
    margin: 12px 0 0 10px;
  }

  .intro-specs {
    right: 20px;
    bottom: 22px;
    left: 20px;
    overflow: hidden;
  }

  .intro-specs span {
    flex: 1;
    padding: 12px 8px;
    font-size: 7px;
    letter-spacing: 0.08em;
    text-align: center;
  }

  .wordmark-number {
    font-size: 29px;
  }

  .tour {
    min-height: 560px;
    grid-template-rows: minmax(0, 1fr) 94px;
  }

  .tour-header {
    background: linear-gradient(180deg, rgba(5, 6, 5, 0.74), transparent);
  }

  .tour-header .wordmark-address {
    display: none;
  }

  .tour-header .wordmark-number {
    border: 0;
    font-size: 30px;
  }

  .tour-tools {
    gap: 6px;
  }

  .tool-button {
    width: 42px;
    height: 42px;
  }

  .tool-button em {
    display: none;
  }

  .tour-stage {
    padding: 0;
  }

  .image-frame {
    border: 0;
  }

  .tour-image {
    object-position: center;
  }

  .image-vignette {
    background:
      linear-gradient(0deg, rgba(3, 4, 3, 0.82) 0%, transparent 46%),
      linear-gradient(180deg, rgba(3, 4, 3, 0.42) 0%, transparent 25%);
  }

  .nav-button {
    top: 54%;
    width: 43px;
    height: 43px;
    font-size: 16px;
  }

  .nav-previous {
    left: 12px;
  }

  .nav-next {
    right: 12px;
  }

  .room-details {
    right: 24px;
    bottom: 28px;
    left: 24px;
    width: auto;
  }

  .room-details h2 {
    max-width: 86%;
    font-size: clamp(38px, 12vw, 58px);
  }

  .room-details > span {
    max-width: 84%;
    font-size: 10px;
    line-height: 1.5;
  }

  .photo-count {
    right: 18px;
    bottom: 23px;
  }

  .photo-count span,
  .photo-count small {
    display: none;
  }

  .thumbnail-nav {
    padding: 10px 12px 10px;
  }

  .thumbnail {
    width: 82px;
    height: 66px;
  }
}

@media (max-width: 460px) {
  .intro-copy {
    bottom: 98px;
  }

  .intro-description {
    max-width: 340px;
    margin-bottom: 20px;
  }

  .intro-specs span:nth-child(3) {
    border-right: 0;
  }

  .intro-specs span:nth-child(4) {
    display: none;
  }

  .room-details > span {
    max-width: 92%;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
