body.portal-home { --front-width: 680px; padding: 0; background: #fff; }
.portal-home .portal-masthead,
.portal-home .draw-sticky-wrapper,
.portal-home .portal-content {
  width: min(100%, var(--front-width));
  margin: 0 auto;
}
.portal-home .portal-masthead > a {
  width: 100%;
  max-height: none;
  background: #fff;
}
.portal-home .portal-content { display: block; padding: 0 0 24px; }
.portal-home .front-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 12px 16px;
  border-bottom: 1px solid #e5e5e5;
}
.front-link {
  display: flex;
  min-width: 0;
  min-height: 44px;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border: 1px solid #dedede;
  border-radius: 4px;
  color: #302629;
  font-size: 14px;
  font-weight: 600;
  overflow-wrap: anywhere;
}
.front-link img { display: block; width: 32%; max-height: 48px; object-fit: contain; }
.front-link__arrow { margin-left: auto; color: #9e3037; }
.portal-home .post-list-v2 { width: 100%; margin: 0; border: 0; }
.front-post-heading {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  padding: 18px 16px 12px;
  color: #221d1e;
  font-size: 20px;
  line-height: 1.25;
}
.front-post-heading::before { content: ''; width: 3px; height: 17px; background: #a52a32; }
.portal-home .post-list-v2__row {
  grid-template-columns: 54px minmax(0, 1fr) 74px;
  column-gap: 12px;
  align-items: center;
  min-height: 54px;
  padding: 8px 12px;
  border-top: 1px solid #eee;
}
.portal-home .post-list-v2__row--new-type { border-top: 2px solid #e4dadd; }
.portal-home .post-list-v2__row > * {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.front-post__tag {
  padding: 3px 2px;
  border: 1px solid #dbe8df;
  border-radius: 4px;
  background: #f4faf6;
  color: #285b40;
  font-size: 13px;
  font-weight: 700;
  text-align: center;
}
.front-post__tag[data-tag="出售帖"] { background: #fdf1f1; color: #962832; border-color: #f4dadd; }
.front-post__tag[data-tag="高手帖"] { background: #f3f6fc; color: #344b79; border-color: #dbe3f3; }
.front-post__tag[data-tag="推荐帖"] { background: #f7f2fa; color: #694078; border-color: #e8dcef; }
.front-post__title { display: flex; align-items: baseline; gap: 6px; font-size: 18px; font-weight: 750; min-width: 0; white-space: nowrap; overflow: hidden; }
.front-post__head { flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.front-post__slogan { flex: 0 3 auto; min-width: 0; font-weight: 600; }
.front-post__author { color: #61585b; font-size: 13px; text-align: end; }
@media (max-width: 600px) {
  .portal-home .post-list-v2__row {
    grid-template-columns: 43px minmax(0, 1fr) 54px;
    column-gap: 6px;
    min-height: 44px;
    padding: 6px;
  }
  .front-post__tag, .front-post__author { font-size: 12px; }
  .front-post__title { font-size: 15px; }
  /* 手机端：标签缩成单行小字、作者与标题重复时让位给标题，标题最多两行，保证看得清 */
  .portal-home .post-list-v2__row {
    grid-template-columns: 34px minmax(0, 1fr);
    min-height: 46px;
    padding: 8px 10px;
  }
  .portal-home .post-list-v2__row .front-post__author { display: none; }
  .portal-home .post-list-v2__row .front-post__tag { font-size: 10px; padding: 2px 0; text-align: center; letter-spacing: -0.5px; }
  .portal-home .post-list-v2__row .front-post__title {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 15px;
    line-height: 1.3;
  }
  .portal-home .post-list-v2__row .front-post__title { font-size: 13px; gap: 4px; }
  .portal-home .post-list-v2__row .front-post__slogan {
    display: inline-block;
    max-width: 10.4em;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 12px;
  }
}
.front-link:focus-visible, .portal-home .post-list-v2__row:focus-visible { outline: 2px solid #9e3037; outline-offset: -2px; }

.front-gallery { padding: 12px 10px; border-top: 1px solid #eee; }
.front-gallery [hidden] { display: none; }
.front-gallery header { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.front-gallery .front-post-heading { padding: 8px 0; }
.front-gallery label { font-size: 12px; }
.front-gallery select, .front-gallery button { font: inherit; color: inherit; background: white; border: 1px solid #ddd; border-radius: 4px; cursor: pointer; }
.front-gallery select, .front-gallery [data-more], .front-gallery dialog button { padding: 6px; }
.front-gallery__grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 6px; margin-block: 8px; }
.front-gallery__grid button { padding: 0; min-width: 0; overflow: hidden; text-align: left; }
.front-gallery__grid img { display: block; width: 100%; aspect-ratio: 3/4; object-fit: contain; }
.front-gallery__grid span { display: block; padding: 4px; font-size: 12px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.front-gallery dialog { width: min(94vw,560px); max-height: 90dvh; margin: auto; padding: 12px; border: 0; border-radius: 6px; overflow: auto; }
.front-gallery dialog::backdrop { background: #101010b8; }
.front-gallery dialog img { width: 100%; height: auto; display: block; margin: 8px auto; }
.portal-home .zodiac-reference-section { margin: 8px 0 0; padding: 0; border: 0; }
.portal-home .zodiac-reference-image { width: 100%; height: auto; max-width: 100%; max-height: none; border: 0; }

.front-period-ad {
  margin: 10px 10px 0;
  border: 1px solid #a93037;
  border-radius: 6px;
  overflow: hidden;
  background: #fff;
  color: #252122;
  text-align: center;
}
.front-period-ad h2 {
  margin: 0;
  padding: 8px 12px;
  background: #a93037;
  color: #fff;
  font-size: clamp(16px, 4.2vw, 21px);
  overflow-wrap: anywhere;
}
.front-period-ad ol { margin: 0; padding: 0 10px; list-style: none; }
.front-period-ad li { padding: 8px 0; }
.front-period-ad li + li { border-top: 1px solid #e3d9da; }
.front-period-ad h3 { margin: 0; font-size: clamp(14px, 3.8vw, 18px); overflow-wrap: anywhere; }
.front-period-ad h3 span { margin-inline-start: 8px; white-space: normal; }
.front-period-ad p {
  margin: 4px 0 0;
  color: #9b232b;
  font-size: clamp(13px, 3.7vw, 19px);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.front-account-links {
  display: flex;
  gap: 8px;
  margin: 10px 10px 0;
}
.front-account-links a {
  flex: 1;
  display: grid;
  place-items: center;
  min-height: 44px;
  padding: 4px 6px;
  border: 1px solid #e7dadd;
  border-radius: 6px;
  background: #fff;
  color: #96282f;
  font-size: 15px;
  font-weight: 700;
}
.front-fixed-banner { margin: 10px; }

@media (max-width: 380px) {
  .portal-home .post-list-v2__row { grid-template-columns: 30px minmax(0, 1fr); padding: 8px 8px; }
  .portal-home .post-list-v2__row .front-post__tag { font-size: 9px; letter-spacing: -0.6px; }
  .portal-home .post-list-v2__row .front-post__title { font-size: 12px; gap: 3px; }
  .portal-home .post-list-v2__row .front-post__slogan { font-size: 11px; max-width: 10.4em; }
}
