:root {
  --bg: #f5f6f7;
  --surface: #ffffff;
  --text: #1d2428;
  --muted: #3e474e;
  --muted-2: #4a535a;
  --line: rgba(29, 36, 40, 0.08);
  --accent: #0a6570;
  --accent-2: #22c1d6;
  --accent-soft: rgba(18, 150, 166, 0.12);
  --vip: #e0543a;
  --vip-ink: #fff8f6;
  --cta: #0e6f7c;
  --cta-ink: #fffdf8;
  --cta-wash: rgba(8, 42, 48, 0.22);
  --cta-line: rgba(255, 236, 210, 0.55);
  --shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
  --shadow-2: 0 4px 12px rgba(0, 0, 0, 0.08);
  --radius: 12px;
  --radius-lg: 20px;
  --max: 1320px;
  --header-h: 64px;
  --cta-space: 96px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

html,
body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-size: 16px;
  line-height: 1.65;
  overflow-wrap: anywhere;
  font-family: "PingFang SC", "Microsoft YaHei", "Noto Sans SC", sans-serif;
}

h1 {
  font-size: 32px;
  line-height: 1.22;
}

h2 {
  font-size: 22px;
  line-height: 1.25;
}

h3 {
  font-size: 18px;
  line-height: 1.3;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  color: #0d7a88;
}

a:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

button,
input {
  font: inherit;
}

.skip {
  position: absolute;
  left: -999px;
  top: 8px;
}

.skip:focus {
  left: 12px;
  background: #fff;
  padding: 8px 12px;
  z-index: 100;
}

.wrap {
  width: min(var(--max), calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: #ffffff;
  border-bottom: 1px solid var(--line);
}

.nav-bar {
  min-height: var(--header-h);
  display: flex;
  align-items: center;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: baseline;
  gap: 8px;
  color: var(--text);
  flex-shrink: 0;
}

.brand:hover {
  color: var(--text);
}

.brand-mark {
  font-weight: 800;
  font-size: 22px;
  letter-spacing: 0.02em;
  color: var(--accent);
}

.brand-full {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.3;
}

.nav-main {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

.nav-main a {
  color: var(--text);
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 15px;
}

.nav-main a:hover,
.nav-main a[aria-current="page"] {
  background: var(--accent-soft);
  color: #0d5f6a;
}

.nav-tools {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: 8px;
}

.icon-btn,
.nav-toggle {
  width: 44px;
  height: 44px;
  border: 0;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  border-radius: 50%;
}

.icon-btn:hover,
.nav-toggle:hover {
  background: var(--accent-soft);
}

.vip-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 14px;
  border-radius: 999px;
  background: var(--vip);
  color: var(--vip-ink);
  font-size: 14px;
  font-weight: 700;
}

.vip-btn:hover {
  color: var(--vip-ink);
  filter: brightness(0.96);
}

.nav-toggle {
  display: none;
}

.hero {
  position: relative;
  margin: 16px auto 0;
  width: min(var(--max), calc(100% - 32px));
  height: 450px;
  border-radius: 12px;
  overflow: hidden;
  background: #dfe8ea;
}

.hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-search {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: min(640px, calc(100% - 32px));
  background: #fff;
  border-radius: 999px;
  box-shadow: var(--shadow-2);
  display: flex;
  align-items: center;
  padding: 6px 6px 6px 16px;
}

.hero-search label {
  color: var(--muted);
  font-size: 14px;
  margin-right: 10px;
  flex-shrink: 0;
}

.hero-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  background: transparent;
  padding: 10px 8px;
  color: var(--text);
}

.hero-search button {
  border: 0;
  background: var(--accent);
  color: #fff;
  min-height: 42px;
  padding: 0 18px;
  border-radius: 999px;
  cursor: pointer;
}

.entry-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin: 18px auto 8px;
}

.entry-card {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px 16px;
  box-shadow: var(--shadow);
  color: var(--text);
  min-height: 88px;
}

.entry-card:hover {
  color: var(--text);
  box-shadow: var(--shadow-2);
  border-color: rgba(18, 150, 166, 0.28);
}

.entry-ico {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #7fe4ef, #1296a6);
  flex-shrink: 0;
}

.entry-card .entry-title {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.3;
}

.entry-card p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.arrow {
  display: inline-block;
  margin-left: 6px;
  color: var(--accent);
  font-weight: 700;
}

.home-tabs {
  display: flex;
  align-items: center;
  gap: 18px;
  margin: 18px auto 10px;
  border-bottom: 1px solid var(--line);
  overflow-x: auto;
}

.home-tabs button {
  border: 0;
  background: transparent;
  color: var(--muted);
  padding: 10px 2px 12px;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  white-space: nowrap;
}

.home-tabs button[aria-selected="true"] {
  color: var(--text);
  font-weight: 700;
  border-bottom-color: var(--accent);
}

.sort-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 auto 12px;
  color: var(--muted);
  font-size: 14px;
}

.sort-row button {
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  padding: 6px 8px;
}

.sort-row button[aria-pressed="true"] {
  color: var(--accent);
  font-weight: 700;
}

.card-grid {
  display: flex;
  flex-wrap: wrap;
  margin: 0 -8px 24px;
}

.card-grid .post-card {
  width: calc(20% - 16px);
  margin: 8px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  color: var(--text);
}

.card-grid .post-card:hover {
  color: var(--text);
  box-shadow: var(--shadow-2);
  transform: translateY(-1px);
}

.post-thumb {
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: #e7eef0;
}

.post-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.post-body {
  padding: 10px 12px 12px;
}

.post-body h3 {
  margin: 0;
  font-size: 18px;
  line-height: 1.4;
  font-weight: 700;
}

.post-body p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.post-meta {
  margin-top: 8px;
  color: var(--muted-2);
  font-size: 12px;
}

.panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 28px 28px 8px;
  margin: 0 auto 20px;
}

.panel h2 {
  margin: 0 0 12px;
}

.panel h3 {
  margin: 22px 0 8px;
}

.panel p,
.article p {
  margin: 0 0 14px;
}

.panel ul,
.article ul {
  margin: 0 0 16px;
  padding-left: 1.2em;
}

.lead {
  font-size: 17px;
}

.kicker {
  color: var(--accent);
  font-size: 13px;
  font-weight: 700;
  margin: 0 0 8px;
}

.page-hero {
  padding: 28px 0 8px;
}

.page-hero h1,
.hero-copy h1,
.home-block h1 {
  margin: 0 0 12px;
}

.home-block {
  padding: 8px 0 4px;
}

.faq dt {
  font-weight: 700;
  margin: 16px 0 6px;
}

.faq dd {
  margin: 0 0 8px;
}

.split {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 16px;
}

.note-card {
  background: #eef7f8;
  border: 1px solid rgba(18, 150, 166, 0.16);
  border-radius: var(--radius);
  padding: 16px 18px;
}

.note-card h2,
.note-card h3 {
  margin: 0 0 8px;
  font-size: 18px;
}

.crumb {
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 10px;
}

.crumb a {
  color: var(--muted);
}

.site-footer {
  background: var(--surface);
  border-top: 1px solid var(--line);
  padding: 28px 0 calc(var(--cta-space) + 24px);
  color: var(--muted);
  font-size: 14px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 20px;
}

.site-footer a {
  color: var(--text);
}

.site-footer a:hover {
  color: var(--accent);
}

.footer-brand a {
  color: var(--text);
  font-weight: 700;
  font-size: 16px;
}

.foot-links {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.site-cta {
  position: fixed;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  z-index: 70;
  width: min(520px, calc(100vw - 28px));
  min-height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px 22px;
  border-radius: 999px;
  background: var(--cta);
  color: var(--cta-ink);
  font-size: 16px;
  font-weight: 700;
  box-shadow: 0 8px 22px rgba(14, 111, 124, 0.28);
  overflow: hidden;
}

.site-cta:hover,
.site-cta:focus-visible {
  color: var(--cta-ink);
  filter: brightness(1.04);
}

.site-cta::before,
.site-cta::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.site-cta::before {
  inset: 0;
  background: radial-gradient(120% 160% at 28% 50%, var(--cta-wash) 0%, transparent 70%);
  opacity: 0;
  animation: cta-oilslip 2.9s cubic-bezier(0.2, 0.7, 0.3, 1) infinite;
}

.site-cta::after {
  left: 22px;
  right: 22px;
  bottom: 9px;
  height: 3px;
  border-radius: 999px;
  background: var(--cta-line);
  transform: scaleX(1) translateY(2px);
  transform-origin: left;
  opacity: 0;
  animation: cta-stub 2.9s cubic-bezier(0.2, 0.7, 0.3, 1) infinite;
}

.site-cta span {
  position: relative;
  z-index: 1;
}

@keyframes cta-oilslip {
  0%,
  55% {
    opacity: 0;
    transform: scale(1);
  }
  68% {
    opacity: 0.28;
    transform: scale(1);
  }
  86%,
  100% {
    opacity: 0;
    transform: scale(1);
  }
}

@keyframes cta-stub {
  0%,
  62% {
    transform: scaleX(1) translateY(2px);
    opacity: 0;
  }
  74% {
    transform: scaleX(1) translateY(0);
    opacity: 0.7;
  }
  88%,
  100% {
    transform: scaleX(1) translateY(0);
    opacity: 0.2;
  }
}

.drawer {
  position: fixed;
  inset: 0;
  z-index: 60;
  pointer-events: none;
}

.drawer.is-open {
  pointer-events: auto;
}

.drawer-mask {
  position: absolute;
  inset: 0;
  background: rgba(20, 24, 28, 0.35);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.drawer.is-open .drawer-mask {
  opacity: 1;
}

.drawer-panel {
  position: absolute;
  top: 0;
  left: 0;
  width: min(300px, 86vw);
  height: 100%;
  background: #fff;
  padding: 20px 16px;
  transform: translateX(-100%);
  transition: transform 0.22s ease;
  overflow-y: auto;
}

.drawer.is-open .drawer-panel {
  transform: none;
}

.drawer-panel a {
  display: block;
  padding: 12px 8px;
  color: var(--text);
  border-bottom: 1px solid var(--line);
}

.search-layer {
  position: fixed;
  inset: 0;
  z-index: 65;
  background: rgba(245, 246, 247, 0.96);
  display: none;
  padding: 28px 16px 40px;
  overflow-y: auto;
}

.search-layer.is-open {
  display: block;
}

.search-box {
  width: min(720px, 100%);
  margin: 0 auto;
}

.search-box input {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 14px;
  background: #fff;
}

.search-list {
  list-style: none;
  padding: 0;
  margin: 16px 0 0;
}

.search-list li {
  margin: 0 0 8px;
}

.search-list a {
  display: block;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px 14px;
  color: var(--text);
}

.search-empty {
  color: var(--muted);
  margin-top: 16px;
}

.search-close {
  margin: 0 0 16px;
  border: 0;
  background: transparent;
  cursor: pointer;
  color: var(--text);
  min-height: 44px;
}

.is-hidden {
  display: none !important;
}

.err {
  min-height: 50vh;
  padding: 48px 0 24px;
}

@media (max-width: 1199px) {
  .card-grid .post-card {
    width: calc(25% - 16px);
  }
}

@media (max-width: 991px) {
  .entry-grid {
    grid-template-columns: 1fr 1fr;
  }

  .card-grid .post-card {
    width: calc(33.333% - 16px);
  }

  .split,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .hero {
    height: 320px;
  }
}

@media (max-width: 767px) {
  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    order: -1;
  }

  .nav-main {
    display: none;
  }

  .brand-full {
    display: none;
  }

  .hero {
    height: 280px;
    width: calc(100% - 20px);
  }

  .page-hero h1,
  .home-block h1,
  h1 {
    font-size: 26px;
  }

  .panel {
    padding: 20px 16px 6px;
  }

  .card-grid .post-card {
    width: calc(50% - 16px);
  }

  .site-cta {
    left: 14px;
    right: 14px;
    width: auto;
    transform: none;
    min-height: 54px;
    font-size: 15px;
    bottom: calc(12px + env(safe-area-inset-bottom));
  }

  body {
    padding-bottom: 0;
  }
}

@media (max-width: 639px) {
  .entry-card {
    align-items: flex-start;
  }

  .post-body h2,
  .post-body h3 {
    font-size: 14px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .site-cta::before,
  .site-cta::after {
    animation: none;
  }

  .site-cta::before {
    opacity: 0.16;
    transform: scale(1);
  }

  .site-cta::after {
    transform: scaleX(1);
    opacity: 0.45;
  }

  .drawer-panel,
  .drawer-mask,
  .card-grid .post-card {
    transition: none;
  }
}
