/* 水族宠物大全 · 首页样式
   设计宽 1440，容器 1376；配色与分区按 03-ui/home-ui-desktop.png 落位 */

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

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 15px/1.65 var(--font);
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, p, dl, dd, dt, ul, ol { margin: 0; }
ul, ol { list-style: none; padding: 0; }

.wrap {
  width: min(var(--wrap), 100% - 64px);
  margin-inline: auto;
}

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: 12px; top: -60px;
  z-index: 40;
  padding: 8px 14px;
  border-radius: 0 0 8px 8px;
  background: var(--navy);
  color: #fff;
  font-size: 13px;
  transition: top .2s;
}
.skip-link:focus { top: 0; }

:focus-visible {
  outline: 3px solid #f3a712;
  outline-offset: 2px;
}

/* ---------- header ---------- */

.site-header {
  position: relative;
  z-index: 20;
  background: var(--brand);
  color: #fff;
}

.site-header__inner {
  display: flex;
  align-items: center;
  gap: 26px;
  height: 76px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: .01em;
  white-space: nowrap;
}
.logo__mark {
  display: grid;
  place-items: center;
  width: 30px; height: 30px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .16);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 19px;
  margin-left: auto;
  font-size: 13.5px;
}
.main-nav a { opacity: .9; white-space: nowrap; }
.main-nav a:hover { opacity: 1; text-decoration: underline; text-underline-offset: 5px; }
.main-nav a[aria-current="page"] {
  opacity: 1;
  font-weight: 700;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 6px;
}

.header-cta {
  flex: none;
  padding: 7px 15px;
  border: 1px solid rgba(255, 255, 255, .5);
  border-radius: 999px;
  font-size: 12.5px;
  white-space: nowrap;
}
.header-cta:hover { background: rgba(255, 255, 255, .14); }

.nav-toggle {
  display: none;
  align-items: center;
  gap: 7px;
  margin-left: auto;
  padding: 7px 12px;
  border: 1px solid rgba(255, 255, 255, .5);
  border-radius: 999px;
  background: transparent;
  color: inherit;
  font: 600 13px/1 var(--font);
  cursor: pointer;
}
.nav-toggle__bars,
.nav-toggle__bars::before,
.nav-toggle__bars::after {
  display: block;
  width: 16px; height: 2px;
  border-radius: 2px;
  background: currentColor;
  content: "";
  position: relative;
}
.nav-toggle__bars::before { position: absolute; top: -5px; }
.nav-toggle__bars::after { position: absolute; top: 5px; }

/* ---------- hero ---------- */

.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: #08324f;
  color: #fff;
}
.hero__media,
.hero__scrim {
  position: absolute;
  inset: 0;
  z-index: -1;
}
.hero__media img { width: 100%; height: 100%; object-fit: cover; }
.hero__scrim {
  background: linear-gradient(90deg, rgba(6, 34, 58, .94) 0%, rgba(6, 34, 58, .8) 42%, rgba(6, 34, 58, .32) 66%, rgba(6, 34, 58, .06) 100%);
}

.hero__inner {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding-top: 30px;
  padding-bottom: 18px;
  max-width: 1376px;
}
.hero h1 {
  font-size: 41px;
  line-height: 1.08;
  font-weight: 900;
  letter-spacing: .01em;
  margin: 4px 0 0;
}
.hero__sub {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: .02em;
  margin-top: 8px;
  color: #dbeaf8;
}
.hero__lead {
  max-width: 720px;
  margin-top: 10px;
  font-size: 14px;
  line-height: 1.65;
  color: rgba(238, 246, 253, .88);
}
.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 15px;
}

.hero__stats {
  border-top: 1px solid rgba(255, 255, 255, .16);
  background: rgba(5, 28, 48, .58);
  backdrop-filter: blur(2px);
}
.hero__stats-inner {
  display: flex;
  gap: 46px;
  align-items: center;
  height: 50px;
  font-size: 13px;
  color: rgba(232, 243, 253, .92);
}
.hero__stats-inner strong {
  font-size: 19px;
  font-weight: 800;
  color: #fff;
  margin-right: 4px;
}

/* ---------- buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 20px;
  border-radius: 999px;
  font-size: 13.5px;
  font-weight: 700;
  letter-spacing: .02em;
  transition: transform .15s, background-color .15s, color .15s;
}
.btn--primary { background: var(--accent); color: #fff; }
.btn--primary:hover { background: #0f6fc7; }
.btn--ghost {
  border: 1px solid rgba(255, 255, 255, .55);
  color: #fff;
}
.btn--ghost:hover { background: rgba(255, 255, 255, .14); }
.cta-band .btn--ghost { border-color: rgba(255, 255, 255, .6); }

.eyebrow {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .18em;
  color: var(--accent);
  text-transform: uppercase;
}
.eyebrow--light { color: #8fc4f2; }

/* ---------- section heads ---------- */

.sec-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}
.sec-head__title {
  display: flex;
  align-items: baseline;
  gap: 10px;
}
.sec-head h2 {
  font-size: 25px;
  line-height: 1.2;
  font-weight: 800;
  letter-spacing: .01em;
}
.sec-head__note {
  font-size: 12.5px;
  color: var(--muted);
  padding-bottom: 3px;
}
.sec-desc {
  margin-top: 7px;
  font-size: 13px;
  color: var(--muted);
}

/* ---------- topics ---------- */

.topics { padding: 24px 0 20px; }

.cats {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 14px;
  margin-top: 14px;
}
.cat > a {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 10px;
  border-radius: 12px;
  background: var(--surface);
  box-shadow: var(--shadow);
  transition: transform .18s, box-shadow .18s;
}
.cat > a:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 26px rgba(17, 49, 81, .13);
}
.cat__num {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .12em;
  color: var(--accent);
}
.cat__thumb { margin-top: 5px; }
.cat__thumb img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 8px;
}
.cat__name {
  margin-top: 7px;
  font-size: 15px;
  font-weight: 800;
}
.cat__desc {
  margin-top: 3px;
  font-size: 11.5px;
  line-height: 1.45;
  color: var(--muted);
  min-height: 30px;
}
.cat__chips {
  margin-top: 7px;
  padding: 3px 6px;
  border-radius: 999px;
  background: var(--surface-2);
  font-size: 10px;
  line-height: 1.4;
  text-align: center;
  color: #2f5f8a;
}

/* ---------- species ---------- */

.species { padding: 16px 0 18px; }

.species-grid {
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  gap: 12px;
  margin-top: 10px;
}
.species-grid a {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 8px;
  border-radius: 11px;
  background: var(--surface);
  box-shadow: var(--shadow);
  transition: transform .18s;
}
.species-grid a:hover { transform: translateY(-2px); }
.species__thumb img {
  width: 100%;
  aspect-ratio: 2.85 / 1;
  object-fit: cover;
  border-radius: 7px;
}
.species__name {
  margin-top: 6px;
  font-size: 13.5px;
  font-weight: 800;
}
.species__desc {
  margin-top: 2px;
  font-size: 10.5px;
  line-height: 1.45;
  color: var(--muted);
}

/* ---------- rows ---------- */

.rows { padding-bottom: 6px; }
.rows__inner {
  display: grid;
  gap: 22px;
}

.row {
  display: grid;
  grid-template-columns: minmax(0, 1.62fr) minmax(0, 1fr);
  gap: 22px;
  align-items: stretch;
}

.panel {
  padding: 17px 20px 18px;
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}
.panel--table { display: flex; flex-direction: column; }
.panel--table .panel__note {
  margin-top: 9px;
  font-size: 11.5px;
  color: var(--muted);
}
.sec-head--compact { align-items: center; }
.sec-head--compact h2 { font-size: 21px; }

/* table */
.table-wrap { margin-top: 10px; }
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
}
thead th {
  padding: 6px 9px;
  background: var(--accent-soft);
  font-size: 11.5px;
  font-weight: 700;
  color: #23517c;
  text-align: left;
  white-space: nowrap;
}
thead th:first-child { border-radius: 8px 0 0 8px; }
thead th:last-child { border-radius: 0 8px 8px 0; }
tbody th,
tbody td {
  padding: 4.5px 9px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}
tbody tr:nth-child(even) { background: var(--surface-2); }
tbody th { font-weight: 700; white-space: nowrap; }
tbody tr:last-child th,
tbody tr:last-child td { border-bottom: 0; }

/* equipment */
.equip__media { margin-top: 10px; }
.equip__media img {
  width: 100%;
  aspect-ratio: 4.5 / 1;
  object-fit: cover;
  border-radius: 9px;
}
.equip { margin-top: 10px; }
.equip dt {
  font-size: 13px;
  font-weight: 800;
  color: #23517c;
}
.equip dd {
  margin: 2px 0 7px;
  font-size: 12px;
  line-height: 1.5;
  color: var(--muted);
}
.equip dd:last-child { margin-bottom: 0; }

/* path */
.path {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
}
.path li {
  position: relative;
  padding: 10px 11px 11px;
  border-radius: 11px;
  background: var(--surface-2);
}
.path li:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 50%;
  right: -9px;
  width: 6px; height: 6px;
  border-top: 2px solid var(--accent);
  border-right: 2px solid var(--accent);
  transform: translateY(-50%) rotate(45deg);
}
.path__label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .1em;
  color: var(--accent);
}
.path h3 {
  margin-top: 3px;
  font-size: 13.5px;
  font-weight: 800;
}
.path p {
  margin-top: 4px;
  font-size: 11.5px;
  line-height: 1.5;
  color: var(--muted);
}

/* mistakes */
.mistakes {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 18px;
  margin-top: 12px;
}
.mistakes li {
  position: relative;
  padding-left: 22px;
}
.mistakes li::before {
  content: "×";
  position: absolute;
  left: 0; top: 1px;
  display: grid;
  place-items: center;
  width: 15px; height: 15px;
  border-radius: 50%;
  background: #fdeceb;
  color: #d7443a;
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
}
.mistakes h3 {
  font-size: 12.5px;
  font-weight: 800;
}
.mistakes p {
  margin-top: 3px;
  font-size: 11.5px;
  line-height: 1.5;
  color: var(--muted);
}

/* guides */
.guides {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 12px;
}
.guides a {
  display: flex;
  flex-direction: column;
  height: 100%;
}
.guides__thumb img {
  width: 100%;
  aspect-ratio: 2.35 / 1;
  object-fit: cover;
  border-radius: 9px;
}
.guides__title {
  margin-top: 8px;
  font-size: 13.5px;
  font-weight: 800;
  line-height: 1.45;
}
.guides__meta {
  margin-top: 3px;
  font-size: 10.5px;
  color: var(--accent);
  letter-spacing: .04em;
}
.guides__sum {
  margin-top: 4px;
  font-size: 11.5px;
  line-height: 1.5;
  color: var(--muted);
}

/* faq */
.faq { margin-top: 8px; }
.faq details {
  border-bottom: 1px solid var(--line);
}
.faq details:last-child { border-bottom: 0; }
.faq summary {
  position: relative;
  padding: 8px 26px 8px 0;
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "";
  position: absolute;
  top: 15px; right: 4px;
  width: 6px; height: 6px;
  border-right: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  transform: rotate(45deg);
  transition: transform .2s;
}
.faq details[open] summary::after { transform: rotate(-135deg); }
.faq details p {
  padding: 0 18px 10px 0;
  font-size: 11.5px;
  line-height: 1.6;
  color: var(--muted);
}

/* ---------- cta ---------- */

.cta-band {
  position: relative;
  margin-top: 22px;
  overflow: hidden;
  background: linear-gradient(100deg, #0b3f70 0%, #0e5da0 58%, #1173b8 100%);
  color: #fff;
}
.cta-band__media {
  position: absolute;
  inset: 0 0 0 auto;
  width: 40%;
  opacity: .5;
}
.cta-band__media img { width: 100%; height: 100%; object-fit: cover; }
.cta-band__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, #0e5da0 0%, rgba(14, 93, 160, .72) 38%, rgba(10, 70, 122, .28) 100%);
}
.cta-band__inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  min-height: 118px;
  padding-block: 20px;
}
.cta-band h2 {
  font-size: 25px;
  font-weight: 900;
  letter-spacing: .01em;
}
.cta-band p {
  margin-top: 6px;
  font-size: 13px;
  color: rgba(232, 243, 253, .85);
}
.cta-band__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  position: relative;
  z-index: 1;
}
.cta-band .btn--ghost { background: rgba(6, 34, 58, .28); }

/* ---------- footer ---------- */

.site-footer {
  margin-top: 0;
  background: var(--navy);
  color: #cfe0ef;
}
.footer__top {
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  gap: 32px;
  padding: 22px 0 14px;
}
.footer__logo {
  font-size: 18px;
  font-weight: 800;
  color: #fff;
}
.footer__topic {
  margin-top: 6px;
  font-size: 12px;
  line-height: 1.6;
  color: #9db6cb;
}
.footer__cats {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .16em;
  color: #7d9ab3;
}
.footer__cols {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 10px 14px;
  margin-top: 8px;
}
.footer__col { display: flex; flex-direction: column; gap: 1px; }
.footer__col a {
  font-size: 12px;
  line-height: 1.7;
  color: #a8c2d6;
}
.footer__col a:hover { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.footer__parent {
  font-weight: 700;
  color: #eaf3fa !important;
}
.footer__note {
  padding: 10px 0 14px;
  border-top: 1px solid rgba(255, 255, 255, .12);
  font-size: 10.5px;
  line-height: 1.6;
  color: #8ba6bd;
}

/* ---------- responsive ---------- */

@media (max-width: 1240px) {
  .cats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .species-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .row { grid-template-columns: minmax(0, 1fr); }
  .panel--equip .equip__media img { aspect-ratio: 3.2 / 1; }
}

@media (max-width: 1080px) {
  .nav-toggle { display: inline-flex; }
  .main-nav {
    position: absolute;
    top: 76px; left: 0; right: 0;
    display: none;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    padding: 10px 32px 16px;
    background: var(--brand);
    box-shadow: 0 12px 24px rgba(6, 34, 58, .28);
  }
  .main-nav.is-open { display: flex; }
  .main-nav a { width: 100%; padding: 9px 0; font-size: 14px; }
  .header-cta { margin-left: 12px; }
}

@media (max-width: 900px) {
  .hero h1 { font-size: 36px; }
  .hero__sub { font-size: 17px; }
  .hero__stats-inner { gap: 28px; overflow-x: auto; }
  .footer__top { grid-template-columns: 1fr; gap: 20px; }
  .guides { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .path { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
  .wrap { width: calc(100% - 32px); }
  .site-header__inner { height: 64px; gap: 12px; }
  .main-nav { top: 64px; padding-inline: 16px; }
  .logo { font-size: 16px; }
  .logo__mark { width: 26px; height: 26px; }
  .header-cta { font-size: 11.5px; padding: 6px 11px; }

  .hero__inner { padding-top: 26px; padding-bottom: 18px; }
  .hero h1 { font-size: 30px; }
  .hero__sub { font-size: 15px; }
  .hero__lead { font-size: 13.5px; }
  .hero__stats-inner { gap: 20px; height: 48px; font-size: 11.5px; }
  .hero__stats-inner strong { font-size: 16px; }

  .sec-head { flex-direction: column; align-items: flex-start; gap: 4px; }
  .sec-head__title { flex-wrap: wrap; }
  .sec-head h2 { font-size: 21px; }
  .sec-head__note { padding-bottom: 0; }

  .cats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .species-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .species__thumb img { aspect-ratio: 2 / 1; }

  .panel { padding: 14px 14px 16px; }
  .table-wrap { overflow-x: auto; }
  table { font-size: 12px; }
  .path { grid-template-columns: minmax(0, 1fr); }
  .path li:not(:last-child)::after { display: none; }
  .mistakes { grid-template-columns: minmax(0, 1fr); }
  .guides { grid-template-columns: minmax(0, 1fr); }
  .cta-band__media { width: 100%; opacity: .35; }
  .cta-band__inner { flex-direction: column; align-items: flex-start; gap: 18px; min-height: 0; }
  .cta-band h2 { font-size: 21px; }
  .footer__cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    transition-duration: .001ms !important;
  }
}
