:root {
  --bg: #070a1a;
  --panel: rgba(20, 24, 52, 0.96);
  --panel-alt: rgba(12, 16, 40, 0.98);
  --accent: #7f5cff;
  --accent-soft: rgba(127, 92, 255, 0.18);
  --text: #f4f7ff;
  --muted: #a3b0ff;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background: radial-gradient(circle at top, rgba(127, 92, 255, 0.35), transparent 28%),
    linear-gradient(180deg, #090c1c 0%, #02040b 100%);
}

button {
  font: inherit;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.5rem;
  background: rgba(6, 10, 24, 0.95);
  backdrop-filter: blur(18px);
  position: sticky;
  top: 0;
  z-index: 10;
}

.brand {
  font-size: 1.15rem;
  letter-spacing: 0.02em;
  font-weight: 700;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.hint {
  color: var(--muted);
  font-size: 0.96rem;
}

.nav-button,
.close-button {
  border: none;
  background: linear-gradient(135deg, var(--accent), #5a46f3);
  color: white;
  border-radius: 999px;
  padding: 0.8rem 1rem;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.nav-button:hover,
.close-button:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 30px rgba(127, 92, 255, 0.25);
}

.layout {
  display: grid;
  grid-template-columns: minmax(280px, 360px) minmax(380px, 1fr);
  gap: 1.25rem;
  padding: 1.5rem;
}

.panel {
  background: var(--panel);
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-radius: 28px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.25);
  overflow: hidden;
}

.panel-heading {
  padding: 1.35rem 1.5rem 0.8rem;
}

.panel-heading h2 {
  margin: 0 0 0.35rem;
  font-size: 1.15rem;
}

.panel-heading p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.map-shell {
  min-height: 38rem;
  position: relative;
  padding: 1.25rem;
}

.map-background {
  position: absolute;
  inset: 1.25rem;
  border-radius: 28px;
  background-image: url('./assets/0.JPG');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  pointer-events: auto;
}

.map-shell::after {
  content: '';
  position: absolute;
  inset: 1.4rem;
  border-radius: 24px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.02), transparent 38%);
  pointer-events: none;
}

.map-pin {
  position: absolute;
  width: 3.1rem;
  height: 3.1rem;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.9);
  background: radial-gradient(circle, var(--accent) 35%, rgba(127, 92, 255, 0.28) 100%);
  color: white;
  font-weight: 700;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.map-pin:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 16px 35px rgba(127, 92, 255, 0.3);
}

.map-pin.start-pin {
  width: auto;
  min-width: 4rem;
  padding: 0 0.9rem;
  background: linear-gradient(135deg, #ffb459, #ff7f00);
  border-color: rgba(255, 255, 255, 0.95);
  font-size: 0.9rem;
}

.map-pin.active {
  box-shadow: 0 0 0 6px rgba(127, 92, 255, 0.2);
}

.scene-summary {
  padding: 1.25rem 1.5rem 1.75rem;
}

.scene-label {
  margin: 0 0 0.55rem;
  color: var(--accent);
  letter-spacing: 0.08em;
  font-size: 0.8rem;
  text-transform: uppercase;
}

.scene-summary h3 {
  margin: 0 0 0.5rem;
  font-size: 1.3rem;
}

.scene-summary p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.panel-viewer {
  display: flex;
  flex-direction: column;
  min-height: auto;
}

.viewer-content {
  display: grid;
  grid-template-columns: minmax(0, 1.8fr) minmax(320px, 1fr);
  gap: 1rem;
  padding: 1rem 1.5rem 0;
  align-items: start;
}

.panorama {
  min-height: 28rem;
  max-height: calc(100vh - 220px);
  border-radius: 28px;
  overflow: hidden;
  position: relative;
}

.scene-side-panel {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.scene-video-wrapper,
.scene-desc-wrapper {
  border-radius: 24px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.scene-video-wrapper {
  min-height: 220px;
  max-height: 36rem;
}

.scene-desc-wrapper {
  padding: 1.25rem;
  max-height: 32rem;
  overflow: auto;
}

.viewer-footer {
  padding: 1rem 1.5rem;
  color: var(--muted);
}

.scene-video {
  width: 100%;
  height: 100%;
  min-height: 260px;
  object-fit: cover;
  display: block;
}

.scene-text-column {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.scene-text-column .scene-label {
  margin-bottom: 0.75rem;
}

.scene-text-column h3 {
  margin: 0 0 0.75rem;
}

.scene-text-column p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

@media (max-width: 980px) {
  .viewer-content {
    grid-template-columns: 1fr;
  }
}

.model-panel {
  position: fixed;
  right: 1.5rem;
  bottom: 1.5rem;
  width: min(540px, calc(100vw - 3rem));
  max-height: 72vh;
  background: rgba(7, 10, 26, 0.98);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.45);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  z-index: 20;
}

.model-panel.hidden {
  display: none;
}

.model-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.25rem 1.25rem 0.75rem;
}

.model-header h3 {
  margin: 0 0 0.35rem;
}

.model-header p {
  margin: 0;
  color: var(--muted);
  max-width: 320px;
}

.model-container {
  height: 420px;
  background: #02040b;
  padding: 0.5rem;
}


.scene-info-panel {
  position: fixed;
  left: 1.5rem;
  bottom: 1.5rem;
  width: min(360px, calc(30vw));
  max-height: 90vh;
  background: rgba(9, 14, 30, 0.98);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.35);
  display: flex;
  flex-direction: column;
  z-index: 20;
  overflow: hidden;
}

.scene-info-panel.hidden {
  display: none;
}

.scene-info-header {
  padding: 1.25rem 1.25rem 0.75rem;
}

.scene-info-header h3 {
  margin: 0.75rem 0 0;
  font-size: 1rem;
  line-height: 1.5;
  color: #dbe2ff;
}

.scene-info-body {
  padding: 0 1.25rem 1.25rem;
  overflow-y: auto;
}

.scene-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 20px;
  padding: 1rem;
  margin-bottom: 1rem;
}

.scene-card-title {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #98a8ff;
  font-size: 0.78rem;
  margin-bottom: 0.75rem;
}

.scene-picture-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
}

.scene-preview {
  width: 100%;
  min-height: 180px;
  border-radius: 18px;
  overflow: hidden;
  margin-bottom: 0.75rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.10);
}

.scene-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.photo-panel {
  display: flex;
  flex-direction: column;
  padding: 0.75rem;
  min-height: 260px;
}

.photo-panel-body {
  flex: 1;
  min-height: 220px;
  border-radius: 18px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.05);
}

.photo-panel-body img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  background: #02040b;
}

.scene-picture {
  overflow: hidden;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.10);
  cursor: pointer;
}

.scene-picture.active {
  outline: 2px solid rgba(159, 170, 255, 0.9);
}

.scene-picture img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.model-display-container {
  width: 100%;
  height: 100%;
  min-height: 420px;
  border-radius: 18px;
  overflow: hidden;
  background: #010612;
}

.model-container model-viewer {
  width: 100%;
  height: 100%;
}

.hotspot-button {
  border: none;
  background: rgba(127, 92, 255, 0.95);
  color: white;
  padding: 0.65rem 0.9rem;
  font-size: 0.9rem;
  border-radius: 999px;
  cursor: pointer;
}

.nav-hotspot {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.7rem 1rem;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #ffffff;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.nav-icon {
  font-size: 1.1rem;
}

@media (max-width: 1120px) {
  .layout {
    grid-template-columns: 1fr;
  }

  .map-shell {
    min-height: 32rem;
  }
}

@media (max-width: 720px) {
  .topbar {
    flex-direction: column;
    align-items: stretch;
  }

  .topbar-actions {
    justify-content: space-between;
  }

  .panel {
    border-radius: 22px;
  }

  .model-panel {
    right: 1rem;
    left: 1rem;
    bottom: 1rem;
  }
}
