/* =========================================================================
   Bai Lab Portal — Reusable Components
   来源: GEM-DTA Server styles.css
   ========================================================================= */

/* ---- Page Scaffolding ---- */
.page-stack {
  display: flex;
  flex-direction: column;
  gap: 56px;
  width: min(100%, 1280px);
  margin: 0 auto;
  padding: 28px 28px 80px;
}

.page-header {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding-bottom: 18px;
}

.eyebrow {
  margin: 0;
  color: var(--primary);
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.page-title {
  margin: 0;
  color: var(--ink);
  font-size: clamp(1.8rem, 2.6vw, 2.4rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.page-description {
  margin: 0;
  max-width: 78ch;
  color: var(--ink-2);
  font-size: 1.02rem;
  line-height: 1.7;
}

.page-header-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 8px;
}

/* ---- Hero (Home) — gradient with molecular pattern ---- */
.hero {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  padding: 56px 56px;
  color: #fff;
  background:
    radial-gradient(circle at 85% 20%, rgba(255, 255, 255, 0.18), transparent 45%),
    radial-gradient(circle at 15% 90%, rgba(14, 165, 164, 0.45), transparent 50%),
    linear-gradient(135deg, #0e3c8d 0%, #1857c4 45%, #1aa6a6 100%);
  box-shadow: var(--shadow-lg);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.18) 1.5px, transparent 1.5px);
  background-size: 28px 28px;
  opacity: 0.35;
  pointer-events: none;
  mask-image: linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(0,0,0,1) 25%, rgba(0,0,0,1) 75%, rgba(0,0,0,0) 100%);
}

.hero-simple {
  padding: 64px 48px;
}

.hero-inner-simple {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 820px;
  margin: 0 auto;
}

.hero-inner-simple .hero-actions {
  justify-content: center;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border: 1px solid rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(8px);
}

.hero-title {
  margin: 16px 0 0;
  font-size: clamp(2rem, 3.6vw, 2.9rem);
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: -0.025em;
}

.hero-desc {
  margin: 18px 0 0;
  max-width: 60ch;
  color: rgba(255, 255, 255, 0.92);
  font-size: 1.05rem;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.hero-actions .button-secondary {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.35);
  backdrop-filter: blur(6px);
}

.hero-actions .button-secondary:hover {
  background: rgba(255, 255, 255, 0.22);
  border-color: rgba(255, 255, 255, 0.6);
}

.hero-actions .button-primary {
  background: #fff;
  color: var(--primary-dark);
  border-color: #fff;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.18);
}

.hero-actions .button-primary:hover {
  background: var(--primary-soft);
  color: var(--primary-dark);
}

/* ---- Buttons ---- */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  padding: 0 20px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  font-size: 0.94rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
}

.button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.button-primary {
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  border-color: var(--primary-dark);
  box-shadow: 0 4px 12px rgba(24, 87, 196, 0.25);
}

.button-primary:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 8px 20px rgba(24, 87, 196, 0.32);
  text-decoration: none;
}

.button-secondary, .button-ghost {
  color: var(--primary);
  background: #fff;
  border-color: var(--primary-line);
}

.button-secondary:hover:not(:disabled),
.button-ghost:hover:not(:disabled) {
  background: var(--primary-soft);
  border-color: var(--primary);
  text-decoration: none;
}

/* ---- Panels & Cards ---- */
.panel {
  background: var(--bg-panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.panel:hover {
  box-shadow: var(--shadow);
}

.panel-pad { padding: 22px 24px; }

.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 22px;
  border-bottom: 1px solid var(--line);
  background: #fbfcfe;
  border-radius: var(--radius) var(--radius) 0 0;
}

.panel-title {
  margin: 0;
  font-size: 0.98rem;
  font-weight: 600;
  color: var(--ink);
}

/* ---- Feature Cards — colored icon circles ---- */
.feature-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 26px 22px;
  background: var(--bg-panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.feature-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary-line);
}

.feature-icon {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  box-shadow: 0 6px 14px rgba(24, 87, 196, 0.25);
}

.feature-icon svg {
  width: 24px;
  height: 24px;
}

.feature-icon-teal { background: linear-gradient(135deg, var(--teal), #047371); box-shadow: 0 6px 14px rgba(14, 165, 164, 0.28); }
.feature-icon-amber { background: linear-gradient(135deg, #f59e0b, var(--amber)); box-shadow: 0 6px 14px rgba(217, 119, 6, 0.28); }
.feature-icon-coral { background: linear-gradient(135deg, #ef6f7b, var(--coral)); box-shadow: 0 6px 14px rgba(219, 84, 97, 0.28); }
.feature-icon-violet { background: linear-gradient(135deg, #8b76e0, var(--violet)); box-shadow: 0 6px 14px rgba(109, 78, 209, 0.28); }

.feature-title {
  margin: 0;
  color: var(--ink);
  font-size: 1.05rem;
  font-weight: 600;
}

.feature-text {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.65;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

/* ---- Sections ---- */
.content-section {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.section-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  text-align: center;
  max-width: 760px;
  margin: 0 auto;
}

.section-title {
  margin: 0;
  color: var(--ink);
  font-size: clamp(1.45rem, 2.4vw, 1.85rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.section-description {
  margin: 0;
  max-width: 70ch;
  color: var(--muted);
  font-size: 0.98rem;
  line-height: 1.7;
}

.section-divider {
  width: 56px;
  height: 3px;
  margin: 4px auto 0;
  background: linear-gradient(90deg, var(--primary), var(--teal));
  border-radius: 99px;
}

/* ---- Callouts ---- */
.callout {
  display: grid;
  grid-template-columns: 4px 1fr;
  gap: 14px;
  padding: 16px 20px 16px 0;
  border: 1px solid var(--line);
  border-left: 0;
  border-radius: var(--radius);
  background: var(--bg-panel);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.callout::before { content: ""; background: var(--primary); }

.callout-body > :first-child { margin-top: 0; }
.callout-body > :last-child { margin-bottom: 0; }

.callout-title {
  margin: 0 0 6px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--ink);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.callout-cite { background: var(--amber-soft); }
.callout-cite::before { background: var(--amber); }
.callout-note::before { background: var(--primary); }

/* ---- Data Table ---- */
.data-table-wrap {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg-panel);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
}

.data-table thead th {
  text-align: left;
  padding: 12px 16px;
  background: linear-gradient(180deg, #f4f7fc, #eaf0f8);
  color: var(--ink-2);
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border-bottom: 1px solid var(--line-strong);
  white-space: nowrap;
}

.data-table tbody td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  vertical-align: middle;
}

.data-table tbody tr:last-child td { border-bottom: 0; }

.data-table tbody tr {
  transition: background var(--transition);
}

.data-table tbody tr:hover { background: var(--primary-soft); }

/* ---- MetaStrip ---- */
.meta-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg-panel);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.meta-strip > .meta-cell {
  padding: 16px 20px;
  border-right: 1px solid var(--line);
  background: var(--bg-panel);
}

.meta-strip > .meta-cell:last-child { border-right: 0; }

.meta-cell {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.meta-cell .meta-label {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.meta-cell .meta-value {
  color: var(--ink);
  font-size: 1.1rem;
  font-weight: 700;
  font-family: var(--font-mono);
  letter-spacing: -0.005em;
}

/* ---- Contact Grid ---- */
.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: 32px;
  align-items: start;
}

.contact-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.contact-row {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 18px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}

.contact-row:last-child { border-bottom: 0; }

.contact-row dt {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.contact-row dd { margin: 0; color: var(--ink); }

.contact-row dd .lead {
  font-weight: 600;
  margin: 0 0 4px;
}

.contact-row dd .sub {
  color: var(--muted);
  font-size: 0.86rem;
  margin: 0;
}

/* ---- About Grid (for People page) ---- */
.about-grid {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 44px;
  align-items: start;
}

.about-content {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.about-content h3 {
  margin: 0 0 14px;
  color: var(--ink);
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--primary-soft);
  display: flex;
  align-items: center;
  gap: 10px;
}

.about-content h3::before {
  content: "";
  width: 4px;
  height: 18px;
  background: linear-gradient(180deg, var(--primary), var(--teal));
  border-radius: 2px;
}

.about-content p {
  margin: 0 0 10px;
  color: var(--ink-2);
  line-height: 1.75;
}

/* ---- Timeline (for News) ---- */
.timeline-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  position: relative;
}

.timeline-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
  padding: 28px 18px;
  background: var(--bg-panel);
  border: 1px solid var(--line);
  border-right: 0;
  transition: var(--transition);
}

.timeline-card:first-child { border-radius: var(--radius) 0 0 var(--radius); }
.timeline-card:last-child { border-radius: 0 var(--radius) var(--radius) 0; border-right: 1px solid var(--line); }

.timeline-card:hover {
  background: var(--bg-tint);
  transform: translateY(-2px);
  box-shadow: var(--shadow);
  z-index: 1;
}

.timeline-step-circle {
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--teal));
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 1rem;
  box-shadow: 0 8px 18px rgba(24, 87, 196, 0.22);
}

.timeline-title {
  margin: 4px 0 0;
  color: var(--ink);
  font-size: 1rem;
  font-weight: 600;
}

.timeline-copy {
  margin: 0;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.65;
}

.timeline-card:not(:last-child)::after {
  content: "";
  position: absolute;
  right: -10px;
  top: 50px;
  width: 20px;
  height: 2px;
  background: var(--line-strong);
  z-index: 1;
}

/* ---- Empty State ---- */
.empty-state {
  padding: 22px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  color: var(--muted);
  background: var(--bg-panel);
  font-size: 0.9rem;
  text-align: center;
}

/* ---- Utility ---- */
.muted { color: var(--muted); }
