/* General Body & Typography */
body {
    font-family: 'Roboto', sans-serif;
    margin: 0;
    padding: 0;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    transition: background-color 0.3s ease;
    cursor: pointer;
    border: none;
}
.btn-primary {
    background-color: #007bff;
    color: #fff;
}
.btn-primary:hover {
    background-color: #0056b3;
}
.btn-secondary {
    background-color: #6c757d;
    color: #fff;
}
.btn-secondary:hover {
    background-color: #5a6268;
}
.btn-subscribe {
    background-color: #28a745;
    color: #fff;
    padding: 10px 15px;
    border-radius: 0 5px 5px 0;
}
.btn-subscribe:hover {
    background-color: #218838;
}

/* Header Styling */
.main-header {
    background-color: #fff;
    border-bottom: 1px solid #e0e0e0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}
.header-top {
    background-color: #f0f0f0;
    padding: 10px 0;
    font-size: 0.9em;
    color: #555;
}
.header-top .top-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.header-top .top-menu {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
}
.header-top .top-menu li {
    margin-right: 20px;
}
.header-top .top-menu li a {
    text-decoration: none;
    color: #555;
}
.header-top .user-actions {
    display: flex;
    align-items: center;
}
.header-top .user-actions .btn {
    margin-left: 10px;
    padding: 5px 15px;
    font-size: 0.85em;
}
.header-top .language-selector select {
    margin-left: 15px;
    padding: 5px 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    background-color: #fff;
}

.header-main {
    padding: 15px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.header-main .logo img {
    height: 50px;
}
.main-navigation {
    display: flex;
    align-items: center;
}
.main-navigation .nav-menu {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
}
.main-navigation .nav-menu li {
    margin-left: 30px;
    position: relative;
}
.main-navigation .nav-menu li a {
    text-decoration: none;
    color: #333;
    font-weight: bold;
    padding: 10px 0;
    display: block;
}
.main-navigation .nav-menu li a:hover {
    color: #007bff;
}
.main-navigation .nav-menu .has-dropdown:hover .dropdown-menu {
    display: block;
}
.dropdown-menu {
    display: none;
    position: absolute;
    background-color: #fff;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    min-width: 160px;
    z-index: 100;
    list-style: none;
    padding: 10px 0;
    border-radius: 5px;
    top: 100%;
    left: 0;
}
.dropdown-menu li a {
    padding: 8px 20px;
    color: #333;
    display: block;
    white-space: nowrap;
    font-weight: normal;
}
.dropdown-menu li a:hover {
    background-color: #f0f0f0;
    color: #007bff;
}
.search-box {
    margin-left: 30px;
    display: flex;
    border: 1px solid #ccc;
    border-radius: 5px;
    overflow: hidden;
}
.search-box input {
    border: none;
    padding: 8px 10px;
    outline: none;
    width: 180px;
}
.search-box button {
    background-color: #007bff;
    color: #fff;
    border: none;
    padding: 8px 12px;
    cursor: pointer;
}
.search-box button:hover {
    background-color: #0056b3;
}
.mobile-menu-toggle {
    display: none; /* Hidden on desktop */
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 22px;
    position: relative;
}
.mobile-menu-toggle .icon-bar {
    display: block;
    width: 100%;
    height: 3px;
    background-color: #333;
    margin: 4px 0;
    transition: all 0.3s ease;
}

/* Footer Styling */
.main-footer {
    background-color: #222;
    color: #eee;
    padding: 40px 0 20px;
    font-size: 0.9em;
}
.main-footer a {
    color: #eee;
    text-decoration: none;
}
.main-footer a:hover {
    color: #007bff;
}
.footer-widgets {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    margin-bottom: 30px;
}
.footer-widget {
    flex: 1;
    min-width: 250px;
    margin: 0 15px 20px 0;
}
.footer-widget:last-child {
    margin-right: 0;
}
.footer-widget h3 {
    color: #fff;
    font-size: 1.2em;
    margin-bottom: 20px;
    position: relative;
}
.footer-widget h3::after {
    content: '';
    display: block;
    width: 40px;
    height: 2px;
    background-color: #007bff;
    margin-top: 5px;
}
.footer-widget ul {
    list-style: none;
    padding: 0;
    margin: 0;
}
.footer-widget ul li {
    margin-bottom: 10px;
}
.footer-widget .social-links a {
    display: inline-block;
    width: 35px;
    height: 35px;
    line-height: 35px;
    text-align: center;
    background-color: #444;
    border-radius: 50%;
    margin-right: 10px;
    color: #fff;
    transition: background-color 0.3s ease;
}
.footer-widget .social-links a:hover {
    background-color: #007bff;
}
.footer-widget .newsletter-form {
    display: flex;
    margin-top: 15px;
}
.footer-widget .newsletter-form input {
    border: none;
    padding: 10px 15px;
    border-radius: 5px 0 0 5px;
    outline: none;
    flex-grow: 1;
}
.footer-bottom {
    border-top: 1px solid #333;
    padding-top: 20px;
    text-align: center;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}
.footer-bottom p {
    margin: 0;
}
.footer-bottom-nav {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
}
.footer-bottom-nav li {
    margin-left: 20px;
}

/* Responsive Design */
@media (max-width: 992px) {
    .main-navigation .nav-menu {
        display: none; /* Hide main menu on smaller screens */
    }
    .main-navigation .search-box {
        margin-left: auto; /* Push search to right */
    }
    .mobile-menu-toggle {
        display: block; /* Show toggle button */
    }
    .header-main .container {
        justify-content: space-between;
    }
    .header-top .top-nav {
        flex-direction: column;
        align-items: flex-start;
    }
    .header-top .top-menu {
        margin-bottom: 10px;
    }
    .header-top .user-actions {
        width: 100%;
        justify-content: space-around;
        margin-top: 10px;
    }
    .header-top .user-actions .btn {
        margin: 0 5px;
    }
    .header-top .language-selector {
        margin-left: 0;
        margin-top: 10px;
        width: 100%;
        text-align: center;
    }
    .header-top .language-selector select {
        width: 100%;
    }
}

@media (max-width: 768px) {
    .footer-widgets {
        flex-direction: column;
    }
    .footer-widget {
        margin-right: 0;
        margin-bottom: 30px;
        width: 100%;
    }
    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
    .footer-bottom p {
        margin-bottom: 10px;
    }
    .footer-bottom-nav li {
        margin: 0 10px;
    }
}

@media (max-width: 576px) {
    .header-main .logo img {
        height: 40px;
    }
    .search-box {
        display: none; /* Hide search box on very small screens */
    }
    .header-top .top-menu {
        flex-wrap: wrap;
        justify-content: center;
    }
    .header-top .top-menu li {
        margin: 0 10px 5px;
    }
    .footer-widget .newsletter-form {
        flex-direction: column;
    }
    .footer-widget .newsletter-form input {
        border-radius: 5px;
        margin-bottom: 10px;
    }
    .footer-widget .newsletter-form .btn-subscribe {
        border-radius: 5px;
    }
}
/* 移动端内容区防溢出（系统追加，请勿删除） */
@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;
  }
}
