@import url('https://fonts.googleapis.com/css2?family=Marcellus&family=Noto+Serif+SC:wght@500&display=swap');

:root {
  --ruc-red: #9e0b0f;
  --ruc-dark: #7a080b;
  --ruc-gold: #d4af37;
  --bg-gray: #f4f4f4;
  --text-main: #333;
  --text-light: #666;
  --hero-display-font: 'Marcellus', 'Noto Serif SC', 'Songti SC', serif;
  --hero-body-font: 'Noto Sans SC', 'Microsoft YaHei', 'PingFang SC', sans-serif;
}

main.homepage-main {
  max-width: 100%;
  padding: 0;
  margin: 0;
  background-color: var(--bg-gray);
}

main.homepage-main .alert {
  margin: 0 auto;
  max-width: 1200px;
  width: 100%;
}

body {
  color: var(--text-main);
}

.homepage-wrapper {
  font-family: var(--hero-body-font);
}

.homepage-wrapper a {
  text-decoration: none;
  color: inherit;
}

.homepage-wrapper ul {
  list-style: none;
}

.anchor-target {
  scroll-margin-top: 90px;
}

.homepage-hero {
  background: linear-gradient(rgba(158, 11, 15, 0.92), rgba(52, 3, 6, 0.8));
  color: #fff;
  text-align: center;
  padding: clamp(70px, 12vh, 130px) 20px 60px;
  position: relative;
  overflow: hidden;
  min-height: 78vh;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  gap: 24px;
}

.homepage-hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background-position: var(--hero-photo-focus, center 28%);
  background-size: cover;
  background-repeat: no-repeat;
  background-image:
    linear-gradient(120deg, rgba(20, 0, 0, 0.65), rgba(158, 11, 15, 0.2) 55%, rgba(244, 244, 244, 0.05)),
    linear-gradient(180deg, rgba(158, 11, 15, 0.95) 0%, rgba(158, 11, 15, 0.78) 45%, rgba(19, 0, 0, 0.35) 100%),
    var(--hero-photo, var(--hero-bg, url('https://images.unsplash.com/photo-1523050854058-8df90110c9f1?auto=format&fit=crop&w=1200&q=80')));
  opacity: 1;
  z-index: 0;
  filter: contrast(1.05) saturate(0.95);
}

.homepage-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(158, 11, 15, 0.15) 0%, rgba(158, 11, 15, 0.3) 65%, rgba(60, 6, 6, 0.5) 100%);
  z-index: 1;
}

.homepage-hero > * {
  position: relative;
  z-index: 2;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 760px;
  margin: 0 auto;
  margin-top: -30px;
  padding: 28px 36px 34px;
  backdrop-filter: blur(10px);
  background: linear-gradient(135deg, rgba(8, 0, 0, 0.35), rgba(158, 11, 15, 0.25));
  border-radius: 28px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  box-shadow: 0 25px 55px rgba(0, 0, 0, 0.35);
  display: flex;
  flex-direction: column;
  gap: 16px;
  text-align: center;
}

.hero-content h1 {
  font-family: var(--hero-display-font);
  font-size: clamp(2.4rem, 4vw, 3.1rem);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0;
  color: #fff5f2;
}

.hero-content h2 {
  font-family: var(--hero-display-font);
  font-size: clamp(1.4rem, 2.6vw, 1.9rem);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin: 0;
  color: rgba(255, 236, 225, 0.95);
}

.hero-content p {
  font-size: 1.05rem;
  line-height: 1.8;
  color: rgba(255, 255, 255, 0.78);
  margin: 0;
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 10px;
}

.homepage-wrapper .btn-solid,
.homepage-wrapper .btn-outline,
.homepage-wrapper .btn-text {
  border-radius: 999px;
  padding: 10px 22px;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.homepage-wrapper .btn-solid {
  background: #fff;
  color: var(--ruc-red);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.08);
}

.homepage-wrapper .btn-outline {
  border: 1px solid rgba(255, 255, 255, 0.7);
  color: #fff;
}

.homepage-wrapper .btn-text {
  color: var(--ruc-gold);
  padding: 8px 10px;
}

.homepage-wrapper .btn-solid:hover,
.homepage-wrapper .btn-outline:hover,
.homepage-wrapper .btn-text:hover {
  transform: translateY(-2px);
}

.section-title {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 40px;
  color: var(--ruc-red);
  position: relative;
  padding-bottom: 15px;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background-color: var(--ruc-gold);
}

.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
}

.photo-item {
  background-color: #ddd;
  border-radius: 12px;
  overflow: hidden;
  position: relative;
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  aspect-ratio: 4 / 3;
}

.photo-item:hover {
  transform: translateY(-4px);
  z-index: 10;
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.18);
}

.photo-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.gallery-section {
  padding: 70px 5%;
  background-color: #fff;
}

.album-rail {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.album-card {
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-height: 420px;
}

.album-card__cover {
  position: relative;
  padding-bottom: 55%;
  background-size: cover;
  background-position: center;
}

.album-card__badge {
  position: absolute;
  top: 16px;
  left: 16px;
  background: rgba(158, 11, 15, 0.9);
  color: #fff;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.85rem;
}

.album-card__body {
  padding: 24px 24px 28px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.album-card__title-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 12px;
}

.album-card__title-row h3 {
  font-size: 1.3rem;
  margin: 0;
}

.album-chip {
  background: rgba(158, 11, 15, 0.08);
  color: var(--ruc-red);
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.9rem;
}

.album-card__desc {
  color: var(--text-light);
  margin-bottom: 16px;
}

.album-card__preview {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
  gap: 10px;
}

.album-card__preview figure {
  margin: 0;
  border-radius: 10px;
  overflow: hidden;
  position: relative;
}

.album-card__preview img {
  width: 100%;
  height: 90px;
  object-fit: cover;
  display: block;
}

.album-card__preview figcaption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  font-size: 0.75rem;
  color: #fff;
  padding: 4px 8px;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.5));
}

.announcement-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}

.announcement-card {
  background: #fff;
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
  border-top: 4px solid var(--ruc-red);
  display: flex;
  flex-direction: column;
  min-height: 210px;
}

.announcement-card h3 {
  font-size: 1.2rem;
  margin-bottom: 10px;
}

.announcement-card h3 a {
  color: inherit;
}

.announcement-card p {
  flex: 1;
  color: var(--text-light);
}

.announcement-meta {
  font-size: 0.9rem;
  color: var(--text-light);
  margin-bottom: 8px;
}

.announcement-chip-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 25px;
}

.announcement-chip-bar a {
  padding: 6px 14px;
  border-radius: 20px;
  border: 1px solid #ddd;
  background: #fff;
  font-size: 0.9rem;
  transition: all 0.2s ease;
}

.announcement-chip-bar a.active,
.announcement-chip-bar a:hover {
  background: var(--ruc-red);
  color: #fff;
  border-color: var(--ruc-red);
}

.section-cta {
  margin-top: 30px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.section-cta.column {
  flex-direction: column;
  align-items: stretch;
}

.section-cta .btn-solid {
  background: var(--ruc-red);
  color: #fff;
  box-shadow: 0 10px 20px rgba(158, 11, 15, 0.25);
}

.section-cta .btn-outline {
  border: 1px solid var(--ruc-red);
  color: var(--ruc-red);
  background: #fff;
}

.section-cta .btn-text {
  color: var(--ruc-gold);
}

.timeline-section {
  padding: 70px 5% 80px;
  background-color: var(--bg-gray);
}

.timeline-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
  gap: 40px;
  align-items: start;
}

.timeline-column,
.announcements-column {
  background: #fff;
  border-radius: 12px;
  padding: 40px 35px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
}

.announcements-column {
  position: sticky;
  top: 100px;
}

.timeline {
  position: relative;
  max-width: 1000px;
  margin: 0 auto;
}

.timeline::after {
  content: '';
  position: absolute;
  width: 4px;
  background-color: var(--ruc-red);
  top: 0;
  bottom: 0;
  left: 50%;
  margin-left: -2px;
}

.timeline-container {
  padding: 10px 40px;
  position: relative;
  width: 50%;
}

.timeline-container.left {
  left: 0;
}

.timeline-container.right {
  left: 50%;
}

.timeline-container::after {
  content: '';
  position: absolute;
  width: 20px;
  height: 20px;
  right: -10px;
  background-color: #fff;
  border: 4px solid var(--ruc-gold);
  top: 20px;
  border-radius: 50%;
  z-index: 1;
}

.timeline-container.right::after {
  left: -10px;
}

.timeline-content {
  padding: 20px 30px;
  background-color: #fff;
  border-radius: 6px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  border-left: 4px solid var(--ruc-red);
}

.timeline-content.highlight {
  border-color: var(--ruc-gold);
  box-shadow: 0 8px 24px rgba(212, 175, 55, 0.3);
}

.timeline-content.visible {
  opacity: 1 !important;
  transform: translateY(0) !important;
}

.timeline-content h3 {
  color: var(--ruc-red);
  font-size: 1.2rem;
  margin-bottom: 6px;
}

.timeline-content .date {
  color: var(--text-light);
  font-size: 0.9rem;
  font-style: italic;
  margin-bottom: 12px;
  display: block;
}

.timeline-tags {
  margin-top: 10px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 0.85rem;
}

.timeline-tags .badge {
  background: rgba(158, 11, 15, 0.1);
  color: var(--ruc-red);
  border-radius: 999px;
  padding: 4px 10px;
}

.timeline-tags a {
  color: var(--ruc-gold);
  text-decoration: underline;
}

.timeline-table-wrapper {
  margin-top: 30px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px #eee;
}

.timeline-table-wrapper table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
}

.timeline-table-wrapper th,
.timeline-table-wrapper td {
  padding: 12px 16px;
  border-bottom: 1px solid #f0f0f0;
  text-align: left;
}

.timeline-table-wrapper thead {
  background: rgba(158, 11, 15, 0.05);
  color: var(--ruc-red);
}

.homepage-footer {
  background-color: #333;
  color: #fff;
  text-align: center;
  padding: 40px 20px;
}

.homepage-footer p {
  opacity: 0.75;
  font-size: 0.95rem;
}

@media (max-width: 992px) {
  .announcement-card {
    min-height: 180px;
  }

  .timeline-grid {
    grid-template-columns: 1fr;
  }

  .announcements-column,
  .timeline-column {
    position: static;
  }
}

@media (max-width: 768px) {
  .homepage-hero {
    min-height: 68vh;
    padding: 70px 16px 50px;
  }
  .homepage-hero::after {
    opacity: 0.4;
  }
  .hero-content {
    margin-top: -10px;
    padding: 22px 20px 26px;
    border-radius: 22px;
    gap: 12px;
  }
  .hero-content h1 {
    font-size: 2rem;
    letter-spacing: 0.05em;
  }
  .hero-content h2 {
    font-size: 1.2rem;
    letter-spacing: 0.12em;
  }
  .hero-content p {
    font-size: 0.95rem;
    line-height: 1.6;
  }
  .timeline::after {
    left: 31px;
  }
  .timeline-container {
    width: 100%;
    padding-left: 70px;
    padding-right: 25px;
  }
  .timeline-container::after {
    left: 21px;
  }
  .timeline-container.right {
    left: 0;
  }

}
