body {
    font-family: "Noto Serif TC", serif;
    font-optical-sizing: auto;
    font-style: normal;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

header {
    background-color: #007bff;
    color: white;
    padding: 10px 20px;
    text-align: center;
}

nav {
    margin: auto;
}

nav a {
    color: white;
    text-decoration: none;
    margin: 0 5px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0px;
}

h1,
h2,
h3 {
    color: #333;
}

p {
    margin: 0px;
    line-height: 1.6;
}

.footer {
    background-color: #f8f9fa;
    text-align: center;
    padding: 10px 0;
    position: relative;
    bottom: 0;
    width: 100%;
}

/* Tiffany 綠主色 */
:root {
    --bs-primary: #1abc9c !important;
}

/* 覆蓋 Navbar、Footer、Hero 區塊主色 */
.bg-primary,
.navbar.bg-primary,
footer.bg-primary {
    background-color: #1abc9c !important;
}

.navbar .navbar-brand,
.navbar .nav-link,
footer,
.bg-primary,
.text-white {
    color: #fff !important;
}

.navbar-brand {
    font-size: 18px;
    user-select: none;
}

/* 按鈕主色 */
.btn-primary {
    background-color: #1abc9c !important;
    border-color: #1abc9c !important;
}

.btn-primary:hover,
.btn-primary:focus {
    background-color: #17a589 !important;
    border-color: #17a589 !important;
}

.hero-section {
    min-height: 100vh;
    width: 100%;
    background: url('/src/images/HeroSection_Background.webp') center center/cover no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    user-select: none;
}

.hero-section::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(26, 188, 156, 0.2);
    /* Tiffany 綠半透明遮罩，可依需求調整 */
    z-index: 1;
}

.hero-section .container {
    position: relative;
    z-index: 2;
}

#backToTopBtn {
    opacity: 0;
    transition: opacity 0.5s, box-shadow 0.5s, transform 0.5s, background-color 0.5s, border-color 0.5s;
    pointer-events: none;
    box-shadow: 0 6px 15px rgba(26, 188, 156, 0.35);
    /* 更明顯的初始陰影 */
}

#backToTopBtn.show {
    opacity: 1;
    pointer-events: auto;
    box-shadow: 0 6px 15px rgba(26, 188, 156, 0.35);
}

#backToTopBtn:hover,
#backToTopBtn:focus {
    box-shadow: 0 8px 20px rgba(26, 188, 156, 0.5);
    /* hover 時陰影更強更大 */
    transform: scale(0.8);
    background-color: #17a589 !important;
    border-color: #17a589 !important;
}

.mainslogan {
    font-size: 2.5em;
    font-weight: 1000;
    margin-bottom: 0.5em;
    color: #fff;
}

.subslogan {
    font-size: 1.5em;
    margin-bottom: 1.5em;
    color: #cecece;
    font-style: italic;
}

/* 強制讓 dropdown-menu 不超出視窗 */
.dropdown-item {
    margin: 0 !important;
    padding: 0.5rem;
}

.section-title {
    text-align: center;
    font-size: 28px;
    margin-top: 0px;
    margin-bottom: 2em;
    color: #333;
    font-weight: 800;
    user-select: none;
}

.section-title.text-start {
    text-align: left !important;
    margin-bottom: 1rem;
}

.section-content {
    text-align: justify;
    font-size: 18px;
    color: #666;
    line-height: 1.8;
}

.section-content-important {
    font-weight: bold;
    font-size: 18px;
    color: #d9534f;
    text-align: justify;
    line-height: 1.8;
    margin-top: 1rem;
}

.section-style {
    margin-top: 15rem;
    margin-bottom: 15rem;
    padding-left: 2rem;
    padding-right: 2rem;
}

.section-style-light {
    padding-top: 15rem;
    padding-bottom: 15rem;
    padding-left: 2rem;
    padding-right: 2rem;
    background-color: rgb(250, 250, 250);
}

.card-title {
    font-size: 1.2em;
    text-align: center;
    font-weight: 600;
    margin-bottom: 18px;
}

.card-text {
    text-align: justify;
    text-align-last: left;
    font-size: 1em;
    color: #666;
    line-height: 1.8;
    font-weight: 600;
    margin-bottom: 18px;
    hyphens: auto;
}

ul {
    color: gray;
    line-height: 1.8;
}

.card-text ul,
.card-text ol,
ul,
ol {
    text-align: left;
    margin-left: 1.2em;
    padding-left: 0.5em;
}

.card-body {
    padding: 1rem;
}

.h-100 {
    border-radius: 24px;
}

.service-row {
    margin-bottom: 3rem;
}

.service-img-wrapper {
    width: 100%;
    aspect-ratio: 3/2;
    /* 6:4 */
    overflow: hidden;
    border-radius: 18px;
    background: #e0e0e0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.service-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.service-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 1rem;
    text-align: center;
}

.service-desc {
    font-size: 18px;
    color: #444;
    margin-bottom: 0.5rem;
    text-align: justify;
    text-align-last: left;
    hyphens: auto;
    word-break: break-word;
}

.service-list {
    color: #888;
    font-size: 16px;
    padding-left: 1.2em;
    margin-bottom: 0;
}

.service-list li {
    margin-bottom: 0.3em;
    list-style-type: disc;
}

/* 行動裝置時圖片在上、文字在下 */
@media (max-width: 767.98px) {
    .service-row {
        flex-direction: column !important;
    }

    .service-desc {
        text-align: justify;
        text-align-last: left;
        hyphens: auto;
        word-break: break-word;
    }

    .service-img-wrapper {
        margin-bottom: 1.2rem;
    }

    .service-row>.col-md-6 {
        padding-left: 0;
        padding-right: 0;
    }

    .section-title.text-start {
        text-align: center !important;
        margin-bottom: 4rem;
    }
}

@media (max-width: 768px) {
    header {
        font-size: 1.2em;
    }

    .container {
        padding: 10px;
    }

    nav a {
        margin: 0 10px;
    }

    .mainslogan {
        font-size: 24px;
    }

    .subslogan {
        font-size: 16px;
    }

    .section-title {
        font-size: 24px;
    }
}

.service-row>.col-md-6 {
    padding-left: 2rem;
    padding-right: 2rem;
}

.list-unstyled {
    text-align: center;
}

.map-iframe {
    width: 100%;
    height: 450px;
    border: 0;
    border-radius: 8px;
    text-align: center;
}

.aboutus-list {
    list-style: none;
    padding: 0;
    margin: 2rem 0 0 0;
    text-align: center;
}

.aboutus-list li {
    line-height: 4rem;
    font-size: 18px;
}

.global-network-section {
    position: relative;
    overflow: hidden;
    transition: height 0.5s ease-in-out;
    background-repeat: no-repeat;
    background-position: center bottom;
}

.global-subtitle {
    text-align: center;
    font-size: 1.2em;
    color: #1abc9c;
    font-weight: 600;
    letter-spacing: 2px;
    margin-bottom: 2rem;
}

.global-network-container {
    position: relative;
    z-index: 2;
}

.world-map-bg {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80%;
    height: 60%;
    opacity: 0.1;
    z-index: 1;
}

.location-card {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    border: 1px solid #e9ecef;
    transition: transform 0.3s, box-shadow 0.3s;
    position: relative;
    z-index: 3;
    height: fit-content;
    /* 重點：讓卡片高度自適應內容 */
}

.location-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(26, 188, 156, 0.15);
}

.location-title {
    font-size: 20px;
    font-weight: 700;
    color: #1abc9c;
    margin-bottom: 1rem;
    border-bottom: 2px solid #1abc9c;
    padding-bottom: 0.5rem;
    display: inline-block;
}

.location-countries {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.country-tag {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 20px;
    padding: 0.4rem 0.8rem;
    font-size: 16px;
    color: #495057;
    transition: all 0.3s ease;
    cursor: pointer;
}

.country-tag:hover {
    background: #1abc9c;
    color: white;
    border-color: #1abc9c;
}

/* 輪播容器 */
.location-carousel-container {
    position: relative;
    min-height: 200px;
    font-size: 16px;
}

.location-carousel {
    position: relative;
    overflow: hidden;
}

.location-slide {
    opacity: 0;
    transform: translateX(30px);
    transition: all 0.5s ease-in-out;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    pointer-events: none;
}

.location-slide.active {
    opacity: 1;
    transform: translateX(0);
    position: relative;
    pointer-events: auto;
}

/* 導航按鈕 */
.carousel-navigation {
    display: flex;
    gap: 0.5rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

.nav-dot {
    background: #e9ecef;
    border: none;
    border-radius: 20px;
    padding: 0.5rem 1rem;
    font-size: 16px;
    color: #495057;
    cursor: pointer;
    transition: all 0.3s ease;
}

.nav-dot:hover,
.nav-dot.active {
    background: #1abc9c;
    color: white;
}

/* 右側地圖 */
.global-map-container {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
    min-height: 400px;
}

.world-map-image {
    max-width: 100%;
    height: auto;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.world-map-image:hover {
    opacity: 1;
}

/* 服務產業 hover 效果 */
#industries .border {
    transition: all 0.3s ease;
    cursor: pointer;
    border: 1px solid #e9ecef !important;
    background: white;
}

#industries .border:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(26, 188, 156, 0.15);
    border-color: #1abc9c !important;
    background: #f8f9fa;
}

#industries .border:hover {
    color: #1abc9c;
    font-weight: 600;
}

/* 服務產業文字效果 */
#industries .border {
    font-size: 18px;
    font-weight: 500;
    color: #495057;
    padding: 1rem 0.5rem;
    min-height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    line-height: 1.4;
}

/* 點擊效果 */
#industries .border:active {
    transform: translateY(-2px) !important;
    box-shadow: 0 4px 15px rgba(26, 188, 156, 0.2) !important;
}

/* 響應式調整 */
@media (max-width: 768px) {
    #industries .border {
        padding: 0.8rem 0.3rem;
        min-height: 70px;
        font-size: 16px;
    }

    #industries .border:hover {
        transform: translateY(-3px);
        box-shadow: 0 6px 20px rgba(26, 188, 156, 0.15);
    }

    .aboutus-list {
        text-align: left;
    }
}

/* 確保在小屏幕上有足夠的間距 */
#industries .row.g-5 {
    --bs-gutter-x: 1rem;
    --bs-gutter-y: 1rem;
}

@media (min-width: 768px) {
    #industries .row.g-5 {
        --bs-gutter-x: 2rem;
        --bs-gutter-y: 2rem;
    }
}

.navbar-logo {
    height: 60px;
    width: auto;
    transition: all 0.3s ease;
}

.navbar-logo:hover {
    transform: scale(1.05);
}