/* ===== Detail page: gray detail-paper + white content sheet ===== */
.shell--detail {
  background: transparent;
  /* padding: 0 40px; */
  padding-bottom: 40px;
}

.detail-paper {
  background: #ececec;
  padding: 0 80px;
}

.detail-paper__sheet {
  background: #fff;
  padding: 44px 56px 36px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
}

.detail-paper__title {
  font-size: 36px;
  font-weight: 700;
  line-height: 1.35;
  text-align: center;
  color: #000;
}

.detail-paper__meta {
  margin-top: 14px;
  font-size: 14px;
  line-height: 1.8;
  text-align: center;
  color: rgba(0, 0, 0, 0.45);
}

.detail-paper__divider {
  width: 100%;
  height: 1px;
  margin: 18px 0 28px;
  border: 0;
  background: #e5e5e5;
}

.detail-paper__body {
  font-size: 16px;
  line-height: 1.85;
  color: #333;
  word-break: break-word;
}

.detail-paper__lead {
  margin: 0 0 1em;
  text-indent: 2em;
  color: #8b3a2f;
}

.detail-paper__body p {
  margin: 0 0 1em;
  text-indent: 2em;
}

.detail-paper__body p:last-child {
  margin-bottom: 0;
}

.detail-paper__body .detail-paper__direction-title {
  margin: 1.5em 0 0.75em;
  font-size: 20px;
  font-weight: 700;
  line-height: 1.5;
  text-align: center;
  text-indent: 0;
  color: #000;
}

.detail-paper__body .detail-paper__direction-body {
  margin-bottom: 1em;
}

.detail-paper__body img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  margin: 24px auto;
}

.detail-paper__body table {
  width: 100%;
  margin: 16px 0;
  border-collapse: collapse;
}

.detail-paper__body table td,
.detail-paper__body table th {
  border: 1px solid #e5e5e5;
  padding: 8px 10px;
}

/* ===== Prev / Next row ===== */
.detail-turn {
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin-top: 24px;
  background: #fff;
  border: 1px solid #e5e5e5;
}

.detail-turn__item {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 52px;
  padding: 12px 18px;
  font-size: 14px;
  line-height: 1.5;
  color: #666;
}

.detail-turn__item + .detail-turn__item {
  border-left: 1px solid #e5e5e5;
}

.detail-turn__label {
  flex: 0 0 auto;
  color: #999;
}

.detail-turn__link {
  flex: 1;
  min-width: 0;
  color: #333;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.detail-turn__link:hover {
  color: var(--blue);
}

.detail-turn__empty {
  color: #bbb;
}

/* ===== Bottom recommend panels ===== */
.detail-recommend {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  margin-top: 0;
  background: #fff;
  border: 1px solid #e5e5e5;
  border-top: 0;
}

.detail-recommend__panel + .detail-recommend__panel {
  border-left: 1px solid #e5e5e5;
}

.detail-recommend__head {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 16px;
  background: #f0f0f0;
  border-top: 3px solid var(--blue);
  margin-top: -1px;
}

.detail-recommend__title {
  font-size: 24px;
  font-weight: 700;
  line-height: 1.2;
  color: #000;
}

.detail-recommend__list {
  padding: 0;
}

.detail-recommend__list li {
  border-bottom: 1px solid #f0f0f0;
}

.detail-recommend__list li:last-child {
  border-bottom: 0;
}

.detail-recommend__list a {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 10px 16px 10px 28px;
  font-size: 14px;
  line-height: 1.4;
  position: relative;
}

.detail-recommend__list a::before {
  content: "";
  position: absolute;
  left: 14px;
  top: 50%;
  width: 6px;
  height: 6px;
  margin-top: -3px;
  border-radius: 50%;
  background: var(--blue);
  flex-shrink: 0;
}

.detail-recommend__list a:hover .detail-recommend__text {
  color: var(--blue);
}

.detail-recommend__text {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.detail-recommend__list time {
  flex: 0 0 auto;
  font-size: 12px;
  color: rgba(0, 0, 0, 0.4);
  white-space: nowrap;
}

@media (max-width: 1024px) {
  .detail-paper {
    padding: 20px 24px 28px;
  }

  .detail-paper__sheet {
    padding: 36px 32px 28px;
  }
}

@media (max-width: 768px) {
  .shell--detail {
    padding: 16px 0 28px;
  }

  .detail-paper {
    padding: 16px 12px 20px;
  }

  .detail-paper__sheet {
    padding: 28px 20px 24px;
  }

  .detail-paper__title {
    font-size: 24px;
  }

  .detail-paper__meta {
    font-size: 13px;
    line-height: 1.6;
  }

  .detail-paper__body {
    font-size: 15px;
    line-height: 1.75;
  }

  .detail-turn {
    grid-template-columns: 1fr;
    margin-top: 20px;
  }

  .detail-turn__item + .detail-turn__item {
    border-left: 0;
    border-top: 1px solid #e5e5e5;
  }

  .detail-turn__link {
    white-space: normal;
  }

  .detail-recommend {
    grid-template-columns: 1fr;
  }

  .detail-recommend__panel + .detail-recommend__panel {
    border-left: 0;
    border-top: 1px solid #e5e5e5;
  }

  .detail-recommend__list a {
    flex-wrap: wrap;
  }

  .detail-recommend__text {
    white-space: normal;
  }
}
