html {
    font-size: 100%;
    scroll-behavior: auto !important;
}

body {
    font-family: 微軟正黑體, Arial !important;
}

.topbar-inner, .header-inner, .ticker-wrap, .page-ticker-wrap, .crumb, .section-inner, .footer-inner, .tabs, .page-main-inner, .side-hero-content,
.page-hero-inner, main.main-wrap, .qi-hero-inner, .lq-page, .inner-hero-inner, .qual-inner, .qi-hero-inner, .q2q3-result-wrap {
    max-width: 1420px !important;
}

.crumb {
    font-size: 1rem !important;
}

.social-icon--ig {
    background: url("../../images/ig_bg.png") center/cover no-repeat;
}

a {
    color: var(--text);
    text-decoration: none;
}

.system-note {
    display: block;
    font-family: NotoSansTC, 'Noto Sans TC', sans-serif;
    font-size: 0.84375rem;
    font-weight: normal;
    font-stretch: normal;
    font-style: normal;
    line-height: 1.6;
    letter-spacing: normal;
    text-align: left;
    color: #226b5c;
}

.notice-emphasis-danger {
    padding-bottom: 1px;
    font-weight: bold;
    color: red;
}

.notice-link-accent {
    text-decoration: none;
    color: green;
    font-weight: bold;
}

.mailing-address-header {
    justify-content: flex-start;
    gap: 1rem;
}

.address-field {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.address-detail-row > .col:first-child {
    flex: 0 0 70%;
    max-width: 70%;
}

.address-detail-row > .col:last-child {
    flex: 0 0 30%;
    max-width: 30%;
}

input[type=radio], input[type="checkbox"] {
    width: 15px;
    height: 15px;
    accent-color: #226b5c;
}

input[readonly],
input[disabled],
textarea[readonly],
textarea:read-only,
textarea[disabled] {
    background-color: #f3f4f6 !important;
    border: 1px solid #cbd5e1 !important;
    color: #111827 !important;
    cursor: default !important;
    box-shadow: none !important;
    opacity: 1 !important;
}

input[readonly]:focus,
input:read-only:focus,
input[disabled]:focus,
textarea[readonly]:focus,
textarea:read-only:focus,
textarea[disabled]:focus {
    outline: none;
    box-shadow: none !important;
}

.btn {
    display: inline-flex;
    align-items: center;
    font-size: 0.8438rem;
    font-weight: 500;
    white-space: nowrap;
    color: var(--green-deep);
    cursor: pointer;
    font-family: "Noto Sans TC", sans-serif;
    letter-spacing: 0.04em;
    gap: 0.5rem;
    padding: 0.6875rem 1.5rem !important;
    border-width: 1.5px;
    border-style: solid;
    border-color: rgba(45, 138, 118, 0.25);
    border-image: initial;
    border-radius: 20px;
    background: rgb(255, 255, 255);
    transition: 0.22s;
}

    .btn:hover, .btn:focus-visible, .btn:active {
        color: var(--green-deep) !important;
        border-color: var(--green) !important;
        background: var(--green-pale) !important;
        transform: translateY(-1px) !important;
        box-shadow: 0 4px 12px -4px rgba(45, 138, 118, 0.2) !important;
    }

    .btn.btn-primary:disabled {
        color: #667a73 !important;
        border-color: #b9cbc4 !important;
        background: #dbe8e4 !important;
        cursor: not-allowed;
        opacity: 1;
        transform: none !important;
        box-shadow: none !important;
    }

    .btn.btn-invert {
        background-image: linear-gradient(135deg, #23837a 0%, #226b5c 100%);
        box-shadow: 0 6px 16px -6px rgba(34, 107, 92, 0.4);
        background-color: rgba(255, 255, 255, 0);
        color: #fff;
    }

    .btn.btn-download {
        font-size: 0.875rem;
        color: var(--gold);
        text-decoration: none;
        font-weight: 600;
        padding: 0.375rem 0.875rem;
        border: 1px solid var(--gold-soft);
        transition: all .2s;
    }

        .btn.btn-download:hover {
            background: var(--gold) !important;
            color: #fff !important;
            border-color: var(--gold) !important;
        }

    .btn.btn-reset {
        color: var(--green-deep);
        border-color: var(--green-soft);
        background: #fff;
    }

        .btn.btn-reset:hover {
            color: var(--green-deep) !important;
            border-color: var(--green) !important;
            background: var(--green-pale) !important;
        }

.class-actions {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.25rem;
}

.class-action-form {
    margin: 0;
}

.btn-edit,
.btn-delete,
.btn-search {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

    .btn-edit::before,
    .btn-delete::before,
    .btn-search::before {
        font-family: bootstrap-icons !important;
        font-style: normal;
        font-weight: 400;
        font-variant: normal;
        text-transform: none;
        line-height: 1;
        font-size: 0.95em;
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
    }

    .btn-edit::before {
        content: "\f4cb";
    }

    .btn-delete::before {
        content: "\F659";
    }

    .btn-search:before {
        content: "\F52A";
    }

    /*.trainex-type-link {
    display: inline-block;
    padding: 2px 4px;
    border-radius: 4px;
    font-weight: 600;
    color: #226b5c;
    outline: 1px solid #2a4a422b;
}

.trainex-type-link:hover {
    color: #28423bfa;
    background-color: #226b5c26;
}

.trainex-type-link:focus-visible {
    outline: 5px solid #2a4a422b;
}*/
.page-hero {
    background: linear-gradient(135deg,#1A2E3A 0%,#1E3A30 55%,#243C3A 100%) !important;
    border-bottom: none !important;
    padding: 3.5rem 0 3rem !important;
}

.page-hero {
    background: linear-gradient(135deg,#F8F4EB 0%,#F2EAD6 40%,#EEE8D8 100%);
    padding: 3.25rem 0 2.75rem;
    position: relative;
    overflow: hidden;
    border-bottom: 2px solid var(--gold)
}

    .page-hero::before {
        content: "";
        position: absolute;
        top: -80px;
        right: -80px;
        width: 380px;
        height: 380px;
        border-radius: 50%;
        background: radial-gradient(circle,rgba(212,169,74,0.14),transparent 68%);
        pointer-events: none
    }

    .page-hero::after {
        content: "";
        position: absolute;
        bottom: -60px;
        left: 10%;
        width: 280px;
        height: 280px;
        border-radius: 50%;
        background: radial-gradient(circle,rgba(45,138,118,0.08),transparent 68%);
        pointer-events: none
    }

.page-hero-deco {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: 480px;
    pointer-events: none;
    overflow: hidden
}

.page-hero-deco-r {
    position: absolute;
    border-radius: 20px;
    border: 1.5px solid
}

@keyframes phFloat1 {
    0%,100% {
        transform: rotate(-8deg) translateY(0)
    }

    50% {
        transform: rotate(-8deg) translateY(-6px)
    }
}

@keyframes phFloat2 {
    0%,100% {
        transform: rotate(5deg) translateY(0)
    }

    50% {
        transform: rotate(5deg) translateY(5px)
    }
}

@keyframes phFloat3 {
    0%,100% {
        transform: rotate(-3deg) translateY(0)
    }

    50% {
        transform: rotate(-3deg) translateY(-4px)
    }
}

.page-hero-deco-r1 {
    width: 240px;
    height: 170px;
    right: -40px;
    top: -20px;
    border-color: rgba(212,169,74,0.35);
    background: rgba(212,169,74,0.07);
    animation: phFloat1 7s ease-in-out infinite
}

.page-hero-deco-r2 {
    width: 190px;
    height: 150px;
    right: 110px;
    top: -10px;
    border-color: rgba(212,169,74,0.3);
    background: rgba(212,169,74,0.04);
    animation: phFloat2 9s ease-in-out infinite
}

.page-hero-deco-r3 {
    width: 140px;
    height: 120px;
    right: 10px;
    bottom: -10px;
    border-color: rgba(212,169,74,0.22);
    background: rgba(212,169,74,0.05);
    animation: phFloat3 8s ease-in-out infinite
}

.page-hero-inner {
    max-width: 1320px;
    margin: 0 auto;
    padding-top: 0;
    padding-bottom: 0;
    padding-left: 2.5rem;
    padding-right: 2.5rem;
    position: relative;
    z-index: 2
}

.page-hero-label {
    font-size: 0.75rem;
    letter-spacing: 0.3em;
    color: var(--accent);
    text-transform: uppercase;
    margin-bottom: 0.75rem;
    font-family: 'JetBrains Mono',monospace;
    font-weight: 600
}

.page-hero-title {
    font-family: 'Noto Serif TC',serif;
    font-size: 2.875rem;
    font-weight: 700;
    color: var(--green-deep);
    line-height: 1.3;
    margin-bottom: 0
}

    .page-hero-title span {
        color: var(--green-deep);
        font-style: normal
    }

.page-hero-gold-line {
    width: 52px;
    height: 2px;
    background: linear-gradient(90deg,var(--gold),var(--gold-soft),transparent);
    border-radius: 2px;
    margin: 1rem 0 0.625rem
}

.page-hero-sub {
    font-size: 0.9375rem;
    color: var(--text-muted);
    letter-spacing: 0.05em
}

@media(max-width:40rem) {
    .page-hero-inner {
        padding-left: 1.125rem;
        padding-right: 1.125rem
    }
}

@media(max-width:57.5rem) {
    .section-inner, .page-hero-inner {
        padding-left: 1.5rem;
        padding-right: 1.5rem
    }
}

@media(max-width:40rem) {
    .page-hero-title {
        font-size: 1.875rem
    }
}

.page-hero {
    background: linear-gradient(135deg,#1A2E3A 0%,#1E3A30 55%,#243C3A 100%) !important;
    border-bottom: none !important;
    padding: 3.5rem 0 3rem !important;
}

    .page-hero::before {
        content: "";
        position: absolute;
        left: 0;
        top: 0;
        bottom: 0;
        width: 5px;
        background: linear-gradient(180deg,var(--gold) 0%,var(--teal) 60%,transparent 100%);
        z-index: 3
    }

.page-hero-label {
    color: rgba(255,255,255,0.55) !important;
    letter-spacing: 0.32em;
    font-size: 0.6875rem !important
}

.page-hero-title {
    color: #fff !important;
    font-size: 3.25rem !important;
    line-height: 1.15 !important
}

    .page-hero-title span {
        color: var(--gold-soft) !important;
        font-style: normal !important
    }

.page-hero-gold-line {
    background: linear-gradient(90deg,var(--gold),var(--gold-soft),transparent) !important;
    margin: 1.125rem 0 0.75rem !important
}

.page-hero-sub {
    color: rgba(255,255,255,0.55) !important
}

.page-hero-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.14);
    border-radius: 20px;
    padding: 0.3125rem 0.875rem;
    font-size: 0.75rem;
    color: rgba(255,255,255,0.60);
    letter-spacing: 0.06em;
    font-family: 'JetBrains Mono',monospace
}

    .page-hero-tag::before {
        content: "";
        width: 6px;
        height: 6px;
        border-radius: 50%;
        background: var(--teal);
        flex-shrink: 0
    }

.page-hero-deco-r {
    border-color: rgba(255,255,255,0.10) !important;
    background: rgba(255,255,255,0.04) !important
}

.page-hero-deco-r1 {
    border-color: rgba(212,169,74,0.30) !important;
    background: rgba(212,169,74,0.06) !important
}
/* === HERO REDESIGN v2 - 淺底排版層次 === */
.page-hero {
    background: #F7F4EE !important;
    border-bottom: none !important;
    padding: 0 !important;
    min-height: 180px;
}

.page-hero-inner {
    display: grid !important;
    grid-template-columns: 1fr !important;
    padding: 3rem 2.5rem 0 !important;
    position: relative;
}
    /* 大數字裝飾 - 各頁自訂 */
    .page-hero-inner::before {
        font-family: 'Noto Serif TC',serif;
        font-size: 9.375rem;
        font-weight: 700;
        color: rgba(34,107,92,0.05);
        line-height: 1;
        pointer-events: none;
        user-select: none;
        letter-spacing: -0.04em;
        position: absolute;
        right: 40px;
        top: 50%;
        transform: translateY(-55%);
    }

.page-hero::after {
    content: "";
    display: block;
    height: 1px;
    background: linear-gradient(90deg, var(--gold) 0%, var(--teal) 40%, transparent 80%);
    margin: 0 2.5rem;
    opacity: 0.6;
}

.page-hero-label {
    font-family: 'JetBrains Mono',monospace !important;
    font-size: 0.625rem !important;
    letter-spacing: 0.28em;
    color: var(--text-muted) !important;
    text-transform: uppercase;
    margin-bottom: 0.625rem !important;
    display: flex !important;
    align-items: center;
    gap: 0.625rem;
}

    .page-hero-label::before {
        content: "";
        width: 28px;
        height: 1px;
        background: var(--gold);
        flex-shrink: 0;
    }

.page-hero-title {
    font-family: 'Noto Serif TC',serif !important;
    font-size: 3.5rem !important;
    font-weight: 700 !important;
    color: var(--ink) !important;
    line-height: 1.1 !important;
    margin-bottom: 0 !important;
}

    .page-hero-title span {
        color: var(--green-deep) !important;
        font-style: normal !important;
    }

.page-hero-gold-line {
    background: linear-gradient(90deg,var(--gold),var(--gold-soft),transparent) !important;
    width: 52px !important;
    height: 2px !important;
    border-radius: 2px;
    margin: 1.125rem 0 0 !important;
}

.page-hero-sub {
    font-size: 0.8125rem !important;
    color: var(--text-muted) !important;
    letter-spacing: 0.08em;
    margin-top: 0.5rem !important;
}

.page-hero-bottom {
    grid-column: 1/-1;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1.25rem 0 1.75rem;
    border-top: 1px solid rgba(34,107,92,0.10);
    margin-top: 1.5rem;
}

.page-hero-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.4375rem;
    font-family: 'JetBrains Mono',monospace;
    font-size: 0.6875rem;
    letter-spacing: 0.1em;
    color: var(--text-muted);
}

.page-hero-chip-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--gold);
    flex-shrink: 0;
}

    .page-hero-chip-dot.teal {
        background: var(--teal);
    }

.page-hero-tag {
    display: none !important;
}

.page-hero-deco-r {
    display: none !important;
}

.page-hero-inner::before {
    content: "遴選";
}

.award-hero-deco, .page-hero-deco, .award-hero-deco-r, .page-hero-deco-r {
    display: none !important
}

.hero-geo {
    position: absolute;
    right: 40px;
    top: 50%;
    transform: translateY(-50%);
    width: 200px;
    height: 200px;
    pointer-events: none;
    user-select: none;
}

.award-hero::before, .page-hero::before {
    display: none !important;
}

.award-hero-inner::before, .page-hero-inner::before {
    display: none !important;
}
/* === HERO REDESIGN — orb system === */
.award-hero, .page-hero {
    background: #F7F4EE !important;
    position: relative !important;
    overflow: hidden !important;
    padding: 0 !important;
    border-bottom: none !important;
    min-height: 200px;
}

.hero-wave {
    display: none !important;
}

.hero-geo {
    display: none !important;
}

.award-hero::after, .page-hero::after {
    display: none !important;
}

.award-hero::before, .page-hero::before {
    display: none !important;
}

.award-hero-inner::before, .page-hero-inner::before {
    display: none !important;
}

.hero-orbs {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.hero-orb {
    position: absolute;
    border-radius: 50%;
}

.award-hero-inner, .page-hero-inner {
    position: relative;
    z-index: 2;
    padding: 2.75rem 3rem 0 3rem !important;
    display: block !important;
    grid-template-columns: unset !important;
}

.award-hero-label, .page-hero-label {
    font-family: 'JetBrains Mono',monospace !important;
    font-size: 0.625rem !important;
    letter-spacing: 0.28em;
    color: var(--text-muted) !important;
    margin-bottom: 0.625rem !important;
    display: flex !important;
    align-items: center;
    gap: 0.625rem;
}

    .award-hero-label::before, .page-hero-label::before {
        content: "";
        width: 20px;
        height: 1px;
        background: var(--gold);
        flex-shrink: 0;
    }

.award-hero-title, .page-hero-title {
    font-size: 3.25rem !important;
    font-weight: 700 !important;
    color: var(--ink) !important;
    line-height: 1.1 !important;
    margin-bottom: 0 !important;
    font-style: normal !important;
}

    .award-hero-title span, .page-hero-title span {
        color: var(--green-deep) !important;
        font-style: normal !important;
    }

.award-hero-bottom, .page-hero-bottom {
    padding: 1.125rem 0 1.625rem !important;
    border-top: 1px solid rgba(34,107,92,0.10) !important;
    margin-top: 1.25rem !important;
    display: flex !important;
    gap: 1.25rem !important;
}

.page-hero-gold-line {
    margin-top: 0.875rem !important;
}

.page-hero-sub {
    margin-top: 0.375rem !important;
}

@media(max-width:768px) {
    .award-hero-inner, .page-hero-inner {
        padding: 2rem 1.5rem 0 1.5rem !important;
    }

    .award-hero-title, .page-hero-title {
        font-size: 2.25rem !important;
    }

    .hero-orbs {
        opacity: 0.6;
    }
}

@media(max-width:920) {
    .page-hero-inner {
        padding-left: 1.5rem;
        padding-right: 1.5rem
    }
}

/*=== 表頭置中對齊 ===*/
table.dataTable th {
    vertical-align: middle !important;
    text-align: center !important;
    /*border: solid 1px #ccc !important;*/
    white-space: nowrap;
}

    /*=== 強迫表頭不受表身影響 ===*/
    table.dataTable th.text-start, table.dataTable th.text-end {
        text-align: center !important;
    }

/*=== Button 不換行 ===*/
table.dataTable .btn {
    white-space: nowrap;
}

/*=== 內容垂直置中 ===*/
table.dataTable > tbody > tr > td {
    vertical-align: middle !important;
}


fieldset {
    border: 1px solid silver;
    border-radius: 10px;
    padding: 0 1rem 0.7rem 1rem;
    width: max-content;
    max-width: 100%;
}

legend {
    top: -20px;
    float: inherit;
    width: inherit;
    font-size: 1.2rem;
    padding: 0 0.5rem;
    font-weight: bold;
}



/* === jquery.Datatables樣式 === */
/* 頁次 */
.view-pager {
    margin-top: .85rem !important;
    margin-bottom: 1rem !important;
    position: absolute;
    bottom: -60px;
    width: 100%;
    left: 0
}

/*=== paging 格式 ===*/
div.dt-container .dt-paging .dt-paging-button {
    padding: 0 !important;
}

div.dt-container div.dt-layout-row {
    margin-top: 0 !important;
}


.navbar {
    background-color: #fff !important;
    height: 60px; /* 設定 navbar 高度為 66px */
    font-weight: bold !important;
}

/*=== 頁籤樣式 ===*/
.nav-tabs .nav-item {
    /*width: 140px;*/
    margin-right: 3px;
}

    .nav-tabs .nav-item:last-child {
        margin-right: 0;
    }
/*=== 設定所有 Tab 的一般樣式為灰色背景 ===*/
.nav-tabs .nav-link {
    width: 100%;
    /* height: 45px; */
    background-color: #EBEEF5;
    color: #000;
    font-weight: bold;
    border: 1px solid #ddd;
    /*margin-bottom: -1px;*/ /* 移除底部邊框的重疊 */
}
    /* 設定 Active Tab 的樣式為白色背景 */
    .nav-tabs .nav-link.active {
        background-color: #fff;
        color: #000;
        margin-left: 0px;
        margin-top: 0px;
        /*border-bottom-color: transparent;*/ /* 讓 active 的 tab 與內容無縫連接 */
        /*border-bottom: none;*/
    }

.nav-link:disabled {
    pointer-events: auto;
    color: #a6a6a6;
    cursor: not-allowed;
}

/* 確保下拉選單在 hover 時不會馬上消失 */
.dropdown:hover .dropdown-menu {
    display: block;
}

/*=== 設定 tab-content 的邊框，使其與 Tab 連接 ===*/
.tab-content {
    /*background-color: #fff;*/
    border: 1px solid #ddd;
    border-top: none; /*=== 移除上邊框以連接 active 的 tab ===*/
    /*padding: 1rem;*/
}

    .tab-content > .tab-pane {
        padding: 1rem !important;
    }

/*=== 設定 tab-content 的邊框，使其與 Tab 連接 ===*/
.tab-content {
    /*background-color: #fff;*/
    border: 1px solid #ddd;
    border-top: none; /*=== 移除上邊框以連接 active 的 tab ===*/
    /*padding: 1rem;*/
}



input[type='checkbox'] + label, input[type='radio'] + label, label + input[type='checkbox'], label + input[type='radio'] {
    padding-left: 2pt;
}


.Dialog {
    display: none;
}

span.Required,
label.Required {
    position: relative;
    padding-left: 15px;
}
    span.Required::after,
    label.Required::after {
        content: '*';
        color: red;
        width: 10px;
        height: 10px;
        display: flex;
        align-items: normal;
        justify-content: center;
        position: absolute;
        left: 0;
        top: calc(50% - 8px);
    }

th.Required::before {
    content: '*';
    color: red;
    margin-right: 2px;
    position: relative;
    top: 2pt;
}


.FormRWD > .row {
    margin-bottom: 0.25rem;
}

    .FormRWD > .row > div {
        display: flex;
        align-items: center;
    }

.FormRWD .col-form-label {
    font-weight: bold;
}

@media (min-width: 768px) {
    .FormRWD .col-form-label {
        text-align: right;
    }
}

.Form > .row {
    margin-bottom: 0.25rem;
}

    .Form > .row > div {
        display: flex;
        align-items: center;
    }

    .Form > .row div > label:first-child {
        font-weight: bold;
        text-align: right;
        margin-right: 0.5rem;
    }

    .Form > .row div.NoColumnLabel > label:first-child {
        font-weight: inherit !important;
        text-align: inherit !important;
        margin-right: inherit !important;
        min-width: auto !important;
    }

/* .Col1-MinW-n */
.Form.Col1-MinW-1 > .row > div:nth-child(1) > label:first-child {
    min-width: 1rem;
}

.Form.Col1-MinW-2 > .row > div:nth-child(1) > label:first-child {
    min-width: 2rem;
}

.Form.Col1-MinW-3 > .row > div:nth-child(1) > label:first-child {
    min-width: 3rem;
}

.Form.Col1-MinW-4 > .row > div:nth-child(1) > label:first-child {
    min-width: 4rem;
}

.Form.Col1-MinW-5 > .row > div:nth-child(1) > label:first-child {
    min-width: 5rem;
}

.Form.Col1-MinW-6 > .row > div:nth-child(1) > label:first-child {
    min-width: 6rem;
}

.Form.Col1-MinW-7 > .row > div:nth-child(1) > label:first-child {
    min-width: 7rem;
}

.Form.Col1-MinW-8 > .row > div:nth-child(1) > label:first-child {
    min-width: 8rem;
}

.Form.Col1-MinW-9 > .row > div:nth-child(1) > label:first-child {
    min-width: 9rem;
}

.Form.Col1-MinW-10 > .row > div:nth-child(1) > label:first-child {
    min-width: 10rem;
}

/* .Col2-MinW-n */
.Form.Col2-MinW-1 > .row > div:nth-child(2) > label:first-child {
    min-width: 1rem;
}

.Form.Col2-MinW-2 > .row > div:nth-child(2) > label:first-child {
    min-width: 2rem;
}

.Form.Col2-MinW-3 > .row > div:nth-child(2) > label:first-child {
    min-width: 3rem;
}

.Form.Col2-MinW-4 > .row > div:nth-child(2) > label:first-child {
    min-width: 4rem;
}

.Form.Col2-MinW-5 > .row > div:nth-child(2) > label:first-child {
    min-width: 5rem;
}

.Form.Col2-MinW-6 > .row > div:nth-child(2) > label:first-child {
    min-width: 6rem;
}

.Form.Col2-MinW-7 > .row > div:nth-child(2) > label:first-child {
    min-width: 7rem;
}

.Form.Col2-MinW-8 > .row > div:nth-child(2) > label:first-child {
    min-width: 8rem;
}

.Form.Col2-MinW-9 > .row > div:nth-child(2) > label:first-child {
    min-width: 9rem;
}

.Form.Col2-MinW-10 > .row > div:nth-child(2) > label:first-child {
    min-width: 10rem;
}

/* .Col3-MinW-n */
.Form.Col3-MinW-1 > .row > div:nth-child(3) > label:first-child {
    min-width: 1rem;
}

.Form.Col3-MinW-2 > .row > div:nth-child(3) > label:first-child {
    min-width: 2rem;
}

.Form.Col3-MinW-3 > .row > div:nth-child(3) > label:first-child {
    min-width: 3rem;
}

.Form.Col3-MinW-4 > .row > div:nth-child(3) > label:first-child {
    min-width: 4rem;
}

.Form.Col3-MinW-5 > .row > div:nth-child(3) > label:first-child {
    min-width: 5rem;
}

.Form.Col3-MinW-6 > .row > div:nth-child(3) > label:first-child {
    min-width: 6rem;
}

.Form.Col3-MinW-7 > .row > div:nth-child(3) > label:first-child {
    min-width: 7rem;
}

.Form.Col3-MinW-8 > .row > div:nth-child(3) > label:first-child {
    min-width: 8rem;
}

.Form.Col3-MinW-9 > .row > div:nth-child(3) > label:first-child {
    min-width: 9rem;
}

.Form.Col3-MinW-10 > .row > div:nth-child(3) > label:first-child {
    min-width: 10rem;
}

/* .Col4-MinW-n */
.Form.Col4-MinW-1 > .row > div:nth-child(4) > label:first-child {
    min-width: 1rem;
}

.Form.Col4-MinW-2 > .row > div:nth-child(4) > label:first-child {
    min-width: 2rem;
}

.Form.Col4-MinW-3 > .row > div:nth-child(4) > label:first-child {
    min-width: 3rem;
}

.Form.Col4-MinW-4 > .row > div:nth-child(4) > label:first-child {
    min-width: 4rem;
}

.Form.Col4-MinW-5 > .row > div:nth-child(4) > label:first-child {
    min-width: 5rem;
}

.Form.Col4-MinW-6 > .row > div:nth-child(4) > label:first-child {
    min-width: 6rem;
}

.Form.Col4-MinW-7 > .row > div:nth-child(4) > label:first-child {
    min-width: 7rem;
}

.Form.Col4-MinW-8 > .row > div:nth-child(4) > label:first-child {
    min-width: 8rem;
}

.Form.Col4-MinW-9 > .row > div:nth-child(4) > label:first-child {
    min-width: 9rem;
}

.Form.Col4-MinW-10 > .row > div:nth-child(4) > label:first-child {
    min-width: 10rem;
}

/* .Col5-MinW-n */
.Form.Col5-MinW-1 > .row > div:nth-child(5) > label:first-child {
    min-width: 1rem;
}

.Form.Col5-MinW-2 > .row > div:nth-child(5) > label:first-child {
    min-width: 2rem;
}

.Form.Col5-MinW-3 > .row > div:nth-child(5) > label:first-child {
    min-width: 3rem;
}

.Form.Col5-MinW-4 > .row > div:nth-child(5) > label:first-child {
    min-width: 4rem;
}

.Form.Col5-MinW-5 > .row > div:nth-child(5) > label:first-child {
    min-width: 5rem;
}

.Form.Col5-MinW-6 > .row > div:nth-child(5) > label:first-child {
    min-width: 6rem;
}

.Form.Col5-MinW-7 > .row > div:nth-child(5) > label:first-child {
    min-width: 7rem;
}

.Form.Col5-MinW-8 > .row > div:nth-child(5) > label:first-child {
    min-width: 8rem;
}

.Form.Col5-MinW-9 > .row > div:nth-child(5) > label:first-child {
    min-width: 9rem;
}

.Form.Col5-MinW-10 > .row > div:nth-child(5) > label:first-child {
    min-width: 10rem;
}

/* MinW-n */
.Form div.MinW-1 > label:first-child {
    min-width: 1rem !important;
}

.Form div.MinW-2 > label:first-child {
    min-width: 2rem !important;
}

.Form div.MinW-3 > label:first-child {
    min-width: 3rem !important;
}

.Form div.MinW-4 > label:first-child {
    min-width: 4rem !important;
}

.Form div.MinW-5 > label:first-child {
    min-width: 5rem !important;
}

.Form div.MinW-6 > label:first-child {
    min-width: 6rem !important;
}

.Form div.MinW-7 > label:first-child {
    min-width: 7rem !important;
}

.Form div.MinW-8 > label:first-child {
    min-width: 8rem !important;
}

.Form div.MinW-9 > label:first-child {
    min-width: 9rem !important;
}

.Form div.MinW-10 > label:first-child {
    min-width: 10rem !important;
}



.FormTable {
    width: 100%;
}

    .FormTable th, .FormTable td {
        padding-top: 1pt;
        padding-bottom: 2pt;
    }

    .FormTable th {
        width: 1%;
        white-space: nowrap;
        text-align: right;
        padding-right: 5pt;
    }

        .FormTable th:not(:first-child) {
            padding-left: 20pt;
        }



.field-validation-error, .validation-summary-errors {
    color: red;
}


.DatePicker {
    width: 120pt;
    background-image: url('../images/calendar-10-16.gif');
    background-repeat: no-repeat;
    background-position: calc(100% - 5px) center;
}

.TimePicker {
    width: 70pt;
    background-image: url('../images/clock-5-16.gif');
    background-repeat: no-repeat;
    background-position: calc(100% - 5px) center;
}

.ui-datepicker  {
    width: auto !important;
}

    .ui-datepicker .ui-datepicker-header > div {
        width: 100% !important;
        padding: 0 2em !important;
    }

.ui-datepicker-year {
    width: 80pt !important;
}

.ui-datepicker-month {
    width: 60pt !important;
}

input:not([type='submit']):not([type='button']):not([type='reset']).Disabled,
select.Disabled,
textarea.Disabled,
select.Disabled + span.select2-container .select2-selection, /* select2 */
.Disabled input:not([type='submit']):not([type='button']):not([type='reset']):not(.Enabled),
.Disabled select:not(.Enabled),
.Disabled textarea:not(.Enabled),
.Disabled select:not(.Enabled) + span.select2-container .select2-selection /* select2 */ {
    pointer-events: none;
    background-color: whitesmoke;
}

    select.Disabled + span.select2-container .select2-selection__clear,
    select.Disabled + span.select2-container .select2-selection__choice__remove,
    .Disabled select + span.select2-container .select2-selection__clear,
    .Disabled select + span.select2-container .select2-selection__choice__remove {
        display: none;
    }

input[type='submit'].Disabled,
input[type='button'].Disabled,
input[type='reset'].Disabled,
button.Disabled,
.Disabled input[type='submit']:not(.Enabled),
.Disabled input[type='button']:not(.Enabled),
.Disabled input[type='reset']:not(.Enabled),
.Disabled button:not(.Enabled) {
    pointer-events: none;
    opacity: 0.5; /* 淡化顏色 */
}

.Disabled input[type='checkbox']:not(.Enabled) + label,
.Disabled input[type='radio']:not(.Enabled) + label {
    pointer-events: none;
    opacity: 0.5; /* 淡化顏色 */
}

.Disabled .nav-tabs:not(.Enabled) .nav-link {
    color: gray;
    pointer-events: none;
}

.Disabled label:not(.Enabled) {
    pointer-events: none;
}



.EditButtons.Browse .AfterModify,
.EditButtons.Modify .BeforeModify,
.EditButtons.NoData .CheckExists {
    pointer-events: none;
    opacity: 0.5; /* 淡化顏色 */
}

.EditForm.Browse input:not([type='submit']):not([type='button']):not(.Exception),
.EditForm.Browse select:not(.Exception),
.EditForm.Browse textarea:not(.Exception),
.EditForm.Browse select:not(.Exception) + span.select2-container .select2-selection /* select2 */ {
    pointer-events: none;
    background-color: whitesmoke;
}

.EditForm.Browse input[type='submit']:not(.Exception),
.EditForm.Browse input[type='button']:not(.Exception),
.EditForm.Browse button:not(.Exception) {
    pointer-events: none;
    opacity: 0.5; /* 淡化顏色 */
}

.EditForm.Browse:not(.Inverted) .nav-tabs .nav-link {
    color: gray;
    pointer-events: none;
}

.EditForm.Browse label:not(.Exception) {
    pointer-events: none;
}

.EditForm.Modify.Inverted .nav-tabs .nav-link {
    color: gray;
    pointer-events: none;
}

ul.List {
    display: inline-block;
    margin: 0;
    padding-left: 0;
}

.List li {
    display: inline-block;
    list-style: none;
    white-space: nowrap;
    margin-right: 5px;
}

.List.Vertical li {
    display: block !important;
}

ul.TreeView {
    margin: 0;
    padding-left: 0;
}

.TreeView ul {
    padding-left: 14pt;
}

.TreeView li {
    list-style: none;
}

.ui-timepicker-viewport .ui-menu-item {
    text-align: left;
}


.MainMenu .active {
    color: #fff !important;
}

.MainMenu a {
    color: #000 !important;
}

.SideMenu {
    left: auto;
    right: 0;
    min-width: auto;
}

.PageTitle {
    background-color: rgba(240,240,240);
    border-top: 1px solid rgba(0,0,0,.125);
    border-bottom: 1px solid rgba(0,0,0,.125);
}

.PageTitle h5 {
    font-weight: bold;
    margin: 0.7rem 1rem;
}



/* jQuery dialog 的關閉視窗圖示被 Bootstrap 弄掉！補回來 */
.ui-dialog-titlebar-close {
    background-image: url("../lib/jquery.ui/images/ui-icons_444444_256x240.png");
    background-position: -96px -128px;
}

/* === 表單 Form  === */
.form-content-block {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 2rem;
}
.form-content-block.recent-detail{
    padding:0 2rem 1rem 0;
}

.iex-question-card {
    background: #fff;
    border: 1px solid #dfe9df;
    border-radius: 20px;
    padding: 22px;
}

.iex-question-no {
    color: #2d7a55;
    font-weight: 700;
    font-size: 0.95rem;
}

.iex-question-text {
    color: #1f2a22;
    font-size: 1.05rem;
    line-height: 1.8;
    margin-top: 8px;
}

.iex-timer-panel {
    min-width: 176px;
    padding: 16px 18px;
    border-radius: 20px;
    background: linear-gradient(135deg, #ebf7ef 0%, #dcefe2 100%);
    border: 1px solid #c7dfcf;
    position: fixed;
    top: calc(var(--header-h, 120px) + 16px);
    right: 24px;
    z-index: var(--z-scroll);
    box-shadow: 0 8px 24px rgba(30, 73, 52, 0.12);
}

.iex-timer-label {
    color: #557062;
    font-size: 0.95rem;
}

.iex-timer-value {
    color: #1f5138;
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.1;
    margin-top: 6px;
}

.iex-option-list {
    display: grid;
    gap: 10px;
    margin-top: 18px;
}

.iex-option {
    display: flex;
    gap: 12px;
    align-items: center;
    padding: 14px 16px;
    border: 1px solid #dbe6dd;
    border-radius: 16px;
    background: #fbfdfb;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.iex-option:hover {
    border-color: #8db29a;
    box-shadow: 0 8px 18px rgba(45, 122, 85, 0.08);
    transform: translateY(-1px);
}

.iex-option-index {
    width: 28px;
    height: 28px;
    border-radius: 999px;
    background: #e5f2e9;
    color: #1f5138;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: none;
}

.iex-option-text {
    color: #314237;
    line-height: 1.7;
}

.iex-option.is-selected {
    border-color: #2d7a55;
    background: #edf7f0;
}

.iex-option-list.is-readonly .iex-option:hover {
    transform: none;
    box-shadow: none;
}

@media (max-width: 991.98px) {
    .iex-timer-panel {
        position: static;
        right: auto;
        top: auto;
        z-index: auto;
        box-shadow: none;
    }
}

@media (max-width: 767.98px) {
    .iex-timer-panel {
        width: 100%;
    }
}

.form-section-block {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 2rem;
    border-top: 1px solid #e2eef1;
    border-bottom: 1px solid #e2eef1;
}

.form-date-range {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.form-seminar-section {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    border-top: 1px solid #e2eef1;
    border-bottom: 1px solid #e2eef1;
    background-color: #fbfdfc;
    padding: 2rem;
}

.sat-admin-section {
    gap: 0.35rem;
    padding-top: 1.5rem;
    padding-bottom: 1.5rem;
}

.sat-score-row {
    display: grid;
    grid-template-columns: minmax(180px, 24%) minmax(0, 1fr);
    align-items: center;
    column-gap: 1.25rem;
    min-height: 58px;
    padding: 0.45rem 0;
    border-bottom: 1px solid #e8eeee;
}

.sat-score-row > label {
    margin: 0;
}

.sat-score-options {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    align-items: center;
    gap: 0.35rem;
}

.sat-score-options-short {
    grid-template-columns: repeat(2, minmax(120px, 180px));
}

.sat-score-options-status {
    grid-template-columns: repeat(3, minmax(120px, 180px));
}

.sat-score-options .btn {
    margin: 0 !important;
    width: 100%;
}

.sat-field-label {
    font-weight: 700;
}

.sat-choice-label {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 54px;
    padding: 0.65rem 1rem;
    border: 1px solid #c7dfcf;
    border-radius: 999px;
    background: #fbfdfb;
    color: #1f5138;
    font-weight: 700;
    text-align: center;
    transition: border-color 0.2s ease, background-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.sat-choice-label:hover {
    border-color: #8db29a;
    background: #edf7f0;
    color: #1f5138;
    box-shadow: 0 6px 14px rgba(45, 122, 85, 0.1);
}

.sat-choice-label-sm {
    min-height: 42px;
    padding: 0.45rem 0.75rem;
}

.btn-check:checked + .sat-choice-label {
    border-color: #226b5c;
    background-image: linear-gradient(135deg, #23837a 0%, #226b5c 100%);
    background-color: transparent;
    color: #fff;
    box-shadow: 0 6px 16px -6px rgba(34, 107, 92, 0.4);
}

.sat-admin-section .sat-score-row:last-child {
    border-bottom: 0;
}

@media (max-width: 767.98px) {
    .sat-score-row {
        grid-template-columns: 1fr;
        row-gap: 0.45rem;
        min-height: auto;
    }

    .sat-score-options,
    .sat-score-options-short,
    .sat-score-options-status {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .sat-score-options-status {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

.form-hint {
    color: #294a41;
    font-size: small;
    margin-left: 0.6rem;
}

.form-wrap {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.form-options {
    min-height: calc(1.5em + 0.75rem + 2px);
    display: flex;
    flex-direction: row;
    justify-content: center;
    gap: 2.5rem;
}

.form-option {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    margin: 0;
}

.paper-options {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.45fr) minmax(0, 1fr);
    justify-content: stretch;
    gap: 0.5rem 2rem;
    text-align: left;
}

.paper-options .form-option {
    align-items: flex-start;
}

.discount-options {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    gap: 0.5rem;
    text-align: left;
}

.discount-options .form-option {
    align-items: flex-start;
}

@media (max-width: 768px) {
    .paper-options {
        grid-template-columns: 1fr;
    }
}

.form-buttons-wrap {
    text-align: center;
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 2rem;
}

.qst-section-label {
    font-size: 1.05rem;
    font-weight: 700;
    color: #2a4a42 !important;
}

.qst-teacher-table {
    width: 100%;
    min-width: 1000px;
    table-layout: fixed;
    border-collapse: collapse;
}

.qst-teacher-table th,
.qst-teacher-table td {
    vertical-align: middle;
}

.qst-teacher-table thead th {
    background-color: #247f70 !important;
    border: 1px solid #fff !important;
    color: #fff;
    font-weight: 700;
    text-align: center !important;
    white-space: nowrap;
}

.qst-teacher-course-column {
    width: 25.5%;
}

.qst-teacher-speaker-column {
    width: 9%;
}

.qst-teacher-score-column {
    width: 5.5%;
}

.qst-teacher-table thead tr:nth-child(2) th:first-child::before {
    content: none !important;
    display: none;
}

.qst-teacher-table thead th:nth-child(1),
.qst-teacher-table tbody td:nth-child(1) {
    white-space: nowrap;
}

.qst-teacher-table thead th:nth-child(2),
.qst-teacher-table tbody td:nth-child(2) {
    white-space: nowrap;
}

.qst-teacher-table thead th:nth-child(n + 3),
.qst-teacher-table tbody td:nth-child(n + 3) {
    text-align: center;
}

.qst-teacher-table tbody tr:nth-child(even) {
    background-color: #f8f8f1;
}

.qst-teacher-table tbody tr:nth-child(odd) {
    background-color: #fff;
}

.qst-teacher-table tbody td {
    border-color: #e5e7eb;
}

.form .qst-teacher-table tbody td:nth-child(n + 3) input.form-control {
    width: 52px;
    margin: 0 auto;
    padding: 0;
    text-align: center;
}

.qst-teacher-table.table thead th:first-child {
    padding: 1rem 0.5rem;
}

.result-note {
    background: linear-gradient(135deg, rgba(212, 169, 74, 0.06), rgba(212, 169, 74, 0.02));
    border: 1px solid rgba(212, 169, 74, 0.28);
    border-left: 3px solid var(--gold, #d4a94a);
    border-radius: 12px;
    padding: 1rem 1.25rem;
    font-size: 0.8125rem;
    color: var(--text-muted, #6f7772);
    line-height: 1.9;
}

.result-note strong {
    color: var(--text, #374037);
    font-weight: 700;
}

.form-fields-520 .row > .col:first-child {
    flex: 0 0 520px;
    max-width: 520px;
}

.form-fields-520 .row > .col:last-child {
    flex: 1 1 auto;
}

.form-fields-captcha .captcha-row {
    margin-bottom: 0;
    max-width: 520px;
}

.per-info-fields .form-control[readonly] {
    background-color: #f8faf9;
}

.up-pw-note {
    margin-top: 0.5rem;
}

.up-pw-note-list {
    list-style: none;
    margin: 0.35rem 0 0;
    padding: 0;
    color: #c62828;
    line-height: 1.8;
}

.up-pw-note-list li {
    margin: 0;
}

@media (max-width: 767.98px) {
    .form-fields-520 .row > .col:first-child {
        flex: 1 1 100%;
        max-width: 100%;
    }
}

/* === Shared Detail Helpers === */
.detail-date-range-wrap {
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 0.5rem;
}

.detail-count-inline {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.detail-count-input {
    max-width: 120px;
}

.detail-inline-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: nowrap;
}

.detail-inline-btn {
    white-space: nowrap;
}

.detail-inline-check {
    margin: 0;
    white-space: nowrap;
}

.detail-option-list-wrap {
    min-height: auto;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 0.75rem 1.5rem;
}

.detail-option-group + .detail-option-group {
    margin-top: 1rem;
}

.detail-col-stack {
    display: flex;
    flex-direction: column;
}

.detail-image-preview {
    max-width: 480px;
    max-height: 250px;
    display: block;
    margin-top: 8px;
}

.detail-file-input {
    width: 100%;
    background: #fff;
    border: 1px solid #ced4da;
    border-radius: 0.375rem;
    padding: 0.375rem 0.75rem;
}

.detail-file-input::file-selector-button {
    font-size: 0.8438rem;
    font-weight: 500;
    color: var(--green-deep);
    letter-spacing: 0.04em;
    border-color: rgba(45, 138, 118, 0.25);
    border-radius: 50px;
    background: rgb(255, 255, 255);
    padding: 0.45rem 1rem;
    margin-right: 0.625rem;
    cursor: pointer;
    transition: 0.22s;
}

.detail-file-input:hover::file-selector-button {
    color: var(--green-deep);
    border-color: var(--green);
    background: var(--green-pale);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px -4px rgba(45, 138, 118, 0.2);
}

/* === Shared Layout Styles (moved from _Layout.cshtml) === */
.top-menu {
    text-align: right;
}

.crumb {
    justify-content: space-evenly;
}

main {
    flex: 1 1 auto;
}

main.main-wrap {
    max-width: 1320px;
    margin: 0 auto;
    padding: 4rem 2.5rem;
}

.footer-nav-label:not(.menu-level-1) {
    font-size: 0.9375rem;
    color: var(--text-muted, #6b7f78);
    font-weight: inherit;
    border-bottom: none;
    margin-bottom: 0;
    padding: 4px 0;
}

.footer-nav-label:not(.menu-level-1) ~ ul li a {
    padding: 4px 10px;
}

.footer-nav-label:not(.menu-level-1) ~ ul li a:hover {
    padding-left: 8px;
}

.EditForm > .row {
    margin-bottom: 0.75rem;
}

.table {
    width: 100%;
    border-collapse: collapse;
}

.table thead tr {
    background: linear-gradient(90deg,#0D5647 0%,#1A774F 100%);
}

.table thead th {
    color: #fff;
    background-color: transparent;
    font-size: 1rem !important;
    font-weight: 600;
    letter-spacing: 0.08em;
    padding: 1rem 0.5rem !important;
    text-align: left;
    vertical-align: middle;
    border: none;
    white-space: nowrap;
}

.table thead th:first-child {
    border-radius: 0;
    padding-left: 1.5rem !important;
    position: relative;
}

.table thead th:first-child::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: var(--gold);
}

    .table thead th input[type=radio] {
        accent-color: var(--gold);
    }

    .table thead th input[type="checkbox"] {
        appearance: none;
        width: 15px;
        height: 15px;
        border: 1px solid var(--gold);
        font-size: 0.8rem;
        /*border-radius: 4px;*/
        cursor: pointer;
    }

        .table thead th input[type="checkbox"]:checked {
            background: var(--gold);
            border-color: var(--gold);
            position: relative;
        }

            .table thead th input[type="checkbox"]:checked::after {
                content: "✓";
                color: #FFFFFF;
                font-weight: bold;
                line-height: 12px;
                text-align: center;
                display: block;
            }

.table tbody tr:nth-child(odd),
.table > tbody > tr:nth-child(odd) > td,
.table > tbody > tr:nth-child(odd) > th {
    background: #fff;
}

.table tbody tr:nth-child(even),
.table > tbody > tr:nth-child(even) > td,
.table > tbody > tr:nth-child(even) > th {
    background: rgba(212,169,74,0.04);
}

.table tbody tr {
    border-bottom: 1px solid rgba(212,169,74,0.12);
    transition: background .15s,transform .15s;
}

.table tbody tr:last-child {
    border-bottom: none;
}

.table tbody tr:hover {
    background: linear-gradient(90deg,rgba(212,169,74,0.08),rgba(212,169,74,0.03));
    transform: translateX(2px);
}

table tbody th {
    font-weight: normal;
    vertical-align: middle;
}

.table td {
    padding: 1rem 0.5rem;
    font-size: 1rem !important;
    color: var(--text);
    vertical-align: middle;
}

.table td:first-child {
    padding-left: 1.5rem;
    position: relative;
}

.table td:first-child::before {
    content: "";
    position: absolute;
    left: 0;
    top: 25%;
    bottom: 25%;
    width: 3px;
    background: var(--gold);
    border-radius: 2px;
    opacity: 0;
    transition: opacity .2s;
}

.table tbody tr:hover td:first-child::before {
    opacity: 1;
}

.table td.text-right, .table td.number {
    padding-right: 1.25rem;
    text-align: right !important;
}

.table a {
    color: var(--green-deep);
}

.table .btn {
    padding: 0.375rem 0.875rem !important;
    margin-right: 5px;
    margin-bottom: 5px;
}

.table .btn-download {
    white-space: nowrap;
    color: var(--gold);
}

.table .btn-edit,
.table .btn-delete,
.table .btn-search {
    display: inline-block;
    border-radius: 0.375rem;
    padding: 0.2rem 0.4rem !important;
}

/* DataTables 樣式表（datatables.datatables.min.css）由 TagHelper 注入，
   載入順序在 site.css 之後，以下選擇器以較高權重覆蓋其預設值 */
.table.dataTable > tbody > tr > td {
    padding: 1rem 0.5rem;
}

/* 維持 .table td:first-child 的左側留白 */
.table.dataTable > tbody > tr > td:first-child {
    padding-left: 1.5rem;
}

/* 可排序欄位的上下箭頭，改為白色半透明 */
.table.dataTable thead > tr > th.dt-orderable-asc span.dt-column-order::before,
.table.dataTable thead > tr > th.dt-ordering-asc span.dt-column-order::before,
.table.dataTable thead > tr > th.dt-orderable-desc span.dt-column-order::after,
.table.dataTable thead > tr > th.dt-ordering-desc span.dt-column-order::after {
    opacity: 0.35;
    color: #fff;
}

/* 目前排序方向的箭頭以金色全亮標示（升冪亮 ▲、降冪亮 ▼） */
.table.dataTable thead > tr > th.dt-ordering-asc span.dt-column-order::before,
.table.dataTable thead > tr > th.dt-ordering-desc span.dt-column-order::after {
    opacity: 1;
    color: var(--gold);
}

.modal-overlay {
    display: none;
}

.modal-overlay.open {
    display: flex;
}

.form {
    position: relative;
    padding: 2rem;
    box-shadow: 0 4px 24px -8px rgba(45, 138, 118, 0.08);
    border: solid 1px #e5f0f2;
    background-color: #fff;
    border-top: none;
    border-top-left-radius: 5px;
    border-top-right-radius: 5px;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.form::before {
    content: '';
    width: 100%;
    height: 3px;
    background-image: linear-gradient(to right, #226b5c, #34c1ce 50%, #e8cb7e);
    position: absolute;
    top: 0;
    left: 0;
    border-top-left-radius: 3px;
    border-top-right-radius: 3px;
}

.title {
    position: relative;
    padding-left: 20px;
    font-weight: bold;
    font-size: 1.2rem;
    color: #226b5c;
}

.title::before {
    content: '';
    position: absolute;
    left: 0px;
    top: 5px;
    display: block;
    width: 4px;
    height: 22px;
    border-radius: 2px;
    background-image: linear-gradient(to bottom, #2d8a76, #34c1ce);
}

.sub-title {
    font-weight: bold;
    color: #226b5c;
}

.form .row label {
    font-weight: bold;
    color: #2a4a42;
}

.form input:not([type='submit']):not([type='button']):not(.Exception),
.form select:not(.Exception),
.form textarea:not(.Exception),
.form select:not(.Exception) + span.select2-container .select2-selection {
    padding: 0.5rem 1rem;
    border-radius: 10px;
    border: solid 1px #d0e5e8;
    background-color: #fff;
}

.form input[type='text'].hour, .form input[type='text'].minute {
    width: 70px !important;
}

.form input[type='text']::placeholder {
    color: #6b897f;
}

.form hr {
    margin: 2rem 0;
    border-top: #e5f0f2 solid 1px;
    opacity: 1;
}

.form .btn {
    padding: 0.6875rem 2.5rem !important;
}

.form .btn-sm {
    min-height: 30px;
    padding: 0.25rem 0.75rem !important;
    font-size: 0.75rem;
}

fieldset {
    width: 100%;
    margin-top: 20px;
    margin-bottom: 20px;
    padding: 20px 30px;
    border-radius: 18px;
    box-shadow: 0 2px 12px -6px rgba(34, 107, 92, 0.08);
    border: solid 1px #d0e5e8;
    background-color: #fff;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

fieldset legend {
    display: none;
}

    fieldset .row {
        gap: 0.5rem;
    }

    fieldset .col {
        display: flex;
        align-items: center;
        flex-wrap: wrap;
        flex: 0 1 auto;
        /*width: auto;*/
    }

    fieldset .row:last-child .col {
        width: auto;
    }

    fieldset .row:last-child .col:last-child {
        flex: 1 1 auto;
    }

fieldset .col-form-label {
    font-weight: bold;
    color: #2a4a42;
    white-space: nowrap;
    flex: 0 0 100px;
    margin-right: 20px;
    text-align: right;
}

    fieldset input:not([type='submit']):not([type='button']):not(.Exception),
    fieldset select:not(.Exception),
    fieldset textarea:not(.Exception),
    fieldset select:not(.Exception) + span.select2-container .select2-selection {
        padding: 0.5rem 1rem;
        border-radius: 10px;
        border: solid 1px #d0e5e8;
        background-color: #fff;
    }

fieldset .bottom-wrap {
    flex: 1 1 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

    fieldset .button-wrap {
        display: flex;
        align-items: center;
        /*justify-content: flex-end;*/
        gap: 0.5rem;
        flex-wrap: wrap;
    }

fieldset input[type='text'].hour, fieldset input[type='text'].minute {
    width: 60px !important;
}

fieldset input[type='text']::placeholder {
    color: #6b897f;
}

fieldset .btn, fieldset .btn-download {
    margin-left: 0.5rem !important;
    padding: 0.6875rem 2.5rem !important;
}

    fieldset .btn.btn-dot {
        padding: 0.6875rem 1rem !important;
    }

    @media(max-width:768px) {
        .crumb {
        justify-content: flex-start;
    }

    .form .row {
        flex-direction: column;
        margin-bottom: 0 !important;
    }

    .form .row > div {
        margin-bottom: 1rem !important;
    }

    fieldset .col {
        flex-direction: column;
        align-items: flex-start;
    }

    fieldset .col-form-label {
        white-space: nowrap;
        flex: 0 1 auto;
        margin-right: 0px;
        text-align: left;
    }

    fieldset .bottom-wrap {
        width: 100%;
        margin: 0;
        gap: 0.5rem;
        flex-wrap: wrap;
    }
}

/* === Voucher shared qi hero/button styles === */
.qi-hero {
    position: relative;
    overflow: hidden;
    z-index: 0;
    isolation: isolate;
    padding: 4.5rem 0 5rem;
    min-height: 500px;
    background:
        radial-gradient(ellipse 55% 35% at 84% 10%, rgba(26, 155, 173, 0.16) 0%, transparent 65%),
        radial-gradient(ellipse 45% 32% at 10% 80%, rgba(212, 169, 74, 0.12) 0%, transparent 65%),
        radial-gradient(ellipse 35% 28% at 52% 50%, rgba(34, 107, 92, 0.08) 0%, transparent 65%),
        radial-gradient(ellipse 28% 22% at 6% 16%, rgba(52, 193, 206, 0.10) 0%, transparent 65%),
        linear-gradient(180deg, #dff2ed 0%, #e8f6f2 35%, #f1f9f7 70%, #f6fbfa 100%);
}

.qi-orbs {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 1;
    overflow: hidden;
}

.qi-orb {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
}

.qi-orb-a {
    width: min(480px, 60%);
    height: min(480px, 60%);
    top: 2%;
    right: 4%;
    background: radial-gradient(circle, rgba(26, 155, 173, 0.42) 0%, transparent 65%);
    filter: blur(52px);
    animation: qiOrbA 14s ease-in-out infinite;
}

.qi-orb-b {
    width: min(380px, 50%);
    height: min(380px, 50%);
    bottom: 4%;
    left: 3%;
    background: radial-gradient(circle, rgba(212, 169, 74, 0.32) 0%, transparent 65%);
    filter: blur(44px);
    animation: qiOrbB 18s ease-in-out infinite;
}

.qi-orb-c {
    width: min(300px, 42%);
    height: min(300px, 42%);
    top: 38%;
    left: 32%;
    background: radial-gradient(circle, rgba(34, 107, 92, 0.26) 0%, transparent 65%);
    filter: blur(48px);
    animation: qiOrbC 22s ease-in-out infinite;
}

@keyframes qiOrbA {
    0%,
    100% {
        transform: translate(0, 0);
    }

    33% {
        transform: translate(-28px, 22px);
    }

    66% {
        transform: translate(18px, -26px);
    }
}

@keyframes qiOrbB {
    0%,
    100% {
        transform: translate(0, 0);
    }

    40% {
        transform: translate(24px, -20px);
    }

    70% {
        transform: translate(-18px, 28px);
    }
}

@keyframes qiOrbC {
    0%,
    100% {
        transform: translate(0, 0);
    }

    30% {
        transform: translate(20px, 24px);
    }

    65% {
        transform: translate(-24px, -18px);
    }
}

.qi-hero-inner {
    max-width: 1320px;
    margin: 0 auto;
    padding-top: 0;
    padding-bottom: 0;
    padding-left: 2.5rem;
    padding-right: 2.5rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 2;
}

.qi-eyebrow {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.6562rem;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--green-deep);
    margin-bottom: 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.625rem;
    font-weight: 600;
}

.qi-eyebrow::before {
    content: "";
    width: 24px;
    height: 1px;
    background: var(--gold);
}

.qi-title {
    font-family: 'Noto Serif TC', serif;
    font-weight: 700;
    font-size: 3.375rem;
    line-height: 1.1;
    letter-spacing: 0.02em;
    color: var(--ink);
    margin-bottom: 0.5rem;
}

.qi-title .accent {
    color: var(--green-deep);
    display: block;
    width: fit-content;
    position: relative;
}

.qi-title .accent::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -4px;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--gold) 0%, var(--gold-soft) 60%, transparent 100%);
}

.qi-desc {
    font-size: 0.9062rem;
    line-height: 1.95;
    color: var(--text-muted);
    max-width: 400px;
    margin: 1.5rem 0 2rem;
}

.qi-desc strong {
    color: var(--green-deep);
    font-weight: 600;
}

.qi-note {
    display: inline-flex;
    align-items: center;
    gap: 0.625rem;
    background: linear-gradient(135deg, #C99A3A 0%, var(--gold) 100%);
    border: none;
    border-radius: 10px;
    padding: 0.75rem 1.125rem;
    font-size: 0.8125rem;
    color: #fff;
    line-height: 1.7;
    box-shadow: 0 4px 14px -4px rgba(212, 169, 74, 0.45);
}

.qi-note img {
    width: 14px;
    height: 14px;
    display: block;
    object-fit: contain;
    flex-shrink: 0;
    margin-top: 0.125rem;
    filter: brightness(0) invert(1);
}

.qi-right {
    display: flex;
    flex-direction: column;
    gap: 0.875rem;
    position: relative;
}

.qi-right::before {
    content: none;
}

.qi-btn {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    padding: 1.25rem 1.5rem;
    border: 0;
    border-radius: 16px;
    width: 100%;
    text-align: left;
    text-decoration: none;
    cursor: pointer;
    transition: transform .28s cubic-bezier(.22,.68,0,1.1),box-shadow .28s;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.qi-btn::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(105deg,transparent 35%,rgba(255,255,255,0.14) 50%,transparent 65%);
    transform: translateX(-120%);
    transition: transform .55s ease;
    pointer-events: none;
}

.qi-btn:hover::before {
    transform: translateX(120%);
}

.qi-btn::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
    opacity: .4;
    border-radius: 16px;
}

.qi-btn-1 {
    background: linear-gradient(135deg,#0A6B7A 0%,#1A9BAD 100%);
    color: #fff;
    box-shadow: 0 6px 24px -6px rgba(10,107,122,0.5),inset 0 1px 0 rgba(255,255,255,0.15);
}

.qi-btn-1:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 36px -8px rgba(10,107,122,0.42),inset 0 1px 0 rgba(255,255,255,0.15);
}

.qi-btn-1 .qi-btn-accent {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1.5px;
    background: linear-gradient(90deg,transparent,var(--gold-soft) 30%,var(--gold) 50%,var(--gold-soft) 70%,transparent);
}

.qi-btn-1 .qi-btn-bar {
    position: absolute;
    left: 0;
    top: 18%;
    bottom: 18%;
    width: 2.5px;
    border-radius: 2px;
    background: linear-gradient(180deg,rgba(255,255,255,0.9),rgba(255,255,255,0.4));
    transform: scaleY(0);
    transform-origin: center;
    transition: transform .28s ease;
}

.qi-btn-1:hover .qi-btn-bar {
    transform: scaleY(1);
}

.qi-btn-1-glow {
    position: absolute;
    right: -30px;
    bottom: -30px;
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: radial-gradient(circle,rgba(255,255,255,0.14) 0%,transparent 70%);
    pointer-events: none;
}

.qi-btn-2 {
    background: #fff;
    border: 1px solid rgba(45,138,118,0.16);
    color: var(--ink);
    box-shadow: 0 2px 10px -4px rgba(15,46,39,0.08),inset 0 1px 0 rgba(255,255,255,0.9);
}

.qi-btn-2:hover {
    border-color: rgba(45,138,118,0.36);
    transform: translateY(-3px);
    box-shadow: 0 12px 28px -8px rgba(45,138,118,0.2),inset 0 1px 0 rgba(255,255,255,0.9);
}

.qi-btn-2-bar {
    position: absolute;
    left: 0;
    top: 20%;
    bottom: 20%;
    width: 2px;
    border-radius: 2px;
    background: linear-gradient(180deg,var(--green-soft),var(--green));
    transform: scaleY(0);
    transform-origin: center;
    transition: transform .28s ease;
}

.qi-btn-2:hover .qi-btn-2-bar {
    transform: scaleY(1);
}

.qi-btn-3 {
    background: linear-gradient(135deg,var(--ink) 0%,#2A4A40 100%);
    color: #fff;
    box-shadow: 0 6px 24px -6px rgba(15,46,39,0.45),inset 0 1px 0 rgba(255,255,255,0.08);
}

.qi-btn-3:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 36px -8px rgba(15,46,39,0.38),inset 0 1px 0 rgba(255,255,255,0.08);
}

.qi-btn-3 .qi-btn-bar {
    position: absolute;
    left: 0;
    top: 18%;
    bottom: 18%;
    width: 2.5px;
    border-radius: 2px;
    background: linear-gradient(180deg,var(--teal),var(--green-soft));
    transform: scaleY(0);
    transform-origin: center;
    transition: transform .28s ease;
}

.qi-btn-3:hover .qi-btn-bar {
    transform: scaleY(1);
}

.qi-btn-3-glow {
    position: absolute;
    right: -40px;
    top: -40px;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: radial-gradient(circle,rgba(52,193,206,0.18) 0%,transparent 70%);
    pointer-events: none;
}

.qi-btn-icon {
    width: 50px;
    height: 50px;
    border-radius: 13px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    transition: transform .25s;
}

.qi-btn:hover .qi-btn-icon {
    transform: scale(1.06);
}

.qi-btn-1 .qi-btn-icon {
    background: rgba(255,255,255,0.18);
    border: 1px solid rgba(255,255,255,0.2);
}

.qi-btn-2 .qi-btn-icon {
    background: linear-gradient(135deg,var(--green-deep),var(--green));
    color: #fff;
    box-shadow: 0 4px 12px -4px rgba(34,107,92,0.4);
}

.qi-btn-3 .qi-btn-icon {
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.12);
}

.qi-btn-icon svg {
    width: 22px;
    height: 22px;
    stroke-width: 1.6;
}

.qi-btn-icon img {
    width: 22px;
    height: 22px;
    display: block;
    object-fit: contain;
}

.qi-btn-text {
    flex: 1;
}

.qi-btn-title {
    font-family: 'Noto Sans TC',sans-serif;
    font-weight: 700;
    font-size: 1.062rem;
    letter-spacing: 0.03em;
    line-height: 1.2;
}

.qi-btn-tag {
    font-family: 'JetBrains Mono',monospace;
    font-size: 0.5625rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    margin-top: 0.3125rem;
}

.qi-btn-title--green {
    color: var(--green-deep);
}

.qi-btn-tag--muted {
    color: var(--text-muted);
}

.qi-btn-tag--dim {
    opacity: 0.5;
}

.qi-btn-arrow {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform .25s,background .25s;
}

.qi-btn-1 .qi-btn-arrow {
    background: rgba(255,255,255,0.14);
    border: 1px solid rgba(255,255,255,0.2);
}

.qi-btn-2 .qi-btn-arrow {
    background: rgba(34,107,92,0.07);
    border: 1px solid rgba(34,107,92,0.14);
}

.qi-btn-3 .qi-btn-arrow {
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.12);
}

.qi-btn-arrow--soft {
    background: rgba(45, 138, 118, 0.08);
}

.qi-btn-arrow-icon--green {
    color: var(--green);
}

.qi-btn-arrow svg {
    width: 14px;
    height: 14px;
    transition: transform .25s;
}

.qi-btn:hover .qi-btn-arrow {
    transform: scale(1.1);
}

.qi-btn:hover .qi-btn-arrow svg {
    transform: translateX(2px);
}

.lq-date-range {
    display: flex;
    align-items: center;
    gap: 10px;
}

@media(max-width:960px) {
    .qi-hero-inner {
        grid-template-columns: 1fr;
        gap: 2.25rem;
        padding: 0 1.25rem;
    }

    .qi-title {
        font-size: 2.25rem;
    }

    .qi-hero {
        z-index: 0;
        padding: 3rem 0 3.5rem;
        min-height: auto;
    }

    .qi-right::before {
        inset: -16px -18px;
    }

    .qi-right {
        max-width: 100%;
    }

    .qi-btn {
        padding: 1rem 1.125rem;
    }
}

@media(max-width:40rem) {
    .qi-hero-inner {
        padding-left: 1.125rem;
        padding-right: 1.125rem;
    }
}

@media only screen and (max-width: 768px) {
    main.main-wrap {
        padding: 2rem 1.5rem;
    }

    .footer {
        padding-top: 0;
    }

    .table {
        background-color: transparent !important;
    }

        .table,
        .table thead,
        .table tbody,
        .table th,
        .table td,
        .table tr,
        .table caption {
            display: block;
        }

            .table thead th {
                display: none;
            }

            .table thead tr {
                position: absolute;
                top: -9999px;
                left: -9999px;
            }

            .table tr {
                border: 1px solid #ccc;
                margin-bottom: 15px;
                background-color: #ffffff;
            }

            .table tbody tr:nth-child(even):hover {
                background: rgba(212,169,74,0.04);
                transform: none;
            }

            .table tbody tr:nth-child(odd):hover {
                background: none;
                transform: none;
            }

            .table tbody td, .table tbody th {
                border: none !important;
                border-bottom: 1px solid #eee !important;
                position: relative;
                padding-left: calc(30% + 1rem) !important;
                white-space: normal;
                text-align: left !important;
                min-height: 60px;
            }

                .table tbody td::after, .table tbody th::after {
                    content: attr(data-th);
                    position: absolute;
                    top: 0px;
                    left: 0px;
                    width: 30%;
                    white-space: nowrap;
                    text-align: left;
                    font-weight: bold;
                    background: linear-gradient(90deg, var(--green-deep) 0%, #2D8A76 100%);
                    color: #fff;
                    height: 100%;
                    padding: 1rem 0.5rem;
                }

            .table td:first-child::before {
                display: none;
            }

            .table td.text-right, .table td.number {
                padding-right: 2.5rem;
            }

    .form-content-block {
        padding: 0;
    }
}

.modal-footer {
    justify-content: center;
}

.sat-course-card {
    padding: 1.5rem;
    border-radius: 16px;
}

.sat-course-score-list {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}