/* General Body Styles */
body {
    font-family: 'Arial', sans-serif;
    margin: 0;
    padding: 0;
    line-height: 1.6;
    color: #333;
    background-color: #f8f8f8;
}

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

/* Header Styles */
.main-header {
    background-color: #ffffff;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    position: relative;
    z-index: 1000;
}

.header-top-bar {
    background-color: #0056b3;
    color: #ffffff;
    padding: 10px 0;
    font-size: 0.9em;
}

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

.top-nav-links a {
    color: #ffffff;
    text-decoration: none;
    margin-left: 15px;
    transition: color 0.3s ease;
}

.top-nav-links a:hover {
    color: #e0e0e0;
}

.header-main-nav .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
}

.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: #333;
    font-size: 1.8em;
    font-weight: bold;
}

.logo img {
    margin-right: 10px;
}

.primary-navigation ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
}

.primary-navigation ul li {
    position: relative;
    margin-left: 30px;
}

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

.primary-navigation .nav-link:hover,
.primary-navigation .nav-link.active {
    color: #007bff;
}

.dropdown-menu {
    display: none;
    position: absolute;
    background-color: #ffffff;
    box-shadow: 0 8px 16px rgba(0,0,0,0.2);
    min-width: 160px;
    z-index: 1;
    border-radius: 5px;
    padding: 10px 0;
    top: 100%; /* Position below the parent */
    left: 0;
}

.dropdown:hover .dropdown-menu,
.dropdown-menu.active { /* Added for JS toggle on mobile */
    display: block;
}

.dropdown-item {
    color: #333;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    transition: background-color 0.3s ease;
}

.dropdown-item:hover {
    background-color: #f1f1f1;
    color: #007bff;
}

.header-actions {
    display: flex;
    align-items: center;
}

.search-box {
    display: flex;
    border: 1px solid #ddd;
    border-radius: 20px;
    overflow: hidden;
    margin-right: 20px;
}

.search-input {
    border: none;
    padding: 8px 15px;
    outline: none;
    width: 180px;
}

.search-button {
    background-color: #007bff;
    color: white;
    border: none;
    padding: 8px 15px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.search-button:hover {
    background-color: #0056b3;
}

.menu-toggle {
    display: none; /* Hidden on desktop */
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 20px;
    position: relative;
}

.menu-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background-color: #333;
    margin-bottom: 6px;
    transition: all 0.3s ease;
}

.menu-toggle span:last-child {
    margin-bottom: 0;
}

.menu-toggle.open span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}
.menu-toggle.open span:nth-child(2) {
    opacity: 0;
}
.menu-toggle.open span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* Hero Section */
.hero-section {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url('https://picsum.photos/id/1015/1600/900') no-repeat center center/cover;
    color: white;
    text-align: center;
    padding: 100px 0;
}

.hero-section h1 {
    font-size: 3.5em;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

.hero-section p {
    font-size: 1.3em;
    margin-bottom: 40px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.btn {
    display: inline-block;
    padding: 12px 25px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    margin: 0 10px;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.btn-primary {
    background-color: #007bff;
    color: white;
    border: 2px solid #007bff;
}

.btn-primary:hover {
    background-color: #0056b3;
    border-color: #0056b3;
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: transparent;
    color: white;
    border: 2px solid white;
}

.btn-secondary:hover {
    background-color: white;
    color: #007bff;
    transform: translateY(-2px);
}

/* Footer Styles */
.main-footer {
    background-color: #222;
    color: #eee;
    padding: 50px 0 20px;
    font-size: 0.9em;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.footer-col h3 {
    color: #007bff;
    margin-bottom: 20px;
    font-size: 1.2em;
}

.footer-col p {
    margin-bottom: 10px;
    line-height: 1.8;
}

.footer-col ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-col ul li {
    margin-bottom: 8px;
}

.footer-link {
    color: #ccc;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-link:hover {
    color: #007bff;
}

.social-links a {
    color: #ccc;
    font-size: 1.5em;
    margin-right: 15px;
    transition: color 0.3s ease;
}

.social-links a:hover {
    color: #007bff;
}

.newsletter-form {
    display: flex;
    margin-top: 15px;
}

.newsletter-form input[type="email"] {
    flex-grow: 1;
    padding: 10px 15px;
    border: 1px solid #555;
    border-radius: 5px 0 0 5px;
    background-color: #333;
    color: white;
    outline: none;
}

.newsletter-form input[type="email"]::placeholder {
    color: #aaa;
}

.btn-subscribe {
    background-color: #007bff;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 0 5px 5px 0;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

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

.newsletter-privacy {
    font-size: 0.8em;
    color: #aaa;
    margin-top: 10px;
}

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid #333;
    margin-top: 30px;
}

.footer-bottom p {
    margin: 5px 0;
    color: #aaa;
}

/* Responsive adjustments */
@media (max-width: 992px) {
    .primary-navigation ul {
        margin-left: 0;
    }
    .primary-navigation ul li {
        margin-left: 20px;
    }
    .search-box {
        width: 150px;
    }
}

@media (max-width: 768px) {
    .header-top-bar .container {
        flex-direction: column;
        text-align: center;
    }
    .top-nav-links {
        margin-top: 10px;
    }
    .header-main-nav .container {
        flex-wrap: wrap;
        justify-content: center;
    }
    .logo {
        margin-bottom: 15px;
    }
    .primary-navigation {
        width: 100%;
        order: 3; /* Push navigation below logo and actions */
        display: none; /* Hide navigation by default for mobile */
        background-color: #ffffff;
        box-shadow: 0 8px 16px rgba(0,0,0,0.1);
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        padding: 10px 0;
    }
    .primary-navigation.active {
        display: block;
    }
    .primary-navigation ul {
        flex-direction: column;
        text-align: center;
    }
    .primary-navigation ul li {
        margin: 0;
        border-bottom: 1px solid #eee;
    }
    .primary-navigation ul li:last-child {
        border-bottom: none;
    }
    .nav-link {
        padding: 15px 0;
    }
    .header-actions {
        order: 2;
        margin-left: auto;
    }
    .search-box {
        margin-right: 10px;
        width: auto;
    }
    .search-input {
        width: 120px;
    }
    .menu-toggle {
        display: block; /* Show menu toggle on mobile */
    }
    .hero-section {
        padding: 60px 0;
    }
    .hero-section h1 {
        font-size: 2.5em;
    }
    .hero-section p {
        font-size: 1em;
    }
    .btn {
        margin: 5px;
    }
    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }
    .footer-col ul {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
    }
    .footer-col ul li {
        margin: 0 10px 10px 10px;
    }
    .social-links {
        margin-top: 20px;
    }
    .newsletter-form {
        justify-content: center;
    }
    .newsletter-form input, .btn-subscribe {
        border-radius: 5px;
        margin: 5px 0;
    }
    .newsletter-form {
        flex-direction: column;
        align-items: center;
    }
    .newsletter-form input[type="email"] {
        border-radius: 5px;
        width: 80%;
        margin-bottom: 10px;
    }
    .btn-subscribe {
        border-radius: 5px;
        width: 80%;
    }
}

@media (max-width: 480px) {
    .hero-section h1 {
        font-size: 2em;
    }
    .hero-section p {
        font-size: 0.9em;
    }
    .top-nav-links {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
    }
    .top-nav-links a {
        margin: 5px 10px;
    }
}

/* Font Awesome for icons */
@import url('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css');
/* 移动端内容区防溢出（系统追加，请勿删除） */
@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;
  }
}
