@charset "utf-8";
/* 課表整合樣式：搭配 main.css，無須再載入 table.css。
   包含日期篩選、日期標題、課程標籤、桌面表格、手機卡片。
   桌面：801px 以上；手機／平板：800px 以下。
*/

/* ---------- 日期篩選：文字＋底線 ---------- */
#tabsNav {
    box-sizing: border-box;
    display: flex;
    flex-wrap: wrap;
    gap: 0;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    margin: 0 0 18px;
    padding: 0;
    border: 0;
    border-bottom: 1px solid #ddd;
    background: none;
    list-style: none;
}
#tabsNav > li {
    display: block;
    flex: 0 0 auto;
    float: none;
    width: auto;
    margin: 0;
    padding: 0;
    border: 0;
    background: none;
    box-shadow: none;
    list-style: none;
}
#tabsNav > li > a {
    box-sizing: border-box;
    display: block;
    padding: 12px 20px;
    border: 0;
    border-bottom: 3px solid transparent;
    border-radius: 0;
    background: transparent;
    color: #777;
    font-size: 17px;
    font-weight: normal;
    line-height: 1.5;
    text-align: center;
    text-decoration: none;
    white-space: nowrap;
    box-shadow: none;
    transition: background .2s, color .2s, border-color .2s;
}
#tabsNav > li > a:hover {
    background: #faf7f4;
    color: #76432e;
    border-bottom-color: #d8c2b4;
}
#tabsNav > li.active > a {
    border: 0;
    border-bottom: 3px solid #76432e;
    background: transparent;
    color: #76432e;
    font-weight: bold;
    box-shadow: none;
}
#tabsNav > li > a:focus-visible {
    outline: 2px solid #76432e;
    outline-offset: -2px;
}
#tabsNav > .clear { display: none; }

/* ---------- 每日課程與標籤 ---------- */
.tab_contentr { min-width: 0; }
.tab_contentr > .tab_content { margin-bottom: 28px; }
.tab_contentr .schedule-date {
    margin: 0 0 12px;
    padding: 10px 14px;
    border-left: 4px solid #76432e;
    background: #f5eee8;
    color: #76432e;
    font-size: 20px;
    font-weight: bold;
    line-height: 1.5;
}
.tab_contentr .classTag {
    display: inline-block;
    padding: 4px 5px;
    border-radius: 2px;
    background: #e6e6e6;
    color: #666;
    font-size: 14px;
    font-weight: normal;
    line-height: 1.2;
    vertical-align: baseline;
}
.tab_contentr .classTagOrange { background: #f90; }
.tab_contentr .css-table { width: 100%; }
.tab_contentr .css-table .th,
.tab_contentr .css-table .td { box-sizing: border-box; }
.tab_contentr .css-table .td {
    overflow-wrap: break-word;
    word-wrap: break-word;
}
.tab_contentr .css-table .center { text-align: center; }
.tab_contentr .css-table .nowrap { white-space: nowrap; }

/* ---------- 桌面：三欄表格 ---------- */
@media screen and (min-width: 801px) {
    .tab_contentr .css-table {
        display: table;
        border-collapse: collapse;
    }
    .tab_contentr .css-table > .thead { display: table-header-group; }
    .tab_contentr .css-table > .tbody { display: table-row-group; }
    .tab_contentr .css-table .tr { display: table-row; }
    .tab_contentr .css-table .th,
    .tab_contentr .css-table .td {
        display: table-cell;
        padding: 5px 10px;
        border-bottom: 1px solid #e0e0e0;
        vertical-align: middle;
    }
    .tab_contentr .css-table .th {
        background: #333;
        color: #fff;
    }
    .tab_contentr .css-table > .tbody > .tr:nth-child(odd) {
        background: #fafafa;
    }
}

/* ---------- 手機／平板：課程卡片 ---------- */
@media screen and (max-width: 800px) {
    .tab_contentr .card-table,
    .tab_contentr .card-table > .tbody { display: block; }
    .tab_contentr .card-table > .thead { display: none; }
    .tab_contentr .card-table > .tbody > .tr {
        display: block;
        margin: 0 0 12px;
        padding: 12px;
        border-radius: 5px;
        background: #fff;
        box-shadow: 0 1px 6px rgba(32, 33, 36, .2);
    }
    .tab_contentr .card-table > .tbody > .tr:last-child { margin-bottom: 0; }
    .tab_contentr .card-table .td {
        display: block;
        width: 100%;
        padding: 0;
        border: 0;
        line-height: 1.6;
    }
    .tab_contentr .card-table .tdHeader {
        margin-bottom: 8px;
        color: #70351c;
        font-size: 19px;
        font-weight: bold;
        text-align: left;
    }
    .tab_contentr .card-table .tdHeader span {
        color: #000;
        font-size: 15px;
    }
    .tab_contentr .card-table .td h4 {
        margin: 0 0 4px;
        line-height: 1.6;
    }
    .tab_contentr .card-table .td p { margin: 0; }
    .tab_contentr .card-table .td + .td { margin-top: 6px; }
}

/* ---------- 手機日期選單：單排左右滑動 ---------- */
@media screen and (max-width: 600px) {
    #tabsNav {
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
        padding-bottom: 4px;
    }
    #tabsNav > li > a {
        padding: 10px 16px;
        font-size: 15px;
    }
    .tab_contentr .schedule-date { font-size: 18px; }
}
