/* 홍한의원 GEO 사이트
   색: 송록(기존 홈페이지 브랜드 색) 한 가지를 중심으로, 휴진·주의에만 대추색을 씁니다.
   글꼴: Pretendard 한 가지. 자바스크립트는 쓰지 않습니다. */

:root {
  --pine: #0a5c52;
  --pine-deep: #084a42;
  --pine-mid: #3a7f75;
  --jade: #e8f4f2;
  --paper: #ffffff;
  --ink: #17211f;
  --muted: #586764;
  --line: #d5e0dd;
  --jujube: #a2362b;
  --measure: 40rem;
  --font: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", "Malgun Gothic", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.75;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.wrap { width: min(100% - 2rem, 64rem); margin-inline: auto; }

a { color: var(--pine); text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
a:hover { color: var(--pine-deep); text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--pine); outline-offset: 3px; border-radius: 2px; }

.skip { position: absolute; left: -999rem; top: 0; background: var(--pine); color: #fff; padding: 0.75rem 1rem; z-index: 10; }
.skip:focus { left: 0; }

/* 머리 */
.site-head { border-bottom: 1px solid var(--line); }
.site-head .wrap { display: flex; flex-wrap: wrap; align-items: baseline; column-gap: 1.5rem; padding-block: 1rem 0; }
.brand { font-size: 1.375rem; font-weight: 800; letter-spacing: -0.03em; color: var(--pine); text-decoration: none; }
.head-tel { margin-left: auto; font-weight: 600; font-variant-numeric: tabular-nums; text-decoration: none; }
.site-nav { flex-basis: 100%; display: flex; gap: 1.5rem; overflow-x: auto; margin-top: 0.5rem; scrollbar-width: none; }
.site-nav::-webkit-scrollbar { display: none; }
.site-nav a { flex: none; padding-block: 0.625rem; color: var(--ink); text-decoration: none; font-weight: 500; border-bottom: 3px solid transparent; }
.site-nav a:hover { border-bottom-color: var(--line); }
.site-nav a[aria-current="page"] { color: var(--pine); border-bottom-color: var(--pine); font-weight: 700; }

/* 본문 공통 */
main { padding-block: 2.5rem 4.5rem; }
main > * { max-width: var(--measure); }

h1, h2, h3 { line-height: 1.3; letter-spacing: -0.025em; text-wrap: balance; }
h1 { font-size: clamp(1.875rem, 1.2rem + 3vw, 2.75rem); font-weight: 800; margin: 0 0 1.25rem; }
h2 { font-size: 1.5rem; font-weight: 750; margin: 3rem 0 0.875rem; padding-top: 1.25rem; border-top: 1px solid var(--line); }
h3 { font-size: 1.1875rem; font-weight: 700; margin: 2rem 0 0.5rem; }
p { margin: 0 0 1.125rem; }
ul, ol { margin: 0 0 1.25rem; padding-left: 1.25rem; }
li { margin-bottom: 0.375rem; }
li::marker { color: var(--pine-mid); }
strong { font-weight: 700; }

.lead { font-size: 1.25rem; line-height: 1.65; color: var(--ink); margin-bottom: 2rem; }

.note { border-left: 3px solid var(--jujube); padding: 0.125rem 0 0.125rem 1rem; color: var(--muted); font-size: 1rem; }

.crumbs ol { display: flex; flex-wrap: wrap; gap: 0.25rem 0; list-style: none; margin: 0 0 1.25rem; padding: 0; font-size: 0.9375rem; color: var(--muted); }
.crumbs li { margin: 0; }
.crumbs li::after { content: "/"; margin-inline: 0.5rem; color: var(--line); }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--pine); text-decoration: underline; }

.stamp { margin-top: 3rem; font-size: 0.9375rem; color: var(--muted); }

/* 순서가 있는 절차 */
.steps { list-style: none; padding: 0; counter-reset: step; }
.steps li { counter-increment: step; position: relative; padding: 0 0 1rem 2.75rem; margin: 0; border-left: 1px solid var(--line); margin-left: 0.875rem; }
.steps li:last-child { border-left-color: transparent; padding-bottom: 0; }
.steps li::before { content: counter(step); position: absolute; left: -0.875rem; top: 0; width: 1.75rem; height: 1.75rem; display: grid; place-items: center; background: var(--pine); color: #fff; border-radius: 50%; font-size: 0.875rem; font-weight: 700; }

/* 표 */
.table-wrap { overflow-x: auto; margin: 0 0 1.5rem; max-width: 100%; }
table { border-collapse: collapse; width: 100%; font-size: 1rem; font-variant-numeric: tabular-nums; }
th, td { text-align: left; padding: 0.625rem 1rem 0.625rem 0; border-bottom: 1px solid var(--line); vertical-align: top; }
thead th { font-size: 0.875rem; font-weight: 600; color: var(--muted); border-bottom: 2px solid var(--pine); white-space: nowrap; }
tbody th { font-weight: 600; }
td { white-space: nowrap; }
td:last-child, th:last-child { padding-right: 0; }

/* 병원 기본 정보 */
.facts { margin: 0 0 1.5rem; }
.facts div { display: grid; grid-template-columns: 5.5rem 1fr; gap: 0.75rem; padding-block: 0.5rem; border-bottom: 1px solid var(--line); }
.facts dt { color: var(--muted); font-size: 0.9375rem; }
.facts dd { margin: 0; }

/* 진료시간 띠: 이 사이트의 얼굴 */
.tt { max-width: 46rem; margin: 0 0 2.5rem; }
.tt-rows { list-style: none; margin: 0; padding: 0; }
.tt-row, .tt-axis { display: grid; grid-template-columns: 1.75rem 1fr 13.5rem; align-items: center; column-gap: 0.875rem; }
.tt-row { margin: 0; padding-block: 0.3125rem; }
.tt-day { font-weight: 700; }
.tt-row.weekend .tt-day { color: var(--pine); }
.tt-track { position: relative; height: 1.375rem; background: repeating-linear-gradient(to right, var(--line) 0 1px, transparent 1px calc(100% / 11)); border-right: 1px solid var(--line); }
.bar { position: absolute; top: 0; bottom: 0; background: var(--pine-mid); }
.bar.night { background: var(--pine-deep); }
.tt-row.weekend .bar { background: var(--pine); }
.tt-time { font-variant-numeric: tabular-nums; font-size: 1rem; white-space: nowrap; }
.tt-tag { margin-left: 0.5rem; font-size: 0.8125rem; font-weight: 600; color: var(--pine); }
.tt-ticks { position: relative; height: 1.5rem; font-size: 0.75rem; color: var(--muted); }
.tt-ticks span { position: absolute; top: 0.25rem; transform: translateX(-50%); white-space: nowrap; }
.tt-ticks span:first-child { transform: none; }
.tt-ticks span:last-child { transform: translateX(-100%); }
.tt-foot { margin: 0.75rem 0 0; font-size: 0.9375rem; color: var(--muted); }

/* 목록: 분야, 질문 */
.index, .qlist { list-style: none; padding: 0; margin: 0 0 1.5rem; }
.index li, .qlist li { margin: 0; padding-block: 0.875rem; border-bottom: 1px solid var(--line); }
.index a, .qlist a { font-size: 1.125rem; font-weight: 700; text-decoration: none; }
.index a:hover, .qlist a:hover { text-decoration: underline; }
.index p, .qlist p { margin: 0.25rem 0 0; font-size: 1rem; color: var(--muted); line-height: 1.6; }
.qlist a { font-weight: 600; }

/* 질문 글: 답을 먼저 */
.qa h1 { font-size: clamp(1.625rem, 1.1rem + 2.4vw, 2.25rem); }
.answer { display: grid; grid-template-columns: auto 1fr; gap: 1rem; align-items: start; margin: 0 0 2.25rem; padding: 1.25rem; background: var(--jade); }
.answer p { margin: 0; font-size: 1.1875rem; line-height: 1.65; font-weight: 500; }
.seal { display: grid; place-items: center; width: 2.5rem; height: 2.5rem; background: var(--pine); color: #fff; font-size: 1.25rem; font-weight: 800; border-radius: 3px; }

/* 첫 화면 */
.home h1 { font-size: clamp(2.25rem, 1.4rem + 4.5vw, 3.75rem); margin-bottom: 1rem; }
.home .lead { max-width: 36rem; }
.home main > *, main.home > * { max-width: 46rem; }

/* 발 */
.site-foot { background: var(--pine-deep); color: #dcebe8; padding-block: 2.5rem 3rem; font-size: 0.9375rem; }
.site-foot a { color: #fff; }
.foot-name { font-size: 1.25rem; font-weight: 800; color: #fff; margin-bottom: 0.75rem; }
.site-foot .facts { max-width: 40rem; }
.site-foot .facts div { border-bottom-color: rgba(255, 255, 255, 0.16); }
.site-foot .facts dt { color: #a9c9c3; }
.foot-links { display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; margin: 1.5rem 0; }
.foot-legal { color: #a9c9c3; font-size: 0.875rem; line-height: 1.7; margin: 0; max-width: 40rem; }

@media (max-width: 40rem) {
  body { font-size: 1rem; }
  main { padding-block: 1.75rem 3.5rem; }
  .tt-row, .tt-axis { grid-template-columns: 1.5rem 1fr; }
  .tt-row .tt-time { grid-column: 2; font-size: 0.875rem; color: var(--muted); }
  .tt-axis .tt-time { display: none; }
  .tt-track { height: 1.125rem; }
  .answer { grid-template-columns: 1fr; padding: 1rem; }
  .answer p { font-size: 1.0625rem; }
  .facts div { grid-template-columns: 4.5rem 1fr; }
  td { white-space: normal; }
}

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

@media print {
  .site-head, .site-foot, .crumbs, .skip { display: none; }
  body { font-size: 11pt; }
}
