.topic-hero-strip {
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
  padding: 48px var(--page-padding);
  text-align: center;
  position: relative;
  overflow: hidden;
}

.topic-hero-strip::after {
  content: "";
  position: absolute;
  width: 240px;
  height: 240px;
  top: -80px;
  left: 15%;
  border-radius: 50%;
  background: rgba(244, 235, 217, 0.18);
  filter: blur(50px);
  animation: breathe 7s ease-in-out infinite;
}

.topic-hero-strip h1 {
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  color: rgba(244, 235, 217, 0.98);
  max-width: 800px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.topic-hero-strip h1 em {
  font-style: italic;
}

.layout-sidebar-rail {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 48px;
  max-width: 1100px;
  margin: 0 auto;
  padding: 48px var(--page-padding);
}

.sidebar-rail {
  position: sticky;
  top: 80px;
  align-self: start;
}

.sidebar-rail img {
  border-radius: var(--soft-radius);
  max-width: 100%;
  max-height: 320px;
  object-fit: cover;
  margin-bottom: 20px;
  box-shadow: 0 12px 40px rgba(44, 36, 29, 0.1);
}

.sidebar-nav {
  list-style: none;
  padding: 0;
}

.sidebar-nav li {
  margin-bottom: 8px;
}

.sidebar-nav a {
  display: block;
  padding: 10px 14px;
  font-size: 13px;
  color: var(--muted);
  font-family: "Segoe UI", Arial, sans-serif;
  border-radius: 12px;
  transition: background 0.4s ease, color 0.4s ease;
}

.sidebar-nav a:hover {
  background: rgba(141, 91, 62, 0.12);
  color: var(--primary);
}

.topic-body h2 {
  font-size: 1.4rem;
  margin: 36px 0 14px;
  color: var(--primary);
}

.topic-body h2:first-child {
  margin-top: 0;
}

.topic-body p {
  margin-bottom: 16px;
  color: var(--text);
}

.topic-body ul {
  margin: 0 0 16px 24px;
}

.topic-body li {
  margin-bottom: 8px;
}

@media (max-width: 768px) {
  .layout-sidebar-rail {
    grid-template-columns: 1fr;
    overflow-x: hidden;
    max-width: 100%;
  }

  .sidebar-rail {
    position: static;
    max-width: 100%;
    overflow: hidden;
  }

  .sidebar-rail img {
    max-width: 100%;
    width: 100%;
    height: auto;
    max-height: 240px;
  }
}
