/* 네일마마 공용 디자인 — 모바일 우선, 넉넉한 여백 */
:root {
  --bg: #ffffff;
  --bg-soft: #faf6f7;
  --ink: #27242a;
  --ink-soft: #57505e;
  --line: #ece4e7;
  --primary: #b03a5b;
  --primary-dark: #8f2c48;
  --primary-ink: #ffffff;
  --accent: #2f6f6a;
  --radius: 8px;
  --cta-cycle: 4s;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Malgun Gothic", "Apple SD Gothic Neo", sans-serif;
  font-size: 16.5px;
  line-height: 1.78;
  letter-spacing: 0;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.wrap { max-width: 760px; margin: 0 auto; padding: 0 20px; }

/* 헤더 */
.site-header {
  border-bottom: 1px solid var(--line);
  background: var(--bg);
  position: sticky; top: 0; z-index: 40;
}
.site-header .wrap {
  display: flex; align-items: center; gap: 18px;
  padding-top: 12px; padding-bottom: 12px;
}
.brand {
  font-weight: 800; font-size: 19px; color: var(--primary);
  text-decoration: none; white-space: nowrap;
}
.brand span { color: var(--ink); font-weight: 600; font-size: 13px; margin-left: 6px; }
.site-nav { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; }
.site-nav::-webkit-scrollbar { display: none; }
.site-nav a {
  color: var(--ink-soft); text-decoration: none; font-size: 14.5px;
  padding: 6px 10px; border-radius: 6px; white-space: nowrap;
}
.site-nav a:hover { background: var(--bg-soft); color: var(--primary); }

/* 히어로 */
.hero { margin: 26px 0 10px; }
.hero img {
  width: 100%; height: auto; border-radius: var(--radius);
  display: block; aspect-ratio: 1200 / 630; object-fit: cover;
  background: var(--bg-soft);
}

/* 본문 타이포 */
h1 { font-size: 28px; line-height: 1.4; margin: 26px 0 10px; font-weight: 800; }
h2 { font-size: 21px; line-height: 1.5; margin: 44px 0 14px; font-weight: 800; }
h3 { font-size: 17.5px; margin: 30px 0 10px; font-weight: 700; }
p { margin: 18px 0; }
ul, ol { margin: 18px 0; padding-left: 22px; }
li { margin: 10px 0; }
strong { color: var(--ink); }
a { color: var(--primary); }

.meta {
  color: var(--ink-soft); font-size: 13.5px; margin: 6px 0 22px;
  display: flex; flex-wrap: wrap; gap: 4px 14px;
}

/* 리드 박스 — 핵심 하나만 */
.lead-box {
  background: var(--bg-soft);
  border-left: 4px solid var(--primary);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 20px 22px;
  margin: 24px 0 30px;
  font-size: 17px; line-height: 1.75;
}
.lead-box p { margin: 0; }

/* 표 */
.table-scroll { overflow-x: auto; margin: 22px 0; }
table {
  width: 100%; border-collapse: collapse; font-size: 15px;
  min-width: 520px;
}
th, td {
  border: 1px solid var(--line); padding: 12px 14px;
  text-align: left; vertical-align: top;
}
th { background: var(--bg-soft); font-weight: 700; }

/* 카드 */
.card-grid { display: grid; gap: 14px; margin: 24px 0; }
.card {
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px 22px; background: var(--bg);
}
.card h3 { margin-top: 0; }
.card p { margin: 10px 0 0; }

/* 링크 카드 (허브/관련글) */
.link-list { display: grid; gap: 12px; margin: 22px 0; }
.link-card {
  display: block; text-decoration: none; color: var(--ink);
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px 20px; transition: border-color .15s ease;
}
.link-card:hover { border-color: var(--primary); }
.link-card .t { font-weight: 700; font-size: 16px; display: block; }
.link-card .d { color: var(--ink-soft); font-size: 14px; display: block; margin-top: 4px; line-height: 1.6; }

/* CTA 버튼 — runner-pulse */
.cta-block { margin: 30px 0; }
.cta-button {
  position: relative; isolation: isolate;
  display: flex; width: 100%; min-height: 56px;
  align-items: center; justify-content: center;
  overflow: hidden;
  padding: 14px 20px;
  border: 2px solid var(--primary);
  border-radius: 6px;
  background: var(--primary);
  color: var(--primary-ink) !important;
  font-size: 16.5px; font-weight: 800; line-height: 1.5;
  text-align: center; text-decoration: none;
  cursor: pointer;
  animation: cta-soft-pulse var(--cta-cycle) ease-in-out infinite;
  transition: transform .18s ease, background-color .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.cta-button > span { position: relative; z-index: 2; }
.cta-button::after {
  content: ""; position: absolute; z-index: 1;
  top: -45%; bottom: -45%; left: -18%; width: 9%;
  background: #ffffff; opacity: 0;
  transform: skewX(-16deg); pointer-events: none;
  animation: cta-runner var(--cta-cycle) ease-in-out infinite;
}
.cta-button:hover {
  background: var(--primary-dark); border-color: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 5px 0 rgba(80, 15, 35, 0.25);
}
.cta-button:active { transform: translateY(1px); box-shadow: none; }
.cta-button:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
.cta-button:hover, .cta-button:focus-visible, .cta-button:active { animation: none; }
.cta-button:hover::after, .cta-button:focus-visible::after, .cta-button:active::after { opacity: 0; animation: none; }

@keyframes cta-runner {
  0%, 16% { left: -18%; opacity: 0; }
  22% { opacity: .25; }
  54% { left: 112%; opacity: .15; }
  60%, 100% { left: 112%; opacity: 0; }
}
@keyframes cta-soft-pulse {
  0%, 12%, 54%, 100% { box-shadow: 0 0 0 0 rgba(176, 58, 91, 0); }
  22% { box-shadow: 0 0 0 7px rgba(176, 58, 91, 0.16); }
  34% { box-shadow: 0 0 0 3px rgba(176, 58, 91, 0.09); }
}

/* 보조 CTA — 정적 */
.cta-secondary {
  display: flex; width: 100%; min-height: 50px;
  align-items: center; justify-content: center;
  padding: 12px 18px; margin: 14px 0;
  border: 1.5px solid var(--primary); border-radius: 6px;
  background: var(--bg); color: var(--primary) !important;
  font-size: 15.5px; font-weight: 700; text-decoration: none; text-align: center;
}
.cta-secondary:hover { background: var(--bg-soft); }

/* FAQ */
.faq-item { border-bottom: 1px solid var(--line); padding: 18px 0; }
.faq-item h3 { margin: 0 0 8px; font-size: 16.5px; }
.faq-item p { margin: 0; color: var(--ink-soft); }

/* 작성자/출처 */
.byline {
  margin: 40px 0 10px; padding: 18px 20px;
  border: 1px solid var(--line); border-radius: var(--radius);
  font-size: 14px; color: var(--ink-soft); line-height: 1.7;
}

/* 푸터 */
.site-footer {
  margin-top: 60px; border-top: 1px solid var(--line);
  background: var(--bg-soft);
  padding: 30px 0 110px;
  font-size: 13.5px; color: var(--ink-soft);
}
.site-footer a { color: var(--ink-soft); margin-right: 14px; }
.site-footer .biz { margin-top: 12px; line-height: 1.7; }

/* 모바일 스티키 / 플로팅 */
.nm-sticky {
  display: none;
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
  background: var(--primary);
  padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
  box-shadow: 0 -4px 18px rgba(60, 15, 30, 0.22);
}
.nm-sticky a {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  color: #fff; text-decoration: none;
  font-size: 15px; font-weight: 800; line-height: 1.4; text-align: center;
  min-height: 40px;
}
.nm-sticky.nm-floating {
  left: auto; right: 14px; bottom: 14px;
  border-radius: 999px; padding: 12px 20px;
}
.nm-sticky.nm-floating a { min-height: 0; font-size: 14px; }

@media (max-width: 768px) {
  body { font-size: 16px; }
  h1 { font-size: 24px; }
  h2 { font-size: 19.5px; margin-top: 40px; }
  .nm-sticky { display: block; }
  .nm-sticky.nm-hidden-initial { display: none; }
  .nm-sticky.nm-revealed { display: block; }
  .site-footer { padding-bottom: 130px; }
}

@media (prefers-reduced-motion: reduce) {
  .cta-button, .cta-button::after { animation: none; }
}
