.support-reading-grid{max-width:none;align-items:start}
.support-filter-form,.support-message-filter{display:grid;gap:12px;margin-bottom:18px}
.support-filter-form .search-input{width:100%;min-width:0}
.support-filter-form.support-search-form{grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:8px}
.order-chat-history:not(.support-message-filter){margin-bottom:10px}
.support-filter-actions{display:flex;flex-wrap:wrap;gap:8px;align-items:center}
.support-selection{padding:14px;background:#f2f8fc;border:1px solid #d9e9f2;border-radius:12px;margin:14px 0;display:grid;gap:10px}
.support-selection p{margin:0;font-size:13px;font-weight:600;color:#27465d}
.support-pagination{display:flex;flex-wrap:wrap;gap:9px;align-items:center;justify-content:space-between;margin:12px 0;font-size:12px;color:#566877}
.support-pagination>p,.support-pagination>small{flex-basis:100%;margin:0}
.support-pagination>div{display:flex;gap:6px}
.support-session-row{display:flex;align-items:flex-start;gap:10px;min-width:0}
.support-session-check{width:18px;height:18px;flex:0 0 18px;margin:18px 0 0;accent-color:#24749e;cursor:pointer}
.support-session-card{text-align:left;width:100%;min-width:0}
.support-session-card.selected{border-color:#90cbed;background:#f1f9fe}
.support-session-card p{font-size:12px}
.support-session-card p.muted{font-size:11px;margin-top:9px}
.support-message-filter{border-top:1px solid #e7edf2;border-bottom:1px solid #e7edf2;padding:14px 0}
@media(max-width:760px){.support-reading-grid{grid-template-columns:minmax(0,1fr)}.support-filter-form .field-grid,.support-message-filter .field-grid{grid-template-columns:minmax(0,1fr)}.support-session-check{width:22px;height:22px;flex-basis:22px}.support-selection .btn{min-height:42px}}

/* 三個入口共用：訊息欄位避免縮放，鍵盤展開後仍可看到輸入與傳送。 */
.chat-compose{min-width:0}
.chat-compose textarea{min-width:0;width:0;font-size:16px;line-height:1.5}
.chat-compose button[type="submit"]{flex:none;min-height:45px}
@media(max-width:760px),(any-pointer:coarse){
 .recipient-label select{font-size:16px;min-width:0;max-width:100%;min-height:40px}
 .drawer-chat{padding:16px}
 .chat-compose{gap:7px}
 .chat-compose .btn{padding:10px 12px}
 html[data-chat-editing]{scroll-behavior:auto}
 html[data-chat-editing] .mobile-nav{display:none}
 html[data-chat-editing="order"] .order-drawer{top:var(--chat-visible-top,0px);bottom:auto;height:var(--chat-visible-height,100dvh);max-height:var(--chat-visible-height,100dvh);scroll-behavior:auto;overflow-anchor:none;scroll-padding:72px 0 12px}
 html[data-chat-editing="order"] .drawer-top{padding:10px 16px}
 html[data-chat-editing="order"] .drawer-top .section-kicker{display:none}
 html[data-chat-editing="order"] .drawer-top h2{font-size:19px;margin:0}
 html[data-chat-editing="support"] body{padding-bottom:calc(var(--chat-keyboard-inset,0px) + 16px + env(safe-area-inset-bottom,0px))}
 .chat-compose textarea{scroll-margin:70px 0 16px;max-height:90px}
}

/* 未讀訊息沿用三端的行程入口與卡片，0 則時不佔空間。 */
.unread-badge{display:inline-flex;align-items:center;justify-content:center;min-width:21px;height:21px;padding:0 5px;border-radius:999px;background:#db3048;color:#fff!important;font-size:12px;font-weight:750;line-height:1;font-variant-numeric:tabular-nums;white-space:nowrap;flex:none}
.nav-item{position:relative}
#desktop-nav .nav-unread-badge{margin-left:auto}
.mobile-nav .nav-unread-badge{position:absolute;top:1px;left:calc(50% + 5px);border:2px solid #fff;min-width:22px;height:22px;box-shadow:0 1px 3px #8d152627}
.order-card-actions .order-unread-badge{margin-left:2px;box-shadow:none}

/* 地址與複製按鈕同排；長地址自然換行，不裁切門牌與樓層。 */
.address-copy-row{display:flex;align-items:flex-start;gap:8px;min-width:0;width:100%}
.address-copy-text{flex:1;min-width:0;white-space:pre-wrap;overflow-wrap:anywhere}
.airport-route-stops li>div:has(.address-copy-row){flex:1}
.address-copy-button{flex:none;display:inline-flex;align-items:center;justify-content:center;min-width:44px;min-height:32px;padding:5px 8px;border:1px solid #cfe8f7;border-radius:9px;background:#eef9ff;color:#1677ad;font-size:12px;font-weight:600;line-height:1.4;cursor:pointer;white-space:nowrap}
.address-copy-button:disabled{opacity:.6;cursor:wait}
.address-copy-button:focus-visible{outline:2px solid #228bcc;outline-offset:2px}
.address-copy-dialog{width:420px;max-width:calc(100% - 28px);padding:20px;border:1px solid #d8eaf5;border-radius:18px;color:#24465c;box-shadow:0 15px 50px #183c5933}
.address-copy-dialog::backdrop{background:#17374d50}
.address-copy-heading{display:flex;align-items:center;justify-content:space-between;gap:10px}
.address-copy-dialog p{font-size:14px;line-height:1.6;margin:14px 0}
.address-copy-dialog textarea{width:100%;font-size:16px;line-height:1.6;resize:none}

/* 司機與乘客所有頁面直接顯示內容，連線資訊收在我的帳號。 */
#app[data-portal="driver"] .app-header,#app[data-portal="passenger"] .app-header{display:none}
body:has(#app[data-portal="driver"]) .matching-invitation-compact{top:calc(env(safe-area-inset-top) + 12px)}

#app[data-portal="driver"] #sync-status,#app[data-portal="passenger"] #sync-status{display:none}
#app[data-portal="driver"] #last-sync,#app[data-portal="passenger"] #last-sync{display:none}

.account-connection{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:8px 16px;padding:13px 0;margin-bottom:4px;border-bottom:1px solid var(--line);font-size:13px}
.account-connection>strong{font-weight:600}
.account-connection>div{text-align:right;min-width:0}
.account-connection-status{display:inline-flex;align-items:center;gap:7px;font-size:13px;color:#23856e;white-space:nowrap}
.account-connection-status.offline{color:#ac6b18}
.account-connection-status.offline .live-dot{background:#d8a043}
.account-connection small{display:block;font-size:11px;color:var(--muted);margin-top:3px}

/* 手機底部選單使用實色，減少 LINE 內建瀏覽器滑動時的背景合成。 */
@media(max-width:768px){
 #app[data-portal="passenger"] .mobile-nav,#app[data-portal="driver"] .mobile-nav{background:#fff;-webkit-backdrop-filter:none;backdrop-filter:none}
}
