function MissionDetail({ nav, ended, mstate }) {
  const { Button, Badge } = window.SpotureDesignSystem_f7ad96;
  const params = new URLSearchParams(location.search);
  const state = mstate || params.get('mstate') || 'intro';
  const MY_HANDLE = 'gukbap_lover92';
  const ENDED_BASE = {
    name: '새벽 국밥 인증 챌린지', period: '2026-07-01 ~ 2026-07-31', goal: 3,
    reward: '국밥교환권 (100명 추첨)', lottery: true, prizeCount: 100, drawDate: '2026-07-28',
    joinedCount: 742, doneCount: 486,
    winners: [['미도리', 'midori_eats'], ['국밥러버', 'gukbap_lover92'], ['수아', 'sua_9'], ['도윤', 'doyun'], ['예린', 'yerin.k'], ['민서', 'minseo.eat'], ['준호', 'junho_88'], ['채원', 'chaewon.s']]
  };
  const ENDED_VARIANTS = {
    ended: { now: 3, achieved: true, won: true, rewardState: '당첨', rank: 42, percentile: 6, note: '7/28 발표 · 스폰서가 개별 안내드렸어요' },
    endedLost: { now: 3, achieved: true, won: false, rewardState: '미당첨', rank: 203, percentile: 42, note: '완주는 했지만 아쉽게 추첨에서 빠졌어요. 다음 챌린지 응모권 1매를 드렸어요.' },
    endedMiss: { now: 1, achieved: false, won: false, rewardState: '미완주 (1/3)', rank: null, percentile: null, note: '인증 1장에서 기간이 끝나 추첨 대상에 오르지 못했어요. 다음 챌린지에 다시 도전해 보세요.' }
  };
  const E = ended || (ENDED_VARIANTS[state] ? Object.assign({}, ENDED_BASE, ENDED_VARIANTS[state]) : null);
  const WINNERS = E ? (E.won === false
    ? ((E.winners) || []).map(w => w[1] === MY_HANDLE ? ['하늘', 'haneul_92'] : w)
    : (E.winners || [])) : [];
  const mask = h => h.length <= 3 ? h[0] + '**' : h.slice(0, 3) + '*'.repeat(Math.min(5, h.length - 3));
  if (E) return (
    <div style={{ flex: '1 1 0%', minHeight: 0, display: 'flex', flexDirection: 'column', position: 'relative' }}>
      <StatusBar />
      <ScreenHeader title={E.name} sub={'종료된 챌린지 · ' + E.period} onBack={() => E.from === 'missions' ? nav('missions', { initialTab: '종료' }) : E.from === 'feed' ? nav('feed') : nav('profile')} />
      <div style={{ flex: '1 1 0%', minHeight: 0, overflowY: 'auto', padding: '0 20px 190px' }}>
        <div style={{ background: 'var(--bg-ink)', borderRadius: 'var(--radius-card)', overflow: 'hidden', boxShadow: 'var(--shadow-float)', marginBottom: 16 }}>
          <div style={{ height: 132, position: 'relative' }}>
            <img src="../../assets/feed/mukeunji-jjim.jpeg" alt="" style={{ width: '100%', height: '100%', objectFit: 'cover', display: 'block', opacity: .82 }} />
            <span style={{ position: 'absolute', left: 14, top: 14, font: '700 11px/1 var(--font-family)', color: 'rgba(255,255,255,.72)', background: 'rgba(0,0,0,.5)', borderRadius: 999, padding: '7px 11px', letterSpacing: '.04em' }}>종료</span>
          </div>
          <div style={{ padding: 18 }}>
            <span style={{ font: 'var(--text-heading)', color: '#fff', display: 'block', marginBottom: 6 }}>{E.name}</span>
            <p style={{ font: 'var(--text-caption)', color: 'rgba(255,255,255,.68)', margin: '0 0 14px', lineHeight: 1.6 }}>{E.period} 진행 · {E.lottery ? E.drawDate + ' 추첨 발표' : '완주 시 ' + E.reward + ' 지급'}</p>
            <div style={{ display: 'flex', gap: 18 }}>
              {[['참여자', E.joinedCount.toLocaleString() + '명'], ['완주', E.doneCount.toLocaleString() + '명'], ['보상', E.reward.split(' (')[0]]].map(([k, v]) => (
                <div key={k}>
                  <span style={{ font: '700 15px/1 var(--font-family)', color: '#fff', display: 'block', marginBottom: 4 }}>{v}</span>
                  <span style={{ font: 'var(--text-micro)', color: 'rgba(255,255,255,.5)' }}>{k}</span>
                </div>
              ))}
            </div>
          </div>
        </div>
        <div style={{ background: 'var(--surface-1)', border: '1.5px solid ' + (E.won ? 'var(--text-success)' : 'var(--border-strong)'), borderRadius: 'var(--radius-card)', padding: 16, marginBottom: 22 }}>
          <div style={{ display: 'flex', alignItems: 'center', gap: 10, marginBottom: 8 }}>
            <i className={'ti ti-' + (E.won ? 'trophy' : E.achieved ? 'flag-check' : 'flag-off')} style={{ fontSize: 18, color: E.won ? 'var(--text-success)' : 'var(--text-muted)', flexShrink: 0 }}></i>
            <span style={{ font: 'var(--text-body-strong)' }}>{E.won ? '당첨되었어요' : E.achieved ? '완주했지만 미당첨이에요' : '완주하지 못했어요'}</span>
          </div>
          <p style={{ font: 'var(--text-caption)', color: 'var(--text-secondary)', margin: '0 0 12px', lineHeight: 1.6 }}>{E.note}</p>
          <div style={{ display: 'grid', gridTemplateColumns: 'repeat(3,1fr)', gap: 1, background: 'var(--border)', border: '1px solid var(--border)', borderRadius: 'var(--radius-tile)', overflow: 'hidden' }}>
            {[['내 기록', E.now + '/' + E.goal], ['완주 순위', E.rank ? E.rank + '위' : '—'], ['상위', E.percentile ? E.percentile + '%' : '—']].map(([k, v]) => (
              <div key={k} style={{ background: 'var(--surface-1)', padding: '12px 10px', textAlign: 'center' }}>
                <span style={{ font: '700 15px/1 var(--font-family)', display: 'block', marginBottom: 4 }}>{v}</span>
                <span style={{ font: 'var(--text-micro)', color: 'var(--text-muted)' }}>{k}</span>
              </div>
            ))}
          </div>
        </div>
        {E.lottery && WINNERS.length > 0 && <React.Fragment>
        <span style={{ font: 'var(--text-heading)', display: 'block', marginBottom: 10 }}>당첨자 발표</span>
        <div style={{ background: 'var(--surface-1)', borderRadius: 'var(--radius-card)', boxShadow: 'var(--shadow-card)', overflow: 'hidden', marginBottom: 12 }}>
          {WINNERS.map((w, i) => {
            const me = w[1] === MY_HANDLE;
            return (
              <div key={w[1]} style={{ display: 'flex', alignItems: 'center', gap: 12, padding: '13px 16px', borderTop: i === 0 ? 'none' : '1px solid var(--border)', background: me ? 'var(--bg-success)' : 'transparent' }}>
                <span style={{ width: 22, font: '600 12px/1 var(--font-family)', color: 'var(--text-muted)', flexShrink: 0 }}>{i + 1}</span>
                <div style={{ width: 30, height: 30, borderRadius: '50%', background: 'var(--surface-2)', display: 'flex', alignItems: 'center', justifyContent: 'center', flexShrink: 0, font: '700 12px/1 var(--font-family)', color: 'var(--text-secondary)' }}>{w[0].slice(0, 1)}</div>
                <span style={{ flex: 1, minWidth: 0, font: 'var(--text-body)' }}>{w[0]}<span style={{ color: 'var(--text-muted)' }}>{' @' + mask(w[1])}</span></span>
                {me && <span style={{ font: '600 11px/1 var(--font-family)', color: 'var(--text-success)', flexShrink: 0 }}>나</span>}
              </div>
            );
          })}
          <div style={{ padding: '13px 16px', borderTop: '1px solid var(--border)', font: 'var(--text-small)', color: 'var(--text-muted)', textAlign: 'center' }}>외 {(E.prizeCount - WINNERS.length).toLocaleString()}명 · 개인정보 보호를 위해 아이디는 일부만 표시돼요</div>
        </div>
        </React.Fragment>}
        <span style={{ font: 'var(--text-heading)', display: 'block', marginBottom: 10 }}>결과 요약</span>
        <div style={{ background: 'var(--surface-1)', borderRadius: 'var(--radius-card)', padding: '4px 16px', boxShadow: 'var(--shadow-card)', marginBottom: 22 }}>
          {[['진행 기간', E.period], ['참여자', E.joinedCount.toLocaleString() + '명'], ['완주자', E.doneCount.toLocaleString() + '명 (' + Math.round(E.doneCount / E.joinedCount * 100) + '%)'], ['보상', E.reward]]
            .concat(E.lottery ? [['당첨 인원', E.prizeCount.toLocaleString() + '명 추첨'], ['당첨 확률', '완주자 기준 ' + Math.round(E.prizeCount / E.doneCount * 100) + '%'], ['추첨 발표', E.drawDate]] : [['달성 조건', E.goal + '곳 방문 인증']])
            .concat([['완주 순위', E.rank ? E.doneCount.toLocaleString() + '명 중 ' + E.rank + '위 (상위 ' + E.percentile + '%)' : '완주자만 집계돼요'], ['내 결과', E.rewardState]]).map((r, i) => (
            <div key={r[0]} style={{ display: 'flex', alignItems: 'flex-start', justifyContent: 'space-between', gap: 16, padding: '13px 0', borderTop: i === 0 ? 'none' : '1px solid var(--border)' }}>
              <span style={{ font: 'var(--text-small)', color: 'var(--text-secondary)', flexShrink: 0 }}>{r[0]}</span>
              <span style={{ font: 'var(--text-small)', fontWeight: 600, textAlign: 'right' }}>{r[1]}</span>
            </div>
          ))}
        </div>
      </div>
      <div style={{ position: 'absolute', left: 0, right: 0, bottom: 88, padding: '0 20px 8px', pointerEvents: 'none' }}><div style={{ pointerEvents: 'auto' }}>
        <Button variant="secondary" onClick={() => E.from === 'missions' ? nav('missions', { initialTab: '종료' }) : E.from === 'feed' ? nav('feed') : nav('profile')}>{E.from === 'missions' ? '미션 목록으로' : E.from === 'feed' ? '피드로 돌아가기' : '내 챌린지로'}</Button>
      </div></div>
    </div>
  );
  const [agree, setAgree] = React.useState(state !== 'intro');
  const shots = [{ ok: true, tag: '밀키트 패키지', img: '../../assets/feed/hanwoo-raw.jpeg' }, { ok: state !== 'intro', tag: '조리 과정', img: '../../assets/feed/kimchi-jjigae.jpeg' }, { ok: false, tag: '완성 한 상', img: '../../assets/feed/steak-platter.jpeg' }];
  const doneCount = state === 'intro' ? 0 : state === 'progress' ? 1 : 3;
  const MSN = { need: 3, minPhotos: 2, tag: '밀키트' };
  const MTAG = '#' + String(MSN.tag).replace(/^#+/, '');
  const rules = [
    { icon: 'article', label: '게시물 ' + MSN.need + '건 올리기', sub: '기간 안에 서로 다른 게시물 ' + MSN.need + '건을 올려야 완주예요' },
    { icon: 'photo', label: '게시물당 사진 ' + MSN.minPhotos + '장 이상', sub: '밀키트 패키지 · 조리 과정 · 완성 한 상' },
    { icon: 'map-pin', label: '위치는 집 또는 실내', sub: '주소는 공개되지 않고 동네 단위만 표시돼요' },
    { icon: 'calendar', label: '기간 내 업로드', sub: '8월 1일 ~ 8월 21일 23:59' },
    { icon: 'tag', label: '메뉴 태그 필수', sub: MTAG + ' 태그가 있어야 인증돼요' }
  ];
  const statusCard = {
    progress: { tone: 'warning', icon: 'progress', title: '인증 진행 중 · 1/3건', body: '게시물 2건을 더 올리면 응모가 완료돼요. 한 건에 사진 2장 이상 담아주세요.', cta: '게시물 이어서 올리기', go: 'upload' },
    review: { tone: 'warning', icon: 'clock', title: '심사 중', body: '스폰서 미션은 담당자가 사진을 확인해요. 보통 1~2일 안에 결과를 알려드려요.', cta: '내 인증 사진 보기', go: 'profile' },
    done: { tone: 'success', icon: 'ticket', title: '응모 완료 · 응모권 1장', body: '추첨 결과는 8월 25일 알림으로 보내드려요. 행운을 빌어요!', cta: '내 응모 내역 보기', go: 'profile' },
    announced: { tone: 'success', icon: 'trophy', title: '결과가 발표됐어요', body: '8월 25일 추첨이 끝났어요. 내 결과와 당첨자 명단을 확인해 보세요.', cta: '결과 확인하기', go: 'result' },
    rejected: { tone: 'danger', icon: 'alert-triangle', title: '인증 1장이 반려됐어요', body: '완성 한 상 사진에서 밀키트 패키지가 보이지 않았어요. 사유를 확인하고 그 사진만 다시 올리면 재심사됩니다.', cta: '반려 사유 자세히 보기', go: 'missionRejection' }
  }[state];
  return (
    <div style={{ flex: '1 1 0%', minHeight: 0, display: 'flex', flexDirection: 'column', position: 'relative' }}>
      <StatusBar />
      <ScreenHeader title="이달의 밀키트 인증샷" sub="스폰서 미션 · 남은 기간 6일" onBack={() => nav('feed')} />
      <div style={{ flex: '1 1 0%', minHeight: 0, overflowY: 'auto', padding: '0 20px 190px' }}>
        <div style={{ background: 'var(--bg-ink)', borderRadius: 'var(--radius-card)', overflow: 'hidden', boxShadow: 'var(--shadow-float)', marginBottom: 16 }}>
          <div style={{ height: 132, background: 'rgba(255,255,255,.08)', position: 'relative' }}>
            <img src="../../assets/feed/steak-platter.jpeg" alt="" style={{ width: '100%', height: '100%', objectFit: 'cover', display: 'block' }} />
            <span style={{ position: 'absolute', left: 14, top: 14, font: '700 11px/1 var(--font-family)', color: '#fff', background: 'var(--text-accent)', borderRadius: 999, padding: '7px 11px', letterSpacing: '.04em' }}>SPONSORED</span>
          </div>
          <div style={{ padding: 18 }}>
            <span style={{ font: 'var(--text-heading)', color: '#fff', display: 'block', marginBottom: 6 }}>이달의 밀키트 인증샷</span>
            <p style={{ font: 'var(--text-caption)', color: 'rgba(255,255,255,.68)', margin: '0 0 14px', lineHeight: 1.6 }}>집에서 만든 밀키트 한 상을 올려주세요. 사진 2장 이상 담긴 게시물 3건을 올리면 응모권 2매를 드리고, 8월 25일 추첨으로 30명께 밀키트 6종 세트를 보내드려요.</p>
            <div style={{ display: 'flex', gap: 18 }}>
              {[['참여자', '1,284명'], ['경품', '밀키트 6종 세트'], ['당첨', '30명 추첨']].map(([k, v]) => (
                <div key={k}>
                  <span style={{ font: '700 15px/1 var(--font-family)', color: '#fff', display: 'block', marginBottom: 4 }}>{v}</span>
                  <span style={{ font: 'var(--text-micro)', color: 'rgba(255,255,255,.5)' }}>{k}</span>
                </div>
              ))}
            </div>
          </div>
        </div>
        {(state === 'review' || state === 'done' || state === 'announced') && (
          <div style={{ display: 'flex', alignItems: 'center', gap: 12, background: state === 'announced' ? 'var(--bg-success)' : 'var(--surface-2)', borderRadius: 'var(--radius-tile)', padding: '13px 16px', marginBottom: 12 }}>
            <i className={'ti ti-' + (state === 'announced' ? 'confetti' : 'hourglass')} style={{ fontSize: 17, color: state === 'announced' ? 'var(--text-success)' : 'var(--text-secondary)', flexShrink: 0 }}></i>
            <div style={{ flex: 1, minWidth: 0 }}>
              <span style={{ font: 'var(--text-body-strong)', display: 'block', marginBottom: 2 }}>{state === 'announced' ? '추첨 발표 완료 · 8월 25일' : '추첨 발표까지 D-6'}</span>
              <span style={{ font: 'var(--text-small)', color: 'var(--text-secondary)' }}>{state === 'announced' ? '결과는 미션 상세와 알림에서 확인할 수 있어요' : '8월 25일 오후 6시 · 발표되면 알림으로 알려드려요'}</span>
            </div>
          </div>
        )}
        {statusCard && (
          <div style={{ background: 'var(--surface-1)', border: '1.5px solid ' + (statusCard.tone === 'success' ? 'var(--text-success)' : statusCard.tone === 'danger' ? 'var(--text-danger)' : 'var(--text-warning)'), borderRadius: 'var(--radius-card)', padding: 16, marginBottom: 16 }}>
            <div style={{ display: 'flex', alignItems: 'center', gap: 10, marginBottom: 8 }}>
              <i className={'ti ti-' + statusCard.icon} style={{ fontSize: 18, color: statusCard.tone === 'success' ? 'var(--text-success)' : statusCard.tone === 'danger' ? 'var(--text-danger)' : 'var(--text-warning)', flexShrink: 0 }}></i>
              <span style={{ font: 'var(--text-body-strong)' }}>{statusCard.title}</span>
            </div>
            <p style={{ font: 'var(--text-caption)', color: 'var(--text-secondary)', margin: '0 0 12px', lineHeight: 1.6 }}>{statusCard.body}</p>
            <Button variant="secondary" size="sm" onClick={() => statusCard.go === 'result' ? nav('missionDetail', { ended: Object.assign({}, ENDED_BASE, ENDED_VARIANTS.ended, { name: '이달의 밀키트 인증샷', period: '2026-08-01 ~ 2026-08-21', reward: '밀키트 6종 세트 (30명 추첨)', prizeCount: 30, drawDate: '2026-08-25', note: '8/25 발표 · 스폰서가 개별 안내드렸어요', from: 'feed' }) }) : statusCard.go === 'missionRejection' ? nav('missionRejection', { from: 'missionDetail' }) : nav(statusCard.go)}>{statusCard.cta}</Button>
          </div>
        )}
        <span style={{ font: 'var(--text-heading)', display: 'block', marginBottom: 10 }}>인증 게시물 {doneCount}/3건 · 건당 사진 2장 이상</span>
        <div style={{ display: 'grid', gridTemplateColumns: 'repeat(3,1fr)', gap: 8, marginBottom: 22 }}>
          {shots.map((s, i) => {
            const ok = i < doneCount;
            return (
              <div key={s.tag}>
                <div style={{ width: '100%', aspectRatio: '1', borderRadius: 'var(--radius-tile)', background: 'var(--surface-2)', border: ok ? 'none' : '1.5px dashed var(--border-strong)', boxSizing: 'border-box', display: 'flex', alignItems: 'center', justifyContent: 'center', position: 'relative', marginBottom: 6, overflow: 'hidden' }}>
                  <img src={s.img} alt="" style={{ position: 'absolute', inset: 0, width: '100%', height: '100%', objectFit: 'cover', opacity: ok ? 1 : .22 }} />
                  {ok
                    ? <span style={{ position: 'absolute', right: 6, bottom: 6, width: 22, height: 22, borderRadius: '50%', background: 'var(--text-success)', display: 'flex', alignItems: 'center', justifyContent: 'center' }}><i className="ti ti-check" style={{ fontSize: 13, color: '#fff' }}></i></span>
                    : <i className="ti ti-camera" style={{ fontSize: 20, color: 'var(--text-muted)', position: 'relative' }}></i>}
                  <span style={{ position: 'absolute', left: 6, top: 6, font: 'var(--text-micro)', color: ok ? '#fff' : 'var(--text-muted)', textShadow: ok ? '0 1px 3px rgba(0,0,0,.5)' : 'none' }}>{i + 1}</span>
                </div>
                <span style={{ font: 'var(--text-micro)', color: ok ? 'var(--text-primary)' : 'var(--text-muted)', display: 'block', textAlign: 'center' }}>{s.tag}</span>
              </div>
            );
          })}
        </div>
        <span style={{ font: 'var(--text-heading)', display: 'block', marginBottom: 10 }}>인증 조건</span>
        <div style={{ display: 'flex', flexDirection: 'column', gap: 8, marginBottom: 22 }}>
          {rules.map(r => (
            <div key={r.label} style={{ display: 'flex', alignItems: 'center', gap: 12, background: 'var(--surface-1)', borderRadius: 'var(--radius-tile)', padding: 14, boxShadow: 'var(--shadow-card)' }}>
              <div style={{ width: 38, height: 38, borderRadius: 12, background: 'var(--bg-accent)', display: 'flex', alignItems: 'center', justifyContent: 'center', flexShrink: 0 }}><i className={'ti ti-' + r.icon} style={{ fontSize: 17, color: 'var(--text-accent)' }}></i></div>
              <div style={{ flex: 1, minWidth: 0 }}>
                <span style={{ font: 'var(--text-body-strong)', display: 'block', marginBottom: 2 }}>{r.label}</span>
                <span style={{ font: 'var(--text-small)', color: 'var(--text-secondary)' }}>{r.sub}</span>
              </div>
            </div>
          ))}
        </div>
        <span style={{ font: 'var(--text-heading)', display: 'block', marginBottom: 10 }}>진행 순서</span>
        <div style={{ background: 'var(--surface-1)', borderRadius: 'var(--radius-card)', padding: 18, boxShadow: 'var(--shadow-card)', marginBottom: 22 }}>
          {['게시물 3건 업로드 (건당 사진 2장 이상)', '담당자 심사 (1~2일)', '응모권 발급', '8월 25일 추첨 발표'].map((t, i) => (
            <div key={t} style={{ display: 'flex', alignItems: 'center', gap: 12, marginBottom: i === 3 ? 0 : 12 }}>
              <span style={{ width: 24, height: 24, borderRadius: '50%', flexShrink: 0, background: i < (state === 'announced' ? 4 : state === 'done' ? 3 : state === 'review' ? 2 : state === 'progress' ? 1 : 0) ? 'var(--text-success)' : 'var(--surface-2)', color: i < (state === 'announced' ? 4 : state === 'done' ? 3 : state === 'review' ? 2 : state === 'progress' ? 1 : 0) ? '#fff' : 'var(--text-muted)', font: '600 12px/1 var(--font-family)', display: 'flex', alignItems: 'center', justifyContent: 'center' }}>{i + 1}</span>
              <span style={{ font: 'var(--text-caption)', color: 'var(--text-primary)' }}>{t}</span>
            </div>
          ))}
        </div>
        <span style={{ font: 'var(--text-heading)', display: 'block', marginBottom: 10 }}>유의사항</span>
        <ul style={{ margin: '0 0 18px', padding: '0 0 0 18px' }}>
          {['같은 사진을 여러 미션에 중복 제출할 수 없어요.', '타인의 사진이나 상업용 이미지는 반려됩니다.', '경품 발송을 위해 당첨 후 배송지를 입력해 주세요.', '스폰서는 인증 사진을 홍보에 활용할 수 있어요.'].map(t => (
            <li key={t} style={{ font: 'var(--text-small)', color: 'var(--text-secondary)', lineHeight: 1.7 }}>{t}</li>
          ))}
        </ul>
        {state === 'intro' && (
          <div onClick={() => setAgree(!agree)} style={{ display: 'flex', alignItems: 'center', gap: 10, background: 'var(--surface-1)', borderRadius: 'var(--radius-tile)', padding: 14, boxShadow: 'var(--shadow-card)', cursor: 'pointer' }}>
            <span style={{ width: 22, height: 22, borderRadius: 6, flexShrink: 0, background: agree ? 'var(--text-accent)' : 'var(--surface-2)', border: agree ? 'none' : '1.5px solid var(--border-strong)', display: 'flex', alignItems: 'center', justifyContent: 'center' }}>{agree && <i className="ti ti-check" style={{ fontSize: 14, color: '#fff' }}></i>}</span>
            <span style={{ font: 'var(--text-caption)', color: 'var(--text-primary)' }}>유의사항과 개인정보 활용에 동의합니다</span>
          </div>
        )}
      </div>
      <div style={{ position: 'absolute', left: 0, right: 0, bottom: 88, padding: '0 20px 8px', pointerEvents: 'none' }}><div style={{ pointerEvents: 'auto' }}>
        {state === 'announced'
          ? <Button variant="primary" onClick={() => nav('missionDetail', { ended: Object.assign({}, ENDED_BASE, ENDED_VARIANTS.ended, { name: '이달의 밀키트 인증샷', period: '2026-08-01 ~ 2026-08-21', reward: '밀키트 6종 세트 (30명 추첨)', prizeCount: 30, drawDate: '2026-08-25', note: '8/25 발표 · 스폰서가 개별 안내드렸어요', from: 'feed' }) })}><i className="ti ti-trophy" style={{ fontSize: 17 }}></i>결과 확인하기</Button>
          : state === 'review'
          ? <Button variant="secondary" onClick={() => nav('feed')}>결과를 기다리는 중</Button>
          : state === 'done'
            ? <Button variant="primary" onClick={() => nav('feed')}>피드로 돌아가기</Button>
            : <Button variant="primary" disabled={!agree} onClick={() => nav('uploadMission')}><i className="ti ti-camera" style={{ fontSize: 17 }}></i>{state === 'intro' ? '사진 올리고 참여하기' : state === 'rejected' ? '사진 다시 올리기' : '사진 이어서 올리기'}</Button>}
      </div></div>
    </div>
  );
}
window.MissionDetail = MissionDetail;
