/* Base template styles */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}

main {
    min-height: calc(100vh - 200px);
    padding-top: 0px;
}

/* Navbar styles */
nav.navbar {
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    position: relative;
    z-index: 1050; /* 確保navbar在最高層級 */
}

nav.navbar .navbar-brand {
    font-weight: bold;
    font-size: 1.5rem;
    color: #ffffff !important;
}

nav.navbar .nav-link {
    color: #ffffff !important;
    font-weight: 500;
    transition: color 0.3s ease;
}

nav.navbar .nav-link:hover {
    color: #ffd700 !important;
}

/* Footer styles */
footer {
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    color: #ffffff;
    padding: 2rem 0;
    margin-top: auto;
    position: relative;
    z-index: 1050; /* 確保footer在最高層級，與navbar相同 */
}

footer h5 {
    color: #ffd700;
    margin-bottom: 1rem;
}

footer a {
    color: #ffffff;
    text-decoration: none;
    transition: color 0.3s ease;
}

footer a:hover {
    color: #ffd700;
}

/* Language dropdown styles */
.navbar .dropdown-menu {
    background-color: rgba(30, 60, 114, 0.95) !important;
    border: none !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2) !important;
    z-index: 1051 !important; /* 確保下拉選單在navbar之上 */
}

.navbar .dropdown-item {
    color: #ffffff !important;
    padding: 0.5rem 1rem !important;
}

.navbar .dropdown-item:hover {
    background-color: rgba(255, 215, 0, 0.2) !important;
    color: #ffd700 !important;
}

.navbar .dropdown-item button {
    background: none !important;
    border: none !important;
    color: #ffffff !important;
    width: 100% !important;
    text-align: left !important;
    padding: 0 !important;
    font-size: inherit !important;
    background-color: transparent !important;
}

.navbar .dropdown-item button:hover {
    color: #ffffff !important;
    background-color: transparent !important;
}