/* 全局重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, sans-serif;
}

body {
    overflow-x: hidden;
    scroll-behavior: smooth;
    padding-top: 0;
    background-color: #f5f5f5;
    width: 100%;
    min-height: 100vh;
    margin: 0;
}

/* 导航栏样式 - 底层显示+可见性优化 */
.nav-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 999;
    padding: 10px 20px;
    background-color: rgba(255, 255, 255, 0.5);
    margin: 0;
}

.logo {
    color: #333;
    text-shadow: none;
    display: flex;
    align-items: center;
    font-size: 20px; /* 示例：20px，可改为22px、24px等 */
    font-weight: 550; /* 可选：轻微加粗，让文字更醒目 */
}

.logo img {
    height: 40px;
    margin-right: 10px;
}

.box-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: transparent;
}

.search-bar {
    display: flex;
    gap: 5px;
    margin-left: auto;
    margin-right: 10px;
}

.search-bar input {
    padding: 5px 10px;
    border: 1px solid #ccc;
    background: rgba(255, 255, 255, 0.8);
    color: #333;
    border-radius: 4px;
}

.search-bar input::placeholder {
    color: #666;
}

.search-bar button {
    padding: 5px 10px;
    border: none;
    background: rgba(255, 255, 255, 0.8);
    color: hsl(0, 88%, 50%);
    border-radius: 40px;
    cursor: pointer;
}

.header2 {
    display: flex;
    gap: 15px;
}

.header2 a {
    text-decoration: none;
    color: #333;
    text-shadow: none;
    padding: 5px 10px;
}

.navbar {
    display: flex;
    justify-content: center;
    align-items: center;
    background: transparent;
    padding: 10px 0;
    margin-top: 5px;
}

.navbar a {
    color: #333;
    text-shadow: none;
    text-decoration: none;
    padding: 14px 16px;
    margin: 0 5px;
}

.dropdown {
    overflow: hidden;
}

.dropdown-content {
    display: none;
    position: absolute;
    background: rgba(249, 249, 249, 0.95);
    min-width: 95px;
    z-index: 1000;
    max-height: 600px;
    overflow-y: auto;
}

.split-line {
    border-right: 2px solid #333;
    padding-right: 20px;
}

.dropdown-content a {
    color: #333;
    text-shadow: none;
    padding: 12px 16px;
    display: block;
    text-align: left;
}

.dropdown:hover .dropdown-content {
    display: block;
}

.navbar a:hover, .dropdown:hover .dropbtn {
    background: rgba(0, 0, 0, 0.1);
}

/* 背景图片容器 - 中层显示+顶头无间隙 */
.bg-image-container {
    position: relative;
    z-index: 2;
    margin-top: 0;
    width: 100%;
}

.bg-image-container img {
    width: 100%;
    display: block;
    height: auto;
}

/* 留言板容器 - 顶层居中显示 */
.container {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
    width: 800px;
    height: 400px;
    /* 核心：设置白色半透明背景（0.8为透明度，范围0-1） */
    background-color: rgba(255, 255, 255, 0.8); 
    padding: 20px;
    box-shadow: 0 0 10px rgba(6, 6, 6, 0.1);
    margin: 0;
}

h1 {
    text-align: center;
    color: #333;
    margin-bottom: 20px;
}

#messageList {
    list-style-type: none;
    padding: 0;
    margin-bottom: 20px;
}

#messageList li {
    background-color: rgba(255, 255, 255, 0.5);
    margin-bottom: 10px;
    padding: 10px;
    border-left: 5px solid #007bff;
    border-radius: 4px;
}

#messageForm {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    background-color: rgba(255, 255, 255, 0.5);
}

#messageInput {
    width: calc(100% - 100px);
    height: 150px;
    padding: 10px;
    font-size: 16px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background-color: rgba(255, 255, 255, 0.1);
}

#messageForm button {
    width: 80px;
    padding: 10px 0;
    font-size: 16px;
    cursor: pointer;
    background: #c23b22;
    color: #fff;
    border: none;
    border-radius: 4px;
    white-space: nowrap;
}

/* 页脚样式 - 紧贴图片+顶层显示 */
.footer {
    margin-top: 0;
    position: static;
    z-index: 20;
    width: 100%;
    background: rgba(51, 51, 51, 0.9);
    color: #fff;
    padding: 20px 0;
    text-align: center;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

.social-media a {
    display: inline-block;
    margin: 0 5px;
}

.social-media img {
    width: 40px;
    height: auto;
}