﻿/* ==========================================================
   MJIT세무회계사무소 — 차분한 의료 블루
   한 가지 서체(IBM Plex Sans KR), 강조는 '세무 처방전' 한 곳에만
   ========================================================== */
:root {
  --bg: #f7fafd;
  --surface: #ffffff;
  --rx: #1f5a96;
  --rx-deep: #17487a;
  --navy: #14304f;
  --body: #2e3d4f;
  --muted: #5b6b7d;
  --wash: #e9f1f9;
  --line: #d5e1ec;
  --font: 'IBM Plex Sans KR', 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
}

body.mjit-body {
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.75;
  color: var(--body);
  background: var(--bg);
  word-break: keep-all;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { color: var(--navy); letter-spacing: -0.02em; }
.text-navy { color: var(--navy) !important; }

a:focus-visible,
button:focus-visible,
summary:focus-visible { outline: 2px solid var(--rx); outline-offset: 3px; border-radius: 4px; }

.skip-link {
  position: absolute;
  left: 1rem;
  top: -3rem;
  z-index: 100;
  padding: .5rem .9rem;
  background: var(--navy);
  color: #fff;
  border-radius: 6px;
}
.skip-link:focus { top: .75rem; }

/* ---------- 헤더 ---------- */
.site-header {
  background: rgba(255, 255, 255, .96);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; flex-direction: column; line-height: 1.25; }
.brand-name { font-weight: 700; font-size: 1.125rem; color: var(--navy); letter-spacing: -0.02em; }
.brand-sub { font-size: .8125rem; color: var(--rx); font-weight: 500; }

.nav-link {
  display: inline-block;
  padding: .4rem .65rem;
  font-size: .9375rem;
  color: var(--body);
  border-radius: 6px;
}
.nav-link:hover { color: var(--rx); background: var(--wash); }
.nav-link-active { color: var(--rx); font-weight: 600; box-shadow: inset 0 -2px 0 var(--rx); border-radius: 0; }
.nav-link-active:hover { background: transparent; }

.header-tel { font-weight: 600; color: var(--navy); font-variant-numeric: tabular-nums; }
.header-tel:hover { color: var(--rx); }

.menu-btn {
  border: 1px solid var(--line);
  padding: .4rem .8rem;
  border-radius: 6px;
  font-size: .9375rem;
  font-weight: 500;
  color: var(--navy);
  background: var(--surface);
}
.mobile-menu { border-top: 1px solid var(--line); background: var(--surface); }
.mobile-menu .nav-link { padding: .75rem .25rem; border-bottom: 1px solid var(--line); border-radius: 0; box-shadow: none; }

/* ---------- 버튼 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  padding: .8rem 1.25rem;
  font-weight: 600;
  line-height: 1.3;
  border: 1px solid transparent;
  transition: background-color .15s ease, border-color .15s ease;
}
.btn-sm { padding: .55rem .9rem; font-size: .9375rem; }
.btn-primary { background: var(--rx); color: #fff; }
.btn-primary:hover { background: var(--rx-deep); }
.btn-secondary { background: var(--surface); color: var(--navy); border-color: var(--line); }
.btn-secondary:hover { border-color: var(--rx); color: var(--rx); }
.btn-on-dark { background: #fff; color: var(--navy); }
.btn-on-dark:hover { background: var(--wash); }
/* 서브페이지 어두운 영역용 (기존 클래스 유지) */
.btn-outline { background: transparent; border-color: rgba(255,255,255,.5); color: #fff; }

/* ---------- 공통 블록 (서브페이지 호환) ---------- */
.panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
}
.sub-hero {
  background: var(--navy);
  color: #fff;
  border-radius: 8px;
}
.sub-hero h1, .sub-hero h2 { color: #fff; font-weight: 700; }
main h1.font-extrabold, main h2.font-extrabold { font-weight: 700; }

/* ---------- 홈: 첫 화면 ---------- */
.home-hero { background: var(--surface); border-bottom: 1px solid var(--line); }
.home-hero h1 { font-size: clamp(1.95rem, 4.2vw, 2.75rem); line-height: 1.3; font-weight: 700; letter-spacing: -0.035em; }
.lead { font-size: 1.0625rem; line-height: 1.85; max-width: 36em; }

.facts { display: flex; flex-wrap: wrap; gap: 1.25rem 2.25rem; padding-top: 1.5rem; border-top: 1px solid var(--line); }
.facts dt { font-size: .8125rem; color: var(--muted); }
.facts dd { font-weight: 600; color: var(--navy); }

/* 세무 처방전: 실제 처방전 양식의 칸 구조를 빌린다 */
.rx-form {
  background: var(--surface);
  border: 1.5px solid var(--rx);
  border-radius: 4px;
  font-size: .9375rem;
  box-shadow: 0 1px 2px rgba(20, 48, 79, .06), 0 12px 32px -18px rgba(20, 48, 79, .28);
}
.rx-title {
  padding: 1rem 1rem .85rem;
  text-align: center;
  font-size: 1.375rem;
  font-weight: 700;
  letter-spacing: .6em;
  text-indent: .6em;
  color: var(--navy);
  border-bottom: 1.5px solid var(--rx);
}
.rx-meta { display: grid; grid-template-columns: 6.5rem 1fr; border-bottom: 1.5px solid var(--rx); }
.rx-meta dt, .rx-meta dd { padding: .55rem .8rem; border-bottom: 1px solid var(--line); }
.rx-meta dt { background: var(--wash); color: var(--rx); font-weight: 600; font-size: .875rem; border-right: 1px solid var(--line); }
.rx-meta dd { color: var(--navy); font-weight: 500; }
.rx-meta dt:nth-last-of-type(1), .rx-meta dd:nth-last-of-type(1) { border-bottom: 0; }

.rx-table { width: 100%; border-collapse: collapse; }
.rx-table caption { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.rx-table th {
  background: var(--wash);
  color: var(--rx);
  font-weight: 600;
  font-size: .8125rem;
  text-align: left;
  padding: .5rem .8rem;
  border-bottom: 1px solid var(--rx);
}
.rx-table td { padding: .6rem .8rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.rx-table th + th, .rx-table td + td { border-left: 1px solid var(--line); }
.rx-table td:first-child { color: var(--navy); font-weight: 600; }
.rx-table td:last-child { font-variant-numeric: tabular-nums; white-space: nowrap; }
.rx-note { padding: .75rem .8rem .85rem; font-size: .8125rem; line-height: 1.6; color: var(--muted); }

/* ---------- 홈: 본문 섹션 ---------- */
.section { padding: 4.5rem 0; }
.section + .section { border-top: 1px solid var(--line); }
.section-title { font-size: clamp(1.5rem, 2.8vw, 1.875rem); font-weight: 700; line-height: 1.4; }

.issue-list > div { padding: 1.1rem 0; border-bottom: 1px solid var(--line); }
.issue-list > div:first-child { border-top: 1px solid var(--line); }
.issue-list dt { font-weight: 600; color: var(--navy); font-size: 1.0625rem; }
.issue-list dd { margin-top: .25rem; color: var(--body); }

.service-rows { border-top: 1.5px solid var(--navy); }
.service-rows li { border-bottom: 1px solid var(--line); }
.service-rows a {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: .15rem 1.5rem;
  padding: 1.15rem .25rem;
}
.service-rows a:hover .svc-name { color: var(--rx); }
.svc-name { font-weight: 600; color: var(--navy); font-size: 1.0625rem; }
.svc-desc { grid-column: 1; color: var(--muted); font-size: .9375rem; }
.svc-more { grid-column: 2; grid-row: 1 / span 2; align-self: center; font-size: .875rem; color: var(--rx); font-weight: 500; white-space: nowrap; }
@media (min-width: 768px) {
  .service-rows a { grid-template-columns: 16rem 1fr auto; align-items: baseline; }
  .svc-desc { grid-column: 2; }
  .svc-more { grid-column: 3; grid-row: 1; }
}

/* ---------- FAQ ---------- */
.faq-list { border-top: 1.5px solid var(--navy); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-item summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 1.1rem .25rem;
  cursor: pointer;
  list-style: none;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary h3 { font-size: 1.0625rem; font-weight: 600; line-height: 1.5; }
.faq-item summary:after {
  content: '';
  flex: none;
  width: .6rem;
  height: .6rem;
  border-right: 2px solid var(--rx);
  border-bottom: 2px solid var(--rx);
  transform: rotate(45deg) translateY(-3px);
  transition: transform .2s ease;
}
.faq-item[open] summary:after { transform: rotate(-135deg) translateY(-2px); }
.faq-item summary:hover h3 { color: var(--rx); }
.faq-item p { padding: 0 .25rem 1.4rem; max-width: 46em; }

/* ---------- 상담 안내 ---------- */
.consult-band { background: var(--wash); border-top: 1px solid var(--line); }

/* ---------- 폼 (consult.asp) ---------- */
.mjit-body input[type=text],
.mjit-body input[type=email],
.mjit-body textarea { background: #fff; }
.mjit-body input[type=text]:focus,
.mjit-body input[type=email]:focus,
.mjit-body textarea:focus { outline: none; border-color: var(--rx); box-shadow: 0 0 0 3px rgba(31, 90, 150, .18); }
.mjit-body input[type=checkbox] { accent-color: var(--rx); }

/* ---------- 푸터 ---------- */
.site-footer { margin-top: 0; background: var(--navy); color: #c9d5e2; }
.site-footer a { color: #fff; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: rgba(255,255,255,.35); }
.site-footer a.btn { text-decoration: none; color: var(--navy); }
.footer-name { color: #fff; font-weight: 700; font-size: 1.125rem; }
.footer-links { display: grid; gap: .4rem; }
.footer-copy { border-top: 1px solid rgba(255,255,255,.12); text-align: center; font-size: .8125rem; padding: 1rem; color: #93a4b8; }

/* 서브페이지 main 과 푸터 사이 간격 */
main + .site-footer { margin-top: 0; }
main.max-w-6xl, main.max-w-4xl { padding-bottom: 5rem; }

@media (prefers-reduced-motion: reduce) {
  .btn, .faq-item summary:after { transition: none; }
}

@media (max-width: 767px) {
  .section { padding: 3.25rem 0; }
  .rx-title { font-size: 1.2rem; letter-spacing: .4em; text-indent: .4em; }
  .rx-meta { grid-template-columns: 5.5rem 1fr; }
}
