
/* 易壅塞路段表格樣式（與天氣資訊頁同一套設計語言） */
.congestion-card {
    max-width: 1200px;
    margin: 0 auto;
    padding-bottom: 60px;
}
.congestion-table-container {
    background: #fff;
    border: 1px solid #e6ebf2;
    border-radius: 14px;
    overflow: auto;
    /* 限高讓捲動發生在表格內（搭配 sticky 表頭） */
    max-height: 68vh;
    box-shadow: 0 2px 12px rgba(44,84,132,0.08);
}
.congestion-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 1rem;
}
.congestion-table th, .congestion-table td {
    text-align: left;
    padding: 14px 18px;
    vertical-align: middle;
}
/* 表頭固定：底線用 box-shadow，sticky 時才不會跟著捲走 */
.congestion-table thead th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: #f4f7fb;
    color: #33475c;
    font-size: 0.875rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    box-shadow: inset 0 -1px 0 #dfe6ee;
}
/* 欄寬改由 CSS 控制（原 th width 屬性為過時寫法） */
.congestion-table th:nth-child(1) { width: 15%; }
.congestion-table th:nth-child(2) { width: 10%; }
.congestion-table th:nth-child(3),
.congestion-table th:nth-child(4),
.congestion-table th:nth-child(5) { width: 25%; }
.congestion-table tbody td {
    color: #1f2937;
}
.congestion-table tbody tr:last-child td {
    border-bottom: none;
}
.highway-group {
    border-bottom: 1px solid #e6ebf2 !important;
}
.highway-group td {
    border-bottom: 1px dashed #edf1f6;
}
.highway-group:last-child td {
    border-bottom: none;
}
@media (max-width: 600px) {
    .congestion-table { font-size: 0.9375rem; }
    .congestion-table th, .congestion-table td { padding: 10px 12px; }
}
.back-to-top {
    position: fixed;
    bottom: 40px;
    right: 20px;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #3730a3;
    color: #fff;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.125rem;
    box-shadow: 0 4px 12px rgba(55,48,163,0.35);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease, transform 0.25s ease;
    z-index: 999;
}
.back-to-top.visible {
    opacity: 1;
    pointer-events: auto;
}
.back-to-top:hover {
    background: #4338ca;
    transform: translateY(-2px);
}
