:root {
  --blue-900: #0a2540;
  --blue-800: #0f3560;
  --blue-600: #16548e;
  --blue-500: #1f6feb;
  --blue-100: #e8f0fe;
  --bg: #f4f7fb;
  --card: #ffffff;
  --text: #1c2b3a;
  --muted: #5a6b7d;
  --border: #dbe4f0;
  --shadow: 0 1px 3px rgba(10, 37, 64, .08), 0 8px 24px rgba(10, 37, 64, .06);
  --shadow-hover: 0 2px 6px rgba(10, 37, 64, .1), 0 16px 40px rgba(10, 37, 64, .12);
  --radius: 14px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; }

a { color: var(--blue-600); text-decoration: none; }
a:hover { text-decoration: none; }

.container {
  max-width: 980px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ---------- top bar ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 56px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 16px;
  color: var(--blue-900);
}

.brand-mark {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--blue-500), var(--blue-800));
  color: #fff;
  font-size: 15px;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  letter-spacing: -.5px;
}

.brand small {
  font-weight: 500;
  color: var(--muted);
  font-size: 12px;
}

.back {
  font-size: 14px;
  font-weight: 600;
  color: var(--blue-800);
}
.back:hover { color: var(--blue-500); }

.topnav { display: flex; gap: 6px; }

.nav-link {
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
  padding: 7px 14px;
  border-radius: 999px;
}
.nav-link:hover { background: var(--blue-100); color: var(--blue-800); }
.nav-link.active { background: var(--blue-100); color: var(--blue-800); }

/* ---------- hero ---------- */
.hero { padding: 48px 0 28px; }

.kicker {
  display: inline-block;
  margin: 0 0 10px;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--blue-100);
  color: var(--blue-800);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .3px;
}

h1 {
  margin: 0 0 12px;
  font-size: 34px;
  line-height: 1.15;
  color: var(--blue-900);
  letter-spacing: -.5px;
}

.lead {
  margin: 0;
  max-width: 720px;
  font-size: 17px;
  color: var(--muted);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 20px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--blue-800);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: background .15s, border-color .15s, transform .15s;
}
.btn:hover { border-color: var(--blue-500); background: var(--blue-100); }
.btn:active { transform: translateY(1px); }

.btn-primary {
  background: var(--blue-600);
  border-color: var(--blue-600);
  color: #fff;
}
.btn-primary:hover { background: var(--blue-500); border-color: var(--blue-500); }

/* ---------- feed (main page) ---------- */
.feed {
  display: flex;
  flex-direction: column;
  gap: 26px;
  padding: 10px 0 50px;
}

.card {
  display: block;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s;
}
.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
  border-color: #bcd0ea;
}

.card-thumb {
  display: block;
  width: 100%;
  height: auto;
  background: #eef3fa;
  border-bottom: 1px solid var(--border);
}

.card-body { padding: 20px 24px 22px; }

.card-kicker {
  margin: 0 0 4px;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: .6px;
  text-transform: uppercase;
  color: var(--blue-500);
}

.card h2 {
  margin: 0 0 8px;
  font-size: 22px;
  color: var(--blue-900);
  letter-spacing: -.2px;
}

.card p {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 15px;
  max-width: 640px;
}

.card-meta { display: flex; flex-wrap: wrap; gap: 8px; }

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 12px;
  border-radius: 999px;
  background: var(--blue-100);
  color: var(--blue-800);
  font-size: 12.5px;
  font-weight: 600;
}

.card-arrow {
  position: absolute;
}

/* ---------- detail pages ---------- */
.section { padding: 30px 0 6px; scroll-margin-top: 76px; }

.section-title {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin: 0 0 18px;
  font-size: 21px;
  color: var(--blue-900);
}
.section-title::before {
  content: "";
  width: 5px;
  height: 22px;
  border-radius: 3px;
  background: var(--blue-500);
  align-self: center;
}

.section-count {
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
}

.slides { display: flex; flex-direction: column; gap: 22px; padding-bottom: 10px; }

.slide {
  position: relative;
  margin: 0;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.slide .num {
  position: absolute;
  top: 12px;
  left: 14px;
  z-index: 2;
  padding: 3px 12px;
  border-radius: 999px;
  background: rgba(10, 37, 64, .82);
  color: #fff;
  font-size: 12.5px;
  font-weight: 700;
}

.slide img {
  display: block;
  width: 100%;
  height: auto;
}

.slide figcaption {
  padding: 12px 18px;
  font-size: 14px;
  color: var(--muted);
  border-top: 1px solid var(--border);
  background: #fafcfe;
}

/* ---------- video ---------- */
.video-wrap {
  background: #0a1622;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.video-wrap video {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  background: #000;
}

.video-note {
  margin: 12px 2px 0;
  font-size: 13.5px;
  color: var(--muted);
}

/* ---------- footer ---------- */
footer {
  margin-top: 56px;
  background: var(--blue-900);
  color: #b9c9de;
}

.footer-inner {
  padding: 30px 0 34px;
  display: flex;
  flex-wrap: wrap;
  gap: 18px 40px;
  justify-content: space-between;
  align-items: flex-start;
  font-size: 14px;
}

.footer-brand {
  font-weight: 700;
  color: #fff;
  font-size: 15px;
  margin-bottom: 6px;
}

footer a { color: #dce7f5; }
footer a:hover { color: #fff; text-decoration: underline; }

.footer-copy { width: 100%; margin-top: 10px; font-size: 12.5px; color: #7d93b3; }

/* ---------- main page: two-line header ---------- */
.home .topbar-inner {
  height: auto;
  padding: 12px 0;
}

.home .brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 11px;
  font-size: 21px;
  flex: 0 0 auto;
}

.home .brand-text {
  display: flex;
  flex-direction: column;
  gap: 3px;
  line-height: 1.2;
}

.home .brand-line {
  font-size: 26px;
  font-weight: 700;
  color: var(--blue-900);
  letter-spacing: -.3px;
}

.home .brand-slogan {
  font-size: 16px;
  font-weight: 600;
  color: var(--blue-800);
}

/* ---------- responsive ---------- */
@media (max-width: 640px) {
  h1 { font-size: 27px; }
  .hero { padding: 32px 0 20px; }
  .topnav .nav-link { padding: 6px 10px; font-size: 13px; }
  .card-body { padding: 16px 18px 18px; }
  .card h2 { font-size: 19px; }

  .home .topbar-inner { padding: 10px 0; }
  .home .brand-mark { width: 34px; height: 34px; font-size: 17px; }
  .home .brand-line { font-size: 20px; }
  .home .brand-slogan { font-size: 13.5px; }
}
