/* 定义页面布局 */
body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
}

header {
    background-color: #333;
    color: #fff;
    padding: 20px;
}

/* 头部样式 */
header {
    background-color: #333;
    color: #fec751;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

nav ul {
    margin: 0;
    padding: 0;
    list-style: none;
    display: flex;
}

nav ul li {
    margin-right: 10px;
}

nav ul li a {
    text-decoration: none;
    color: #fff;
    padding: 10px;
    border-radius: 5px;
}

nav ul li a:hover,
nav ul li a:focus {
    background-color: #fec751;
    color: #333;
}

/* 增加内容 */
h1 {
    font-size: 24px;
    margin: 0;
}

.subtitle {
    font-size: 16px;
}

button {
    padding: 10px 20px;
    background-color: #fff;
    color: #fec751;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

button:hover,
button:focus {
    background-color: #fec751;
    color: #333;
}

nav ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

nav ul li {
    display: inline;
    margin-right: 10px;
}

nav ul li a {
    text-decoration: none;
    color: #fff;
}

main {
    padding: 20px 0;
}

#hero {
    background-image: url('../img/1.jpg');
    background-repeat: no-repeat;
    background-position: center;
    background-size: cover;
    padding: 100px;
    height: 300px;
    text-align: center;
    align-items: center;
    color: #fec751;
}

#hero h2 {
    font-size: 36px;
}

#hero p {
    font-size: 18px;
    margin-bottom: 20px;
}


button {
    padding: 10px 20px;
    background-color: #333;
    color: #fff;
    border: none;
    cursor: pointer;
}

#services {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    padding: 20px;
    max-width: 1200px;
    /* 控制九宫格宽度 */
    margin: 0 auto;
    /* 水平居中 */
}

.service-item {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    width: 400px;
    height: 400px;
}

.service-item img {
    width: 100%;
    height: 100%;
    background-repeat: no-repeat;
}

.mask {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    opacity: 0;
    transition: opacity 0.3s;
  }
  
  .service-item:hover .mask {
    opacity: 1;
  }



#about {
    background-color: #f0f0f0;
    padding: 20px;
}

footer {
    background-color: #333;
    color: #fff;
    padding: 10px;
    text-align: center;
}


.title1 {
    text-align: center;
    color: #fec751;
}


#pic {
    margin-top: 100px;
}

.xuanchuan {
    display: flex;
    justify-content: center;
    align-items: center;
  }


  .swiper {
    width: 70%;
    height: 500px;
    padding-top: 50px;
    padding-bottom: 50px;
}
 
.swiper-slide {
    background-position: center;
    background-size: cover;
    width: 500px;
    height: 500px;
}
 
.swiper-slide img {
    width: 100%;
    height: 100%;
}



#video{
    margin: 50px 0;
}


/* a标签去掉下划线 */
a {
    text-decoration: none;
    color: #fff;
}

a:hover {   
    color: #fec751;
}

/* 响应式样式 */
@media (max-width: 768px) {
    header {
        text-align: center;
    }

    nav ul li {
        display: block;
        margin-bottom: 10px;
    }

    #hero {
        padding: 50px;
    }

    #hero h2 {
        font-size: 24px;
    }

    #hero p {
        font-size: 16px;
        margin-bottom: 10px;
    }
}
