:root {
  --bg: #f6f8f7;
  --ink: #131b20;
  --muted: #6e7a82;
  --line: rgba(19, 27, 32, 0.1);
  --paper: rgba(255, 255, 255, 0.82);
  --shadow: 0 22px 60px rgba(21, 40, 54, 0.12);
  --font: Inter, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  color: var(--ink);
  font-family: var(--font);
  background:
    radial-gradient(circle at 14% 4%, rgba(31, 157, 142, 0.18), transparent 24%),
    radial-gradient(circle at 90% 16%, rgba(99, 102, 241, 0.14), transparent 22%),
    radial-gradient(circle at 76% 92%, rgba(245, 158, 11, 0.14), transparent 26%),
    linear-gradient(180deg, #fbfdfb, var(--bg));
  letter-spacing: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

.page {
  width: min(100%, 1180px);
  margin: 0 auto;
  padding: 26px 22px 42px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 22px;
}

.eyebrow {
  margin: 0;
  color: #178f82;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.14em;
}

.topbar h1 {
  margin: 8px 0 0;
  font-size: clamp(24px, 4vw, 42px);
  line-height: 1.08;
}

.ghost-link {
  display: inline-grid;
  place-items: center;
  min-width: 72px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.66);
  color: #243139;
  font-weight: 850;
}

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

.test-card {
  --accent: #178f82;
  --accent-2: #0ea5e9;
  position: relative;
  overflow: hidden;
  min-height: 260px;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: 8px;
  background:
    radial-gradient(circle at 100% 0, color-mix(in srgb, var(--accent), transparent 76%), transparent 34%),
    linear-gradient(180deg, rgba(255,255,255,.92), rgba(255,255,255,.74));
  box-shadow: 0 16px 42px rgba(21, 40, 54, 0.1);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.test-card:hover {
  transform: translateY(-4px);
  border-color: color-mix(in srgb, var(--accent), white 22%);
  box-shadow: 0 24px 62px rgba(21, 40, 54, 0.16);
}

.test-card::after {
  content: "";
  position: absolute;
  right: -34px;
  bottom: -34px;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--accent), transparent 84%);
}

.card-top {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  margin-bottom: 18px;
}

.card-top small {
  display: inline-grid;
  place-items: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: white;
  font-size: 13px;
  font-weight: 900;
  box-shadow: 0 12px 24px color-mix(in srgb, var(--accent), transparent 72%);
}

.test-card h3,
.test-card p,
.meta,
.test-card strong {
  position: relative;
  z-index: 1;
}

.test-card h3 {
  margin: 0 0 12px;
  font-size: 24px;
  line-height: 1.22;
}

.test-card p {
  min-height: 72px;
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.65;
}

.meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.meta span {
  padding: 6px 9px;
  border: 1px solid rgba(19, 27, 32, 0.08);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.66);
  color: #33424c;
  font-size: 12px;
  font-weight: 850;
}

.test-card strong {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 48px;
  padding: 0 14px;
  border-radius: 8px;
  color: white;
  background: #131b20;
  font-size: 15px;
}

.test-card strong::after {
  content: ">";
  color: color-mix(in srgb, var(--accent), white 18%);
  font-size: 20px;
}

.card-mbti { --accent: #4f46e5; --accent-2: #0ea5e9; }
.card-five { --accent: #0f766e; --accent-2: #22c55e; }
.card-trauma { --accent: #be123c; --accent-2: #fb7185; }
.card-career { --accent: #365314; --accent-2: #eab308; }
.card-city-fit { --accent: #047857; --accent-2: #38bdf8; }
.card-element { --accent: #7c3aed; --accent-2: #f59e0b; }
.card-civil { --accent: #9a3412; --accent-2: #0f766e; }
.card-love { --accent: #831843; --accent-2: #fb7185; }
.card-talent { --accent: #7c3aed; --accent-2: #38bdf8; }
.card-deity { --accent: #1f766f; --accent-2: #7c6fd6; }
.card-boy-control { --accent: #d94669; --accent-2: #ff7fa0; }

footer {
  margin-top: 22px;
  padding: 18px 0 0;
  color: var(--muted);
  text-align: center;
  font-size: 13px;
  line-height: 1.7;
}

@media (max-width: 920px) {
  .test-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .page {
    padding: 18px 14px 32px;
  }

  .topbar {
    align-items: flex-start;
  }

  .ghost-link {
    min-width: 58px;
    height: 38px;
  }

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

  .test-card {
    min-height: 0;
  }

  .test-card p {
    min-height: 0;
  }
}
