:root {
  color-scheme: light;
  --ink: #1f2328;
  --muted: #5b6472;
  --line: #d8dee8;
  --paper: #fbfaf7;
  --panel: #ffffff;
  --accent: #1f7a68;
  --accent-soft: #e7f3ef;
  --warm: #a5482a;
  --warm-soft: #f6ece5;
  --shadow: 0 18px 50px rgba(31, 35, 40, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 1180px;
  color: var(--ink);
  background: linear-gradient(135deg, #eef7fb 0%, #fbfaf7 36%, #f8f2f6 100%);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.65;
}

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

a:hover {
  text-decoration: underline;
}

.app-shell {
  display: block;
  min-height: 100vh;
}

.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 10;
  width: 300px;
  height: 100vh;
  background: rgba(255, 255, 255, 0.86);
  border-right: 1px solid var(--line);
  padding: 34px 24px;
  backdrop-filter: blur(18px);
  overflow-y: auto;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-size: 25px;
  font-weight: 850;
  margin-bottom: 34px;
}

.logo:hover {
  text-decoration: none;
}

.logo-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 8px;
  background: var(--accent);
  color: white;
  font-size: 20px;
}

.side-nav {
  display: grid;
  gap: 14px;
}

.side-nav a {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--muted);
  padding: 13px 12px;
  border-radius: 8px;
  font-weight: 650;
}

.side-nav a.active {
  color: var(--ink);
  background: rgba(31, 122, 104, 0.1);
}

.side-nav a:hover {
  color: var(--ink);
  background: rgba(31, 122, 104, 0.08);
  text-decoration: none;
}

.side-nav span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 7px;
  background: #eef3f0;
  color: var(--accent);
  font-size: 13px;
  font-weight: 850;
  letter-spacing: 0;
  flex: 0 0 auto;
}

.main-shell {
  min-width: 0;
  margin-left: 300px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 2;
  background: rgba(251, 250, 247, 0.64);
  backdrop-filter: blur(18px);
}

.nav {
  max-width: 1280px;
  margin: 0;
  padding: 18px 28px;
  display: flex;
  justify-content: flex-start;
  gap: 16px;
  align-items: center;
}

.menu-button {
  border: 0;
  background: transparent;
  font-size: 24px;
  color: var(--muted);
  padding: 6px 8px;
}

.nav-links {
  margin-left: auto;
  display: flex;
  gap: 26px;
  flex-wrap: wrap;
}

.nav-links a {
  color: var(--ink);
  font-weight: 650;
}

.tool-home {
  max-width: 1380px;
  margin: 0 auto;
  padding: 0 28px 48px;
}

.hero {
  max-width: 1280px;
  margin: 0 auto;
  padding: 54px 28px 28px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 26px;
  justify-items: center;
  text-align: center;
}

.search-hero {
  min-height: 430px;
  display: grid;
  align-content: center;
  justify-items: center;
  text-align: center;
  padding: 26px 0 34px;
}

.eyebrow {
  color: var(--warm);
  font-weight: 700;
  margin: 0 0 10px;
}

h1 {
  font-size: clamp(46px, 7vw, 86px);
  line-height: 1.05;
  margin: 0 0 12px;
  letter-spacing: 0;
  max-width: 900px;
}

h2 {
  font-size: 28px;
  line-height: 1.2;
  margin: 0 0 16px;
}

h3 {
  margin: 0 0 8px;
}

.lede {
  max-width: 820px;
  color: var(--muted);
  font-size: 18px;
  margin-left: auto;
  margin-right: auto;
}

.pill {
  display: inline-flex;
  padding: 6px 18px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid var(--line);
  color: var(--warm);
  font-weight: 800;
  margin: 0 0 18px;
}

.finder-panel {
  width: min(780px, 100%);
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 0;
  box-shadow: none;
}

.search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  width: min(840px, 100%);
  margin: 0 auto;
  border: 1px solid rgba(31, 35, 40, 0.08);
  border-radius: 999px;
  padding: 18px 22px;
  background: rgba(31, 35, 40, 0.18);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.65);
}

.search-box input {
  min-width: 0;
  width: 100%;
  border: 0;
  background: transparent;
  font: inherit;
  color: white;
  font-size: 20px;
}

.search-box input::placeholder {
  color: rgba(255, 255, 255, 0.76);
}

.search-box span {
  white-space: nowrap;
  color: white;
  font-size: 26px;
}

.search-tabs {
  display: flex;
  justify-content: center;
  gap: 40px;
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 17px;
}

.search-tabs .active {
  color: var(--ink);
  font-weight: 800;
  border-bottom: 4px solid var(--ink);
}

.quick-links {
  justify-content: center;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.showcase {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 18px;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  box-shadow: var(--shadow);
}

.rail-tabs {
  display: grid;
  gap: 8px;
  align-content: start;
}

.rail-tabs button {
  border: 0;
  border-radius: 8px;
  padding: 12px 8px;
  color: var(--muted);
  background: transparent;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.rail-tabs button.active {
  color: var(--ink);
  background: #eef0ef;
}

.banner-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.banner-card {
  min-height: 118px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  padding: 18px;
  color: #1f2a44;
  font-size: 25px;
  font-weight: 850;
  text-align: center;
}

.banner-card:hover {
  text-decoration: none;
}

.blue { background: #d9e8ff; }
.green { background: #def2d7; }
.violet { background: #f0e2fa; }
.cyan { background: #d8f0fa; }

.quick-links a {
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 10px;
  background: #fff;
  font-size: 14px;
}

.section {
  max-width: 1280px;
  margin: 0 auto;
  padding: 34px 20px;
}

.directory-panel {
  margin-top: 28px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 22px;
}

.promo-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.promo-strip a {
  min-height: 112px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  font-size: 24px;
  font-weight: 850;
  color: #22304a;
  background: linear-gradient(135deg, #dceafe, #f2f7ff);
  border: 1px solid rgba(255, 255, 255, 0.78);
  box-shadow: var(--shadow);
}

.promo-strip a:nth-child(2) {
  background: linear-gradient(135deg, #dff3d7, #f3fbef);
}

.promo-strip a:nth-child(3) {
  background: linear-gradient(135deg, #f1e7fb, #fbf2ff);
}

.promo-strip a:hover {
  text-decoration: none;
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 16px;
  margin-bottom: 16px;
}

.section-head .eyebrow {
  margin-bottom: 4px;
}

.text-link {
  font-weight: 700;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}

.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.card:hover {
  transform: translateY(-2px);
  border-color: rgba(31, 122, 104, 0.38);
  box-shadow: 0 12px 32px rgba(31, 35, 40, 0.08);
}

.meta {
  color: var(--muted);
  font-size: 14px;
}

.tag {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 13px;
  margin: 0 6px 6px 0;
}

.tag-warm {
  background: var(--warm-soft);
  color: var(--warm);
}

.category-band {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 12px;
}

.category-card {
  min-height: 178px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.category-card p {
  color: var(--muted);
  margin-bottom: 0;
  font-size: 14px;
}

.category-index {
  color: var(--warm);
  font-weight: 800;
  font-size: 13px;
}

.tool-section {
  margin-top: 18px;
}

.tool-section-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-top: 1px solid var(--line);
}

.tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 14px;
}

.tool-card[hidden] {
  display: none;
}

.tool-head {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.tool-mark {
  width: 42px;
  height: 42px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 800;
  border: 1px solid rgba(31, 122, 104, 0.16);
}

.feature-card {
  min-height: 170px;
}

.entry-layout {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(260px, 1fr);
  gap: 22px;
}

.fact-list {
  display: grid;
  gap: 12px;
}

.fact-list dt {
  font-weight: 700;
}

.fact-list dd {
  margin: 0;
  color: var(--muted);
}

.info-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 26px 0;
}

.info-strip div {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
}

.info-strip strong,
.info-strip span {
  display: block;
}

.info-strip strong {
  margin-bottom: 6px;
}

.info-strip span {
  color: var(--muted);
}

.site-footer {
  border-top: 1px solid var(--line);
  margin-top: 48px;
  padding: 24px 20px;
  color: var(--muted);
}

.site-footer-inner {
  max-width: 1120px;
  margin: 0 auto;
}

@media (max-width: 720px) {
  .nav {
    align-items: flex-start;
    flex-direction: column;
  }

  .hero {
    padding-top: 42px;
    grid-template-columns: 1fr;
  }

  .tool-home {
    padding: 0 16px 36px;
  }

  .search-hero {
    min-height: 340px;
  }

  .showcase {
    grid-template-columns: 1fr;
  }

  .rail-tabs {
    display: flex;
    overflow-x: auto;
  }

  .banner-grid {
    grid-template-columns: 1fr;
  }

  .entry-layout {
    grid-template-columns: 1fr;
  }

  .info-strip {
    grid-template-columns: 1fr;
  }

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

  .category-grid {
    grid-template-columns: 1fr;
  }

  .promo-strip {
    grid-template-columns: 1fr;
  }

  .search-tabs {
    gap: 18px;
    font-size: 15px;
  }
}

@media (min-width: 721px) and (max-width: 1040px) {
  .category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
