/* ═══════════════════════════════════════════
   오상신경외과 — 의학백과 스타일
   ═══════════════════════════════════════════ */

/* ─── 공통 ─── */
body {
  font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, sans-serif;
  color: #363636; background: #fff;
  -webkit-font-smoothing: antialiased;
}

/* ─── 브레드크럼 ─── */
.ency-breadcrumb {
  background: #f9f8f6; border-bottom: 1px solid #f0ece7;
  padding: 12px 0; font-size: 13px;
}
.ency-breadcrumb__inner {
  max-width: 900px; margin: 0 auto; padding: 0 24px;
  display: flex; align-items: center; gap: 8px;
  flex-wrap: wrap;
}
.ency-breadcrumb a { color: #888; text-decoration: none; }
.ency-breadcrumb a:hover { color: #c3a990; }
.ency-breadcrumb span { color: #ccc; }
.ency-breadcrumb .current { color: #363636; font-weight: 500; }

/* ─── 히어로 (개별 페이지) ─── */
.ency-hero {
  background: linear-gradient(135deg, #f9f8f6 0%, #f0ece7 100%);
  padding: 60px 0 48px;
}
.ency-hero__inner {
  max-width: 900px; margin: 0 auto; padding: 0 24px;
}
.ency-hero__badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: #c3a990; color: #fff;
  padding: 6px 16px; border-radius: 24px;
  font-size: 13px; font-weight: 500;
  margin-bottom: 20px;
}
.ency-hero__title {
  font-size: clamp(28px, 4vw, 40px); font-weight: 800;
  color: #222; line-height: 1.3; margin-bottom: 8px;
  letter-spacing: -0.02em;
}
.ency-hero__subtitle {
  font-size: 16px; color: #888; margin-bottom: 24px;
  font-weight: 400;
}
.ency-hero__lead {
  font-size: clamp(15px, 2vw, 17px); color: #555;
  line-height: 1.85; margin-bottom: 24px;
}
.ency-hero__meta {
  display: flex; gap: 20px; font-size: 13px; color: #999;
}
.ency-hero__meta i { margin-right: 4px; }

/* ─── 요약 박스 ─── */
.ency-summary {
  padding: 40px 0;
}
.ency-summary__inner {
  max-width: 900px; margin: 0 auto; padding: 32px;
  background: #f9f8f6; border-radius: 16px;
  border-left: 4px solid #c3a990;
}
.ency-summary__inner h2 {
  font-size: 16px; font-weight: 700; color: #c3a990;
  margin-bottom: 12px; letter-spacing: 1px;
}
.ency-summary__inner p {
  font-size: 15px; color: #555; line-height: 1.85;
}

/* ─── 본문 ─── */
.ency-article { padding: 20px 0 60px; }
.ency-article__inner {
  max-width: 900px; margin: 0 auto; padding: 0 24px;
}
.ency-article__inner h2 {
  font-size: clamp(20px, 3vw, 26px); font-weight: 700;
  color: #222; margin: 48px 0 20px;
  padding-bottom: 12px; border-bottom: 2px solid #f0ece7;
}
.ency-article__inner h2:first-child { margin-top: 0; }
.ency-article__inner h3 {
  font-size: 18px; font-weight: 600; color: #363636;
  margin: 32px 0 12px;
}
.ency-article__inner p {
  font-size: 16px; line-height: 1.9; color: #444;
  margin-bottom: 16px;
}
.ency-article__inner strong { color: #363636; }
.ency-list {
  margin: 16px 0; padding-left: 20px;
  list-style: none;
}
.ency-list li {
  position: relative; padding-left: 16px;
  font-size: 16px; line-height: 1.9; color: #444;
  margin-bottom: 8px;
}
.ency-list li::before {
  content: ''; position: absolute; left: 0; top: 12px;
  width: 6px; height: 6px; border-radius: 50%;
  background: #c3a990;
}
.ref-num {
  font-size: 11px; color: #c3a990; font-weight: 600;
  cursor: help;
}

/* ─── FAQ ─── */
.ency-faq { padding: 60px 0; background: #f9f8f6; }
.ency-faq__inner {
  max-width: 900px; margin: 0 auto; padding: 0 24px;
}
.ency-faq__inner > h2 {
  font-size: 22px; font-weight: 700; color: #222;
  margin-bottom: 32px;
}
.ency-faq__inner > h2 i { color: #c3a990; margin-right: 8px; }
.ency-faq__item {
  background: #fff; border-radius: 12px;
  margin-bottom: 12px; overflow: hidden;
  border: 1px solid #f0ece7;
}
.ency-faq__q {
  width: 100%; padding: 20px 24px;
  display: flex; justify-content: space-between; align-items: center;
  font-size: 16px; font-weight: 600; color: #363636;
  background: none; border: none; cursor: pointer;
  text-align: left; font-family: inherit;
  transition: background 0.2s;
}
.ency-faq__q:hover { background: #fafafa; }
.ency-faq__q i {
  font-size: 12px; color: #999;
  transition: transform 0.3s;
}
.ency-faq__q[aria-expanded="true"] i { transform: rotate(180deg); }
.ency-faq__a {
  max-height: 0; overflow: hidden;
  transition: max-height 0.3s ease;
}
.ency-faq__a p {
  padding: 0 24px 20px;
  font-size: 15px; line-height: 1.85; color: #555;
}

/* ─── 참고문헌 ─── */
.ency-references { padding: 60px 0; }
.ency-references__inner {
  max-width: 900px; margin: 0 auto; padding: 0 24px;
}
.ency-references__inner > h2 {
  font-size: 20px; font-weight: 700; color: #222;
  margin-bottom: 24px;
}
.ency-references__inner > h2 i { color: #c3a990; margin-right: 8px; }
.ency-ref__list {
  padding: 0; list-style: none;
  counter-reset: ref;
}
.ency-ref__list li {
  font-size: 13px; line-height: 1.7; color: #666;
  padding: 12px 0; border-bottom: 1px solid #f0ece7;
}
.ency-ref__list em { font-style: italic; }
.ency-ref__doi, .ency-ref__pm {
  display: inline-block; padding: 2px 8px;
  border-radius: 4px; font-size: 11px; font-weight: 600;
  text-decoration: none; margin-left: 4px;
}
.ency-ref__doi { background: #e8f4e8; color: #2a7a2a; }
.ency-ref__pm { background: #e8ecf4; color: #2a4a7a; }
.ency-ref__doi:hover { background: #d0e8d0; }
.ency-ref__pm:hover { background: #d0d8e8; }

/* ─── 관련 항목 ─── */
.ency-related { padding: 60px 0; background: #f9f8f6; }
.ency-related__inner {
  max-width: 900px; margin: 0 auto; padding: 0 24px;
}
.ency-related__inner > h2 {
  font-size: 20px; font-weight: 700; color: #222;
  margin-bottom: 24px;
}
.ency-related__inner > h2 i { color: #c3a990; margin-right: 8px; }
.ency-related__grid {
  display: flex; flex-wrap: wrap; gap: 10px;
}
.ency-related__link {
  display: inline-block; padding: 10px 20px;
  background: #fff; border: 1px solid #e5e5e5;
  border-radius: 8px; font-size: 14px; font-weight: 500;
  color: #363636; text-decoration: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.ency-related__link:hover {
  border-color: #c3a990; color: #c3a990;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

/* ─── 태그 ─── */
.ency-tags { padding: 24px 0 40px; }
.ency-tags__inner {
  max-width: 900px; margin: 0 auto; padding: 0 24px;
  display: flex; flex-wrap: wrap; gap: 8px;
}
.ency-tag {
  display: inline-block; padding: 4px 12px;
  background: #f0ece7; border-radius: 20px;
  font-size: 12px; color: #888;
}

/* ─── 면책 ─── */
.ency-disclaimer { padding: 0 0 40px; }
.ency-disclaimer__inner {
  max-width: 900px; margin: 0 auto; padding: 20px 24px;
  background: #fff8f0; border: 1px solid #f0e0c8;
  border-radius: 8px;
}
.ency-disclaimer__inner p {
  font-size: 13px; color: #997a50; line-height: 1.7;
}
.ency-disclaimer__inner i { margin-right: 6px; }

/* ─── CTA ─── */
.ency-cta {
  padding: 80px 0; background: #3a422c;
  text-align: center; color: #fff;
}
.ency-cta__inner {
  max-width: 600px; margin: 0 auto; padding: 0 24px;
}
.ency-cta__text {
  font-size: 16px; color: rgba(255,255,255,0.7); margin-bottom: 12px;
}
.ency-cta__inner h3 {
  font-size: clamp(22px, 3vw, 30px); font-weight: 700;
  margin-bottom: 36px; line-height: 1.5;
}
.ency-cta__buttons { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
.ency-cta__btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 16px 36px; border-radius: 50px;
  font-size: 16px; font-weight: 700; text-decoration: none;
  transition: all 0.3s;
}
.ency-cta__btn--tel { background: #fff; color: #3a422c; }
.ency-cta__btn--tel:hover { background: #f2efea; transform: translateY(-2px); box-shadow: 0 6px 20px rgba(0,0,0,0.2); }
.ency-cta__btn--kakao { background: #FEE500; color: #3C1E1E; }
.ency-cta__btn--kakao:hover { background: #f5dc00; transform: translateY(-2px); box-shadow: 0 6px 20px rgba(254,229,0,0.3); }

/* ═══ 인덱스 페이지 ═══ */

/* 히어로 */
.ency-idx-hero {
  background: linear-gradient(135deg, #363636 0%, #555 50%, #363636 100%);
  padding: 80px 0 60px; text-align: center; color: #fff;
}
.ency-idx-hero__inner { max-width: 700px; margin: 0 auto; padding: 0 24px; }
.ency-idx-hero__label {
  font-size: 13px; letter-spacing: 4px; color: rgba(255,255,255,0.6);
  margin-bottom: 16px; text-transform: uppercase;
}
.ency-idx-hero h1 {
  font-size: clamp(32px, 5vw, 48px); font-weight: 800;
  margin-bottom: 16px; letter-spacing: -0.02em;
}
.ency-idx-hero__desc {
  font-size: 16px; color: rgba(255,255,255,0.8); line-height: 1.8;
  margin-bottom: 36px;
}
.ency-idx-hero__desc strong { color: #fff; }
.ency-idx-hero__search {
  max-width: 500px; margin: 0 auto;
  display: flex; align-items: center;
  background: rgba(255,255,255,0.15);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 50px; padding: 0 24px;
  transition: background 0.3s;
}
.ency-idx-hero__search:focus-within {
  background: rgba(255,255,255,0.25);
  border-color: rgba(255,255,255,0.4);
}
.ency-idx-hero__search i { color: rgba(255,255,255,0.6); margin-right: 12px; }
.ency-idx-hero__search input {
  width: 100%; padding: 16px 0; border: none; background: none;
  font-size: 16px; color: #fff; outline: none;
  font-family: inherit;
}
.ency-idx-hero__search input::placeholder { color: rgba(255,255,255,0.5); }

/* 카테고리 필터 */
.ency-filter {
  background: #fff; border-bottom: 1px solid #f0ece7;
  position: sticky; top: 64px; z-index: 90;
  padding: 16px 0;
}
.ency-filter__inner {
  max-width: 1200px; margin: 0 auto; padding: 0 24px;
  display: flex; gap: 8px; overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.ency-filter__btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 16px; border-radius: 24px;
  font-size: 13px; font-weight: 500;
  color: #888; background: #f9f8f6;
  border: 1px solid transparent;
  white-space: nowrap; cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); font-family: inherit;
}
.ency-filter__btn:hover { color: #c3a990; background: #f0ece7; }
.ency-filter__btn.active {
  background: #c3a990; color: #fff;
  border-color: #c3a990;
}

@media (max-width: 768px) {
  .ency-filter { top: 56px; }
}

/* 카테고리 섹션 */
.ency-index__body {
  max-width: 1200px; margin: 0 auto;
  padding: 40px 24px 80px;
}
.ency-index__section { margin-bottom: 48px; }
.ency-index__section > h2 {
  font-size: 20px; font-weight: 700; color: #222;
  margin-bottom: 20px; display: flex; align-items: center; gap: 10px;
}
.ency-index__section > h2 i { color: #c3a990; }
.ency-index__count {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 28px; height: 28px; padding: 0 8px;
  background: #f0ece7; border-radius: 14px;
  font-size: 13px; font-weight: 600; color: #888;
}
.ency-index__grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 12px;
}
.ency-index__card {
  display: flex; flex-direction: column;
  padding: 20px 24px;
  background: #fff; border: 1px solid #f0ece7;
  border-radius: 12px; text-decoration: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.ency-index__card:hover {
  border-color: #c3a990;
  box-shadow: 0 4px 16px rgba(0,0,0,0.06);
  transform: translateY(-2px);
}
.ency-index__card-title {
  font-size: 16px; font-weight: 600; color: #363636;
  margin-bottom: 4px;
}
.ency-index__card-en {
  font-size: 13px; color: #999; font-weight: 400;
}

/* 검색 결과 */
.ency-search-results {
  max-width: 1200px; margin: 0 auto;
  padding: 40px 24px;
}
.ency-search-empty {
  text-align: center; color: #999;
  font-size: 16px; padding: 60px 0;
}

/* ─── 반응형 ─── */
@media (max-width: 768px) {
  .ency-hero { padding: 40px 0 32px; }
  .ency-hero__meta { flex-direction: column; gap: 8px; }
  .ency-cta { padding: 60px 0; }
  .ency-cta__buttons { flex-direction: column; align-items: center; }
  .ency-cta__btn { width: 100%; max-width: 300px; justify-content: center; }
  .ency-idx-hero { padding: 60px 0 40px; }
  .ency-index__grid { grid-template-columns: 1fr; }
}
