* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  height: 100%;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background-color: #fafbfc;
  color: #000;
  line-height: 1.6;
}

.detail-container {
  display: flex;
  height: 100vh;
  overflow: hidden;
}

.detail-sidebar {
  width: 40%;
  background-color: #fff;
  overflow-y: auto;
  border-right: 1px solid #d0d0d0;
  display: flex;
  flex-direction: column;
}

.detail-header {
  position: sticky;
  top: 0;
  background-color: #fff;
  padding: 1.2rem 1.5rem;
  border-bottom: 1px solid #d0d0d0;
  z-index: 10;
}

.detail-header h1 {
  font-size: 1.1em;
  font-weight: 300;
  letter-spacing: 0.12em;
  margin-bottom: 0.8rem;
}

.detail-header h1 a {
  color: #000;
  text-decoration: none;
}

.back-link {
  color: #000;
  text-decoration: none;
  font-size: 0.85em;
  font-weight: 300;
  transition: opacity 0.3s ease;
}

.back-link:hover {
  opacity: 0.6;
}

.detail-content {
  padding: 2rem 1.5rem;
  flex: 1;
}

.detail-content h2 {
  font-size: 1.2em;
  font-weight: 300;
  margin-bottom: 2rem;
}

.detail-section {
  margin-bottom: 2.5rem;
}

.detail-section h3 {
  font-size: 0.85em;
  font-weight: 300;
  text-transform: uppercase;
  margin-bottom: 1rem;
  color: #666;
  letter-spacing: 0.05em;
}

.detail-section p {
  font-size: 0.9em;
  font-weight: 300;
  color: #333;
  line-height: 1.7;
}

.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.tag {
  display: inline-block;
  padding: 0.4rem 0.8rem;
  border: 1px solid #d0d0d0;
  font-size: 0.8em;
  font-weight: 300;
  color: #666;
  border-radius: 2px;
  transition: all 0.3s ease;
}

.tag:hover {
  background-color: #f5f5f5;
  border-color: #999;
}

.detail-gallery {
  width: 60%;
  overflow-y: auto;
  padding: 2rem;
  background-color: #fafafa;
}

.image-column {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.detail-image {
  margin: 0;
  padding: 0;
  width: 100%;
}

.detail-image.full-width {
  width: 100%;
}

.image-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  width: 100%;
}

.image-row .detail-image {
  margin: 0;
  padding: 0;
  width: 100%;
}

.detail-image img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 4px;
}

/* Tablet and smaller screens */
@media (max-width: 768px) {
  .detail-container {
    flex-direction: column;
    height: auto;
  }

  .detail-sidebar {
    width: 100%;
    border-right: none;
    border-bottom: 1px solid #d0d0d0;
    max-height: 50vh;
  }

  .detail-gallery {
    width: 100%;
    padding: 1rem;
  }
}

/* Mobile */
@media (max-width: 480px) {
  .detail-header {
    padding: 1rem;
  }

  .detail-header h1 {
    font-size: 0.85em;
    margin-bottom: 0.5rem;
  }

  .detail-content {
    padding: 1.5rem 1rem;
  }

  .detail-content h2 {
    font-size: 1em;
    margin-bottom: 1.5rem;
  }

  .detail-section {
    margin-bottom: 1.5rem;
  }

  .detail-gallery {
    padding: 1rem;
  }

  .image-column {
    gap: 1rem;
  }
}
