body {
  font-family: 'Noto Sans KR', sans-serif;
  margin: 0;
  padding: 0 1em;
  background-color: #ffffff;
  color: #222;
}

main {
  padding-left: 1em;
  padding-right: 1em;
}

.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: #177245;
  color: white;
  padding: 1rem 2rem;
}

.navbar .logo {
  font-size: 1.5rem;
  font-weight: bold;
}

.navbar ul {
  list-style: none;
  display: flex;
  gap: 1.5rem;
  margin: 0;
  padding: 0;
}

.navbar a {
  color: white;
  text-decoration: none;
}

.hero {
  background: linear-gradient(to right, #008000, #2e8b57);
  color: white;
  text-align: center;
  padding: 4rem 2rem;
}

h1, h2, h3 {
  margin-top: 1.5em;
}

.hero h1 {
  font-size: 2.5rem;
}

pre {
  white-space: pre-wrap;
  line-height: 2.5em;
}

.hero .button {
  display: inline-block;
  margin-top: 1rem;
  padding: 0.75rem 1.5rem;
  background-color: #fff;
  color: #222;
  text-decoration: none;
  border-radius: 5px;
  font-weight: bold;
}

.cta {
  background-color: #fff9d1;
  padding: 3rem 2rem;
  text-align: center;
  color: #177245;
}

.cta .button {
  display: inline-block;
  margin-top: 1rem;
  padding: 0.75rem 1.5rem;
  background-color: #177245;
  color: white;
  text-decoration: none;
  border-radius: 5px;
}

.section {
  padding: 3rem 2rem;
  background-color: white;
  color: #407a52;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.feature-item {
  background-color: #407a52;
  padding: 1.5rem;
  border-radius: 8px;
  color: white;
}


button {
  min-height: 44px;
  font-size: 1em;
  padding: 10px 16px;
  margin: 0.5em 0;
}

textarea {
  font-size: 1em;
  padding: 8px;
}

.question-box {
  line-height: 1.5em;
  text-align: left;
  padding-left: 0.5em;
}

#exploreAnswer {
  font-family: 'Nanum Gothic', sans-serif;
  font-size: 18px;
  font-weight: bold;
  line-height: 1.6;
  white-space: pre-line;
  margin-top: 1em;
}

#scoreResult {
  font-family: 'Nanum Gothic', sans-serif;
  font-size: 14px;
  font-weight: bold;
  white-space: pre-line;  /* \n 줄바꿈만 허용, 빈줄 없음 */
  line-height: 1.3em;     /* 간격 줄이기 */
}

.popup {
  resize: both;
  overflow: auto;
  max-width: 90vw;
  max-height: 80vh;
  position: fixed;
  background: white;
  border: 1px solid #aaa;
  box-shadow: 0 2px 10px rgba(0,0,0,0.2);
  padding: 1em;
  top: 10vh;
  left: 5vw;
}

@media (max-width: 768px) {
  .question-box {
    flex: 1 1 100%;
  }

  .popup {
    width: 90vw;
    left: 5vw;
    top: 10vh;
  }

  nav ul {
    flex-direction: column;
  }
}

/* 상단 메뉴 배경 */

.navbar-bg {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: #339900;
  color: white;
  padding: 1rem 2rem;
}

.navbar-bg .logo-bg {
  font-size: 1.5rem;
  font-weight: bold;
}

.navbar-bg ul {
  list-style: none;
  display: flex;
  gap: 1.5rem;
  margin: 0;
  padding: 0;
}

.navbar-bg a {
  color: white;
  text-decoration: none;
}





/* Hero 섹션 배경 */
.hero-bg {
  background: linear-gradient(to right, #33ff66, #339900);
  color: white;
  text-align: center;
  padding: 4rem 2rem;
}



/* Feature Grid 배경 */
.feature-item-bg {
  background-color: #339900;
  padding: 1.5rem;
  border-radius: 8px;
  color: white;
}

.cta-bg {
  background-color: #99cc00;
  padding: 3rem 2rem;
  text-align: center;
  color: #177245;
}

/* 버튼들을 한 줄에 중앙 정렬 */
.btn-row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;               /* 버튼 간격 */
  flex-wrap: wrap;         /* 좁은 화면에서 줄바꿈 */
  margin: 20px 0;
}

/* 링크/버튼 공통 박스 스타일 */
.btn-box {
  display: inline-flex;    /* 텍스트 클릭영역 = 전체 박스 */
  justify-content: center;
  align-items: center;
  height: 56px;
  width: clamp(180px, 28vw, 260px);  /* 동일 크기, 반응형 */
  padding: 0 20px;
  background: #fff;        /* 박스 바탕 흰색 */
  color: #807532;             /* 글자 검은색 */
  border: 1.5px solid white;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 700;
  text-decoration: none;   /* <a> 밑줄 제거 */
  box-shadow: 0 2px 0 rgba(0,0,0,0.15);
  transition: transform 120ms ease, box-shadow 120ms ease, background-color 120ms ease;
  cursor: pointer;
}

/* 호버/포커스 효과 */
.btn-box:hover,
.btn-box:focus-visible {
  background: #f6f6f6;
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgba(0,0,0,0.08), 0 2px 0 rgba(0,0,0,0.18);
  outline: none;
}

/* 클릭 시 살짝 눌리는 느낌 */
.btn-box:active {
  transform: translateY(0);
  box-shadow: 0 2px 0 rgba(0,0,0,0.15);
}

/* 접근성: 키보드 포커스 링 */
.btn-box:focus-visible {
  box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.25), 0 6px 14px rgba(0,0,0,0.08);
}

/* 사용자가 모션 감소를 선호하는 경우 애니메이션 최소화 */
@media (prefers-reduced-motion: reduce) {
  .btn-box {
    transition: none;
  }
}
