/* 하루씩 넘기기형 — 큰 날짜 하나가 주인공. 날짜·제목은 Hahmlet, 본문은 Pretendard. 자두색 + 회분홍 */
@font-face {
  font-family: 'Pretendard Variable';
  src: url('/fonts/PretendardVariable.woff2') format('woff2-variations');
  font-weight: 45 920; font-style: normal; font-display: swap;
}
:root {
  --bg: #F3EFEC;
  --card: #FFFCFA;
  --ink: #2B2229;
  --ink-2: #625560;
  --muted: #9C8F98;
  --line: #E4DADD;
  --plum: #5A3753;
  --plum-2: #7A4E71;
  --rose: #EBDCE1;
  --rose-2: #F6EEF0;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 400 15.5px/1.65 'Pretendard Variable', -apple-system, BlinkMacSystemFont, 'Malgun Gothic', sans-serif;
  letter-spacing: -0.2px; word-break: keep-all; overflow-wrap: anywhere;
}
a { color: inherit; }
button, input, textarea { font: inherit; color: inherit; }
h1, h2 { margin: 0; }
[hidden] { display: none !important; }

.head { display: flex; align-items: baseline; gap: 14px; max-width: 1040px; margin: 0 auto; padding: 26px 24px 0; }
.head__brand { font-family: 'Hahmlet', serif; font-weight: 700; font-size: 21px; text-decoration: none; color: var(--plum); }
.head__sub { font-size: 13.5px; color: var(--muted); }
.head__owner { margin-left: auto; font-size: 14px; font-weight: 600; color: var(--plum); text-underline-offset: 4px; white-space: nowrap; }

.main { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 36px; align-items: start; max-width: 1040px; margin: 0 auto; padding: 28px 24px 0; }

/* 예약 내용 카드 */
.ticket { position: sticky; top: 16px; padding: 22px 22px 20px; border-radius: 14px; background: var(--card); box-shadow: 0 1px 0 var(--line), 0 18px 40px -28px rgba(90, 55, 83, .45); }
.ticket__eyebrow { margin: 0 0 14px; font-size: 12.5px; font-weight: 700; color: var(--plum-2); letter-spacing: .4px; }
.opts { margin: 0 0 16px; padding: 0; border: 0; min-width: 0; }
.opts legend { padding: 0; margin-bottom: 6px; font-size: 12.5px; color: var(--muted); }
.opt { position: relative; display: flex; justify-content: space-between; align-items: baseline; gap: 10px; padding: 9px 0 9px 24px; border-bottom: 1px solid var(--line); cursor: pointer; font-size: 14.5px; }
.opt::before { content: ''; position: absolute; left: 0; top: 13px; width: 14px; height: 14px; border-radius: 50%; border: 1.5px solid var(--muted); }
.opt.is-on::before { border-color: var(--plum); background: radial-gradient(var(--plum) 0 3.5px, transparent 4px); }
.opt.is-on span { font-weight: 700; }
.opt input { position: absolute; opacity: 0; pointer-events: none; }
.opt:has(input:focus-visible) { outline: 2px solid var(--plum); outline-offset: 2px; }
.opt:has(input:disabled) { cursor: default; opacity: .7; }
.opt b { font-weight: 500; font-size: 13.5px; color: var(--ink-2); white-space: nowrap; }
small { font-size: 11.5px; color: var(--muted); font-weight: 400; }
.ticket__dl { display: grid; grid-template-columns: 64px 1fr; gap: 6px 10px; margin: 0 0 16px; font-size: 14px; }
.ticket__dl dt { color: var(--muted); }
.ticket__dl dd { margin: 0; font-weight: 600; }
.ticket__dl dd.is-empty { font-weight: 400; color: var(--ink-2); }
.ticket__coach { display: flex; gap: 12px; align-items: center; padding: 12px; margin-bottom: 14px; border-radius: 10px; background: var(--rose-2); }
.ticket__face { display: grid; place-items: center; flex: none; width: 40px; height: 40px; border-radius: 50%; background: var(--plum); color: #fff; font-family: 'Hahmlet', serif; font-weight: 700; }
.ticket__coach p { margin: 0; font-size: 12.5px; color: var(--ink-2); line-height: 1.5; }
.ticket__coach b { display: block; font-size: 13.5px; color: var(--ink); }
.ticket__sum { display: flex; justify-content: space-between; align-items: baseline; margin: 0; padding-top: 12px; border-top: 1.5px solid var(--ink); }
.ticket__sum span { font-size: 13.5px; color: var(--ink-2); }
.ticket__sum b { font-family: 'Hahmlet', serif; font-size: 24px; font-weight: 700; color: var(--plum); }
.ticket__pay { margin: 4px 0 0; font-size: 12.5px; color: var(--muted); text-align: right; }

/* 날짜 넘기기 */
.day { min-width: 0; }
.pager { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px; padding-bottom: 22px; border-bottom: 1px solid var(--line); }
.pager__btn { display: inline-flex; align-items: center; gap: 6px; min-height: 46px; padding: 0 18px; border: 1px solid var(--line); border-radius: 99px; background: var(--card); font-weight: 600; font-size: 14.5px; cursor: pointer; white-space: nowrap; }
.pager__btn span { font-size: 22px; line-height: 1; margin-top: -3px; }
.pager__btn:hover:not(:disabled) { border-color: var(--plum); color: var(--plum); }
.pager__btn:disabled { opacity: .35; cursor: default; }
.pager__now { text-align: center; }
.pager__rel { margin: 0; font-size: 13px; font-weight: 700; color: var(--plum-2); letter-spacing: .5px; }
.pager__date { font-family: 'Hahmlet', serif; font-weight: 300; font-size: 54px; line-height: 1.12; letter-spacing: -1.5px; }
.pager__dow { margin: 0; font-family: 'Hahmlet', serif; font-size: 17px; color: var(--ink-2); }
.skip { margin: 12px 0 0; padding: 8px 12px; border-radius: 8px; background: var(--rose-2); font-size: 13px; color: var(--plum-2); text-align: center; }

.day__title { margin: 26px 0 12px; font-family: 'Hahmlet', serif; font-weight: 500; font-size: 19px; }
.day__title span { font-family: 'Pretendard Variable', sans-serif; font-size: 14px; font-weight: 400; color: var(--muted); }
.slots { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.slot { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; min-height: 66px; padding: 10px 16px; border-radius: 12px; text-align: left; }
.slot b { font-family: 'Hahmlet', serif; font-weight: 500; font-size: 22px; line-height: 1.2; }
.slot span { font-size: 12.5px; }
.slot--open { border: 1.5px solid var(--plum-2); background: var(--card); color: var(--plum); cursor: pointer; }
.slot--open span { color: var(--muted); }
.slot--open:hover { background: var(--rose-2); }
.slot--open.is-on { background: var(--plum); border-color: var(--plum); color: #fff; }
.slot--open.is-on span { color: var(--rose); }
.slot--taken { border: 1.5px solid transparent; background: var(--rose); color: #9C7D90; }
.slot--taken b { text-decoration: line-through; text-decoration-thickness: 1.5px; }
.slot--blocked { border: 1.5px dashed #CDBEC6; color: var(--muted); }
.slot--past { border: 1.5px solid transparent; color: #C4B8BF; }
.legend { display: flex; flex-wrap: wrap; gap: 4px 16px; margin: 12px 0 0; font-size: 12.5px; color: var(--muted); }
.lg { display: inline-block; width: 12px; height: 12px; margin-right: 5px; border-radius: 3px; vertical-align: -1px; }
.lg--open { border: 1.5px solid var(--plum-2); }
.lg--taken { background: var(--rose); }
.lg--blocked { border: 1.5px dashed #CDBEC6; }
.lg--past { background: #EAE3E6; }

.form { margin-top: 8px; padding-top: 4px; }
.field { display: block; margin-bottom: 13px; }
.field > span { display: block; margin-bottom: 5px; font-weight: 600; font-size: 14px; }
.field i { font-style: normal; font-weight: 400; color: var(--muted); }
.field input, .field textarea { width: 100%; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--card); font-size: 16px; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--plum); box-shadow: 0 0 0 3px var(--rose); }
.field textarea { resize: vertical; }
.error { margin: 0 0 10px; color: #A2342E; font-weight: 600; font-size: 14px; }
.error:empty { display: none; }
.cta { display: inline-flex; align-items: center; justify-content: center; min-height: 50px; padding: 0 26px; border: 0; border-radius: 99px; background: var(--plum); color: #fff; font-weight: 700; font-size: 15.5px; text-decoration: none; cursor: pointer; }
.cta:hover { background: var(--ink); }
.fine { margin: 10px 0 0; font-size: 13px; color: var(--muted); }

/* 완료 — 확정 대기 안내 */
.done { padding: 30px 32px 32px; border-radius: 14px; background: var(--card); }
.done__badge { display: inline-block; margin: 0 0 12px; padding: 3px 10px; border-radius: 99px; background: #FBEBB8; color: #6B4F0C; font-size: 12.5px; font-weight: 700; }
.done__title { font-family: 'Hahmlet', serif; font-weight: 500; font-size: 34px; letter-spacing: -1px; margin-bottom: 8px; }
.done__lead { margin: 0 0 22px; color: var(--ink-2); }
.done__flow { display: grid; grid-template-columns: repeat(3, 1fr); margin: 0 0 22px; padding: 0; list-style: none; counter-reset: f; }
.done__flow li { position: relative; padding: 18px 8px 0 0; border-top: 3px solid var(--line); font-size: 13px; color: var(--muted); }
.done__flow li::before { content: ''; position: absolute; top: -8px; left: 0; width: 13px; height: 13px; border-radius: 50%; background: var(--line); }
.done__flow b { display: block; font-size: 14px; color: var(--ink-2); }
.done__flow .is-done { border-color: var(--plum); }
.done__flow .is-done::before { background: var(--plum); }
.done__flow .is-now::before { background: #E7B93A; box-shadow: 0 0 0 4px #FBEBB8; }
.done__flow .is-now b { color: var(--ink); }
.done__dl { display: grid; grid-template-columns: 76px 1fr; gap: 8px 12px; margin: 0 0 24px; padding: 16px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); font-size: 14.5px; }
.done__dl dt { color: var(--muted); }
.done__dl dd { margin: 0; font-weight: 600; }
.done__act { display: flex; flex-wrap: wrap; gap: 10px; }
.ghost { min-height: 50px; padding: 0 22px; border: 1px solid var(--line); border-radius: 99px; background: transparent; font-weight: 600; cursor: pointer; }
.ghost:hover { border-color: var(--plum); color: var(--plum); }

.maker { max-width: 1040px; margin: 44px auto 0; padding: 0 24px; }
.maker p { margin: 0; padding-top: 16px; border-top: 1px solid var(--line); font-size: 13px; color: var(--ink-2); }
.maker b { color: var(--plum); margin-right: 3px; }
.maker a { font-weight: 600; color: var(--plum); }
.foot { max-width: 1040px; margin: 0 auto; padding: 18px 24px 44px; font-size: 12.5px; color: var(--muted); }
.foot p { margin: 0 0 2px; }

@media (max-width: 860px) {
  .main { grid-template-columns: 1fr; gap: 24px; }
  .ticket { position: static; }
}
@media (max-width: 600px) {
  .head { flex-wrap: wrap; gap: 2px 10px; padding: 18px 16px 0; }
  .head__sub { order: 3; width: 100%; }
  .main { padding: 18px 16px 0; gap: 22px; }
  .ticket { padding: 16px 16px 14px; }
  .ticket__coach { display: none; }
  .ticket__dl { grid-template-columns: 56px 1fr; font-size: 13.5px; margin-bottom: 12px; }
  .ticket__dl dt:nth-of-type(n+2), .ticket__dl dd:nth-of-type(n+2) { display: none; }
  .ticket__sum b { font-size: 21px; }
  /* 이전·다음이 화면 양끝 */
  .pager { grid-template-columns: 1fr 1fr; gap: 14px 8px; }
  .pager__now { grid-column: 1 / -1; grid-row: 1; }
  .pager__btn { justify-content: center; }
  .pager__btn:first-child { justify-self: start; }
  .pager__btn:last-child { justify-self: end; }
  .pager__date { font-size: 46px; }
  .slots { gap: 8px; }
  .slot { min-height: 60px; padding: 8px 10px; }
  .slot b { font-size: 19px; }
  .cta { width: 100%; }
  .done { padding: 24px 18px; }
  .done__title { font-size: 28px; }
  .done__act > * { width: 100%; }
  .maker, .foot { padding-left: 16px; padding-right: 16px; }
}
