/* ハネムーンの栞 — 誌面が主役のジャーナルアプリ。
   墨紺 × 生成りの紙 × シャンパンゴールド。地図はタブの一つに格下げ。 */

:root {
  --ink: #141b2d;
  --ink-soft: #232c44;
  --ink-2: #4b5568;
  --ink-3: #98a0b3;
  --paper: #f2eee5;        /* 誌面の地 */
  --card: #fffdf8;         /* カードの紙 */
  --hairline: #e0dacb;
  --gold: #a5822f;
  --gold-deep: #85671c;
  --gold-soft: #f0e6ca;
  --gold-bright: #d6b96a;
  --warn-bg: #f7edd6;
  --warn-ink: #7c5a14;
  --danger: #a92219;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
  --tabbar-h: 58px;

  --sans: -apple-system, BlinkMacSystemFont, 'Hiragino Sans', 'Noto Sans JP', sans-serif;
  --mono: ui-monospace, 'SF Mono', 'IBM Plex Mono', 'Menlo', monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

/* display指定を持つ要素でも hidden 属性を必ず勝たせる */
[hidden] { display: none !important; }

html, body { height: 100%; }

body {
  font-family: var(--sans);
  color: var(--ink);
  background: var(--paper);
  height: 100%;
  overflow: hidden;
  overscroll-behavior: none;
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
}

/* 画面全体を占めるアプリ枠。全UIはこの中に絶対配置する
   （iOSのホーム画面アプリで下端まで確実に届かせるための骨格） */
#app-frame {
  position: fixed; inset: 0;
  background: var(--paper);
  overflow: hidden;
  -webkit-user-select: none; user-select: none;
  -webkit-touch-callout: none;
}
#app-frame img { -webkit-user-drag: none; -webkit-touch-callout: none; }

/* 紙の質感（うっすらノイズ） */
body::before {
  content: '';
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  opacity: .5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 .55 0 0 0 0 .5 0 0 0 0 .42 0 0 0 .05 0'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---- ビュー枠 ---- */
.view {
  position: absolute; inset: 0; bottom: calc(var(--tabbar-h) + var(--safe-b));
  overflow-y: auto; overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  z-index: 1;
}
.view[hidden] { display: none; }

/* ---- 上部バー（栞） ---- */
#tophead {
  position: sticky; top: 0; z-index: 50;
  background: rgb(242 238 229 / .92);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--hairline);
}
#daybar { padding-top: calc(10px + var(--safe-t)); }

/* 日付ストリップ（滞在エリアの帯＋日付チップ） */
.daybar {
  overflow-x: auto;
  scrollbar-width: none;
  padding: 2px 12px 8px;
}
.daybar::-webkit-scrollbar { display: none; }

/* 地図ページの上部にも同じストリップを敷く */
#map-daybar {
  position: absolute; left: 0; right: 0; top: 0;
  z-index: 900;
  background: rgb(242 238 229 / .92);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--hairline);
  padding-top: calc(8px + var(--safe-t));
}
.db-scroll { width: fit-content; margin: 0 auto; }

.db-bands { display: flex; gap: 5px; margin-bottom: 3px; }
.band {
  flex: 0 0 auto;
  position: relative; height: 13px;
  font-size: .55rem; font-weight: 800; letter-spacing: .02em;
  color: var(--gold-deep);
}
.band::before {
  content: '';
  position: absolute; left: 2px; right: 2px; top: 50%;
  height: 1px;
  background: #d8cfb6;
}
/* ラベルは線の上に重ねる。帯より長い街名は少しはみ出すだけで途切れない */
.band span {
  position: absolute; left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  background: var(--paper);
  padding: 0 4px;
  white-space: nowrap;
  line-height: 1;
}

.db-chips { display: flex; gap: 5px; }

.dchip {
  flex: 0 0 44px;
  display: flex; flex-direction: column; align-items: center;
  padding: 5px 0 9px;
  border: 1px solid transparent; border-radius: 11px;
  background: transparent;
  cursor: pointer; position: relative;
  transition: background .15s;
}
.dc-wd {
  font-size: .58rem; font-weight: 700;
  color: var(--ink-3);
}
.dc-wd.sat { color: #3b6bb5; }
.dc-wd.sun { color: #b5493b; }
.dc-num {
  font-family: var(--mono);
  font-size: 1.02rem; font-weight: 600; line-height: 1.25;
  color: var(--ink-2);
}
.dchip-past { opacity: .45; }
.dchip-cur {
  background: var(--ink);
  border-color: var(--ink);
  opacity: 1;
  box-shadow: 0 3px 10px rgb(20 27 45 / .25);
}
.dchip-cur .dc-num { color: #fdfcf9; }
.dchip-cur .dc-wd, .dchip-cur .dc-wd.sat, .dchip-cur .dc-wd.sun { color: var(--gold-bright); }
.dchip-today:not(.dchip-cur) { border-color: var(--gold); }
.dc-dot {
  position: absolute; left: 50%; bottom: 3px;
  width: 4px; height: 4px; margin-left: -2px;
  border-radius: 50%;
  background: var(--gold);
}
.dchip-cur .dc-dot { background: var(--gold-bright); }

/* スワイプの日送りアニメーション */
.slide-left { animation: slide-l .26s cubic-bezier(.22,.61,.36,1); }
.slide-right { animation: slide-r .26s cubic-bezier(.22,.61,.36,1); }
@keyframes slide-l { from { transform: translateX(26px); opacity: .4; } to { transform: none; opacity: 1; } }
@keyframes slide-r { from { transform: translateX(-26px); opacity: .4; } to { transform: none; opacity: 1; } }
.topbar-mid {
  flex: 1; min-width: 0;
  display: flex; align-items: center; gap: 8px;
}
#day-nav-label {
  font-size: .74rem; font-weight: 600; letter-spacing: .05em;
  color: var(--ink-2);
  font-feature-settings: 'palt';
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.chip-today {
  position: absolute; right: 10px; bottom: 12px; z-index: 60;
  border: 1px solid var(--gold); border-radius: 999px;
  background: var(--gold-soft); color: var(--gold-deep);
  font-size: .66rem; font-weight: 800; letter-spacing: .08em;
  padding: 5px 11px; cursor: pointer; white-space: nowrap;
  box-shadow: 0 2px 8px rgb(20 27 45 / .15);
}
.clock {
  font-family: var(--mono);
  font-size: .7rem; font-weight: 600; color: var(--ink-2);
  white-space: nowrap;
}
.nav-btn {
  width: 34px; height: 34px; flex: 0 0 auto;
  border: 1px solid var(--hairline); border-radius: 50%;
  background: var(--card); color: var(--ink);
  font-size: 1.15rem; line-height: 1; cursor: pointer;
  box-shadow: 0 1px 3px rgb(20 27 45 / .08);
  transition: transform .12s;
}
.nav-btn:active { transform: scale(.92); }
.nav-btn:disabled { opacity: .3; box-shadow: none; }

/* ---- 日の表紙 ---- */
.hero {
  position: relative;
  margin: 14px 14px 0;
  border-radius: 14px;
  overflow: hidden;
  background:
    linear-gradient(160deg, var(--ink) 0%, var(--ink-soft) 60%, #2e3a5c 100%);
  box-shadow: 0 10px 30px rgb(20 27 45 / .28);
}
.hero.has-img {
  background-image:
    linear-gradient(180deg, rgb(15 20 36 / .45) 0%, rgb(15 20 36 / .78) 78%),
    var(--hero);
  background-size: cover;
  background-position: center;
}
/* 金の背筋 — 栞の紐 */
.hero::after {
  content: '';
  position: absolute; top: 0; left: 22px; width: 3px; height: 44px;
  background: linear-gradient(180deg, var(--gold-bright), var(--gold) 70%, transparent);
}
.hero-inner { padding: 40px 20px 20px; }
.hero-label {
  font-family: var(--mono);
  font-size: .68rem; font-weight: 600; letter-spacing: .22em;
  color: var(--gold-bright);
}
.hero-label i { font-style: normal; opacity: .5; }
.hero h2 {
  color: #fdfcf9;
  font-size: 1.5rem; font-weight: 800; line-height: 1.35;
  letter-spacing: .01em; font-feature-settings: 'palt';
  margin-top: 8px;
  text-shadow: 0 1px 10px rgb(15 20 36 / .5);
}
.hero p {
  color: rgb(253 252 249 / .82);
  font-size: .8rem; font-weight: 500; line-height: 1.75;
  margin-top: 8px; max-width: 34em;
}

/* ---- タイムライン ---- */
.cards { padding: 18px 14px 0 10px; }

.card { position: relative; display: flex; }
.card.is-done { opacity: .55; }

/* min-width: 0 が肝。flexアイテムは既定で内容幅より縮まず、
   時刻の長い行だけ列が広がってレールがずれる。 */
.card-time {
  flex: 0 0 60px;
  min-width: 0; max-width: 60px;
  padding: 17px 7px 0 0;
  display: flex; flex-direction: column; gap: 1px; align-items: flex-end;
  text-align: right;
}
.card-time .t {
  font-family: var(--mono);
  font-size: .82rem; font-weight: 600; line-height: 1.4;
  white-space: nowrap;
}
.card-time .t-end {
  font-family: var(--mono);
  font-size: .64rem; font-weight: 500; color: var(--ink-2);
  line-height: 1.4; white-space: nowrap;
}
.zone {
  font-size: .58rem; font-weight: 700; color: var(--gold-deep);
  line-height: 1.4;
}

/* レール：線もマーカーも同じ固定値で置く（left 17px + 2px幅 = 中心18px、マーカー中心も18px） */
.rail { flex: 0 0 36px; position: relative; }
.rail::before {
  content: '';
  position: absolute; left: 17px; top: 0; bottom: 0;
  width: 2px;
  background: #ddd5c2;
}
.cards .card:first-child .rail::before { top: 24px; }
.cards .card:last-child .rail::before { bottom: auto; height: 24px; }
.rail-mark {
  position: absolute; left: 4px; top: 10px;
  width: 28px; height: 28px;
  border-radius: 50%;
  display: grid; place-items: center;
  background: var(--card);
  border: 1px solid #cdc4ac;
  color: var(--ink-2);
  box-shadow: 0 1px 3px rgb(20 27 45 / .1);
}
.rail-mark svg { display: block; }
.card.is-done .rail-mark { color: var(--ink-3); background: var(--paper); }
.card.is-next .rail-mark {
  background: var(--ink); color: var(--gold-bright);
  border-color: var(--ink);
  box-shadow: 0 0 0 4px var(--gold-soft), 0 2px 6px rgb(20 27 45 / .3);
}

.card-main {
  flex: 1; min-width: 0;
  background: var(--card);
  border: 1px solid #e7e0cf;
  border-radius: 12px;
  box-shadow: 0 1px 2px rgb(20 27 45 / .05), 0 4px 14px rgb(20 27 45 / .06);
  padding: 13px 15px;
  margin: 5px 0 10px;
}
.card.is-next .card-main {
  border-color: #cfae5e;
  box-shadow: 0 6px 20px rgb(165 130 47 / .2);
}
.card.flash .card-main { animation: card-flash 1.3s ease; }
@keyframes card-flash {
  0% { background: var(--gold-soft); }
  100% { background: var(--card); }
}

.next-flag {
  display: inline-block;
  background: var(--ink); color: var(--gold-bright);
  font-size: .62rem; font-weight: 800; letter-spacing: .16em;
  padding: 4px 10px 3px;
  border-radius: 3px;
  margin-bottom: 8px;
}

.card-main h3 {
  font-size: .95rem; font-weight: 700; line-height: 1.55;
  font-feature-settings: 'palt'; letter-spacing: .01em;
}

.detail {
  font-size: .78rem; font-weight: 500; color: var(--ink-2);
  line-height: 1.7; margin-top: 4px;
}

.photo { margin: 10px 0 2px; }
.photo img {
  width: 100%; aspect-ratio: 16 / 10; object-fit: cover;
  display: block; border-radius: 6px;
  background: var(--paper);
}
.photo figcaption {
  font-size: .56rem; color: var(--ink-3);
  margin-top: 4px; text-align: right; letter-spacing: .02em;
}

.warn {
  font-size: .76rem; font-weight: 700; line-height: 1.65; margin-top: 8px;
  background: var(--warn-bg); color: var(--warn-ink);
  padding: 7px 10px; border-left: 2px solid var(--gold);
  border-radius: 0 4px 4px 0;
}

.ref {
  margin-top: 8px; display: flex; align-items: center; gap: 7px;
  font-size: .66rem; font-weight: 800; color: var(--ink-3);
  letter-spacing: .1em;
}
code {
  font-family: var(--mono);
  font-size: .78rem; font-weight: 600; color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--hairline);
  padding: 2px 7px; border-radius: 4px;
  letter-spacing: .02em;
  user-select: all; word-break: break-all;
}

/* カードの操作は箱ボタンでなく控えめなテキストリンクにする */
.card-actions {
  display: flex; flex-wrap: wrap; gap: 6px 16px;
  margin-top: 9px;
  border-top: 1px solid #f0ebdd;
  padding-top: 8px;
}
.act {
  border: none; background: none; padding: 2px 0;
  font-family: var(--sans);
  font-size: .74rem; font-weight: 700; letter-spacing: .03em;
  color: var(--gold-deep); text-decoration: none;
  cursor: pointer;
  display: inline-flex; align-items: center; gap: 2px;
  white-space: nowrap;
}
.act::after { content: '›'; font-size: 1.05em; opacity: .65; margin-left: 1px; }
.act-ext::after { content: '↗'; font-size: .82em; }
.act:active { opacity: .6; }
.act-guide {
  background: var(--gold-soft);
  border-radius: 999px;
  padding: 4px 13px;
  color: var(--gold-deep);
}

/* 予約ページのPDFリンク用 */
.btn-ghost {
  font-family: var(--sans);
  border: 1px solid rgb(20 27 45 / .24);
  border-radius: 6px;
  background: transparent; color: var(--ink);
  font-size: .72rem; font-weight: 700; letter-spacing: .04em;
  text-decoration: none;
  padding: 6px 12px; cursor: pointer; white-space: nowrap;
}
.btn-ghost:active { border-color: var(--gold); color: var(--gold-deep); }

.day-foot {
  text-align: center;
  font-family: var(--mono);
  font-size: .62rem; letter-spacing: .18em; color: var(--ink-3);
  padding: 26px 0 30px;
}

/* ---- 予約・緊急ページ ---- */
.page { padding: calc(14px + var(--safe-t)) 14px 24px; }

/* 予約カテゴリのジャンプナビ（topheadと同じ吸着ヘッダー構造） */
.pagehead {
  position: sticky; top: 0; z-index: 50;
  background: rgb(242 238 229 / .92);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--hairline);
}
.page-body { padding: 14px 14px 24px; }
.bk-nav {
  display: flex; gap: 6px;
  overflow-x: auto; scrollbar-width: none;
  padding: calc(10px + var(--safe-t)) 14px 10px;
}
.bk-nav::-webkit-scrollbar { display: none; }
.bk-jump {
  flex: 0 0 auto;
  border: 1px solid rgb(20 27 45 / .18); border-radius: 999px;
  padding: 6px 13px;
  background: var(--card); color: var(--ink-2);
  font-family: var(--sans);
  font-size: .72rem; font-weight: 700;
  cursor: pointer; white-space: nowrap;
}
.bk-jump:active { background: var(--ink); color: var(--gold-bright); }
.group { scroll-margin-top: calc(60px + var(--safe-t)); }
.page-title {
  font-size: 1.25rem; font-weight: 800; letter-spacing: .02em;
  font-feature-settings: 'palt';
  padding: 8px 2px 14px;
}
.group { margin-bottom: 18px; }
.group h2 {
  font-size: .68rem; font-weight: 800; letter-spacing: .22em;
  color: var(--gold-deep);
  padding: 0 4px 7px;
}
.group-body {
  background: var(--card);
  border: 1px solid var(--hairline);
  border-radius: 10px;
  box-shadow: 0 2px 8px rgb(20 27 45 / .07);
  padding: 2px 14px;
}

/* 予約の詳細カード */
.bk-card {
  background: var(--card);
  border: 1px solid #e7e0cf;
  border-radius: 12px;
  box-shadow: 0 1px 2px rgb(20 27 45 / .05), 0 4px 14px rgb(20 27 45 / .06);
  padding: 13px 15px 11px;
  margin-bottom: 10px;
}
.bk-card.is-todo { border-left: 3px solid var(--gold); background: linear-gradient(90deg, var(--warn-bg), var(--card) 55%); }
.bk-card.flash { animation: card-flash 1.3s ease; }
.bk-head {
  display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
}
.bk-head h3 {
  font-size: .9rem; font-weight: 700; line-height: 1.5;
  font-feature-settings: 'palt';
}
.bk-head code { flex: 0 0 auto; }
.bk-status {
  flex: 0 0 auto; font-size: .64rem; font-weight: 800; letter-spacing: .08em;
  color: var(--gold); background: var(--warn-bg); border: 1px solid var(--gold);
  border-radius: 999px; padding: 2px 9px; white-space: nowrap;
}
.bk-sec { margin-top: 9px; }
.bk-sec-h {
  font-size: .62rem; font-weight: 800; letter-spacing: .1em;
  color: var(--ink-3); margin-bottom: 1px;
}
.bk-notes {
  margin: 3px 0 0; padding: 0; list-style: none;
}
.bk-notes li {
  position: relative; padding-left: 13px;
  font-size: .74rem; font-weight: 500; color: var(--ink-2);
  line-height: 1.7; margin-top: 3px;
}
.bk-notes li::before {
  content: ''; position: absolute; left: 2px; top: .62em;
  width: 4px; height: 4px; border-radius: 50%; background: var(--gold);
}
.bk-note {
  font-size: .74rem; font-weight: 500; color: var(--ink-2);
  line-height: 1.65; margin-top: 4px;
}
.bk-fields { margin-top: 8px; }
.bk-fields > div {
  display: flex; gap: 12px;
  padding: 6px 0;
  border-bottom: 1px solid rgb(224 218 203 / .5);
  font-size: .78rem; line-height: 1.6;
}
.bk-fields > div:last-child { border-bottom: none; }
.bk-fields dt {
  flex: 0 0 4.8em; white-space: nowrap;
  font-size: .7rem; font-weight: 800; color: var(--ink-3);
  letter-spacing: .04em; padding-top: .18em;
}
.bk-fields dd { flex: 1; min-width: 0; font-weight: 500; color: var(--ink); }
.bk-actions {
  margin-top: 8px; padding-top: 8px;
  border-top: 1px solid #f0ebdd;
  display: flex; flex-direction: column; align-items: flex-start; gap: 8px;
}
.bk-nopdf {
  font-size: .72rem; font-weight: 700; color: var(--ink-3);
  letter-spacing: .04em;
}
.bk-nopdf::before { content: '□ '; }
.row {
  display: flex; align-items: center; gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid rgb(224 218 203 / .55);
  font-size: .8rem; line-height: 1.6;
}
.row:last-child { border-bottom: none; }
.row-main { flex: 1; min-width: 0; }
.row-title { font-weight: 700; }
.row-note { font-size: .72rem; font-weight: 500; color: var(--ink-2); margin-top: 2px; line-height: 1.65; }
.row-side { flex: 0 0 auto; display: flex; flex-direction: column; align-items: flex-end; gap: 5px; }
.row.is-todo {
  background: linear-gradient(90deg, var(--warn-bg), transparent 90%);
  border-left: 2px solid var(--gold);
  padding-left: 10px; margin: 0 -14px 0 -12px; padding-right: 14px;
}
.todo-mark { font-size: .7rem; font-weight: 800; color: var(--warn-ink); }

.btn-call {
  font-family: var(--mono);
  background: var(--danger); color: #fff;
  font-size: .8rem; font-weight: 600;
  padding: 8px 13px; border-radius: 6px; text-decoration: none;
  white-space: nowrap;
  box-shadow: 0 2px 6px rgb(169 34 25 / .3);
}

/* ---- 地図タブ ---- */
#view-map { overflow: hidden; }
#map { position: absolute; inset: 0; filter: saturate(.82) contrast(1.02); }

/* ピンをタップすると出る旅程カード */
.map-card {
  position: absolute; left: 12px; right: 12px; bottom: 12px;
  z-index: 950;
  background: var(--card);
  border: 1px solid var(--hairline);
  border-radius: 14px;
  box-shadow: 0 10px 34px rgb(20 27 45 / .3);
  padding: 14px 16px 12px;
}
#map-card-close {
  position: absolute; right: 8px; top: 8px;
  width: 30px; height: 30px;
  border: none; border-radius: 50%;
  background: var(--paper); color: var(--ink-2);
  font-size: 1.05rem; line-height: 1; cursor: pointer;
}
.mc-row { display: flex; gap: 12px; align-items: flex-start; }
.mc-thumb {
  flex: 0 0 64px; width: 64px; height: 64px;
  border-radius: 8px; object-fit: cover;
  background: var(--paper);
}
.mc-icon {
  display: grid; place-items: center;
  color: var(--gold-deep);
  border: 1px solid var(--hairline);
}
.mc-main { flex: 1; min-width: 0; padding-right: 22px; }
.mc-time {
  font-family: var(--mono);
  font-size: .68rem; font-weight: 600; color: var(--gold-deep);
}
.mc-main h3 {
  font-size: .92rem; font-weight: 700; line-height: 1.5;
  font-feature-settings: 'palt';
  margin-top: 1px;
}
.mc-main p {
  font-size: .74rem; font-weight: 500; color: var(--ink-2);
  line-height: 1.6; margin-top: 3px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden;
}
.mc-actions {
  display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 10px;
  border-top: 1px solid #f0ebdd; padding-top: 8px;
}

/* 行程／おすすめ切り替え */
.map-top {
  position: absolute; left: 12px; right: 66px; top: calc(96px + var(--safe-t));
  z-index: 890;
  display: flex; flex-direction: column; gap: 8px;
  align-items: flex-start;
  pointer-events: none;
}
/* 地図上部のコントロールは「連結セグメント」で統一し、
   バラバラの浮いたピルに見えないようにする。 */
.reco-cats {   /* #map-areas と #reco-cats 共通の器 */
  display: inline-flex; align-items: center; gap: 2px;
  background: var(--card); border: 1px solid rgb(20 27 45 / .1);
  border-radius: 999px; padding: 3px;
  box-shadow: 0 3px 10px rgb(20 27 45 / .16);
  max-width: 100%; overflow-x: auto; scrollbar-width: none;
  pointer-events: auto;
}
.reco-cats::-webkit-scrollbar { display: none; }
.rcat, .marea {
  flex: 0 0 auto; border: none; background: none; border-radius: 999px;
  padding: 6px 13px; font-family: var(--sans);
  font-size: .72rem; font-weight: 700; color: var(--ink-2);
  cursor: pointer; white-space: nowrap;
  transition: background .15s, color .15s;
}
.rcat.active, .marea.active { background: var(--ink); color: var(--gold-bright); }

/* おすすめスポットのピンは金色 */
.pin-reco .pin-dot {
  background: var(--gold);
  color: #fff;
  box-shadow: 0 0 0 1px rgb(133 103 28 / .4), 0 3px 8px rgb(20 27 45 / .3);
}
.mc-reco p { -webkit-line-clamp: 4; }
.mc-badge {
  display: inline-block;
  font-size: .6rem; font-weight: 800; letter-spacing: .06em;
  padding: 2px 8px; border-radius: 3px;
  margin-left: 4px; vertical-align: 1px;
}
.mc-open { background: #e5efe2; color: #2c6b33; }
.mc-closed { background: #eee9de; color: var(--ink-3); }
.mc-hours {
  margin-top: 5px;
  font-size: .68rem; font-weight: 600; color: var(--ink-2);
  line-height: 1.6;
}

#locate {
  position: absolute; right: 14px; top: calc(96px + var(--safe-t)); z-index: 890;
  width: 46px; height: 46px; border: 1px solid rgb(20 27 45 / .1);
  border-radius: 50%;
  background: var(--card); color: var(--ink-2);
  display: grid; place-items: center; cursor: pointer;
  box-shadow: 0 3px 14px rgb(20 27 45 / .22);
  transition: color .2s, transform .12s;
}
#locate:active { transform: scale(.92); }
#locate.active { color: var(--gold-deep); }

.pin { display: flex; flex-direction: column; align-items: center; gap: 3px; }
.pin-dot {
  width: 33px; height: 33px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--ink); color: #f5e9c8;
  border: 2px solid var(--card);
  box-shadow: 0 0 0 1px rgb(20 27 45 / .25), 0 3px 8px rgb(20 27 45 / .35);
}
.pin-dot svg { display: block; }
.pin-label {
  background: var(--card); color: var(--ink);
  font-size: 10.5px; font-weight: 700; line-height: 1.3;
  padding: 2px 7px; border-radius: 3px; white-space: nowrap;
  border: 1px solid rgb(20 27 45 / .12);
  box-shadow: 0 1px 4px rgb(20 27 45 / .22);
  max-width: 112px; overflow: hidden; text-overflow: ellipsis;
}
.pin-done { opacity: .58; }
.pin-done .pin-dot { background: var(--ink-3); }
.pin-hotel .pin-dot {
  background: var(--card); color: var(--gold-deep);
  border-color: var(--card);
  box-shadow: 0 0 0 2px var(--gold-deep), 0 3px 8px rgb(20 27 45 / .32);
}
.pin-hotel .pin-label { color: var(--gold-deep); font-weight: 800; border-color: rgb(133 103 28 / .35); }

.me-dot {
  width: 18px; height: 18px; border-radius: 50%;
  background: #1d4ed8; border: 3px solid #fff;
  box-shadow: 0 0 0 1px rgb(29 78 216 / .45), 0 2px 6px rgb(0 0 0 / .3);
  animation: me-pulse 2.4s ease-out infinite;
}
@keyframes me-pulse {
  0%   { box-shadow: 0 0 0 0 rgb(29 78 216 / .35), 0 2px 6px rgb(0 0 0 / .3); }
  70%  { box-shadow: 0 0 0 14px rgb(29 78 216 / 0), 0 2px 6px rgb(0 0 0 / .3); }
  100% { box-shadow: 0 0 0 0 rgb(29 78 216 / 0), 0 2px 6px rgb(0 0 0 / .3); }
}

/* ---- みどころガイド（タブバーは隠さない） ---- */
#guide-modal {
  position: absolute; left: 0; right: 0; top: 0;
  bottom: calc(var(--tabbar-h) + var(--safe-b));
  z-index: 950;
  background: var(--paper);
  overflow-y: auto; overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  animation: gd-in .28s cubic-bezier(.22,.61,.36,1);
}
@keyframes gd-in {
  from { transform: translateY(24px); opacity: 0; }
  to { transform: none; opacity: 1; }
}
#guide-close {
  position: fixed; left: 14px; top: calc(12px + var(--safe-t));
  z-index: 990;
  border: none; border-radius: 999px;
  padding: 9px 16px;
  background: rgb(20 27 45 / .6); color: #fff;
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  font-family: var(--sans);
  font-size: .78rem; font-weight: 700; letter-spacing: .04em;
  line-height: 1; cursor: pointer;
  box-shadow: 0 2px 10px rgb(20 27 45 / .3);
}
#guide-close:active { opacity: .75; }
.gd-return {
  display: block; width: 100%;
  margin-top: 14px;
  border: none; border-radius: 12px;
  padding: 14px;
  background: var(--ink); color: var(--gold-bright);
  font-family: var(--sans);
  font-size: .84rem; font-weight: 800; letter-spacing: .06em;
  cursor: pointer;
}
.gd-return:active { opacity: .85; }

.gd-hero {
  position: relative;
  min-height: 220px;
  display: flex; align-items: flex-end;
  background: linear-gradient(160deg, var(--ink) 0%, var(--ink-soft) 60%, #2e3a5c 100%);
}
.gd-hero.has-img {
  background-image:
    linear-gradient(180deg, rgb(15 20 36 / .25) 0%, rgb(15 20 36 / .8) 82%),
    var(--hero);
  background-size: cover;
  background-position: center;
}
.gd-hero-inner { padding: 60px 20px 18px; }
.gd-label {
  font-family: var(--mono);
  font-size: .66rem; font-weight: 600; letter-spacing: .22em;
  color: var(--gold-bright);
}
.gd-label i { font-style: normal; opacity: .5; }
.gd-hero h2 {
  color: #fdfcf9;
  font-size: 1.4rem; font-weight: 800; line-height: 1.4;
  font-feature-settings: 'palt';
  margin-top: 6px;
  text-shadow: 0 1px 10px rgb(15 20 36 / .5);
}

.gd-content {
  max-width: 620px; margin: 0 auto;
  padding: 16px 18px calc(40px + var(--safe-b));
}
.gd-intro {
  font-size: .88rem; font-weight: 600; line-height: 1.9;
  color: var(--ink);
  border-left: 3px solid var(--gold);
  padding-left: 12px;
  margin: 6px 0 8px;
}
.gd-spot {
  background: var(--card);
  border: 1px solid #e7e0cf;
  border-radius: 12px;
  box-shadow: 0 1px 2px rgb(20 27 45 / .05), 0 4px 14px rgb(20 27 45 / .06);
  padding: 13px 15px;
  margin-top: 12px;
}
.gd-spot .photo { margin: 0 0 10px; }
.gd-spot h3 {
  font-size: .95rem; font-weight: 800; line-height: 1.5;
  font-feature-settings: 'palt';
}
.gd-spot h3::before { content: '◆ '; color: var(--gold); font-size: .8em; }
.gd-spot p {
  font-size: .8rem; font-weight: 500; color: var(--ink-2);
  line-height: 1.8; margin-top: 4px;
}
.gd-tips {
  margin-top: 16px;
  background: var(--warn-bg);
  border-left: 3px solid var(--gold);
  border-radius: 0 8px 8px 0;
  padding: 12px 15px;
}
.gd-tips h3 {
  font-size: .68rem; font-weight: 800; letter-spacing: .2em;
  color: var(--gold-deep);
}
.gd-tips ul { margin: 6px 0 0; padding-left: 1.2em; }
.gd-tips li {
  font-size: .78rem; font-weight: 600; color: var(--warn-ink);
  line-height: 1.8;
}
.gd-foot { margin-top: 18px; text-align: center; }

/* ---- トースト ---- */
.toast {
  position: absolute; left: 50%; top: calc(16px + var(--safe-t));
  transform: translate(-50%, -250%);
  opacity: 0; pointer-events: none;
  z-index: 1200; max-width: 90vw;
  padding: 11px 18px; border-radius: 6px;
  background: var(--ink); color: var(--paper);
  border-left: 3px solid var(--gold);
  font-size: .84rem; font-weight: 700;
  box-shadow: 0 6px 22px rgb(20 27 45 / .35);
  transition: transform .3s cubic-bezier(.22,.61,.36,1);
}
.toast.show { transform: translate(-50%, 0); opacity: 1; }
.toast.error { background: var(--danger); border-left-color: #f3c9c4; }

/* ---- 下部ナビ ---- */
#tabbar {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 1000;
  height: calc(var(--tabbar-h) + var(--safe-b));
  padding-bottom: var(--safe-b);
  display: flex;
  background: var(--ink);
  box-shadow: 0 -4px 20px rgb(20 27 45 / .3);
}
#tabbar::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, transparent, var(--gold) 25%, var(--gold-bright) 50%, var(--gold) 75%, transparent);
}
.tabbtn {
  flex: 1;
  border: none; background: none; cursor: pointer;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  color: rgb(253 252 249 / .48);
  transition: color .18s;
}
.tabbtn svg { width: 21px; height: 21px; }
.tabbtn span {
  font-size: .6rem; font-weight: 800; letter-spacing: .14em;
}
.tabbtn.active { color: var(--gold-bright); }

/* ---- PC ---- */
@media (min-width: 700px) {
  #journal, .page { max-width: 620px; margin: 0 auto; }
  .topbar { padding-left: max(14px, calc(50vw - 310px)); padding-right: max(14px, calc(50vw - 310px)); }
  #tabbar { max-width: 430px; left: 50%; transform: translateX(-50%); border-radius: 14px 14px 0 0; }
}
