@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@500;600;700&family=Noto+Sans+KR:wght@400;500;600;700;800&display=swap');

:root {
  --ink: #20201e;
  --muted: #74746e;
  --line: #e9e7e1;
  --cream: #f7f5ee;
  --orange: #ff6847;
  --orange-dark: #ec5030;
  --yellow: #ffd85b;
  --green: #247c67;
  --white: #fff;
  --shadow: 0 18px 50px rgba(53, 44, 30, .09);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: #fff; font-family: "Noto Sans KR", sans-serif; word-break: keep-all; }
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
.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; }

.site-header { position: sticky; top: 0; z-index: 20; background: rgba(255,255,255,.92); border-bottom: 1px solid rgba(32,32,30,.08); backdrop-filter: blur(14px); }
.header-inner { max-width: 1180px; height: 72px; margin: auto; padding: 0 24px; display: flex; align-items: center; gap: 54px; }
.brand { display: flex; align-items: center; gap: 10px; font-size: 21px; font-weight: 800; letter-spacing: -.06em; }
.brand-mark { display: grid; place-items: center; width: 34px; height: 34px; color: #fff; background: var(--orange); border-radius: 10px 10px 10px 3px; font: 700 20px/1 "DM Sans", sans-serif; letter-spacing: 0; }
.header-nav { display: flex; gap: 34px; height: 100%; align-items: center; font-size: 14px; font-weight: 600; color: #77766f; }
.header-nav a { display: flex; height: 100%; align-items: center; position: relative; }
.header-nav .active { color: var(--ink); }
.header-nav .active::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: var(--orange); border-radius: 3px 3px 0 0; }
.saved-button { margin-left: auto; border: 1px solid var(--line); border-radius: 999px; background: #fff; padding: 9px 14px; cursor: pointer; color: #55544f; font-size: 13px; font-weight: 600; }
.saved-button > svg { width: 17px; height: 17px; margin-right: 4px; color: var(--orange); vertical-align: -4px; }
.saved-button strong { display: inline-grid; place-items: center; min-width: 20px; height: 20px; margin-left: 3px; border-radius: 50%; color: #fff; background: var(--orange); font-size: 11px; }
.saved-button[aria-pressed="true"] { border-color: var(--orange); color: var(--orange-dark); background: #fff7f4; }

.hero { overflow: hidden; background: var(--cream); }
.hero-inner { min-height: 490px; max-width: 1180px; margin: auto; padding: 62px 24px 56px; display: grid; grid-template-columns: 1.12fr .88fr; align-items: center; }
.eyebrow, .section-kicker { color: var(--orange-dark); font: 700 12px/1.4 "DM Sans", "Noto Sans KR", sans-serif; letter-spacing: .12em; }
.hero h1 { margin: 17px 0 20px; font-size: clamp(42px, 5vw, 66px); line-height: 1.16; letter-spacing: -.065em; }
.hero h1 em { position: relative; z-index: 1; color: var(--orange); font-style: normal; }
.hero h1 em::after { content: ""; position: absolute; z-index: -1; left: 0; right: -4px; bottom: 4px; height: 13px; background: var(--yellow); opacity: .7; transform: rotate(-1deg); }
.hero-copy > p { margin: 0 0 30px; color: #6d6b63; font-size: 16px; line-height: 1.8; }
.hero-cta { display: inline-flex; align-items: center; gap: 18px; padding: 14px 20px; color: #fff; background: var(--ink); border-radius: 5px; font-weight: 700; font-size: 14px; transition: transform .2s, background .2s; }
.hero-cta svg { width: 18px; height: 18px; }
.hero-cta:hover { transform: translateY(-2px); background: var(--orange-dark); }
.hero-art { position: relative; min-height: 360px; display: grid; place-items: center; }
.calendar-card { position: relative; z-index: 3; width: 230px; height: 252px; display: flex; flex-direction: column; align-items: center; padding-top: 39px; background: #fff; border: 2px solid var(--ink); border-radius: 14px; box-shadow: 13px 14px 0 var(--yellow); transform: rotate(2deg); }
.calendar-top { position: absolute; inset: 0 0 auto; height: 38px; display: flex; align-items: center; justify-content: center; gap: 42px; background: var(--orange); border-bottom: 2px solid var(--ink); border-radius: 11px 11px 0 0; }
.calendar-top span { width: 8px; height: 18px; margin-top: -20px; border: 2px solid var(--ink); border-radius: 6px; background: #fff; }
.calendar-card strong { margin-top: 18px; color: var(--orange); font: 700 16px "DM Sans"; letter-spacing: .16em; }
.calendar-card b { font: 700 86px/.95 "DM Sans"; letter-spacing: -.06em; }
.calendar-card small { margin-top: 11px; font: 700 10px "DM Sans"; letter-spacing: .14em; }
.orbit { position: absolute; border-radius: 50%; border: 1px solid #d4d0c4; }
.orbit-one { width: 390px; height: 390px; }
.orbit-two { width: 285px; height: 285px; border-style: dashed; }
.float-tag { position: absolute; z-index: 4; padding: 10px 14px; background: #fff; border: 1.5px solid var(--ink); border-radius: 6px; box-shadow: 4px 4px 0 rgba(32,32,30,.12); font-size: 12px; font-weight: 700; }
.float-tag svg { width: 18px; height: 18px; margin-right: 5px; vertical-align: -5px; }
.tag-one { top: 60px; left: 9%; transform: rotate(-6deg); }
.tag-two { right: 2%; bottom: 54px; transform: rotate(5deg); }
.spark { position: absolute; color: var(--orange); font-size: 30px; }
.spark svg { width: 30px; height: 30px; }
.spark-one { top: 32px; right: 14%; }
.spark-two { bottom: 20px; left: 18%; color: var(--green); font-size: 22px; }

.quick-stats { max-width: 1180px; min-height: 106px; margin: -1px auto 0; padding: 0 24px; display: flex; align-items: center; border-bottom: 1px solid var(--line); }
.quick-stats > div { min-width: 176px; display: flex; align-items: baseline; gap: 10px; }
.quick-stats strong { font: 700 25px "DM Sans", "Noto Sans KR"; }
.quick-stats span { color: var(--muted); font-size: 12px; }
.quick-stats > p { margin-left: auto; color: #95938c; font-size: 11px; }
.live-dot { display: inline-block; width: 7px; height: 7px; margin-right: 6px; border-radius: 50%; background: #34ad72; }

.events-section { max-width: 1180px; margin: auto; padding: 86px 24px 100px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; margin-bottom: 30px; }
.section-heading h2, .guide-section h2 { margin: 9px 0 0; font-size: 34px; letter-spacing: -.055em; }
.section-heading > p { margin: 0 0 3px; color: var(--muted); font-size: 13px; }
.filter-panel { display: grid; grid-template-columns: minmax(245px, 1fr) auto 150px; gap: 12px; padding: 14px; background: var(--cream); border-radius: 10px; }
.search-box { min-width: 0; height: 46px; padding: 0 15px; display: flex; align-items: center; gap: 10px; background: #fff; border: 1px solid #e6e2d9; border-radius: 6px; }
.search-box > svg { width: 19px; height: 19px; color: #9a9890; }
.search-box input { width: 100%; border: 0; outline: 0; color: var(--ink); background: transparent; font-size: 13px; }
.filter-chips { display: flex; gap: 5px; align-items: center; }
.filter-chip { min-width: 48px; height: 36px; border: 0; border-radius: 999px; background: transparent; color: #77756e; cursor: pointer; font-size: 12px; font-weight: 600; }
.filter-chip.active { color: #fff; background: var(--ink); }
.select-box, .select-box select { width: 100%; }
.select-box select, #sortSelect { height: 46px; padding: 0 34px 0 13px; appearance: none; border: 1px solid #e6e2d9; border-radius: 6px; outline: 0; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='m1 1 5 5 5-5' fill='none' stroke='%23666' stroke-width='1.5'/%3E%3C/svg%3E") no-repeat right 12px center; color: #55534d; font-size: 12px; }
.result-toolbar { height: 71px; display: flex; align-items: center; justify-content: space-between; }
.result-toolbar p { color: #77756e; font-size: 13px; }
.result-toolbar p strong { color: var(--orange-dark); }
#sortSelect { width: 125px; height: 34px; border: 0; padding-left: 4px; }
.event-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.event-card { position: relative; overflow: hidden; background: #fff; border: 1px solid var(--line); border-radius: 10px; transition: transform .25s, box-shadow .25s; }
.event-card:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.card-visual { position: relative; height: 152px; padding: 23px; overflow: hidden; background: var(--card-bg); }
.card-visual::before, .card-visual::after { content: ""; position: absolute; border-radius: 50%; background: var(--card-accent); opacity: .55; }
.card-visual::before { width: 170px; height: 170px; right: -47px; bottom: -90px; }
.card-visual::after { width: 68px; height: 68px; right: 52px; top: -28px; opacity: .28; }
.poster-copy { position: relative; z-index: 1; width: 72%; }
.poster-copy small { font: 700 9px "DM Sans"; letter-spacing: .12em; }
.poster-copy h3 { margin: 9px 0 0; font-size: 20px; line-height: 1.3; letter-spacing: -.045em; }
.poster-icon { position: absolute; z-index: 1; right: 23px; bottom: 14px; width: 48px; height: 48px; color: var(--card-accent); filter: drop-shadow(2px 3px 0 rgba(255,255,255,.7)); }
.poster-icon svg, .dialog-visual svg { width: 100%; height: 100%; }
.status-badge { position: absolute; z-index: 2; left: 16px; top: 16px; padding: 5px 9px; color: #fff; background: var(--orange); border-radius: 4px; font-size: 10px; font-weight: 700; }
.status-badge.ongoing { background: var(--green); }
.save-card { position: absolute; z-index: 4; top: 12px; right: 12px; width: 34px; height: 34px; display: grid; place-items: center; border: 0; border-radius: 50%; color: #6b6963; background: rgba(255,255,255,.9); box-shadow: 0 3px 12px rgba(0,0,0,.08); cursor: pointer; font-size: 20px; }
.save-card svg { width: 18px; height: 18px; }
.save-card.saved { color: var(--orange); }
.card-body { padding: 20px; }
.date-line { margin: 0 0 7px; color: var(--orange-dark); font: 700 12px "DM Sans", "Noto Sans KR"; }
.card-body h3 { margin: 0 0 14px; min-height: 49px; font-size: 17px; line-height: 1.45; letter-spacing: -.035em; }
.meta-list { display: grid; gap: 7px; margin-bottom: 18px; color: #79776f; font-size: 12px; }
.meta-list span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.meta-list i { display: inline-block; width: 18px; height: 14px; vertical-align: -2px; font-style: normal; }
.meta-list i svg { width: 14px; height: 14px; }
.card-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.card-actions button, .card-actions .register-link { height: 40px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 5px; background: #fff; cursor: pointer; font-size: 12px; font-weight: 700; }
.card-actions .register-link { color: #fff; border-color: var(--orange); background: var(--orange); }
.card-actions .register-link:hover { background: var(--orange-dark); }
.card-actions .register-link.is-pending { color: #85827a; border-color: #dedbd3; background: #eeece6; cursor: not-allowed; }
.empty-state { padding: 80px 20px; text-align: center; border: 1px dashed #ddd8cc; border-radius: 10px; background: #fbfaf7; }
.empty-state > span svg { width: 38px; height: 38px; }
.empty-state h3 { margin: 14px 0 6px; }
.empty-state p { margin: 0 0 18px; color: var(--muted); font-size: 13px; }
.empty-state button { padding: 9px 15px; border: 0; border-radius: 5px; color: #fff; background: var(--ink); cursor: pointer; }

.guide-section { max-width: 1180px; margin: 0 auto 100px; padding: 44px 46px; display: grid; grid-template-columns: .85fr 1.6fr; align-items: center; background: var(--cream); border-radius: 12px; }
.guide-section ol { display: grid; grid-template-columns: repeat(3,1fr); list-style: none; margin: 0; padding: 0; }
.guide-section li { padding: 0 25px; display: flex; flex-direction: column; border-left: 1px solid #dedbd2; }
.guide-section li b { margin-bottom: 15px; color: var(--orange); font: 700 13px "DM Sans"; }
.guide-section li strong { font-size: 14px; }
.guide-section li span { margin-top: 5px; color: var(--muted); font-size: 11px; }

footer { padding: 45px 0; color: #b4b2aa; background: var(--ink); }
.footer-inner { max-width: 1180px; margin: auto; padding: 0 24px; display: flex; justify-content: space-between; align-items: end; }
.footer-brand { width: max-content; color: #fff; }
.footer-brand + p { margin: 11px 0 0; font-size: 11px; }
.disclaimer { max-width: 620px; margin: 0; text-align: right; font-size: 10px; line-height: 1.8; }
.event-dialog { width: min(520px, calc(100% - 32px)); padding: 0; border: 0; border-radius: 14px; box-shadow: 0 30px 90px rgba(0,0,0,.24); }
.event-dialog::backdrop { background: rgba(20,20,18,.55); backdrop-filter: blur(3px); }
.dialog-close { position: absolute; z-index: 3; top: 12px; right: 12px; width: 34px; height: 34px; display: grid; place-items: center; border: 0; border-radius: 50%; background: rgba(255,255,255,.9); cursor: pointer; }
.dialog-close svg { width: 18px; height: 18px; }
.dialog-visual { height: 180px; display: grid; place-items: center; background: var(--card-bg); }
.dialog-visual svg { width: 65px; height: 65px; color: rgba(255,255,255,.8); }
.dialog-body { padding: 26px 28px 30px; }
.dialog-body .date-line { margin-bottom: 8px; }
.dialog-body h2 { margin: 0 0 20px; font-size: 23px; }
.dialog-info { display: grid; grid-template-columns: 68px 1fr; gap: 10px; margin-bottom: 24px; font-size: 13px; }
.dialog-info dt { color: var(--muted); }
.dialog-info dd { margin: 0; }
.dialog-register { height: 48px; display: grid; place-items: center; color: #fff; background: var(--orange); border-radius: 6px; font-weight: 700; font-size: 14px; }
.dialog-register.is-pending { color: #85827a; border: 1px solid #dedbd3; background: #eeece6; cursor: not-allowed; }

@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr .8fr; }
  .filter-panel { grid-template-columns: 1fr 150px; }
  .filter-chips { grid-column: 1 / -1; grid-row: 2; overflow-x: auto; }
  .event-grid { grid-template-columns: repeat(2, 1fr); }
  .guide-section { margin-inline: 24px; grid-template-columns: 1fr; gap: 34px; }
}

@media (max-width: 640px) {
  .header-inner { height: 62px; padding: 0 17px; gap: 0; }
  .header-nav { display: none; }
  .saved-button { padding: 7px 10px; }
  .hero-inner { min-height: auto; padding: 48px 20px 35px; display: block; }
  .hero h1 { font-size: 41px; }
  .desktop-only { display: none; }
  .hero-art { min-height: 290px; transform: scale(.82); margin: -10px -30px -20px; }
  .quick-stats { min-height: 90px; padding: 0 20px; gap: 24px; overflow-x: auto; }
  .quick-stats > div { min-width: 120px; flex-direction: column; gap: 1px; }
  .quick-stats > p { display: none; }
  .events-section { padding: 65px 17px 76px; }
  .section-heading { display: block; }
  .section-heading h2, .guide-section h2 { font-size: 29px; }
  .section-heading > p { margin-top: 10px; }
  .filter-panel { grid-template-columns: 1fr; }
  .filter-chips { grid-column: 1; grid-row: auto; }
  .event-grid { grid-template-columns: 1fr; }
  .guide-section { margin: 0 17px 70px; padding: 35px 25px; }
  .guide-section ol { grid-template-columns: 1fr; gap: 20px; }
  .guide-section li { padding: 0 0 0 18px; }
  .guide-section li b { margin-bottom: 4px; }
  .footer-inner { align-items: start; flex-direction: column; gap: 25px; }
  .disclaimer { text-align: left; }
}

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }
