:root {
  --navy-900: #0c1e3a;
  --navy-800: #122849;
  --navy-700: #1a3560;
  --blue-600: #2563eb;
  --blue-500: #3b82f6;
  --blue-100: #dbeafe;
  --slate-50: #f8fafc;
  --slate-200: #e2e8f0;
  --slate-600: #475569;
  --white: #ffffff;
  --radius: 12px;
  --shadow: 0 4px 24px rgba(12, 30, 58, 0.12);
  --font: "Pretendard", "Apple SD Gothic Neo", "Malgun Gothic", system-ui,
    sans-serif;
}

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

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

body {
  margin: 0;
  min-height: 100dvh;
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--navy-900);
  background: linear-gradient(165deg, var(--slate-50) 0%, var(--blue-100) 45%, var(--slate-50) 100%);
}

.site-header {
  background: linear-gradient(135deg, var(--navy-900) 0%, var(--navy-700) 100%);
  color: var(--white);
  padding: 2.5rem 1.25rem 2rem;
  text-align: center;
}

.site-header__brand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.site-header__icon {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
}

.site-header__icon svg {
  width: 1.35rem;
  height: 1.35rem;
  fill: none;
  stroke: var(--white);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.site-header h1 {
  margin: 0;
  font-size: clamp(1.35rem, 4vw, 1.75rem);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.site-header__subtitle {
  margin: 0.35rem 0 0;
  font-size: 1.05rem;
  font-weight: 500;
  opacity: 0.92;
}

.site-header__tagline {
  margin: 1rem auto 0;
  max-width: 28rem;
  font-size: 0.9rem;
  opacity: 0.78;
  line-height: 1.5;
}

main {
  max-width: 42rem;
  margin: 0 auto;
  padding: 1.75rem 1.25rem 3rem;
}

.section-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--slate-600);
  margin: 0 0 0.75rem 0.25rem;
}

.test-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.test-card {
  margin: 0;
}

.test-card__link {
  display: block;
  text-decoration: none;
  color: inherit;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid var(--slate-200);
  padding: 1.25rem 1.35rem;
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}

.test-card__link:hover,
.test-card__link:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(12, 30, 58, 0.16);
  border-color: var(--blue-500);
  outline: none;
}

.test-card__link:focus-visible {
  outline: 2px solid var(--blue-500);
  outline-offset: 2px;
}

.test-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 0.65rem;
}

.badge {
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  background: var(--blue-100);
  color: var(--navy-700);
}

.test-card__title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--navy-900);
  line-height: 1.45;
}

.test-card__subtitle {
  margin: 0.4rem 0 0;
  font-size: 0.875rem;
  color: var(--slate-600);
}

.test-card__cta {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.85rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--blue-600);
}

.test-card__cta svg {
  width: 1rem;
  height: 1rem;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
}

.loading,
.error {
  text-align: center;
  padding: 2rem 1rem;
  color: var(--slate-600);
  background: var(--white);
  border-radius: var(--radius);
  border: 1px dashed var(--slate-200);
}

.error {
  color: #b91c1c;
  border-color: #fecaca;
  background: #fef2f2;
}

.site-footer {
  text-align: center;
  padding: 1.5rem 1.25rem 2rem;
  font-size: 0.8rem;
  color: var(--slate-600);
}

.site-footer a {
  color: var(--navy-700);
  text-decoration: none;
  font-weight: 500;
}

.site-footer a:hover {
  text-decoration: underline;
}

@media (min-width: 640px) {
  .site-header {
    padding: 3rem 1.5rem 2.5rem;
  }

  main {
    padding: 2rem 1.5rem 3.5rem;
  }
}
