/* 我的旅遊書（#/my-book，web/src/my-book.js）。一頁一頁左右滑，像翻一本小書。 */
.qb-page-wrap { max-width: 560px; margin: 0 auto; padding: 12px 16px 120px; }
.qb-message { display: grid; gap: 12px; justify-items: start; padding: 20px; }
.qb-message svg { width: 32px; height: 32px; color: var(--ql-navy, #0a3451); }

.qb-book {
  display: flex; overflow-x: auto; scroll-snap-type: x mandatory; overscroll-behavior-x: contain;
  gap: 0; border-radius: 6px 16px 16px 6px; background: #fffdf8;
  box-shadow: inset 10px 0 12px -10px rgba(10, 52, 81, .25), 0 10px 26px rgba(59, 42, 18, .14);
  border: 1px solid #e0d4c1; scrollbar-width: none;
}
.qb-book::-webkit-scrollbar { display: none; }
.qb-book:focus-visible { outline: 3px solid rgba(232, 108, 52, .45); outline-offset: 3px; }

.qb-page {
  flex: 0 0 100%; scroll-snap-align: start; box-sizing: border-box; min-height: min(72vh, 640px);
  padding: 22px 20px 18px 26px; display: flex; flex-direction: column; gap: 14px; position: relative;
  color: #3f3a32;
}
.qb-page h2 { margin: 0; font-size: 24px; line-height: 1.35; color: var(--ql-navy, #0a3451); text-wrap: balance; }

.qb-cover { justify-content: flex-end; padding: 0; overflow: hidden; border-radius: 6px 16px 16px 6px; background: var(--ql-navy, #0a3451); color: #fff; }
.qb-cover-photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .55; }
.qb-cover-mascot { position: absolute; top: 16%; left: 50%; width: 132px; padding: 22px; border-radius: 50%; background: #fffdf8; transform: translateX(-50%); }
.qb-cover-title { position: relative; padding: 24px 24px 8px; }
.qb-cover-title small { font-size: 15px; letter-spacing: .08em; opacity: .9; }
.qb-cover-title h1 { margin: 2px 0 6px; font-size: 44px; letter-spacing: .12em; color: #fff; }
.qb-cover-title p { margin: 0; font-size: 15px; opacity: .92; }
.qb-hint { position: relative; margin: 0; padding: 0 24px 22px; font-size: 13px; opacity: .85; display: flex; align-items: center; gap: 4px; }
.qb-hint svg { width: 14px; height: 14px; }

.qb-contents ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.qb-contents button { width: 100%; display: grid; grid-template-columns: 58px 1fr; grid-template-rows: auto auto; column-gap: 10px; text-align: left; padding: 10px 12px; min-height: 52px; border: 1px solid #e3d8c6; border-radius: 12px; background: #fff; color: inherit; cursor: pointer; }
.qb-contents button span { grid-row: 1 / 3; align-self: center; font-size: 13px; color: var(--ql-orange, #c2552a); }
.qb-contents button strong { color: var(--ql-navy, #0a3451); font-size: 16px; overflow-wrap: anywhere; }
.qb-contents button small { color: #7a7266; font-size: 12px; }

.qb-chapter header { display: flex; justify-content: space-between; align-items: center; font-size: 13px; color: var(--ql-orange, #c2552a); letter-spacing: .06em; }
.qb-status { padding: 3px 10px; border-radius: 999px; font-size: 12px; letter-spacing: 0; }
.qb-status.is-public { background: #0f766e; color: #fff; }
.qb-status.is-ready { background: #fdf0e3; color: #8a4b1d; }
.qb-status.is-draft { background: #eef2f5; color: #4a5d6b; }

.qb-photos { display: grid; gap: 6px; border-radius: 10px; overflow: hidden; }
.qb-photos img { width: 100%; height: 100%; object-fit: cover; display: block; }
.qb-photos-1 { grid-template-columns: 1fr; height: 220px; }
.qb-photos-2 { grid-template-columns: 1fr 1fr; height: 180px; }
.qb-photos-3 { grid-template-columns: 2fr 1fr; grid-template-rows: 1fr 1fr; height: 220px; }
.qb-photos-3 img:first-child { grid-row: 1 / 3; }
.qb-photos-4 { grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; height: 240px; }

.qb-chapter dl { margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 8px 14px; }
.qb-chapter dl div:first-child { grid-column: 1 / -1; }
.qb-chapter dt { font-size: 12px; color: #7a7266; letter-spacing: .04em; }
.qb-chapter dd { margin: 2px 0 0; font-size: 15px; line-height: 1.6; color: #2f2b25; overflow-wrap: anywhere; }
.qb-chapter blockquote { margin: 0; padding: 10px 14px; border-left: 3px solid var(--ql-orange, #c2552a); background: #fff6ee; border-radius: 0 10px 10px 0; font-size: 15px; line-height: 1.7; }
.qb-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; }
.qb-actions a { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 14px; border: 1px solid #d1c3ad; border-radius: 10px; background: #fff; color: #4e503f; text-decoration: none; font-size: 14px; }
.qb-actions a svg { width: 17px; height: 17px; }
.qb-actions a:focus-visible, .qb-controls button:focus-visible, .qb-contents button:focus-visible { outline: 3px solid rgba(232, 108, 52, .45); outline-offset: 2px; }
.qb-chapter footer { align-self: center; font-size: 12px; color: #a39a8c; font-variant-numeric: tabular-nums; }

.qb-controls { display: flex; justify-content: center; align-items: center; gap: 18px; margin-top: 14px; font-variant-numeric: tabular-nums; color: #5b554b; }
.qb-controls button { width: 48px; height: 48px; display: grid; place-items: center; border: 1px solid #d1c3ad; border-radius: 50%; background: #fffdf8; color: var(--ql-navy, #0a3451); cursor: pointer; }
.qb-controls svg { width: 20px; height: 20px; }
.qb-flip { display: inline-grid; transform: scaleX(-1); }

@media (prefers-reduced-motion: reduce) { .qb-book { scroll-behavior: auto; } }
.qb-hint-box{display:flex;gap:8px;align-items:flex-start;margin:0;padding:10px 12px;border:1px solid #e3b79a;border-radius:12px;background:#fff6ee;font-size:14px;line-height:1.6;color:#5b4a3b}
.qb-hint-box svg{flex:none;width:18px;height:18px;margin-top:3px;color:var(--ql-orange,#c2552a)}
.qb-hint-box a{color:var(--ql-orange,#c2552a);font-weight:700}
