/* ============================================================
   旅の1日プランナー — 見た目（スタイル）だけを集めたファイル
   もとは index.html の <style>…</style> の中にありました。
   ============================================================ */

:root {
  --bg: #FFF7F2;
  --ink: #2B2440;
  --sub: #A0938A;
  --line: #EFE7E0;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; padding: 0; }
body {
  font-family: 'M PLUS Rounded 1c', system-ui, sans-serif;
  color: var(--ink);
  background: linear-gradient(165deg, #FFE3D2, var(--bg) 38%);
  min-height: 100vh;
}
button { font-family: inherit; cursor: pointer; }
input, textarea { font-family: inherit; }
input:focus, textarea:focus { border-color: #FF9048 !important; }
a { color: #FF6B5C; }
a:hover { color: #E5533C; }
::-webkit-scrollbar { width: 0; height: 0; }

.app {
  max-width: 460px; margin: 0 auto; min-height: 100vh;
  background: var(--bg); position: relative;
  box-shadow: 0 0 44px rgba(70,45,30,.09);
}

/* Header */
.header {
  position: sticky; top: 0; z-index: 20;
  background: rgba(255,247,242,.9); backdrop-filter: blur(10px);
  padding: 18px 18px 8px; border-bottom: 1px solid rgba(120,90,70,.06);
}
.header-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.trip-title { font-size: 23px; font-weight: 800; letter-spacing: .2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.trip-range { font-size: 13px; color: var(--sub); font-weight: 700; margin-top: 3px; }
.edit-btn { flex: 0 0 auto; border: none; background: #fff; color: #8A7F77; font-weight: 800; font-size: 13px; padding: 8px 14px; border-radius: 14px; box-shadow: 0 2px 8px rgba(70,45,30,.08); }

.tabs { display: flex; gap: 8px; overflow-x: auto; margin-top: 14px; padding-bottom: 6px; }
.tab { display: flex; flex-direction: column; align-items: center; gap: 1px; flex: 0 0 auto; padding: 8px 17px; border-radius: 16px; border: none; background: #fff; color: #9A8E86; box-shadow: 0 2px 7px rgba(70,45,30,.07); }
.tab .t-label { font-size: 14px; font-weight: 800; }
.tab .t-sub { font-size: 11px; font-weight: 700; opacity: .82; }
.tab.active { background: linear-gradient(135deg, #FF6B5C, #FF9048); color: #fff; box-shadow: 0 6px 14px rgba(255,100,80,.36); }

/* Timeline */
.tl-wrap { position: relative; padding: 10px 0 130px; }
.tl { position: relative; margin: 0 4px; }
.tl-bg { position: absolute; inset: 0; }
.hour-line { position: absolute; left: 54px; right: 6px; height: 1px; background: rgba(120,95,80,.12); pointer-events: none; }
.hour-label { position: absolute; left: 6px; width: 42px; text-align: right; font-size: 12px; font-weight: 700; color: #BDB1A8; pointer-events: none; }
.gap-label { position: absolute; left: 62px; right: 10px; text-align: center; font-size: 12px; font-weight: 800; color: #C9BCB2; letter-spacing: 1px; pointer-events: none; }
.now-line { position: absolute; left: 50px; right: 6px; height: 2px; background: #FF2D6E; pointer-events: none; z-index: 6; }
.now-line span { position: absolute; left: -5px; top: -4px; width: 10px; height: 10px; border-radius: 50%; background: #FF2D6E; }

.block { position: absolute; left: 62px; right: 10px; border-radius: 16px; padding: 8px 12px; color: #fff; overflow: hidden; display: flex; flex-direction: column; gap: 2px; border: 2px solid rgba(255,255,255,.6); }
.block.plan { background: linear-gradient(135deg, #FF7A59, #FFA24C); box-shadow: 0 6px 15px rgba(255,120,80,.32); }
.block.move { background: linear-gradient(135deg, #2FBEC9, #4FD3AE); box-shadow: 0 6px 15px rgba(47,190,201,.3); }
.block-head { display: flex; justify-content: space-between; align-items: baseline; gap: 6px; }
.block-title { font-size: 15px; font-weight: 800; line-height: 1.15; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.block-chip { font-size: 10px; font-weight: 800; padding: 2px 8px; border-radius: 8px; background: rgba(255,255,255,.3); color: #fff; flex: 0 0 auto; white-space: nowrap; }
.block-time { font-size: 12px; font-weight: 700; opacity: .94; }

/* FAB */
.fab { position: fixed; bottom: 26px; right: max(18px, calc(50% - 212px)); z-index: 30; width: 62px; height: 62px; border-radius: 22px; border: none; background: linear-gradient(135deg, #FF6B5C, #FF9048); color: #fff; font-size: 32px; box-shadow: 0 12px 26px rgba(255,100,80,.46); line-height: 1; }

/* Sheet */
.backdrop { position: fixed; inset: 0; z-index: 40; background: rgba(43,36,64,.34); animation: fadeIn .18s ease; }
.sheet { position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); width: 100%; max-width: 460px; z-index: 41; background: #fff; border-radius: 28px 28px 0 0; padding: 10px 20px calc(24px + env(safe-area-inset-bottom)); box-shadow: 0 -14px 40px rgba(43,36,64,.22); animation: sheetUp .26s cubic-bezier(.2,.9,.3,1); max-height: 92vh; overflow-y: auto; }
.grabber { width: 44px; height: 5px; border-radius: 3px; background: #E7DED7; margin: 2px auto 14px; }
.sheet-title { font-size: 19px; font-weight: 800; margin-bottom: 14px; }
.field-label { font-size: 13px; font-weight: 800; color: #8A7F77; display: block; margin-bottom: 6px; }
.txt { width: 100%; border: 2px solid var(--line); background: #FBF7F4; border-radius: 14px; padding: 13px 14px; font-size: 16px; font-weight: 700; color: var(--ink); outline: none; margin-bottom: 16px; }
textarea.txt { min-height: 72px; font-size: 15px; font-weight: 600; resize: none; margin: 10px 0 0; }
.date-in { width: 100%; border: 2px solid var(--line); background: #FBF7F4; border-radius: 14px; padding: 12px; font-size: 15px; font-weight: 700; color: var(--ink); outline: none; }

.seg { display: flex; gap: 6px; background: #F2ECE7; padding: 5px; border-radius: 16px; margin-bottom: 14px; }
.seg button { flex: 1; border: none; border-radius: 12px; padding: 11px; font-size: 15px; font-weight: 800; color: #9A8E86; background: transparent; }
.seg button.on-plan { color: #fff; background: linear-gradient(135deg, #FF7A59, #FFA24C); box-shadow: 0 4px 12px rgba(0,0,0,.12); }
.seg button.on-move { color: #fff; background: linear-gradient(135deg, #2FBEC9, #4FD3AE); box-shadow: 0 4px 12px rgba(0,0,0,.12); }

.stepper { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.step-btn { width: 48px; height: 48px; border-radius: 15px; border: 2px solid var(--line); background: #fff; font-size: 24px; font-weight: 700; color: #FF6B5C; }
.step-val { flex: 1; text-align: center; font-size: 28px; font-weight: 800; letter-spacing: 1px; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.chip { border: none; border-radius: 12px; padding: 10px 15px; font-size: 14px; font-weight: 800; color: #7C7168; background: #F2ECE7; }
.chip.active { color: #fff; background: linear-gradient(135deg, #FF6B5C, #FF9048); box-shadow: 0 4px 11px rgba(255,100,80,.32); }

.detail-toggle { border: none; background: none; color: #9A8E86; font-weight: 800; font-size: 14px; padding: 0 0 4px; }
.accent { color: #FF6B5C; }
.save-btn { width: 100%; margin-top: 20px; border: none; border-radius: 17px; padding: 16px; font-size: 17px; font-weight: 800; color: #fff; background: linear-gradient(135deg, #FF6B5C, #FF9048); box-shadow: 0 8px 20px rgba(255,100,80,.38); }
.delete-btn { width: 100%; margin-top: 10px; border: none; background: none; color: #E5533C; font-weight: 800; font-size: 15px; padding: 10px; }
.row2 { display: flex; gap: 12px; margin-bottom: 4px; }
.row2 > div { flex: 1; }
.hidden { display: none !important; }

@keyframes sheetUp { from { transform: translate(-50%, 100%); } to { transform: translate(-50%, 0); } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
