:root {
  --ink: #17201d;
  --muted: #66736e;
  --paper: #eef1ec;
  --surface: #ffffff;
  --line: #d8ded9;
  --accent: #176f6b;
  --shadow: 0 18px 48px rgba(29, 42, 36, 0.1);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    linear-gradient(90deg, rgba(23, 32, 29, 0.028) 1px, transparent 1px),
    linear-gradient(rgba(23, 32, 29, 0.028) 1px, transparent 1px),
    var(--paper);
  background-size: 32px 32px;
  font-family: "Microsoft YaHei", "PingFang SC", sans-serif;
}

button,
input {
  font: inherit;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  width: min(1320px, calc(100vw - 40px));
  margin: 18px auto 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--ink);
  text-decoration: none;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 6px;
  background: var(--ink);
  color: white;
  font-family: Georgia, serif;
  font-size: 23px;
  font-weight: 700;
}

.brand > span:last-child {
  display: grid;
  gap: 1px;
}

.brand strong {
  font-size: 15px;
}

.brand small,
.topbar-meta {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
}

.topbar-meta {
  display: flex;
  align-items: center;
  gap: 16px;
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.status i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #2c9b6b;
  box-shadow: 0 0 0 4px rgba(44, 155, 107, 0.12);
}

main {
  width: min(1320px, calc(100vw - 40px));
  margin: 54px auto 80px;
}

.intro {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 500px);
  gap: 50px;
  align-items: end;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--accent);
  font-family: Georgia, serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 10px;
  font-family: Georgia, "Microsoft YaHei", serif;
  font-size: clamp(36px, 5vw, 58px);
  line-height: 1.08;
  letter-spacing: 0;
}

.intro p:last-child {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 14px;
}

.search-box {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 10px;
  align-items: center;
  height: 54px;
  padding: 0 14px;
  border: 1px solid #cbd4ce;
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--shadow);
}

.search-box svg {
  width: 18px;
  color: var(--accent);
}

.search-box input {
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
}

kbd {
  padding: 3px 7px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #f3f5f2;
  color: var(--muted);
  font-size: 11px;
}

.controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 44px;
  padding-bottom: 12px;
  border-bottom: 1px solid #cdd5cf;
}

.category-tabs {
  display: flex;
  gap: 5px;
  overflow-x: auto;
}

.category-tabs button {
  height: 32px;
  padding: 0 12px;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.category-tabs button.active {
  background: var(--ink);
  color: white;
}

#resultCount {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.app-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.app-card {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 13px;
  min-height: 168px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--ink);
  text-decoration: none;
  transition: transform 150ms ease, border-color 150ms ease, box-shadow 150ms ease;
}

.app-card:hover {
  transform: translateY(-3px);
  border-color: var(--app-color);
  box-shadow: var(--shadow);
}

.app-card.featured {
  border-top: 3px solid var(--app-color);
}

.app-icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 6px;
  background: color-mix(in srgb, var(--app-color) 12%, white);
  color: var(--app-color);
}

.app-icon svg {
  width: 23px;
}

.app-copy {
  display: grid;
  min-width: 0;
}

.app-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}

.app-heading h2 {
  margin-bottom: 0;
  font-size: 17px;
}

.app-type {
  flex: 0 0 auto;
  padding: 3px 6px;
  border: 1px solid var(--line);
  border-radius: 4px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
}

.app-card p {
  margin: 10px 0 16px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.65;
}

.app-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  align-self: end;
  color: var(--app-color);
  font-size: 11px;
  font-weight: 800;
}

.app-foot svg {
  width: 16px;
}

.empty-result {
  margin-top: 30px;
  padding: 60px 20px;
  border: 1px dashed #bdc7c0;
  border-radius: 7px;
  color: var(--muted);
  text-align: center;
}

.empty-result svg {
  width: 30px;
}

.empty-result strong {
  display: block;
  margin-top: 10px;
  color: var(--ink);
}

.empty-result p {
  margin: 6px 0 0;
  font-size: 12px;
}

footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  width: min(1320px, calc(100vw - 40px));
  margin: 0 auto 22px;
  color: var(--muted);
  font-size: 11px;
}

code {
  color: var(--accent);
  font-weight: 800;
}

@media (max-width: 920px) {
  .intro {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .app-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .topbar,
  main,
  footer {
    width: min(100% - 24px, 1320px);
  }

  .topbar-meta,
  kbd {
    display: none;
  }

  main {
    margin-top: 38px;
  }

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

  footer {
    display: grid;
  }
}
