/* 3초 여행 — 출시 앱 층 (가장 마지막에 불러온다)
 *
 * 하단 탭 · 상자 · 버튼을 출시 앱 기준으로 다시 정리한다.
 *  - 하단 탭: 화면 끝까지 이어지는 흰 표면 + 위쪽 얇은 선 하나. 다섯 탭 같은 높이, 가운데 돌출 없음.
 *            선택은 진한 글자와 굵은 선 아이콘. 색 포인트는 ‘만들기’ 아이콘의 차분한 코랄 하나.
 *  - 버튼: 대표(차콜 바탕·흰 글자, 48–52, 반경 12) / 보조(연한 중립 바탕) / 텍스트 / 아이콘(44×44).
 *  - 상자: 고르는 항목은 카드, 이어 읽는 항목은 목록, 예산은 한 영역, 설정은 묶음 행.
 *          배경·테두리·그림자를 한 상자에 겹치지 않는다(그림자는 시트·메뉴만).
 */

:root {
  --a-ink: #1C222B;            /* 대표 버튼 — 흰 글자 15.6:1 */
  --a-ink-press: #0E1217;
  --a-on-ink: #FFFFFF;
  --a-neutral: #EEF1F4;        /* 보조 버튼 바탕 — 진한 글자 14.4:1 */
  --a-neutral-press: #E1E5EA;
  --a-coral: #E0664D;          /* 만들기 아이콘 한 곳(그림 요소 3.4:1) */
  --a-tab-ink: #151C28;
  --a-tab-mute: #6A7485;       /* 흰 바탕 4.7:1 */
  --a-line: #E6E9EE;
  --a-radius-photo: 16px;
  --a-radius-ctl: 12px;
  --a-radius-sheet: 22px;
  --nav-h: 56px;
}
:root.theme-dark {
  --a-ink: #EEF2F6; --a-ink-press: #D5DBE2; --a-on-ink: #10151C;
  --a-neutral: #252B33; --a-neutral-press: #2E353F;
  --a-tab-ink: #EEF2F6; --a-tab-mute: #9AA3AE; --a-line: #2A3038;
}
@media (prefers-color-scheme: dark) {
  :root.allow-dark {
    --a-ink: #EEF2F6; --a-ink-press: #D5DBE2; --a-on-ink: #10151C;
    --a-neutral: #252B33; --a-neutral-press: #2E353F;
    --a-tab-ink: #EEF2F6; --a-tab-mute: #9AA3AE; --a-line: #2A3038;
  }
}

/* =====================================================================
 * 1. 하단 탭 — 화면에 붙는 가벼운 5탭
 * ===================================================================== */
.bottom-tab-nav {
  display: grid !important;
  grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
  align-items: stretch;
  height: calc(var(--nav-h) + var(--safe-bottom, env(safe-area-inset-bottom, 0px))) !important;
  padding-bottom: var(--safe-bottom, env(safe-area-inset-bottom, 0px)) !important;
  /* 표면은 화면 양끝까지, 탭은 본문 폭 안에 */
  max-width: none !important; width: 100% !important;
  padding-inline: max(var(--app-side-padding, 16px), calc((100% - var(--app-content-max, 100%)) / 2)) !important;
  background: var(--r-surface) !important;
  backdrop-filter: none !important; -webkit-backdrop-filter: none !important;
  border-top: 1px solid var(--a-line) !important;
  box-shadow: none !important; border-radius: 0 !important;
}
.bottom-tab-nav .tab-button {
  display: flex !important; flex-direction: column; align-items: center; justify-content: center !important;
  gap: 3px !important; height: var(--nav-h) !important; min-height: 48px !important; min-width: 0;
  padding: 0 !important; margin: 0 !important;
  background: none !important; border: 0 !important; border-radius: 0 !important;
  color: var(--a-tab-mute) !important; font-weight: 600;
  -webkit-tap-highlight-color: transparent;
}
.bottom-tab-nav .tab-button::before, .bottom-tab-nav .tab-button::after { display: none !important; }
.bottom-tab-nav .tab-ico { width: 24px; height: 24px; flex: none; stroke-width: 1.8; transform: none !important; transition: transform 120ms var(--r-ease, ease); }
.bottom-tab-nav .tab-label { font-size: 11px !important; line-height: 14px !important; font-weight: 600 !important; letter-spacing: -0.01em; white-space: nowrap; }
/* 선택 — 진한 글자 + 굵은 선(배경 캡슐·위쪽 막대 없음) */
.bottom-tab-nav .tab-button.is-active { color: var(--a-tab-ink) !important; }
.bottom-tab-nav .tab-button.is-active .tab-ico { stroke-width: 2.5; }
.bottom-tab-nav .tab-button.is-active .tab-label { font-weight: 800 !important; }
/* 만들기 — 코랄은 아이콘 선 한 곳에만 */
/* 눌림 — 아이콘만 살짝 */
.bottom-tab-nav .tab-button:active .tab-ico { transform: scale(.9) !important; }
.bottom-tab-nav .tab-button:focus-visible { outline: 2px solid var(--r-focus) !important; outline-offset: -6px !important; border-radius: 12px !important; }
@media (max-width: 359px) {
  .bottom-tab-nav { padding-inline: 4px !important; }
  .bottom-tab-nav .tab-ico { width: 22px; height: 22px; }
}
/* 하단 탭이 없는 화면 — 여행 만들기·코스 상세(아래에 화면 전용 행동 바 하나만) */
:root[data-page="create-trip"], :root[data-page="roadmap-detail"] { --nav-h: 0px; }
:root[data-page="create-trip"] .bottom-tab-nav,
:root[data-page="roadmap-detail"] .bottom-tab-nav { display: none !important; }
/* 마지막 콘텐츠가 탭 뒤에 가려지지 않게 */
.app-page > .page-scroll { padding-bottom: calc(var(--nav-h) + var(--safe-bottom, env(safe-area-inset-bottom, 0px)) + 24px) !important; }
:root[data-page="create-trip"] #createTripPage .page-scroll { padding-bottom: calc(96px + var(--safe-bottom, 0px)) !important; }
:root[data-page="roadmap-detail"] #roadmapDetailPage .page-scroll { padding-bottom: calc(92px + var(--safe-bottom, 0px)) !important; }

/* =====================================================================
 * 2. 버튼 — 대표 · 보조 · 텍스트 · 아이콘
 * ===================================================================== */
.btn, .action-btn, .hero-cta, .search-submit, .btn-edit, .checks-btn, .more-item, .sc-more {
  -webkit-tap-highlight-color: transparent;
  transition: background-color 120ms var(--r-ease, ease), color 120ms var(--r-ease, ease), transform 120ms var(--r-ease, ease), opacity 120ms ease;
}
.btn { min-height: 48px; border-radius: var(--a-radius-ctl) !important; font-size: 15px; font-weight: 700; letter-spacing: -0.01em; }

/* 대표 — 차콜 바탕 · 흰 글자 */
.btn-primary, #stepNext, #stepGenerate, .hero-cta, #btnSave, #useRoadmapBtn, #bookingConfirm, .alt-apply.btn-primary,
#homePage .hero-card .hero-cta, .topbar-cta, .topbar-nav .topbar-cta {
  background: var(--a-ink) !important; color: var(--a-on-ink) !important;
  border: 0 !important; box-shadow: none !important; background-image: none !important;
  border-radius: var(--a-radius-ctl) !important;
}
.btn-primary:hover, #stepNext:hover, #stepGenerate:hover, .hero-cta:hover, #btnSave:hover, #useRoadmapBtn:hover, .topbar-cta:hover { background: #2A323D !important; }
.btn-primary:active, #stepNext:active, #stepGenerate:active, .hero-cta:active, #btnSave:active, #useRoadmapBtn:active, #bookingConfirm:active, .topbar-cta:active {
  background: var(--a-ink-press) !important; transform: scale(.98);
}
#stepNext, #stepGenerate, #useRoadmapBtn, #bookingConfirm { min-height: 52px !important; font-size: 16px !important; }
:root.theme-dark .btn-primary:hover, :root.theme-dark #stepNext:hover, :root.theme-dark #btnSave:hover { background: #FFFFFF !important; }

/* 보조 — 연한 중립 바탕, 테두리 없음 */
.btn-soft, .btn-ghost, #stepPrev, .action-btn, .btn-edit, #shareRoadmapBtn, .alt-apply.btn-soft {
  background: var(--a-neutral) !important; color: var(--r-text) !important;
  border: 0 !important; box-shadow: none !important; border-radius: var(--a-radius-ctl) !important;
}
.btn-soft:hover, .btn-ghost:hover, #stepPrev:hover, .action-btn:hover, .btn-edit:hover { background: var(--a-neutral-press) !important; }
.btn-soft:active, .btn-ghost:active, #stepPrev:active, .action-btn:active, .btn-edit:active { background: var(--a-neutral-press) !important; transform: scale(.98); }
/* 선택(켜짐) — 보조 버튼이 눌린 상태로 남을 때 */
.btn-edit.is-active, .btn-edit[aria-pressed="true"], .action-btn[aria-pressed="true"]:not(#btnSave) {
  background: var(--a-ink) !important; color: var(--a-on-ink) !important;
}
.btn-sm { min-height: 40px !important; padding: 0 14px !important; font-size: 14px !important; }

/* 텍스트 — 초기화 · 전체 보기 · 다른 대안 보기 */
.btn-text, .section-more, .budget-alts-more {
  min-height: 44px; padding: 0 2px !important; background: none !important; border: 0 !important;
  color: var(--r-brand-on-soft, #1F4F94) !important; font-size: 14px; font-weight: 700;
}
.btn-text:active, .section-more:active { opacity: .6; }

/* 비활성 — 흐린 파랑 대신 중립 회색으로 분명하게 */
.btn:disabled, .btn[aria-disabled="true"], #bookingConfirm[aria-disabled="true"], #stepNext:disabled {
  background: var(--a-neutral) !important; color: var(--r-text-3) !important; opacity: 1 !important; transform: none !important; cursor: not-allowed;
}
/* 로딩 — 라벨은 숨기고 폭은 그대로 */
.btn[aria-busy="true"], .action-btn[aria-busy="true"] { color: transparent !important; }
.btn-primary[aria-busy="true"]::after, #btnSave[aria-busy="true"]::after, #stepGenerate[aria-busy="true"]::after { border-color: var(--a-on-ink) transparent var(--a-on-ink) transparent !important; }
.btn-soft[aria-busy="true"]::after, .action-btn:not(#btnSave)[aria-busy="true"]::after { border-color: var(--r-text) transparent var(--r-text) transparent !important; }

/* 아이콘만 있는 버튼 — 44×44 이상 */
.icon-btn, .topbar-back, .action-icon, .sc-more { min-width: 44px !important; min-height: 44px !important; }
.icon-btn:active, .topbar-back:active { background: var(--a-neutral) !important; }

/* =====================================================================
 * 3. 상자 — 카드 · 목록 · 요약 · 묶음 행
 * ===================================================================== */
.roadmap-card, .profile-card, .search-card, .my-list-card, .people-box, .trip-summary, .tool-card, .budget-panel,
.setting-list, .my-list { box-shadow: none !important; }
.form-input, .budget-input-wrap, .date-trigger, .city-search-wrap input { border-radius: var(--a-radius-ctl) !important; }
.bottom-sheet { border-radius: var(--a-radius-sheet) var(--a-radius-sheet) 0 0 !important; }

/* 코스 카드 — 사진이 있으면 사진 → 도시·국가 → 코스명 → 기간·스타일, 없으면 글 중심 카드 */
.roadmap-card { border-radius: var(--a-radius-photo) !important; border: 1px solid var(--a-line) !important; background: var(--r-surface) !important; }
.roadmap-card .rc-media:not(.has-landmark-img) { display: none !important; }
.roadmap-card .rc-media.has-landmark-img { aspect-ratio: 4 / 3; border-radius: 0; }
.roadmap-card .rc-place { font-size: 13px; font-weight: 600; color: var(--r-text-2); }
.roadmap-card .rc-title { font-size: 16px !important; line-height: 1.35; font-weight: 800; }
/* 예시 표시는 배지 대신 정보 줄의 글자로 */
.roadmap-card .rc-sample-tag { background: none !important; border: 0 !important; padding: 0 !important; min-height: 0 !important; margin-left: 0 !important; color: var(--r-text-3) !important; font-size: 13px !important; font-weight: 500 !important; }
.roadmap-card .rc-sample-tag::before { content: '·\00a0'; }
.roadmap-card:active { transform: scale(.985); }
.roadmap-grid { gap: 12px !important; grid-template-columns: 1fr !important; }
@media (min-width: 360px) { .roadmap-grid { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; } }
@media (min-width: 768px) { .roadmap-grid { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; } }
@media (min-width: 1024px) { .roadmap-grid { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; gap: 16px !important; } }
}

/* 섹션 간격·좌측 기준선 */
.section-block { margin-top: 28px !important; }
.section-head { margin-bottom: 12px !important; }
.section-title { font-size: 19px; font-weight: 800; letter-spacing: -0.02em; }
.page-title { letter-spacing: -0.025em; }
.page-sub, .section-sub { margin-top: 6px !important; }

/* =====================================================================
 * 4. 홈 — 소개는 상자 없이 짧게, 첫 코스가 빨리 보이게
 * ===================================================================== */
#homePage .hero-card {
  background: none !important; border: 0 !important; border-radius: 0 !important; padding: 12px 0 4px !important; min-height: 0 !important;
}
#homePage .hero-card .hero-illust { display: none !important; }
#homePage .hero-card .hero-greet { display: none; }
#homePage .hero-card .hero-title { font-size: 26px !important; line-height: 1.3 !important; margin: 0 !important; }
#homePage .hero-card .hero-sub { margin-top: 6px !important; font-size: 15px !important; color: var(--r-text-2) !important; }
#homePage .hero-card .hero-cta {
  margin-top: 16px !important; min-height: 50px !important; padding: 0 18px !important; width: 100%; justify-content: center; gap: 6px;
}
@media (min-width: 600px) { #homePage .hero-card .hero-cta { width: auto; } }
#homePage .search-card { margin-top: 16px !important; min-height: 50px !important; border-radius: var(--a-radius-ctl) !important; background: var(--r-surface) !important; border: 1px solid var(--a-line) !important; }
@media (min-width: 1024px) {
  #homePage .hero-card { padding: 32px 0 8px !important; }
  #homePage .hero-card .hero-title { font-size: 36px !important; }
}

/* =====================================================================
 * 5. 탐색 · 코스 상세
 * ===================================================================== */
#explorePage .search-card { border-radius: var(--a-radius-ctl) !important; border: 1px solid var(--a-line) !important; min-height: 50px !important; }
/* 상세 표지 — 사진이 없으면 큰 색 덩어리 없이 글자만 */
.roadmap-cover:not(.has-landmark-img) {
  background: none !important; border: 0 !important; padding: 8px 0 0 !important; min-height: 0 !important; height: auto !important;
  border-radius: 0 !important; margin: 0 0 8px !important;
}
.roadmap-cover:not(.has-landmark-img) .rd-title { font-size: 26px; }
.roadmap-cover.has-landmark-img { border-radius: var(--a-radius-photo) !important; }
.roadmap-meta { gap: 6px !important; }
/* 정보는 칩 여러 개 대신 한 줄 글자 */
.roadmap-meta .meta-pill { background: none !important; border: 0 !important; padding: 0 !important; min-height: 0 !important; color: var(--r-text-2) !important; font-size: 14px; font-weight: 600; }
.roadmap-meta .meta-pill + .meta-pill::before { content: '·'; margin-right: 6px; color: var(--r-text-3); }
/* 예상 비용 — 하나의 요약 영역 */
.rd-cost { background: var(--r-surface-2) !important; border: 0 !important; border-radius: 14px !important; padding: 14px 16px !important; }
/* 날짜별 코스 — 왼쪽 시간 / 오른쪽 장소, 날짜 사이 여백, 장소 사이 얇은 선 */
.rd-day { margin-top: 20px !important; }
.rd-day-h { font-size: 16px !important; font-weight: 800; margin: 0 0 4px !important; }
.rd-stops { list-style: none; margin: 0; padding: 0 !important; border: 0 !important; background: none !important; }
.rd-stop {
  display: grid !important; grid-template-columns: 52px 24px minmax(0, 1fr); align-items: baseline; column-gap: 4px;
  padding: 12px 0 !important; margin: 0 !important; background: none !important; border: 0 !important; border-radius: 0 !important;
  border-bottom: 1px solid var(--a-line) !important;
}
.rd-stop .rd-time { font-size: 14px; font-weight: 800; color: var(--r-text); font-variant-numeric: tabular-nums; }
.rd-stop .rd-ico { font-size: 15px; }
.rd-stop .rd-name { font-size: 15px; font-weight: 700; color: var(--r-text); display: flex; flex-direction: column; gap: 2px; }
.rd-stop .rd-name small { font-size: 13px; font-weight: 500; color: var(--r-text-2); }
.rd-move { text-align: left !important; padding: 6px 0 6px 80px !important; margin: 0 !important; background: none !important; border: 0 !important; border-bottom: 1px solid var(--a-line) !important; font-size: 13px; color: var(--r-text-3); }
.rd-move::before, .rd-stop::before, .rd-stops::before { display: none !important; }
/* 하단 행동 바 — 화면 아래 하나(공유는 보조, 만들기는 대표) */
#roadmapDetailPage .roadmap-cta-row {
  position: fixed !important; left: 0; right: 0; bottom: 0; z-index: 40; display: flex; gap: 8px;
  margin: 0 auto !important; max-width: var(--app-content-max, 100%);
  padding: 10px var(--app-side-padding, 16px) calc(10px + var(--safe-bottom, env(safe-area-inset-bottom, 0px))) !important;
  background: var(--r-surface) !important; border-top: 1px solid var(--a-line); box-shadow: none !important;
}
#roadmapDetailPage .roadmap-cta-row[hidden] { display: none !important; }
#roadmapDetailPage .roadmap-cta-row #shareRoadmapBtn { flex: 0 0 auto; min-width: 84px; min-height: 52px; }
#roadmapDetailPage .roadmap-cta-row #useRoadmapBtn { flex: 1 1 auto; }

/* =====================================================================
 * 6. 여행 만들기 — 질문·입력·이전/다음 하나
 * ===================================================================== */
#createTripPage .step-nav { gap: 8px !important; background: var(--r-surface) !important; border-top: 1px solid var(--a-line) !important; }
#createTripPage .step-nav #stepPrev { min-width: 88px; min-height: 52px; }
/* 코스에서 가져온 안내 — 상자 대신 얇은 안내 줄 */
#prefillBanner, #createTripPage .prefill-banner {
  background: var(--r-surface-2) !important; border: 0 !important; border-radius: var(--a-radius-ctl) !important;
  padding: 10px 12px !important; font-size: 13px !important; line-height: 1.5;
}
#createTripPage .form-label, #createTripPage .step-subh { margin-bottom: 8px; }
#createTripPage .form-error, #createTripPage .field-error { margin-top: 6px; font-size: 13px; }
/* 세부 옵션(항공·숙소·직접 선택) — 펼침 행 */
#createTripPage details.dest-advanced, #createTripPage details.budget-more {
  background: none !important; border: 0 !important; border-top: 1px solid var(--a-line) !important; border-bottom: 1px solid var(--a-line) !important;
  border-radius: 0 !important; margin-top: 16px;
}
#createTripPage details.dest-advanced > summary, #createTripPage details.budget-more > summary {
  min-height: 52px; display: flex; align-items: center; padding: 0 2px !important; font-size: 15px; font-weight: 700; color: var(--r-text);
}

/* =====================================================================
 * 7. 내 일정 — 제목·기간 → 예산 → 날짜 → 첫 장소
 * ===================================================================== */
#schedulePage .schedule-head { gap: 12px !important; }
#schedulePage .schedule-actions { display: flex !important; gap: 8px !important; align-items: stretch; }
#schedulePage .schedule-actions[hidden] { display: none !important; }
#schedulePage .schedule-actions #btnSave { flex: 1 1 auto !important; min-height: 48px !important; font-size: 15px !important; }
#schedulePage .schedule-actions .action-icon { flex: 0 0 48px !important; width: 48px; min-height: 48px !important; padding: 0 !important; justify-content: center; }
#schedulePage .schedule-actions #btnSave.is-active { background: var(--a-neutral) !important; color: var(--r-text) !important; }
#schedulePage .schedule-actions #btnSave.is-active svg { fill: var(--a-coral); stroke: var(--a-coral); }
.more-wrap { position: relative; display: flex; }
.more-menu {
  position: absolute; right: 0; top: calc(100% + 6px); z-index: 30; min-width: 196px; padding: 6px;
  background: var(--r-surface); border: 1px solid var(--a-line); border-radius: 14px; box-shadow: var(--r-shadow-float) !important;
}
.more-menu[hidden] { display: none; }
.more-item {
  display: flex; align-items: center; gap: 10px; width: 100%; min-height: 48px; padding: 0 12px;
  background: none; border: 0; border-radius: 10px; color: var(--r-text); font-size: 15px; font-weight: 600; text-align: left;
}
.more-item:hover, .more-item:focus-visible { background: var(--a-neutral); }
.more-item:focus-visible { outline: 2px solid var(--r-focus); outline-offset: -2px; }
.more-item[aria-busy="true"] { opacity: .5; pointer-events: none; }
#schedulePage .save-status { margin-top: 8px !important; font-size: 13px; }
#schedulePage .shared-banner { border-radius: var(--a-radius-ctl) !important; }
/* 여행 중 안내 — 얇은 강조선 한 줄 대신 연한 요약 영역 하나 */
#schedulePage .now-next { margin-top: 12px !important; border: 0 !important; border-left: 0 !important; background: var(--r-surface-2) !important; border-radius: 14px !important; }

/* 예산 — 하나의 요약 영역: 입력 예산 · 예상 총액 · 초과/남는 금액 행, 추천 대안 한 줄 */
#schedulePage .budget-panel {
  margin-top: 16px !important; padding: 4px 16px 12px !important;
  background: var(--r-surface) !important; border: 1px solid var(--a-line) !important; border-radius: 16px !important;
}
#schedulePage .money-rows--panel .money-row { padding: 10px 0 !important; }
#schedulePage .budget-meta { margin: 6px 0 0 !important; }

/* 날짜 탭 — 날짜와 일차만, 마지막 날짜까지 잘리지 않게 */
#schedulePage .day-row { margin-top: 20px !important; }
#schedulePage .day-chips {
  gap: 6px !important; padding: 2px var(--app-side-padding, 16px) 2px !important;
  margin: 0 calc(-1 * var(--app-side-padding, 16px)) !important;
  scroll-padding-inline: var(--app-side-padding, 16px) !important; scroll-snap-type: x proximity;
}
#schedulePage .day-chips::after { content: ''; flex: 0 0 1px; }   /* 오른쪽 끝 여백(스크롤 끝에서도 잘리지 않게) */
#schedulePage .day-chip {
  min-width: 64px !important; min-height: 52px !important; padding: 6px 10px !important; scroll-snap-align: start;
  background: var(--r-surface) !important; border: 1px solid var(--a-line) !important; border-radius: 12px !important; box-shadow: none !important; color: var(--r-text) !important;
}
#schedulePage .day-chip .day-chip-date { font-size: 15px !important; }
#schedulePage .day-chip .day-chip-label { font-size: 12px !important; color: var(--r-text-2) !important; }
#schedulePage .day-chip.is-active { background: var(--a-ink) !important; border-color: var(--a-ink) !important; color: var(--a-on-ink) !important; }
#schedulePage .day-chip.is-active .day-chip-label { color: var(--a-on-ink) !important; opacity: .8; }
#schedulePage .day-sub { margin-top: 10px !important; gap: 6px !important; }
/* 일정 점검 — 상자 대신 한 줄 행 */
#schedulePage .checks-btn {
  min-height: 44px; padding: 0 12px !important; background: var(--r-surface-2) !important; border: 0 !important; border-radius: 12px !important;
}
#schedulePage .checks-btn.is-warn { background: var(--r-danger-soft, #FEF3F2) !important; }

/* 일정·지도 전환 — 작은 전환 하나 + 편집(보조) */
#schedulePage .schedule-toolbar { margin-top: 16px !important; }

/* 장소 목록 — 시각은 왼쪽, 장소는 상자 없이 한 목록(장소 사이 얇은 선) */
.timeline .schedule-card .schedule-card-main {
  margin: 0 !important; padding: 12px 44px 12px 2px !important; position: relative;
  background: none !important; border: 0 !important; border-radius: 0 !important;
  border-bottom: 1px solid var(--a-line) !important;
}
.timeline .schedule-card.is-focused .schedule-card-main { background: var(--r-brand-soft) !important; border-radius: 10px !important; }
.timeline .schedule-card .sc-when { padding-top: 13px !important; }
.timeline .schedule-card::after { top: 16px !important; }
.timeline .tl-move { padding: 6px 0 !important; }
/* 장소 더보기(⋯) */
.timeline .sc-more {
  position: absolute; top: 4px; right: -4px; display: inline-flex; align-items: center; justify-content: center;
  background: none; border: 0; border-radius: 10px; color: var(--r-text-2); padding: 0;
}
.timeline .sc-more:hover, .timeline .sc-more[aria-expanded="true"] { background: var(--a-neutral); color: var(--r-text); }
.timeline .sc-more:focus-visible { outline: 2px solid var(--r-focus); outline-offset: -2px; }
.timeline .sc-more .dots {
  width: 18px; height: 4px;
  background: radial-gradient(circle, currentColor 1.9px, transparent 2.2px) 0 50% / 7px 4px repeat-x;
}
/* 고정·다녀옴·편집은 더보기를 열었을 때(또는 일정 편집 중)만 */
.timeline .schedule-card:not(.is-editing):not(.is-actions-open) .schedule-card-actions { display: none !important; }
.timeline .schedule-card.is-actions-open .schedule-card-actions,
.timeline .schedule-card.is-editing .schedule-card-actions {
  display: flex !important; gap: 6px !important; padding: 8px 0 4px !important;
}
.timeline .schedule-card-actions .edit-button, .timeline .schedule-card-actions .pin-btn, .timeline .schedule-card-actions .visit-btn {
  min-height: 40px !important; padding: 0 14px !important; border-radius: 10px !important;
  background: var(--a-neutral) !important; color: var(--r-text) !important; font-size: 14px !important; font-weight: 700 !important;
}
.timeline .schedule-card-actions .pin-btn.is-on, .timeline .schedule-card-actions .visit-btn.is-on { background: var(--a-ink) !important; color: var(--a-on-ink) !important; }

/* 예약 후보 줄 — 상자 하나를 가볍게 */
#schedulePage .booking-cta { background: var(--r-surface-2) !important; border: 0 !important; border-radius: 16px !important; }
#schedulePage .booking-cta #openBookingBtn { background: var(--r-surface) !important; border: 1px solid var(--r-border-strong) !important; }
#schedulePage .cost-summary, #schedulePage .tools-section { box-shadow: none !important; }

/* =====================================================================
 * 8. 시트 — 위: 제목·닫기 / 가운데: 스크롤 / 아래: 선택 개수·대표 버튼
 * ===================================================================== */
.bottom-sheet .sheet-head { padding: 6px 6px 6px 20px !important; border-bottom: 1px solid var(--a-line) !important; }
.bottom-sheet .sheet-head h2 { font-size: 18px; font-weight: 800; }
.bottom-sheet .sheet-foot { border-top: 1px solid var(--a-line) !important; }
.bottom-sheet .sheet-handle { width: 36px; height: 4px; border-radius: 2px; background: var(--r-border-strong); margin: 8px auto 2px; }
#bookingSheet { display: flex; flex-direction: column; }
#bookingSheet .sheet-filters { flex: none; padding: 10px 16px !important; gap: 6px !important; flex-wrap: nowrap !important; overflow-x: auto; scrollbar-width: none; border-bottom: 1px solid var(--a-line); }
#bookingSheet .sheet-filters::-webkit-scrollbar { display: none; }
#bookingSheet .sheet-filters .chip { flex: none; min-height: 36px; }
#bookingSheet .book-scroll { flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 12px 20px 24px !important; }
#bookingSheet .book-notice { margin: 0 0 8px !important; background: var(--r-surface-2) !important; border: 0 !important; border-radius: 12px !important; font-size: 13px; }
#bookingSheet .sheet-foot { flex-direction: column !important; align-items: stretch !important; gap: 8px !important; }
#bookingSheet .sheet-total { display: flex; justify-content: space-between; align-items: baseline; font-size: 14px; color: var(--r-text-2); }
#bookingSheet .sheet-total strong { font-size: 17px; color: var(--r-text); }
#bookingSheet .book-hint { margin: 0 !important; font-size: 13px; color: var(--r-text-2); }
#bookingSheet .book-hint.is-nudge { color: var(--r-danger); font-weight: 700; }
/* 후보 행 — 체크 · 이름 · 금액, 외부 찾기는 텍스트 버튼 */
#bookingSheet .book-row { border-radius: 0 !important; background: none !important; border: 0 !important; border-bottom: 1px solid var(--a-line) !important; }
#bookingSheet .book-mark { background: var(--a-neutral) !important; border: 0 !important; border-radius: 10px !important; }

/* =====================================================================
 * 9. 마이 — 묶음 행: [아이콘][제목] ……… [상태] ›
 * ===================================================================== */
#myPage .profile-card { background: var(--r-surface) !important; border: 1px solid var(--a-line) !important; border-radius: 16px !important; }
#myPage .profile-card .btn, #myPage .profile-card button { border-radius: var(--a-radius-ctl) !important; }
.setting-list, .my-list { border: 1px solid var(--a-line) !important; border-radius: 16px !important; background: var(--r-surface) !important; }
.setting-row { min-height: 54px !important; gap: 12px !important; border-bottom: 1px solid var(--a-line) !important; }
.setting-row:last-child { border-bottom: 0 !important; }
.setting-row .sr-ico { flex: none; width: 24px; display: inline-flex; justify-content: center; color: var(--r-text-2); }
.setting-row .sr-label { flex: 1 1 auto; min-width: 0; text-align: left; font-weight: 600; color: var(--r-text); }
.setting-row .setting-meta { flex: none; max-width: 46%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; color: var(--r-text-2); }
.setting-row .setting-arrow { flex: none; margin-left: 0 !important; width: 12px; text-align: right; color: var(--r-text-3); }
.setting-row:active { background: var(--a-neutral) !important; }
.my-group-h { font-size: 13px !important; font-weight: 700 !important; color: var(--r-text-2) !important; margin: 0 4px 8px !important; }

/* =====================================================================
 * 10. 장식 정리 — 빈 공간을 채우던 색 블록·반투명 카드
 * ===================================================================== */
.hero-aurora, .hero-route { display: none !important; }
.rc-reason-line { color: var(--r-text-2); font-size: 13px; }
/* 더보기를 열면 편집도 바로(일정 편집 모드에 들어가지 않아도) */
.timeline .schedule-card.is-actions-open .schedule-card-actions .edit-button { display: inline-flex !important; align-items: center; }
.timeline .schedule-card-actions .edit-button { order: -1; }
/* 아이콘만 있는 일정 버튼은 좁은 화면에서도 아이콘을 보인다 */
#schedulePage .schedule-actions .action-icon svg, #schedulePage .schedule-actions #btnSave svg { display: block !important; width: 20px; height: 20px; }
@media (max-width: 359px) { #schedulePage .schedule-actions #btnSave svg { display: none !important; } }
/* 장소 — 카테고리 · 비용 한 줄 */
.timeline .schedule-card-meta-line { display: flex !important; flex-wrap: wrap; align-items: center; column-gap: 8px !important; row-gap: 4px; }
.timeline .schedule-card-meta-line .schedule-cost { font-size: 15px !important; font-weight: 700 !important; color: var(--r-text) !important; margin: 0; font-variant-numeric: tabular-nums; }
.timeline .schedule-card-meta-line .schedule-price-tag { font-size: 13px; font-weight: 500; color: var(--r-text-3); }

/* =====================================================================
 * 공통 규격 v2 — 같은 역할은 어디에 놓여도 같은 크기·같은 상태
 *  칩            시각 40 · 좌우 13 · 터치 44(위아래 2px 확장) · 선택은 차콜 채움(체크·굵기 변화 없음 → 폭 고정)
 *  주요 버튼      52(하단 작업 바·시트) / 48(본문 안) · 차콜 · 흰 글자
 *  소형 보조      시각 40 · 좌우 14 · 터치 44 · 연한 중립 바탕
 *  텍스트 동작    배경 없음 · 높이 44
 *  아이콘 버튼    44~48
 *  두 줄 요소     날짜 탭 52(별도 규격)
 * 상태: 기본 · 선택(차콜) · 눌림(진하게 + 0.97~0.98배) · 로딩(라벨 숨김·폭 유지) · 비활성(회색) · 키보드 포커스(2px 링)
 * ===================================================================== */
:root { --ctl-chip: 40px; --ctl-sm: 40px; --ctl-main: 48px; --ctl-bar: 52px; --ctl-hit: 44px; }

/* --- 칩 --- */
.chip, .chip-mini {
  position: relative; min-height: var(--ctl-chip) !important; height: auto; padding: 0 13px !important;
  border-radius: 999px !important; font-size: 14px !important; font-weight: 600 !important; gap: 0 !important; line-height: 1.2;
  background: var(--r-surface) !important; border: 1px solid var(--r-border-strong) !important; color: var(--r-text) !important;
  box-shadow: none !important; white-space: nowrap;
}
.chip::before, .chip-mini::before, #styleChips .chip[aria-pressed="true"]::before, .review-tags .chip-mini.is-active::before { content: none !important; display: none !important; }
.chip::after, .chip-mini::after { content: ''; position: absolute; inset: -2px 0; }   /* 터치 44 */
.chip:hover { border-color: var(--a-ink) !important; }
.chip.is-active, .chip[aria-pressed="true"], .chip-mini.is-active, .chip-mini[aria-pressed="true"] {
  background: var(--a-ink) !important; border-color: var(--a-ink) !important; color: var(--a-on-ink) !important;
}
.chip:active, .chip-mini:active { transform: scale(.97); }
.chip:disabled, .chip[aria-disabled="true"] { opacity: .45; cursor: not-allowed; transform: none; }
.chip:focus-visible, .chip-mini:focus-visible { outline: 2px solid var(--r-focus) !important; outline-offset: 2px; }
.chip-row, .chip-wrap, .chip-row--wrap, #exploreFilters { gap: 8px !important; }
/* 홈 스타일 6개 — 탐색 필터와 같은 칩, 좁은 폭에서는 두 줄로 */
#homePage .home-styles {
  display: flex !important; flex-wrap: wrap !important; gap: 8px !important; overflow: visible !important;
  margin: 0 !important; padding: 0 !important; -webkit-mask-image: none !important; mask-image: none !important;
}
#homePage .home-styles .chip { flex: none !important; width: auto !important; }
#homePage .home-subh { margin: 20px 0 8px !important; font-size: 14px; }

/* --- 버튼 --- */
.btn { min-height: var(--ctl-main) !important; padding: 0 18px; position: relative; }
#stepNext, #stepGenerate, #useRoadmapBtn, #bookingConfirm, .alt-confirm, #editSave { min-height: var(--ctl-bar) !important; }
#stepPrev[hidden] { display: none !important; }
#createTripPage .step-nav #stepNext:only-of-type, #createTripPage .step-nav:has(#stepPrev[hidden]) #stepNext { flex: 1 1 100%; }
/* 소형 보조 — 편집 · 일정/지도 · 예약 완료 표시 · 장소 행동 · 다녀옴 */
.btn-sm, #schedulePage .btn-edit, #bookingSheet .book-mark, .timeline .schedule-card-actions .edit-button,
.timeline .schedule-card-actions .pin-btn, .timeline .schedule-card-actions .visit-btn, .visit-inline, #profileAuthBtn {
  position: relative; min-height: var(--ctl-sm) !important; height: var(--ctl-sm); padding: 0 14px !important;
  border-radius: 10px !important; font-size: 14px !important; font-weight: 700 !important;
  display: inline-flex !important; align-items: center; justify-content: center;
  background: var(--a-neutral) !important; color: var(--r-text) !important; border: 0 !important;
}
.btn-sm::after, #schedulePage .btn-edit::after, #bookingSheet .book-mark::after, .visit-inline::after, #profileAuthBtn::after,
.timeline .schedule-card-actions button::after { content: ''; position: absolute; inset: -2px 0; }
#schedulePage .btn-edit.is-active, #schedulePage .btn-edit[aria-pressed="true"], #bookingSheet .book-mark.is-on,
.timeline .schedule-card-actions .pin-btn.is-on, .visit-inline.is-on {
  background: var(--a-ink) !important; color: var(--a-on-ink) !important;
}
.btn-sm:active, #schedulePage .btn-edit:active, #bookingSheet .book-mark:active, .visit-inline:active { transform: scale(.97); background: var(--a-neutral-press) !important; }
/* 텍스트 동작 — 배경 없이 */
.btn-text, .section-more, .budget-alts-more, #bookingSheet .book-link {
  min-height: var(--ctl-hit) !important; display: inline-flex !important; align-items: center; padding: 0 2px !important;
  background: none !important; border: 0 !important; color: var(--r-brand-on-soft, #1F4F94) !important;
  font-size: 14px !important; font-weight: 700 !important; text-decoration: none !important;
}
.btn-text:focus-visible, .budget-alts-more:focus-visible, #bookingSheet .book-link:focus-visible { outline: 2px solid var(--r-focus); outline-offset: 2px; border-radius: 6px; }
/* 키보드 포커스 — 모든 버튼 같은 링 */
.btn:focus-visible, .action-btn:focus-visible, .btn-sm:focus-visible, .btn-edit:focus-visible, .book-mark:focus-visible,
.visit-inline:focus-visible, .alt-opt:focus-visible, .view-toggle button:focus-visible, .day-chip:focus-visible, .roadmap-card:focus-visible {
  outline: 2px solid var(--r-focus) !important; outline-offset: 2px !important;
}
/* 일정 / 지도 + 일정 편집 — 같은 높이 40, 같은 중심선 */
#schedulePage .schedule-toolbar { display: flex !important; align-items: center !important; justify-content: space-between; gap: 8px; }
#schedulePage .view-toggle {
  display: inline-flex !important; align-items: stretch; height: var(--ctl-sm); padding: 2px !important; gap: 2px !important;
  border: 0 !important; background: var(--a-neutral) !important; border-radius: 10px !important; box-sizing: border-box;
}
#schedulePage .view-toggle button {
  min-height: 0 !important; height: 100%; min-width: 60px !important; padding: 0 14px !important; position: relative;
  font-size: 14px !important; font-weight: 700 !important; border: 0 !important; border-radius: 8px !important;
  background: transparent !important; color: var(--r-text-2) !important;
}
#schedulePage .view-toggle button::after { content: ''; position: absolute; inset: -4px 0; }
#schedulePage .view-toggle button[aria-pressed="true"] { background: var(--r-surface) !important; color: var(--r-text) !important; }
/* 하단 탭 — 선택은 진한 글자·굵은 선, 만들기는 + 표시에만 코랄 */
.bottom-tab-nav .tab-create .tab-ico line { stroke: var(--a-coral); }
.bottom-tab-nav .tab-button.is-active .tab-ico { stroke-width: 2.4; }

/* --- 코스 카드 — 도시 → 제목 5 → 기간 7, 사진 없으면 글만 --- */
.roadmap-card .rc-bottom {
  padding: 13px 14px !important; display: flex !important; flex-direction: column; gap: 0 !important;
  min-height: 0 !important; justify-content: flex-start !important;
}
.roadmap-card .rc-place { margin: 0 !important; font-size: 13px; line-height: 1.35; }
.roadmap-card .rc-title { margin: 5px 0 0 !important; font-size: 16px !important; line-height: 1.35 !important; -webkit-line-clamp: 2; }
.roadmap-card .rc-info { margin: 7px 0 0 !important; padding: 0 !important; font-size: 13px !important; line-height: 1.35; color: var(--r-text-2); }
.roadmap-card .rc-likes { margin-top: 4px !important; background: none !important; color: var(--r-text-2) !important; padding: 0 !important; }

/* --- 코스 상세 — 제목·기간·비용을 가까이, 금액 > 포함 항목 > 근거(펼침) --- */
.roadmap-cover:not(.has-landmark-img) { margin-bottom: 4px !important; }
.roadmap-meta { margin-bottom: 0 !important; }
#roadmapBody { margin-top: 0 !important; }
.rd-cost {
  margin-top: 16px !important; padding: 14px 0 4px !important; background: none !important; border: 0 !important; border-radius: 0 !important;
  border-top: 1px solid var(--a-line) !important;
}
.rd-cost .rd-h { margin: 0 0 4px !important; font-size: 13px !important; font-weight: 700; color: var(--r-text-2) !important; }
.rd-cost-num { margin: 0 !important; font-size: 24px !important; font-weight: 800; letter-spacing: -0.02em; color: var(--r-text); }
.rd-cost-who { font-size: 15px; font-weight: 700; color: var(--r-text-2); }
.rd-cost-note { margin: 4px 0 0 !important; font-size: 14px !important; color: var(--r-text-2) !important; }
.rd-source { margin: 4px 0 0 !important; }
.rd-source > summary { min-height: var(--ctl-hit); display: inline-flex; align-items: center; gap: 4px; font-size: 13px; font-weight: 700; color: var(--r-text-2); cursor: pointer; list-style: none; }
.rd-source > summary::-webkit-details-marker { display: none; }
.rd-source > summary::after { content: '›'; transform: rotate(90deg); display: inline-block; transition: transform 150ms; }
.rd-source[open] > summary::after { transform: rotate(-90deg); }
.rd-source > p { margin: 0 0 8px; font-size: 13px; line-height: 1.55; color: var(--r-text-3); }
.rd-cost + .rd-h, .rd-note + .rd-h { border-top: 1px solid var(--a-line); padding-top: 18px; margin-top: 12px !important; }
/* 공유는 앱바 보조 동작(작은 화면) — 하단에는 대표 버튼 하나 */
.topbar-actions { display: flex; align-items: center; justify-content: flex-end; }
.topbar-share { color: var(--r-text) !important; }
@media (max-width: 1023px) {
  :root:not([data-page="roadmap-detail"]) #topbarShare { display: none !important; }
  #roadmapDetailPage .roadmap-cta-row #shareRoadmapBtn { display: none !important; }
}
@media (min-width: 1024px) { #topbarShare { display: none !important; } }

/* --- 내 일정 --- */
#schedulePage .save-status { margin-top: 6px !important; font-size: 13px; color: var(--r-text-2); }
/* 예산 — 행 3개 + 추천 대안 한 줄(적용은 시트에서) */
#budgetAlts { margin-top: 4px; }
.alt-summary { display: flex; align-items: center; gap: 8px; padding-top: 8px; border-top: 1px solid var(--a-line); }
.alt-summary-text { flex: 1 1 auto; min-width: 0; margin: 0; display: flex; flex-wrap: wrap; align-items: baseline; column-gap: 8px; }
.alt-summary-k { font-size: 13px; font-weight: 700; color: var(--r-text-2); }
.alt-summary-v { font-size: 14px; font-weight: 700; color: var(--r-text); overflow-wrap: anywhere; }
.alt-summary .budget-alts-more { flex: none; }
.budget-alts-none { font-size: 13px; color: var(--r-text-2); margin: 8px 0 0; }
/* 여행 중 — 현재·다음 요약만 */
#schedulePage .now-next .nn-actions .btn-soft { display: none; }
/* 다녀옴 — 타임라인의 해당 장소에서 */
.visit-inline { align-self: flex-start; margin-top: 6px; height: 36px; min-height: 36px !important; font-size: 13px !important; }
.visit-inline.is-on::before { content: '✓'; margin-right: 4px; }

/* --- 예산 대안 시트 — 행 선택 → 하단 ‘이 조합 적용’ --- */
#altSheet .alt-sheet-lead { margin: 0 0 12px !important; font-size: 14px; color: var(--r-text-2); }
#altSheet .alt-opts { display: flex; flex-direction: column; gap: 8px; }
.alt-opt {
  display: flex; align-items: flex-start; gap: 12px; width: 100%; padding: 14px; text-align: left;
  background: var(--r-surface); border: 1px solid var(--a-line); border-radius: 14px; color: var(--r-text);
  transition: background-color 120ms ease, border-color 120ms ease;
}
.alt-opt:active { background: var(--r-surface-2); }
.alt-opt.is-on { background: var(--r-surface-2); border-color: var(--a-ink); box-shadow: inset 0 0 0 1px var(--a-ink); }
.alt-opt-mark { position: relative; flex: none; width: 22px; height: 22px; margin-top: 3px; border-radius: 50%; border: 2px solid var(--r-border-strong); box-sizing: border-box; }
.alt-opt.is-on .alt-opt-mark { background: var(--a-ink); border-color: var(--a-ink); }
.alt-opt.is-on .alt-opt-mark::after {
  content: ''; position: absolute; inset: 3px; background: var(--a-on-ink);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='5 12.5 10 17.5 19 7'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='5 12.5 10 17.5 19 7'/%3E%3C/svg%3E") center / contain no-repeat;
}
.alt-opt-main { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.alt-opt-total { font-size: 20px; font-weight: 800; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; color: var(--r-text); }
.alt-opt-label { font-size: 15px; font-weight: 700; color: var(--r-text); overflow-wrap: anywhere; }
.alt-opt-sub { font-size: 13px; color: var(--r-text-2); }
.alt-opt-sub.is-over { color: var(--r-danger); }
#altSheet .alt-foot { flex-direction: column !important; align-items: stretch !important; gap: 8px !important; }
#altSheet .alt-foot .sheet-total { display: flex; justify-content: space-between; align-items: baseline; font-size: 14px; color: var(--r-text-2); }
#altSheet .alt-foot .sheet-total strong { font-size: 18px; color: var(--r-text); font-variant-numeric: tabular-nums; }
#altSheet .sheet-body { padding-bottom: 20px !important; }

/* --- 예약 시트 — 행 체크 → 하단 확정, 예약 사이트 열기는 텍스트 동작 --- */
#bookingSheet .book-actions { gap: 4px 16px !important; }

/* --- 마이 — 프로필은 한 줄, ‘내 여행’ 묶음이 바로 아래 / 나머지는 제목·구분선·행 --- */
#myPage .profile-card {
  display: flex !important; align-items: center; gap: 12px; padding: 4px 0 16px !important;
  background: none !important; border: 0 !important; border-radius: 0 !important; border-bottom: 1px solid var(--a-line) !important;
}
#myPage .profile-avatar { width: 44px !important; height: 44px !important; font-size: 18px !important; flex: none; }
#myPage .profile-info { flex: 1 1 auto; min-width: 0; }
#myPage .profile-name { font-size: 16px; font-weight: 800; }
#myPage .profile-email { font-size: 13px; color: var(--r-text-2); line-height: 1.45; }
#myPage .my-group { margin-top: 20px !important; }
#myPage .my-group:first-of-type .setting-list { border: 1px solid var(--a-line) !important; border-radius: 16px !important; background: var(--r-surface) !important; }
#myPage .my-group:not(:first-of-type) .setting-list {
  border: 0 !important; border-radius: 0 !important; background: none !important;
  border-top: 1px solid var(--a-line) !important; border-bottom: 1px solid var(--a-line) !important;
}
#myPage .my-group:not(:first-of-type) .setting-row { padding-left: 2px !important; padding-right: 2px !important; }
#myPage .setting-row { padding-left: 16px; padding-right: 16px; }
/* 홈 스타일 6개 — 어떤 폭에서도 3개씩 두 줄(한 개만 남지 않게) */
#homePage .home-styles { display: grid !important; grid-template-columns: repeat(3, max-content); justify-content: start; }
/* 예약 후보 행 — [예약 사이트 열기 ↗] [예약 완료로 표시] 한 줄 */
#bookingSheet .book-actions { display: flex !important; flex-direction: row !important; flex-wrap: wrap; align-items: center; }
#bookingSheet .book-actions > * { flex: none; }

/* =====================================================================
 * 3차 다듬기 — 홈·탐색·여행 만들기·로딩·마이
 * ===================================================================== */
/* 홈 스타일 — 한 줄(넘치면 옆으로 넘김) */
#homePage .home-styles {
  display: flex !important; flex-wrap: nowrap !important; overflow-x: auto !important; gap: 8px !important;
  margin: 0 calc(-1 * var(--app-side-padding, 16px)) !important; padding: 2px var(--app-side-padding, 16px) 4px !important;
  scrollbar-width: none; scroll-padding-inline: var(--app-side-padding, 16px);
}
#homePage .home-styles::-webkit-scrollbar { display: none; }
#homePage .home-styles .chip { flex: none !important; }
/* 코스 카드 — 내용만큼만 */
.roadmap-grid { align-items: start !important; gap: 10px !important; }
.roadmap-card { border-radius: 14px !important; }
.roadmap-card .rc-bottom { padding: 11px 12px 12px !important; }
.roadmap-card .rc-place { font-size: 12px !important; }
.roadmap-card .rc-title { margin-top: 3px !important; font-size: 15px !important; line-height: 1.3 !important; }
.roadmap-card .rc-info { margin-top: 5px !important; font-size: 12.5px !important; }

/* 탐색 — 스타일 칩은 검색할 때만(빈 자리 없이) */
#exploreFilters[hidden] { display: none !important; }
#exploreFilters { margin-top: 10px; }

/* 여행 만들기 — 누구와 가나요: 체크 없이 색으로만 */
#createTripPage .choice-grid .choice-card::after { content: none !important; display: none !important; }
#createTripPage .choice-grid .choice-card { justify-content: center !important; }
#createTripPage .choice-grid .choice-card.is-active { background: var(--a-ink) !important; border-color: var(--a-ink) !important; }
#createTripPage .choice-grid .choice-card.is-active .ch-label { color: var(--a-on-ink) !important; }

/* 달력 — 날짜와 출국·귀국 글자 사이 여백 */
.cal-cell { min-height: 44px !important; flex-direction: column; justify-content: flex-start !important; padding-top: 9px !important; line-height: 1 !important; }
.cal-cell.range-start::after, .cal-cell.range-end::after { position: static !important; display: block; margin-top: 5px; font-size: 10px !important; font-weight: 700; line-height: 1; }
.cal-cell:not(.range-start):not(.range-end) { justify-content: center !important; padding-top: 0 !important; }

/* 체크 목록 — 세부 스타일·이동·식사 조건 */
.check-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 12px; margin: 4px 0 0; }
@media (max-width: 359px) { .check-list { grid-template-columns: 1fr; } }
.check-opt {
  position: relative; display: flex; align-items: center; gap: 10px; min-height: 44px; width: 100%;
  padding: 0 2px; background: none; border: 0; border-bottom: 1px solid var(--a-line); border-radius: 0;
  color: var(--r-text); font-size: 15px; font-weight: 600; text-align: left; cursor: pointer;
}
.check-opt::before {
  content: ''; flex: none; width: 20px; height: 20px; border-radius: 6px; box-sizing: border-box;
  border: 1.5px solid var(--r-border-strong); background: var(--r-surface) center / 12px no-repeat;
}
.check-opt.is-active::before, .check-opt[aria-pressed="true"]::before {
  background-color: var(--a-ink); border-color: var(--a-ink);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='5 12.5 10 17.5 19 7'/%3E%3C/svg%3E");
}
.check-opt:focus-visible { outline: 2px solid var(--r-focus); outline-offset: 2px; border-radius: 6px; }
.check-opt.is-custom { color: var(--r-text); }
.check-add { display: flex; gap: 8px; align-items: center; margin: 10px 0 0; }
.check-add .form-input { flex: 1 1 auto; min-width: 0; min-height: 44px !important; height: 44px; font-size: 15px; }
.check-add .btn-sm { flex: none; }

/* 예산 입력 — 상자 없이 가운데 큰 숫자 */
#createTripPage .budget-field { text-align: center; }
#createTripPage .budget-field .form-label { justify-content: center; display: flex; gap: 6px; }
#createTripPage .budget-field .form-hint, #createTripPage .budget-field .form-error, #createTripPage .budget-level-badge { text-align: center; }
#createTripPage .budget-input-wrap {
  display: flex !important; justify-content: center; align-items: baseline; gap: 6px;
  width: min(240px, 100%); margin: 14px auto 6px !important; min-height: 0 !important; padding: 0 0 6px !important;
  background: none !important; border: 0 !important; border-bottom: 2px solid var(--r-border-strong) !important; border-radius: 0 !important; outline: 0 !important;
}
#createTripPage .budget-input-wrap:focus-within { border-bottom-color: var(--a-ink) !important; outline: 0 !important; }
#createTripPage .budget-input-wrap .budget-input {
  flex: 0 1 auto; width: 6ch; min-width: 3ch; text-align: right; font-size: 36px !important; font-weight: 800; letter-spacing: -0.02em;
}
#createTripPage .budget-input-wrap .bd-unit-fixed { font-size: 18px !important; font-weight: 700; color: var(--r-text-2); }

/* 추천 예산 — 같은 안쪽 여백, 금액·버튼 오른쪽 끝 맞춤 */
#createTripPage .budget-suggest {
  margin-top: 24px; padding: 16px !important; background: var(--r-surface) !important;
  border: 1px solid var(--a-line) !important; border-radius: 16px !important; box-shadow: none !important;
}
#createTripPage .budget-suggest-head { margin: 0 0 4px !important; }
#createTripPage .budget-suggest .money-rows { margin: 0; padding: 0; display: block; }
#createTripPage .budget-suggest .money-row {
  display: flex; justify-content: space-between; align-items: baseline; gap: 12px;
  padding: 10px 0 !important; margin: 0 !important; border-bottom: 1px solid var(--a-line);
}
#createTripPage .budget-suggest .money-row dt { font-size: 14px; color: var(--r-text-2); font-weight: 600; margin: 0; padding: 0; }
#createTripPage .budget-suggest .money-row dt small { display: block; margin-top: 2px; font-size: 12px; color: var(--r-text-3); font-weight: 500; }
#createTripPage .budget-suggest .money-row dd { margin: 0; padding: 0; font-size: 15px; font-weight: 700; color: var(--r-text); text-align: right; }
#createTripPage .budget-suggest .money-row--total { border-bottom: 0; padding-top: 12px !important; }
#createTripPage .budget-suggest .money-row--total dt { color: var(--r-text); font-weight: 800; font-size: 15px; }
#createTripPage .budget-suggest .money-row--total dd { font-size: 18px; font-weight: 800; }
#createTripPage .budget-suggest #budgetSuggestText { margin: 6px 0 12px; font-size: 13px; color: var(--r-text-2); }
#createTripPage .budget-suggest .budget-apply { width: 100%; margin: 0; }
/* 예산 수준 — 같은 크기 3칸 */
#createTripPage .budget-marks { display: grid !important; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px !important; margin-top: 12px; }
#createTripPage .budget-marks button {
  display: flex !important; flex-direction: column; align-items: flex-start; gap: 2px; min-height: 0;
  padding: 12px !important; background: var(--r-surface) !important; border: 1px solid var(--a-line) !important; border-radius: 12px !important;
  text-align: left; color: var(--r-text);
}
#createTripPage .budget-marks button.is-active, #createTripPage .budget-marks button[aria-pressed="true"] { background: var(--a-ink) !important; border-color: var(--a-ink) !important; color: var(--a-on-ink) !important; }
#createTripPage .budget-marks .bm-label { font-size: 14px !important; font-weight: 800 !important; }
#createTripPage .budget-marks .bm-val { font-size: 13px !important; font-weight: 700 !important; opacity: 1 !important; }
#createTripPage .budget-marks .bm-desc { font-size: 12px; line-height: 1.4; opacity: .75; }

/* 일정 만드는 중 — 앱 아이콘 경로 모션 */
#genLoadingOverlay .gl-plane-route { width: 132px; height: 132px; margin-bottom: 14px; }
#genLoadingOverlay .gl-plane-route path { animation: none !important; }
#genLoadingOverlay .gl-plane-route mask path { stroke: #fff !important; stroke-width: 12 !important; stroke-dasharray: 1 1 !important; }
#genLoadingOverlay .gl-plane-route .gl-dots { stroke: var(--a-ink) !important; stroke-width: 3.4 !important; stroke-linecap: round; stroke-dasharray: 0.1 6.2 !important; fill: none; }
#genLoadingOverlay .gl-plane-route .gl-start { fill: none; stroke: var(--a-ink); stroke-width: 3.2; }
#genLoadingOverlay .gl-plane-route .gl-stop { fill: var(--a-ink); }
#genLoadingOverlay .gl-plane-route .gl-glow { fill: var(--r-brand); }
#genLoadingOverlay .gl-plane-route .gl-plane path { fill: var(--a-ink) !important; stroke: none !important; }
@media (prefers-reduced-motion: reduce) {
  #genLoadingOverlay .gl-plane-route mask path { stroke-dashoffset: 0 !important; }
}

/* 앱바 텍스트 동작 — 내 블로그의 ‘새 글’ */
.topbar-text-btn {
  display: none; min-height: 44px; padding: 0 8px; background: none; border: 0;
  color: var(--r-brand-on-soft, #1F4F94); font-size: 15px; font-weight: 800; white-space: nowrap;
}
:root[data-page="my-blogs"] .topbar-text-btn { display: inline-flex; align-items: center; }
.topbar-text-btn:focus-visible { outline: 2px solid var(--r-focus); outline-offset: 2px; border-radius: 8px; }
#myBlogsPage .page-header { margin-bottom: 8px; }

/* 설정 — 분류 목록 → 분류별 화면 */
#settingsSheet .sheet-head { display: grid !important; grid-template-columns: 44px 1fr 44px; align-items: center; padding: 6px !important; }
#settingsSheet .sheet-head h3 { grid-column: 2; text-align: center; margin: 0; font-size: 17px; font-weight: 800; }
#settingsSheet .sheet-head #settingsClose { grid-column: 3; }
#settingsSheet .set-back { grid-column: 1; grid-row: 1; font-size: 30px; line-height: 1; font-weight: 300; }
#settingsSheet .set-view[hidden] { display: none !important; }
#settingsSheet .set-group-h { margin: 18px 4px 8px; font-size: 13px; font-weight: 700; color: var(--r-text-2); }
#settingsSheet .set-view > .set-group-h:first-child { margin-top: 4px; }
#settingsSheet .set-note { margin: 0 4px 12px; font-size: 14px; color: var(--r-text-2); }
#settingsSheet #accountSettings:not([hidden]) ~ .set-note, #settingsSheet .set-view[data-set-view="account"]:has(#accountSettings:not([hidden])) #accountGuestNote { display: none; }
#settingsSheet .set-view[data-set-view="account"]:has(#accountSettings[hidden]) .setting-list { display: none; }
#settingsSheet .setting-row--block { flex-direction: column; align-items: stretch !important; gap: 10px; padding: 14px 16px !important; }
#settingsSheet .set-view:not([data-set-view="root"]) { animation: set-in 180ms var(--r-ease, ease); }
@keyframes set-in { from { opacity: 0; transform: translateX(16px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { #settingsSheet .set-view { animation: none !important; } }
#createTripPage #budgetTripSummaryH { margin-top: 24px !important; }
#genLoadingOverlay .gl-plane-route .gl-start { fill: var(--r-bg, #F7F8FA) !important; }
#genLoadingOverlay .gl-plane-route .gl-guide { stroke: none !important; fill: none; }
#genLoadingOverlay .gl-plane-route .gl-dot { fill: var(--a-ink); }

/* 설정 — 아래에서 올라오는 시트가 아닌 새 창(화면 전체), 분류를 누르면 옆으로 넘어가는 화면 */
#settingsSheet {
  top: 0 !important; bottom: 0 !important; left: 0 !important; right: 0 !important; margin: 0 auto;
  height: 100% !important; max-height: none !important; border-radius: 0 !important; box-shadow: none !important;
  background: var(--r-bg) !important; padding-top: env(safe-area-inset-top, 0px);
  transform: translateX(100%) !important; transition: transform 240ms var(--r-ease, ease) !important;
}
#settingsSheet.is-visible { transform: none !important; }
#settingsSheet .sheet-handle { display: none !important; }
#settingsSheet .sheet-head { background: var(--r-surface); }
#settingsSheet .sheet-body { padding: 8px 16px calc(24px + env(safe-area-inset-bottom, 0px)) !important; }
#settingsBackdrop { background: transparent !important; }
@media (prefers-reduced-motion: reduce) { #settingsSheet { transition: none !important; } }
/* 예산 금액 — 밑줄은 숫자 칸에만, 단위(만원)는 밑줄 밖, 숫자는 화면 가운데 */
#createTripPage .budget-input-wrap {
  display: grid !important; grid-template-columns: 1fr auto 1fr; align-items: end; column-gap: 10px;
  width: 100% !important; margin: 16px 0 8px !important; padding: 0 !important; border: 0 !important;
}
#createTripPage .budget-input-wrap .budget-input {
  grid-column: 2; width: 5.5ch !important; min-width: 0; text-align: center !important;
  padding: 0 0 6px !important; border-bottom: 2px solid var(--r-border-strong) !important;
}
#createTripPage .budget-input-wrap:focus-within .budget-input { border-bottom-color: var(--a-ink) !important; }
#createTripPage .budget-input-wrap .bd-unit-fixed { grid-column: 3; justify-self: start; padding-bottom: 10px; }

/* =====================================================================
 * 4차 — 반응형 정리(데스크톱 상단 메뉴 / 모바일 하단 탭), 홈 폭, 여행 중 요약, 도시 바로가기
 * 메뉴 전환 기준: 1024px(상단 메뉴 5개 + 여행 만들기가 로고와 한 줄에 들어가는 최소 폭)
 * ===================================================================== */
@media (min-width: 1024px) {
  :root { --nav-h: 0px; }
  .bottom-tab-nav { display: none !important; }            /* 화면·키보드·접근성 트리에서 모두 빠진다 */
  .app-page > .page-scroll { padding-bottom: calc(32px + var(--safe-bottom, 0px)) !important; }
  :root[data-page="roadmap-detail"] #roadmapDetailPage .page-scroll { padding-bottom: calc(96px + var(--safe-bottom, 0px)) !important; }
  .topbar-spacer.topbar-actions { display: flex !important; }
  /* 상단 메뉴 — 현재 화면 표시(글자 진하게 + 옅은 바탕), 여행 만들기는 대표 버튼 */
  .topbar-nav a[aria-current="page"] { background: var(--a-neutral) !important; color: var(--r-text) !important; font-weight: 800; }
  .topbar-nav a { min-height: 40px; display: inline-flex; align-items: center; padding: 0 12px; font-weight: 600; color: var(--r-text-2); }
  /* 데스크톱에서는 일정·지도를 두 칸으로 함께 보여 주므로 전환 버튼을 숨긴다 */
  #schedulePage .view-toggle { display: none !important; }
}

/* 홈 — 제목·버튼·검색·카드 같은 왼쪽 기준선, 데스크톱 제목은 한 줄 */
#homePage .hero-text { max-width: none !important; }
@media (min-width: 768px) {
  #homePage .hero-title br { display: none; }
  #homePage .hero-title { white-space: normal; text-wrap: balance; }
  #homePage .search-card { max-width: 560px; }
  #homePage .hero-card .hero-cta { width: auto !important; }
}
#homePage .hero-card .hero-sub { margin-top: 8px !important; }
#homePage .hero-card .hero-cta { margin-top: 20px !important; }

/* 홈 스타일 — 한 줄(넘치면 칩 영역 안에서 옆으로), 오른쪽 흐림으로 더 있음을 알림 + ‘전체 스타일’ */
.home-subh-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 20px 0 6px; }
.home-subh-row .home-subh { margin: 0 !important; }
.home-subh-row .section-more { font-size: 13px !important; }
#homePage .home-styles {
  padding-right: 40px !important;
  -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 40px), transparent) !important;
          mask-image: linear-gradient(90deg, #000 calc(100% - 40px), transparent) !important;
}
@media (min-width: 600px) {
  #homePage .home-styles { -webkit-mask-image: none !important; mask-image: none !important; padding-right: var(--app-side-padding, 16px) !important; }
}
@media (min-width: 600px) { .home-subh-row .section-more { display: none; } }

/* 도시 바로가기 — 도시마다 한 번, 움직이지 않는 칩(줄바꿈) */
#homePage .city-marquee.city-chips {
  display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 0 !important; overflow: visible !important;
  -webkit-mask-image: none !important; mask-image: none !important;
}
#homePage .city-chips .city-chip { flex: none; }

/* 정렬(인기순·최신순) — 일정/지도 전환과 같은 분할 컨트롤 규격: 시각 40, 두 옵션 같은 폭 */
#explorePage .sort-tabs { height: 40px; padding: 2px !important; box-sizing: border-box; border: 0 !important; background: var(--a-neutral) !important; border-radius: 10px !important; display: inline-grid !important; grid-template-columns: 1fr 1fr; width: 160px !important; }
#explorePage .sort-tabs .sort-tab { min-height: 0 !important; height: 100%; padding: 0 !important; border-radius: 8px !important; font-weight: 700 !important; position: relative; }
#explorePage .sort-tabs .sort-tab::after { content: ''; position: absolute; inset: -4px 0; }
#explorePage .sort-tabs::before { top: 2px !important; bottom: 2px !important; left: 2px !important; width: calc((100% - 4px) / 2) !important; border: 0 !important; border-radius: 8px !important; }
#explorePage .sort-tabs:has(.sort-tab:nth-of-type(2).is-active)::before { transform: translateX(100%) !important; }

/* 여행 중 — 두 행 [지금/다음][장소 이름(최대 두 줄)][시각·남은 시간] */
#schedulePage .now-next { padding: 10px 12px !important; display: flex !important; flex-direction: column; gap: 4px; }
#schedulePage .now-next[hidden] { display: none !important; }
#schedulePage .now-next .nn-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 0 0 2px !important; font-size: 13px; color: var(--r-text-2); }
#schedulePage .now-next .nn-head strong { font-weight: 800; color: var(--r-text); }
#schedulePage .now-next .nn-go { min-height: 32px !important; font-size: 13px !important; }
#schedulePage .now-next .nn-row { display: grid !important; grid-template-columns: 34px minmax(0, 1fr) auto; align-items: baseline; column-gap: 8px; padding: 4px 0 !important; }
#schedulePage .now-next .nn-label { font-size: 13px; font-weight: 800; color: var(--r-text-2); }
#schedulePage .now-next .nn-name {
  font-size: 15px; font-weight: 700; color: var(--r-text); line-height: 1.35;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere;
}
#schedulePage .now-next .nn-meta { font-size: 13px; color: var(--r-text-2); white-space: nowrap; font-variant-numeric: tabular-nums; text-align: right; }
#schedulePage .now-next .nn-done { margin: 2px 0 0; font-size: 13px; color: var(--r-text-2); }
/* 예산 — 예상 총액에 ‘2명 전체 · 추정 요금’을 붙여 둔다 */
#schedulePage .money-rows--panel .money-row dt .money-note { display: block; margin-top: 2px; font-size: 12px; font-weight: 500; color: var(--r-text-3); }
#schedulePage .budget-meta[hidden] { display: none !important; }
/* 타임라인 — 지도 열기도 44 높이로 누를 수 있게 */
.timeline .sc-where .sc-map-link { min-height: 44px !important; margin: -6px 0; }
@media (min-width: 768px) { #homePage .search-card { margin-left: 0 !important; margin-right: auto !important; } }
@media (min-width: 600px) { .home-subh-row .section-more { display: none !important; } }
#schedulePage .now-next .nn-row { grid-template-columns: 40px minmax(0, 1fr) auto !important; }
#schedulePage .now-next .nn-label { white-space: nowrap; }


/* 데스크톱 — 로고·메뉴와 본문(제목·검색·카드)의 양끝 기준선을 같게 */
@media (min-width: 1024px) { html body .app-topbar { padding-left: 16px !important; padding-right: 16px !important; } }
@media (min-width: 1024px) {
  .topbar-spacer.topbar-actions { width: auto !important; min-width: 0 !important; }
  :root:not([data-page="my-blogs"]) .topbar-spacer.topbar-actions { display: none !important; }
}
/* ‘여행 스타일로 찾기’와 ‘전체 스타일’을 같은 중심선에 — 제목의 바깥 여백은 줄(row)이 갖는다 */
#homePage .home-subh-row .home-subh { margin: 0 !important; }
