:root {
  --bg: #f5f7fa;
  --bg-tint: #e9eff7;
  --ink: #1b2a41;
  --ink-soft: #4a5a73;
  --accent: #2f6fd6;
  --accent-dark: #1f55ad;
  --line: #c9d4e3;
  --sun: #f2b632;
  --sea: #1fa39a;
  --rose: #e8628a;
  --err: #b3261e;
  --ok: #17694a;
  --font: "Noto Sans KR", "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 18px;
  line-height: 1.7;
  word-break: keep-all;
  overflow-wrap: break-word;
}

.wrap {
  width: 100%;
  max-width: 680px;
  margin: 0 auto;
  padding: 0 20px;
}

h1, h2, h3, p, ul, ol, dl, dd { margin: 0; }

/* ---- 맨 위 띠 ---- */
.notice-bar {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--ink);
  color: #fff;
  text-align: center;
  font-size: 15px;
  font-weight: 700;
  padding: 10px 16px;
}

/* ---- 첫 화면 ---- */
.hero {
  position: relative;
  overflow: hidden;
  padding: 48px 0 56px;
}

.circles {
  position: absolute;
  top: -40px;
  right: -90px;
  width: 340px;
  height: 340px;
  pointer-events: none;
}

.circle {
  position: absolute;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  mix-blend-mode: multiply;
  opacity: 0.9;
  animation: gather 1.2s cubic-bezier(.2, .7, .2, 1) both;
}
.c1 { background: var(--sun); top: 0;    left: 40px; }
.c2 { background: var(--sea); top: 90px; left: 0;    animation-delay: .15s; }
.c3 { background: var(--rose); top: 90px; left: 100px; animation-delay: .3s; }

@keyframes gather {
  from { transform: translate(var(--dx, 60px), var(--dy, -60px)) scale(.6); opacity: 0; }
  to   { transform: none; opacity: .9; }
}
.c1 { --dx: 0px;   --dy: -80px; }
.c2 { --dx: -80px; --dy: 40px; }
.c3 { --dx: 80px;  --dy: 40px; }

.hero-text { position: relative; padding-top: 150px; }

h1 {
  font-size: clamp(44px, 12vw, 68px);
  line-height: 1.15;
  font-weight: 900;
  letter-spacing: -0.02em;
}

.lead {
  margin-top: 20px;
  font-size: 20px;
  color: var(--ink-soft);
}

.facts {
  margin: 32px 0;
  display: grid;
  gap: 14px;
  border-top: 2px solid var(--ink);
}
.facts > div {
  display: grid;
  grid-template-columns: 4.5em 1fr;
  gap: 8px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}
.facts dt { color: var(--ink-soft); font-weight: 500; }
.facts dd { font-weight: 700; }
.facts .sub {
  display: block;
  margin-top: 2px;
  font-size: 15px;
  font-weight: 400;
  color: var(--ink-soft);
}

/* ---- 버튼 ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 56px;
  padding: 0 32px;
  border: 0;
  border-radius: 14px;
  background: var(--accent);
  color: #fff;
  font: inherit;
  font-size: 19px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}
.btn:hover { background: var(--accent-dark); }
.btn[disabled] { background: #8a97ad; cursor: wait; }
.btn-submit { width: 100%; margin-top: 8px; }

a:focus-visible, button:focus-visible, input:focus-visible, .check:focus-within {
  outline: 3px solid var(--ink);
  outline-offset: 3px;
}

/* ---- 섹션 ---- */
.section { padding: 56px 0; }
.section.tint { background: var(--bg-tint); }

h2 {
  font-size: 30px;
  line-height: 1.3;
  font-weight: 800;
  margin-bottom: 16px;
}
h3 {
  font-size: 20px;
  line-height: 1.4;
  font-weight: 700;
  margin: 28px 0 8px;
}
.section p + p { margin-top: 12px; }
.small { font-size: 15px; color: var(--ink-soft); }

/* ---- 프로그램 타임라인 ---- */
.timeline {
  list-style: none;
  padding: 0;
  margin-top: 28px;
  border-left: 4px solid var(--ink);
}
.timeline > li {
  position: relative;
  padding: 0 0 32px 24px;
}
.timeline > li:last-child { padding-bottom: 0; }
.timeline > li::before {
  content: "";
  position: absolute;
  left: -12px;
  top: 8px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--bg-tint);
  border: 4px solid var(--ink);
}
.timeline h3 { margin: 4px 0 0; }
.timeline .time { font-weight: 800; color: var(--accent-dark); font-size: 17px; }
.timeline .zone { font-size: 15px; color: var(--ink-soft); }
.tag {
  display: inline-block;
  margin-top: 10px !important;
  padding: 2px 12px;
  border-radius: 999px;
  background: #fff;
  border: 2px solid var(--accent);
  color: var(--accent-dark);
  font-size: 15px;
  font-weight: 700;
}
.tag-common { border-color: var(--line); color: var(--ink-soft); }

/* ---- 참가 안내 ---- */
.steps { padding-left: 1.4em; }
.steps li { margin-bottom: 8px; }

.pending { list-style: none; padding: 0; margin-top: 12px; border-top: 1px solid var(--line); }
.pending li {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}
.pending span { color: var(--ink-soft); white-space: nowrap; }

/* ---- 주최·주관 ---- */
.host-list { margin-bottom: 16px; border-top: 2px solid var(--ink); }
.host-list > div {
  display: grid;
  grid-template-columns: 3em 1fr;
  gap: 8px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}
.host-list dt { color: var(--ink-soft); }
.host-list dd { font-weight: 700; }
.contact { list-style: none; padding: 0; margin-top: 8px; }
.contact li { padding: 4px 0; }
.contact-note { font-size: 15px; color: var(--ink-soft); }

/* ---- 신청 폼 ---- */
.practice-note {
  margin: 8px 0 28px;
  padding: 14px 16px;
  background: #fff6dc;
  border-left: 6px solid var(--sun);
  font-weight: 500;
}

.field { margin: 0 0 28px; padding: 0; border: 0; min-width: 0; }
.field > label, legend {
  display: block;
  padding: 0;
  margin-bottom: 8px;
  font-size: 18px;
  font-weight: 700;
}
input[type="text"], input[type="tel"], input[type="number"] {
  width: 100%;
  min-height: 56px;
  padding: 0 16px;
  border: 2px solid var(--ink-soft);
  border-radius: 12px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 18px;
}
input[aria-invalid="true"] { border-color: var(--err); }

.hint { font-size: 15px; color: var(--ink-soft); margin-top: 6px; }
fieldset .hint { margin: -4px 0 10px; }

.check {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 14px 16px;
  margin-bottom: 10px;
  border: 2px solid var(--line);
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
}
.check input {
  flex: none;
  width: 26px;
  height: 26px;
  margin: 2px 0 0;
  accent-color: var(--accent);
}
.check small { display: block; color: var(--ink-soft); font-size: 15px; }

.consent h3 { margin-top: 0; }
.small-list { padding-left: 1.2em; margin: 0 0 14px; font-size: 16px; color: var(--ink-soft); }

.err {
  min-height: 0;
  margin-top: 6px;
  color: var(--err);
  font-size: 16px;
  font-weight: 700;
}
.err:empty { display: none; }

/* 상태 안내 (실패·미확인) */
.status {
  margin: 0 0 16px;
  padding: 16px;
  border-radius: 12px;
  border: 2px solid var(--err);
  background: #fdecea;
  color: #5c1410;
  font-weight: 500;
}
.status[hidden] { display: none; }

/* 접수 완료: 서버가 201로 저장 성공을 알린 뒤에만 보임 */
.done {
  padding: 28px 20px;
  border: 3px solid var(--ok);
  border-radius: 16px;
  background: #e8f5ee;
}
.done[hidden] { display: none; }
.done h3 { margin-top: 0; color: var(--ok); font-size: 24px; }
.receipt {
  margin: 4px 0 12px !important;
  font-size: 32px;
  font-weight: 900;
  letter-spacing: .02em;
  word-break: break-all;
}

/* ---- 맨 아래 ---- */
.footer {
  padding: 32px 0 48px;
  background: var(--ink);
  color: #fff;
}
.footer .small { color: #b9c5d9; margin-top: 8px; }

/* ---- 큰 화면 ---- */
@media (min-width: 720px) {
  .circles { right: calc(50% - 440px); top: 0; }
  .hero-text { padding-top: 90px; }
}

/* ---- 글자 링크 (홈페이지 ↔ 행사소개) ---- */
.text-link-row { margin-top: 18px; }
.text-link {
  display: inline-block;
  padding: 10px 0;
  color: var(--accent-dark);
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.text-link:hover { color: var(--ink); }
.text-link-light { color: #fff; }
.text-link-light:hover { color: #b9c5d9; }

/* ---- 움직임 줄이기 ---- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .circle { animation: none; }
}
