/* ==========================================================================
   博鱼官方网址 · 共享站点样式 /assets/site.css
   水域档案库：深海蓝外壳 · 纸白内容 · 珊瑚橙锚点
   ========================================================================== */

/* ---------- 1. Reset 与设计变量 ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

:root {
  /* 品牌色 */
  --deep: #0B2E4F;
  --ink: #0A0A0A;
  --paper: #F7F3EA;
  --coral: #FF5A3C;
  --aqua: #3BB7B0;
  --sand: #D9A441;
  --grey: #C9C2B6;
  --ice: #E8F4F6;
  --teal: #123B44;
  --coral-soft: #FFD8CF;

  /* 字体 */
  --font-display: "Noto Serif SC", "Source Han Serif SC", "Songti SC", "SimSun", serif;
  --font-body: "Noto Sans SC", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --font-mono: "IBM Plex Mono", "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  /* 结构 */
  --gutter: clamp(16px, 4vw, 56px);
  --shell: min(1240px, calc(100% - var(--gutter) * 2));
  --header-h: 92px;
  --rule: 2px solid var(--ink);
  --rule-soft: 2px solid var(--grey);
  --shadow-hard: 6px 6px 0 var(--ink);
  --shadow-aqua: 6px 6px 0 var(--aqua);
  --radius: 0px;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 20px);
}

body {
  margin: 0;
  background-color: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.78;
  letter-spacing: 0.012em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img,
svg,
picture,
video {
  display: block;
  max-width: 100%;
}

button {
  font: inherit;
  color: inherit;
}

/* ---------- 2. 中文排版与基础元素 ---------- */
h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.22;
  letter-spacing: 0.02em;
  margin: 0 0 0.6em;
  text-wrap: balance;
}

h1 {
  font-size: clamp(2.4rem, 6vw, 4.6rem);
}

h2 {
  font-size: clamp(1.8rem, 3vw, 3rem);
}

h3 {
  font-size: clamp(1.25rem, 2vw, 1.7rem);
}

p {
  margin: 0 0 1em;
}

p:last-child {
  margin-bottom: 0;
}

a {
  color: var(--deep);
  text-decoration: none;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}

a:hover {
  color: var(--coral);
}

strong {
  font-weight: 700;
}

ul,
ol {
  margin: 0 0 1em;
  padding-left: 1.2em;
}

hr {
  border: 0;
  border-top: var(--rule-soft);
  margin: 2em 0;
}

::selection {
  background: var(--coral);
  color: #0A0A0A;
}

:focus-visible {
  outline: 3px solid var(--coral);
  outline-offset: 3px;
}

.site-footer :focus-visible,
.site-header :focus-visible,
.card--deep :focus-visible {
  outline-color: var(--sand);
}

/* ---------- 3. 通用工具类 ---------- */
.shell {
  width: var(--shell);
  margin-inline: auto;
}

.prose {
  max-width: 68ch;
}

.mono {
  font-family: var(--font-mono);
  font-size: 0.85em;
  letter-spacing: 0.08em;
}

.section {
  padding-block: clamp(48px, 8vw, 96px);
}

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px 32px;
  margin-bottom: clamp(24px, 4vw, 48px);
  padding-bottom: 18px;
  border-bottom: var(--rule);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.55em;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--deep);
  margin: 0 0 12px;
}

.eyebrow::before {
  content: "";
  width: 26px;
  height: 4px;
  background: var(--coral);
}

.section-title {
  font-size: clamp(1.8rem, 3vw, 3rem);
  margin: 0;
}

.lede {
  font-size: clamp(1rem, 1.4vw, 1.15rem);
  line-height: 1.8;
  max-width: 62ch;
  color: #33332e;
  margin: 0;
}

/* ---------- 4. 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
  padding: 0.85em 1.5em;
  border: var(--rule);
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.3;
  text-decoration: none;
  box-shadow: 4px 4px 0 var(--ink);
  cursor: pointer;
  transition: transform 0.16s ease, box-shadow 0.16s ease, background-color 0.16s ease, color 0.16s ease;
}

.btn:hover {
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 var(--ink);
  color: var(--ink);
}

.btn:active {
  transform: translate(1px, 1px);
  box-shadow: 2px 2px 0 var(--ink);
}

.btn--coral {
  background: var(--coral);
  color: #0A0A0A;
}

.btn--coral:hover {
  background: #ff6d52;
  color: #0A0A0A;
}

.btn--deep {
  background: var(--deep);
  color: var(--paper);
  border-color: var(--ink);
  box-shadow: 4px 4px 0 var(--aqua);
}

.btn--deep:hover {
  background: var(--teal);
  color: var(--paper);
  box-shadow: 6px 6px 0 var(--aqua);
}

.btn--ghost {
  background: transparent;
  box-shadow: none;
  border-color: var(--ink);
}

.btn--ghost:hover {
  background: var(--ice);
  box-shadow: 4px 4px 0 var(--ink);
}

.btn--sm {
  padding: 0.55em 1em;
  font-size: 13px;
  box-shadow: 3px 3px 0 var(--ink);
}

.btn--sm:hover {
  box-shadow: 5px 5px 0 var(--ink);
}

/* ---------- 5. 标签 ---------- */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
  padding: 4px 10px;
  border: 2px solid var(--ink);
  background: var(--ice);
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  line-height: 1.5;
  vertical-align: middle;
}

.tag--coral {
  background: var(--coral);
  color: #0A0A0A;
}

.tag--aqua {
  background: var(--aqua);
  color: #04201F;
}

.tag--sand {
  background: var(--sand);
  color: #1A1204;
}

/* ---------- 6. 卡片 ---------- */
.card {
  position: relative;
  background: var(--paper);
  border: var(--rule);
  box-shadow: var(--shadow-hard);
  padding: clamp(18px, 2.2vw, 28px);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.card:hover,
.card:focus-within {
  transform: translate(-2px, -2px);
  box-shadow: 8px 8px 0 var(--aqua);
}

.card--ice {
  background: var(--ice);
}

.card--deep {
  background: var(--deep);
  color: var(--paper);
  border-color: var(--ink);
  box-shadow: var(--shadow-aqua);
}

.card--deep .card__title {
  color: #FFFFFF;
}

.card--deep .card__text {
  color: var(--ice);
}

.card--deep .card__index {
  color: var(--coral-soft);
}

.card__index {
  display: block;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.16em;
  color: var(--sand);
  margin-bottom: 12px;
}

.card__title {
  font-family: var(--font-display);
  font-size: clamp(1.15rem, 1.8vw, 1.55rem);
  line-height: 1.32;
  margin: 0 0 10px;
}

.card__text {
  font-size: 15.5px;
  line-height: 1.75;
  color: #3B3B36;
  margin: 0;
}

/* ---------- 7. 媒体容器（页面阶段放入图片） ---------- */
.media {
  position: relative;
  overflow: hidden;
  background: var(--ice);
  border: var(--rule);
  box-shadow: var(--shadow-hard);
}

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

.media--wide {
  aspect-ratio: 16 / 9;
}

.media--square {
  aspect-ratio: 1 / 1;
}

.media--tall {
  aspect-ratio: 3 / 4;
}

.media__caption {
  position: absolute;
  left: 0;
  bottom: 0;
  padding: 8px 14px;
  background: var(--deep);
  color: var(--paper);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  line-height: 1.5;
}

/* ---------- 8. 网格与横向轨道 ---------- */
.grid {
  display: grid;
  gap: clamp(18px, 2.4vw, 32px);
}

.grid--2 {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
}

.grid--3 {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
}

.rail {
  display: flex;
  gap: clamp(14px, 2vw, 24px);
  margin: 0;
  padding: 4px 4px 18px;
  list-style: none;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  overscroll-behavior-x: contain;
}

.rail > * {
  flex: 0 0 min(84vw, 340px);
  scroll-snap-align: start;
}

.rail::-webkit-scrollbar {
  height: 8px;
}

.rail::-webkit-scrollbar-track {
  background: var(--grey);
}

.rail::-webkit-scrollbar-thumb {
  background: var(--deep);
}

/* ---------- 9. 面包屑 ---------- */
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.06em;
  color: #4A4A44;
}

.breadcrumb li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.breadcrumb li + li::before {
  content: "/";
  color: var(--grey);
}

.breadcrumb a {
  color: var(--deep);
  border-bottom: 1px solid var(--aqua);
}

.breadcrumb a:hover {
  color: var(--coral);
  border-bottom-color: var(--coral);
}

/* ---------- 10. 页头 ---------- */
.skip-link {
  position: absolute;
  left: 12px;
  top: -80px;
  z-index: 120;
  padding: 10px 18px;
  background: var(--sand);
  color: var(--ink);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.06em;
  border: var(--rule);
  box-shadow: 4px 4px 0 var(--ink);
  text-decoration: none;
  transition: top 0.16s ease;
}

.skip-link:focus {
  top: 12px;
  color: var(--ink);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: var(--deep);
  color: var(--paper);
  border-bottom: 3px solid var(--ink);
  box-shadow: 0 4px 0 rgba(10, 10, 10, 0.28);
  transition: box-shadow 0.18s ease;
}

.site-header[data-scrolled="true"] {
  --header-h: 68px;
  box-shadow: 0 6px 0 rgba(10, 10, 10, 0.42);
}

.header-shell {
  width: var(--shell);
  margin-inline: auto;
  display: flex;
  align-items: center;
  gap: clamp(12px, 3vw, 40px);
  min-height: var(--header-h);
  padding-block: clamp(10px, 1.4vw, 16px);
  transition: min-height 0.18s ease, padding-block 0.18s ease;
}

/* 品牌块 */
.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: 0 0 auto;
  color: var(--paper);
  text-decoration: none;
}

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

.brand-glyph {
  display: grid;
  gap: 4px;
  width: 36px;
  flex: 0 0 auto;
}

.brand-glyph span {
  display: block;
  height: 4px;
  border-radius: 99px;
  background: var(--aqua);
  transition: width 0.18s ease, background-color 0.18s ease;
}

.brand-glyph span:nth-child(1) {
  width: 100%;
  background: var(--coral);
}

.brand-glyph span:nth-child(2) {
  width: 72%;
}

.brand-glyph span:nth-child(3) {
  width: 44%;
  background: var(--sand);
}

.brand:hover .brand-glyph span:nth-child(2) {
  width: 100%;
}

.brand:hover .brand-glyph span:nth-child(3) {
  width: 72%;
}

.brand-text {
  display: block;
}

.brand-name {
  display: block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 24px;
  line-height: 1.1;
  letter-spacing: 0.1em;
  transition: font-size 0.18s ease;
}

.brand-sub {
  display: block;
  margin-top: 5px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.24em;
  line-height: 1.2;
  color: var(--grey);
  text-transform: uppercase;
}

/* 主导航 */
.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(10px, 1.6vw, 26px);
  margin-left: auto;
}

.nav-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: clamp(4px, 1vw, 16px);
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav-link {
  display: inline-flex;
  align-items: baseline;
  gap: 7px;
  padding: 8px 6px;
  color: var(--paper);
  font-size: 15px;
  font-weight: 500;
  line-height: 1.3;
  text-decoration: none;
  border-bottom: 2px solid transparent;
  transition: color 0.16s ease, border-color 0.16s ease, background-color 0.16s ease;
}

.nav-link:hover,
.nav-link:focus-visible {
  color: var(--ice);
  border-bottom-color: var(--coral);
  background: rgba(59, 183, 176, 0.14);
}

.nav-index {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  color: var(--aqua);
  transition: color 0.16s ease;
}

.nav-link:hover .nav-index,
.nav-link:focus-visible .nav-index {
  color: var(--sand);
}

.nav-link[aria-current="page"] {
  color: #FFFFFF;
  border-bottom-color: var(--coral);
  background: rgba(255, 90, 60, 0.14);
}

.nav-link[aria-current="page"] .nav-index {
  color: var(--coral);
}

.nav-label {
  display: inline-block;
  white-space: nowrap;
}

.nav-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 18px;
  background: var(--coral);
  color: #0A0A0A;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 1.3;
  text-decoration: none;
  border: var(--rule);
  box-shadow: 4px 4px 0 var(--sand);
  transition: transform 0.16s ease, box-shadow 0.16s ease, background-color 0.16s ease;
}

.nav-cta:hover,
.nav-cta:focus-visible {
  color: #0A0A0A;
  background: #ff6d52;
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 var(--sand);
}

/* 移动端按钮 */
.nav-toggle {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: 46px;
  height: 42px;
  margin-left: auto;
  padding: 0;
  background: transparent;
  color: var(--paper);
  border: 2px solid var(--paper);
  cursor: pointer;
  transition: border-color 0.16s ease, background-color 0.16s ease;
}

.nav-toggle:hover {
  border-color: var(--coral);
  background: rgba(255, 90, 60, 0.14);
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: currentColor;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* 阅读进度条 */
.scroll-meter {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -3px;
  height: 3px;
  pointer-events: none;
  z-index: 2;
}

.scroll-meter-fill {
  display: block;
  width: 0;
  height: 100%;
  background: var(--coral);
}

/* ---------- 11. 页脚 ---------- */
.site-footer {
  background: var(--deep);
  color: var(--paper);
  border-top: 3px solid var(--ink);
}

.wave-band {
  height: 12px;
  background: repeating-linear-gradient(
    90deg,
    var(--deep) 0 22px,
    var(--aqua) 22px 44px,
    var(--coral) 44px 54px,
    var(--sand) 54px 66px
  );
}

.footer-shell {
  width: var(--shell);
  margin-inline: auto;
  padding-block: clamp(40px, 6vw, 80px) clamp(24px, 3vw, 36px);
}

.footer-top {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) minmax(0, 1.4fr);
  gap: clamp(28px, 5vw, 72px);
  align-items: start;
}

.footer-mark {
  margin: 0 0 16px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2rem, 4vw, 3.1rem);
  line-height: 1.08;
  letter-spacing: 0.08em;
  color: #FFFFFF;
}

.footer-mark em {
  display: block;
  margin-top: 12px;
  font-family: var(--font-mono);
  font-style: normal;
  font-size: 11px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--aqua);
}

.footer-note {
  max-width: 34ch;
  margin: 0 0 16px;
  font-size: 15px;
  line-height: 1.8;
  color: var(--ice);
}

.footer-domain {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.14em;
  color: var(--sand);
}

.footer-cols {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(20px, 3vw, 44px);
}

.footer-title {
  margin: 0 0 16px;
  padding-bottom: 10px;
  border-bottom: 2px solid rgba(247, 243, 234, 0.24);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--sand);
}

.footer-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 10px;
}

.footer-link {
  display: inline-block;
  padding-bottom: 2px;
  color: var(--paper);
  font-size: 15px;
  line-height: 1.6;
  border-bottom: 1px solid transparent;
  transition: color 0.16s ease, border-color 0.16s ease;
}

.footer-link:hover,
.footer-link:focus-visible {
  color: var(--coral-soft);
  border-bottom-color: var(--aqua);
}

.footer-contact {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr));
  gap: 20px clamp(20px, 3vw, 40px);
  margin-top: clamp(30px, 4vw, 52px);
  padding-top: clamp(20px, 3vw, 28px);
  border-top: 2px solid rgba(247, 243, 234, 0.22);
}

.contact-item {
  margin: 0;
  min-width: 0;
}

.contact-label {
  display: block;
  margin-bottom: 6px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--aqua);
}

.contact-value {
  display: block;
  font-size: 15px;
  line-height: 1.7;
  color: var(--paper);
  overflow-wrap: break-word;
  word-break: break-word;
}

.footer-legal {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px 28px;
  margin-top: clamp(24px, 3vw, 36px);
  padding-top: 18px;
  border-top: 1px solid rgba(247, 243, 234, 0.18);
}

.footer-legal-line {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.06em;
  line-height: 1.7;
  color: var(--grey);
}

/* ---------- 12. 响应式 ---------- */
@media (max-width: 1080px) {
  .nav-link {
    font-size: 14px;
    padding: 8px 4px;
  }

  .nav-cta {
    padding: 9px 14px;
    font-size: 13px;
  }
}

@media (max-width: 900px) {
  :root {
    --header-h: 76px;
  }

  .site-header[data-scrolled="true"] {
    --header-h: 64px;
  }

  .nav-toggle {
    display: flex;
  }

  .site-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    margin: 0;
    padding: 18px var(--gutter) 26px;
    background: var(--teal);
    border-top: 3px solid var(--ink);
    border-bottom: 5px solid var(--ink);
    box-shadow: 0 10px 0 rgba(10, 10, 10, 0.3);
    max-height: calc(100vh - var(--header-h));
    max-height: calc(100dvh - var(--header-h));
    overflow-y: auto;
  }

  .site-nav[data-open] {
    display: flex;
  }

  .nav-list {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    width: 100%;
  }

  .nav-link {
    display: flex;
    width: 100%;
    justify-content: flex-start;
    padding: 14px 6px;
    font-size: 16px;
    border-bottom: 2px solid rgba(247, 243, 234, 0.16);
  }

  .nav-link[aria-current="page"] {
    background: var(--deep);
    border-bottom-color: var(--coral);
  }

  .nav-index {
    font-size: 11px;
    min-width: 2.2em;
  }

  .nav-cta {
    align-self: stretch;
    margin-top: 16px;
    padding: 13px 18px;
    font-size: 15px;
  }

  .brand-name {
    font-size: 21px;
  }

  .brand-sub {
    font-size: 10px;
    letter-spacing: 0.2em;
  }

  .brand-glyph {
    width: 30px;
  }

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

  .footer-note {
    max-width: 100%;
  }
}

@media (max-width: 560px) {
  body {
    font-size: 16px;
  }

  .section-head {
    align-items: flex-start;
  }

  .footer-cols {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .footer-legal {
    flex-direction: column;
    gap: 6px;
  }

  .btn {
    width: 100%;
  }
}

/* ---------- 13. 减少动态效果 ---------- */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }

  .btn:hover,
  .btn:active,
  .nav-cta:hover,
  .card:hover,
  .card:focus-within {
    transform: none;
  }
}
