/* ============================================================
   KW All Care Week — 모바일 우선 스타일
   ============================================================ */
:root {
  /* 포스터·광운대 로고의 남색 + 포스터 주황 포인트, 학과 심볼 버건디 */
  --bg: #f4f5f9;
  --surface: #ffffff;
  --surface-2: #eef0f6;
  --text: #1a1d2b;
  --muted: #5d6276;
  --line: #dde0ea;
  --primary: #22389a;
  --primary-ink: #ffffff;
  --primary-soft: #e7ebf8;
  --accent: #e8502a;
  --accent-soft: #fdece6;
  --brand: #8e1622;
  --brand-soft: #f6e5e7;
  --slot: #22389a;
  --slot-soft: rgba(34, 56, 154, 0.14);
  --busy: #c4c7d2;
  --busy-ink: #4f5363;
  --ok: #1d7a4a;
  --ok-soft: #e3f3ea;
  --err: #c0362c;
  --err-soft: #fdecea;
  --info-soft: #eaf0fb;
  --info: #22389a;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(20,30,70,.05), 0 4px 16px rgba(20,30,70,.06);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #12141c;
    --surface: #1b1e29;
    --surface-2: #242838;
    --text: #eceef6;
    --muted: #a3a8bd;
    --line: #333849;
    --primary: #8fa3ff;
    --primary-ink: #0f1430;
    --primary-soft: #262e52;
    --accent: #ff8a66;
    --accent-soft: #3a2520;
    --brand: #ec8b96;
    --brand-soft: #3a2026;
    --slot: #8fa3ff;
    --slot-soft: rgba(143, 163, 255, 0.22);
    --busy: #454a5c;
    --busy-ink: #cfd3e0;
    --ok: #6fcf97;
    --ok-soft: #1d3326;
    --err: #ff8a80;
    --err-soft: #3a1f1d;
    --info-soft: #1e2744;
    --info: #a9b8ff;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Pretendard", "Noto Sans KR", "Malgun Gothic", sans-serif;
  font-size: 16px;
  line-height: 1.55;
  word-break: keep-all;
}
a { color: var(--primary); }
h1 { font-size: 1.35rem; margin: 0 0 .75rem; line-height: 1.35; }
h2 { font-size: 1.05rem; margin: 0 0 .5rem; }
small { color: var(--muted); }

/* 헤더 */
.site-header {
  display: flex; align-items: baseline; gap: .6rem; flex-wrap: wrap;
  padding: .9rem 16px; background: var(--surface); border-bottom: 1px solid var(--line);
}
.logo { font-weight: 800; color: var(--primary); text-decoration: none; letter-spacing: -.01em; }
.logo-sub { font-size: .85rem; color: var(--muted); }
.site-header nav { margin-left: auto; display: flex; gap: .75rem; font-size: .9rem; }

.page { max-width: 720px; margin: 0 auto; padding: 1.25rem 16px 4rem; }

/* 단계 표시 */
.steps { display: flex; gap: .35rem; list-style: none; padding: 0; margin: 0 0 1.25rem; counter-reset: s; }
.steps li {
  flex: 1; text-align: center; font-size: .78rem; color: var(--muted);
  padding-top: .45rem; border-top: 3px solid var(--line);
}
.steps li.past { border-color: var(--primary); color: var(--text); }
.steps li.current { border-color: var(--primary); color: var(--primary); font-weight: 700; }

/* 안내 */
.notice { padding: .8rem 1rem; border-radius: 10px; margin-bottom: 1rem; font-size: .95rem; }
.notice.info { background: var(--info-soft); color: var(--info); }
.notice.error { background: var(--err-soft); color: var(--err); font-weight: 600; }
.hint { color: var(--muted); font-size: .9rem; margin: 0 0 .9rem; }

/* 유형 카드 */
.cards { display: grid; gap: .75rem; }
.card, .choice {
  display: flex; flex-direction: column; gap: .2rem; text-align: left;
  width: 100%; padding: 1rem 1.1rem; border-radius: var(--radius);
  background: var(--surface); border: 1.5px solid var(--line); color: var(--text);
  font: inherit; cursor: pointer; box-shadow: var(--shadow);
  transition: border-color .15s, transform .05s;
}
.card strong { font-size: 1.1rem; }
.card span { color: var(--text); }
.card:hover:not(:disabled), .choice:hover { border-color: var(--primary); }
.card:active:not(:disabled) { transform: scale(.99); }
.card:disabled { opacity: .5; cursor: not-allowed; }

.choice-list { display: grid; gap: .6rem; }
.choice { flex-direction: row; align-items: center; font-weight: 600; min-height: 56px; }
.choice.check { gap: .8rem; font-weight: 400; }
.choice.check span { display: flex; flex-direction: column; }
.choice.check input { width: 22px; height: 22px; accent-color: var(--primary); flex: none; }
.choice.disabled { opacity: .5; cursor: not-allowed; }

/* 버튼 */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 1.4rem; border-radius: 12px; border: 1.5px solid var(--primary);
  background: var(--primary); color: var(--primary-ink); font: inherit; font-weight: 700;
  text-decoration: none; cursor: pointer;
}
.btn.ghost { background: transparent; color: var(--primary); }
.btn.small { min-height: 40px; padding: 0 1rem; font-size: .9rem; }
.btn:disabled { opacity: .6; cursor: wait; }
.nav { display: flex; gap: .6rem; justify-content: space-between; margin-top: 1.5rem; }
.nav .btn { flex: 1; }
.row-actions { display: flex; gap: .5rem; margin-top: .6rem; }

/* 폼 */
label { display: flex; flex-direction: column; gap: .3rem; font-size: .9rem; font-weight: 600; margin-bottom: .8rem; }
input[type="text"], input[type="email"], input[type="tel"], input[type="date"], input[type="time"],
input[type="password"], select, textarea {
  font: inherit; font-weight: 400; width: 100%; min-height: 46px; padding: .55rem .75rem;
  border: 1.5px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--text);
}
textarea { min-height: 90px; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--primary); outline-offset: 1px; border-color: transparent; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 .75rem; }
fieldset { border: 0; padding: 0; margin: 0 0 .9rem; }
legend { font-size: .9rem; font-weight: 600; margin-bottom: .4rem; padding: 0; }
.chips { display: flex; flex-wrap: wrap; gap: .45rem; margin-bottom: .5rem; }
.chip { margin: 0; flex-direction: row; font-weight: 500; }
.chip input { position: absolute; opacity: 0; pointer-events: none; }
.chip span {
  display: inline-block; padding: .45rem .9rem; border-radius: 999px; border: 1.5px solid var(--line);
  background: var(--surface); cursor: pointer; font-size: .92rem;
}
.chip input:checked + span { background: var(--primary); border-color: var(--primary); color: var(--primary-ink); }
.chip input:focus-visible + span { outline: 2px solid var(--primary); outline-offset: 2px; }
.check { flex-direction: row; align-items: center; gap: .55rem; font-weight: 600; }
.check input { width: 20px; height: 20px; accent-color: var(--primary); }

/* 타임라인 */
.tl { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: .75rem; box-shadow: var(--shadow); }
.tl-tabs { display: flex; gap: .35rem; overflow-x: auto; padding-bottom: .6rem; scrollbar-width: none; }
.tl-tab {
  flex: none; display: inline-flex; align-items: center; gap: .35rem;
  padding: .45rem .8rem; border-radius: 999px; border: 1.5px solid var(--line);
  background: var(--surface); color: var(--text); font: inherit; font-size: .9rem; cursor: pointer;
}
.tl-tab.active { background: var(--primary); border-color: var(--primary); color: var(--primary-ink); font-weight: 700; }
.tl-tab em {
  font-style: normal; font-size: .72rem; min-width: 1.2rem; height: 1.2rem; border-radius: 999px;
  display: inline-grid; place-items: center; background: var(--primary-soft); color: var(--primary); font-weight: 700;
}
.tl-tab.active em { background: var(--primary-ink); color: var(--primary); }
.tl-wrap { display: grid; grid-template-columns: 3rem 1fr; padding: .5rem 0; }
.tl-axis { position: relative; }
.tl-hour { position: absolute; right: .5rem; transform: translateY(-50%); font-size: .75rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.tl-col { position: relative; background: var(--surface-2); border-radius: 8px; cursor: copy; touch-action: manipulation; }
.tl-line { position: absolute; left: 0; right: 0; border-top: 1px dashed var(--line); pointer-events: auto; }
.tl-line.hour { border-top-style: solid; }
.tl-busy, .tl-slot {
  position: absolute; left: 4px; right: 4px; border-radius: 6px; font-size: .8rem;
  display: flex; align-items: flex-start; padding: 2px 8px; overflow: hidden;
}
.tl-busy {
  background: repeating-linear-gradient(135deg, var(--busy), var(--busy) 6px, transparent 6px, transparent 11px), var(--surface-2);
  color: var(--busy-ink); font-weight: 600; cursor: not-allowed; border: 1px solid var(--busy);
}
.tl-slot { background: var(--slot-soft); border: 2px solid var(--slot); color: var(--text); cursor: pointer; font-weight: 700; }
.tl-slot.selected { background: var(--slot); color: var(--primary-ink); }
.tl-slot.error { border-color: var(--err); box-shadow: 0 0 0 3px var(--err-soft); }
.tl-slot-time { font-variant-numeric: tabular-nums; line-height: 1.2; }
.tl-handle {
  position: absolute; left: 0; right: 0; bottom: -2px; height: 18px; cursor: ns-resize; touch-action: none;
  display: grid; place-items: center;
}
.tl-handle::after { content: ""; width: 34px; height: 5px; border-radius: 3px; background: currentColor; opacity: .55; }
.tl-controls { margin-top: .6rem; padding: .75rem; border-radius: 10px; background: var(--primary-soft); }
.tl-controls-title { font-weight: 700; margin-bottom: .4rem; }
.tl-controls-row { display: flex; align-items: center; gap: .5rem; margin-bottom: .4rem; }
.tl-controls-row span { width: 2.5rem; font-size: .88rem; color: var(--muted); }
.tl-controls button {
  min-height: 40px; padding: 0 .9rem; border-radius: 10px; border: 1.5px solid var(--primary);
  background: var(--surface); color: var(--primary); font: inherit; font-weight: 700; cursor: pointer;
}
.tl-controls .tl-remove { border-color: var(--err); color: var(--err); width: 100%; margin-top: .2rem; }

.slot-summary { margin-top: .8rem; font-size: .92rem; }
.slot-summary p { margin: 0 0 .3rem; }
.slot-summary ul { margin: 0; padding-left: 1.2rem; }
.slot-summary .is-custom { color: var(--info); }

.custom { margin-top: 1rem; background: var(--surface); border: 1px dashed var(--line); border-radius: var(--radius); padding: .8rem 1rem; }
.custom summary { cursor: pointer; font-weight: 700; color: var(--primary); }
.custom[open] summary { margin-bottom: .6rem; }
.custom-current { margin: .6rem 0 0; font-size: .9rem; color: var(--info); }

/* 확인 */
.review { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: .4rem 1rem; box-shadow: var(--shadow); }
.review dl { display: grid; grid-template-columns: 6.5rem 1fr; margin: 0; }
.review dt, .review dd { padding: .6rem 0; border-bottom: 1px solid var(--line); margin: 0; }
.review dt { color: var(--muted); font-size: .9rem; }
.review dl > :nth-last-child(-n+2) { border-bottom: 0; }
.privacy { margin-top: 1.2rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem; }
.privacy table { width: 100%; border-collapse: collapse; font-size: .88rem; margin-bottom: .6rem; }
.privacy th, .privacy td { text-align: left; padding: .45rem .4rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.privacy th { width: 7rem; color: var(--muted); font-weight: 600; }

/* 완료 */
.done-icon {
  width: 64px; height: 64px; border-radius: 50%; background: var(--ok-soft); color: var(--ok);
  display: grid; place-items: center; font-size: 2rem; font-weight: 800; margin: 1rem 0;
}
.done-guide { margin-top: 1rem; }

/* 토스트 */
.toast {
  position: fixed; left: 50%; bottom: calc(20px + env(safe-area-inset-bottom)); transform: translate(-50%, 20px);
  max-width: calc(100% - 32px); padding: .7rem 1.1rem; border-radius: 12px;
  background: var(--text); color: var(--bg); font-size: .92rem; opacity: 0; pointer-events: none;
  transition: opacity .2s, transform .2s; z-index: 10;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* 진입 화면 */
.hero { padding: 1.5rem 0 1rem; }
.hero h1 { font-size: 1.6rem; margin-bottom: .4rem; }
.hero p { color: var(--muted); margin: 0; }
.menu { display: grid; gap: .75rem; margin-top: 1.25rem; }
.menu a.card { text-decoration: none; }
.menu .card.soon { opacity: .55; pointer-events: none; }

/* 관리자 */
.admin-table { width: 100%; border-collapse: collapse; background: var(--surface); border-radius: var(--radius); overflow: hidden; }
.admin-table th, .admin-table td { padding: .55rem .6rem; border-bottom: 1px solid var(--line); text-align: left; font-size: .9rem; vertical-align: middle; }
.admin-table th { color: var(--muted); font-weight: 600; width: 40%; }
.admin-table code { font-size: .78rem; color: var(--muted); }

@media (min-width: 720px) {
  .cards { grid-template-columns: repeat(3, 1fr); }
  .card { min-height: 170px; }
  .nav .btn { flex: 0 0 auto; min-width: 140px; }
}
@media (max-width: 380px) {
  .grid2 { grid-template-columns: 1fr; }
  .review dl { grid-template-columns: 5.5rem 1fr; }
}

/* 내 신청 조회 */
.my-list { display: grid; gap: .8rem; }
.my-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: .9rem 1rem; box-shadow: var(--shadow); }
.my-card.is-off { opacity: .65; }
.my-card header { display: flex; justify-content: space-between; align-items: center; gap: .5rem; margin-bottom: .4rem; }
.my-card dl { display: grid; grid-template-columns: 5.5rem 1fr; margin: 0; font-size: .92rem; }
.my-card dt, .my-card dd { margin: 0; padding: .3rem 0; }
.my-card dt { color: var(--muted); }
.my-actions { margin-top: .6rem; display: flex; justify-content: flex-end; }
.badge { font-size: .78rem; font-weight: 700; padding: .2rem .6rem; border-radius: 999px; white-space: nowrap; }
.badge.ok { background: var(--ok-soft); color: var(--ok); }
.badge.wait { background: var(--info-soft); color: var(--info); }
.badge.off { background: var(--surface-2); color: var(--muted); }
.btn.danger { border-color: var(--err); color: var(--err); }

/* 교수 화면 */
.page.wide { max-width: 1100px; }
.site-header nav a { text-decoration: none; }
.prof-row { display: block; width: 100%; text-align: left; font: inherit; color: var(--text); cursor: pointer; }
.prof-row:hover { border-color: var(--primary); }
.prof-row-sub { font-size: .88rem; color: var(--muted); }
.prof-choice { justify-content: space-between; text-decoration: none; }
.count-badge {
  min-width: 1.8rem; height: 1.8rem; padding: 0 .5rem; border-radius: 999px; background: var(--err); color: #fff;
  display: inline-grid; place-items: center; font-weight: 800; font-size: .9rem;
}
.cand-list { list-style: none; padding: 0; margin: 0; display: grid; gap: .5rem; }
.cand { display: flex; justify-content: space-between; align-items: center; gap: .6rem; background: var(--surface);
  border: 1px solid var(--line); border-radius: 10px; padding: .6rem .8rem; }
.cand.is-custom { border-style: dashed; }
.row-actions.wrap { flex-wrap: wrap; margin-top: 1rem; }
.confirm-box { margin-top: 1rem; background: var(--primary-soft); border-radius: var(--radius); padding: 1rem; }
.msgs { display: grid; gap: .5rem; margin: .6rem 0; }
.msg { max-width: 85%; background: var(--surface-2); border-radius: 12px; padding: .55rem .8rem; }
.msg.mine { margin-left: auto; background: var(--primary-soft); }
.msg-body { white-space: pre-wrap; font-size: .95rem; }
.msg-meta { font-size: .75rem; color: var(--muted); margin-top: .2rem; }
.msg-form { display: grid; gap: .5rem; }
.msg-form .btn { justify-self: end; }
.my-msgs { margin-top: .6rem; border-top: 1px solid var(--line); padding-top: .5rem; }
.my-msgs summary { cursor: pointer; font-weight: 700; color: var(--primary); font-size: .92rem; }

/* 전체 타임라인 */
.tt-legend { display: flex; flex-wrap: wrap; gap: .4rem 1rem; font-size: .82rem; margin: .4rem 0 .8rem; align-items: center; }
.tt-legend i { display: inline-block; width: 14px; height: 14px; border-radius: 4px; vertical-align: -2px; margin-right: .3rem; }
.tt-legend .check { margin: 0; font-weight: 500; }
.tt-wrap { display: grid; grid-template-columns: 3rem 1fr; overflow-x: auto; }
.tt-axis { position: relative; margin-top: 2rem; }
.tt-axis span { position: absolute; right: .4rem; transform: translateY(-50%); font-size: .72rem; color: var(--muted); }
.tt-cols { display: grid; gap: 4px; }
.tt-head { height: 2rem; display: grid; place-items: center; font-weight: 700; font-size: .88rem; }
.tt-body { position: relative; background: var(--surface-2); border-radius: 8px; }
.tt-line { position: absolute; left: 0; right: 0; border-top: 1px dashed var(--line); }
.tt-line.hour { border-top-style: solid; }
.tt-blk { position: absolute; left: 3px; right: 3px; border-radius: 6px; font-size: .74rem; padding: 1px 5px; overflow: hidden; cursor: pointer; line-height: 1.25; }
.conf-booth { background: #8e1622; color: #fff; }
.conf-one { background: #22389a; color: #fff; }
.seminar { background: #1d7a4a; color: #fff; }
.cand { }
.tt-blk.cand, .tt-legend i.cand { background: rgba(34, 56, 154, .14); border: 1px solid rgba(34, 56, 154, .35); color: var(--text); }
.tt-blk.cand.custom, .tt-legend i.cand.custom { background: transparent; border: 1.5px dashed var(--muted); }
#ttInfo { margin-top: 1rem; }
.admin-picker { background: var(--info-soft); color: var(--info); padding: .7rem .9rem; border-radius: 10px; }
.admin-picker select { margin-top: .3rem; }
.companion-row { display: grid; grid-template-columns: 1fr 1fr auto; gap: 0 .6rem; align-items: end; }
.companion-del { min-height: 46px; width: 40px; margin-bottom: .8rem; border: 1.5px solid var(--line); border-radius: 10px;
  background: var(--surface); color: var(--muted); font: inherit; cursor: pointer; }

/* 관리자 */
.site-header nav { flex-wrap: wrap; }
.site-header nav a.active { font-weight: 800; text-decoration: underline; }
.sec { margin-top: 1.8rem; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .6rem; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: .8rem 1rem; box-shadow: var(--shadow); }
.stat-v { font-size: 1.6rem; font-weight: 800; color: var(--primary); font-variant-numeric: tabular-nums; }
.stat-l { font-weight: 700; }
.stat-s { font-size: .8rem; color: var(--muted); }
.table-wrap { overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; background: var(--surface); font-size: .88rem; }
.data-table th, .data-table td { padding: .5rem .6rem; border-bottom: 1px solid var(--line); text-align: left; white-space: nowrap; }
.data-table th { color: var(--muted); font-weight: 600; background: var(--surface-2); }
.data-table td { font-variant-numeric: tabular-nums; }
ul.plain { padding-left: 1.1rem; margin: .4rem 0; }
.danger-zone { border-color: var(--err); }
.danger-btn { background: var(--err); border-color: var(--err); }
.sem-h { font-size: .95rem; margin: 1rem 0 .4rem; }
.notice.klas { font-weight: 600; }
/* 카드 안 표가 화면 폭을 넘지 않도록 (표만 가로 스크롤) */
.my-list { grid-template-columns: minmax(0, 1fr); }
.my-card { min-width: 0; }
.table-wrap { max-width: 100%; -webkit-overflow-scrolling: touch; }
/* 첫 화면 메뉴 카드는 내용 높이만 */
.menu .card { min-height: 0; }
.confirm-step { margin-top: 1.5rem; background: var(--surface); border: 1.5px solid var(--primary); border-radius: var(--radius); padding: 1rem; }
.confirm-step h2 { margin-top: 0; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.export-panel { margin-top: 1.5rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: .9rem 1rem; }
.export-panel summary { cursor: pointer; font-weight: 700; color: var(--primary); }
.export-panel form { margin-top: .8rem; }

/* ---------- 브랜드·픽토그램 (포스터 반영) ---------- */
.logo { display: inline-flex; align-items: center; gap: .45rem; }
.logo img { width: 30px; height: 30px; border-radius: 50%; background: #fff; }
.ico { display: inline-block; vertical-align: middle; flex: none; }
.with-ico { display: flex; align-items: center; gap: .3rem; }

.hero { padding: 1.4rem 0 .6rem; }
.hero-kicker { margin: 0; font-size: .85rem; color: var(--muted); font-style: italic; }
.hero-title { font-size: clamp(2rem, 9vw, 3rem); font-weight: 900; color: var(--primary); letter-spacing: -.02em;
  line-height: 1.05; margin: .3rem 0 .4rem; transform: skewX(-6deg); transform-origin: left; }
.hero-title span { color: var(--accent); margin-left: .1em; }
.hero-sub { margin: 0 0 .9rem; font-weight: 700; }
.facts { list-style: none; padding: 0; margin: 0; display: grid; gap: .35rem; font-size: .92rem; }
.facts li { display: flex; align-items: center; gap: .45rem; color: var(--text); }
.facts li .ico { color: var(--primary); }
.facts b { color: var(--muted); font-weight: 600; min-width: 4.2rem; }
.facts a { color: inherit; }

.multi-note { display: flex; gap: .7rem; align-items: flex-start; background: var(--accent-soft); color: var(--text);
  border: 1.5px solid var(--accent); border-radius: 12px; padding: .75rem .9rem; margin: 1rem 0; }
.multi-note .ico { color: var(--accent); margin-top: .1rem; }
.multi-note p { margin: 0; font-size: .93rem; }
.multi-note b { color: var(--accent); }

.sec-title { font-size: 1.05rem; margin: 1.4rem 0 .6rem; }
.type-list { display: grid; gap: .6rem; }
.type-card { display: flex; align-items: center; gap: .9rem; padding: .9rem 1rem; border-radius: var(--radius);
  background: var(--surface); border: 1.5px solid var(--line); color: var(--text); text-decoration: none; box-shadow: var(--shadow); }
.type-card:hover { border-color: var(--primary); }
.type-body { display: flex; flex-direction: column; gap: .1rem; flex: 1; min-width: 0; }
.type-body small { font-size: .82rem; }
.type-go { color: var(--muted); }
.type-ico { width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; flex: none;
  background: var(--primary-soft); color: var(--primary); }
.type-ico.booth { background: var(--brand-soft); color: var(--brand); }
.type-ico.seminar { background: var(--accent-soft); color: var(--accent); }
.type-tag { display: inline-block; align-self: flex-start; font-size: .7rem; font-weight: 800; letter-spacing: .04em;
  background: var(--primary); color: var(--primary-ink); padding: .12rem .5rem; border-radius: 6px; }

.card.type-pick { gap: .3rem; }
.card.type-pick .type-ico { margin-bottom: .3rem; }

.menu { display: grid; gap: .6rem; margin-top: 1.4rem; }
.menu-btn { display: flex; align-items: center; justify-content: center; gap: .5rem; min-height: 52px; border-radius: 12px;
  border: 1.5px solid var(--primary); color: var(--primary); background: var(--surface); text-decoration: none; font-weight: 700; }
.menu-btn.primary { background: var(--primary); color: var(--primary-ink); font-size: 1.05rem; min-height: 56px; }

.home-poster { margin-top: 1.6rem; text-align: center; }
.home-poster a { display: inline-block; color: var(--muted); text-decoration: none; }
.home-poster img { width: 100%; max-width: 367px; height: auto; border-radius: 12px; box-shadow: var(--shadow); display: block; }
.poster-cap { display: inline-flex; align-items: center; gap: .3rem; margin-top: .4rem; font-size: .85rem; }

.site-footer { text-align: center; padding: 1.6rem 16px 2.4rem; color: var(--muted); font-size: .85rem; border-top: 1px solid var(--line); margin-top: 2rem; }
.site-footer img { width: 190px; height: auto; border-radius: 6px; }
.site-footer p { margin: .4rem 0 0; }
.site-footer a { color: var(--muted); }

.done-icon .ico { color: var(--ok); }

@media (min-width: 900px) {
  .page.home { max-width: 1080px; }
  .home-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 2.5rem; align-items: start; }
  .home-poster { margin-top: 1.4rem; position: sticky; top: 1rem; }
  .menu { grid-template-columns: 1.4fr 1fr 1fr; }
}
.type-ico.sm { width: 28px; height: 28px; border-radius: 8px; margin-right: .35rem; }
.my-card header strong.with-ico { gap: 0; }
/* 첫 화면 프로그램 선택 */
.hero-sub { margin-bottom: 1.1rem; }
.sec-title small { display: block; font-weight: 500; font-size: .82rem; color: var(--muted); margin-top: .2rem; }
.type-card { width: 100%; text-align: left; font: inherit; cursor: pointer; transition: border-color .15s, box-shadow .15s; }
.type-card .type-check { color: var(--primary); opacity: 0; transition: opacity .15s; }
.type-card.selected { border-color: var(--primary); border-width: 2.5px; box-shadow: 0 0 0 4px var(--primary-soft), var(--shadow); }
.type-card.selected .type-check { opacity: 1; }
.type-card:disabled { opacity: .5; cursor: not-allowed; }
.pick-hint { min-height: 1.2em; margin: .8rem 0 0; color: var(--accent); font-weight: 700; font-size: .9rem; }
.pick-hint:empty { margin: 0; min-height: 0; }
.apply-type { display: flex; align-items: center; gap: .4rem; margin: 0 0 1rem; font-weight: 700; color: var(--primary); }
.apply-type a { margin-left: auto; font-size: .85rem; font-weight: 500; }
/* 포스터: 원본 해상도로 크게 */
.home-poster img { max-width: 440px; }
@media (min-width: 900px) {
  .home-grid { grid-template-columns: minmax(0, 1fr) 420px; }
}
/* 시간 선택 안내 팝업 */
.link-btn { background: none; border: 0; padding: 0; font: inherit; color: var(--primary); text-decoration: underline; cursor: pointer; font-weight: 700; }
dialog.guide { border: 0; border-radius: 18px; padding: 1.3rem 1.2rem 1.1rem; width: min(420px, calc(100% - 32px));
  background: var(--surface); color: var(--text); box-shadow: 0 20px 60px rgba(0,0,0,.25); }
dialog.guide::backdrop { background: rgba(10, 15, 40, .45); }
dialog.guide h2 { margin: 0 0 .8rem; font-size: 1.15rem; }
.guide-steps { list-style: none; padding: 0; margin: 0 0 1rem; display: grid; gap: .75rem; counter-reset: g; }
.guide-steps li { display: flex; gap: .7rem; align-items: flex-start; }
.guide-steps b { display: block; font-size: .95rem; }
.guide-steps small { display: block; font-size: .85rem; line-height: 1.45; }
.guide-ico { width: 40px; height: 40px; border-radius: 12px; flex: none; display: grid; place-items: center;
  background: var(--primary-soft); color: var(--primary); }
/* 입력칸이 카드 밖으로 나가지 않도록 (Safari의 날짜·시간 입력 최소폭 대응) */
input, select, textarea { min-width: 0; max-width: 100%; }
input[type="date"], input[type="time"] { -webkit-appearance: none; appearance: none; display: block; text-align: left; }
input[type="date"]::-webkit-date-and-time-value, input[type="time"]::-webkit-date-and-time-value { text-align: left; }
.grid2 > * { min-width: 0; }
label { min-width: 0; }
.confirm-step { overflow: hidden; }
.confirm-box { margin-top: .8rem; padding: .9rem .8rem; }
.confirm-box h3 { margin: 0 0 .3rem; font-size: 1rem; }
.cand > span { flex: 1; min-width: 0; }
.cand .btn { white-space: nowrap; flex: none; }
.adj-row { margin: -.2rem 0 .9rem; flex-wrap: wrap; }
.hero .hero-sub { margin-bottom: 1.5rem; }
/* 머리글: 로고·부제·사용자 표기를 한 줄, 세로 가운데 정렬 */
.site-header { align-items: center; flex-wrap: wrap; row-gap: .4rem; }
.site-header .logo { flex: none; white-space: nowrap; line-height: 1; }
.site-header .logo-sub { flex: 1 1 0; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; line-height: 1.2; }
.site-header nav { flex: 0 1 auto; }
@media (max-width: 400px) {
  .site-header .logo-sub { font-size: .78rem; }
}
