/* ============================================================
   css/life.css - 100세 생활백서
   ============================================================ */

/* 하위 메뉴 탭 (폰에서는 가로로 밀기) */
.life-tabs {
  display: flex; gap: 8px; overflow-x: auto; -webkit-overflow-scrolling: touch;
  padding: 2px 2px 10px; margin-bottom: 16px; scrollbar-width: none;
}
.life-tabs::-webkit-scrollbar { display: none; }
.life-tabs a {
  flex-shrink: 0; padding: 10px 16px; border: 2px solid #fed7aa; border-radius: 22px;
  font-size: 17px; font-weight: 700; color: #9a3412; background: #fff; text-decoration: none; white-space: nowrap;
}
.life-tabs a:hover { background: #fff7ed; }
.life-tabs a.is-current { background: #ea580c; border-color: #ea580c; color: #fff; }

/* 본문 글씨 */
.life-lead { font-size: 19px; line-height: 1.75; margin: 0 0 10px; }
.life-sub { font-size: 20px; font-weight: 700; color: #9a3412; margin: 18px 0 6px; }

/* 전화 버튼 */
.life-tels { display: flex; flex-wrap: wrap; gap: 10px; margin: 12px 0 4px; }
.life-tel {
  display: inline-flex; flex-direction: column; justify-content: center; min-height: 60px; min-width: 150px;
  padding: 8px 18px; border-radius: 14px; background: #fff7ed; border: 2px solid #fdba74; text-decoration: none; color: #7c2d12;
}
.life-tel:hover { background: #ffedd5; text-decoration: none; }
.life-tel__num { font-size: 22px; font-weight: 800; letter-spacing: .5px; }
.life-tel__label { font-size: 15px; color: #9a3412; }
.life-ask { background: #fffbeb; border: 1px dashed #fdba74; border-radius: 12px; padding: 12px 14px; margin-top: 14px; }
.life-ask > strong { display: block; font-size: 18px; color: #9a3412; }

/* 더 알아보기 링크 */
.life-more { margin-top: 12px; display: flex; flex-wrap: wrap; gap: 8px; }
.life-more a {
  display: inline-block; padding: 9px 14px; border-radius: 10px; background: #eff6ff; border: 1px solid #bfdbfe;
  font-size: 17px; font-weight: 700; color: #1d4ed8; text-decoration: none;
}
.life-more a:hover { background: #dbeafe; }
.life-more a::before { content: '\25B6  '; font-size: 12px; }

/* 첫 화면 카드 */
.life-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 26px; }
.life-card {
  display: block; padding: 20px 16px; border-radius: 16px; background: #fff; border: 2px solid #fed7aa;
  text-decoration: none; color: #111; text-align: center;
}
.life-card:hover { border-color: #ea580c; background: #fff7ed; text-decoration: none; }
.life-card__icon { font-size: 40px; line-height: 1; display: block; margin-bottom: 8px; }
.life-card__title { display: block; font-size: 21px; font-weight: 800; margin-bottom: 4px; }
.life-card__desc { display: block; font-size: 16px; color: #57534e; line-height: 1.5; }

/* 아래 다른 메뉴 */
.life-mini { display: flex; flex-wrap: wrap; gap: 8px; }
.life-mini a {
  padding: 9px 14px; border-radius: 22px; border: 1px solid #fed7aa; background: #fff;
  font-size: 17px; color: #7c2d12; text-decoration: none;
}
.life-mini a:hover { background: #fff7ed; }
.life-note { font-size: 17px; color: #57534e; background: #fafaf9; border-radius: 10px; padding: 12px 14px; margin: 20px 0; line-height: 1.7; }

/* 전화번호 표 */
.life-table { width: 100%; border-collapse: collapse; font-size: 18px; background: #fff; margin: 10px 0 8px; border: 1px solid #e7e5e4; border-radius: 10px; overflow: hidden; }
.life-table th { background: #fff7ed; color: #9a3412; text-align: left; padding: 12px 14px; border-bottom: 2px solid #fed7aa; white-space: nowrap; }
.life-table td { padding: 12px 14px; border-bottom: 1px solid #f5f5f4; vertical-align: middle; }
.life-table tr:last-child td { border-bottom: 0; }
.life-table td:first-child { white-space: nowrap; font-weight: 800; }
.life-table td:first-child a { font-size: 21px; color: #c2410c; text-decoration: none; }
.life-table td:first-child a::before { content: '\1F4DE  '; font-size: 16px; }

@media (max-width: 1020px) {
  .life-cards { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
  .life-tel { flex: 1 1 140px; }
  .life-card { padding: 16px 10px; }
  .life-card__title { font-size: 19px; }
  /* 표를 줄마다 카드처럼 (칸 이름은 data-label) */
  .life-table, .life-table tbody, .life-table tr, .life-table td { display: block; width: 100%; border: 0; }
  .life-table { border: 0; background: none; }
  .life-table thead { display: none; }
  .life-table tr { background: #fff; border: 1px solid #fed7aa; border-radius: 12px; margin-bottom: 10px; overflow: hidden; }
  .life-table td { padding: 6px 14px; border: 0; font-size: 18px; }
  .life-table td:first-child { background: #fff7ed; padding: 10px 14px; }
  .life-table td + td::before { content: attr(data-label) " : "; font-weight: 700; color: #78716c; }
  .life-table td:last-child { padding-bottom: 12px; }
}

/* ---------- 안심 식당 찾기 (life/safefood.asp) ---------- */
.sf-form { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; align-items: end; background: #fff7ed; border: 2px solid #fed7aa; border-radius: 16px; padding: 18px; margin: 18px 0; }
.sf-field label { display: block; font-size: 19px; font-weight: 800; color: #9a3412; margin-bottom: 6px; }
.sf-field label small { font-size: 15px; font-weight: 600; color: #78716c; }
.sf-field select { width: 100%; min-height: 60px; padding: 8px 12px; border: 3px solid #d6d3d1; border-radius: 12px; background: #fff; font: inherit; font-size: 20px; color: #1c1917; }
.sf-field select:focus { border-color: #ea580c; outline: 3px solid #fed7aa; }
.sf-field select:disabled { background: #f5f5f4; color: #a8a29e; }
.sf-submit { grid-column: 1 / -1; min-height: 64px; border: 0; border-radius: 14px; background: #ea580c; color: #fff; font: inherit; font-size: 23px; font-weight: 800; cursor: pointer; }
.sf-submit:hover { background: #c2410c; }
.sf-guide { font-size: 21px; font-weight: 700; color: #57534e; text-align: center; padding: 26px 12px; background: #fafaf9; border-radius: 14px; margin: 0 0 20px; }
.sf-empty { font-size: 20px; line-height: 1.7; margin: 0; }
.sf-result__title { font-size: 26px; font-weight: 800; margin: 8px 0 4px; word-break: keep-all; }
.sf-result__title strong { color: #c2410c; }
.sf-result__sub { font-size: 17px; color: #78716c; margin: 0 0 14px; }
.sf-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.sf-item { border: 2px solid #e7e5e4; border-radius: 16px; padding: 16px 18px; background: #fff; }
.sf-item__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.sf-item__name { font-size: 23px; font-weight: 800; color: #1c1917; word-break: break-all; }
.sf-grade { flex: none; font-size: 17px; font-weight: 800; padding: 5px 12px; border-radius: 999px; background: #dcfce7; color: #166534; white-space: nowrap; }
.sf-item__meta { font-size: 17px; font-weight: 700; color: #78716c; margin: 6px 0 0; }
.sf-item__addr { font-size: 19px; color: #44403c; margin: 6px 0 0; word-break: keep-all; }
.sf-item__btns { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 12px; }
.sf-btn { display: inline-flex; align-items: center; min-height: 52px; padding: 8px 16px; border: 2px solid #d6d3d1; border-radius: 12px; font-size: 19px; font-weight: 800; color: #44403c; text-decoration: none; background: #fff; white-space: nowrap; }
.sf-btn:hover { background: #fafaf9; text-decoration: none; }
.sf-btn--tel { border-color: #fdba74; color: #c2410c; background: #fff7ed; }
.sf-pager { display: flex; justify-content: center; align-items: center; gap: 16px; margin: 20px 0 8px; font-size: 19px; font-weight: 700; }
.sf-pager a { display: inline-flex; align-items: center; min-height: 52px; padding: 8px 18px; border: 2px solid #fed7aa; border-radius: 12px; color: #c2410c; text-decoration: none; }
.sf-about { font-size: 19px; line-height: 1.7; margin: 0 0 10px; word-break: keep-all; }
@media (max-width: 768px) {
  .sf-form { grid-template-columns: 1fr; padding: 14px; }
  .sf-item { padding: 14px; }
  .sf-item__head { flex-direction: column; gap: 6px; }
  .sf-item__name { font-size: 22px; }
  .sf-btn { flex: 1 1 auto; justify-content: center; }
}
.sf-grade--pet { background: #fef3c7; color: #92400e; }
.sf-field--wide { grid-column: 1 / -1; }
.sf-field input[type="search"] { width: 100%; min-height: 60px; padding: 8px 14px; border: 3px solid #d6d3d1; border-radius: 12px; background: #fff; font: inherit; font-size: 20px; color: #1c1917; box-sizing: border-box; }
.sf-field input[type="search"]:focus { border-color: #ea580c; outline: 3px solid #fed7aa; }
