@import url('https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.9/dist/web/static/pretendard.css');
@import url('https://fonts.googleapis.com/css2?family=Gowun+Batang:wght@400;700&family=Gaegu:wght@400;700&display=swap');

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary: #c98ba0;
  --primary-dark: #a86178;
  --primary-soft: #f7e3e8;
  --secondary: #b8a4d4;
  --accent: #d4b08c;
  --accent-soft: #f5e8d8;
  --bg-base: #fbf6f1;
  --bg-pink: #fae3e6;
  --bg-cream: #faf5ee;
  --bg-gradient: linear-gradient(180deg, #fbf6f1 0%, #fae3e6 100%);
  --text: #3a2d36;
  --text-soft: #5c4a55;
  --text-light: #9b8a93;
  --card-bg: #ffffff;
  --border: rgba(168, 97, 120, 0.08);
  --shadow-sm: 0 2px 12px rgba(168, 97, 120, 0.04);
  --shadow: 0 6px 24px rgba(168, 97, 120, 0.07);
  --shadow-lg: 0 14px 40px rgba(168, 97, 120, 0.12);
}

html, body {
  font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  color: var(--text);
  background: var(--bg-gradient);
  background-attachment: fixed;
  min-height: 100vh;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  letter-spacing: -0.01em;
}

.serif, h1, h2, h3, h4, .q-text {
  font-family: 'Gowun Batang', 'Pretendard', serif;
  letter-spacing: -0.02em;
}

.container {
  max-width: 540px;
  margin: 0 auto;
  padding: 20px 22px 56px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  position: relative;
  z-index: 1;
}

/* === 떠다니는 배경 장식 === */
.floating-decorations {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.float-item {
  position: absolute;
  bottom: -40px;
  opacity: 0;
  animation: floatUp linear infinite;
  filter: drop-shadow(0 2px 4px rgba(168, 97, 120, 0.1));
}

@keyframes floatUp {
  0% { transform: translateY(0) rotate(0deg) scale(0.6); opacity: 0; }
  10% { opacity: 0.55; }
  50% { transform: translateY(-50vh) rotate(180deg) scale(1); }
  90% { opacity: 0.55; }
  100% { transform: translateY(-110vh) rotate(360deg) scale(0.7); opacity: 0; }
}

/* === 결과 페이지 컨페티 === */
.confetti-container {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  overflow: hidden;
}

.confetti-item {
  position: absolute;
  top: -60px;
  opacity: 1;
  animation: confettiFall linear forwards;
  filter: drop-shadow(0 4px 8px rgba(168, 97, 120, 0.2));
}

@keyframes confettiFall {
  0% { transform: translateY(0) rotate(0) scale(0.8); opacity: 1; }
  10% { transform: translateY(8vh) rotate(45deg) scale(1); }
  100% { transform: translateY(110vh) rotate(540deg) scale(0.8); opacity: 0.2; }
}

/* Header */
.header {
  text-align: center;
  padding: 10px 0 28px;
}

.header .logo {
  font-family: 'Gowun Batang', serif;
  font-size: 22px;
  font-weight: 700;
  color: var(--primary-dark);
  text-decoration: none;
  letter-spacing: 0.01em;
}

/* Hero */
.hero {
  text-align: center;
  padding: 32px 0 36px;
}

.hero .emoji {
  font-size: 52px;
  margin-bottom: 18px;
  filter: drop-shadow(0 4px 12px rgba(168, 97, 120, 0.15));
  animation: heroEmojiFloat 3s ease-in-out infinite;
}

@keyframes heroEmojiFloat {
  0%, 100% { transform: translateY(0) rotate(-2deg); }
  50% { transform: translateY(-8px) rotate(2deg); }
}

/* === 메인 히어로 마스코트 === */
.hero-mascot {
  position: relative;
  width: 100%;
  height: 130px;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mascot-row {
  display: flex;
  gap: 18px;
  align-items: center;
  position: relative;
  z-index: 2;
}

.mascot {
  font-size: 52px;
  filter: drop-shadow(0 6px 16px rgba(168, 97, 120, 0.25));
  display: inline-block;
}

.mascot.m-left {
  font-size: 44px;
  animation: mascotBounceA 2.8s ease-in-out infinite;
}

.mascot.m-center {
  font-size: 64px;
  animation: mascotBounceB 2.4s ease-in-out infinite;
  animation-delay: 0.2s;
}

.mascot.m-right {
  font-size: 44px;
  animation: mascotBounceA 2.8s ease-in-out infinite;
  animation-delay: 0.4s;
}

@keyframes mascotBounceA {
  0%, 100% { transform: translateY(0) rotate(-6deg); }
  50% { transform: translateY(-10px) rotate(6deg); }
}

@keyframes mascotBounceB {
  0%, 100% { transform: translateY(0) scale(1) rotate(0deg); }
  50% { transform: translateY(-14px) scale(1.08) rotate(-3deg); }
}

.sparkle {
  position: absolute;
  font-size: 22px;
  opacity: 0;
  filter: drop-shadow(0 2px 6px rgba(212, 176, 140, 0.4));
  z-index: 1;
  animation: sparkleTwinkle 3s ease-in-out infinite;
}

.sp-1 { top: 8px;   left: 22%; animation-delay: 0s; }
.sp-2 { top: 20px;  right: 22%; font-size: 18px; animation-delay: 0.8s; }
.sp-3 { bottom: 14px; left: 18%; font-size: 16px; animation-delay: 1.5s; }
.sp-4 { bottom: 20px; right: 18%; font-size: 20px; animation-delay: 2.2s; }

@keyframes sparkleTwinkle {
  0%, 100% { opacity: 0; transform: scale(0.5) rotate(0); }
  50% { opacity: 1; transform: scale(1.1) rotate(180deg); }
}

.hero h1 {
  font-size: 30px;
  font-weight: 700;
  line-height: 1.35;
  margin-bottom: 14px;
  color: var(--text);
}

.hero h1 .accent {
  color: var(--primary-dark);
  position: relative;
  display: inline-block;
}

.hero h1 .accent::after {
  content: '';
  position: absolute;
  left: -2px;
  right: -2px;
  bottom: 2px;
  height: 8px;
  background: var(--primary-soft);
  z-index: -1;
  border-radius: 4px;
}

.hero .subtitle {
  font-size: 14px;
  color: var(--text-light);
  margin-bottom: 28px;
  font-weight: 500;
  line-height: 1.7;
}

/* Buttons */
.btn {
  display: inline-block;
  width: 100%;
  padding: 16px 24px;
  border: none;
  border-radius: 14px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  text-align: center;
  transition: all 0.2s ease;
  letter-spacing: -0.01em;
}

.btn-primary {
  background: var(--primary);
  color: white;
  box-shadow: 0 6px 20px rgba(168, 97, 120, 0.25);
}

.btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(168, 97, 120, 0.35);
}

.btn-secondary {
  background: white;
  color: var(--text);
  border: 1.5px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.btn-secondary:hover {
  border-color: var(--primary);
  color: var(--primary-dark);
  background: var(--primary-soft);
}

.btn + .btn {
  margin-top: 10px;
}

/* Test cards (hub) */
.test-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 28px;
}

.test-card {
  display: flex;
  align-items: center;
  gap: 18px;
  background: white;
  border-radius: 22px;
  padding: 22px 22px;
  text-decoration: none;
  color: var(--text);
  box-shadow: var(--shadow);
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
  border: 1px solid var(--border);
}

.test-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(180deg, var(--primary), var(--secondary));
}

.test-card-teto::before {
  background: linear-gradient(180deg, #e8a890, #d4856a);
}

.test-card-compat::before {
  background: linear-gradient(180deg, #b8a4d4, #8e7ab8);
}

.test-card-compat .test-card-meta {
  color: #7c5fa3;
}

.test-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

.test-card::after {
  content: '✨';
  position: absolute;
  top: 12px;
  right: 14px;
  font-size: 14px;
  opacity: 0;
  transform: scale(0.5) rotate(-30deg);
  transition: all 0.3s;
}

.test-card:hover::after {
  opacity: 1;
  transform: scale(1.2) rotate(20deg);
}

.test-card-emoji {
  transition: transform 0.3s ease;
}

.test-card:hover .test-card-emoji {
  animation: cardEmojiBounce 0.5s ease;
}

@keyframes cardEmojiBounce {
  0%, 100% { transform: scale(1) rotate(0); }
  50% { transform: scale(1.15) rotate(-8deg); }
}

.test-card-emoji {
  font-size: 40px;
  flex-shrink: 0;
  filter: drop-shadow(0 2px 8px rgba(168, 97, 120, 0.12));
}

.test-card-body h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--text);
}

.test-card-body p {
  font-size: 13px;
  color: var(--text-light);
  margin-bottom: 8px;
  line-height: 1.5;
}

.test-card-meta {
  font-size: 11px;
  color: var(--primary-dark);
  font-weight: 700;
  letter-spacing: 0.02em;
}

.test-card-teto .test-card-meta {
  color: #b87455;
}

/* Feature list / link list */
.feature-list {
  background: white;
  border-radius: 22px;
  padding: 24px 22px;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

.feature-list h3 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 14px;
  text-align: center;
}

.feature-list ul {
  list-style: none;
}

.feature-list li {
  padding: 9px 0;
  font-size: 13.5px;
  color: var(--text-soft);
  display: flex;
  gap: 10px;
  align-items: center;
}

.feature-list li::before {
  content: '✦';
  color: var(--accent);
  font-size: 11px;
}

.link-list {
  list-style: none;
}

.link-list li {
  padding: 0;
}

.link-list li::before { content: none; }

.link-list a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 4px;
  font-size: 14px;
  color: var(--text);
  text-decoration: none;
  border-bottom: 1px solid var(--border);
  font-weight: 600;
}

.link-list a::after {
  content: '›';
  color: var(--text-light);
  font-size: 20px;
  font-weight: 400;
}

.link-list li:last-child a {
  border-bottom: none;
}

.link-list a:hover {
  color: var(--primary-dark);
}

/* Progress */
.progress-wrap {
  margin-bottom: 32px;
}

.progress-bar {
  height: 6px;
  background: rgba(168, 97, 120, 0.1);
  border-radius: 100px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary) 0%, var(--secondary) 100%);
  border-radius: 100px;
  transition: width 0.4s ease;
}

.progress-text {
  text-align: center;
  margin-top: 12px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-light);
  letter-spacing: 0.08em;
}

/* Question card */
.question-card {
  background: white;
  border-radius: 28px;
  padding: 40px 28px;
  box-shadow: var(--shadow);
  margin-bottom: 22px;
  min-height: 180px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  position: relative;
}

.question-card::before {
  content: '“';
  position: absolute;
  top: 12px;
  left: 20px;
  font-family: 'Gowun Batang', serif;
  font-size: 40px;
  color: var(--primary-soft);
  line-height: 1;
}

.q-text {
  font-size: 21px;
  font-weight: 700;
  text-align: center;
  line-height: 1.55;
  color: var(--text);
}

.choice-btn {
  display: block;
  width: 100%;
  padding: 18px 22px;
  background: white;
  border: 1.5px solid var(--border);
  border-radius: 16px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  text-align: left;
  box-shadow: var(--shadow-sm);
  transition: all 0.15s;
  margin-bottom: 10px;
}

.choice-btn:hover {
  border-color: var(--primary);
  background: var(--primary-soft);
  transform: translateX(3px);
  box-shadow: var(--shadow);
}

.choice-btn:active {
  transform: scale(0.99);
}

/* Section title */
.section-title {
  text-align: center;
  margin-bottom: 32px;
}

.section-title h2 {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 10px;
}

.section-title p {
  font-size: 13px;
  color: var(--text-light);
}

/* Blood / Gender grid */
.blood-grid, .gender-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.blood-btn, .gender-btn {
  aspect-ratio: 1;
  background: white;
  border: 1.5px solid var(--border);
  border-radius: 24px;
  font-family: inherit;
  cursor: pointer;
  box-shadow: var(--shadow);
  transition: all 0.2s;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.blood-btn {
  font-family: 'Gowun Batang', serif;
  font-size: 48px;
  font-weight: 700;
  color: var(--primary-dark);
}

.blood-btn:hover, .gender-btn:hover {
  border-color: var(--primary);
  background: var(--primary-soft);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.blood-btn .label {
  display: block;
  font-family: 'Pretendard', sans-serif;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-light);
  margin-top: 4px;
}

.gender-emoji {
  font-size: 56px;
}

.gender-btn strong {
  font-size: 17px;
  font-weight: 700;
  color: var(--text);
}

/* Result hero */
.result-hero {
  text-align: center;
  padding: 20px 0 32px;
}

.result-hero .type-badge {
  display: inline-block;
  background: white;
  padding: 7px 18px;
  border-radius: 100px;
  font-family: 'Pretendard', sans-serif;
  font-size: 11px;
  font-weight: 700;
  color: var(--primary-dark);
  margin-bottom: 18px;
  box-shadow: var(--shadow-sm);
  letter-spacing: 0.08em;
  border: 1px solid var(--border);
}

.result-hero h1 {
  font-size: 30px;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--text);
}

.result-hero .tagline {
  font-size: 14px;
  color: var(--text-soft);
}

/* Result cards */
.result-card {
  background: white;
  border-radius: 22px;
  padding: 24px 22px;
  box-shadow: var(--shadow);
  margin-bottom: 14px;
  border: 1px solid var(--border);
}

.result-card h3 {
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.result-card p, .result-card li {
  font-size: 14px;
  line-height: 1.8;
  color: var(--text-soft);
}

.result-card ul {
  list-style: none;
  padding-left: 0;
}

.result-card ul li {
  padding: 8px 0 8px 22px;
  position: relative;
}

.result-card ul li::before {
  content: '✦';
  position: absolute;
  left: 4px;
  top: 9px;
  color: var(--accent);
  font-size: 11px;
}

.blood-trait-line {
  font-weight: 700;
  color: var(--primary-dark);
  margin-bottom: 8px;
}

.compat-list li {
  padding: 10px 0 10px 22px;
  border-bottom: 1px solid var(--border);
}

.compat-list li:last-child {
  border-bottom: none;
}

.compat-note {
  display: block;
  margin-top: 4px;
  font-size: 13px;
  color: var(--text-light);
}

.tip-card {
  background: linear-gradient(135deg, #fbf4ec 0%, #f8e3e7 100%);
  border-color: rgba(212, 176, 140, 0.2);
}

.tip-card h3 {
  color: var(--primary-dark);
}

.match-card-result {
  background: linear-gradient(135deg, #fbf4ec 0%, #f8e3e7 100%);
  border-color: rgba(212, 176, 140, 0.2);
}

.match-spotlight {
  text-align: center;
  padding: 16px 0 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.match-spot-emoji {
  font-size: 56px;
  margin-bottom: 4px;
  filter: drop-shadow(0 4px 12px rgba(168, 97, 120, 0.18));
}

.match-spotlight strong {
  font-family: 'Gowun Batang', serif;
  font-size: 26px;
  font-weight: 700;
  color: var(--primary-dark);
}

.match-spot-tagline {
  font-size: 13px;
  color: var(--text-light);
}

.match-reason-text {
  font-size: 14px;
  line-height: 1.7;
  text-align: center;
  padding: 14px 8px 0;
  border-top: 1px dashed var(--border);
  color: var(--text-soft);
}

.placeholder-note {
  background: rgba(255, 255, 255, 0.6);
  border: 1px dashed var(--border);
  border-radius: 16px;
  padding: 20px;
  font-size: 14px;
  color: var(--text-light);
  text-align: center;
  margin-bottom: 16px;
}

/* Share */
.share-section {
  margin-top: 24px;
  text-align: center;
}

.share-section .share-label {
  font-size: 12px;
  color: var(--text-light);
  margin-bottom: 12px;
  letter-spacing: 0.05em;
}

.footer {
  text-align: center;
  padding: 36px 0 16px;
  font-size: 12px;
  color: var(--text-light);
  margin-top: auto;
  letter-spacing: 0.05em;
}

.footer-links {
  margin-top: 12px;
  display: flex;
  justify-content: center;
  gap: 16px;
}

.footer-links a {
  color: var(--text-light);
  text-decoration: none;
  font-size: 11px;
}

.footer-links a:hover {
  color: var(--primary-dark);
}

/* === 도감 페이지 === */
.doc-article .doc-hero {
  text-align: center;
  padding: 20px 0 16px;
}

.doc-emoji {
  font-size: 56px;
  margin: 12px 0;
  filter: drop-shadow(0 4px 12px rgba(168, 97, 120, 0.15));
}

.group-section {
  margin: 32px 0;
}

.group-section h2 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 16px;
  padding-left: 4px;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 10px;
}

.group-section h2::before {
  content: '';
  width: 4px;
  height: 18px;
  background: var(--primary);
  border-radius: 2px;
}

.type-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.type-card {
  background: white;
  border-radius: 18px;
  padding: 20px 14px;
  text-decoration: none;
  color: var(--text);
  text-align: center;
  box-shadow: var(--shadow);
  transition: all 0.2s;
  display: flex;
  flex-direction: column;
  gap: 4px;
  border: 1px solid var(--border);
}

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

.type-emoji {
  font-size: 30px;
  margin-bottom: 4px;
}

.type-card strong {
  font-family: 'Gowun Batang', serif;
  font-size: 17px;
  font-weight: 700;
  color: var(--primary-dark);
  letter-spacing: 0;
}

.type-nick {
  font-size: 12px;
  color: var(--text-light);
}

.blood-type-card .type-emoji {
  font-family: 'Gowun Batang', serif;
  font-size: 36px;
  font-weight: 700;
  color: var(--primary-dark);
}

.match-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 8px;
}

.match-card {
  background: linear-gradient(135deg, #fdf4ee 0%, #faeae0 100%);
  border-radius: 14px;
  padding: 16px 12px;
  text-decoration: none;
  color: var(--text);
  text-align: center;
  transition: transform 0.15s;
  display: flex;
  flex-direction: column;
  gap: 2px;
  border: 1px solid var(--border);
}

.match-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.match-emoji {
  font-size: 24px;
}

.match-card strong {
  font-family: 'Gowun Batang', serif;
  font-size: 15px;
  font-weight: 700;
  color: var(--primary-dark);
}

.match-nick {
  font-size: 11px;
  color: var(--text-light);
}

.blood-variants {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.blood-variant {
  padding: 14px 16px;
  background: rgba(247, 227, 232, 0.4);
  border-radius: 12px;
  border-left: 3px solid var(--primary);
}

.blood-variant h4 {
  font-size: 14px;
  font-weight: 700;
  color: var(--primary-dark);
  margin-bottom: 6px;
}

.blood-variant p {
  font-family: 'Pretendard', sans-serif;
  font-size: 13px;
  color: var(--text-soft);
  line-height: 1.65;
  letter-spacing: -0.01em;
}

.related-group {
  margin-bottom: 16px;
}

.related-group h5 {
  font-family: 'Pretendard', sans-serif;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-light);
  margin-bottom: 10px;
  letter-spacing: 0.05em;
}

.mini-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.mini-card {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 8px 14px;
  background: rgba(255, 255, 255, 0.7);
  border-radius: 100px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
  transition: all 0.15s;
  border: 1px solid var(--border);
}

.mini-card:hover {
  background: var(--primary-soft);
  border-color: var(--primary);
  color: var(--primary-dark);
}

.cta-box {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  border-radius: 22px;
  padding: 28px 22px;
  text-align: center;
  margin: 28px 0;
  color: white;
  box-shadow: 0 12px 32px rgba(168, 97, 120, 0.25);
}

.cta-box h3 {
  font-family: 'Gowun Batang', serif;
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 18px;
  color: white;
}

.cta-box .btn-primary {
  background: white;
  color: var(--primary-dark);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.cta-box .btn-primary:hover {
  background: var(--bg-cream);
  transform: translateY(-2px);
}

.cta-box .btn-secondary {
  background: rgba(255, 255, 255, 0.2);
  color: white;
  border-color: rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(8px);
}

.cta-box .btn-secondary:hover {
  background: rgba(255, 255, 255, 0.3);
  border-color: rgba(255, 255, 255, 0.5);
  color: white;
}

.compat-list-doc .compat-row {
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}

.compat-list-doc .compat-row:last-child {
  border-bottom: none;
}

.compat-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 4px;
  font-size: 15px;
}

.compat-header strong {
  font-family: 'Gowun Batang', serif;
  font-weight: 700;
}

.compat-score {
  color: var(--primary-dark);
  font-weight: 700;
  letter-spacing: 0.05em;
}

.compat-list-doc p {
  font-family: 'Pretendard', sans-serif;
  font-size: 13px;
  color: var(--text-light);
  letter-spacing: -0.01em;
}

/* === 상세 카드 === */
.style-summary-text {
  font-size: 15px;
  font-weight: 600;
  color: var(--primary-dark);
  margin-bottom: 18px;
  padding: 14px 16px;
  background: var(--primary-soft);
  border-radius: 12px;
  line-height: 1.7;
}

.style-details {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.style-item h4 {
  font-family: 'Pretendard', sans-serif;
  font-size: 14px;
  font-weight: 700;
  color: var(--primary-dark);
  margin-bottom: 6px;
  letter-spacing: -0.01em;
}

.style-item p {
  font-size: 13.5px;
  line-height: 1.75;
  color: var(--text-soft);
}

.detail-list .detail-item {
  padding: 12px 0 12px 22px !important;
  position: relative;
  border-bottom: 1px dashed var(--border);
  display: block;
}

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

.detail-list .detail-item::before {
  content: '✦' !important;
  top: 14px !important;
  color: var(--accent) !important;
}

.detail-list .detail-item strong {
  display: block;
  font-family: 'Gowun Batang', serif;
  font-size: 15px;
  font-weight: 700;
  color: var(--primary-dark);
  margin-bottom: 4px;
}

.detail-list .detail-item span {
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--text-soft);
}

/* === Match Detail === */
.match-detail {
  background: linear-gradient(135deg, #fdf4ee 0%, #faeae0 100%);
  border-radius: 16px;
  padding: 18px 16px;
  margin-bottom: 12px;
  border: 1px solid var(--border);
}

.match-detail:last-child {
  margin-bottom: 0;
}

.match-detail-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 10px;
}

.match-detail-emoji {
  font-size: 30px;
}

.match-detail-head strong {
  display: block;
  font-family: 'Gowun Batang', serif;
  font-size: 17px;
  font-weight: 700;
  color: var(--primary-dark);
  line-height: 1.2;
}

.match-detail-nick {
  font-size: 12px;
  color: var(--text-light);
}

.match-why {
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--text-soft);
  margin-bottom: 8px;
}

.match-synergy {
  font-size: 13px;
  font-weight: 700;
  color: var(--primary-dark);
  padding-top: 8px;
  border-top: 1px dashed var(--border);
}

.match-warning {
  font-size: 13px;
  font-weight: 700;
  color: #b87555;
  padding-top: 8px;
  border-top: 1px dashed var(--border);
}

/* === 연인 궁합 섹션 === */
.partner-card {
  background: linear-gradient(135deg, #fff 0%, #fdf4f1 100%);
}

.partner-intro {
  font-size: 13px;
  color: var(--text-light);
  margin-bottom: 16px;
  line-height: 1.6;
}

.partner-form-section {
  margin: 20px 0;
}

.partner-form-section h4 {
  font-size: 14px;
  font-weight: 700;
  color: var(--primary-dark);
  margin-bottom: 10px;
}

.pick-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.pick-grid-blood {
  grid-template-columns: repeat(4, 1fr);
}

.pick-btn {
  padding: 10px 6px;
  background: white;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  font-family: 'Pretendard', sans-serif;
  font-size: 12px;
  font-weight: 700;
  color: var(--text);
  cursor: pointer;
  transition: all 0.15s;
}

.pick-btn:hover {
  border-color: var(--primary);
}

.pick-btn.selected {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}

.pick-btn-blood {
  padding: 12px 6px;
  font-size: 14px;
  font-family: 'Gowun Batang', serif;
}

/* 연인 결과 */
.partner-summary {
  margin: 20px 0;
}

.partner-vs {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  padding: 20px 0;
}

.partner-side {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  text-align: center;
}

.partner-emoji {
  font-size: 44px;
  filter: drop-shadow(0 4px 12px rgba(168, 97, 120, 0.15));
}

.partner-side strong {
  font-family: 'Gowun Batang', serif;
  font-size: 17px;
  font-weight: 700;
  color: var(--primary-dark);
}

.partner-side span {
  font-size: 12px;
  color: var(--text-light);
}

.partner-x {
  font-family: 'Gowun Batang', serif;
  font-size: 28px;
  color: var(--primary);
  font-weight: 700;
}

.score-box {
  background: linear-gradient(135deg, var(--primary-soft) 0%, #fdf0e8 100%);
  border-radius: 18px;
  padding: 22px 18px;
  text-align: center;
  border: 1px solid var(--border);
}

.score-emoji {
  font-size: 40px;
  margin-bottom: 6px;
}

.score-box h4 {
  font-family: 'Gowun Batang', serif;
  font-size: 22px;
  font-weight: 700;
  color: var(--primary-dark);
  margin-bottom: 8px;
}

.score-box p {
  font-size: 13px;
  color: var(--text-soft);
  margin-bottom: 16px;
  line-height: 1.6;
}

.score-bar-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  color: var(--text-soft);
  font-weight: 600;
}

.score-bar {
  flex: 1;
  height: 8px;
  background: rgba(255, 255, 255, 0.7);
  border-radius: 100px;
  overflow: hidden;
}

.score-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary) 0%, var(--secondary) 100%);
  border-radius: 100px;
  transition: width 0.6s ease;
}

.score-num {
  font-family: 'Gowun Batang', serif;
  font-size: 14px;
  font-weight: 700;
  color: var(--primary-dark);
}

.sub-head {
  font-family: 'Gowun Batang', serif;
  font-size: 16px;
  font-weight: 700;
  margin: 22px 0 12px;
  color: var(--text);
}

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

.dim-card {
  background: white;
  border-radius: 14px;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-left: 4px solid var(--primary);
}

.dim-card.dim-match {
  border-left-color: #88b89a;
  background: #f3fbf6;
}

.dim-card.dim-diff {
  border-left-color: #d4b08c;
  background: #fdf6ef;
}

.dim-card strong {
  display: block;
  font-family: 'Gowun Batang', serif;
  font-size: 14px;
  font-weight: 700;
  color: var(--primary-dark);
  margin-bottom: 6px;
}

.dim-card p {
  font-size: 13px;
  line-height: 1.7;
  color: var(--text-soft);
}

.blood-compat-box {
  background: linear-gradient(135deg, #fdf4ee 0%, #faeae0 100%);
  border-radius: 14px;
  padding: 16px;
  border: 1px solid var(--border);
}

.blood-compat-head {
  display: flex;
  justify-content: space-between;
  margin-bottom: 6px;
}

.blood-compat-head strong {
  font-family: 'Gowun Batang', serif;
  font-size: 15px;
  font-weight: 700;
  color: var(--primary-dark);
}

.blood-compat-box .score {
  color: var(--primary-dark);
  font-weight: 700;
}

.blood-compat-box p {
  font-size: 13px;
  color: var(--text-soft);
  line-height: 1.6;
}

.tip-box-inner {
  background: linear-gradient(135deg, #fbf4ec 0%, #f8e3e7 100%);
  border-radius: 14px;
  padding: 16px;
  border: 1px solid var(--border);
}

.tip-box-inner p {
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--text-soft);
}

.tip-box-inner .partner-tip {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px dashed var(--border);
}

.tip-box-inner strong {
  color: var(--primary-dark);
}

/* === 테토 카드 픽 === */
.teto-pick-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 4px;
}

.teto-pick-card {
  background: white;
  border: 1.5px solid var(--border);
  border-radius: 14px;
  padding: 16px 12px;
  font-family: inherit;
  cursor: pointer;
  text-align: center;
  transition: all 0.15s;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.teto-pick-card:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
  background: var(--primary-soft);
}

.teto-pick-emoji {
  font-size: 28px;
}

.teto-pick-card strong {
  font-family: 'Gowun Batang', serif;
  font-size: 14px;
  font-weight: 700;
  color: var(--primary-dark);
}

.teto-pick-card span {
  font-size: 11px;
  color: var(--text-light);
  line-height: 1.4;
}

/* === 궁합 도구 페이지 === */
.compat-picker {
  padding: 24px 20px;
}

.picker-section {
  margin-bottom: 8px;
}

.picker-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  gap: 10px;
  flex-wrap: wrap;
}

.picker-head h3 {
  font-size: 16px;
  font-weight: 700;
  margin: 0;
}

.picker-preview {
  font-size: 13px;
  color: var(--text-light);
  padding: 6px 12px;
  background: var(--bg-cream);
  border-radius: 100px;
  font-weight: 600;
}

.picker-preview.active {
  color: var(--primary-dark);
  background: var(--primary-soft);
}

.picker-preview .preview-emoji {
  margin-right: 4px;
}

.compat-group {
  margin-bottom: 14px;
}

.compat-group h5 {
  font-family: 'Pretendard', sans-serif;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-light);
  margin-bottom: 8px;
  letter-spacing: 0.08em;
  padding-left: 4px;
}

.compat-type-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.compat-type-btn {
  background: white;
  border: 1.5px solid var(--border);
  border-radius: 12px;
  padding: 12px 4px;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.15s;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.compat-type-btn:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
  background: var(--primary-soft);
}

.compat-type-btn.selected {
  background: var(--primary);
  color: white;
  border-color: var(--primary-dark);
  box-shadow: 0 4px 14px rgba(168, 97, 120, 0.3);
}

.compat-type-btn.selected strong {
  color: white;
}

.compat-type-emoji {
  font-size: 20px;
}

.compat-type-btn strong {
  font-family: 'Pretendard', sans-serif;
  font-size: 12px;
  font-weight: 700;
  color: var(--primary-dark);
  letter-spacing: 0.02em;
}

.picker-divider {
  display: flex;
  justify-content: center;
  margin: 20px 0;
  position: relative;
}

.picker-divider::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--border);
  z-index: 0;
}

.swap-btn {
  position: relative;
  z-index: 1;
  background: white;
  border: 1.5px solid var(--border);
  border-radius: 100px;
  padding: 8px 18px;
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  color: var(--primary-dark);
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: all 0.15s;
}

.swap-btn:hover {
  background: var(--primary-soft);
  border-color: var(--primary);
}

.result-divider {
  text-align: center;
  margin: 32px 0 20px;
  position: relative;
}

.result-divider::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--border);
}

.result-divider span {
  font-family: 'Gowun Batang', serif;
  position: relative;
  background: var(--bg-base);
  padding: 0 16px;
  font-size: 14px;
  color: var(--primary-dark);
  font-weight: 700;
}

.vs-card {
  background: linear-gradient(135deg, #fff 0%, #fdf4f1 100%);
}

.special-match {
  border: 2px solid var(--primary);
  background: linear-gradient(135deg, #fbf0f3 0%, #f7e3e8 100%);
}

.special-match h3 {
  margin-bottom: 12px;
}

.special-badge {
  display: inline-block;
  background: var(--primary);
  color: white;
  padding: 6px 14px;
  border-radius: 100px;
  font-family: 'Pretendard', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.05em;
  margin-bottom: 14px;
}

.warning-badge {
  background: #b87555;
}

.bad-match-card {
  border-color: #d4a890;
  background: linear-gradient(135deg, #fdf6ef 0%, #f8e4d4 100%);
}

.why-text, .synergy-text, .warning-text {
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--text-soft);
  margin-bottom: 8px;
}

.synergy-text {
  font-weight: 700;
  color: var(--primary-dark);
  padding-top: 10px;
  border-top: 1px dashed var(--border);
  margin-top: 8px;
}

.warning-text {
  font-weight: 700;
  color: #a8633d;
  padding-top: 10px;
  border-top: 1px dashed var(--border);
  margin-top: 8px;
}

.dim-card {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.dim-card .dim-icon {
  font-size: 16px;
  color: var(--primary);
  margin-top: 2px;
  flex-shrink: 0;
}

.style-compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 24px;
}

.style-col {
  background: var(--primary-soft);
  border-radius: 14px;
  padding: 14px 12px;
}

.style-col-head {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 8px;
}

.style-col-emoji {
  font-size: 22px;
}

.style-col-head strong {
  font-family: 'Gowun Batang', serif;
  font-size: 15px;
  font-weight: 700;
  color: var(--primary-dark);
}

.style-col p {
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--text-soft);
}

.style-row-compare {
  margin-bottom: 18px;
  padding-top: 16px;
  border-top: 1px dashed var(--border);
}

.style-row-compare h5 {
  font-family: 'Pretendard', sans-serif;
  font-size: 13px;
  font-weight: 700;
  color: var(--primary-dark);
  margin-bottom: 10px;
  letter-spacing: -0.01em;
}

.row-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.row-grid > div {
  background: #fbf6f1;
  border-radius: 10px;
  padding: 10px;
  border: 1px solid var(--border);
}

.row-grid strong {
  display: block;
  font-family: 'Pretendard', sans-serif;
  font-size: 11px;
  font-weight: 700;
  color: var(--primary-dark);
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}

.row-grid p {
  font-size: 12px;
  line-height: 1.55;
  color: var(--text-soft);
}

/* === Responsive === */
@media (min-width: 768px) {
  .hero h1 { font-size: 36px; }
  .result-hero h1 { font-size: 36px; }
  .type-grid { grid-template-columns: repeat(4, 1fr); }
  .match-grid { grid-template-columns: 1fr 1fr; }
}
