/* fixycle-site/style.css — 사이트 전체 스타일 (외부 프레임워크 없음) */

:root {
  /* 로고 파일에서 직접 뽑아낸 색 (images/logo.png)
     네이비 #2a3273 · 그린 #83b754 */
    --blue: #182a88;
  --blue-dark: #162067;
  --blue-soft: #efedf6;
  --green: #78bc29;
  --green-dark: #4a8600;
  --green-soft: #f0f6e7;

  --bg: #f7f9f8;
  --surface: #ffffff;
  --fg: #17211c;
  --muted: #66736c;
  --border: #e2e8e5;

  --radius: 14px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(23, 33, 28, 0.04), 0 8px 24px rgba(23, 33, 28, 0.05);
  --shadow-lift: 0 4px 8px rgba(23, 33, 28, 0.06), 0 16px 32px rgba(23, 33, 28, 0.1);
  --maxw: 1000px;
}

* {
  box-sizing: border-box;
}

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

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

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--blue);
}

h1,
h2,
h3 {
  letter-spacing: -0.02em;
}

.container {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 20px;
}

.skip-link {
  position: absolute;
  left: -9999px;
}
.skip-link:focus {
  left: 8px;
  top: 8px;
  background: var(--surface);
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  z-index: 20;
}

/* ---------- 헤더 ---------- */
.site-header {
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: saturate(180%) blur(8px);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 10;
}

.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 20px;
  padding-top: 12px;
  padding-bottom: 12px;
}

.brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  color: var(--fg);
}

/* 로고 이미지 (images/logo.png 등을 넣으면 자동으로 표시된다) */
.brand-logo {
  height: 36px;
  width: auto;
}

.brand-text {
  font-weight: 800;
  font-size: 1.3rem;
  letter-spacing: -0.02em;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
  margin-left: auto;
  margin-right: 14px;
}

.nav-link {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.94rem;
  font-weight: 500;
  padding: 7px 12px;
  border-radius: 999px;
  transition: background 0.15s, color 0.15s;
}

.nav-link:hover {
  color: var(--fg);
  background: var(--bg);
}

.nav-link.is-active {
  color: var(--blue);
  background: var(--blue-soft);
  font-weight: 700;
}

/* 언어 전환 */
.lang-switch {
  display: inline-flex;
  border: 1px solid var(--border);
  border-radius: 999px;
  overflow: hidden;
  background: var(--surface);
}

.lang-switch button {
  font: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 6px 12px;
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.lang-switch button:hover {
  color: var(--fg);
}

.lang-switch button.is-active {
  background: var(--blue);
  color: #fff;
}

/* ---------- 히어로 (메인) ---------- */
.hero {
  background: linear-gradient(160deg, var(--blue-soft) 0%, var(--green-soft) 100%);
  border-bottom: 1px solid var(--border);
}

.hero-inner {
  padding-top: 60px;
  padding-bottom: 60px;
}

.hero-title {
  margin: 0 0 20px;
  font-size: clamp(1.9rem, 5vw, 3rem);
  line-height: 1.25;
  font-weight: 800;
  color: var(--blue);
}

.hero-title-accent {
  color: var(--blue);
}

.hero-lead {
  margin: 0 0 24px;
  max-width: 40em;
  color: var(--fg);
  font-size: 1.05rem;
}

/* 인용구 — 왼쪽에 색 막대 */
.hero-quote {
  margin: 0 0 32px;
  padding: 2px 0 2px 16px;
  border-left: 4px solid var(--green);
  max-width: 40em;
  font-style: italic;
  font-weight: 600;
  color: var(--fg);
}

/* 성과 숫자 카드 */
.stats {
  list-style: none;
  margin: 0 0 32px;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 14px;
  max-width: 640px;
}

.stat {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px 20px;
}

.stat-value {
  display: block;
  font-size: 1.85rem;
  font-weight: 800;
  line-height: 1.15;
  color: var(--blue);
  font-variant-numeric: tabular-nums;
}

.stat-label {
  display: block;
  margin-top: 2px;
  font-size: 0.88rem;
  color: var(--muted);
}

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

/* ---------- 본문 ---------- */
main {
  padding-bottom: 72px;
  min-height: 60vh;
}

.page-head {
  padding-top: 48px;
  padding-bottom: 4px;
}

.page-title {
  font-size: clamp(1.7rem, 4vw, 2.2rem);
  font-weight: 800;
  margin: 0 0 8px;
}

.lead {
  color: var(--muted);
  margin: 0;
  max-width: 46em;
}

.section {
  margin-top: 44px;
}

/* 섹션 제목에만 적용 — 카드 제목·목록 제목까지 물들지 않도록 직계 자식으로 한정한다 */
.section > h2,
.section > .section-head > h2 {
  font-size: 1.3rem;
  margin: 0 0 16px;
  position: relative;
  padding-left: 14px;
}

/* 제목 앞의 작은 색 막대 */
.section > h2::before,
.section > .section-head > h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.32em;
  width: 5px;
  height: 1em;
  border-radius: 3px;
  background: var(--green);
}

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.section-head h2 {
  margin: 0;
}

.more-link {
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
}

.more-link:hover {
  text-decoration: underline;
}

.muted {
  color: var(--muted);
}

.empty {
  color: var(--muted);
  background: var(--surface);
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  padding: 28px;
  text-align: center;
}

.note {
  color: var(--muted);
  font-size: 0.9rem;
  margin-top: 18px;
}

.prose p {
  margin: 0 0 10px;
}

.prose p:last-child {
  margin-bottom: 0;
}

.prose ul {
  margin: 0 0 10px;
  padding-left: 20px;
}

.prose h3 {
  font-size: 1.02rem;
  margin: 18px 0 8px;
}

/* 흰 패널 (폼, 연락처 목록) */
.card-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 26px 28px;
}

/* ---------- 연혁 (소개 페이지) ---------- */
.timeline {
  list-style: none;
  margin: 0;
  padding: 0 0 0 26px;
  position: relative;
}

/* 왼쪽 세로선 */
.timeline::before {
  content: "";
  position: absolute;
  left: 5px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: var(--border);
  border-radius: 1px;
}

.timeline-item {
  position: relative;
  padding-bottom: 28px;
}

.timeline-item:last-child {
  padding-bottom: 0;
}

/* 동그란 점 */
.timeline-item::before {
  content: "";
  position: absolute;
  left: -26px;
  top: 7px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--green);
  border: 2px solid var(--surface);
  box-shadow: 0 0 0 2px var(--green-soft);
}

.timeline-date {
  display: block;
  font-size: 0.9rem;
  font-weight: 800;
  color: var(--green-dark);
  font-variant-numeric: tabular-nums;
}

.timeline-title {
  margin: 2px 0 4px;
  font-size: 1.05rem;
  font-weight: 700;
}

.timeline-text {
  margin: 0;
  color: var(--muted);
  max-width: 46em;
}

/* ---------- 목록 (공지 / 활동) ---------- */
.list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 14px;
}

.list-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 20px 24px;
}

/* 눌러서 상세 팝업을 여는 항목 (공지·활동·멤버·자전거 공통) */
.is-clickable {
  position: relative;
  transition: border-color 0.15s, box-shadow 0.15s, transform 0.15s;
}

.is-clickable:hover {
  border-color: var(--blue);
  box-shadow: var(--shadow-lift);
  transform: translateY(-3px);
}

.list-item-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 12px;
  margin-bottom: 8px;
}

.list-item-head h2,
.list-item-head h3 {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 700;
}

.list-item-head time {
  color: var(--muted);
  font-size: 0.85rem;
  font-variant-numeric: tabular-nums;
}

/* 공지·활동에 넣는 선택 사진 (없으면 아예 출력되지 않는다)
   사진을 자르지 않고 원본 비율 그대로 보여주되, 너무 커지지 않게 폭만 제한한다. */
.list-photo {
  width: 100%;
  max-width: 560px;
  height: auto;
  border-radius: 10px;
  margin: 4px 0 14px;
  background: var(--bg);
}

/* 언론보도의 매체명 태그 */
.outlet {
  display: inline-block;
  margin-bottom: 8px;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--blue-soft);
  color: var(--blue);
  font-size: 0.76rem;
  font-weight: 700;
}

.article-link {
  display: inline-block;
  margin-top: 10px;
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
}

.article-link:hover {
  text-decoration: underline;
}

/* ---------- 자전거 필터 / 검색 ---------- */
.toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 22px;
}

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.filter-btn {
  font: inherit;
  font-size: 0.9rem;
  color: var(--fg);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 8px 15px;
  cursor: pointer;
  line-height: 1.2;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}

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

.filter-btn.is-active {
  background: var(--blue);
  border-color: var(--blue);
  color: #fff;
  font-weight: 700;
}

.filter-btn .count {
  display: inline-block;
  margin-left: 4px;
  font-size: 0.8rem;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.filter-btn.is-active .count {
  color: rgba(255, 255, 255, 0.75);
}

.search-box input[type="search"] {
  width: 230px;
  max-width: 100%;
  padding: 9px 14px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  font: inherit;
  font-size: 0.9rem;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

[hidden] {
  display: none !important;
}

/* ---------- 카드 그리드 ---------- */
.grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 20px;
}

.grid--bikes {
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
}

.grid--members {
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  margin-bottom: 30px;
}

/* ---------- 멤버 명단 (소개 페이지) ---------- */
.member-group {
  margin: 26px 0 12px;
  font-size: 1rem;
  font-weight: 800;
  color: var(--blue);
  letter-spacing: -0.01em;
}

.member-group::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 8px;
  border-radius: 50%;
  background: var(--green);
  vertical-align: middle;
}

.member-list {
  list-style: none;
  margin: 0 0 26px;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 10px;
}

.member-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
}

.member-name {
  display: block;
  font-weight: 700;
}

.member-role {
  display: block;
  margin-top: 2px;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--green-dark);
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.card--bike {
  position: relative;
  transition: border-color 0.15s, box-shadow 0.15s, transform 0.15s;
}

.card--bike:hover {
  border-color: var(--blue);
  box-shadow: var(--shadow-lift);
  transform: translateY(-3px);
}

/* 카드 전체를 덮는 투명 버튼 */
.card-open {
  position: absolute;
  inset: 0;
  width: 100%;
  border: 0;
  background: transparent;
  cursor: pointer;
  border-radius: var(--radius);
}

.card-open:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: -3px;
}

.card-more {
  display: block;
  margin-top: 12px;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--blue);
}

.card-photo {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  background: var(--bg);
}

.card-photo--round {
  width: 92px;
  height: 92px;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  margin: 22px auto 0;
  border: 3px solid var(--green-soft);
}

.card-body {
  padding: 16px 20px 20px;
}

.card--member .card-body {
  text-align: center;
}

.card-title {
  margin: 8px 0 4px;
  font-size: 1.05rem;
  font-weight: 700;
}

.card-text {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.role {
  margin: 0 0 8px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--green-dark);
  text-transform: uppercase;
}

/* 상태 배지 */
.status {
  display: inline-block;
  font-size: 0.76rem;
  font-weight: 700;
  padding: 4px 11px;
  border-radius: 999px;
  border: 1px solid transparent;
}

.status--repairing {
  background: #fff3dd;
  color: #96560a;
  border-color: #f4dcb2;
}

.status--forsale {
  background: var(--green-soft);
  color: var(--green-dark);
  border-color: #d3e9b0;
}

.status--sold {
  background: #eef1f0;
  color: #6b7772;
  border-color: #dfe4e2;
}

/* ---------- 자전거 상세 팝업 ---------- */
.modal {
  width: min(680px, 92vw);
  max-height: 86vh;
  padding: 0;
  border: none;
  border-radius: 18px;
  background: var(--surface);
  color: var(--fg);
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.28);
}

.modal::backdrop {
  background: rgba(17, 26, 22, 0.55);
  backdrop-filter: blur(2px);
}

.modal-inner {
  max-height: 86vh;
  overflow-y: auto;
  padding: 28px 30px 32px;
  -webkit-overflow-scrolling: touch;
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 16px;
  z-index: 2;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
}

.modal-close:hover {
  color: var(--fg);
  border-color: var(--muted);
}

.modal-title {
  margin: 10px 0 6px;
  font-size: 1.45rem;
  font-weight: 800;
  padding-right: 40px;
}

.modal-desc {
  margin: 0 0 20px;
  color: var(--muted);
}

/* 공지·활동 팝업의 날짜와 사진 */
.modal-date {
  display: block;
  color: var(--muted);
  font-size: 0.85rem;
  font-variant-numeric: tabular-nums;
  margin-top: 4px;
}

.modal-photo {
  width: 100%;
  height: auto;
  border-radius: 12px;
  margin: 6px 0 20px;
  background: var(--bg);
}

/* 멤버 팝업 */
.modal-inner--member {
  text-align: center;
}

.modal-inner--member .modal-title {
  padding-right: 0;
}

.modal-inner--member .prose {
  text-align: left;
  margin-top: 16px;
}

.modal-avatar {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  margin: 10px auto 4px;
  border: 4px solid var(--green-soft);
  background: var(--bg);
}

.gallery {
  display: grid;
  gap: 12px;
  margin-bottom: 22px;
}

.gallery img {
  width: 100%;
  border-radius: 12px;
  background: var(--bg);
}

/* 팝업 안의 신청/이동 버튼 */
.modal-cta {
  margin: 22px 0 0;
}

.modal-foot {
  margin: 24px 0 0;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  font-size: 0.9rem;
  color: var(--muted);
}

/* ---------- CTA / 버튼 ---------- */
.cta {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 36px 28px;
  text-align: center;
}

.cta h2 {
  margin: 0 0 8px;
  padding-left: 0;
}

.cta h2::before {
  display: none;
}

.cta p {
  margin: 0 0 20px;
  color: var(--muted);
}

.button {
  display: inline-block;
  background: var(--blue);
  color: #fff;
  border: 1px solid var(--blue);
  border-radius: 999px;
  padding: 12px 26px;
  font-size: 0.98rem;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, transform 0.1s;
}

.button:hover {
  background: var(--blue-dark);
  border-color: var(--blue-dark);
}

.button:active {
  transform: translateY(1px);
}

.button--ghost {
  background: var(--surface);
  color: var(--blue);
}

.button--ghost:hover {
  background: var(--blue-soft);
  border-color: var(--blue);
  color: var(--blue-dark);
}

.form .button {
  justify-self: start;
}

/* ---------- 폼 ---------- */
.form {
  max-width: 580px;
  display: grid;
  gap: 18px;
}

.field {
  display: grid;
  gap: 6px;
}

.field label {
  font-weight: 700;
  font-size: 0.93rem;
}

.req {
  color: #c0392b;
}

input[type="text"],
input[type="email"],
input[type="file"],
select,
textarea {
  width: 100%;
  font: inherit;
  color: inherit;
  padding: 11px 13px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
}

textarea {
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus,
.filter-btn:focus-visible,
.lang-switch button:focus-visible {
  outline: 3px solid var(--blue-soft);
  outline-offset: 0;
  border-color: var(--blue);
}

.hint {
  margin: 0;
  font-size: 0.85rem;
  color: var(--muted);
}

/* Netlify Forms 허니팟 — 사람에게는 보이지 않는다 */
.hidden-field {
  display: none;
}

.contact-list {
  list-style: none;
  margin: 0;
  padding: 26px 28px;
  display: grid;
  gap: 12px;
}

.contact-list li {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
}

.contact-list strong {
  display: inline-block;
  min-width: 100px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
}

/* ---------- 푸터 ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  background: var(--surface);
  padding: 28px 0 44px;
  font-size: 0.9rem;
  color: var(--muted);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 24px;
  justify-content: space-between;
  align-items: flex-end;
}

.site-footer p {
  margin: 0 0 2px;
}

.footer-brand {
  font-weight: 800;
  font-size: 1.05rem;
  color: var(--fg);
}

/* ---------- 모바일 ---------- */
@media (max-width: 720px) {
  body {
    font-size: 15px;
  }

  /* 모바일: 1행 = 로고 + 언어전환, 2행 = 메뉴 */
  .header-inner {
    align-items: center;
    gap: 6px;
  }

  /* 탭이 7개라 한 줄에 다 안 들어간다. 잘리지 않게 줄바꿈시킨다. */
  .nav {
    order: 3;
    width: 100%;
    gap: 2px;
    margin: 0 0 0 -10px;
    flex-wrap: wrap;
  }

  .nav-link {
    white-space: nowrap;
    padding: 5px 10px;
  }

  .nav-link {
    padding: 6px 10px;
    font-size: 0.9rem;
  }

  .hero-inner {
    padding-top: 44px;
    padding-bottom: 44px;
  }

  .hero-actions .button {
    flex: 1 1 auto;
    text-align: center;
  }

  .page-head {
    padding-top: 32px;
  }

  .grid--bikes,
  .grid--members {
    grid-template-columns: 1fr;
  }

  .toolbar {
    flex-direction: column;
    align-items: stretch;
  }

  .search-box input[type="search"] {
    width: 100%;
  }

  .card-panel,
  .contact-list {
    padding: 20px 18px;
  }

  .modal {
    width: 94vw;
    max-height: 90vh;
  }

  .modal-inner {
    max-height: 90vh;
    padding: 24px 18px 28px;
  }

  .modal-title {
    font-size: 1.25rem;
  }

  .contact-list strong {
    min-width: 0;
    width: 100%;
  }
}
