html {
    width: 100%;
    height: 100%;
    overflow-x: hidden;
    font-size: 16px;
}

body {
    background-color: #fff;
    color: #000;
    width: 100%;
    min-height: 100%;
    -ms-overflow-style: scrollbar;
    margin: 0;
    font-family: "Noto Sans", "Microsoft JhengHei", "Helvetica Neue", Helvetica,
        Arial, sans-serif;
}

h3,
h4,
h5,
h6 {
    font-family: "Microsoft JhengHei", "Source Sans Pro", "Helvetica Neue",
        Helvetica, Arial, sans-serif;
}

h3,
h4 {
    font-weight: normal;
}

h3 {
    font-size: 21px;
}

h4 {
    font-size: 18px;
}

.btn-link:hover {
    text-decoration: none;
}

a,
.text-link {
    color: #007bff;
    text-decoration: none;
}

@media all and (max-width: 768px) {
    .form-group .input-group {
        margin-bottom: 15px !important;
    }
}

@media all and (max-width: 1025px) {
    /*
	body{font-size:13px;}
	form{font-size:13px;}
	*/
}

/*
ol {
	margin: 12px 0 12px 27px;
	padding: 0;
}
*/

li {
    margin: 0;
    padding: 0;
}

.pointer {
    cursor: pointer;
}

.btn-rounded {
    overflow: hidden;
}

.btn-submit {
    cursor: pointer;
}

.form-group {
    margin-bottom: 12px;
}

.right input {
    text-align: right;
}

img {
    max-width: 100%;
}

h1 {
    color: #000;
    font-size: 28px;
    font-family: "Microsoft YaHei", Arial, Helvetica, sans-serif;
    line-height: 130%;
    margin: 0 0 15px 0;
}

.main {
    min-height: 300px;
}

.main h1 {
    margin: 15px 0;
}

h1 .label {
    font-family: "Microsoft JhengHei", Arial, Helvetica, sans-serif;
}

h2 {
    font-size: 20px;
    font-family: "Microsoft JhengHei", Arial, Helvetica, sans-serif;
    font-weight: bold;
}

/* bootstrap hack */

.lead {
    font-weight: inherit;
}

.btn {
    font-size: inherit;
}

.control-label {
    white-space: nowrap;
    padding-top: 7px;
}

.form-control,
.form-select {
    border-color: #aaa;
}

/* card-box */

.card-box {
    border-color: #ddd;
}

.btn-link {
    color: #09f;
}

@media all and (max-width: 768px) {
    .card-box {
        border: none;
        padding: 0;
    }
}

/*
.card-box h4 {
    margin: 0;
    margin-bottom: 20px;
    line-height: 130%;
    padding: 0 2px 7px 2px;
    border-bottom: #f1f1f1 solid 1px;
}
*/

/* no-gutters Class Rules */

.row.gutter-3 {
    margin-right: -3px;
    margin-left: -3px;
}

.row.gutter-3>[class^="col-"],
.row.gutter-3>[class*=" col-"] {
    padding-right: 3px;
    padding-left: 3px;
}

.row.no-gutters {
    margin-right: 0;
    margin-left: 0;
}

.row.no-gutters>[class*="col-"] {
    padding-right: 0;
    padding-left: 0;
}

/* end bootstrap */

/* login-page */
@media all and (max-width: 768px) {
    body.login-body {
        /*
    background: #cbecff;
    */
        background: #e9f5fb;
    }
}

.login-page {
    width: 950px;
    margin: 30px auto;
    text-align: center;
    line-height: 140%;
}

.yts-login-box {
    background-position: 50% 0%;
    background-repeat: no-repeat;
    width: 950px;
    height: 467px;
    margin: 20px auto;
    padding: 20px 0;
    text-align: left;
}

.yts-login-title {
    color: #609;
    font-size: 19px;
    line-height: 29px;
    text-align: left;
    margin-left: 450px;
}

.yts-login-form {
    margin: 0;
    padding: 0 150px 0 450px;
}

.wrapper {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
    min-height: 100%;
    min-height: 500px;
    background: #fff;
}

@media all and (max-width: 800px) {
    .wrapper {
        padding: 0 20px;
    }
}

@media all and (max-width: 480px) {
    .wrapper {
        padding: 0 15px;
    }
}

.logo {
    margin: 5px 5px;
    padding: 0;
    line-height: 1;
}

.logo img {
    max-width: 140px;
}

/* top-right */

.top-right {}

.top-right ul {
    margin: 10px 0;
    padding: 0;
    display: table;
    width: auto;
    float: right;
}

.top-right li {
    margin: 0 10px;
    padding: 0;
    float: left;
    list-style: none;
    font-size: 16px;
}

.top-right li a {
    color: #333;
}

/* topmenu */

.topmenu {}

.topmenu ul {
    margin: 0;
    padding: 0;
}

.topmenu li {
    float: left;
    list-style: none;
    margin: 0;
    padding: 0;
    box-sizing: content-box;
    width: 16.6667%;
    font-size: 16px;
    text-align: center;
    border-top: solid 3px;
    border-bottom: solid 3px;
}

.topmenu li a {
    color: #000;
    height: 34px;
    line-height: 34px;
    display: block;
}

.topmenu li a:hover {
    background: #f6f6f6;
}

.topmenu li a.current {
    background: #f6f6f6;
    font-weight: bold;
}

.topmenu li.border-red {
    border-top-color: #f30;
    border-bottom-color: #f30;
}

.topmenu li.border-orange {
    border-top-color: #f60;
    border-bottom-color: #f60;
}

.topmenu li.border-yellow {
    border-top-color: #fc3;
    border-bottom-color: #fc3;
}

.topmenu li.border-green {
    border-top-color: #090;
    border-bottom-color: #090;
}

.topmenu li.border-apple-green {
    border-top-color: #81c868;
    border-bottom-color: #81c868;
}

.topmenu li.border-sky-blue {
    border-top-color: #24d2f7;
    border-bottom-color: #24d2f7;
}

.topmenu li.border-blue {
    border-top-color: #09f;
    border-bottom-color: #09f;
}

.topmenu li.border-indigo {
    border-top-color: #0e00db;
    border-bottom-color: #0e00db;
}

.topmenu li.border-purple {
    border-top-color: #90c;
    border-bottom-color: #90c;
}

.topmenu li.border-pink {
    border-top-color: #f69;
    border-bottom-color: #f69;
}

/* left-submenu */

#left-submenu {
    margin: 0;
    padding: 0;
}

#left-submenu ul {
    margin: 0;
    padding: 0;
}

#left-submenu li {
    margin: 0;
    padding: 10px;
    border-bottom: #ddd solid 1px;
    list-style: none;
}

#left-submenu li.last {
    border: none;
}

#left-submenu a {
    color: #333;
    display: block;
}

/*  */

.theme-heading {
    background: url(../images/theme-bg.jpg);
    height: 45px;
    line-height: 45px;
    font-size: 21px;
    color: #fff;
    margin-bottom: 15px;
    padding-left: 25px;
    padding-right: 25px;
    font-family: "Microsoft JhengHei", "Microsoft YaHei", Arial, Helvetica,
        sans-serif;
    text-shadow: rgba(0, 0, 0, 0.9) 1px 1px 1px;
    letter-spacing: 1px;
    font-weight: bold;
}

@media all and (max-width: 768px) {
    .theme-heading {
        margin-left: -15px;
        margin-right: -15px;
    }
}

@media all and (max-width: 768px) {
    .table-xs {
        margin-left: -15px;
        margin-right: -15px;
        width: calc(100% + 30px) !important;
        max-width: calc(100% + 30px) !important;
    }
}

.table-narrow th,
.table-narrow td {
    padding: 4px 4px !important;
}

.nowrap {
    white-space: nowrap !important;
}

/* leftmenu  */

.left-submenu-h3 {
    font-size: 16px;
    font-weight: bold;
    padding: 10px;
    margin: 0;
    border-bottom: #ccc solid 1px;
    color: #639 !important;
}

.left-submenu-h3 a {
    color: #639 !important;
}

.shop-leftmenu {
    margin: 0 5px;
}

.shop-leftmenu a {
    display: block;
}

.shop-leftmenu-submenu-group {
    padding-bottom: 15px;
    display: none;
}

.shop-leftmenu-submenu-name {
    border-bottom: #aaa dotted 1px;
    padding: 4px 1px;
}

/* topmenu */

.submenu {
    margin-top: -20px;
}

.submenu ul {
    margin: 0;
    padding: 0;
}

.submenu li {
    margin: 0 !important;
    padding: 0;
    list-style: none;
    width: 16.666%;
    display: block;
    float: left;
}

.submenu li .btn {
    border-radius: 0;
}

/* footer */

#footer {
    text-align: center;
    margin: 90px 0 0 0;
    padding-top: 12px;
    padding-bottom: 30px;
    line-height: 140%;
    border-top: #ccc solid 1px;
    clear: both;
}

/* */

sup.required {
    color: #f30;
    margin-left: 3px;
    margin-right: -7px;
}

#fixth {
    background: #fff;
}

#studstats-thead th {
    padding-top: 2px;
    padding-bottom: 2px;
}

.int {
    text-align: right;
}

.int-warning {
    position: absolute;
    top: -15px;
    left: -5px;
    z-index: 9;
    display: none;
    font-size: 13px;
    font-family: Arial, "新細明體", Helvetica, sans-serif;
}

.notebox {
    background: #f6f6f6;
    padding: 10px 15px;
    border: #ccc dashed 1px;
}

.preview-title {
    color: #aaa;
    font-size: 21px;
    letter-spacing: 5px;
    font-family: "Microsoft YaHei", Tahoma, Geneva, sans-serif;
    font-weight: 100;
}

.a4-paper-width {
    width: 21cm;
}

.a4-paper {
    width: 22cm;
    height: 29.7cm;
    background: #fff;
    box-shadow: rgba(0, 0, 0, 0.2) 5px 5px 5px;
    margin: 80px auto;
    padding: 1cm 0;
    border: #999 solid 1px;
    box-sizing: border-box;
    position: relative;
}

.remove-list {
    color: #999;
    cursor: pointer;
}

.remove-list:hover {
    color: #f00;
}

.remove-list:active {
    color: #900;
}

.black-cover,
.black-cover-lock {
    background: #000;
    position: fixed;
    z-index: 100;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    display: none;
}

/* bootstrap */

.table th {
    white-space: nowrap;
}

.table-align-middle th,
.table-align-middle td {
    vertical-align: middle;
}

#management-area {
    margin: 50px 0 30px 0;
    clear: both;
}

.sign-table {
    border-bottom: #999 solid 1px !important;
    border-left: #999 solid 1px !important;
}

.sign-table th,
.sign-table td {
    border-top: #999 solid 1px !important;
    border-right: #999 solid 1px !important;
    text-align: center;
}

#dont-f5 {
    position: fixed;
    z-index: 1001;
    top: 35%;
    left: 50%;
    margin-left: -300px;
    clear: both;
    width: 600px;
    height: 100px;
    text-align: left;
    color: #fff;
    font-weight: bold;
    display: none;
    text-shadow: rgba(0, 0, 0, 1) 1px 1px 2px;
}

#thxbox {
    position: fixed;
    top: 45%;
    left: 50%;
    width: 500px;
    margin-left: -250px;
    margin-top: -100px;
    height: 250px;
    background: #fff;
    z-index: 9999;
    border-radius: 12px;
    box-shadow: #000 0 0 15px;
    line-height: 150%;
}

#topbar {
    position: fixed;
    z-index: 99;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.8);
    padding: 10px;
    box-shadow: #999 0 0 5px;
}

.topbar-wrapper {
    width: 21cm;
    margin: 0 auto;
    position: relative;
}

.iframe-full {
    width: 100%;
    height: 100%;
    border: none;
    padding: 0;
    margin: 0;
}

#report h1 {
    font-size: 24px;
}

/* text align for bootstrap 5 */
.text-left {
    text-align: left !important;
}

.text-right {
    text-align: right !important;
}

/* colors */

.text-yamaha {
    color: #462a6e !important;
}

.text-orange {
    color: #f60 !important;
}

a.text-orange:hover {
    color: #f30 !important;
}

.text-black {
    color: #000;
}

.text-pf {
    color: #9e692c !important;
}

.text-pop {
    color: #80c1c1 !important;
}

.text-comfrey {
    color: #38214a !important;
}

.bg-comfrey {
    background-color: #38214a !important;
}

.text-violet {
    color: #a51f5e !important;
}

.bg-violet {
    background-color: #a51f5e !important;
}

.bg-purple {
    background-color: #7266ba !important;
}

.bg-f1f1f1 {
    background: #f1f1f1;
}

.bg-eee {
    background: #eee;
}

.bg-ddd {
    background: #ddd;
}

.bg-pf {
    background: #9e692c !important;
}

.bg-pop {
    background: #80c1c1;
}

.bg-light.active {
    background-color: #eee !important;
}

/* 回bootstrap預設 */

.text-primary {
    color: #007bff !important;
}

a.text-primary:focus,
a.text-primary:hover {
    color: #0056b3 !important;
}

.mobile-menu {
    font-size: 24px;
}

.remove {
    cursor: pointer;
}

.remove:hover {
    color: #f00;
}

/* mmenu */

.mm-listview>li>a,
.mm-listview>li>span {
    padding: 15px;
}

/* fancybox rsn add*/

.fancybox-html-box {
    width: 800px;
    max-width: 800px;
}

/* rsn-modal */

.rsn-modal {
    position: fixed;
    z-index: 101;
    width: 400px;
    min-height: 100px;
    top: 45%;
    left: 0;
    right: 0;
    display: table;
    margin-left: auto;
    margin-right: auto;
    margin-top: -50px;
    max-width: calc(100% - 30px);
}

.line-150 td {
    line-height: 150% !important;
}

.line-180 td {
    line-height: 180% !important;
}

/* font-size */

.font-12 {
    font-size: 12px;
}

.font18,
.font-18 {
    font-size: 18px;
}

.font21,
.font-21 {
    font-size: 24px;
}

.font24,
.font-24 {
    font-size: 24px;
}

.font28,
.font-28 {
    font-size: 28px;
}

/** custom btn **/

/* btn-outline-pop */

.btn-outline-pop {
    color: #80c1c1;
    border-color: #80c1c1;
}

.btn-outline-pop:hover {
    color: #fff;
    background-color: #80c1c1;
    border-color: #80c1c1;
}

.btn-outline-pop.focus,
.btn-outline-pop:focus {
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.5);
}

.btn-outline-pop.disabled,
.btn-outline-pop:disabled {
    color: #80c1c1;
    background-color: transparent;
}

.btn-outline-pop:not(:disabled):not(.disabled).active,
.btn-outline-pop:not(:disabled):not(.disabled):active,
.show>.btn-outline-pop.dropdown-toggle {
    color: #fff;
    background-color: #80c1c1;
    border-color: #80c1c1;
}

.btn-outline-pop:not(:disabled):not(.disabled).active:focus,
.btn-outline-pop:not(:disabled):not(.disabled):active:focus,
.show>.btn-outline-pop.dropdown-toggle:focus {
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.5);
}

/* btn-outline-pf */

.btn-outline-pf {
    color: #9e692c;
    border-color: #9e692c;
}

.btn-outline-pf:hover {
    color: #fff;
    background-color: #9e692c;
    border-color: #9e692c;
}

.btn-outline-pf.focus,
.btn-outline-pf:focus {
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.5);
}

.btn-outline-pf.disabled,
.btn-outline-pf:disabled {
    color: #9e692c;
    background-color: transparent;
}

.btn-outline-pf:not(:disabled):not(.disabled).active,
.btn-outline-pf:not(:disabled):not(.disabled):active,
.show>.btn-outline-pf.dropdown-toggle {
    color: #fff;
    background-color: #9e692c;
    border-color: #9e692c;
}

.btn-outline-pf:not(:disabled):not(.disabled).active:focus,
.btn-outline-pf:not(:disabled):not(.disabled):active:focus,
.show>.btn-outline-pf.dropdown-toggle:focus {
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.5);
}

a:hover .mini-stat {
    box-shadow: rgba(0, 0, 0, 0.3) 0 0 2px;
}

@media all and (max-width: 768px) {
    a:hover .mini-stat {
        box-shadow: none;
    }
}

.widget-bg-color-icon .bg-icon-pf {
    background-color: rgba(158, 105, 44, 0.2);
    border: 1px solid #9e692c;
}

.widget-bg-color-icon .bg-icon-pop {
    background-color: rgba(128, 193, 193, 0.2);
    border: 1px solid #80c1c1;
}

/* dataTable */

table.dataTable thead .sorting::after,
table.dataTable thead .sorting_asc::after,
table.dataTable thead .sorting_desc::after {
    top: auto;
    bottom: 4px;
}

/*======================= SCROLL TO TOP =======================*/

#back-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 999;
    display: none;
}

#back-top a {
    width: 50px;
    height: 50px;
    line-height: 47px;
    display: block;
    text-align: center;
    font-size: 14px;
    font-family: Arial, Helvetica, sans-serif;
    text-transform: none;
    text-decoration: none;
    color: #464646;
    border-radius: 50%;
    border: 3px solid #e3e3e3;
    background: #fff;
    font-weight: bold;
    /* transition */
    -webkit-transition: 0.2s;
    -moz-transition: 0.2s;
    transition: 0.2s;
}

#back-top a:hover {
    border: 3px solid #464646;
}

a.hover-shadow:hover {
    display: block;
    margin-top: -1px;
    margin-bottom: 1px;
    box-shadow: rgba(0, 0, 0, 0.2) 0 1px 5px !important;
}

/* form-check 共通放大與邊框強化 */
.form-check {
    cursor: pointer;
}

.form-check-input {
    width: 1.2rem;
    height: 1.2rem;
    border: 1px solid #495057;
    cursor: pointer;
}

input[type="checkbox"].form-check-input {
    border-radius: 0% !important;
}

input[type="radio"].form-check-input {
    border-radius: 50% !important;
}

.form-check-label {
    font-size: 1rem;
    cursor: pointer;
    padding-left: .3rem;
    font-weight: normal;
    line-height: 1.2rem;
}

/* 避免 Bootstrap 內建 hover/active 把你覆蓋掉 */
.form-check-success .form-check-input:checked {
    background-color: #198754;
    border-color: #198754;
}

.form-check-danger .form-check-input:checked {
    background-color: #dc3545;
    border-color: #dc3545;
}

.form-check-primary .form-check-input:checked {
    background-color: #0d6efd;
    border-color: #0d6efd;
}

.form-check-warning .form-check-input:checked {
    background-color: #ffc107;
    border-color: #ffc107;
}

.form-check-info .form-check-input:checked {
    background-color: #0dcaf0;
    border-color: #0dcaf0;
}

.form-check-secondary .form-check-input:checked {
    background-color: #6c757d;
    border-color: #6c757d;
}

.form-check-dark .form-check-input:checked {
    background-color: #212529;
    border-color: #212529;
}

/* 得分特效 */
.floating-score {
    position: absolute;
    z-index: 9999;
    font-weight: bold;
    font-size: 1.1rem;
    pointer-events: none;
    animation: floatUp 900ms ease-out forwards;
    will-change: transform, opacity;
    white-space: nowrap;
    transform-origin: left center;
}

.floating-plus {
    color: #28a745;
}

/* 綠：加分 */
.floating-minus {
    color: #dc3545;
}

@keyframes floatUp {
    0% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }

    100% {
        opacity: 0;
        transform: translateY(-28px) scale(1);
    }
}

.score-hud {
    position: fixed;
    right: 16px;
    bottom: 16px;
    z-index: 1050;
    /* 高於一般內容，低於 modal */
    background: rgba(33, 37, 41, 0.92);
    /* 深色半透明 */
    color: #fff;
    padding: 10px 14px;
    border-radius: 14px;
    font-weight: 700;
    line-height: 1.2;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25);
    user-select: none;
}

.score-hud .score-label {
    opacity: .85;
    font-weight: 500;
    margin-right: 6px;
}

.score-hud .score-value {
    font-variant-numeric: tabular-nums;
}

/* bump 動畫 */
.score-hud {
    transition: transform 0.18s ease;
}

.score-hud.is-bump {
    transform: scale(1.06);
}

/* 表格轉置 */
.transpose-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    display: block;
    /* <- 保證可見 */
    width: 100%;
    /* <- 佔滿行，避免被壓縮到 0 寬 */
}

.transpose-wrap>.table {
    margin-bottom: 0;
    /* 視覺更緊湊 */
}

/* 只影響轉置表（你原本的 is-transposed 規則保留） */
.table.is-transposed {
    table-layout: fixed;
    /*
    border-collapse: separate;
    */
    border-spacing: 0;
}

.table.is-transposed thead th {
    text-align: center !important;
}

.table.is-transposed> :not(caption)>*>* {
    padding: .35rem .5rem;
    white-space: normal;
    word-break: break-word;
    overflow-wrap: anywhere;
}

.table.is-transposed thead th {
    position: sticky;
    top: 0;
    z-index: 2;
    background: var(--bs-body-bg, #fff);
}

.table.is-transposed th[scope="row"] {
    position: sticky;
    left: 0;
    z-index: 1;
    background: var(--bs-body-bg, #fff);
    box-shadow: 1px 0 0 0 rgba(0, 0, 0, .05);
}

.table.is-transposed tbody tr:nth-child(even) th,
.table.is-transposed tbody tr:nth-child(even) td {
    background-color: rgba(0, 0, 0, .04);
}

.table.is-transposed th,
.table.is-transposed td {
    border-color: #e9ecef;
}