/* ==========================================================================
   (주)우리끼리 — bahnauto.kr
   ========================================================================== */

:root {
  --bg: #ffffff;
  --bg-alt: #f6f7f9;
  --fg: #17191c;
  --fg-muted: #5c6470;
  --border: #e3e6ea;
  --accent: #1f5fd8;
  --accent-fg: #ffffff;
  --radius: 12px;
  --wrap: 1120px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1216;
    --bg-alt: #161a20;
    --fg: #e9edf2;
    --fg-muted: #99a3b0;
    --border: #262c34;
    --accent: #6aa1ff;
    --accent-fg: #0f1216;
  }
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo",
    "Pretendard", "Noto Sans KR", "Malgun Gothic", "맑은 고딕", sans-serif;
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  word-break: keep-all;
}

a { color: inherit; }

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

.skip-link {
  position: absolute;
  left: -9999px;
}
.skip-link:focus {
  left: 16px;
  top: 16px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--accent);
  color: var(--accent-fg);
  border-radius: 8px;
}

/* ---------- header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.brand-mark {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  background: var(--accent);
  flex: none;
}

.nav {
  display: flex;
  gap: 28px;
  font-size: 15px;
  color: var(--fg-muted);
}

.nav a {
  text-decoration: none;
  transition: color 0.15s ease;
}

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

/* ---------- hero ---------- */

.hero {
  padding: 112px 0 96px;
  border-bottom: 1px solid var(--border);
}

.eyebrow {
  margin: 0 0 16px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.18em;
  color: var(--accent);
}

.hero-title {
  margin: 0 0 20px;
  font-size: clamp(32px, 5.2vw, 52px);
  line-height: 1.25;
  letter-spacing: -0.02em;
  font-weight: 700;
  max-width: 18ch;
}

.hero-desc {
  margin: 0 0 36px;
  max-width: 52ch;
  font-size: 17px;
  color: var(--fg-muted);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 48px;
  padding: 0 26px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  transition: opacity 0.15s ease, background 0.15s ease;
}

.btn-primary {
  background: var(--accent);
  color: var(--accent-fg);
}
.btn-primary:hover { opacity: 0.88; }

.btn-ghost {
  border-color: var(--border);
  color: var(--fg);
}
.btn-ghost:hover { background: var(--bg-alt); }

/* ---------- sections ---------- */

.section { padding: 96px 0; }

.section-alt {
  background: var(--bg-alt);
  border-block: 1px solid var(--border);
}

.section-label {
  margin: 0 0 10px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.18em;
  color: var(--accent);
}

.section-title {
  margin: 0 0 40px;
  font-size: clamp(26px, 3.4vw, 34px);
  letter-spacing: -0.02em;
  font-weight: 700;
}

.section-desc {
  margin: -24px 0 32px;
  max-width: 54ch;
  color: var(--fg-muted);
}

/* ---------- about ---------- */

.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 56px;
  align-items: start;
}

.about-body p {
  margin: 0 0 18px;
  color: var(--fg-muted);
  font-size: 17px;
}
.about-body strong { color: var(--fg); }

.facts {
  margin: 0;
  border-top: 1px solid var(--border);
}

.fact {
  display: flex;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
  font-size: 15px;
}

.fact dt {
  flex: none;
  width: 84px;
  color: var(--fg-muted);
}

.fact dd {
  margin: 0;
  font-weight: 500;
}

/* ---------- cards ---------- */

.cards {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}

.card {
  padding: 28px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.card h3 {
  margin: 0 0 10px;
  font-size: 18px;
  letter-spacing: -0.01em;
}

.card p {
  margin: 0;
  color: var(--fg-muted);
  font-size: 15px;
}

/* ---------- contact ---------- */

.contact-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--border);
  max-width: 640px;
}

.contact-list li {
  display: flex;
  gap: 24px;
  padding: 18px 0;
  border-bottom: 1px solid var(--border);
}

.contact-key {
  flex: none;
  width: 80px;
  color: var(--fg-muted);
  font-size: 15px;
}

.contact-val {
  font-weight: 500;
  word-break: break-all;
}

/* ---------- footer ---------- */

.site-footer {
  padding: 56px 0;
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  font-size: 14px;
  color: var(--fg-muted);
}

.footer-brand {
  margin: 0 0 12px;
  font-weight: 700;
  color: var(--fg);
}

.footer-meta { margin: 0 0 16px; }

.footer-copy { margin: 0; }

/* ---------- responsive ---------- */

@media (max-width: 768px) {
  .hero { padding: 72px 0 64px; }
  .section { padding: 64px 0; }
  .about-grid { grid-template-columns: 1fr; gap: 36px; }
  .nav { gap: 18px; font-size: 14px; }
  .btn { flex: 1 1 auto; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}

/* ==========================================================================
   멀티페이지 전환 추가분
   ========================================================================== */

/* ---------- 현재 페이지 표시 ---------- */

.nav a.is-active {
  color: var(--fg);
  font-weight: 600;
}

/* ---------- 하위 페이지 헤드 ---------- */

.page-head {
  padding: 80px 0 56px;
  border-bottom: 1px solid var(--border);
}

.page-title {
  margin: 0 0 16px;
  font-size: clamp(28px, 4.4vw, 42px);
  line-height: 1.3;
  letter-spacing: -0.02em;
  font-weight: 700;
}

.page-desc {
  margin: 0;
  max-width: 54ch;
  font-size: 17px;
  color: var(--fg-muted);
}

/* ---------- 카드 링크 ---------- */

.card-link {
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: border-color 0.15s ease, transform 0.15s ease;
}

.card-link:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
}

.card-link h3 { margin: 0; }

.card-link h3 a {
  text-decoration: none;
}

/* 카드 전체를 클릭 영역으로 확장 */
.card-link h3 a::after {
  content: "";
  position: absolute;
  inset: 0;
}

.card-link { position: relative; }

.card-link p { margin: 0; }

.card-more {
  margin-top: auto;
  padding-top: 8px;
  font-size: 14px;
  font-weight: 600;
  color: var(--accent);
}

/* ---------- 진행 절차 ---------- */

.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  counter-reset: step;
}

.step {
  padding: 28px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.step-num {
  display: block;
  margin-bottom: 12px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--accent);
}

.step h3 {
  margin: 0 0 8px;
  font-size: 17px;
  letter-spacing: -0.01em;
}

.step p {
  margin: 0;
  font-size: 15px;
  color: var(--fg-muted);
}

/* ---------- CTA ---------- */

.cta { text-align: center; }

.cta-title {
  margin: 0 0 12px;
  font-size: clamp(22px, 3vw, 30px);
  letter-spacing: -0.02em;
  font-weight: 700;
}

.cta-desc {
  margin: 0 0 28px;
  color: var(--fg-muted);
}

.cta-actions { justify-content: center; }

/* ---------- 404 ---------- */

.error-page {
  padding: 120px 0;
  text-align: center;
}

.error-page .hero-actions { justify-content: center; }

/* ---------- 푸터 레이아웃 ---------- */

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 32px;
  margin-bottom: 28px;
}

.footer-nav {
  display: flex;
  gap: 20px;
  font-size: 14px;
}

.footer-nav a { text-decoration: none; }
.footer-nav a:hover { color: var(--fg); }

/* ---------- 문의 폼 (외부 서비스 연결 시 사용) ---------- */

.form {
  max-width: 560px;
  margin-top: 48px;
}

.field { margin-bottom: 20px; }

.field label {
  display: block;
  margin-bottom: 8px;
  font-size: 14px;
  font-weight: 600;
}

.field input[type="text"],
.field input[type="email"],
.field textarea {
  width: 100%;
  padding: 12px 14px;
  background: var(--bg);
  color: var(--fg);
  border: 1px solid var(--border);
  border-radius: 10px;
  font: inherit;
  font-size: 15px;
}

.field input:focus,
.field textarea:focus {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
  border-color: transparent;
}

.field textarea { resize: vertical; }

.field-check {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.field-check input { margin-top: 4px; flex: none; }

.field-check label {
  margin: 0;
  font-weight: 400;
  font-size: 14px;
  color: var(--fg-muted);
  line-height: 1.6;
}

.req { color: #d64545; }

/* 스팸 방지용 honeypot — 사람 눈에 보이지 않게 */
.hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* ---------- 반응형 보정 ---------- */

@media (max-width: 768px) {
  .page-head { padding: 56px 0 40px; }
  .error-page { padding: 80px 0; }
  .footer-inner { flex-direction: column; gap: 24px; }
}
