*{
	margin: 0;
	padding: 0;
	box-sizing: border-box;
	font-family: 'Poppins', sans-serif;
}

html,body{
	width: 100%;
	height: 100%;
}

.indexbody{
    width: 100%;
	height: 100%;
    background-image: url(img/img_1.jpg);
    background-repeat: no-repeat;
    background-position: center;
    background-size: cover;
}

.top{
    width: 100%;
    height: 238px;
    padding: 40px 50px 0 50px;
}

.imgbox{
    float: right;
    width: 595px;
    height: 198px;
    background-image: url(img/img_logo.png);
    background-repeat: no-repeat;
    background-position: center;
}

.center{
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    width: 100%;
    height: calc(100% - 358px);
    padding: 5% 50px 50px 50px;
}

.box{
    flex: 1;
    height: 100%;
    margin: 0 10px;
    background: #c2c2c2af;
    border-radius: 15px;
    border: 2px solid #424242;
}

.box:first-child {
    margin-left: 0;
}

.box:last-child {
    margin-right: 0;
    border: 2px solid transparent;
    background: transparent;
}

.boxtop{
    width: 100%;
    height: 40px;
    color: #e0e0e0;
    background-color: #424242;
    font-size: 16px;
    font-weight: 600;
    line-height: 40px;
    padding: 0 10px;
    border-radius: 10px 10px 0 0;
}

.boxbody{
    width: 100%;
    height: calc(100% - 65px);
    padding: 10px;
    border-radius: 0 0 10px 10px;
    overflow-y: auto;
}

.box:first-child .boxbody {
    height: calc(100% - 45px);
}

.boxbuttom{
    width: 100%;
    height: 25px;
    padding: 0 10px;
    font-size: 15px;
    line-height: 25px;
}

.buttom {
    width: 100%;
    min-height: 120px;
    height: auto;

    padding: 10px 10px;

    background: #242424e1;

    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;

    color: #fff;

    border-top: 1px solid #555;
}

/* 上方分隔線 */
.buttom-line {
    width: 90%;
    height: 1px;

    background-color: #555;

    margin-bottom: 12px;
}

/* Copyright */
.buttom-copyright {
    font-size: 14px;
    color: #ffffff;

    margin-bottom: 6px;
}

/* 連結 */
.buttom-links {
    display: flex;
    justify-content: center;
    align-items: center;

    gap: 8px;

    font-size: 12px;

    margin-bottom: 6px;
}

.buttom-links a {
    color: #aaa;

    text-decoration: none;

    transition: 0.3s;
}

.buttom-links a:hover {
    color: #ffffff;
}

.buttom-links span {
    color: #555;
}

/* 權利聲明 */
.buttom-notice {
    width: 90%;
    max-width: 900px;

    text-align: center;

    font-size: 11px;
    line-height: 1.5;

    color: #777;
}

.boxbody_box_1{
    width: 100%;
    height: 30px;
    font-size: 15px;
    border-bottom: 1px solid #ffffff;
    line-height: 30px;
    margin-top: 15px;
}

.boxbody_box_1:first-child{
    margin-top: 0;
}

.boxbody_box_1_left{
    float: left;
}

.boxbody_box_1_right{
    float: right;
}

.boxbody_box_2{
    width: 100%;
    padding: 5px 0;
    font-size: 15px;
    box-sizing: border-box;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.boxbody_box_3{
    width: 100%;
    text-align: right;
}

.score-link {
    color: #000000;
    text-decoration: none;
    cursor: pointer;
}

.score-link:hover {
    color: #007bff;
    text-decoration: underline;
}


/* ================================
   Button
   ================================ */

.button {
    width: 100%;
    height: 100px;
    margin-bottom: 20px;

    border: none;
    border-radius: 0;

    overflow: hidden;

    display: flex;
    align-items: center;
    justify-content: center;

    background: transparent;
    cursor: pointer;

    appearance: none;
    -webkit-appearance: none;
}

.button img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

/* 滑鼠移入時不改變外觀 */
.button:hover {
    background: transparent;
    border: none;
}

/* 點擊時不顯示背景 */
.button:active {
    background: transparent;
}

/* 移除瀏覽器預設的焦點外框 */
.button:focus {
    outline: none;
}


/* =========================================================
   平板
   寬度：769px ~ 1024px
   ========================================================= */

@media screen and (min-width: 769px) and (max-width: 1024px) {

    html,
    body {
        width: 100%;
        height: auto;
        min-height: 100%;
    }

    .indexbody {
        width: 100%;
        min-height: 100vh;
        height: auto;
    }

    .top {
        width: 100%;
        height: 180px;
        padding: 25px 25px 0 25px;
    }

    .imgbox {
        float: none;
        width: 100%;
        height: 150px;
        background-size: contain;
    }

    .center {
        display: flex;
        flex-direction: column;
        flex-wrap: nowrap;

        width: 100%;
        height: auto;

        padding: 20px 20px 20px 20px;

        gap: 20px;
    }

    .box {
        width: 100%;

        flex: 0 0 350px;

        margin: 0;

        border-radius: 15px;
    }

    .box:first-child,
    .box:last-child {
        margin: 0;
    }

    .boxbody {
        height: calc(100% - 65px);
    }

    .box:first-child .boxbody {
        height: calc(100% - 45px);
    }

    .buttom {
        width: 100%;
        height: 100px;
    }

}


/* =========================================================
   手機
   寬度：768px 以下
   ========================================================= */

@media screen and (max-width: 768px) {

    html,
    body {
        width: 100%;
        height: auto;
        min-height: 100%;
    }

    .indexbody {
        width: 100%;
        min-height: 100vh;
        height: auto;
    }

    .top {
        width: 100%;
        height: 150px;
        padding: 20px 15px 0 15px;
    }

    .imgbox {
        float: none;
        width: 100%;
        height: 120px;

        background-size: contain;
        background-position: center;
    }

    .center {
        display: flex;
        flex-direction: column;
        flex-wrap: nowrap;

        width: 100%;
        height: auto;

        padding: 15px 15px 15px 15px;

        gap: 15px;
    }

    .box {
        width: 100%;

        flex: 0 0 300px;

        margin: 0;

        border-radius: 15px;
    }

    .box:first-child,
    .box:last-child {
        margin: 0;
    }

    .boxbody {
        height: calc(100% - 65px);
    }

    .box:first-child .boxbody {
        height: calc(100% - 45px);
    }

    .buttom {
        width: 100%;
        height: 80px;
    }

}

/* =========================================================
   Live Results
   ========================================================= */

.live-home-event-name{
    width: 100%;
    padding: 5px 5px 12px 5px;

    color: #222222;

    font-size: 15px;
    font-weight: 600;

    line-height: 1.5;

    border-bottom: 1px solid rgba(255,255,255,0.8);

    overflow-wrap: anywhere;
    word-break: break-word;
}


.live-home-group-list{
    width: 100%;

    padding-top: 10px;
}


.live-home-group-button{
    width: 100%;
    min-height: 48px;

    margin-bottom: 10px;
    padding: 8px 12px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    border: 1px solid #777777;
    border-radius: 8px;

    background: rgba(255,255,255,0.55);

    color: #222222;

    text-decoration: none;

    transition:
        background-color 0.2s ease,
        border-color 0.2s ease,
        transform 0.15s ease,
        box-shadow 0.2s ease;
}


.live-home-group-button:hover{

    background: rgba(255,255,255,0.9);

    border-color: #424242;

    box-shadow:
        0 3px 8px rgba(0,0,0,0.15);

    transform: translateY(-1px);
}


.live-home-group-button:active{

    transform: translateY(0);

    box-shadow:
        0 1px 3px rgba(0,0,0,0.12);
}


.live-home-group-name{
    
    flex: 1;

    font-size: 14px;
    line-height: 1.4;

    overflow-wrap: anywhere;
    word-break: break-word;
}


.live-home-empty{

    width: 100%;

    padding: 30px 10px;

    text-align: center;

    color: #777777;

    font-size: 14px;
}

/* =========================================================
   羚揚欣業首頁：統一企業視覺風格
   與 events.php 共用底圖、半透明面板及灰白色系
   放置於 index.css 最末端
   ========================================================= */


/* ================================
   1. 首頁背景
   ================================ */

.indexbody {
    min-height: 100vh;
    height: auto;

    background-image:
        linear-gradient(
            rgba(15, 15, 15, 0.38),
            rgba(15, 15, 15, 0.55)
        ),
        url("img/img_1.jpg");

    background-repeat: no-repeat;
    background-position: center center;
    background-size: cover;
    background-attachment: fixed;
}


/* ================================
   2. 主要資訊面板
   ================================ */

.box {
    background: rgba(25, 25, 25, 0.52);

    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 15px;

    backdrop-filter: blur(7px);
    -webkit-backdrop-filter: blur(7px);

    overflow: hidden;

    transition:
        background-color 0.25s ease,
        border-color 0.25s ease;
}

/* 保留右側功能圖示區原本的透明外觀 */
.box:last-child {
    background: transparent;
    border-color: transparent;

    backdrop-filter: none;
    -webkit-backdrop-filter: none;

    overflow: visible;
}


/* ================================
   3. 區塊標題
   ================================ */

.boxtop {
    color: #ffffff;

    background: rgba(15, 15, 15, 0.72);

    border-bottom: 1px solid rgba(255, 255, 255, 0.20);

    letter-spacing: 0.4px;
}


/* ================================
   4. 區塊內容
   ================================ */

.boxbody {
    color: rgba(255, 255, 255, 0.90);
}

.boxbody_box_1 {
    color: rgba(255, 255, 255, 0.88);

    border-bottom:
        1px solid rgba(255, 255, 255, 0.22);
}

.boxbody_box_2 {
    color: rgba(255, 255, 255, 0.92);

    line-height: 1.7;
}

.boxbody_box_3 {
    color: rgba(255, 255, 255, 0.88);
}


/* 日期、消息分類及其他一般文字 */
.boxbody_box_1_left,
.boxbody_box_1_right {
    color: inherit;
}


/* ================================
   5. 連結
   ================================ */

.score-link {
    color: #ffffff;

    text-decoration: none;

    transition:
        color 0.2s ease,
        opacity 0.2s ease;
}

.score-link:hover {
    color: #d4d4d4;
    text-decoration: underline;
}


/* More 連結 */
.boxbuttom {
    color: rgba(255, 255, 255, 0.88);
}

.boxbuttom .score-link {
    color: rgba(255, 255, 255, 0.88);
}

.boxbuttom .score-link:hover {
    color: #ffffff;
}


/* ================================
   6. 內容捲動條
   ================================ */

.boxbody::-webkit-scrollbar {
    width: 6px;
}

.boxbody::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.025);
    border-radius: 10px;
}

.boxbody::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.28);
    border-radius: 10px;
}

.boxbody::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.48);
}


/* ================================
   7. 即時成績區
   ================================ */

.live-home-event-name {
    color: #ffffff;

    border-bottom:
        1px solid rgba(255, 255, 255, 0.25);
}

.live-home-group-button {
    color: #ffffff;

    background: rgba(255, 255, 255, 0.09);

    border: 1px solid rgba(255, 255, 255, 0.24);
    border-radius: 8px;

    box-shadow: none;
}

.live-home-group-button:hover {
    color: #ffffff;

    background: rgba(255, 255, 255, 0.17);

    border-color: rgba(255, 255, 255, 0.48);

    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.12);

    transform: translateY(-1px);
}

.live-home-group-button:active {
    background: rgba(255, 255, 255, 0.12);

    box-shadow: none;
    transform: translateY(0);
}

.live-home-empty {
    color: rgba(255, 255, 255, 0.65);
}


/* ================================
   8. 頁尾
   ================================ */

.buttom {
    background: rgba(15, 15, 15, 0.66);

    border-top:
        1px solid rgba(255, 255, 255, 0.18);

    backdrop-filter: blur(7px);
    -webkit-backdrop-filter: blur(7px);
}

.buttom-line {
    background: rgba(255, 255, 255, 0.24);
}

.buttom-copyright {
    color: rgba(255, 255, 255, 0.90);
}

.buttom-links a {
    color: rgba(255, 255, 255, 0.65);
}

.buttom-links a:hover {
    color: #ffffff;
}

.buttom-links span {
    color: rgba(255, 255, 255, 0.30);
}

.buttom-notice {
    color: rgba(255, 255, 255, 0.48);
}


/* ================================
   9. 平板及手機背景
   ================================ */

@media screen and (max-width: 1024px) {

    .indexbody {
        background-attachment: scroll;
    }

}


/* ================================
   10. 手機字體與間距微調
   ================================ */

@media screen and (max-width: 768px) {

    .box {
        border-radius: 13px;
    }

    .boxtop {
        border-radius: 10px 10px 0 0;
    }

    .boxbody_box_1 {
        font-size: 14px;
    }

    .boxbody_box_2 {
        font-size: 14px;
        line-height: 1.7;
    }

}

/* ========================================
   電腦版：讓首頁頁尾貼齊視窗底部
   ======================================== */

@media screen and (min-width: 1025px) {

    html,
    body {
        width: 100%;
        min-height: 100%;
        height: 100%;
    }

    .indexbody {
        width: 100%;
        min-height: 100vh;
        height: auto;

        display: flex;
        flex-direction: column;
    }

    .top {
        flex: 0 0 238px;
    }

    .center {
        flex: 1 0 auto;
        height: auto;
    }

    .buttom {
        width: 100%;
        margin-top: auto;
        flex-shrink: 0;
    }

}



/* =========================================================
   電腦版：五大區塊等高、各自垂直捲動
   ========================================================= */

@media screen and (min-width: 1025px) {

    .center {
        display: flex;
        flex-direction: row;
        flex-wrap: nowrap;
        align-items: stretch;

        flex: 1 1 auto;
        min-height: 350px;
        height: auto;

        padding: 170px 50px 50px;
        gap: 20px;
    }

    /* 五個區塊全部等高 */
    .center > .box {
        flex: 1 1 0;
        min-width: 0;
        min-height: 0;
        height: auto;

        margin: 0;

        display: flex;
        flex-direction: column;

        overflow: hidden;
    }

    /* 五個區塊的標題列固定高度 */
    .center > .box > .boxtop {
        flex: 0 0 40px;
        height: 40px;
        min-height: 40px;
    }

    /* 五個區塊的內容區都能獨立垂直捲動 */
    .center > .box > .boxbody {
        flex: 1 1 0;
        min-height: 0;
        height: auto;

        overflow-x: hidden;
        overflow-y: auto;

        scrollbar-width: thin;
        scrollbar-color:
            rgba(255, 255, 255, 0.38)
            rgba(255, 255, 255, 0.04);
    }

    /* 第 2、3、4 區塊的 More 固定在底部 */
    .center > .box:nth-child(2) > .boxbuttom,
    .center > .box:nth-child(3) > .boxbuttom,
    .center > .box:nth-child(4) > .boxbuttom {
        flex: 0 0 25px;
        height: 25px;
    }

    /* 第五區圖示按鈕間距 */
    .center > .box:last-child > .button {
        flex-shrink: 0;
    }

}


/* =========================================================
   五大區塊：精緻垂直捲動條
   ========================================================= */

/* Chrome、Edge、Safari */
.center > .box > .boxbody::-webkit-scrollbar {
    width: 7px;
}

.center > .box > .boxbody::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.035);
    border-radius: 10px;
}

.center > .box > .boxbody::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.30);
    border: 1px solid rgba(30, 30, 30, 0.35);
    border-radius: 10px;
}

.center > .box > .boxbody::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.58);
}

.center > .box > .boxbody::-webkit-scrollbar-thumb:active {
    background: rgba(255, 255, 255, 0.72);
}

/* ========================================
   第五區：功能按鈕不顯示捲動條
   ======================================== */

@media screen and (min-width: 1025px) {

    .center > .box:last-child {
        overflow: visible;
        background: transparent;
        border-color: transparent;
    }

    .center > .box:last-child .boxbody {
        overflow: visible;
    }

}

/* 隱藏第五區的捲動條 */
.center > .box:last-child .boxbody::-webkit-scrollbar {
    display: none;
}

.center > .box:last-child .boxbody {
    scrollbar-width: none;
}

/* ========================================
   第一區：最新消息分類顏色
   ======================================== */

/* 共用設定 */
.center > .box:first-child .boxbody_box_1_left {
    display: inline-block;

    padding: 0 9px;

    color: #ffffff;
    font-size: 13px;
    font-weight: 600;

    line-height: 23px;

    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.28);
}

/* 羚揚消息：銀灰色 */
.center > .box:first-child
.boxbody_box_1_left.msg-company {
    background: rgba(145, 145, 145, 0.42);
}

/* 成績消息：低調藍灰色 */
.center > .box:first-child
.boxbody_box_1_left.msg-result {
    background: rgba(74, 134, 187, 0.62);
}

/* 賽場消息：沉穩橄欖綠 */
.center > .box:first-child
.boxbody_box_1_left.msg-event {
    background: rgba(86, 168, 80, 0.62);
}

.registration-expired {
    color: #b94a48;
    font-weight: 600;
    white-space: nowrap;
}


/* =========================================================
   Copyright Lightbox
   ========================================================= */

/* 背景遮罩：預設隱藏 */

.copyright-lightbox {

    position: fixed;

    inset: 0;

    width: 100%;
    height: 100%;

    display: flex;
    justify-content: center;
    align-items: center;

    padding: 20px;

    background: rgba(0, 0, 0, 0.68);

    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);

    z-index: 9999;

    opacity: 0;
    visibility: hidden;

    transition:
        opacity 0.25s ease,
        visibility 0.25s ease;

}

/* 顯示 */

.copyright-lightbox.active {

    opacity: 1;
    visibility: visible;

}

/* 燈箱主體 */

.copyright-lightbox-content {

    width: 100%;
    max-width: 600px;

    max-height: 80vh;

    background: rgba(245, 245, 245, 0.97);

    border: 1px solid rgba(255, 255, 255, 0.8);

    border-radius: 12px;

    overflow: hidden;

    box-shadow:
        0 15px 45px rgba(0, 0, 0, 0.35);

    transform: translateY(15px);

    transition: transform 0.25s ease;

}

/* 開啟動畫 */

.copyright-lightbox.active
.copyright-lightbox-content {

    transform: translateY(0);

}

/* 標題列 */

.copyright-lightbox-header {

    height: 55px;

    padding: 0 20px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    color: #ffffff;

    background: #424242;

    font-size: 17px;
    font-weight: 600;

    letter-spacing: 1px;

}

/* 關閉按鈕 */

.copyright-close {

    width: 32px;
    height: 32px;

    border: none;

    background: transparent;

    color: #ffffff;

    font-size: 28px;
    line-height: 1;

    cursor: pointer;

    transition: color 0.2s ease;

}

.copyright-close:hover {

    color: #c8c8c8;

}

/* 內容區 */

.copyright-lightbox-body {

    padding: 25px 28px;

    max-height: calc(80vh - 55px);

    overflow-y: auto;

    color: #444444;

    font-size: 14px;
    line-height: 1.9;

}

/* 小標題 */

.copyright-lightbox-body h3 {

    margin-bottom: 18px;

    color: #333333;

    font-size: 16px;
    font-weight: 600;

}

/* 段落 */

.copyright-lightbox-body p {

    margin-bottom: 15px;

    text-align: justify;

}

/* 底部版權 */

.copyright-lightbox-footer {

    margin-top: 25px;
    padding-top: 15px;

    border-top: 1px solid #dddddd;

    color: #888888;

    font-size: 12px;

    text-align: center;

}

/* 手機版 */

@media screen and (max-width: 768px) {

    .copyright-lightbox {

        padding: 15px;

    }

    .copyright-lightbox-content {

        max-width: 100%;
        max-height: 85vh;

    }

    .copyright-lightbox-body {

        padding: 20px;

        max-height: calc(85vh - 55px);

        font-size: 13px;

    }

}

/* =========================================================
   Contact Lightbox
   ========================================================= */

.contact-content {
    width: 100%;
    text-align: center;
}

.contact-content h3 {
    margin-top: 0;
    margin-bottom: 10px;
}

.contact-content > p {
    margin-bottom: 16px;
    text-align: center;
    line-height: 1.6;
}

/* =========================================================
   Contact Form
   ========================================================= */

.contact-form-group {
    display: flex;
    flex-direction: column;
    margin-bottom: 16px;
}

.contact-form-group label {
    margin-bottom: 7px;
    font-size: 15px;
    font-weight: 600;
}

.contact-form-group input,
.contact-form-group textarea {
    width: 100%;
    box-sizing: border-box;
    padding: 11px 13px;
    border: 1px solid #ccc;
    border-radius: 7px;
    background: #fff;
    color: #333;
    font-family: inherit;
    font-size: 15px;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.contact-form-group input:focus,
.contact-form-group textarea:focus {
    border-color: #8c8c8c;
    box-shadow: 0 0 0 3px rgba(120, 120, 120, 0.12);
}

.contact-form-group textarea {
    resize: vertical;
    min-height: 130px;
}

.contact-form-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 18px;
}

.contact-submit-button {
    min-width: 130px;
    padding: 11px 25px;
    border: none;
    border-radius: 7px;
    background: #777;
    color: #fff;
    font-size: 15px;
    cursor: pointer;
    transition: background 0.2s;
}

.contact-submit-button:hover {
    background: #555;
}

.contact-submit-button:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.contact-status {
    display: none;
    margin-top: 15px;
    padding: 11px 13px;
    border-radius: 6px;
    font-size: 14px;
    line-height: 1.6;
}

.contact-status.success {
    display: block;
    color: #27633d;
    background: #eaf5ed;
}

.contact-status.error {
    display: block;
    color: #a52b2b;
    background: #fbecec;
}

/* 隱藏防機器人欄位 */

.contact-honeypot {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

/* =========================================================
   Contact Lightbox - 自動高度、完整排列
   ========================================================= */

/* 聯絡我們外框 */
#contactLightbox .copyright-lightbox-content {
    height: auto;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* 內容區域 */
#contactLightbox .copyright-lightbox-body {
    height: auto;
    max-height: none;
    overflow-y: visible;
    padding: 20px 28px;
}

/* 聯絡內容 */
#contactLightbox .contact-content {
    width: 100%;
}

/* 標題 */
#contactLightbox .contact-content h3 {
    margin-top: 0;
    margin-bottom: 10px;
}

/* 說明文字 */
#contactLightbox .contact-content p {
    margin-bottom: 16px;
    line-height: 1.6;
}

/* 表單欄位 */
#contactLightbox .contact-form-group {
    margin-bottom: 12px;
}

/* 輸入框 */
#contactLightbox .contact-form-group input {
    height: 42px;
}

/* 訊息輸入框 */
#contactLightbox .contact-form-group textarea {
    min-height: 100px;
    height: 100px;
    resize: none;
}

/* 表單按鈕 */
#contactLightbox .contact-form-actions {
    margin-top: 12px;
}

/* 頁尾 */
#contactLightbox .copyright-lightbox-footer {
    margin-top: 18px;
}

@media screen and (max-width: 768px) {

    #contactLightbox .copyright-lightbox-content {
        max-height: 90vh;
        overflow-y: auto;
    }

    #contactLightbox .copyright-lightbox-body {
        overflow-y: visible;
        padding: 16px 18px;
    }

}