:root {
  --result-accent: #111111;
  --result-muted: #757575;
  --result-border: #e0e0e0;
  --bar-bg: #ececec;
  --bar-fill: #111111;
  --badge-rare-bg: #fff8e1;
  --badge-rare-fg: #b8860b;
  --badge-special-bg: #f3e5f5;
  --badge-special-fg: #663399;
  --badge-hidden-bg: #ffebee;
  --badge-hidden-fg: #d9534f;
  --badge-fallback-bg: #e8f5e9;
  --badge-fallback-fg: #388e3c;
}

main {
  max-width: 720px;
}

.result-page {
  padding: 1rem 0 3rem;
}

.result-banner {
  background: #eef6ff;
  border: 1px solid #cfe4f5;
  border-radius: 12px;
  padding: 1rem 1.25rem;
  margin: 0 0 1.5rem;
}

.result-banner-row {
  display: flex;
  align-items: baseline;
  gap: 0.85rem;
  flex-wrap: wrap;
}

.result-banner-label {
  font-weight: 700;
  color: var(--result-accent);
  font-size: 0.95rem;
}

.result-banner-match {
  font-size: 1.05rem;
  font-weight: 700;
  color: #1967d2;
  font-variant-numeric: tabular-nums;
}

.result-banner-note {
  margin: 0.5rem 0 0;
  font-size: 0.9rem;
  color: var(--result-muted);
  line-height: 1.5;
}

.result-banner-note:empty {
  display: none;
}

.result-banner--friend {
  background: #f4f4f4;
  border-color: #dcdcdc;
}

.result-banner--friend .result-banner-match {
  color: var(--result-accent);
}

.result-header {
  text-align: center;
  padding: 2rem 0 2.5rem;
  border-bottom: 1px solid var(--result-border);
  margin-bottom: 2.5rem;
}

.result-code {
  font-size: clamp(3.5rem, 14vw, 6rem);
  font-weight: 900;
  letter-spacing: 0.04em;
  color: var(--result-accent);
  line-height: 1;
  margin-bottom: 0.5rem;
}

.result-name {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--result-muted);
  margin: 0 0 1rem;
}

.result-tagline {
  font-size: 1.125rem;
  color: var(--result-accent);
  margin: 0 0 1.25rem;
  line-height: 1.55;
}

.result-badges {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.result-badge {
  display: inline-block;
  padding: 0.3rem 0.85rem;
  border-radius: 12px;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.result-badge--rare { background: var(--badge-rare-bg); color: var(--badge-rare-fg); }
.result-badge--special { background: var(--badge-special-bg); color: var(--badge-special-fg); }
.result-badge--hidden { background: var(--badge-hidden-bg); color: var(--badge-hidden-fg); }
.result-badge--fallback { background: var(--badge-fallback-bg); color: var(--badge-fallback-fg); }

.result-description {
  font-size: 1.05rem;
  line-height: 1.8;
  margin-bottom: 3rem;
  color: var(--result-accent);
}

.result-description p {
  margin: 0;
}

.result-profile {
  margin-bottom: 2.5rem;
}

.profile-heading {
  font-size: 1.35rem;
  font-weight: 700;
  margin: 0 0 1.5rem;
  color: var(--result-accent);
}

.profile-model {
  margin-bottom: 1.75rem;
}

.profile-model-name {
  font-size: 1rem;
  font-weight: 700;
  color: var(--result-muted);
  margin: 0 0 0.85rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.profile-axis {
  margin-bottom: 1rem;
}

.profile-axis-label {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 0.25rem;
  font-size: 0.95rem;
  color: var(--result-accent);
}

.profile-axis-value {
  font-variant-numeric: tabular-nums;
  color: var(--result-muted);
  font-size: 0.85rem;
  font-weight: 600;
}

.profile-axis-bar {
  height: 6px;
  background: var(--bar-bg);
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: 0.25rem;
}

.profile-axis-fill {
  height: 100%;
  background: var(--bar-fill);
  border-radius: 3px;
  transition: width 0.4s ease;
}

.profile-axis-poles {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  color: var(--result-muted);
}

.result-share {
  padding: 2rem 0 1.5rem;
  border-top: 1px solid var(--result-border);
  text-align: center;
}

.result-share-heading {
  font-size: 0.95rem;
  color: var(--result-muted);
  margin: 0 0 1rem;
  letter-spacing: 0.01em;
}

.share-buttons {
  display: flex;
  justify-content: center;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.share-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  min-width: 7rem;
  padding: 0.7rem 1.1rem;
  border: 1px solid var(--result-border);
  background: #fff;
  border-radius: 10px;
  font-family: inherit;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--result-accent);
  cursor: pointer;
  transition: background 0.12s ease, transform 0.08s ease, border-color 0.12s ease;
}

.share-btn:hover {
  border-color: var(--result-accent);
  background: #f7f7f7;
}

.share-btn:active {
  transform: scale(0.98);
}

.share-btn--kakao {
  background: #fee500;
  border-color: #fee500;
  color: #3c1e1e;
}

.share-btn--kakao:hover {
  background: #ffd600;
  border-color: #ffd600;
}

.share-toast {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%) translateY(0.75rem);
  background: rgba(0, 0, 0, 0.85);
  color: #fff;
  padding: 0.7rem 1.25rem;
  border-radius: 10px;
  font-size: 0.9rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 9999;
}

.share-toast--visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.result-actions {
  padding-top: 2rem;
  border-top: 1px solid var(--result-border);
  text-align: center;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.result-link {
  display: inline-block;
  margin-top: 1rem;
  padding: 0.85rem 1.75rem;
  background: transparent;
  color: var(--result-accent);
  text-decoration: none;
  border: 1.5px solid var(--result-accent);
  border-radius: 10px;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  transition: background 0.15s ease, color 0.15s ease, transform 0.08s ease;
}

.result-link:hover {
  background: var(--result-accent);
  color: #ffffff;
}

.result-link:active {
  transform: scale(0.98);
}

.result-disclaimer {
  margin-top: 2rem;
  font-size: 0.8rem;
  color: var(--result-muted);
  text-align: center;
  font-style: italic;
}
