/* ========== 桌面端基础样式 ========== */

/* 中间内容区域 - 1350px 容器居中 */
.main-content {
    width: 1350px;
    margin: 0 auto;
    padding: 20px 0;
    text-align: center;
}

/* Banner 图片样式 - 限制在 1200px 容器内 */
.contact-banner {
    width: 100%;
    margin-bottom: 20px;
}

.contact-banner img {
    width: 100%;
    height: auto;
    border-radius: 8px;
}

/* 联系信息和表单容器 - 透明背景，让子元素各自有背景 */
.contact-wrapper {
    background: transparent;
    padding: 0;
    margin: 20px 0;
    display: flex;
    justify-content: space-between;
    gap: 50px;
    width: 100%;
}

/* 联系方式模块 - 白色背景卡片 */
.contact-info {
    flex: 1;
    text-align: left;
    background: #ffffff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.contact-info h2 {
    font-size: 24px;
    color: #0066cc;
    margin-bottom: 20px;
}

.contact-info ul {
    list-style-type: none;
    padding: 0;
}

.contact-info li {
    font-size: 16px;
    color: #666;
    line-height: 24px;
    margin-bottom: 10px;
}

/* 留言表单模块 - 浅蓝色渐变背景区分 */
.contact-form {
    flex: 1;
    text-align: left;
    background: linear-gradient(135deg, #f8f9ff 0%, #eef2ff 100%);
    padding: 30px;
    border-radius: 8px;
    border: 1px solid #d6e4ff;
    box-shadow: 0 2px 8px rgba(0,102,204,0.08);
}

.contact-form h2 {
    font-size: 24px;
    color: #0066cc;
    margin-bottom: 20px;
}

/* 表单样式 - 统一宽度 */
.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 12px 15px;
    margin-bottom: 20px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 16px;
    box-sizing: border-box;
    transition: border-color 0.3s ease;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: #0066cc;
}

.contact-form button {
    width: 100%;
    padding: 12px 20px;
    background: linear-gradient(135deg, #0066cc 0%, #0055aa 100%);
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0,102,204,0.2);
}

.contact-form button:hover {
    background: linear-gradient(135deg, #0055aa 0%, #004499 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,102,204,0.3);
}

.form-note {
    font-size: 14px;
    color: #666;
    margin-top: 10px;
    text-align: center;
}

/* 地图定位模块 - 居中显示 */
.map-section {
    width: 1350px;
    margin: 0 auto 20px;
    text-align: center;
}

.map-section h2 {
    font-size: 24px;
    color: #0066cc;
    margin-bottom: 20px;
    text-align: center;
}

.map-container {
    width: 100%;
    height: 400px;
    border: 1px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
}

.address-text {
    font-size: 16px;
    color: #666;
    margin-top: 20px;
    text-align: center;
}

/* ========== 移动端适配样式 ========== */

/* 平板和手机端（768px 以下） */
@media screen and (max-width: 768px) {
    /* 页面整体容器 */
    .page {
        padding: 0;
        width: 100%;
    }
    
    /* 中间内容区域适配 */
    .main-content {
        width: 100%;
        max-width: 100%;
        padding: 15px 10px;
        box-sizing: border-box;
    }
    
    /* Banner 图片适配 */
    .contact-banner img {
        max-width: 100%;
        height: auto;
        border-radius: 4px;
        margin-bottom: 15px;
    }
    
    /* 联系 wrapper 适配 - 移除父容器背景 */
    .contact-wrapper {
        flex-direction: column;
        gap: 20px;
        padding: 0;
        margin: 15px 0;
        width: 100%;
        background: transparent;
        display: flex;
        justify-content: space-between;
    }
    
    /* 联系信息和表单模块统一基础样式 */
    .contact-info,
    .contact-form {
        width: 100%;
        flex: none;
        text-align: left;
        box-sizing: border-box;
    }
    
    /* 联系方式模块 - 白色背景 */
    .contact-info {
        background: #ffffff;
        padding: 20px 15px;
        border-radius: 8px;
        box-shadow: 0 2px 8px rgba(0,0,0,0.08);
        border: none;
    }

    .contact-info h2 {
        font-size: 20px;
        color: #0066cc;
        margin-bottom: 15px;
    }

    .contact-info ul {
        list-style-type: none;
        padding: 0;
    }

    .contact-info li {
        font-size: 14px;
        color: #666;
        line-height: 1.6;
        margin-bottom: 8px;
        word-break: break-word;
    }
    
    /* 留言表单模块 - 浅蓝色背景区分 */
    .contact-form {
        background: linear-gradient(135deg, #f8f9ff 0%, #eef2ff 100%);
        padding: 20px 15px;
        border-radius: 8px;
        border: 1px solid #d6e4ff;
        box-shadow: 0 2px 8px rgba(0,102,204,0.08);
    }

    .contact-form h2 {
        font-size: 20px;
        color: #0066cc;
        margin-bottom: 15px;
    }

    /* 表单样式 - 统一宽度 */
    .contact-form input,
    .contact-form textarea {
        width: 100%;
        padding: 10px 12px;
        margin-bottom: 15px;
        border: 1px solid #ccc;
        border-radius: 4px;
        font-size: 14px;
        box-sizing: border-box;
        transition: border-color 0.3s ease;
    }

    .contact-form input:focus,
    .contact-form textarea:focus {
        outline: none;
        border-color: #0066cc;
    }

    .contact-form button {
        width: 100%;
        padding: 12px;
        background: linear-gradient(135deg, #0066cc 0%, #0055aa 100%);
        color: #fff;
        border: none;
        border-radius: 4px;
        font-size: 16px;
        cursor: pointer;
        font-weight: 500;
        transition: all 0.3s ease;
        box-shadow: 0 2px 4px rgba(0,102,204,0.2);
    }

    .contact-form button:hover {
        background: linear-gradient(135deg, #0055aa 0%, #004499 100%);
        transform: translateY(-2px);
        box-shadow: 0 4px 8px rgba(0,102,204,0.3);
    }
    
    /* 表单元素适配已在上面统一设置，移除重复样式 */
    
    .form-note {
        font-size: 14px;
        color: #666;
        margin-top: 10px;
        text-align: center;
    }
    
    /* 地图定位模块适配 */
    .map-section {
        width: 100%;
        max-width: 100%;
        padding: 0 10px;
        box-sizing: border-box;
        margin-bottom: 15px;
    }
    
    .map-section h2 {
        font-size: 20px;
        margin-bottom: 15px;
    }
    
    .map-container {
        width: 100%;
        height: 300px;
        border-radius: 4px;
    }
    
    .address-text {
        font-size: 14px;
        line-height: 1.6;
        margin-top: 15px;
        word-break: break-word;
    }
    
    /* 错误提示文字适配 */
    .error-message {
        font-size: 12px;
    }
}

/* 小屏手机（480px 以下）进一步优化 */
@media screen and (max-width: 480px) {
    /* Banner 进一步调整 */
    .contact-banner img {
        border-radius: 2px;
    }
    
    /* 标题进一步缩小 */
    .contact-info h2,
    .contact-form h2,
    .map-section h2 {
        font-size: 18px;
    }
    
    /* 联系信息文字调整 */
    .contact-info li {
        font-size: 13px;
    }
    
    /* 表单元素进一步调整 */
    .contact-form input,
    .contact-form textarea {
        font-size: 13px;
        padding: 6px;
    }
    
    .contact-form button {
        font-size: 15px;
    }
    
    /* 地图高度进一步降低 */
    .map-container {
        height: 250px;
    }
    
    .address-text {
        font-size: 13px;
    }
}
