:root {
  color-scheme: dark;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
  font-weight: 400;
  background: #0f172a;
  color: #f8fafc;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: linear-gradient(135deg, #111827, #1d4ed8);
  color: #f8fafc;
}

.page {
  width: min(95vw, 1120px);
  margin: 0 auto;
  padding: 2rem 1rem;
}

.card {
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 1rem;
  padding: 2rem;
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.25);
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.eyebrow {
  margin: 0 0 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.24em;
  font-size: 0.8rem;
  color: #93c5fd;
}

h1,
h2 {
  margin: 0;
}

.card-copy {
  margin: 0;
  color: #cbd5e1;
  max-width: 22rem;
}

.layout {
  display: grid;
  grid-template-columns: minmax(240px, 320px) 1fr;
  gap: 1rem;
}

.list-panel {
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 0.9rem;
  padding: 1rem;
}

.detail-panel {
  display: flex;
  flex-direction: column;
}

.search-label {
  display: block;
  margin: 0.85rem 0 0.35rem;
  font-size: 0.9rem;
  color: #cbd5e1;
}

.search-input {
  width: 100%;
  border: 1px solid rgba(147, 197, 253, 0.25);
  border-radius: 0.65rem;
  padding: 0.7rem 0.8rem;
  background: rgba(30, 41, 59, 0.9);
  color: #f8fafc;
}

.search-input:focus {
  outline: 2px solid rgba(147, 197, 253, 0.4);
  outline-offset: 2px;
}

.equipment-list {
  list-style: none;
  padding: 0;
  margin: 0.75rem 0 0;
  display: grid;
  gap: 0.5rem;
  max-height: 32rem;
  overflow-y: auto;
  padding-right: 0.35rem;
}

.equipment-list::-webkit-scrollbar {
  width: 0.45rem;
}

.equipment-list::-webkit-scrollbar-thumb {
  background: rgba(147, 197, 253, 0.35);
  border-radius: 999px;
}

.equipment-item {
  width: 100%;
  text-align: left;
  border: 1px solid rgba(147, 197, 253, 0.2);
  border-radius: 0.65rem;
  padding: 0.75rem 0.85rem;
  background: rgba(30, 41, 59, 0.88);
  color: inherit;
  cursor: pointer;
  transition: border-color 160ms ease, transform 160ms ease, background 160ms ease;
}

.equipment-item:hover,
.equipment-item:focus-visible {
  border-color: #93c5fd;
  transform: translateY(-1px);
  outline: none;
}

.equipment-item.active {
  background: #1d4ed8;
  border-color: #93c5fd;
}

.detail-content {
  margin-top: 0;
  min-height: 28rem;
  height: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.model-viewer-shell {
  position: relative;
  flex: 1;
  min-height: 24rem;
  width: 100%;
  border: 1px solid rgba(147, 197, 253, 0.25);
  border-radius: 0.95rem;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.95), rgba(30, 41, 59, 0.95));
}

.model-viewer-shell::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.25) 0%, rgba(2, 6, 23, 0.65) 100%);
  pointer-events: none;
}

model-viewer {
  width: 100%;
  height: 100%;
  min-height: 24rem;
  background: transparent;
}

.placeholder {
  color: #cbd5e1;
  margin: 0;
}

.detail-title {
  position: absolute;
  top: 1rem;
  left: 1rem;
  z-index: 2;
  font-size: 1.35rem;
  margin: 0;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.65);
}

.detail-meta {
  position: absolute;
  bottom: 1rem;
  left: 1rem;
  z-index: 2;
  display: grid;
  gap: 0.35rem;
  color: #f8fafc;
  font-weight: 600;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7);
}

.detail-description {
  position: absolute;
  right: 1rem;
  bottom: 1rem;
  z-index: 2;
  margin: 0;
  max-width: 18rem;
  color: #f8fafc;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7);
}

@media (max-width: 780px) {
  .layout {
    grid-template-columns: 1fr;
  }

  .card-header {
    flex-direction: column;
    align-items: flex-start;
  }
}
