/* ============================================================
   성장 기능 공용 스타일 — growth-features.css
   (합격 예측 · 오타 히트맵 · 주간 리그 · 약어 암기카드)
   기존 sd-* / 카드 톤과 통일
   ============================================================ */

.gf-grid { display: grid; gap: 16px; }
.gf-grid.cols-2 { grid-template-columns: 1fr 1fr; }
.gf-grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 900px) { .gf-grid.cols-2, .gf-grid.cols-3 { grid-template-columns: 1fr; } }

.gf-card {
  background: #fff; border: 1px solid #e5e8e6; border-radius: 16px;
  padding: 20px 22px; box-shadow: 0 2px 10px rgba(20, 40, 30, .04);
}
.gf-card h3 { margin: 0 0 6px; font-size: 1.05rem; }
.gf-card .gf-sub { color: #6b7570; font-size: .86rem; margin: 0 0 14px; }

/* 큰 숫자 카드 */
.gf-hero { text-align: center; padding: 28px 22px; }
.gf-hero .gf-hero-num { font-size: 2.6rem; font-weight: 800; letter-spacing: -1px; line-height: 1.1; }
.gf-hero .gf-hero-label { color: #6b7570; font-size: .9rem; margin-top: 6px; }
.gf-hero.good .gf-hero-num { color: #16794c; }
.gf-hero.warn .gf-hero-num { color: #b45309; }
.gf-hero.bad .gf-hero-num { color: #b91c1c; }

/* 작은 통계 행 */
.gf-stats { display: flex; flex-wrap: wrap; gap: 10px 22px; margin-top: 8px; }
.gf-stat { min-width: 90px; }
.gf-stat .num { display: block; font-size: 1.3rem; font-weight: 700; }
.gf-stat .lbl { display: block; font-size: .78rem; color: #6b7570; margin-top: 2px; }

/* 칩 선택 */
.gf-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.gf-chip {
  border: 1px solid #d5dcd8; background: #f6f8f7; color: #2c3530;
  border-radius: 999px; padding: 8px 16px; font-size: .9rem; cursor: pointer;
  font-family: inherit; transition: all .15s;
}
.gf-chip:hover { border-color: #16794c; }
.gf-chip.active { background: #16794c; border-color: #16794c; color: #fff; font-weight: 600; }

/* 차트 */
.gf-chart-wrap { width: 100%; overflow-x: auto; }
.gf-chart-wrap svg { display: block; width: 100%; height: auto; }

/* 안내/경고 배너 */
.gf-note {
  background: #f2f7f4; border: 1px solid #cfe5d8; color: #1f5138;
  border-radius: 12px; padding: 12px 16px; font-size: .88rem; line-height: 1.55;
}
.gf-note.warn { background: #fdf6ec; border-color: #f0dcbe; color: #7a4b12; }
.gf-note.info { background: #f0f4fb; border-color: #d3ddf0; color: #2b4574; }

/* ── 히트맵 ─────────────────────────────────────── */
.gf-keyboard-host svg { width: 100%; height: auto; max-width: 980px; margin: 0 auto; display: block; }
.gf-heat-legend { display: flex; align-items: center; gap: 8px; font-size: .8rem; color: #6b7570; margin-top: 10px; justify-content: center; }
.gf-heat-legend .bar {
  width: 160px; height: 10px; border-radius: 6px;
  background: linear-gradient(90deg, #e8f3ec, #ffe08a, #f97316, #dc2626);
}
.gf-weak-list { display: grid; gap: 8px; }
.gf-weak-item {
  display: flex; align-items: center; gap: 12px;
  border: 1px solid #eef1ef; border-radius: 12px; padding: 10px 14px;
}
.gf-weak-item .jamo { font-size: 1.4rem; font-weight: 800; width: 44px; text-align: center; }
.gf-weak-item .pos {
  font-size: .72rem; padding: 3px 8px; border-radius: 999px; white-space: nowrap;
  background: #eef4f0; color: #2f5c45;
}
.gf-weak-item .pos.mid { background: #eff3fb; color: #33508a; }
.gf-weak-item .pos.end { background: #fbf1ef; color: #8a4433; }
.gf-weak-item .meter { flex: 1; height: 8px; background: #f0f2f1; border-radius: 6px; overflow: hidden; }
.gf-weak-item .meter i { display: block; height: 100%; background: linear-gradient(90deg, #f59e0b, #dc2626); border-radius: 6px; }
.gf-weak-item .rate { font-size: .85rem; font-weight: 700; width: 74px; text-align: right; }

/* 미니 드릴 */
.gf-drill-target { text-align: center; font-size: 2rem; font-weight: 800; padding: 26px 10px 8px; letter-spacing: 1px; }
.gf-drill-feedback { text-align: center; min-height: 24px; font-size: .9rem; }
.gf-drill-feedback.ok { color: #16794c; }
.gf-drill-feedback.bad { color: #b91c1c; }
.gf-drill-input {
  display: block; width: min(420px, 100%); margin: 12px auto 4px;
  font-size: 1.2rem; padding: 12px 16px; text-align: center;
  border: 2px solid #d5dcd8; border-radius: 12px; font-family: inherit;
}
.gf-drill-input:focus { outline: none; border-color: #16794c; }

/* ── 리그 ─────────────────────────────────────── */
.gf-league-table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.gf-league-table th { text-align: left; color: #6b7570; font-weight: 600; font-size: .78rem; padding: 8px 10px; border-bottom: 1px solid #eef1ef; }
.gf-league-table td { padding: 10px; border-bottom: 1px solid #f4f6f5; }
.gf-league-table tr.me td { background: #f0faf4; font-weight: 700; }
.gf-league-table .rank { width: 52px; font-weight: 800; }
.gf-league-table .rank.r1 { color: #d97706; } .gf-league-table .rank.r2 { color: #64748b; } .gf-league-table .rank.r3 { color: #b45309; }

.gf-streak-flame { font-size: 3rem; line-height: 1; }
.gf-dots { display: grid; grid-template-columns: repeat(14, 1fr); gap: 6px; margin-top: 14px; }
.gf-dot { aspect-ratio: 1; border-radius: 6px; background: #eef1ef; }
.gf-dot.on { background: #22a06b; }
.gf-dot.today { outline: 2px solid #16794c; outline-offset: 1px; }

.gf-badges { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.gf-badge {
  border: 1px solid #eef1ef; border-radius: 14px; padding: 14px 12px; text-align: center;
}
.gf-badge .ico { font-size: 1.8rem; }
.gf-badge .nm { font-weight: 700; font-size: .86rem; margin-top: 6px; }
.gf-badge .ds { color: #6b7570; font-size: .74rem; margin-top: 3px; line-height: 1.4; }
.gf-badge.locked { opacity: .38; filter: grayscale(1); }

/* ── 플래시카드 ─────────────────────────────────── */
.gf-flashcard {
  max-width: 560px; margin: 0 auto; min-height: 300px; display: flex; flex-direction: column;
  justify-content: center; align-items: center; gap: 14px; text-align: center;
  border: 1px solid #e5e8e6; border-radius: 20px; background: #fff; padding: 30px 22px;
  box-shadow: 0 4px 18px rgba(20, 40, 30, .06);
}
.gf-fc-front { font-size: 2rem; font-weight: 800; letter-spacing: .5px; }
.gf-fc-code { font-size: 1.5rem; font-weight: 800; letter-spacing: 4px; color: #16794c; }
.gf-fc-hint { color: #6b7570; font-size: .85rem; }
.gf-fc-keyboard svg { width: 100%; max-width: 460px; height: auto; }
.gf-fc-actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; margin-top: 8px; }
.gf-fc-btn {
  font-family: inherit; font-size: .95rem; font-weight: 700; cursor: pointer;
  border-radius: 12px; padding: 12px 20px; border: 1px solid #d5dcd8; background: #fff;
  transition: transform .1s;
}
.gf-fc-btn:hover { transform: translateY(-1px); }
.gf-fc-btn.show { background: #16794c; border-color: #16794c; color: #fff; min-width: 200px; }
.gf-fc-btn.again { background: #fdf0ef; border-color: #f2c8c4; color: #b91c1c; }
.gf-fc-btn.hard { background: #fdf6ec; border-color: #f0dcbe; color: #b45309; }
.gf-fc-btn.good { background: #f0faf4; border-color: #bfe3cf; color: #16794c; }
.gf-fc-btn.easy { background: #eef6ff; border-color: #c4dcf5; color: #1d4ed8; }
.gf-fc-btn small { display: block; font-weight: 500; font-size: .7rem; opacity: .75; margin-top: 2px; }

.gf-fc-progress { max-width: 560px; margin: 0 auto 14px; display: flex; justify-content: space-between; font-size: .84rem; color: #6b7570; }

.gf-actions-row { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 14px; }
.gf-btn-primary {
  font-family: inherit; background: #16794c; color: #fff; border: none; cursor: pointer;
  border-radius: 12px; padding: 12px 22px; font-size: .95rem; font-weight: 700;
}
.gf-btn-primary:disabled { opacity: .5; cursor: default; }
.gf-btn-ghost {
  font-family: inherit; background: #fff; color: #2c3530; border: 1px solid #d5dcd8; cursor: pointer;
  border-radius: 12px; padding: 12px 22px; font-size: .95rem; font-weight: 600;
}

.gf-empty { text-align: center; color: #6b7570; padding: 40px 10px; font-size: .92rem; line-height: 1.6; }
.gf-loading { text-align: center; color: #6b7570; padding: 30px 10px; }
