/* =========================================================
   김정혜산부인과 — 디자인 시스템
   따뜻·부드러운 여성병원 (로즈–플럼 팔레트)
   ========================================================= */
@import url("https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.9/dist/web/static/pretendard.css");

:root {
  /* Brand */
  --plum:        #b0417e;   /* 로고 꽃 – 메인 포인트 */
  --plum-deep:   #8a2f63;
  --rose:        #e88aae;
  --rose-soft:   #f6dfe8;
  --rose-tint:   #fdf4f7;   /* 아주 옅은 배경 */
  --peach:       #f4c9a3;
  --cream:       #fbf7f3;

  /* Neutrals */
  --ink:         #2e2430;   /* 본문 텍스트 */
  --ink-soft:    #6b5f68;
  --line:        #efe4ea;
  --white:       #ffffff;

  /* System */
  --shadow-sm:   0 2px 10px rgba(138, 47, 99, .06);
  --shadow-md:   0 10px 30px rgba(138, 47, 99, .10);
  --shadow-lg:   0 24px 60px rgba(138, 47, 99, .14);
  --radius:      18px;
  --radius-lg:   28px;
  --maxw:        1120px;
  --gutter:      clamp(20px, 5vw, 48px);
  --font: "Pretendard", -apple-system, BlinkMacSystemFont, system-ui, "Segoe UI", Roboto, "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
}

/* ---------- Reset / Base ---------- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--white);
  line-height: 1.7;
  font-size: 17px;
  letter-spacing: -0.01em;
  word-break: keep-all;
  overflow-wrap: anywhere;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { line-height: 1.3; letter-spacing: -0.02em; margin: 0; font-weight: 700; }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }

/* ---------- Layout ---------- */
.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: clamp(64px, 9vw, 120px); }
.section--tint { background: var(--rose-tint); }
.section--cream { background: var(--cream); }

.section-head { text-align: center; max-width: 640px; margin: 0 auto clamp(36px, 5vw, 60px); }
.eyebrow {
  display: inline-block; font-size: .82rem; font-weight: 700; letter-spacing: .18em;
  color: var(--plum); text-transform: uppercase; margin-bottom: 14px;
}
.section-head h2 { font-size: clamp(1.7rem, 3.6vw, 2.5rem); color: var(--ink); }
.section-head p { margin-top: 16px; color: var(--ink-soft); font-size: 1.05rem; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 14px 26px; border-radius: 999px; font-weight: 700; font-size: 1rem;
  border: 1.5px solid transparent; cursor: pointer; transition: .22s ease; white-space: nowrap;
}
.btn--primary { background: var(--plum); color: #fff; box-shadow: 0 8px 20px rgba(176,65,126,.28); }
.btn--primary:hover { background: var(--plum-deep); transform: translateY(-2px); box-shadow: 0 12px 26px rgba(176,65,126,.34); }
.btn--ghost { background: #fff; color: var(--plum); border-color: var(--rose-soft); }
.btn--ghost:hover { border-color: var(--plum); background: var(--rose-tint); }
.btn--lg { padding: 17px 34px; font-size: 1.05rem; }

/* ---------- Header / Nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255,255,255,.86); backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 74px; }
.brand { display: flex; align-items: center; gap: 11px; font-weight: 800; font-size: 1.18rem; color: var(--ink); }
.brand img { width: 34px; height: 34px; }
.brand small { display: block; font-size: .64rem; font-weight: 600; color: var(--plum); letter-spacing: .12em; margin-top: 1px; }
.nav-links { display: flex; align-items: center; gap: 6px; }
.nav-links a { padding: 10px 15px; border-radius: 10px; font-weight: 600; color: var(--ink-soft); font-size: .98rem; transition: .18s; }
.nav-links a:hover { color: var(--plum); background: var(--rose-tint); }
.nav-cta { display: flex; align-items: center; gap: 12px; }
.nav-tel { font-weight: 800; color: var(--plum); font-size: 1.05rem; }
.nav-toggle { display: none; background: none; border: 0; width: 44px; height: 44px; cursor: pointer; }
.nav-toggle span { display: block; width: 24px; height: 2px; background: var(--ink); margin: 5px auto; border-radius: 2px; transition: .25s; }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background:
    radial-gradient(1200px 600px at 78% -8%, var(--rose-soft), transparent 60%),
    radial-gradient(900px 520px at 8% 108%, #fbe4d4, transparent 55%),
    var(--rose-tint);
}
.hero-inner { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(30px, 5vw, 64px); align-items: center; padding-block: clamp(56px, 8vw, 104px); }
.hero-copy .eyebrow { margin-bottom: 18px; }
.hero-copy h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); color: var(--ink); }
.hero-copy h1 .accent { color: var(--plum); }
.hero-copy .lead { margin-top: 22px; font-size: 1.12rem; color: var(--ink-soft); max-width: 46ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 26px; margin-top: 38px; }
.hero-meta div { font-size: .95rem; color: var(--ink-soft); }
.hero-meta strong { display: block; color: var(--ink); font-size: 1.05rem; margin-top: 2px; }

.hero-visual { position: relative; }
.hero-visual .photo {
  border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-lg);
  aspect-ratio: 4/3; border: 6px solid #fff;
}
.hero-visual .photo img { width: 100%; height: 100%; object-fit: cover; }
.hero-badge {
  position: absolute; left: -18px; bottom: 26px; background: #fff; border-radius: 16px;
  padding: 16px 20px; box-shadow: var(--shadow-md); display: flex; align-items: center; gap: 13px;
}
.hero-badge .mark { width: 42px; height: 42px; background: var(--rose-tint); border-radius: 12px; display: grid; place-items: center; }
.hero-badge .mark img { width: 26px; height: 26px; }
.hero-badge b { font-size: .98rem; }
.hero-badge span { display: block; font-size: .8rem; color: var(--ink-soft); }

/* ---------- Greeting ---------- */
.greeting-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(30px, 5vw, 60px); align-items: center; }
.greeting-photo { border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-md); aspect-ratio: 5/4; }
.greeting-photo img { width: 100%; height: 100%; object-fit: cover; }
.greeting-body h2 { font-size: clamp(1.6rem, 3.4vw, 2.3rem); }
.greeting-body .quote { margin-top: 20px; font-size: 1.15rem; color: var(--plum-deep); font-weight: 600; }
.greeting-body p { margin-top: 18px; color: var(--ink-soft); }
.sign { margin-top: 28px; font-size: 1rem; color: var(--ink-soft); }
.sign b { font-size: 1.3rem; color: var(--ink); font-weight: 700; margin-left: 8px; font-family: "Pretendard"; }

/* ---------- Service cards ---------- */
.card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 22px; }
.svc-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 30px 26px;
  box-shadow: var(--shadow-sm); transition: .24s ease; display: flex; flex-direction: column;
}
.svc-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); border-color: var(--rose-soft); }
.svc-card .ico { width: 56px; height: 56px; border-radius: 16px; background: var(--rose-tint); display: grid; place-items: center; margin-bottom: 18px; }
.svc-card .ico svg { width: 30px; height: 30px; stroke: var(--plum); fill: none; stroke-width: 1.7; }
.svc-card h3 { font-size: 1.25rem; }
.svc-card p { margin-top: 10px; color: var(--ink-soft); font-size: .97rem; flex: 1; }
.svc-card .tags { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 18px; }
.svc-card .tags span { font-size: .82rem; color: var(--plum-deep); background: var(--rose-tint); padding: 5px 11px; border-radius: 999px; }
.svc-card .more { margin-top: 20px; font-weight: 700; color: var(--plum); font-size: .95rem; }

/* ---------- Gallery ---------- */
.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.gallery figure { margin: 0; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); aspect-ratio: 3/2; cursor: pointer; position: relative; }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: .4s ease; }
.gallery figure:hover img { transform: scale(1.06); }
.gallery figcaption {
  position: absolute; inset: auto 0 0 0; padding: 22px 16px 12px; color: #fff; font-size: .92rem; font-weight: 600;
  background: linear-gradient(to top, rgba(46,36,48,.7), transparent);
}

/* ---------- Hours / Info ---------- */
.info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.info-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: clamp(26px, 4vw, 40px); box-shadow: var(--shadow-sm); }
.info-card h3 { font-size: 1.35rem; display: flex; align-items: center; gap: 10px; margin-bottom: 20px; }
.info-card h3 svg { width: 24px; height: 24px; stroke: var(--plum); fill: none; stroke-width: 1.7; }
.hours-row { display: flex; justify-content: space-between; padding: 12px 0; border-bottom: 1px dashed var(--line); }
.hours-row:last-child { border-bottom: 0; }
.hours-row .d { color: var(--ink-soft); }
.hours-row .t { font-weight: 700; }
.hours-row.off .t { color: var(--plum); }
.notice-pill { margin-top: 18px; background: var(--rose-tint); color: var(--plum-deep); border-radius: 12px; padding: 12px 16px; font-size: .92rem; font-weight: 600; }
.contact-line { display: flex; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line); align-items: flex-start; }
.contact-line:last-child { border-bottom: 0; }
.contact-line .k { flex: 0 0 74px; color: var(--ink-soft); font-size: .93rem; }
.contact-line .v { font-weight: 600; }
.contact-line .v a.tel { color: var(--plum); font-weight: 800; font-size: 1.15rem; }

/* ---------- CTA band ---------- */
.cta-band { background: linear-gradient(120deg, var(--plum), var(--plum-deep)); color: #fff; border-radius: var(--radius-lg); padding: clamp(36px, 6vw, 64px); text-align: center; box-shadow: var(--shadow-md); }
.cta-band h2 { font-size: clamp(1.5rem, 3.4vw, 2.2rem); }
.cta-band p { margin-top: 14px; opacity: .92; }
.cta-band .btn--primary { background: #fff; color: var(--plum); margin-top: 26px; box-shadow: 0 10px 24px rgba(0,0,0,.18); }
.cta-band .btn--primary:hover { background: var(--rose-tint); }

/* ---------- Footer ---------- */
.site-footer { background: #2a2130; color: #cabfc7; padding-block: 54px 30px; font-size: .93rem; }
.footer-top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 30px; padding-bottom: 30px; border-bottom: 1px solid rgba(255,255,255,.1); }
.footer-brand { display: flex; align-items: center; gap: 12px; color: #fff; font-weight: 800; font-size: 1.2rem; }
.footer-brand img { width: 36px; height: 36px; }
.footer-info { line-height: 2; }
.footer-info a { color: #fff; }
.footer-bottom { padding-top: 22px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; color: #8f8291; font-size: .86rem; }

/* ---------- Subpage (진료안내 상세) ---------- */
.subhero { background: var(--rose-tint); padding-block: clamp(48px, 7vw, 88px) clamp(40px, 5vw, 60px); }
.breadcrumb { font-size: .9rem; color: var(--ink-soft); margin-bottom: 16px; }
.breadcrumb a:hover { color: var(--plum); }
.subhero h1 { font-size: clamp(1.9rem, 4.4vw, 3rem); }
.subhero p { margin-top: 16px; color: var(--ink-soft); font-size: 1.08rem; max-width: 60ch; }
.topic { display: grid; grid-template-columns: 200px 1fr; gap: 28px; padding: 30px 0; border-bottom: 1px solid var(--line); }
.topic:last-child { border-bottom: 0; }
.topic h3 { font-size: 1.3rem; color: var(--plum-deep); }
.topic .body p + p { margin-top: 12px; }
.topic .body { color: var(--ink-soft); }
.disclaimer { margin-top: 40px; font-size: .88rem; color: var(--ink-soft); background: var(--cream); border-radius: 14px; padding: 18px 22px; }

/* ---------- Lightbox ---------- */
.lightbox { position: fixed; inset: 0; background: rgba(30,20,30,.9); display: none; place-items: center; z-index: 1000; padding: 24px; }
.lightbox.open { display: grid; }
.lightbox img { max-width: min(92vw, 1000px); max-height: 86vh; border-radius: 12px; box-shadow: var(--shadow-lg); }
.lightbox button { position: absolute; top: 22px; right: 26px; background: none; border: 0; color: #fff; font-size: 2.2rem; cursor: pointer; line-height: 1; }

/* ---------- Reveal animation ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } html { scroll-behavior: auto; } }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero-inner, .greeting-grid, .info-grid { grid-template-columns: 1fr; }
  .hero-visual { order: -1; max-width: 460px; margin-inline: auto; }
  .greeting-photo { max-width: 460px; }
  .gallery { grid-template-columns: repeat(2, 1fr); }
  .topic { grid-template-columns: 1fr; gap: 8px; }
}
@media (max-width: 720px) {
  body { font-size: 16px; }
  .nav-links, .nav-tel { display: none; }
  .nav-toggle { display: block; }
  .site-header.open .nav-links {
    display: flex; position: absolute; top: 74px; left: 0; right: 0; flex-direction: column; gap: 0;
    background: #fff; border-bottom: 1px solid var(--line); padding: 10px var(--gutter) 18px; box-shadow: var(--shadow-md);
  }
  .site-header.open .nav-links a { padding: 14px 6px; border-bottom: 1px solid var(--line); border-radius: 0; }
  .site-header.open .nav-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .site-header.open .nav-toggle span:nth-child(2) { opacity: 0; }
  .site-header.open .nav-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .hero-badge { left: 50%; transform: translateX(-50%); bottom: -22px; }
  .hero-visual { margin-bottom: 30px; }
}
@media (max-width: 460px) {
  .gallery { grid-template-columns: 1fr; }
  .hero-actions .btn { flex: 1; justify-content: center; }
}
