/* ============================================
   旬颜 - 首页独有样式
   ============================================ */

/* ---------- 板块容器 ---------- */
.screen {
  padding: 48px 20px;
  position: relative;
  display: grid;
  place-items: center;
}

/* ---------- Hero区 ---------- */
.hero {
  min-height: 100vh;
  overflow: hidden;
  text-align: center;
}

.hero::before,
.hero::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  filter: blur(18px);
  pointer-events: none;
}

.hero::before {
  width: 360px;
  height: 360px;
  top: 8%;
  left: 6%;
  background: radial-gradient(circle, rgba(68, 163, 255, 0.14), transparent 62%);
}

.hero::after {
  width: 300px;
  height: 300px;
  right: 9%;
  bottom: 8%;
  background: radial-gradient(circle, rgba(255, 107, 125, 0.12), transparent 64%);
}

.hero-inner {
  width: 100%;
  max-width: 1120px;
  display: grid;
  justify-items: center;
  gap: 24px;
  padding: 0 0 18px;
}

.hero-note {
  margin: 0;
  color: #fff;
  font-size: 17px;
  line-height: 1.7;
}

/* 搜索框尺寸 */
.search-card {
  width: 100%;
  max-width: 760px;
  padding: 18px;
  border-radius: 28px;
}

.search-input { height: 74px; }
.search-button { height: 74px; min-width: 160px; }

/* ---------- 热门标签 ---------- */
.hot-tags {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 8px;
}

/* ---------- 板块卡片 ---------- */
.section-card {
  width: min(var(--content-width), calc(100vw - 40px));
  padding: 24px;
  border-radius: 36px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.4), rgba(255, 255, 255, 0.4)),
    rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.4);
  box-shadow:
    0 22px 72px rgba(21, 32, 51, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.96),
    inset 0 -18px 36px rgba(91, 140, 255, 0.04);
  backdrop-filter: blur(28px) saturate(165%);
  -webkit-backdrop-filter: blur(28px) saturate(165%);
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

.section-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background:
    radial-gradient(circle at 14% 12%, rgba(68, 163, 255, 0.08), transparent 24%),
    radial-gradient(circle at 82% 14%, rgba(255, 107, 125, 0.08), transparent 20%),
    radial-gradient(circle at 50% 110%, rgba(39, 240, 198, 0.06), transparent 24%);
  opacity: 0.9;
}

.section-card::after {
  content: "";
  position: absolute;
  inset: 12px 14px auto;
  height: 52px;
  border-radius: var(--radius-full);
  background: linear-gradient(115deg, transparent 10%, rgba(255, 255, 255, 0.56) 50%, transparent 84%);
  filter: blur(5px);
  pointer-events: none;
  opacity: 0.45;
}

.section-card > * {
  position: relative;
  z-index: 1;
}

.section-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
  margin-bottom: 20px;
}

.section-title {
  margin: 8px 0 0;
  font-size: 32px;
  line-height: 1.16;
  letter-spacing: 0;
}

.section-title small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 500;
}


.section-head > div:first-child {
  display: grid;
  align-content: center;
  gap: 0;
  min-width: 0;
}

.section-head .section-chip {
  width: fit-content;
  min-height: 38px;
  padding: 9px 14px;
  background: rgba(68, 163, 255, 0.10);
  border-color: rgba(68, 163, 255, 0.14);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

.section-head .link-chip {
  flex-shrink: 0;
  min-height: 38px;
  display: inline-flex;
  align-items: center;
}
/* ---------- 文章网格 ---------- */
.article-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.article {
  padding: 18px;
  border-radius: 28px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.98), rgba(255, 255, 255, 0.84)),
    rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.96);
  box-shadow:
    0 16px 34px rgba(21, 32, 51, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.96),
    inset 0 -12px 22px rgba(91, 140, 255, 0.03);
  min-height: 188px;
  display: grid;
  gap: 12px;
  align-content: start;
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(22px) saturate(150%);
  -webkit-backdrop-filter: blur(22px) saturate(150%);
  isolation: isolate;
}

.article::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background:
    radial-gradient(circle at 16% 18%, rgba(255, 107, 125, 0.05), transparent 34%),
    radial-gradient(circle at 84% 16%, rgba(68, 163, 255, 0.07), transparent 30%),
    radial-gradient(circle at 50% 102%, rgba(39, 240, 198, 0.05), transparent 24%);
  opacity: 0.8;
}

.article::after {
  content: "";
  position: absolute;
  inset: auto -18% -34% auto;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(68, 163, 255, 0.08), transparent 70%);
  pointer-events: none;
}

.article > * {
  position: relative;
  z-index: 1;
}

.article-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}

.article-meta {
  color: var(--muted-light);
  font-size: 13px;
}


.article-info {
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px 10px;
  min-width: 0;
}

.home-article-thumb {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 20px;
  background: rgba(238, 242, 247, 0.86);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

.home-article-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}.article h3 {
  margin: 0;
  font-size: 20px;
  line-height: 1.28;
  letter-spacing: 0;
}

.article p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.68;
}

.article-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
}

/* ---------- 响应式 ---------- */
@media (max-width: 980px) {
  .article-grid { grid-template-columns: 1fr; }
  .section-head { align-items: start; flex-direction: column; }
}

@media (max-width: 640px) {
  .screen {
    padding-inline: 12px;
  }

  .section-card {
    width: min(100vw - 24px, var(--content-width));
  }

  .hero-inner {
    gap: 18px;
    padding: 6px 0 22px;
  }

  .logo-badge {
    padding: 14px 22px;
    font-size: 18px;
  }

  .section-title {
    font-size: 28px;
  }

  .search-card {
    border-radius: 28px;
    padding: 14px;
  }

  .search-input,
  .search-button {
    height: 64px;
    border-radius: 20px;
  }

  .section-card {
    padding: 18px;
    border-radius: 28px;
  }

  .article {
    min-height: auto;
    padding: 16px;
    border-radius: 24px;
  }

}

/* ---------- Category types: home ---------- */
.home-category-section .article-top {
  justify-content: flex-end;
}

.home-category-doctor .section-card {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.74), rgba(235, 247, 255, 0.80)),
    rgba(255, 255, 255, 0.70);
  box-shadow:
    0 24px 70px rgba(43, 94, 145, 0.10),
    inset 0 1px 0 rgba(255, 255, 255, 0.96);
}

.home-category-doctor .section-card::before {
  background:
    linear-gradient(90deg, rgba(68, 163, 255, 0.12), transparent 48%),
    radial-gradient(circle at 88% 14%, rgba(255, 255, 255, 0.82), transparent 26%);
}

.home-category-doctor .article-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.home-category-doctor .article {
  grid-template-columns: minmax(126px, 30%) minmax(0, 1fr);
  gap: 18px;
  align-items: stretch;
  align-content: stretch;
  min-height: 178px;
  padding: 18px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.98), rgba(235, 247, 255, 0.90)),
    rgba(255, 255, 255, 0.92);
  box-shadow:
    0 18px 36px rgba(43, 94, 145, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.96);
}

.home-category-doctor .article::before {
  content: "";
  inset: 0;
  background:
    radial-gradient(circle at 12% 18%, rgba(68, 163, 255, 0.10), transparent 34%),
    radial-gradient(circle at 86% 16%, rgba(255, 255, 255, 0.70), transparent 28%);
  opacity: 0.82;
}

.home-category-doctor .article::after {
  inset: auto -42px -54px auto;
  width: 150px;
  height: 150px;
  background: radial-gradient(circle, rgba(68, 163, 255, 0.10), transparent 70%);
}

.home-doctor-thumb {
  display: block;
  min-height: 142px;
  border: 1px solid rgba(255, 255, 255, 0.86);
  border-radius: 24px;
  overflow: hidden;
  background:
    linear-gradient(145deg, rgba(225, 244, 255, 0.96), rgba(255, 255, 255, 0.86)),
    rgba(235, 247, 255, 0.86);
  box-shadow:
    0 14px 30px rgba(43, 94, 145, 0.13),
    inset 0 1px 0 rgba(255, 255, 255, 0.96);
}

.home-doctor-thumb img,
.home-doctor-thumb span {
  width: 100%;
  height: 100%;
  min-height: inherit;
}

.home-doctor-thumb img {
  display: block;
  object-fit: cover;
}

.home-doctor-thumb span {
  display: grid;
  place-items: center;
  color: #2b5f99;
  font-size: 34px;
  font-weight: 900;
}

.home-doctor-main {
  min-width: 0;
  display: grid;
  gap: 10px;
  align-content: space-between;
}

.home-doctor-name {
  margin: 0;
  font-size: 22px;
  line-height: 1.28;
}

.home-doctor-specialties {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.68;
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.home-doctor-meta {
  justify-content: flex-end;
  align-self: end;
  padding: 6px 10px;
  border: 1px solid rgba(255, 255, 255, 0.68);
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.54);
}

.home-category-project .section-card {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.74), rgba(241, 252, 247, 0.82)),
    rgba(255, 255, 255, 0.70);
  box-shadow:
    0 24px 70px rgba(37, 124, 105, 0.09),
    inset 0 1px 0 rgba(255, 255, 255, 0.96);
}

.home-category-project .section-card::before {
  background:
    linear-gradient(90deg, rgba(46, 169, 139, 0.12), transparent 46%),
    radial-gradient(circle at 86% 18%, rgba(255, 205, 171, 0.20), transparent 24%);
}

.home-category-project .article-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.home-category-project .article {
  min-height: 204px;
  align-content: space-between;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.98), rgba(240, 252, 247, 0.88)),
    rgba(255, 255, 255, 0.92);
  box-shadow:
    0 18px 36px rgba(37, 124, 105, 0.07),
    inset 0 1px 0 rgba(255, 255, 255, 0.96);
}

.home-category-project .article:first-child {
  grid-column: span 2;
}

.home-category-project .article::before {
  background:
    linear-gradient(90deg, rgba(46, 169, 139, 0.18), transparent 56%),
    radial-gradient(circle at 90% 12%, rgba(255, 176, 121, 0.13), transparent 28%);
}

.home-category-project .article::after {
  content: "";
  inset: auto 18px 18px auto;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(46, 169, 139, 0.14);
  border-radius: 16px;
  background:
    linear-gradient(135deg, rgba(46, 169, 139, 0.14), rgba(255, 255, 255, 0.78)),
    linear-gradient(90deg, transparent 46%, rgba(46, 169, 139, 0.28) 47% 53%, transparent 54%);
}

.home-category-project .article:first-child h3 {
  max-width: 78%;
  font-size: 22px;
}

.home-category-project .mini-tag {
  color: #1f7469;
  background: rgba(46, 169, 139, 0.09);
  border-color: rgba(46, 169, 139, 0.16);
}

.home-category-project .article-info {
  padding: 6px 10px;
  border: 1px solid rgba(255, 255, 255, 0.68);
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.58);
}

@media (max-width: 980px) {
  .home-category-doctor .article-grid,
  .home-category-project .article-grid {
    grid-template-columns: 1fr;
  }

  .home-category-project .article:first-child {
    grid-column: auto;
  }
}

@media (min-width: 641px) and (max-width: 980px) {
  .home-category-project .article-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .home-category-project .article:first-child {
    grid-column: span 2;
  }
}

@media (max-width: 640px) {
  .home-category-doctor .article {
    grid-template-columns: minmax(96px, 32%) minmax(0, 1fr);
    gap: 12px;
    padding: 14px;
  }

  .home-doctor-thumb {
    min-height: 122px;
    border-radius: 20px;
  }

  .home-doctor-name {
    font-size: 18px;
  }

  .home-doctor-specialties {
    font-size: 13px;
    line-height: 1.55;
  }

  .home-category-project .article:first-child h3 {
    max-width: none;
    font-size: 20px;
  }
}