/* ============================================
   PRODUCT 상세페이지 스타일
   ============================================ */

/* 섹션 공통 */
.section { max-width: var(--max-width); margin: 0 auto; padding: 4rem var(--gutter); }
.sec-index { font-family: var(--font-mono); font-size: 0.78rem; font-weight: 700; letter-spacing: 0.15em; color: var(--color-accent); margin-bottom: 0.4rem; }
.pd-h2 { font-size: clamp(1.5rem, 3vw, 2rem); letter-spacing: -0.02em; margin-bottom: 1.5rem; }

/* ── 상단: 갤러리 + 구매 ───────────────── */
.pd-top { max-width: var(--max-width); margin: 0 auto; padding: 3rem var(--gutter); }
.pd-top-inner { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: start; }
.pd-main-img { aspect-ratio: 1; border-radius: 20px; background: linear-gradient(135deg, #eef1f8, #dfe3ec); margin-bottom: 1rem; }
.pd-thumbs { display: flex; gap: 0.75rem; }
.pd-thumb { width: 72px; height: 72px; border-radius: 12px; border: 2px solid transparent; background: linear-gradient(135deg, #eef1f8, #dfe3ec); cursor: pointer; transition: border-color 0.2s; }
.pd-thumb.active { border-color: var(--color-accent); }

.pd-badge { display: inline-block; background: rgba(32,50,255,0.08); color: var(--color-accent); font-family: var(--font-mono); font-size: 0.72rem; font-weight: 700; padding: 0.35rem 0.85rem; border-radius: 100px; margin-bottom: 1rem; }
.pd-name { font-size: clamp(1.8rem, 4vw, 2.6rem); letter-spacing: -0.02em; margin-bottom: 0.5rem; }
.pd-tagline { color: var(--color-muted); font-size: 1.05rem; line-height: 1.6; margin-bottom: 2rem; }

.pd-options { display: flex; flex-direction: column; gap: 1.25rem; margin-bottom: 1.5rem; }
.pd-opt-label { display: block; font-family: var(--font-mono); font-size: 0.75rem; font-weight: 700; color: var(--color-muted); letter-spacing: 0.08em; text-transform: uppercase; margin-bottom: 0.5rem; }
.pd-opt-btns { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.pd-opt-btn { padding: 0.55rem 1.1rem; border: 1px solid #d8dce6; border-radius: 10px; background: #fff; color: var(--color-text); font-weight: 600; font-size: 0.9rem; cursor: pointer; transition: all 0.2s; }
.pd-opt-btn:hover { border-color: var(--color-accent); color: var(--color-accent); }
.pd-opt-btn.selected { background: var(--color-accent); border-color: var(--color-accent); color: #fff; }
.pd-opt-color { display: inline-flex; align-items: center; gap: 0.5rem; }
.pd-chip { width: 14px; height: 14px; border-radius: 50%; border: 1px solid rgba(0,0,0,0.15); display: inline-block; flex-shrink: 0; }

.pd-qty { margin-bottom: 2rem; }
.pd-qty-ctrl { display: inline-flex; align-items: center; border: 1px solid #d8dce6; border-radius: 10px; overflow: hidden; }
.pd-qty-btn { width: 44px; height: 44px; border: none; background: #fff; font-size: 1.3rem; cursor: pointer; color: var(--color-text); transition: background 0.2s; }
.pd-qty-btn:hover { background: var(--color-surface); }
.pd-qty-num { width: 56px; text-align: center; font-weight: 700; font-family: var(--font-mono); }

.pd-add-btn { width: 100%; padding: 1.1rem; background: var(--color-accent); color: #fff; border: none; border-radius: 12px; font-weight: 700; font-size: 1rem; cursor: pointer; transition: all 0.2s; margin-bottom: 0.75rem; }
.pd-add-btn:hover { background: var(--color-accent-dark); transform: translateY(-2px); }
.pd-add-btn.added { background: #16a34a; }
.pd-inquiry-link { display: block; text-align: center; color: var(--color-muted); font-weight: 600; font-size: 0.9rem; }
.pd-inquiry-link:hover { color: var(--color-accent); }

/* ── 탭 ──────────────────────────────── */
.pd-tabs { position: sticky; top: 64px; z-index: 40; background: rgba(255,255,255,0.9); backdrop-filter: blur(12px); border-bottom: 1px solid #e8ebf2; }
.pd-tabs-inner { max-width: var(--max-width); margin: 0 auto; padding: 0 var(--gutter); display: flex; gap: 0.5rem; }
.pd-tab { padding: 1.1rem 1.5rem; border: none; background: none; font-weight: 700; font-size: 0.95rem; color: var(--color-muted); cursor: pointer; border-bottom: 2px solid transparent; transition: all 0.2s; }
.pd-tab:hover { color: var(--color-accent); }
.pd-tab.active { color: var(--color-accent); border-bottom-color: var(--color-accent); }
.pd-panel { display: none; }
.pd-panel.active { display: block; }

/* 상품정보 탭 내부 그룹 간격 통일 */
.pd-panel[data-panel="info"] > .pd-howto,
.pd-panel[data-panel="info"] > .pd-programs,
.pd-panel[data-panel="info"] > .pd-usecase,
.pd-panel[data-panel="info"] > .pd-transmitter,
.pd-panel[data-panel="info"] > .pd-gallery-strip,
.pd-panel[data-panel="info"] > .pd-concept { margin-top: 4.5rem; }

/* ── 특징 4박스 ──────────────────────── */
.pd-feat-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.25rem; }
.pd-feat-card { position: relative; border: 1px solid #e8ebf2; border-radius: 16px; padding: 1.75rem; background: rgba(255,255,255,0.6); }
.pd-feat-icon { width: 44px; height: 44px; border-radius: 12px; background: linear-gradient(135deg, #dfe5ff, #c2ccff); margin-bottom: 1rem; }
.pd-feat-card h3 { font-size: 1.1rem; margin-bottom: 0.5rem; }
.pd-feat-card p { color: var(--color-muted); font-size: 0.9rem; line-height: 1.6; }
.pd-feat-card.highlight { background: linear-gradient(135deg, #2032ff, #4258ff); border-color: transparent; color: #fff; box-shadow: 0 16px 40px rgba(32,50,255,0.3); transform: scale(1.03); }
.pd-feat-card.highlight h3, .pd-feat-card.highlight p { color: #fff; }
.pd-feat-card.highlight .pd-feat-icon { background: rgba(255,255,255,0.25); }
.pd-feat-badge { position: absolute; top: 1rem; right: 1rem; font-family: var(--font-mono); font-size: 0.62rem; font-weight: 800; letter-spacing: 0.1em; background: rgba(255,255,255,0.9); color: var(--color-accent); padding: 0.25rem 0.6rem; border-radius: 100px; }

/* ── 작동방식 쇼케이스 (지그재그 + 슬라이드인) ── */
.pd-feat-showcase { display: flex; flex-direction: column; gap: 5rem; }
.pd-feat-item { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center; opacity: 0; transform: translateX(-40px); transition: opacity 0.7s ease, transform 0.7s ease; }
.pd-feat-item[data-reveal="right"] { transform: translateX(40px); }
.pd-feat-item[data-reveal="right"] .pd-feat-body { order: -1; }
.pd-feat-item.revealed { opacity: 1; transform: translateX(0); }
.pd-feat-visual { position: relative; }
.pd-feat-img { aspect-ratio: 4/3; border-radius: 20px; background: linear-gradient(135deg, #eef1f8, #dfe3ec); position: relative; overflow: hidden; }
.pd-feat-img::after { content: ''; position: absolute; inset: 0; background: linear-gradient(120deg, transparent 30%, rgba(255,255,255,0.5) 50%, transparent 70%); transform: translateX(-100%); animation: pdShine 3.5s ease-in-out infinite; }
@keyframes pdShine { 0%, 100% { transform: translateX(-100%); } 50% { transform: translateX(100%); } }
.pd-feat-num { position: absolute; top: -18px; left: -10px; font-family: var(--font-mono); font-size: 3.5rem; font-weight: 800; color: var(--color-accent); opacity: 0.12; line-height: 1; }
.pd-feat-body h3 { font-size: clamp(1.4rem, 3vw, 2rem); letter-spacing: -0.02em; margin-bottom: 1rem; }
.pd-feat-body p { color: var(--color-muted); font-size: 1.05rem; line-height: 1.8; }

/* ── 강점 태그 ──────────────────────── */
.pd-tags { display: flex; gap: 0.75rem; justify-content: center; flex-wrap: wrap; margin-bottom: 3rem; }
.pd-tag { padding: 0.6rem 1.5rem; background: var(--color-accent); color: #fff; border-radius: 100px; font-weight: 700; font-size: 0.95rem; box-shadow: 0 6px 16px rgba(32,50,255,0.25); }

/* ── 스펙 ───────────────────────────── */
.pd-specs { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; margin-bottom: 3rem; }
.pd-spec { border: 1px solid #e8ebf2; border-radius: 14px; padding: 1.5rem 1rem; text-align: center; background: rgba(255,255,255,0.6); }
.pd-spec-label { display: block; font-family: var(--font-mono); font-size: 0.72rem; color: var(--color-muted); font-weight: 700; margin-bottom: 0.5rem; text-transform: uppercase; }
.pd-spec-value { font-size: 1.15rem; font-weight: 800; color: var(--color-text); }

/* ── 사이즈표 ───────────────────────── */
.pd-size { margin-bottom: 3rem; }
.pd-size-title { font-size: 1.2rem; margin-bottom: 1rem; }
.pd-size-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.pd-size-table th, .pd-size-table td { border: 1px solid #e8ebf2; padding: 0.75rem; text-align: center; }
.pd-size-table th { background: var(--color-surface); font-family: var(--font-mono); font-weight: 700; color: var(--color-text); }
.pd-size-rowlabel { font-weight: 700; background: rgba(245,247,250,0.5); }

/* ── 주의사항 + FAQ ─────────────────── */
.pd-notice { display: flex; gap: 1rem; align-items: flex-start; background: #fff8f0; border: 1px solid #ffe0b8; border-radius: 14px; padding: 1.5rem; }
.pd-notice-icon { flex-shrink: 0; width: 26px; height: 26px; border-radius: 50%; background: #f59e0b; color: #fff; font-weight: 800; display: flex; align-items: center; justify-content: center; }
.pd-notice p { color: #92600a; line-height: 1.6; font-size: 0.92rem; }
.pd-notice-h { font-size: 1.05rem; margin-bottom: 0.4rem; color: #92600a; }
.pd-faq { margin-top: 3rem; }
.pd-faq-item { border: 1px solid #e8ebf2; border-radius: 12px; background: rgba(255,255,255,0.6); overflow: hidden; margin-bottom: 0.75rem; }
.pd-faq-item summary { padding: 1.1rem 1.5rem; font-weight: 700; cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; }
.pd-faq-item summary::-webkit-details-marker { display: none; }
.pd-faq-item summary::after { content: '+'; font-size: 1.3rem; color: var(--color-accent); }
.pd-faq-item[open] summary::after { content: '−'; }
.pd-faq-item p { padding: 0 1.5rem 1.25rem; color: var(--color-muted); line-height: 1.7; }

/* ── 디자인 컨셉 ────────────────────── */
.pd-concept { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center; padding: 3rem; background: linear-gradient(135deg, #0a0e27, #1a1f4d); border-radius: 24px; color: #fff; overflow: hidden; }
.pd-concept-visual { display: flex; align-items: center; justify-content: center; aspect-ratio: 1; }
.pd-concept-circles { position: relative; width: 70%; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(circle, #2032ff 0%, transparent 70%); }
.pd-concept-circles::before, .pd-concept-circles::after { content: ''; position: absolute; inset: 0; border: 2px solid rgba(32,50,255,0.5); border-radius: 50%; animation: pdRipple 3s ease-out infinite; }
.pd-concept-circles::after { animation-delay: 1.5s; }
@keyframes pdRipple { 0% { transform: scale(0.5); opacity: 1; } 100% { transform: scale(1.6); opacity: 0; } }
.pd-concept-text .sec-index { color: #9fb4ff; }
.pd-concept-text h2 { font-size: clamp(1.5rem, 3vw, 2.2rem); margin-bottom: 1rem; }
.pd-concept-text p { color: #c5cdf0; line-height: 1.9; font-size: 0.98rem; }

/* ── 프로그램 ───────────────────────── */
.pd-prog-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; }
.pd-prog-card { display: flex; align-items: center; gap: 1rem; padding: 1.5rem; border: 1px solid #e8ebf2; border-radius: 16px; background: rgba(255,255,255,0.6); transition: all 0.2s; }
.pd-prog-card:hover { border-color: var(--color-accent); transform: translateY(-3px); text-decoration: none; box-shadow: 0 12px 30px rgba(32,50,255,0.1); }
.pd-prog-icon { width: 48px; height: 48px; border-radius: 12px; background: linear-gradient(135deg, #dfe5ff, #c2ccff); flex-shrink: 0; }
.pd-prog-info { display: flex; flex-direction: column; flex: 1; }
.pd-prog-sport { font-family: var(--font-mono); font-size: 0.72rem; color: var(--color-muted); font-weight: 700; }
.pd-prog-name { font-weight: 700; color: var(--color-text); }
.pd-prog-arrow { color: var(--color-accent); font-weight: 700; }

/* ── 사용 사례 ──────────────────────── */
.pd-case-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
.pd-case-card { border-radius: 16px; overflow: hidden; }
.pd-case-img { aspect-ratio: 4/3; background: linear-gradient(135deg, #eef1f8, #dfe3ec); border-radius: 16px; margin-bottom: 0.5rem; }
.pd-case-caption { font-size: 0.85rem; color: var(--color-muted); text-align: center; font-weight: 600; }

/* ── 송신기 안내 ────────────────────── */
.pd-transmitter { display: flex; gap: 1.25rem; align-items: flex-start; background: rgba(32,50,255,0.05); border: 1px solid rgba(32,50,255,0.15); border-radius: 16px; padding: 1.75rem; }
.pd-trans-icon { font-size: 1.6rem; flex-shrink: 0; }
.pd-trans-text h3 { font-size: 1.1rem; margin-bottom: 0.4rem; color: var(--color-accent); }
.pd-trans-text p { color: var(--color-muted); line-height: 1.7; font-size: 0.95rem; }

/* ── 사진 갤러리 (큰 사진 세로 나열) ──── */
.pd-gallery-strip { display: flex; flex-direction: column; gap: 1.25rem; }
.pd-gallery-shot { width: 100%; border-radius: 20px; overflow: hidden; }
.pd-gallery-shot img { width: 100%; display: block; }
.pd-gallery-ph { width: 100%; aspect-ratio: 16/9; background: linear-gradient(135deg, #eef1f8, #dfe3ec); }

/* ── 연관 제품 슬라이드 ─────────────── */
.pd-related-head { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 1.5rem; }
.pd-related-head .pd-h2 { margin-bottom: 0; }
.pd-related-nav { display: flex; gap: 0.5rem; }
.pd-related-arrow { width: 42px; height: 42px; border-radius: 50%; border: 1px solid #d8dce6; background: #fff; color: var(--color-text); font-size: 1.4rem; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: all 0.2s; }
.pd-related-arrow:hover { border-color: var(--color-accent); color: var(--color-accent); }
.pd-related-arrow:disabled { opacity: 0.35; cursor: not-allowed; }
.pd-related-arrow:disabled:hover { border-color: #d8dce6; color: var(--color-text); }
.pd-related-viewport { overflow: hidden; }
.pd-related-track { display: flex; gap: 1.25rem; transition: transform 0.45s cubic-bezier(0.4,0,0.2,1); }
.pd-related-card { flex: 0 0 calc((100% - 5rem) / 5); display: flex; flex-direction: column; border: 1px solid #e8ebf2; border-radius: 16px; overflow: hidden; background: rgba(255,255,255,0.6); transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s; }
.pd-related-card:hover { border-color: var(--color-accent); transform: translateY(-4px); text-decoration: none; box-shadow: 0 14px 32px rgba(32,50,255,0.12); }
.pd-related-img { aspect-ratio: 1; background: linear-gradient(135deg, #eef1f8, #dfe3ec); }
.pd-related-badge { font-family: var(--font-mono); font-size: 0.68rem; color: var(--color-accent); font-weight: 700; padding: 1rem 1rem 0.25rem; }
.pd-related-name { font-weight: 700; color: var(--color-text); padding: 0 1rem 1.25rem; }

/* ── 태블릿 ─────────────────────────── */
@media (max-width: 980px) {
  .pd-related-card { flex: 0 0 calc((100% - 3rem) / 3); }
}

/* ── 모바일 ─────────────────────────── */
@media (max-width: 768px) {
  /* 상단: 이미지 크게 유지 */
  .pd-top { padding: 1.5rem var(--gutter); }
  .pd-top-inner { grid-template-columns: 1fr; gap: 1.5rem; }
  .pd-gallery { max-width: 480px; margin: 0 auto; width: 100%; }

  /* 특징 4박스 → 1단 */
  .pd-feat-grid { grid-template-columns: 1fr; }
  .pd-feat-card.highlight { transform: none; }

  /* 작동방식 → 1단 (이미지가 폭 전체 사용, 안 작아짐) */
  .pd-feat-showcase { gap: 3rem; }
  .pd-feat-item { grid-template-columns: 1fr; gap: 1.25rem; transform: translateY(30px); }
  .pd-feat-item[data-reveal="right"] { transform: translateY(30px); }
  .pd-feat-item[data-reveal="right"] .pd-feat-body { order: 0; }
  .pd-feat-item.revealed { transform: translateY(0); }
  .pd-feat-num { font-size: 2.8rem; top: -14px; }

  /* 스펙 2열, 사이즈표 축소 */
  .pd-specs { grid-template-columns: repeat(2, 1fr); }
  .pd-size-table { font-size: 0.78rem; }

  /* 컨셉·프로그램·사용사례 → 1단 */
  .pd-concept { grid-template-columns: 1fr; padding: 2rem; }
  .pd-prog-list { grid-template-columns: 1fr; }
  .pd-case-grid { grid-template-columns: 1fr; }

  /* 연관제품 → 1.5개씩 (크게, 스와이프 유도) */
  .pd-related-card { flex: 0 0 70%; }

  /* 탭 가로 스크롤 */
  .pd-tabs { top: 60px; }
  .pd-tabs-inner { overflow-x: auto; }
  .pd-tab { white-space: nowrap; flex-shrink: 0; padding: 1rem 1.1rem; }
}

/* 옵션 미선택 경고 */
@keyframes pdShake { 0%, 100% { transform: translateX(0); } 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }
.pd-opt-shake { animation: pdShake 0.4s ease; }
.pd-opt-shake .pd-opt-label { color: #e23a3a; }
.pd-add-btn.pd-add-warn { background: #e23a3a; }