/* ===================== 基础重置 ===================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "PingFang SC", "Microsoft Yahei", sans-serif;
}
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}
body {
  background-color: #f8f9fa;
  color: #333;
  line-height: 1.6;
  font-size: 15px;
}
.rainbow-bar {
  height: 4px;
  background: linear-gradient(
    90deg,
    #ff0018,
    #ffa52c,
    #ffff41,
    #008018,
    #0000f9,
    #86007d
  );
}

/* ===================== 导航栏（移动优先） ===================== */
header.site-header {
  background-color: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  position: sticky;
  top: 0;
  z-index: 100;
}
.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 16px;
  display: flex;
  flex-direction: column;
}
.logo {
  font-size: 18px;
  font-weight: bold;
  color: #6c5ce7;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 12px 0;
  justify-content: center;
}
nav.main-nav ul.nav-links {
  display: flex;
  list-style: none;
  gap: 12px;
  padding: 0 0 10px;
  flex-wrap: wrap;
  justify-content: center;
}
.nav-links a {
  text-decoration: none;
  color: #555;
  font-size: 14px;
  padding: 6px 8px;
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  transition: color 0.3s;
}
.nav-links a:hover,
.nav-links a.active {
  color: #6c5ce7;
  font-weight: 500;
}

/* ===================== 主体容器/卡片 ===================== */
main.site-main {
  max-width: 1200px;
  margin: 20px auto;
  padding: 0 16px;
}
.card {
  background: #fff;
  border-radius: 10px;
  padding: 18px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  margin-bottom: 16px;
}
.card h2 {
  color: #2d3436;
  margin-bottom: 14px;
  font-size: 19px;
  border-left: 4px solid #6c5ce7;
  padding-left: 10px;
}
.page-title {
  font-size: 22px;
  color: #2d3436;
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid #f0f0f0;
  line-height: 1.4;
}

/* ===================== 面包屑 ===================== */
nav.breadcrumb {
  padding: 10px 14px;
  background: #fff;
  border-radius: 8px;
  margin-bottom: 16px;
  font-size: 13px;
  color: #888;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
  overflow-x: auto;
  white-space: nowrap;
}
.breadcrumb a {
  color: #6c5ce7;
  text-decoration: none;
}
.breadcrumb a:hover {
  text-decoration: underline;
}
.breadcrumb .separator {
  margin: 0 6px;
  color: #ccc;
}
.breadcrumb .current {
  color: #333;
  font-weight: 500;
}

/* ===================== 轮播 ===================== */
.slider-container {
  max-width: 1200px;
  margin: 16px auto 0;
  padding: 0 16px;
}
.slider {
  position: relative;
  width: 100%;
  height: 220px;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.1);
}
.slider-track {
  display: flex;
  height: 100%;
  transition: transform 0.5s ease;
}
.slide {
  min-width: 100%;
  height: 100%;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  text-align: center;
}
.slide img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}
.slide:nth-child(1) {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}
.slide:nth-child(2) {
  background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}
.slide:nth-child(3) {
  background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
}
.slide-content {
  position: relative;
  z-index: 2;
  padding: 0 20px;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}
.slide-content h2 {
  font-size: 20px;
  margin-bottom: 8px;
  border: none;
  padding: 0;
  color: #fff;
}
.slide-content p {
  font-size: 14px;
  opacity: 0.95;
}
.slider-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.25);
  border: none;
  color: #fff;
  font-size: 18px;
  cursor: pointer;
  z-index: 3;
  min-width: 36px;
}
.arrow-prev {
  left: 12px;
}
.arrow-next {
  right: 12px;
}
.slider-dots {
  position: absolute;
  bottom: 14px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 3;
}
.dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
}
.dot.active {
  background: #fff;
  width: 24px;
  border-radius: 4px;
}

/* ===================== Hero ===================== */
section.hero-banner {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: #fff;
  padding: 28px 20px;
  border-radius: 10px;
  margin: 24px 0 20px;
  display: flex;
  flex-direction: column-reverse;
  align-items: center;
  gap: 20px;
  text-align: center;
}
.hero-text h1 {
  font-size: 24px;
  margin-bottom: 14px;
}
.hero-text p {
  font-size: 14px;
  opacity: 0.95;
  line-height: 1.8;
  margin-bottom: 20px;
  text-align: left;
}
.hero-illustration {
  flex-shrink: 0;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  padding: 16px;
}
.hero-illustration svg {
  width: 180px;
  height: auto;
}
.btn {
  display: inline-flex;
  align-items: center;
  padding: 10px 26px;
  border-radius: 6px;
  text-decoration: none;
  font-size: 15px;
  border: none;
  cursor: pointer;
  min-height: 44px;
}
.btn-primary {
  background-color: #fff;
  color: #667eea;
  font-weight: 500;
}

/* ===================== 首页板块 ===================== */
.section-title {
  text-align: center;
  font-size: 21px;
  color: #2d3436;
  margin-bottom: 6px;
}
.section-subtitle {
  text-align: center;
  color: #888;
  font-size: 14px;
  margin-bottom: 20px;
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}
.stats-item {
  background: #fff;
  border-radius: 10px;
  padding: 20px 12px;
  text-align: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}
.stats-number {
  font-size: 24px;
  font-weight: bold;
  color: #6c5ce7;
  margin-bottom: 4px;
}
.stats-label {
  color: #666;
  font-size: 13px;
}

.topic-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-bottom: 24px;
}
.topic-card {
  background: #fff;
  border-radius: 10px;
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  transition:
    transform 0.3s,
    box-shadow 0.3s;
}
.topic-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(108, 92, 231, 0.12);
}
.topic-icon {
  font-size: 24px;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f0edff;
  border-radius: 8px;
  flex-shrink: 0;
}
.topic-info h3 {
  font-size: 15px;
  color: #2d3436;
  margin-bottom: 2px;
}
.topic-info p {
  font-size: 12px;
  color: #999;
}

.story-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-bottom: 24px;
}
.story-card {
  background: #fff;
  border-radius: 10px;
  padding: 20px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  position: relative;
}
.story-card::before {
  content: "“";
  font-size: 50px;
  color: #dcd6ff;
  position: absolute;
  top: 8px;
  left: 12px;
  font-family: serif;
  line-height: 1;
}
.story-content {
  position: relative;
  z-index: 1;
  padding-left: 24px;
  color: #555;
  font-size: 14px;
  line-height: 1.8;
  margin-bottom: 12px;
}
.story-author {
  text-align: right;
  color: #6c5ce7;
  font-size: 13px;
  font-weight: 500;
}

.steps-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
.step-item {
  text-align: center;
  padding: 16px 8px;
}
.step-number {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, #a29bfe, #6c5ce7);
  color: #fff;
  font-size: 20px;
  font-weight: bold;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 12px;
}
.step-item h3 {
  font-size: 16px;
  color: #2d3436;
  margin-bottom: 6px;
}
.step-item p {
  font-size: 13px;
  color: #666;
}

/* ===================== 活动卡片 ===================== */
.event-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin-bottom: 24px;
}
.event-card {
  background: #fff;
  border-radius: 10px;
  padding: 18px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  border-left: 3px solid #6c5ce7;
}
.event-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}
.event-title {
  font-size: 16px;
  font-weight: 500;
  color: #2d3436;
}
.event-tag {
  background: #f0edff;
  color: #6c5ce7;
  font-size: 12px;
  padding: 2px 8px;
  border-radius: 4px;
  flex-shrink: 0;
}
.event-meta {
  font-size: 13px;
  color: #888;
  margin-bottom: 6px;
}
.event-desc {
  font-size: 14px;
  color: #555;
  line-height: 1.7;
}
.event-note {
  font-size: 12px;
  color: #999;
  margin-top: 8px;
}

/* ===================== 帖子条目 ===================== */
.post-item {
  padding: 14px 0;
  border-bottom: 1px solid #f1f2f6;
}
.post-item:last-child {
  border-bottom: none;
}
.post-title {
  font-size: 15px;
  color: #2d3436;
  margin-bottom: 4px;
  font-weight: 500;
}
.post-meta {
  font-size: 12px;
  color: #999;
  margin-bottom: 6px;
}
.post-excerpt {
  font-size: 14px;
  color: #666;
  line-height: 1.7;
}

/* ===================== 提示框/时间线/清单 ===================== */
.tip-box {
  background: #f0f9ff;
  border-left: 4px solid #38bdf8;
  padding: 14px 16px;
  border-radius: 4px;
  margin: 14px 0;
  font-size: 14px;
  color: #075985;
  line-height: 1.7;
}
.warning-box {
  background: #fffbeb;
  border-left: 4px solid #f59e0b;
  padding: 14px 16px;
  border-radius: 4px;
  margin: 14px 0;
  font-size: 14px;
  color: #92400e;
  line-height: 1.7;
}
.timeline {
  border-left: 2px solid #e0e7ff;
  padding-left: 20px;
  margin: 20px 0;
}
.timeline-item {
  position: relative;
  margin-bottom: 20px;
}
.timeline-item::before {
  content: "";
  position: absolute;
  left: -26px;
  top: 4px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #6c5ce7;
}
.timeline-date {
  font-weight: 500;
  color: #6c5ce7;
  font-size: 14px;
  margin-bottom: 4px;
}
.timeline-content {
  font-size: 14px;
  color: #555;
  line-height: 1.7;
}

.safety-list {
  padding-left: 20px;
  color: #555;
  line-height: 2;
  font-size: 14px;
}
.safety-list li::marker {
  color: #d63031;
}

.article-content p {
  margin-bottom: 14px;
  font-size: 15px;
  color: #444;
  line-height: 1.8;
}
.article-content h3 {
  font-size: 17px;
  color: #2d3436;
  margin: 20px 0 10px;
}

/* ===================== 通用列表/交友卡片 ===================== */
.feature-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-top: 16px;
}
.feature-item {
  text-align: center;
  padding: 16px;
}
.feature-item .icon {
  width: 54px;
  height: 54px;
  background: linear-gradient(135deg, #a29bfe, #6c5ce7);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 22px;
  margin: 0 auto 12px;
}
.list-item {
  padding: 14px 0;
  border-bottom: 1px solid #f1f2f6;
}
.list-item:last-child {
  border-bottom: none;
}
.list-item h3 {
  font-size: 16px;
  color: #2d3436;
  margin-bottom: 4px;
}
.list-item .meta {
  font-size: 12px;
  color: #999;
  margin-bottom: 6px;
}
.list-item p {
  color: #666;
  font-size: 14px;
}

.user-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
.user-card {
  text-align: center;
  transition: transform 0.3s;
}
.user-card:hover {
  transform: translateY(-3px);
}
.avatar {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  background: linear-gradient(135deg, #ff9a9e, #fecfef);
  margin: 0 auto 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: #fff;
}
.user-card .name {
  font-weight: 500;
  font-size: 15px;
  margin-bottom: 4px;
}
.user-card .info {
  font-size: 12px;
  color: #666;
  margin-bottom: 10px;
}
.btn-small {
  padding: 6px 14px;
  background-color: #6c5ce7;
  color: #fff;
  font-size: 13px;
  border-radius: 4px;
  min-height: 32px;
  border: none;
  cursor: pointer;
}

/* ===================== FAQ / 提示 / 内链 ===================== */
.faq-item {
  margin-bottom: 10px;
  border: 1px solid #eee;
  border-radius: 8px;
  overflow: hidden;
}
.faq-question {
  padding: 14px 16px;
  background-color: #fafafa;
  cursor: pointer;
  font-weight: 500;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
  min-height: 48px;
}
.faq-answer {
  padding: 0 16px;
  max-height: 0;
  overflow: hidden;
  transition: all 0.3s;
  color: #666;
  font-size: 13px;
}
.faq-item.active .faq-answer {
  padding: 14px 16px;
  max-height: 400px;
}
.notice {
  background-color: #fff5f5;
  border-left: 4px solid #ff7675;
  padding: 12px 14px;
  border-radius: 4px;
  font-size: 13px;
  color: #d63031;
  margin: 14px 0;
  line-height: 1.7;
}
.inner-link {
  color: #6c5ce7;
  text-decoration: none;
  border-bottom: 1px dashed #c5befa;
}
.inner-link:hover {
  border-bottom-style: solid;
}

/* ===================== 页脚 ===================== */
footer.site-footer {
  background-color: #2d3436;
  color: #b2bec3;
  padding: 30px 16px 20px;
  margin-top: 40px;
  font-size: 13px;
}
.footer-container {
  max-width: 1200px;
  margin: 0 auto 24px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  text-align: center;
}
.footer-block h4 {
  color: #fff;
  margin-bottom: 12px;
  font-size: 15px;
}
nav.footer-nav .footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  justify-content: center;
}
.footer-links a {
  color: #b2bec3;
  text-decoration: none;
  font-size: 13px;
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  transition: color 0.3s;
}
.footer-links a:hover {
  color: #a29bfe;
}
.copyright {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 18px;
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
}
.copyright p {
  margin-bottom: 6px;
  line-height: 1.7;
}

/* ===================== 桌面端向上适配 ===================== */
@media (min-width: 768px) {
  body {
    font-size: 15px;
  }
  .nav-container {
    flex-direction: row;
    justify-content: space-between;
    height: 64px;
    padding: 0 20px;
  }
  .logo {
    font-size: 20px;
    padding: 0;
    justify-content: flex-start;
  }
  nav.main-nav ul.nav-links {
    gap: 24px;
    padding: 0;
    flex-wrap: nowrap;
    justify-content: flex-end;
  }
  .nav-links a {
    font-size: 15px;
  }

  main.site-main {
    margin: 30px auto;
    padding: 0 20px;
  }
  .card {
    padding: 24px;
    border-radius: 12px;
    margin-bottom: 20px;
  }
  .card h2 {
    font-size: 22px;
  }
  .page-title {
    font-size: 28px;
  }

  .slider-container {
    margin: 20px auto 0;
    padding: 0 20px;
  }
  .slider {
    height: 420px;
    border-radius: 12px;
  }
  .slide-content h2 {
    font-size: 32px;
  }
  .slide-content p {
    font-size: 17px;
  }
  .slider-arrow {
    width: 44px;
    height: 44px;
    font-size: 20px;
  }
  .arrow-prev {
    left: 20px;
  }
  .arrow-next {
    right: 20px;
  }

  section.hero-banner {
    flex-direction: row;
    justify-content: space-between;
    padding: 48px 40px;
    text-align: left;
    gap: 40px;
  }
  .hero-text h1 {
    font-size: 34px;
  }
  .hero-text p {
    font-size: 15.5px;
    text-align: justify;
  }
  .hero-illustration svg {
    width: 280px;
  }

  .section-title {
    font-size: 26px;
  }
  .stats-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
  }
  .stats-number {
    font-size: 32px;
  }
  .topic-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
  }
  .story-grid {
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 20px;
  }
  .steps-grid {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
  }
  .event-grid {
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 18px;
  }
  .feature-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  }
  .user-grid {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 20px;
  }

  .footer-container {
    flex-direction: row;
    justify-content: space-around;
    text-align: left;
  }
  nav.footer-nav .footer-links {
    justify-content: flex-start;
  }
}
/* Functional fixes only; original page appearance retained. */
[hidden] {
  display: none !important;
}
.slider-pause {
  display: block;
  margin: 10px auto;
  padding: 8px 16px;
  border: 1px solid #ddd;
  border-radius: 6px;
  background: #fff;
  color: #555;
}
.slider-dots button {
  border: 0;
  padding: 0;
}
.faq-question:focus-visible {
  outline: 2px solid #6c5ce7;
  outline-offset: -3px;
}
.faq-item.active .faq-answer {
  max-height: none;
}
html:not(.js) .faq-answer {
  max-height: none;
  padding: 14px 16px;
}
.faq-item[id] {
  scroll-margin-top: 150px;
}
.btn-small[disabled] {
  opacity: 0.6;
  cursor: not-allowed;
}
.breadcrumb {
  max-width: 1200px;
  margin: 16px auto;
  padding: 0 16px;
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .slider-track {
    transition: none;
  }
}

/* Local photographs and readable article additions. */
.skip-link {
  position: absolute;
  left: 16px;
  top: -80px;
  z-index: 20;
  padding: 12px;
  background: #fff;
  color: #38296b;
}
.skip-link:focus {
  top: 8px;
}
.page-photo {
  margin: 0 0 24px;
}
.page-photo img {
  width: 100%;
  height: auto;
  aspect-ratio: 1920 / 500;
  object-fit: cover;
  border-radius: 10px;
  display: block;
}
.page-photo figcaption,
.image-caption,
.source-note {
  color: #626262;
  font-size: 13px;
  line-height: 1.8;
}
.image-caption {
  margin-top: 6px;
}
.hero-illustration img {
  width: 280px;
  max-width: 100%;
  height: auto;
  border-radius: 12px;
}
.slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.48);
  pointer-events: none;
}
.reading-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}
.reading-section {
  padding: 24px 0;
  border-bottom: 1px solid #e6e6ef;
  scroll-margin-top: 24px;
}
.reading-section:last-child {
  border: 0;
}
.reading-section p {
  margin: 14px 0;
  line-height: 1.9;
}
.table-scroll {
  overflow-x: auto;
}
table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
  text-align: left;
}
caption {
  text-align: left;
  margin-bottom: 12px;
  font-weight: 600;
}
th,
td {
  border: 1px solid #ddd;
  padding: 12px;
  vertical-align: top;
}
th {
  background: #f7f5fc;
}
button.faq-question {
  width: 100%;
  border: 0;
  background: transparent;
  font: inherit;
  text-align: left;
  color: inherit;
}
@media (max-width: 640px) {
  .reading-grid {
    grid-template-columns: 1fr;
  }
  .page-photo img {
    min-height: 130px;
  }
}

.article-toc {
  margin: 0 0 24px;
  padding: 20px 24px;
  border: 1px solid #dedbe9;
  border-radius: 10px;
  background: #fff;
}
.article-toc h2 {
  font-size: 18px;
  margin: 0 0 12px;
}
.article-toc ul {
  padding-left: 20px;
  line-height: 1.9;
}
