/* shared_css: Basic styles for header and footer */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    color: #333;
    background-color: #f8f9fa;
}

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

/* Header Styles */
.main-header {
    background-color: #ffffff;
    border-bottom: 1px solid #e0e0e0;
    padding: 15px 0;
    box-shadow: 0 2px 4px rgba(0,0,0,.05);
    display: flex;
    flex-direction: column;
}

.main-header > .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.main-header .logo img {
    height: 40px; /* Adjust as needed */
}

.main-nav .nav-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
}

.main-nav .nav-item {
    margin-left: 25px;
    position: relative;
}

.main-nav .nav-link {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    padding: 10px 0;
    display: block;
    transition: color 0.3s ease;
}

.main-nav .nav-link:hover,
.main-nav .nav-link:focus {
    color: #007bff;
}

.main-nav .dropdown-menu {
    display: none;
    position: absolute;
    background-color: #fff;
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
    min-width: 160px;
    z-index: 1000;
    list-style: none;
    padding: 10px 0;
    margin: 0;
    border-radius: 4px;
    left: 0;
    top: 100%; /* Position below the parent link */
}

.main-nav .dropdown-item {
    padding: 8px 20px;
    text-decoration: none;
    color: #333;
    display: block;
    white-space: nowrap;
    transition: background-color 0.3s ease;
}

.main-nav .dropdown-item:hover,
.main-nav .dropdown-item:focus {
    background-color: #f2f2f2;
    color: #007bff;
}

.main-nav .dropdown-toggle[aria-expanded="true"] + .dropdown-menu {
    display: block;
}

/* Basic button styles (if not using a framework like Bootstrap) */
.btn {
    padding: 10px 20px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.btn-primary {
    background-color: #007bff;
    color: #fff;
    border-color: #007bff;
}

.btn-primary:hover {
    background-color: #0056b3;
    border-color: #0056b3;
}

.btn-outline-primary {
    background-color: transparent;
    color: #007bff;
    border-color: #007bff;
}

.btn-outline-primary:hover {
    background-color: #007bff;
    color: #fff;
}

.announcement-bar {
    background-color: #17a2b8; /* bg-info */
    color: #fff;
    padding: 8px 0;
    text-align: center;
    font-size: 0.95em;
}

.announcement-bar a {
    color: #fff;
    font-weight: bold;
    text-decoration: underline;
}

/* Footer Styles */
.main-footer {
    background-color: #343a40; /* bg-dark */
    color: #f8f9fa;
    padding: 50px 0;
    font-size: 0.9em;
}

.main-footer h5 {
    color: #fff;
    margin-bottom: 20px;
    font-weight: 600;
}

.main-footer .list-unstyled {
    list-style: none;
    padding: 0;
    margin: 0;
}

.main-footer .list-unstyled li {
    margin-bottom: 10px;
}

.main-footer .list-unstyled a {
    color: rgba(255, 255, 255, 0.7); /* text-white-50 */
    text-decoration: none;
    transition: color 0.3s ease;
}

.main-footer .list-unstyled a:hover,
.main-footer .list-unstyled a:focus {
    color: #fff;
}

.main-footer address {
    font-style: normal;
    line-height: 1.8;
}

.main-footer .social-icons a {
    color: #fff;
    margin-right: 15px;
    font-size: 1.2em;
    transition: color 0.3s ease;
}

.main-footer .social-icons a:hover {
    color: #007bff;
}

.main-footer .newsletter-signup .form-control {
    border-radius: 5px 0 0 5px;
    border: none;
}

.main-footer .newsletter-signup .btn-primary {
    border-radius: 0 5px 5px 0;
}

.main-footer hr {
    border-color: rgba(255, 255, 255, 0.2); /* border-secondary */
}

.main-footer .text-white-50 a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
}

.main-footer .text-white-50 a:hover {
    color: #fff;
    text-decoration: underline;
}

/* Responsive adjustments (basic example) */
@media (max-width: 768px) {
    .main-header > .container {
        flex-direction: column;
        align-items: flex-start;
    }

    .main-nav .nav-list {
        flex-direction: column;
        width: 100%;
        margin-top: 15px;
    }

    .main-nav .nav-item {
        margin-left: 0;
        margin-bottom: 10px;
    }

    .main-nav .dropdown-menu {
        position: static;
        box-shadow: none;
        border: none;
        padding-left: 20px;
    }

    .header-actions {
        margin-top: 15px;
        width: 100%;
        display: flex;
        justify-content: space-around;
    }

    .main-footer .footer-column {
        margin-bottom: 30px;
    }
}
/* 移动端内容区防溢出（系统追加，请勿删除） */
@media (max-width: 768px) {
  .page-content img {
    max-width: 100% !important;
    height: auto !important;
    display: block;
  }
  .page-content {
    overflow-x: hidden;
    max-width: 100%;
  }
  body {
    overflow-x: hidden;
  }
}
