/* ===================================================================
   공통 스타일
   期待値ナビ(kitaichi-navi) 의 common.css 구조를 이어받되,
   경마에 맞춰 그린 계열로 교체하고 토큰 기반으로 다듬었다.

   색 규칙 (期待値ナビ 와 동일한 사고방식):
   --green-dark 는 링크·강조 문자에 쓰므로 흰 배경과 --green-bg
   양쪽에서 WCAG AA(4.5:1)를 만족해야 한다.
     #16653a → 흰 배경 7.10:1 / --green-bg 6.59:1
   장식용 --green(#1f8a4c) 은 배경·테두리·어두운 바탕 위 글자 전용.
   =================================================================== */

:root {
  --green: #1f8a4c;
  --green-dark: #16653a;
  /* 칠해진 버튼·칩의 배경과 그 위 글자.
     --green(#1f8a4c) 위에 흰 글자는 4.38:1 로 AA 미달이라 따로 둔다. */
  --green-solid: #17703c;
  --on-green: #ffffff;
  --green-light: #cde9d8;
  --green-bg: #f1f8f3;
  --ink: #14261c;
  --ink-soft: #1d3327;
  --text: #2f3430;
  --muted: #667069;
  --line: #e2e7e3;
  --bg: #f7f9f8;
  --card: #ffffff;
  --shadow: 0 1px 2px rgba(20,38,28,.05), 0 4px 16px rgba(20,38,28,.05);
  --radius: 14px;
  --danger: #b3261e;
}

/*
  다크 모드는 토큰만 갈아끼운다. 개별 규칙에 색을 직접 쓰지 말 것 —
  여기서 못 잡으면 다크에서 글자가 사라진다.
*/
@media (prefers-color-scheme: dark) {
  :root {
    --green: #4ec27f;
    --green-dark: #7fd8a3;
    /* 다크에서는 밝은 그린 위에 흰 글자가 2.26:1 밖에 안 된다.
       배경은 그대로 두고 글자를 어둡게 뒤집는다 (8.4:1). */
    --green-solid: #4ec27f;
    --on-green: #0b1611;
    --green-light: #2b4a38;
    --green-bg: #16241c;
    --ink: #0e1712;
    --ink-soft: #142019;
    --text: #dde5e0;
    --muted: #97a49c;
    --line: #2a352e;
    --bg: #101815;
    --card: #17211c;
    --shadow: 0 1px 2px rgba(0,0,0,.3), 0 4px 16px rgba(0,0,0,.25);
    --danger: #ff9a92;
  }
}

/* === 키보드 포커스 === */
/* 마우스 클릭에는 테두리를 내지 않고 키보드 이동일 때만 보이게 한다.
   outline 을 지우기만 하면 키보드 사용자가 현재 위치를 잃는다. */
:focus-visible {
  outline: 3px solid var(--green);
  outline-offset: 2px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--ink);
  color: #fff;
  padding: 10px 16px;
  z-index: 200;
  font-weight: 700;
}

.skip-link:focus {
  left: 0;
  text-decoration: none;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

/* === Reset & Base === */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  font-family: "M PLUS Rounded 1c", "Hiragino Kaku Gothic ProN", "Meiryo", sans-serif;
  color: var(--text);
  background-color: var(--bg);
  line-height: 1.8;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--green-dark);
  text-decoration: none;
}

a:hover { text-decoration: underline; }

img { max-width: 100%; height: auto; }

/* === Layout === */
.site-wrapper {
  flex: 1;
  width: 100%;
  max-width: 960px;
  margin: 0 auto;
  padding: 0 16px;
}

/* === Header / Navigation === */
.site-header {
  background-color: var(--ink);
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 4px rgba(0,0,0,.2);
  border-bottom: 2px solid var(--green);
}

.header-inner {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
}

.site-logo {
  font-size: 1.25rem;
  font-weight: 700;
  color: #fff;
  text-decoration: none;
  letter-spacing: .02em;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.logo-mark {
  width: 26px;
  height: 26px;
  flex-shrink: 0;
  border-radius: 6px;
}

.site-logo .accent { color: #6fd39a; }

.site-logo:hover { text-decoration: none; opacity: .9; }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: #fff;
  font-size: 1.5rem;
  cursor: pointer;
  padding: 4px 8px;
  line-height: 1;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 4px;
}

.site-nav a {
  color: #fff;
  padding: 8px 10px;
  border-radius: 8px;
  font-size: .85rem;
  font-weight: 500;
  white-space: nowrap;
  transition: background-color .2s;
}

.site-nav a:hover,
.site-nav a.active {
  background-color: rgba(111,211,154,.22);
  text-decoration: none;
}

.site-nav a.active {
  color: #6fd39a;
  font-weight: 700;
}

/* 헤더가 sticky 라 앵커 점프 시 제목이 가려진다 */
[id] { scroll-margin-top: 68px; }

/* === Breadcrumb === */
.breadcrumb {
  font-size: .8rem;
  color: var(--muted);
  padding: 14px 0 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--green-dark); }
.breadcrumb .sep { color: var(--line); }
.breadcrumb [aria-current="page"] { color: var(--text); font-weight: 700; }

/* === Page Title === */
.page-title {
  font-size: clamp(1.35rem, 1.05rem + 1.3vw, 1.75rem);
  font-weight: 700;
  color: var(--text);
  margin: 32px 0 8px;
  padding-bottom: 10px;
  border-bottom: 3px solid var(--green);
  line-height: 1.45;
}

.page-lead {
  color: var(--muted);
  font-size: .93rem;
  margin-bottom: 24px;
}

/* === Section === */
.section { margin-bottom: 36px; }

.section-title {
  font-size: clamp(1.1rem, 1rem + .4vw, 1.25rem);
  font-weight: 700;
  color: var(--text);
  margin-bottom: 12px;
  padding-left: 12px;
  border-left: 4px solid var(--green);
}

.section p + p { margin-top: 12px; }

/* === Footer === */
.site-footer {
  background-color: var(--ink-soft);
  color: #b7c2bb;
  padding: 32px 16px 24px;
  margin-top: 48px;
  font-size: .85rem;
}

.footer-inner { max-width: 960px; margin: 0 auto; }

.footer-common {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 16px;
}

.footer-common a { color: #b7c2bb; font-size: .85rem; }
.footer-common a:hover { color: #fff; }

.footer-sub {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  padding-top: 16px;
  border-top: 1px solid rgba(255,255,255,.12);
  margin-bottom: 16px;
}

.footer-sub a { color: #8f9c94; font-size: .8rem; }
.footer-sub a:hover { color: #fff; }

.footer-note {
  color: #8f9c94;
  font-size: .78rem;
  line-height: 1.7;
  margin-bottom: 16px;
}

.footer-copy {
  text-align: center;
  padding-top: 16px;
  border-top: 1px solid rgba(255,255,255,.12);
  color: #8f9c94;
  font-size: .8rem;
}

/* === Ad Slots === */
.ad-slot {
  text-align: center;
  margin: 24px auto;
  overflow: hidden;
}

/* === 次のステップ CTA === */
.next-action-section {
  margin: 40px 0 16px;
  padding: 20px 16px;
  background: var(--green-bg);
  border-radius: var(--radius);
  border: 1px solid var(--green-light);
}

.next-action-label {
  font-size: .8rem;
  font-weight: 700;
  color: var(--green-dark);
  letter-spacing: .05em;
  margin: 0 0 12px;
}

.next-action-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
}

.next-action-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 14px 8px;
  background: var(--card);
  border: 1px solid var(--green-light);
  border-radius: 12px;
  text-decoration: none;
  color: var(--text);
  font-size: .8rem;
  font-weight: 600;
  line-height: 1.35;
  text-align: center;
  transition: background .15s, box-shadow .15s;
}

.next-action-card:hover {
  background: var(--green-bg);
  box-shadow: var(--shadow);
  color: var(--green-dark);
  text-decoration: none;
}

.next-action-icon { font-size: 1.5rem; line-height: 1; }

/* === Responsive === */
@media (max-width: 768px) {
  .nav-toggle { display: block; }

  .site-nav {
    display: none;
    position: absolute;
    top: 56px;
    left: 0;
    right: 0;
    background-color: var(--ink);
    flex-direction: column;
    padding: 8px 0;
    box-shadow: 0 4px 8px rgba(0,0,0,.25);
    border-bottom: 2px solid var(--green);
  }

  .site-nav.open { display: flex; }

  .site-nav a {
    padding: 12px 24px;
    border-radius: 0;
    font-size: 1rem;
    width: 100%;
  }

  .header-inner { height: 52px; }
  .page-title { margin: 24px 0 8px; }
}

@media (max-width: 480px) {
  .site-logo { font-size: 1.05rem; }
}
