/* ══════════════════════════════════════════
   히어로 섹션 — 흰 배경 + 좌: 텍스트 / 우: 이미지+카드
   ══════════════════════════════════════════ */
.course-hero {
  position: relative;
  background: #111;
  overflow: hidden;
}
.hero-dark { background: #111; }
.hero-light { background: #111; }

/* 배경 갤러리 슬라이드 */
.course-hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.course-hero-bg--empty {
  background: #1a1a1a;
}
.course-hero-slides {
  position: absolute;
  inset: 0;
  background: #141414;
}
.course-hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.9s ease;
}
.course-hero-slide.is-active { opacity: 1; }
.course-hero-slide-blur,
.course-hero-slide-main {
  position: absolute;
  inset: 0;
  background-repeat: no-repeat;
  background-position: center center;
}
.course-hero-slide-blur {
  background-size: cover;
  filter: blur(40px);
  opacity: 0.35;
  transform: scale(1.12);
}
.course-hero-slide-main {
  background-size: cover;
  background-position: center right;
  z-index: 1;
  opacity: 0.18;
}

/* 왼쪽 → 검정 그라디언트 오버레이 (텍스트 가독성) */
.course-hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: linear-gradient(
    to right,
    rgba(0,0,0,0.88) 0%,
    rgba(0,0,0,0.72) 50%,
    rgba(0,0,0,0.30) 80%,
    rgba(0,0,0,0.10) 100%
  );
}

/* 히어로 내부 레이아웃 */
.course-hero--gallery .course-hero-inner {
  position: relative;
  z-index: 3;
  padding: 56px 0 52px;
}
.course-hero-inner { display: flex; gap: 36px; align-items: flex-start; }

/* 텍스트 영역 (좌측) */
.course-hero-text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
  padding-right: 8px;
}
.course-hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 14px;
}
.course-hero-copy {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.course-hero-copy .ch-meta { margin-top: 16px; }

/* 텍스트 색상: 항상 흰색 */
.course-hero-text h1,
.course-hero--gallery .course-hero-text h1,
.hero-dark .course-hero-text h1,
.hero-light .course-hero-text h1 {
  color: #fff;
}
.course-hero-text,
.course-hero--gallery .course-hero-text,
.hero-dark .course-hero-text,
.hero-light .course-hero-text {
  color: rgba(255,255,255,0.88);
}
.course-hero--gallery .ch-desc,
.hero-dark .ch-desc,
.hero-light .ch-desc { color: rgba(255,255,255,0.78); }
.course-hero--gallery .ch-meta,
.hero-dark .ch-meta,
.hero-light .ch-meta { color: rgba(255,255,255,0.62); }
.ch-badge {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  width: auto;
  max-width: max-content;
  font-size: 12px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 5px;
  margin-bottom: 0;
  letter-spacing: 0.04em;
  line-height: 1.2;
  white-space: nowrap;
}
.course-hero-badges .ch-badge--meet { margin-bottom: 0; }
.ch-badge--new { background: var(--badge-new); color: #fff; }
.ch-badge--best { background: var(--badge-best); color: #fff; }
.ch-badge--free { background: var(--badge-free); color: #fff; }
.ch-badge--offline { background: var(--badge-offline); color: #fff; }
.ch-badge--live { background: #fff; color: #1a1a1a; border: 1px solid rgba(0,0,0,.08); box-shadow: 0 4px 16px rgba(0,0,0,.08); display: inline-flex; align-items: center; gap: 10px; }
.ch-badge--live .meet-google-icon { width: 28px; height: 28px; flex-shrink: 0; }
.ch-badge:not([class*="ch-badge--"]) { background: #fff; color: var(--text-primary); }
/* ── 히어로 타이포그래피 ── */
.course-hero-text h1 {
  font-size: 36px;
  font-weight: 800;
  line-height: 1.28;
  letter-spacing: -0.025em;
  margin-bottom: 14px;
  word-break: keep-all;
}
.ch-desc {
  font-size: 16px;
  line-height: 1.75;
  margin-bottom: 0;
  opacity: 0.85;
  word-break: keep-all;
  line-break: strict;
  overflow-wrap: normal;
}
.ch-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 14px;
}
.ch-meta span { display: flex; align-items: center; gap: 5px; }
.ch-meta strong { color: #f5a623; font-weight: 700; }
.ch-meta .ti-star { color: #f5a623; }

/* 히어로: 카테고리 */
.ch-category {
  font-size: 13px;
  font-weight: 600;
  color: rgba(255,255,255,0.5);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 10px;
}

/* 히어로: 강사 라인 */
.ch-instructor-line {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid rgba(255,255,255,0.12);
}
.ch-instructor-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(255,255,255,0.2);
  flex-shrink: 0;
}
.ch-instructor-avatar--ph {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,255,255,0.1);
  font-size: 16px;
  color: rgba(255,255,255,0.5);
}
.ch-instructor-name {
  font-size: 14px;
  font-weight: 600;
  color: rgba(255,255,255,0.88);
}
.ch-instructor-role {
  font-size: 13px;
  color: rgba(255,255,255,0.45);
}

/* ── 바이 카드 (히어로 우측) ── */
.course-buy-card {
  width: var(--course-sidebar-width, 300px);
  flex-shrink: 0;
  background: #fff;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 8px 40px rgba(0,0,0,.28), 0 2px 8px rgba(0,0,0,.18);
  border: none;
  /* buy-card spacing tokens */
  --buy-gap: 10px;
  --buy-gap-tight: 4px;
  --buy-section: 16px;
}
.course-buy-card.enrollment-closed-panel {
  position: relative;
  overflow: hidden;
}
.course-buy-card.enrollment-closed-panel::before {
  border-radius: 14px;
}
.course-buy-card.enrollment-closed-panel .enrollment-closed-panel__content {
  display: block;
}
/* 바이카드 썸네일 — 더 크게 */
.buy-thumb {
  width: 100% !important;
  aspect-ratio: 16/9 !important;
  min-height: 168px;
}
.buy-thumb .ti { font-size: 40px; color: var(--text-hint); }
.thumb-dark.buy-thumb { background: linear-gradient(135deg,#0f172a 0%,#1e293b 100%); }
.thumb-dark.buy-thumb .ti { color: rgba(255,255,255,0.22); }
.thumb-light.buy-thumb { background: linear-gradient(135deg,#f1f5f9 0%,#e2e8f0 100%); }
.buy-thumb img { width:100%; height:100%; object-fit:cover; display:block; }
.buy-body {
  padding: 18px 20px 20px;
  display: flex;
  flex-direction: column;
  gap: var(--buy-section);
}
.buy-intro,
.buy-pricing {
  display: flex;
  flex-direction: column;
  gap: var(--buy-gap);
}
.buy-body .btn-enroll,
.buy-body .btn-kakao-room,
.buy-body .buy-enroll-status,
.buy-body .buy-live-head,
.buy-body .buy-price,
.buy-body .buy-price-row,
.buy-body .buy-actions,
.buy-body .buy-features,
.buy-body .live-extra-actions {
  margin: 0;
}
.buy-enroll-status {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
}
.buy-actions {
  display: flex;
  flex-direction: column;
  gap: var(--buy-gap);
}
.buy-enroll-status .enroll-gauge {
  flex: 1;
  max-width: none;
  min-width: 0;
}
.buy-price-row { display: flex; align-items: center; gap: 6px; }
.buy-original { font-size: 10.2px; color: var(--text-hint); text-decoration: line-through; }
.buy-disc { font-size: 9.6px; background: var(--bg-muted); color: var(--text-secondary); padding: 2px 5px; border-radius: 4px; }
.buy-price { font-size: 30px; font-weight: 700; color: var(--text-primary); letter-spacing: -0.02em; }
.buy-coupon-note {
  margin: 6px 0 0;
  font-size: 12.5px;
  line-height: 1.45;
  color: var(--text-muted);
}
.buy-coupon-note--disabled { color: #b45309; }
.buy-checkout-schedule {
  margin: 8px 0 0;
  padding: 8px 10px;
  border-radius: 8px;
  background: #f8fafc;
  border: 1px solid var(--border);
  font-size: 12.5px;
  line-height: 1.45;
  color: var(--text-secondary);
  display: flex;
  align-items: flex-start;
  gap: 6px;
}
.buy-checkout-schedule i { font-size: 15px; margin-top: 1px; flex-shrink: 0; }
.buy-checkout-schedule--upcoming { background: #eff6ff; border-color: #bfdbfe; color: #1d4ed8; }
.buy-checkout-schedule--closed { background: #fef2f2; border-color: #fecaca; color: #b91c1c; }
.buy-price--free { font-size: 30px; font-weight: 700; letter-spacing: -0.01em; line-height: 1.25; color: var(--price-free); }
.buy-live-head {
  display: flex;
  flex-direction: column;
  gap: var(--buy-gap-tight);
  text-align: center;
  padding: 0;
}
.buy-live-price { font-size: 30px; font-weight: 700; color: var(--price-free); line-height: 1.2; }
.buy-live-sub { font-size: 14px; color: #888; margin: 0; line-height: 1.4; }
.buy-live-schedule {
  background: var(--bg-muted);
  border-radius: 8px;
  padding: 10px 12px;
  font-size: 14px;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 6px;
  line-height: 1.4;
}
.buy-live-enrolled { text-align: center; font-size: 15px; line-height: 1.45; }
.btn-enroll.enrolled.buy-live-enrolled--ended {
  background: #222;
  color: #fff;
  cursor: default;
}
.btn-enroll.enrolled.buy-live-enrolled--ended:hover { background: #222; }
.buy-live-ended { background: #ccc; cursor: not-allowed; text-align: center; font-size: 15px; }
.btn-enroll--replay {
  background: #111;
  color: #fff;
}
.btn-enroll--replay:hover { background: #333; }
.btn-enroll--replay-pending {
  background: #f5f5f5;
  color: #888;
  border: 1px solid #e8e8e8;
  cursor: default;
  flex-direction: row;
  gap: 6px;
  line-height: 1.3;
}
.btn-enroll--replay-pending:hover { background: #f5f5f5; }
/* 구매카드에서만 2줄 허용 */
.buy-actions .btn-enroll--replay-pending { flex-direction: column; gap: 4px; line-height: 1.35; text-align: center; }
.btn-enroll__sub {
  display: inline;
  font-size: 12px;
  font-weight: 500;
  color: #999;
}
.buy-actions .btn-enroll__sub { display: block; }
.btn-enroll { display: flex; align-items: center; justify-content: center; gap: 5px; width: 100%; padding: 12px 10px; background: var(--text-primary); color: #fff; border: none; border-radius: 10px; font-size: 15px; font-weight: 500; cursor: pointer; text-decoration: none; transition: background 0.2s; box-sizing: border-box; }
.btn-enroll:hover { background: var(--text-secondary); }
.btn-enroll.enrolled { background: var(--success); }
.btn-enroll--underlay { margin-bottom: 0; cursor: default; }
.btn-enroll--underlay:hover { background: var(--text-primary); }
.btn-enroll--secondary {
  background: #fff;
  color: var(--text-primary);
  border: 1.5px solid var(--border);
}
.btn-enroll--secondary:hover { background: var(--bg-muted); }
.btn-enroll--disabled {
  opacity: 0.55;
  cursor: not-allowed;
  pointer-events: none;
}
.btn-enroll--review {
  background: #111;
  color: #fff;
}
.btn-enroll--review:hover { background: #333; }
.buy-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--buy-gap);
  margin: 0;
  padding: var(--buy-gap) 0 0;
  border-top: 1px solid var(--border);
}
.buy-features li { font-size: 14px; color: var(--text-muted); display: flex; align-items: center; gap: 8px; line-height: 1.45; word-break: keep-all; line-break: strict; overflow-wrap: normal; }
.buy-features .feat-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}
.buy-features .feat-icon .ti { font-size: 16px; line-height: 1; }
.buy-features .feat-icon svg { display: block; width: 15px; height: 15px; }
.buy-features .feat-icon--live .ti { color: var(--text-primary); }
.buy-features .feat-icon--chat .ti { color: var(--text-secondary); }
.btn-kakao-room {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 11px 12px;
  background: #FEE500;
  color: #2a1a1a;
  font-size: 15px;
  font-weight: 600;
  border: none;
  border-radius: 10px;
  text-decoration: none;
  transition: background 0.15s;
  margin-bottom: 0;
  box-sizing: border-box;
  line-height: 1.3;
}
.btn-kakao-room:hover { background: #F5DC00; color: #2a1a1a; }
.btn-kakao-room svg { flex-shrink: 0; display: block; }
/* CTA 스택: 래퍼는 레이아웃에 참여하지 않고 gap만 적용 */
.buy-actions .live-extra-actions {
  display: contents;
}
.buy-actions .btn-enroll,
.buy-actions .btn-kakao-room,
.buy-actions .btn-live-extra {
  min-height: 44px;
  padding: 11px 14px;
  border-radius: 10px;
  font-size: 15px;
  line-height: 1.3;
}
.buy-actions .btn-live-extra--replay-pending {
  min-height: 48px;
  padding: 10px 14px;
}
.feat-icon--replay { background: #f0f0f0; color: #111; }
.feat-icon--material { background: #eef6ff; color: #1a73e8; }
.buy-features .feat-icon--lifetime .ti { color: var(--text-secondary); }
.buy-features .feat-icon--mobile .ti { color: var(--text-secondary); }
.buy-features .feat-icon--cert .ti { color: var(--text-secondary); }
.buy-features .feat-icon--refund .ti { color: var(--text-secondary); }

/* ── 배우는 것 섹션 ── */
.outcomes-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px 28px;
  padding: 24px;
  background: #f9fafb;
  border-radius: 14px;
  border: 1px solid #ebebeb;
}
.outcome-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14.5px;
  color: #333;
  line-height: 1.6;
}
.outcome-item .ti {
  font-size: 16px;
  color: #22c55e;
  flex-shrink: 0;
  margin-top: 2px;
}

/* ── 추천 대상 섹션 ── */
.target-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.target-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 15px;
  color: #333;
  line-height: 1.6;
  padding: 14px 16px;
  background: #f9f9f9;
  border-radius: 10px;
}
.target-item .ti {
  font-size: 18px;
  color: #6366f1;
  flex-shrink: 0;
  margin-top: 1px;
}

/* ── 강사 소개 ── */
.instructor-card {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  padding: 24px;
  background: #f9f9f9;
  border-radius: 14px;
}
.instructor-avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 2px solid #eee;
}
.instructor-avatar--placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #e5e7eb;
  font-size: 28px;
  color: #999;
}
.instructor-info { flex: 1; min-width: 0; }
.instructor-name { font-size: 18px; font-weight: 800; color: #111; margin-bottom: 3px; }
.instructor-role { font-size: 13px; color: #888; margin-bottom: 10px; }
.instructor-bio { font-size: 14.5px; color: #444; line-height: 1.8; white-space: pre-wrap; }

/* ── 사이드 통계 ── */
.side-stats-section .course-section { padding-bottom: 0; }
.side-stats {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px 14px;
  background: var(--bg-soft);
  border-radius: 10px;
}
.side-stat-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--text-secondary);
}
.side-stat-item .ti { font-size: 16px; color: var(--text-hint); flex-shrink: 0; }
.side-stat-item strong { color: var(--text-primary); }

/* ── 섹션 간격 (main col) ── */
.course-body-main .course-section {
  margin-bottom: 52px;
  padding-bottom: 52px;
  border-bottom: 1px solid #f0f0f0;
}
.course-body-main .course-section:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}
.course-body-main .course-section h2 {
  border-bottom: none;
  padding-bottom: 0;
  margin-bottom: 24px;
  font-size: 22px;
  font-weight: 800;
  color: #111;
  letter-spacing: -0.02em;
}

/* ── buy card: 환불 보장 배너 ── */
.buy-guarantee {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: #166534;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: 8px;
  padding: 8px 12px;
}
.buy-guarantee .ti { font-size: 15px; flex-shrink: 0; }

.course-body-wrap { background: #fff; }
.course-body-inner-wrap { padding: 48px 0 80px; }
.course-body-inner {
  display: flex;
  gap: 36px;
  align-items: stretch;
}
.course-body-main {
  flex: 1;
  min-width: 0;
}
.course-body-side {
  width: var(--course-sidebar-width, 300px);
  flex-shrink: 0;
}
.course-section { margin-bottom: 0; }
.course-detail-intro {
  margin-bottom: 36px;
  max-width: 1000px;
}
.course-detail-intro__figure {
  margin: 0;
}
.course-detail-intro__figure + .course-detail-intro__figure {
  margin-top: 0;
}
.course-detail-intro__image {
  display: block;
  width: 100%;
  max-width: 1000px;
  height: auto;
  border-radius: 0;
  border: none;
  background: transparent;
}
.course-detail-intro__text {
  font-size: 16px;
  line-height: 1.85;
  color: var(--text-secondary);
  white-space: pre-wrap;
}
.course-section h2 {
  font-size: 31.2px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0 0 18px;
  padding-bottom: 12px;
  border-bottom: 0.5px solid var(--border);
}
.live-curriculum-image {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 12px;
  border: 0.5px solid var(--border);
  background: var(--bg-soft);
}
.live-curriculum-text {
  font-size: 16px;
  line-height: 1.85;
  color: var(--text-secondary);
  white-space: pre-wrap;
  background: var(--bg-soft);
  border-radius: 12px;
  padding: 18px 20px;
}
.curriculum-empty {
  text-align: center;
  padding: 36px 16px;
  color: var(--text-muted);
  font-size: 15px;
  background: var(--bg-soft);
  border-radius: 12px;
}

/* anticipation styles moved below to unified card section */
.anticipation-coupon-note {
  margin-top: 12px;
  padding: 12px 14px;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.6;
}

.anticipation-modal textarea {
  width: 100%;
  min-height: 110px;
  border: 0.5px solid var(--border);
  border-radius: 10px;
  padding: 14px;
  font-size: 15px;
  line-height: 1.65;
  resize: vertical;
  font-family: inherit;
}
.anticipation-modal textarea:focus { outline: none; border-color: var(--primary); }
.anticipation-modal-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 8px;
  font-size: 13px;
  color: var(--text-hint);
}
.anticipation-modal-note {
  font-size: 13.5px;
  color: var(--text-muted);
  line-height: 1.65;
  margin: 12px 0 16px;
}
.btn-anticipation-submit {
  display: block;
  width: 100%;
  padding: 13px;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
}
.btn-anticipation-submit:hover { background: var(--primary-dark); }
.btn-anticipation-submit:disabled { background: #ccc; cursor: not-allowed; }

.curriculum-list { display: flex; flex-direction: column; gap: 8px; }
.curriculum-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  background: #fff;
  border: 1px solid #f0f0f0;
  border-radius: 10px;
  transition: border-color 0.12s, box-shadow 0.12s;
}
.curriculum-item:hover {
  border-color: #d1d5db;
  box-shadow: 0 2px 8px rgba(0,0,0,.06);
}
.ci-num {
  font-size: 12px;
  font-weight: 700;
  color: #bbb;
  width: 26px;
  flex-shrink: 0;
  font-variant-numeric: tabular-nums;
}
.ci-title {
  flex: 1;
  min-width: 0;
  font-size: 15px;
  font-weight: 500;
  color: #333;
  line-height: 1.5;
}
.ci-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-shrink: 0;
}
.ci-free {
  display: inline-flex;
  align-items: center;
  font-size: 13px;
  background: var(--badge-free);
  color: #fff;
  padding: 6px 10px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 600;
  white-space: nowrap;
  line-height: 1.2;
}
.ci-free:hover { background: #7a9263; }
.ci-watch {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  font-size: 18px;
  color: var(--text-muted);
  text-decoration: none;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--border);
}
.ci-watch:hover { color: var(--text-primary); border-color: var(--text-hint); }
.ci-lock {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  font-size: 16px;
  color: var(--border-strong);
}
.ci-time {
  font-size: 13px;
  color: var(--text-hint);
  white-space: nowrap;
  min-width: 2.8em;
  text-align: right;
  line-height: 1.2;
}

/* Modal */
body.modal-open { overflow: hidden; }
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.52);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9000;
  padding: 24px;
  overflow-y: auto;
  overscroll-behavior: contain;
}
.modal-overlay.hidden { display: none !important; }

.gift-reservation-banner {
  background: linear-gradient(90deg, #ff9f43, #ff6b6b);
  color: #fff;
}
.gift-reservation-banner.hidden { display: none !important; }
.gift-reservation-banner-inner {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  padding: 12px 24px;
}
.gift-reservation-icon { font-size: 20px; }
.gift-reservation-text {
  flex: 1;
  min-width: 220px;
  font-size: 14px;
  font-weight: 600;
}
.gift-reservation-cta {
  border: none;
  background: #fff;
  color: #ff6b6b;
  font-weight: 800;
  font-size: 13.5px;
  padding: 9px 16px;
  border-radius: 20px;
  cursor: pointer;
  white-space: nowrap;
}
.gift-reservation-cta:hover { background: #fff5f0; }
.modal {
  background: #fff;
  border-radius: 16px;
  width: min(100%, 440px);
  max-height: min(90vh, 720px);
  overflow: hidden auto;
  margin: auto;
  flex-shrink: 0;
}
.modal-header { display: flex; align-items: center; justify-content: space-between; padding: 20px 22px 16px; border-bottom: 0.5px solid var(--bg-muted); }
.modal-title { font-size: 25.2px; font-weight: 600; color: var(--text-primary); }
.modal-close { background: none; border: none; font-size: 31.2px; color: var(--text-hint); cursor: pointer; padding: 0; }
.modal-course-info { padding: 14px 22px; background: var(--bg-soft); }
.mci-title { font-size: 21.6px; color: var(--text-secondary); font-weight: 500; }
.modal-section-title { font-size: 20.4px; font-weight: 600; color: var(--text-secondary); padding: 16px 22px 8px; }
.pay-options { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 0 22px 16px; }
.pay-option { cursor: pointer; }
.pay-option input { display: none; }
.pay-label { display: flex; align-items: center; gap: 8px; padding: 11px 14px; border: 0.5px solid var(--border); border-radius: 8px; font-size: 21.6px; color: var(--text-secondary); transition: all 0.15s; }
.pay-option input:checked + .pay-label { border-color: var(--text-primary); background: var(--bg-soft); color: var(--text-primary); font-weight: 500; }
.pay-label .ti { font-size: 27.6px; }
.modal-total { padding: 14px 22px; border-top: 0.5px solid var(--bg-muted); font-size: 21.6px; color: var(--text-muted); text-align: right; }
.modal-total b { font-size: 31.2px; color: var(--text-primary); margin-left: 8px; }
.btn-pay { display: block; width: calc(100% - 44px); margin: 0 22px 12px; padding: 14px; background: var(--text-primary); color: #fff; border: none; border-radius: 8px; font-size: 25.2px; font-weight: 500; cursor: pointer; transition: background 0.2s; }
.btn-pay:hover { background: var(--text-secondary); }
.btn-pay:disabled { background: var(--border-strong); cursor: not-allowed; }
.modal-notice { text-align: center; font-size: 19.2px; color: var(--text-hint); padding: 0 22px 18px; }
.modal-withdrawal-notice { display: flex; gap: 8px; align-items: flex-start; margin: 0 22px 14px; padding: 10px 14px; background: #fff8e1; border: 1px solid #ffe082; border-radius: 6px; font-size: 13px; line-height: 1.5; color: #5d4037; }
.modal-withdrawal-notice i { color: #f9a825; flex-shrink: 0; margin-top: 1px; }
.modal-withdrawal-notice a { color: #5d4037; text-decoration: underline; }

@media (max-width: 900px) {
  .course-hero-inner { flex-direction: column; align-items: stretch; }
  .course-hero-text { min-height: 0; }
  .course-hero-copy { justify-content: flex-start; flex: none; }
  .course-buy-card { width: 100% !important; }
  .course-body-inner { flex-direction: column; gap: 40px; }
  .course-body-side { width: 100%; }
  .anticipation-feed { max-height: none; }
}

/* ── 결제 모달 개선 ── */
.modal-beta-banner {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 12px 18px;
  background: #fff8e1;
  border-bottom: 1px solid #ffe082;
  font-size: 13px; color: #5d4037; line-height: 1.55;
  border-radius: 12px 12px 0 0;
}
.modal-beta-banner i { font-size: 16px; color: #f9a825; flex-shrink: 0; margin-top: 2px; }
.modal-coupon-info { padding: 0 22px; }
.modal-coupon-applied {
  display: flex; align-items: center; gap: 7px;
  padding: 10px 14px; margin-bottom: 4px;
  background: #f0fdf4; border: 1px solid #bbf7d0; border-radius: 8px;
  font-size: 14px; color: #166534;
}
.modal-coupon-applied i { font-size: 16px; }
.modal-coupon-skipped {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  margin-top: 8px;
  border-radius: 10px;
  background: #f8fafc;
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.45;
}
.modal-coupon-discount { margin-left: auto; font-weight: 700; color: #15803d; }

.store-checkout-modal { width: min(100%, 440px); }

@media (min-width: 901px) {
  .modal { width: min(100%, 480px); }
  .store-checkout-modal { width: min(100%, 480px); }
}

.store-checkout-course {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0 22px 16px;
  padding: 14px 16px;
  border-radius: 12px;
  background: var(--bg-soft, #f7f7f7);
  border: 1px solid var(--border);
}
.store-checkout-course__title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.4;
}
.store-checkout-course__price {
  font-size: 16px;
  font-weight: 800;
  color: var(--text-primary);
  white-space: nowrap;
}

.store-coupon-status { margin: 0 22px 14px; }
.store-coupon-status__spin,
.store-coupon-status__row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 11px 14px;
  border-radius: 10px;
  font-size: 13.5px;
  line-height: 1.45;
}
.store-coupon-status__spin {
  background: var(--bg-soft, #f7f7f7);
  color: var(--text-muted);
}
.spinner--sm {
  width: 14px;
  height: 14px;
  border-width: 2px;
  margin: 0;
  display: inline-block;
}
.store-coupon-status__row--ok {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  color: #166534;
}
.store-coupon-status__row--ok i { font-size: 17px; color: #16a34a; }
.store-coupon-status__row--none {
  background: var(--bg-soft, #f7f7f7);
  border: 1px solid var(--border);
  color: var(--text-muted);
}
.store-coupon-status__row--warn {
  background: #fffbeb;
  border: 1px solid #fde68a;
  color: #92400e;
}
.store-coupon-status__badge {
  margin-left: auto;
  padding: 3px 9px;
  border-radius: 999px;
  background: #16a34a;
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.01em;
}

.store-checkout-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 0 22px;
}
.store-option {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 16px;
  border-radius: 14px;
  border: 1.5px solid var(--border);
  background: #fff;
  cursor: pointer;
  text-align: left;
  transition: border-color .15s, box-shadow .15s, transform .15s;
}
.store-option:hover {
  border-color: var(--primary);
  box-shadow: 0 6px 20px rgba(17, 17, 17, 0.08);
  transform: translateY(-1px);
}
.store-option:active { transform: translateY(0); }
.store-option__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: var(--primary);
  color: #fff;
  font-size: 20px;
  flex-shrink: 0;
}
.store-option--muted .store-option__icon {
  background: var(--bg-soft, #f2f2f2);
  color: var(--text-secondary);
  border: 1px solid var(--border);
}
.store-option__body {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
  flex: 1;
}
.store-option__title {
  font-size: 15px;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.01em;
}
.store-option__desc {
  font-size: 12.5px;
  color: var(--text-muted);
  line-height: 1.45;
}
.store-option__desc strong { color: #16a34a; font-weight: 800; }
.store-option__arrow {
  color: var(--text-hint);
  font-size: 18px;
  flex-shrink: 0;
}
.store-option--disabled { opacity: 0.55; }
.store-option--disabled:hover {
  border-color: var(--border);
  box-shadow: none;
  transform: none;
}

.store-checkout-foot {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 16px 22px 22px;
  font-size: 12px;
  color: var(--text-hint);
}
.store-checkout-foot i { font-size: 14px; }

#store-checkout-step-choice.hidden,
#store-checkout-step-result.hidden {
  display: none !important;
}
#store-checkout-step-result {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 0 22px 22px;
}
.store-checkout-result {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 22px 16px;
  border-radius: 14px;
  background: var(--bg-soft, #f7f7f7);
  border: 1px solid var(--border);
  text-align: center;
}
.store-result__badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--border);
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text-secondary);
}
.store-result__badge--ok {
  background: #f0fdf4;
  border-color: #bbf7d0;
  color: #166534;
}
.store-result__badge--ok i { color: #16a34a; }
.store-result__price {
  display: flex;
  align-items: baseline;
  gap: 8px;
}
.store-result__before {
  font-size: 15px;
  color: var(--text-hint);
  text-decoration: line-through;
}
.store-result__after {
  font-size: 26px;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}
.store-result__pct {
  padding: 3px 8px;
  border-radius: 8px;
  background: #16a34a;
  color: #fff;
  font-size: 12.5px;
  font-weight: 800;
}
.store-result__note {
  margin: 0;
  font-size: 12.5px;
  color: var(--text-muted);
  line-height: 1.5;
}
.btn-store-go {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 15px 16px;
  border-radius: 12px;
  border: none;
  background: #03c75a;
  color: #fff;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
  transition: background .15s, transform .15s;
}
.btn-store-go:hover { background: #02b351; transform: translateY(-1px); }
.btn-store-go:active { transform: translateY(0); }
.btn-store-back {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  padding: 12px 16px;
  border-radius: 12px;
  border: 1.5px solid var(--border);
  background: #fff;
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
}
.btn-store-back:hover { border-color: var(--text-hint); }

/* ── 기대평 순서 안내 ── */
.anticipation-flow-hint {
  font-size: 12px; color: var(--text-hint);
  text-align: center; margin-top: 6px;
  display: flex; align-items: center; justify-content: center; gap: 4px;
}
.anticipation-flow-hint i { font-size: 10px; }

/* ── 탭 네비게이션 ── */
.course-tab-nav {
  position: sticky;
  top: 60px;
  z-index: 50;
  background: #fff;
  border-bottom: 2px solid #f0f0f0;
  box-shadow: 0 2px 8px rgba(0,0,0,.06);
}
.course-tab-nav-inner {
  display: flex;
  gap: 0;
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x proximity;
}
.course-tab-nav-inner::-webkit-scrollbar { display: none; }
.tab-btn {
  flex-shrink: 0;
  scroll-snap-align: start;
  background: none;
  border: none;
  border-bottom: 3px solid transparent;
  margin-bottom: -2px;
  padding: 16px 22px;
  font-size: 15px;
  font-weight: 500;
  color: #888;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: color 0.15s, border-color 0.15s;
  white-space: nowrap;
  letter-spacing: -0.01em;
}
.tab-btn:hover { color: #444; }
.tab-btn.is-active {
  color: #111;
  border-bottom-color: #111;
  font-weight: 700;
}
.tab-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  background: #f0f0f0;
  color: #666;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}
.tab-btn.is-active .tab-count { background: var(--text-primary); color: #fff; }

/* ── 탭 패널 ── */
.tab-panel { display: none; }
.tab-panel.is-active { display: block; }

/* ── body 레이아웃 조정 (하단 중복 규칙 — 위의 규칙이 우선) ── */

/* ── 섹션 소제목 ── */
.section-subtitle {
  font-size: 13px;
  font-weight: 400;
  color: var(--primary, #5b7e5f);
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: 999px;
  padding: 2px 10px;
  margin-left: 8px;
  vertical-align: middle;
  white-space: nowrap;
}

/* ── 별점 분포 ── */
.rating-breakdown {
  display: flex;
  gap: 32px;
  align-items: center;
  padding: 24px 28px;
  background: var(--bg-soft);
  border-radius: 16px;
  margin-bottom: 24px;
}
.rb-summary {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  min-width: 100px;
}
.rb-avg {
  font-size: 52px;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1;
  letter-spacing: -0.03em;
}
.rb-stars { display: flex; gap: 2px; }
.rb-total { font-size: 13px; color: var(--text-hint); margin-top: 2px; }
.rb-bars { flex: 1; display: flex; flex-direction: column; gap: 7px; }
.rb-row { display: flex; align-items: center; gap: 10px; }
.rb-label { font-size: 13px; color: var(--text-hint); width: 26px; text-align: right; flex-shrink: 0; }
.rb-bar { flex: 1; height: 8px; background: var(--border); border-radius: 999px; overflow: hidden; }
.rb-fill { height: 100%; background: #f59e0b; border-radius: 999px; transition: width 0.4s; }
.rb-cnt { font-size: 13px; color: var(--text-hint); width: 20px; flex-shrink: 0; }

/* ── 공통 피드 카드 ── */
.reviews-list,
.anticipation-feed { display: flex; flex-direction: column; gap: 14px; }

.review-card,
.anticipation-card {
  background: #fff;
  border: 1px solid #ebebeb;
  border-radius: 14px;
  padding: 22px 24px;
  transition: box-shadow 0.12s;
}
.review-card:hover,
.anticipation-card:hover {
  box-shadow: 0 4px 16px rgba(0,0,0,.07);
}

/* 카드 헤더 공통: 왼쪽 작성자 정보 / 오른쪽 메타(별점·버튼) */
.review-card-head,
.anticipation-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

/* 왼쪽: 이름 + 날짜 */
.review-card-author,
.anticipation-card-author {
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.review-author,
.anticipation-card-id {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
}
.review-date,
.anticipation-card-date {
  font-size: 12px;
  color: var(--text-hint);
}

/* 오른쪽: 별점 (수강후기) */
.review-stars-row { display: flex; gap: 2px; flex-shrink: 0; }

/* 오른쪽: 수정/삭제 버튼 (기대평) */
.anticipation-card-actions {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}
.anticipation-card-edit {
  padding: 5px 12px;
  font-size: 13px;
  font-weight: 500;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--text-secondary);
  cursor: pointer;
  transition: background 0.12s, color 0.12s;
}
.anticipation-card-edit:hover { background: var(--bg-soft); }
.anticipation-card-edit--danger { color: #dc2626; border-color: #fecaca; }
.anticipation-card-edit--danger:hover { background: #fff5f5; }

/* 본문 */
.review-content,
.anticipation-card-content {
  font-size: 15px;
  line-height: 1.75;
  color: var(--text-secondary);
  word-break: keep-all;
  line-break: strict;
  overflow-wrap: normal;
  white-space: pre-wrap;
  margin: 0;
}

/* 내 기대평 강조 */
.anticipation-card--mine {
  border-color: var(--primary, #2563eb);
  background: #f8faff;
}
.anticipation-card-mine-label {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  background: var(--primary, #2563eb);
  color: #fff;
  border-radius: 4px;
  padding: 1px 6px;
  margin-left: 6px;
  vertical-align: middle;
}

.anticipation-edit-locked {
  margin-top: 10px;
  font-size: 13px;
  color: var(--text-hint);
  padding: 8px 12px;
  background: var(--bg-soft);
  border-radius: 8px;
}

.reviews-empty,
.anticipation-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 48px 20px;
  color: var(--text-hint);
  text-align: center;
  background: var(--bg-soft);
  border-radius: 12px;
}
.reviews-empty .ti { font-size: 36px; color: var(--border-strong); }
.reviews-empty p, .anticipation-empty { font-size: 15px; line-height: 1.65; margin: 0; }

/* ── 기대평 작성 바 ── */
.anticipation-write-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}
.btn-write-anticipation {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 18px;
  background: var(--text-primary);
  color: #fff;
  border: none;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
}
.btn-write-anticipation:hover { background: var(--text-secondary); }
.btn-write-anticipation--edit { background: #fff; color: var(--text-primary); border: 1.5px solid var(--border); }
.btn-write-anticipation--edit:hover { background: var(--bg-muted); }
.anticipation-coupon-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 13px;
  color: #166534;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: 999px;
  padding: 5px 12px;
  font-weight: 500;
}

/* ── 다시보기 전 후기 모달 ── */
.review-before-replay-modal,
.review-thanks-modal { max-width: 420px; }

.rbr-body, .rbt-body { padding: 0 24px 24px; }

.rbr-desc {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin: 0 0 20px;
}

.rbr-stars {
  display: flex;
  gap: 6px;
  margin-bottom: 16px;
}
.rbr-star {
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  font-size: 30px;
  line-height: 1;
  transition: transform 0.1s;
}
.rbr-star:hover { transform: scale(1.15); }

.rbr-body textarea {
  width: 100%;
  min-height: 100px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 14px;
  line-height: 1.65;
  resize: vertical;
  box-sizing: border-box;
  font-family: inherit;
  color: var(--text-primary);
}
.rbr-body textarea:focus { outline: none; border-color: var(--primary, #2563eb); }

.rbr-actions {
  display: flex;
  gap: 8px;
  margin-top: 16px;
}
.rbr-btn-skip {
  flex: 0 0 auto;
  padding: 12px 16px;
  background: none;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 14px;
  color: var(--text-hint);
  cursor: pointer;
  transition: background 0.12s;
}
.rbr-btn-skip:hover { background: var(--bg-soft); }
.rbr-btn-submit {
  flex: 1;
  padding: 12px 16px;
  background: var(--text-primary);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.12s;
}
.rbr-btn-submit:hover { opacity: 0.85; }
.rbr-btn-submit:disabled { opacity: 0.5; cursor: not-allowed; }

/* ── 후기 완료 모달 ── */
.rbt-coupon {
  display: flex;
  align-items: center;
  gap: 14px;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: 12px;
  padding: 16px 18px;
  margin-bottom: 14px;
}
.rbt-coupon .ti { font-size: 28px; color: #16a34a; flex-shrink: 0; }
.rbt-coupon-title { font-size: 15px; font-weight: 700; color: #15803d; }
.rbt-coupon-desc { font-size: 13px; color: #166534; margin-top: 2px; }

.rbt-btn-material {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 12px;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  margin-bottom: 14px;
  transition: background 0.12s;
}
.rbt-btn-material:hover { background: var(--border); }

.rbt-btn-replay {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 14px;
  background: var(--text-primary);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: opacity 0.12s;
}
.rbt-btn-replay:hover { opacity: 0.85; }

/* ── 사이드 sticky ── */
.course-side-sticky { position: sticky; top: 116px; }
/* 바이카드 shadow — 히어로에선 없고 사이드바에서만 */
.course-side-sticky .course-buy-card { box-shadow: 0 4px 24px rgba(0,0,0,.10); }
.course-buy-card--side {
  position: static !important;
  width: 100% !important;
  max-width: 100% !important;
  box-shadow: 0 2px 12px rgba(0,0,0,.10);
  border-radius: 12px;
  overflow: hidden;
}
.course-buy-card--side .buy-thumb { display: none; }

/* ── 반응형 ── */
@media (max-width: 900px) {
  .rating-breakdown { flex-direction: column; gap: 20px; align-items: flex-start; padding: 20px; }
  .rb-summary { flex-direction: row; align-items: center; gap: 14px; }
  .rb-avg { font-size: 40px; }
  .tab-btn { padding: 12px 14px; font-size: 14px; }
  .anticipation-write-bar { flex-direction: column; align-items: flex-start; }
  /* 구매 카드 패딩·여백 축소 */
  .course-buy-card { --buy-section: 14px; }
  .outcomes-grid { padding: 20px; gap: 12px 20px; }
}

@media (max-width: 600px) {
  /* 탭 버튼 추가 축소 */
  .tab-btn { padding: 11px 14px; font-size: 13.5px; }
  /* 배우는 것 1열 */
  .outcomes-grid { grid-template-columns: 1fr; padding: 16px; }
  /* 후기 1열 + 카드 패딩 축소 */
  .reviews-list,
  .anticipation-feed { gap: 10px; }
  .review-card,
  .anticipation-card { padding: 16px 16px; }
  /* 결제 옵션 1열 */
  .pay-options { grid-template-columns: 1fr; }
  /* 구매 카드 패딩 축소 */
  .course-buy-card { --buy-section: 12px; --buy-gap: 8px; }
}
