/* ==========================================================================
   yswang.co.kr 공용 스타일
   ========================================================================== */

:root {
  --ysw-point: #2659D9;
  --ysw-pointsoft: #c9d8ff;

  --ysw-ink: #17191d;
  --ysw-inksoft: #4a4f57;
  --ysw-paper: #ffffff;
  --ysw-sand: #eef1f4;
  --ysw-sandsoft: #f6f8fa;
  --ysw-muted: #838a94;
  --ysw-line: #e3e7ec;

  --ysw-radius: 18px;
  --ysw-maxw: 1160px;
}
* { box-sizing: border-box; word-break: keep-all; word-break: auto-phrase; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--ysw-paper);
  color: var(--ysw-ink);
  font-family: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, 'Malgun Gothic', sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
.ysw-en { font-family: 'Montserrat', 'Pretendard Variable', sans-serif; letter-spacing: 0.04em; }
.wrap { max-width: var(--ysw-maxw); margin: 0 auto; padding: 0 24px; }

.ysw-blind { position:absolute; width:1px; height:1px; margin:-1px; padding:0; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }

/* ---------- header ---------- */
.ysw-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--ysw-line);
}
.ysw-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.ysw-logo { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 18px; }
.ysw-logo img { height: 28px; width: auto; }
.ysw-logo .ysw-logoflip {
  position: relative; display: inline-block; height: 1.3em; overflow: hidden;
  line-height: 1.3em; min-width: 108px;
}
.ysw-logo .ysw-logoflip .ysw-line { display: block; transition: transform .4s cubic-bezier(.65, 0, .35, 1); }
.ysw-logo .ysw-logoflip .ysw-line.ysw-kr { position: absolute; top: 0; left: 0; transform: translateY(100%); }
.ysw-logo:hover .ysw-logoflip .ysw-line.ysw-en { transform: translateY(-100%); }
.ysw-logo:hover .ysw-logoflip .ysw-line.ysw-kr { transform: translateY(0); }

.ysw-nav { display: flex; align-items: center; gap: 26px; font-size: 14px; color: var(--ysw-inksoft); }
.ysw-nav a { display: inline-block; padding: 6px 0; border-bottom: 1px solid transparent; transition: border-color .2s, color .2s; }
.ysw-nav a:hover, .ysw-nav a.ysw-on { color: var(--ysw-ink); border-color: var(--ysw-point); }
.ysw-nav .ysw-askbtn { color: var(--ysw-paper); padding-inline: 20px; }
.ysw-nav .ysw-askbtn:hover { color: var(--ysw-paper); border-color: transparent; }
.ysw-nav .ysw-homelink { display: inline-flex; align-items: center; padding: 6px 0; font-size: 15px; }

.ysw-flip { position: relative; display: inline-block; height: 1.3em; overflow: hidden; line-height: 1.6em; vertical-align: top; }
.ysw-flip .ysw-line { display: block; transition: transform .35s cubic-bezier(.65, 0, .35, 1); white-space: nowrap; }
.ysw-flip .ysw-line:last-child { position: absolute; top: 0; left: 0; transform: translateY(100%); }
a:hover .ysw-flip .ysw-line:first-child { transform: translateY(-100%); }
a:hover .ysw-flip .ysw-line:last-child { transform: translateY(0); }

/* ---------- 모바일 햄버거 메뉴 ---------- */
.ysw-burger {
  display: none; flex-direction: column; justify-content: center; align-items: center;
  gap: 5px; width: 40px; height: 40px; padding: 0; border: none; background: transparent; cursor: pointer;
  position: relative; z-index: 210;
}
.ysw-burger span { display: block; width: 22px; height: 2px; background: var(--ysw-ink); border-radius: 2px; }

.ysw-drawer {
  position: fixed; inset: 0; height: 0; overflow: hidden;
  background: #0c0c0c; z-index: 200;
  display: flex; align-items: center; justify-content: center;
  transition: height .5s cubic-bezier(.65, 0, .35, 1);
}
.ysw-drawer.ysw-open { height: 100vh; height: 100dvh; }

.ysw-drawer-close {
  position: absolute; top: 28px; left: 50%; transform: translateX(-50%);
  width: 40px; height: 40px; border: none; background: transparent; cursor: pointer;
}
.ysw-drawer-close span {
  position: absolute; top: 50%; left: 50%; width: 26px; height: 2px; background: #fff;
}
.ysw-drawer-close span:nth-child(1) { transform: translate(-50%, -50%) rotate(45deg); }
.ysw-drawer-close span:nth-child(2) { transform: translate(-50%, -50%) rotate(-45deg); }

.ysw-drawer-inner {
  display: flex; flex-direction: column; align-items: center; gap: 26px;
  max-height: 82vh; overflow-y: auto; padding: 40px 24px;
}
.ysw-drawer-inner a { color: #fff; font-size: 20px; font-weight: 700; letter-spacing: 0.01em; }
.ysw-drawer-inner a.ysw-home { font-size: 22px; }
.ysw-drawer-inner a.ysw-on { text-decoration: underline; text-underline-offset: 6px; }
.ysw-drawer-inner a.ysw-btn { margin-top: 10px; background: #fff; color: #0c0c0c; font-size: 15px; }
.ysw-drawer-inner a.ysw-homelink { color: #d8dadd; font-size: 15px; }
body.ysw-lock { overflow: hidden; }

/* ---------- buttons ---------- */
.ysw-btn {
  display: inline-flex; align-items: center; gap: 8px; padding: 14px 28px;
  border-radius: 999px; background: var(--ysw-ink); color: var(--ysw-paper);
  font-weight: 600; font-size: 15px; transition: transform .2s ease, opacity .2s ease;
}
.ysw-btn:hover { transform: translateY(-2px); opacity: .88; }
.ysw-btn.outline { background: transparent; color: var(--ysw-ink); border: 1px solid var(--ysw-ink); }
.ysw-askbtn { background: var(--ysw-point); }

/* ---------- hero ---------- */
.ysw-hero { padding: 96px 0 64px; }
.ysw-hero .ysw-herogrid { display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 40px; }
.ysw-hero .ysw-heroart {
  display: flex; align-items: center; justify-content: center;
  background: var(--ysw-sandsoft); border: 1px solid var(--ysw-line); border-radius: 28px; padding: 0; overflow: hidden;
  aspect-ratio: 1 / 1;
}
.ysw-hero .ysw-heroart img { width: 100%; height: 100%; object-fit: cover; }
.ysw-eyebrow {
  display: inline-block; font-size: 13px; font-weight: 600; color: var(--ysw-point);
  border: 1px solid var(--ysw-pointsoft); background: var(--ysw-pointsoft); padding: 6px 14px; border-radius: 999px; margin-bottom: 22px;
}
.ysw-hero h1 { font-size: clamp(30px, 4.4vw, 52px); line-height: 1.28; margin: 0 0 20px; letter-spacing: -0.01em; }
.ysw-hero p.ysw-lead { font-size: 18px; color: var(--ysw-inksoft); max-width: 640px; margin: 0 0 30px; }
.ysw-crumb { font-size: 13px; color: var(--ysw-muted); margin-bottom: 18px; }
.ysw-crumb a:hover { color: var(--ysw-ink); }

/* ---------- sections ---------- */
.ysw-section { padding: 64px 0; border-top: 1px solid var(--ysw-line); }
.ysw-section.ysw-noline { border-top: none; }
.ysw-section.ysw-soft { background: var(--ysw-sandsoft); }
.ysw-section h2 { font-size: clamp(24px, 3vw, 34px); margin: 0 0 14px; letter-spacing: -0.01em; }
.ysw-section .ysw-desc { color: var(--ysw-inksoft); font-size: 16px; max-width: 680px; margin: 0 0 40px; }
.ysw-section .ysw-sectionhead { display: grid; grid-template-columns: 1fr 88px; gap: 24px; align-items: flex-start; }
.ysw-section .ysw-sectionhead .ysw-headart {
  width: 88px; height: 88px; border-radius: 20px; background: var(--ysw-sandsoft);
  border: 1px solid var(--ysw-line); display: flex; align-items: center; justify-content: center; padding: 16px;
}

/* ---------- card grid (index page) ---------- */
.ysw-cardgrid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; }
.ysw-card {
  position: relative; display: flex; flex-direction: column; gap: 10px; padding: 26px 16px 28px;
  background: var(--ysw-paper); border: 1px solid var(--ysw-line); border-radius: var(--ysw-radius);
  min-height: 260px; transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.ysw-card:hover { transform: translateY(-6px); border-color: var(--ysw-point); box-shadow: 0 18px 40px rgba(23, 25, 29, 0.08); }
.ysw-card .ysw-idx { font-family: 'Montserrat', sans-serif; font-size: 13px; font-weight: 700; color: var(--ysw-muted); }
.ysw-card h3 { font-size: 19px; margin: 0; line-height: 1.4; }
.ysw-card p { font-size: 14px; color: var(--ysw-muted); margin: 0; flex-grow: 1; }
.ysw-card .ysw-go { align-self: flex-start; font-size: 13px; font-weight: 700; color: var(--ysw-point); display: inline-flex; align-items: center; gap: 6px; }
.ysw-card .ysw-go .ysw-arrow { transition: transform .2s ease; }
.ysw-card:hover .ysw-go .ysw-arrow { transform: translateX(4px); }

/* ---------- feature / info grid ---------- */
.ysw-grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.ysw-grid2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.ysw-feature { padding: 28px; border: 1px solid var(--ysw-line); border-radius: var(--ysw-radius); background: var(--ysw-paper); }
.ysw-feature .ysw-tag { display: inline-block; font-size: 12px; font-weight: 700; color: var(--ysw-point); margin-bottom: 12px; }
.ysw-feature h3 { font-size: 18px; margin: 0 0 10px; }
.ysw-feature p { font-size: 14px; color: var(--ysw-inksoft); margin: 0; }

.ysw-iconfeature { padding: 28px; border: 1px solid var(--ysw-line); border-radius: var(--ysw-radius); background: var(--ysw-paper); }
.ysw-iconfeature .ysw-icon {
  width: 44px; height: 44px; margin-bottom: 16px; padding: 9px;
  border-radius: 12px; background: var(--ysw-pointsoft); color: var(--ysw-point);
}
.ysw-iconfeature h3 { font-size: 17px; margin: 0 0 8px; }
.ysw-iconfeature p { font-size: 14px; color: var(--ysw-inksoft); margin: 0; }

/* ---------- 원장 프로필 카드 ---------- */
.ysw-doctorcard {
  display: grid; grid-template-columns: 260px 1fr; gap: 36px; align-items: start;
  padding: 32px; border: 1px solid var(--ysw-line); border-radius: var(--ysw-radius); background: var(--ysw-paper);
}
.ysw-doctorcard .ysw-photo { border-radius: 14px; overflow: hidden; background: var(--ysw-sandsoft); aspect-ratio: 3/4; }
.ysw-doctorcard .ysw-photo img { width: 100%; height: 100%; object-fit: cover; }
.ysw-doctorcard h3 { font-size: 22px; margin: 0 0 6px; }
.ysw-doctorcard .ysw-role { font-size: 14px; color: var(--ysw-point); font-weight: 700; margin-bottom: 16px; }
.ysw-doctorcard ul { margin: 0; padding-left: 18px; color: var(--ysw-inksoft); font-size: 15px; line-height: 1.9; }

/* ---------- process steps ---------- */
.ysw-steps { display: flex; flex-direction: column; gap: 0; border-top: 1px solid var(--ysw-line); }
.ysw-step { display: grid; grid-template-columns: 90px 1fr; gap: 20px; padding: 26px 0; border-bottom: 1px solid var(--ysw-line); }
.ysw-step .ysw-idx { font-family: 'Montserrat', sans-serif; font-weight: 700; color: var(--ysw-point); font-size: 15px; }
.ysw-step h4 { margin: 0 0 8px; font-size: 17px; }
.ysw-step p { margin: 0; color: var(--ysw-inksoft); font-size: 14px; }

/* ---------- table ---------- */
.ysw-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.ysw-table th, .ysw-table td { text-align: left; padding: 14px 12px; border-bottom: 1px solid var(--ysw-line); }
.ysw-table th { color: var(--ysw-muted); font-weight: 600; width: 30%; }
.ysw-table td.ysw-price { color: var(--ysw-point); font-weight: 700; }
.ysw-hourstable tr.ysw-on td, .ysw-hourstable tr.ysw-on th { color: var(--ysw-point); font-weight: 700; }

/* ---------- blog latest table ---------- */
.datatable { width: 100%; border-collapse: collapse; font-size: 14px; }
.datatable th, .datatable td { text-align: center; padding: 14px 12px; border-bottom: 1px solid var(--ysw-line); }
.datatable th { color: var(--ysw-muted); font-weight: 600;}
.datatable td.hl { color: var(--ysw-point); font-weight: 700; }
.blog-latest-table { table-layout: fixed; width: 100%; }
.blog-latest-table col.col-writer {width: 20%;}
.blog-latest-table col.col-subject {width: 70%;}
.blog-latest-table col:not(.col-subject) {width: 10%;}
.blog-link { display: contents; cursor: auto; } 

/* ---------- 지도/주소 래퍼 ---------- */
.ysw-mapwrap {
  border: 1px solid var(--ysw-line); border-radius: 28px; background: var(--ysw-sandsoft);
  padding: 32px; display: flex; flex-direction: column; gap: 16px;
}

/* ---------- CTA ---------- */
.ysw-cta { background: var(--ysw-ink); color: var(--ysw-paper); border-radius: 28px; padding: 64px 48px; text-align: center; }
.ysw-cta h2 { color: var(--ysw-paper); }
.ysw-cta p { color: rgba(255,255,255,.72); max-width: 520px; margin: 0 auto 30px; }
.ysw-cta .ysw-btn { background: var(--ysw-point); color: var(--ysw-paper); }

/* ---------- 관련 페이지 연결 카드 ---------- */
.ysw-linkgrid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.ysw-linkcard {
  display: flex; align-items: center; gap: 18px; padding: 24px; border: 1px solid var(--ysw-line);
  border-radius: var(--ysw-radius); background: var(--ysw-paper); transition: border-color .2s, transform .2s;
}
.ysw-linkcard:hover { border-color: var(--ysw-point); transform: translateY(-4px); }
.ysw-linkcard .ysw-icon { width: 40px; height: 40px; flex: none; padding: 8px; background: var(--ysw-pointsoft); color: var(--ysw-point); border-radius: 10px; }
.ysw-linkcard h3 { margin: 0 0 4px; font-size: 16px; }
.ysw-linkcard p { margin: 0; font-size: 13px; color: var(--ysw-muted); }

/* ---------- footer ---------- */
.ysw-footer { border-top: 1px solid var(--ysw-line); padding: 40px 0; font-size: 13px; color: var(--ysw-muted); }
.ysw-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; }
.ysw-footer address { font-style: normal; line-height: 1.8; }
.ysw-footer address a:hover { color: var(--ysw-ink); }
.ysw-footer .ysw-sns a { margin-left: 14px; }
.ysw-footer .ysw-sns a:hover { color: var(--ysw-point); }

@media (max-width: 960px) {
  .ysw-cardgrid { grid-template-columns: repeat(2, 1fr); }
  .ysw-grid3 { grid-template-columns: repeat(2, 1fr); }
  .ysw-grid2, .ysw-linkgrid { grid-template-columns: 1fr; }
  .ysw-nav { display: none; }
  .ysw-burger { display: flex; }
  .ysw-hero .ysw-herogrid { grid-template-columns: 1fr; }
  .ysw-hero .ysw-heroart { order: -1; max-width: 280px; margin: 0 auto; }
  .ysw-section .ysw-sectionhead { grid-template-columns: 1fr; }
  .ysw-section .ysw-sectionhead .ysw-headart { order: -1; }
  .ysw-doctorcard { grid-template-columns: 1fr; }
  .ysw-doctorcard .ysw-photo { max-width: 260px; margin: 0 auto; }
  .ysw-hero { padding-top: 10vw;}
  .col-writer, .col-date, .tb-writer, .tb-date {display: none;}
}

@media (min-width: 961px) {
  .ysw-drawer { display: none; }
}

@media (max-width: 620px) {
  .ysw-cardgrid { grid-template-columns: 1fr; }
  .ysw-grid3 { grid-template-columns: 1fr; }
  .ysw-step { grid-template-columns: 1fr; }
  .ysw-cta { padding: 48px 24px; }
  .datatable td.tb-subject {text-align: left;}
}