/* ===== Design tokens (네이비 클래식) ===== */
:root {
  --navy: #1b2a4a;
  --navy-medium: #3e5c94;
  --navy-dark: #14213a;
  --gold: #c9a961;
  --gold-dark: #a67d42;
  --gray-900: #1b1e24;
  --gray-700: #4a5060;
  --gray-500: #7a8090;
  --gray-300: #d8dbe2;
  --gray-100: #f5f6f8;
  --white: #ffffff;
  --radius: 10px;
  --shadow: 0 6px 24px rgba(27, 42, 74, 0.08);
  --shadow-lg: 0 12px 40px rgba(27, 42, 74, 0.14);
  --max-width: 1120px;
  --font: "Pretendard", "Malgun Gothic", "Apple SD Gothic Neo", -apple-system, BlinkMacSystemFont, sans-serif;
  --font-serif: "Noto Serif KR", "Nanum Myeongjo", "Batang", serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  overflow-x: hidden;
  max-width: 100%;

  margin: 0;
  font-family: var(--font);
  color: var(--gray-900);
  line-height: 1.7;
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  word-break: keep-all;
}

img { max-width: 100%; display: block; }
a { overflow-wrap: anywhere; }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* ===== Header ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--gray-300);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  gap: 16px;
}

.logo {
  display: flex;
  align-items: baseline;
  gap: 10px;
  text-decoration: none;
  white-space: nowrap;
}

.logo-word {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--navy);
  letter-spacing: -0.01em;
}

.logo-prefix {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--gold-dark);
  letter-spacing: -0.01em;
}

.main-nav {
  display: flex;
  gap: 28px;
  flex: 1;
  justify-content: center;
}

.main-nav a {
  color: var(--gray-700);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  white-space: nowrap;
}

.main-nav a:hover { color: var(--navy); }

.header-call {
  white-space: nowrap;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}

.nav-toggle span {
  display: block;
  height: 2px;
  background: var(--navy);
  border-radius: 2px;
}

/* ===== Buttons ===== */
.btn {
  display: inline-block;
  padding: 13px 26px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.btn:hover { transform: translateY(-2px); }

.btn-primary {
  background: var(--navy);
  color: var(--white);
  box-shadow: var(--shadow);
}
.btn-primary:hover { background: var(--navy-dark); }

.btn-outline {
  background: transparent;
  color: var(--navy);
  border-color: var(--navy);
}
.btn-outline:hover { background: var(--navy); color: var(--white); }

.btn-kakao {
  background: #fee500;
  color: #391b1b;
}
.btn-kakao:hover { background: #f5d900; }

.btn-call {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--white);
  color: var(--gray-900);
  border-color: var(--gray-300);
  padding: 10px 14px;
}
.btn-call:hover { background: var(--gray-100); }

.cta-group {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

/* ===== Hero ===== */
.hero {
  position: relative;
  min-height: 62vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  color: var(--white);
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    linear-gradient(115deg, rgba(20,33,58,0.72) 0%, rgba(27,42,74,0.5) 42%, rgba(62,92,148,0.38) 100%),
    repeating-linear-gradient(90deg, rgba(255,255,255,0.05) 0, rgba(255,255,255,0.05) 1px, transparent 1px, transparent 120px),
    linear-gradient(135deg, #14213a 0%, #1b2a4a 45%, #3e5c94 100%);
}

.hero-art {
  position: absolute;
  right: -60px;
  bottom: -40px;
  width: min(56vw, 640px);
  height: auto;
}

.hero-inner {
  position: relative;
  z-index: 1;
  max-width: 720px;
}

.hero-inner h1 {
  font-family: var(--font-serif);
  font-size: 2.7rem;
  line-height: 1.4;
  color: var(--white);
  font-weight: 700;
  margin: 0 0 20px;
  letter-spacing: -0.01em;
}

.hero-inner h1 .hl {
  color: var(--gold);
}

.hero-trust {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 28px;
  margin: 28px 0 0;
  padding: 0;
}

.hero-trust li {
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.88rem;
  font-weight: 500;
}

.hero-desc {
  font-size: 1.05rem;
  color: rgba(255,255,255,0.86);
  margin: 0;
}

.btn-outline-dark {
  color: var(--white);
  border-color: rgba(255,255,255,0.6);
}
.btn-outline-dark:hover { background: var(--white); color: var(--navy); }

.hero-scroll {
  position: absolute;
  right: 32px;
  bottom: 28px;
  z-index: 1;
  writing-mode: vertical-rl;
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  color: rgba(255,255,255,0.7);
}

/* ===== Sections ===== */
.section { padding: 88px 0; }
.section-alt { background: var(--gray-100); }

.section-title {
  font-family: var(--font-serif);
  font-size: 1.9rem;
  font-weight: 700;
  color: var(--navy);
  text-align: center;
  margin: 0 0 48px;
  letter-spacing: -0.01em;
}

.subsection-title {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--navy);
  margin: 64px 0 28px;
  text-align: center;
}

.section-note {
  color: var(--gray-500);
  font-size: 0.92rem;
  text-align: center;
  max-width: 720px;
  margin: 0 auto 32px;
}

/* ===== About ===== */
.about-grid {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 48px;
  align-items: start;
}

.about-photo img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.about-content h3 {
  font-family: var(--font-serif);
  font-weight: 700;
  color: var(--navy);
  font-size: 1.4rem;
  margin-top: 0;
}

.info-table {
  width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
  margin: 20px 0 24px;
}

.info-table th, .info-table td {
  text-align: left;
  padding: 12px 16px;
  border-bottom: 1px solid var(--gray-300);
  font-size: 0.95rem;
  overflow-wrap: anywhere;
}

.info-table th {
  width: 110px;
  color: var(--gray-500);
  font-weight: 600;
  background: var(--gray-100);
}

.career-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.career-item {
  font-size: 0.95rem;
}

.reason-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.reason-card {
  background: var(--white);
  border: 1px solid var(--gray-300);
  border-radius: var(--radius);
  padding: 28px;
}

.reason-card h4 {
  font-family: var(--font-serif);
  font-weight: 700;
  color: var(--navy);
  margin: 0 0 12px;
  font-size: 1.08rem;
}

.reason-card p { margin: 0 0 10px; color: var(--gray-700); font-size: 0.95rem; }

.reason-note {
  color: var(--gold-dark) !important;
  font-size: 0.88rem !important;
  font-style: italic;
  margin: 0 !important;
}

/* ===== Practice areas ===== */
.practice-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.practice-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 32px 24px;
  box-shadow: var(--shadow);
}

.practice-icon { font-size: 1.8rem; }

.practice-card h3 {
  font-family: var(--font-serif);
  font-weight: 700;
  color: var(--navy);
  font-size: 1.05rem;
  margin: 14px 0 16px;
}

.practice-card ul {
  margin: 0;
  padding-left: 18px;
  color: var(--gray-700);
  font-size: 0.88rem;
}

.practice-card li { margin-bottom: 8px; }

/* ===== Cases ===== */
.case-filter {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin: 0 0 36px;
}

.info-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 0 0 36px;
}

.info-toolbar .case-filter {
  margin: 0;
  justify-content: flex-start;
}

.info-search {
  position: relative;
  flex-shrink: 0;
}

.info-search-icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 0.85rem;
  opacity: 0.55;
  pointer-events: none;
}

.info-search input {
  width: 260px;
  max-width: 100%;
  padding: 10px 18px 10px 40px;
  border: 1.5px solid var(--gray-300);
  border-radius: 100px;
  font-size: 0.9rem;
  font-family: inherit;
  background: var(--white);
  color: var(--gray-900);
}

.info-search input:focus {
  outline: none;
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(27, 42, 74, 0.08);
}

.filter-btn {
  background: var(--white);
  border: 1.5px solid var(--gray-300);
  color: var(--gray-700);
  font-weight: 600;
  font-size: 0.9rem;
  padding: 10px 20px;
  border-radius: 100px;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.filter-btn:hover { border-color: var(--navy); }

.filter-btn.active {
  background: var(--navy);
  border-color: var(--navy);
  color: var(--white);
}

/* ===== Feed cards (성공사례 / 법률정보 - 블로그 실시간 연동) ===== */
.feed-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.feed-status {
  grid-column: 1 / -1;
  text-align: center;
  color: var(--gray-500);
  font-size: 0.9rem;
  padding: 24px 0;
}

.feed-status.is-hidden { display: none; }

.feed-card {
  display: block;
  background: var(--white);
  border: 1px solid var(--gray-300);
  border-radius: var(--radius);
  padding: 24px;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.feed-card.is-hidden { display: none; }

.feed-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.feed-tag {
  display: inline-block;
  background: var(--navy);
  color: var(--white);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 100px;
  margin: 0 0 12px;
}

.feed-card h4 {
  font-family: var(--font-serif);
  font-weight: 700;
  color: var(--navy);
  margin: 0 0 10px;
  font-size: 1.02rem;
  line-height: 1.5;
}

.feed-summary {
  font-size: 0.88rem;
  color: var(--gray-700);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.feed-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-top: 14px;
  font-size: 0.8rem;
  color: var(--gray-500);
}

.feed-meta .feed-link {
  color: var(--gold-dark);
  font-weight: 600;
  white-space: nowrap;
}

.feed-more {
  text-align: center;
  margin-top: 32px;
}

/* ===== Media ===== */
.media-cards {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.media-cards-solo {
  max-width: 640px;
  margin: 0 auto;
}

.media-card {
  display: block;
  background: var(--white);
  border: 1px solid var(--gray-300);
  border-radius: var(--radius);
  padding: 22px 24px;
  text-decoration: none;
  box-shadow: var(--shadow);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.media-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

.media-card-tag {
  display: inline-block;
  background: var(--gray-100);
  color: var(--gold-dark);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 3px 10px;
  border-radius: 100px;
  margin-bottom: 10px;
}

.media-card h4 {
  font-family: var(--font-serif);
  font-weight: 700;
  margin: 0 0 12px;
  color: var(--navy);
  font-size: 1rem;
  line-height: 1.5;
}

.media-card-link {
  color: var(--gold-dark);
  font-size: 0.85rem;
  font-weight: 600;
}

/* ===== Process ===== */
.process-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 16px;
  max-width: 720px;
  margin: 0 auto;
}

.process-list li {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  background: var(--gray-100);
  border-radius: var(--radius);
  padding: 20px 24px;
}

.step-num {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--navy);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.95rem;
}

.process-list h4 { font-family: var(--font-serif); font-weight: 700; margin: 4px 0 4px; color: var(--navy); font-size: 1rem; }
.process-list p { margin: 0; color: var(--gray-700); font-size: 0.9rem; }

/* ===== Location ===== */
.office-photo {
  max-width: 640px;
  aspect-ratio: 16 / 10;
  margin: 0 auto 28px;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--gray-300);
  box-shadow: var(--shadow);
}

.office-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.location-box { max-width: 640px; margin: 0 auto; text-align: center; }
.location-name { font-family: var(--font-serif); font-weight: 700; font-size: 1.15rem; color: var(--navy); margin: 0 0 8px; }
.location-address { font-size: 1rem; color: var(--gray-700); margin: 0 0 16px; }
.location-notes { list-style: none; padding: 0; margin: 0 0 20px; color: var(--gray-500); font-size: 0.9rem; }
.location-notes li { margin-bottom: 6px; }

.map-embed {
  max-width: 640px;
  height: 360px;
  margin: 28px auto;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--gray-300);
  box-shadow: var(--shadow);
}

/* ===== Contact / Survey form ===== */
.contact-section { text-align: center; }
.contact-lead { color: var(--gray-700); font-size: 1.1rem; margin-bottom: 36px; }
.contact-section .section-note { margin-top: 0; }

.consult-form {
  max-width: 640px;
  margin: 0 auto 40px;
  text-align: left;
  background: var(--white);
  border: 1px solid var(--gray-300);
  border-radius: var(--radius);
  padding: 40px;
}

.form-section {
  border: none;
  padding: 0;
  margin: 0 0 36px;
}

.form-section legend {
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--navy);
  margin-bottom: 18px;
  padding: 0;
}

.form-row { margin-bottom: 18px; }

.form-row label,
.form-label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--gray-700);
  margin-bottom: 8px;
}

.req { color: #c0392b; }

.form-row input[type="text"],
.form-row input[type="tel"],
.form-row input[type="email"],
.form-row select,
.form-row textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--gray-300);
  border-radius: 8px;
  font-size: 0.95rem;
  font-family: inherit;
  background: var(--white);
  color: var(--gray-900);
}

.form-row textarea { resize: vertical; }

.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
  outline: none;
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(27, 42, 74, 0.08);
}

.chip-group {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 10px 18px;
  border: 1.5px solid var(--gray-300);
  border-radius: 100px;
  font-weight: 500;
  font-size: 0.88rem;
  color: var(--gray-700);
  background: var(--white);
  cursor: pointer;
  user-select: none;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.chip input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.chip:hover { border-color: var(--navy); }
.chip:focus-within { outline: 2px solid var(--navy); outline-offset: 2px; }

.chip.is-checked {
  background: var(--navy);
  border-color: var(--navy);
  color: var(--white);
  font-weight: 600;
}

.chip-group-lg .chip { padding: 12px 20px; font-size: 0.92rem; }

.checkbox-row label {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-weight: 500;
  font-size: 0.9rem;
  color: var(--gray-900);
}

.case-detail {
  border-left: 3px solid var(--gold);
  padding: 4px 0 4px 20px;
  margin: 16px 0;
}

.btn-submit {
  width: 100%;
  text-align: center;
  font-size: 1rem;
  padding: 16px;
}

.form-hint {
  text-align: center;
  color: var(--gray-500);
  font-size: 0.82rem;
  margin-top: 12px;
}

.form-status {
  text-align: center;
  font-size: 0.92rem;
  font-weight: 600;
  margin-top: 16px;
  padding: 12px 16px;
  border-radius: 8px;
}

.form-status.is-success {
  color: #1a7a4c;
  background: #e8f7ef;
}

.form-status.is-error {
  color: #a3283c;
  background: #fdecee;
}

.contact-alt { text-align: center; }
.contact-alt p { color: var(--gray-500); margin-bottom: 16px; font-size: 0.9rem; }
.contact-alt .cta-group { justify-content: center; }

/* ===== FAQ ===== */
.faq-list { max-width: 760px; margin: 0 auto; }

.faq-item {
  background: var(--white);
  border: 1px solid var(--gray-300);
  border-radius: var(--radius);
  padding: 18px 24px;
  margin-bottom: 14px;
}

.faq-item summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--navy);
  list-style: none;
  position: relative;
  padding-right: 28px;
}

.faq-item summary::-webkit-details-marker { display: none; }

.faq-item summary::after {
  content: "+";
  position: absolute;
  right: 0;
  top: -2px;
  font-size: 1.3rem;
  color: var(--gold-dark);
}

.faq-item[open] summary::after { content: "−"; }

.faq-item p {
  margin: 14px 0 0;
  color: var(--gray-700);
  font-size: 0.93rem;
}

/* ===== Footer ===== */
.site-footer {
  background: var(--navy-dark);
  color: var(--gray-300);
  padding: 32px 0;
  text-align: center;
  font-size: 0.85rem;
}

.site-footer p { margin: 0 0 8px; }
.footer-disclaimer { color: #6b7690; font-size: 0.78rem; }

.footer-call {
  color: inherit;
  text-decoration: none;
  font-size: 1rem;
  vertical-align: middle;
}

.footer-link {
  color: inherit;
  text-decoration: underline;
}
.footer-link:hover { color: var(--gold); }

/* ===== Mobile call FAB ===== */
.mobile-call-fab {
  display: none;
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--gold);
  color: var(--white);
  text-decoration: none;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  box-shadow: var(--shadow-lg);
  z-index: 90;
}

/* ===== Responsive ===== */
@media (max-width: 1180px) and (min-width: 901px) {
  .logo-word { font-size: 1.05rem; }
  .logo-prefix { font-size: 0.85rem; }
  .main-nav { gap: 16px; }
  .main-nav a { font-size: 0.88rem; }
  .header-call { padding: 8px 14px; font-size: 0.85rem; }
}

@media (max-width: 900px) {
  .main-nav {
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    background: var(--white);
    flex-direction: column;
    padding: 12px 24px 20px;
    gap: 4px;
    border-bottom: 1px solid var(--gray-300);
    transform: translateY(-150%);
    opacity: 0;
    transition: transform 0.2s ease, opacity 0.2s ease;
  }
  .main-nav.open { transform: translateY(0); opacity: 1; }
  .main-nav a { padding: 12px 0; border-bottom: 1px solid var(--gray-100); }
  .nav-toggle { display: flex; }
  .header-call { display: none; }

  .hero { min-height: 53vh; }
  .hero-inner h1 { font-size: 2rem; }
  .hero-art { width: 80vw; opacity: 0.7; }
  .hero-scroll { display: none; }

  .about-grid { grid-template-columns: 1fr; }
  .about-photo { max-width: 260px; margin: 0 auto; }

  .reason-grid { grid-template-columns: 1fr; }
  .practice-grid { grid-template-columns: repeat(2, 1fr); }
  .feed-grid { grid-template-columns: 1fr; }

  .info-toolbar { flex-direction: column; align-items: stretch; }
  .info-search input { width: 100%; }

  .section { padding: 64px 0; }
  .mobile-call-fab { display: flex; }
}

@media (max-width: 560px) {
  .practice-grid { grid-template-columns: 1fr; }
  .hero-inner h1 { font-size: 1.7rem; }
  .cta-group { flex-direction: column; }
  .cta-group .btn { text-align: center; }
  .consult-form { padding: 24px; }
  .map-embed { height: 280px; }
}
