:root {
  --bg: #f6f8f9;
  --surface: #ffffff;
  --surface-soft: #eef5f4;
  --text: #0f172a;
  --text-muted: #475569;
  --primary: #0f3d3e;
  --primary-hover: #145355;
  --accent: #0d9488;
  --border: #e2e8f0;
  --ok-bg: #ecfdf5;
  --ok-text: #065f46;
  --warn-bg: #fffbeb;
  --warn-text: #92400e;
  --danger-bg: #fef2f2;
  --danger-text: #991b1b;
  --radius: 16px;
  --shadow: 0 8px 24px rgba(15, 61, 62, 0.08);
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Pretendard", -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

.site-header {
  background: var(--primary);
  color: #fff;
  padding: 14px 20px;
  position: sticky;
  top: 0;
  z-index: 20;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
}

.header-inner {
  max-width: 960px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
}

.brand-badge {
  background: rgba(255, 255, 255, 0.16);
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
}

.header-nav {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 0.9rem;
  opacity: 0.95;
}

.header-nav a:hover {
  text-decoration: underline;
}

.container {
  max-width: 960px;
  margin: 0 auto;
  padding: 24px 16px 56px;
}

.container-narrow {
  max-width: 720px;
}

.hero {
  background: linear-gradient(135deg, #0f3d3e 0%, #134e4a 100%);
  color: #fff;
  border-radius: var(--radius);
  padding: 32px 24px;
  margin-bottom: 24px;
  box-shadow: var(--shadow);
}

.hero-kicker {
  display: inline-block;
  background: rgba(255, 255, 255, 0.15);
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 700;
  margin-bottom: 10px;
}

.hero h1 {
  margin: 0 0 10px;
  font-size: clamp(1.45rem, 3.6vw, 2rem);
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.hero p {
  margin: 0;
  color: rgba(255, 255, 255, 0.88);
  font-size: 0.98rem;
}

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

.chip {
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-muted);
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.chip.active,
.chip:hover {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

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

.test-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.test-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
  border-color: var(--accent);
}

.card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.card-tag {
  background: var(--surface-soft);
  color: var(--primary);
  font-size: 0.78rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
}

.card-time {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.test-card h2 {
  margin: 0 0 8px;
  font-size: 1.12rem;
  line-height: 1.4;
}

.test-card p {
  margin: 0 0 16px;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.card-cta {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--primary);
}

/* Quiz box */
.quiz-shell {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 20px;
  box-shadow: var(--shadow);
  margin-bottom: 24px;
}

.quiz-header {
  margin-bottom: 20px;
}

.quiz-header h1 {
  margin: 0 0 8px;
  font-size: clamp(1.3rem, 3.2vw, 1.7rem);
  line-height: 1.35;
}

.quiz-desc {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.progress-wrap {
  margin: 18px 0 8px;
}

.progress-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 6px;
}

.progress-bar {
  height: 8px;
  background: #e2e8f0;
  border-radius: 999px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: var(--accent);
  width: 0%;
  transition: width 0.25s ease;
}

.question-title {
  font-size: 1.15rem;
  font-weight: 700;
  margin: 16px 0 6px;
}

.question-hint {
  font-size: 0.86rem;
  color: var(--text-muted);
  margin: 0 0 16px;
}

.option-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.option-btn {
  width: 100%;
  text-align: left;
  padding: 14px 16px;
  background: #f8fafc;
  border: 1.5px solid var(--border);
  border-radius: 12px;
  font-size: 0.96rem;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  transition: all 0.14s ease;
}

.option-btn:hover {
  border-color: var(--accent);
  background: var(--surface-soft);
}

.option-btn.selected {
  border-color: var(--primary);
  background: var(--surface-soft);
  color: var(--primary);
}

.quiz-actions {
  display: flex;
  justify-content: space-between;
  margin-top: 18px;
  gap: 10px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 18px;
  border-radius: 10px;
  font-size: 0.92rem;
  font-weight: 700;
  border: none;
  cursor: pointer;
  transition: background 0.15s ease;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
}

.btn-primary:hover {
  background: var(--primary-hover);
}

.btn-ghost {
  background: #f1f5f9;
  color: var(--text-muted);
}

.btn-ghost:hover {
  background: #e2e8f0;
}

.result-badge {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 800;
  margin-bottom: 10px;
}

.badge-ok { background: var(--ok-bg); color: var(--ok-text); }
.badge-warn { background: var(--warn-bg); color: var(--warn-text); }
.badge-danger { background: var(--danger-bg); color: var(--danger-text); }

.result-title {
  margin: 0 0 10px;
  font-size: 1.35rem;
  line-height: 1.35;
}

.result-summary {
  margin: 0 0 16px;
  color: var(--text-muted);
  font-size: 0.96rem;
}

.result-points {
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px 18px;
  margin: 0 0 18px;
}

.result-points ul {
  margin: 0;
  padding-left: 18px;
}

.result-points li {
  margin-bottom: 6px;
  font-size: 0.93rem;
}

.result-cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 12px;
}

.info-section {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 20px;
  margin-bottom: 20px;
}

.info-section h2 {
  margin: 0 0 12px;
  font-size: 1.12rem;
}

.info-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.info-table th,
.info-table td {
  border-bottom: 1px solid var(--border);
  padding: 10px 8px;
  text-align: left;
}

.info-table th {
  background: #f8fafc;
  color: var(--primary);
  font-weight: 700;
}

.faq-item {
  border-bottom: 1px solid var(--border);
  padding: 12px 0;
}

.faq-item:last-child {
  border-bottom: none;
}

.faq-q {
  font-weight: 700;
  margin-bottom: 4px;
}

.faq-a {
  font-size: 0.92rem;
  color: var(--text-muted);
  margin: 0;
}

.notice-box {
  font-size: 0.83rem;
  color: var(--text-muted);
  background: #f1f5f9;
  padding: 12px 14px;
  border-radius: 10px;
  margin-top: 14px;
}

.site-footer {
  border-top: 1px solid var(--border);
  padding: 24px 16px;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.footer-links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 8px;
}

@media (max-width: 600px) {
  .hero { padding: 24px 18px; }
  .quiz-shell { padding: 20px 16px; }
  .header-nav { font-size: 0.82rem; gap: 10px; }
}
