/* Selection layout: primary filters stay visible; only secondary inputs fold. */
body.compact-selection .topbar { z-index: 10; }
body.compact-selection .site-info-menu { position: relative; flex: 0 0 auto; margin-left: auto; }
.site-info-menu > summary { display: flex; align-items: center; min-height: 34px; padding: 0 10px; border: 1px solid var(--line); border-radius: 6px; background: #fff; font-size: 12px; cursor: pointer; list-style: none; }
.site-info-menu > summary::-webkit-details-marker { display: none; }
.site-info-content { position: absolute; right: 0; top: calc(100% + 6px); width: min(300px, calc(100vw - 24px)); padding: 12px; border: 1px solid var(--line); border-radius: 6px; background: #fff; box-shadow: 0 8px 24px #15243618; font-size: 13px; z-index: 20; }
body.compact-selection .site-info-content .public-guide-nav { display: grid; gap: 4px; margin: 0; padding: 0; background: transparent; }
.site-info-content a { display: flex; align-items: center; min-height: 36px; }
body.compact-selection .site-info-content .bill-check-entry { margin: 8px 0; font-size: 12px; }
body.compact-selection .select-tools { display: block; margin: 0; padding: 0 8px 4px; border: 0; border-radius: 0; background: transparent; }
.selection-quickbar { display: flex; align-items: center; gap: 6px; min-width: 0; }
body.compact-selection .selection-quickbar .city-selector,
body.compact-selection .selection-quickbar .global-filter-bar { flex: 0 1 auto; min-width: 0; margin: 0; padding: 0; gap: 4px; overflow-x: auto; }
body.compact-selection .selection-quickbar .city-selector { max-width: 40%; }
body.compact-selection .selection-quickbar .city-chip,
body.compact-selection .selection-quickbar .global-filter-chip,
body.compact-selection .selection-quickbar .inspiration-mode-link { flex: 0 0 auto; width: auto; min-height: 34px; margin: 0; padding: 0 9px; border: 1px solid var(--line); border-radius: 6px; background: #fff; font-size: 12px; line-height: 1.2; white-space: nowrap; }
body.compact-selection .selection-quickbar .inspiration-mode-link { margin-left: auto; }
body.compact-selection .monthly-filter-bar { display: flex; align-items: center; gap: 6px; margin: 5px 0; }
body.compact-selection .monthly-filter-label,
body.compact-selection .quick-filter-label { flex: 0 0 auto; font-size: 12px; color: var(--text); }
body.compact-selection .monthly-filter-scroll { display: flex; flex: 1; min-width: 0; gap: 4px; flex-wrap: wrap; overflow: visible; }
body.compact-selection .monthly-filter-chip,
body.compact-selection .quick-rule-tags button,
body.compact-selection .advanced-chip-wrap button,
body.compact-selection .more-filter-toggle { min-height: 32px; padding: 0 7px; border-radius: 6px; font-size: 12px; line-height: 1.3; }
body.compact-selection .quick-filter-line { display: flex; align-items: center; gap: 6px; margin: 5px 0 0; overflow: visible; }
body.compact-selection .quick-rule-tags { display: flex; flex: 1; min-width: 0; flex-wrap: wrap; max-height: none; overflow: visible; gap: 4px; }
body.compact-selection .more-filter-toggle { flex: 0 0 auto; }
.selection-filter-panel { margin-top: 6px; padding: 8px 0; border-block: 1px solid var(--line); }
.selection-filter-panel[hidden] { display: none; }
.selection-filter-head { display: flex; align-items: center; justify-content: space-between; font-size: 13px; }
.selection-filter-head button { min-height: 32px; padding: 0 10px; border-radius: 6px; font-size: 12px; color: var(--text); }
.precision-options { margin: 4px 0; }
.precision-options > summary { min-height: 32px; padding: 6px 0; font-size: 12px; cursor: pointer; }
body.compact-selection .selection-filter-panel #positionSearch { display: grid; grid-template-columns: minmax(0, 1fr) 42px 38px; gap: 4px; margin: 0; padding: 6px 0; border: 0; background: transparent; }
body.compact-selection #positionSearch > span { display: none; }
body.compact-selection #positionSearch #positionInputs { display: grid; grid-template-columns: repeat(11, minmax(0, 1fr)); gap: 3px; width: auto; }
body.compact-selection #positionSearch #positionInputs .position-digit { width: 100%; min-width: 0; max-width: none; height: 34px; padding: 0; font-size: 16px; }
body.compact-selection #positionSearch .position-search-button,
body.compact-selection #positionSearch .position-clear-button { min-width: 0; min-height: 34px; margin: 0; padding: 0; font-size: 12px; }
body.compact-selection.select-channel-active .channel-type-guide[data-context="hint"] { display: none; }
body.compact-selection.select-channel-active .channel-type-guide { margin: 2px 8px 4px; padding: 3px 6px; min-height: 24px; font-size: 12px; line-height: 1.5; }
body.compact-selection.select-channel-active .channel-type-guide strong { font-size: 12px; }
body.compact-selection .list-fee-notice { padding: 0 8px; font-size: 12px; }
.fee-notice-disclosure > summary { min-height: 30px; padding: 6px 0; line-height: 18px; cursor: pointer; font-size: 12px; }
.fee-notice-content { padding: 2px 0 8px; line-height: 1.6; }
body.compact-selection.select-channel-active .tabs { display: none; }
body.compact-selection .list-title-group { min-width: 0; display: flex; align-items: center; gap: 6px; }
body.compact-selection #listTitle { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
body.compact-selection #resultViewPicker { flex: 0 0 auto; width: 104px; min-height: 30px; padding: 3px 4px; border: 0; background: transparent; font-size: 12px; color: var(--text); }
body.compact-selection #searchModePicker { width: 86px; min-width: 0; height: 38px; padding: 0 4px; border: 1px solid var(--line); border-radius: 6px; font-size: 12px; background: #fff; color: var(--text); }
body.compact-selection .home-search .search-input-row { display: grid; grid-template-columns: 86px minmax(0, 1fr) 40px 36px; gap: 4px; }
body.compact-selection #searchInput[hidden], body.compact-selection #positionModeSummary[hidden] { display: none; }
body.compact-selection .position-mode-summary { min-width: 0; height: 38px; padding: 9px 8px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 12px; line-height: 20px; color: var(--muted); }

@media (max-width: 620px) {
  body.compact-selection .topbar { min-height: 42px; padding: 4px 8px; gap: 6px; }
  body.compact-selection .brand-reset h1 { font-size: 15px; line-height: 1.3; }
  body.compact-selection .brand-reset p { font-size: 11px; }
  body.compact-selection.select-channel-active .home-search { margin: 0; padding: 5px 8px; }
  body.compact-selection .home-search .search-input-row > input { min-width: 0; min-height: 38px; height: 38px; padding: 6px 8px; font-size: 16px; border-radius: 6px; }
  body.compact-selection .home-search .search-submit-button,
  body.compact-selection .home-search .search-clear-button { min-width: 0; width: auto; min-height: 36px; padding: 0; font-size: 12px; border-radius: 6px; }
  body.compact-selection.select-channel-active .channel-nav { min-height: 34px; margin: 0 0 3px; }
  body.compact-selection.select-channel-active .channel-tab { min-height: 32px; padding: 0 11px; font-size: 12px; }
  body.compact-selection.select-channel-active .list-head { min-height: 32px; padding: 2px 8px; gap: 6px; font-size: 12px; }
  body.compact-selection.select-channel-active .result-count { font-size: 11px; }
  body.compact-selection.select-channel-active .clear-filter-button { flex: 0 0 auto; font-size: 11px; min-height: 28px; padding: 0 6px; }
  body.compact-selection #numberList { container-type: inline-size; }
  body.compact-selection.select-channel-active .feed-line { grid-template-columns: minmax(0, 1fr) 26px 28px 42px; gap: 3px; min-height: 38px; }
  body.compact-selection.select-channel-active .number-main { font-size: 14px; line-height: 1.1; }
  body.compact-selection.select-channel-active .fee-pill { font-size: 10.5px; }
  body.compact-selection.select-channel-active .pool-button { width: 26px; min-width: 0; font-size: 11px; }
  body.compact-selection.select-channel-active .detail-toggle { width: 28px; min-width: 0; font-size: 11px; }
  body.compact-selection.select-channel-active .reserve-button { width: 42px; min-width: 0; font-size: 12px; }
  body.compact-selection.select-channel-active .row-detail { font-size: 12px; }
}
@container (min-width: 360px) {
  body.compact-selection.select-channel-active .number-main { font-size: 16px; }
}
@container (max-width: 329px) {
  body.compact-selection.select-channel-active .number-main { font-size: 13px; }
  body.compact-selection.select-channel-active .fee-pill b { font-size: 0; margin-right: 1px; }
  body.compact-selection.select-channel-active .fee-pill b::after { content: attr(data-compact-label); font-size: 10.5px; }
  body.compact-selection.select-channel-active .fee-pill b[data-compact-label=""] { display: none; }
  body.compact-selection.select-channel-active .feed-line { grid-template-columns: minmax(0, 1fr) 24px 26px 38px; gap: 2px; }
  body.compact-selection.select-channel-active .pool-button { width: 24px; }
  body.compact-selection.select-channel-active .detail-toggle { width: 26px; }
  body.compact-selection.select-channel-active .reserve-button { width: 38px; }
}
@media (max-width: 359px) {
  body.compact-selection .brand-reset h1 { font-size: 14px; }
  body.compact-selection .selection-quickbar { gap: 4px; }
  body.compact-selection .selection-quickbar :is(.city-chip, .global-filter-chip, .inspiration-mode-link) { font-size: 12px; padding: 0 6px; }
}
