.page-content {
    position: relative;
}

/* 图片背景 */
.banner {
    position: relative;
    background-image: url(../img/ocean1.webp);
    background-size: cover;
    background-position: center;
    height: 40vh;
    /* 增加视窗占比 */
    min-height: 600px;
    /* 确保最小高度足够 */
    max-height: 1400px;
    /* 如果需要，也可以调整最大高度 */
    display: flex;
    align-items: center;
    /* 垂直居中 */
    text-align: center;
    overflow: hidden;
    /* 防止内容溢出 */
}

.banner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.3);
}

.banner .container {
    position: relative;
    z-index: 1;
    color: white;
    width: 100%;
    padding: 0 20px;
    /* 仅左右内边距 */
}

.banner h1 {
    font-size: 8rem;
    margin: 0 auto 40px;
    /* 上下左右自动居中 */
    color: white;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
    line-height: 1.2;
    /* 改善换行后的行距 */
    max-width: 1200px;
    /* 控制标题最大宽度 */
    word-break: break-word;
    /* 允许长单词换行 */
}

.banner .btn-orange {
    background-color: #F68B1F;
    color: white;
    padding: 12px 30px;
    border: none;
    border-radius: 4px;
    font-size: 1.6rem;
    cursor: pointer;
}

/* 基础按钮样式 */
.btn-orange {
    background-color: #F68B1F;
    /* 橙色背景 */
    color: white;
    padding: 12px 30px;
    border: none;
    border-radius: 4px;
    font-size: 1.6rem;
    cursor: pointer;
    transition: background-color 0.3s ease;
    /* 添加颜色过渡效果 */
}

/* 悬停状态 */
.btn-orange:hover {
    background-color: #ff6b00;
    /* 深一点的橙色 */
}

/* 激活状态（鼠标按下时） */
.btn-orange:active {
    background-color: yellow;
    /* 更深的橙色 */
}

/* 焦点状态（键盘导航时） */
.btn-orange:focus {
    outline: none;
    /* 移除默认轮廓 */
    box-shadow: 0 0 0 3px rgba(240, 147, 30, 0.5);
    /* 添加橙色光晕 */
}

/* 响应式调整 */
@media (max-width: 1200px) {
    .banner h1 {
        font-size: 6rem;
        /* 中等屏幕缩小字体 */
    }
}

@media (max-width: 768px) {
    .banner {
        min-height: 500px;
        /* 手机端降低最小高度 */
    }

    .banner h1 {
        font-size: 4rem;
        /* 手机端字体进一步缩小 */
        margin-bottom: 30px;
    }
}

@media (max-width: 480px) {
    .banner h1 {
        font-size: 3rem;
        /* 超小屏幕字体 */
        line-height: 1.3;
        /* 增加行距 */
    }

    .banner .btn-orange {
        padding: 10px 25px;
        font-size: 1.4rem;
    }
}

.content-section {
    padding: 40px 0;
    /* border-bottom: 1px solid #eee; */
}

.content-section1 {
    background: #e3f2fd;
    padding: 40px 0;
    border-bottom: 1px solid #eee;
}

.content-section h2 a,
.content-section h2 a:link,
.content-section h2 a:visited,
.content-section h2 a:hover,
.content-section h2 a:active {
    text-decoration: none !important;
    border-bottom: none !important;
}

/* 全局链接下划线重置 */
a,
a:link,
a:visited,
a:hover,
a:active {
    text-decoration: none !important;
    border-bottom: none !important;
}

#about a,
#about a:link,
#about a:visited,
#about a:hover,
#about a:active {
    text-decoration: none !important;
    border-bottom: none !important;
}

#about a::after,
.content-section h2 a::after {
    display: none !important;
}

.content-section h2 {
    margin-bottom: 20px;
    color: #0B1C3C;
}

.content-section1 h2 {
    margin-bottom: 50px;
    align-self: center;
    text-align: center;
    color: #0B1C3C;
}

.introduction-content {
    font-size: 20px;
    /* 特定class的<p>标签生效 */
}

/* Feature Card Styles */
.feature-card {
    background-color: #f8f9fa;
    /* Default background - fallback */
    border-radius: 8px;
    padding: 30px;
    /* 增加内边距 */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%;
    min-height: 300px;
    /* 设置最小高度 */
    display: flex;
    flex-direction: column;
}

/* 卡片内容居中与布局 */
.card-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    height: 100%;
}

/* 按钮置于底部 */
.card-body .btn-orange {
    margin-top: auto;
    align-self: center;
    width: 100%;
    max-width: 200px;
}

.card-title {
    margin-bottom: 1rem;
    font-size: 2.5rem;
    font-weight: bold;
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.card-text {
    flex-grow: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 增加卡片间距 */
#product .row {
    margin-left: -15px;
    margin-right: -15px;
    display: flex;
    flex-wrap: wrap;
}

#product .row>div[class^="col-"] {
    padding-left: 15px;
    padding-right: 15px;
    margin-bottom: 30px;
    height: 100%;
    flex: 1;
}

@media (min-width: 768px) {
    #product .row>div[class^="col-"] {
        margin-bottom: 30px;
    }
}

.card-sensor-bg {
    background-image: url('../img/sensor.webp');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* 产品卡片背景图 */
.card-ShoreBasedObservation-bg {
    background-image: url('../img/ShoreBasedObservation.webp');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.card-OffshoreObservation-bg {
    background-image: url('../img/floatBall.webp');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.card-DisasterRiskReduction-bg {
    background-image: url('../img/StormSurgeWarningPole.webp');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
}

/* 卡片链接样式 */
.card-link {
    display: block;
    text-decoration: none;
    height: 100%;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .feature-card {
        padding: 15px;
    }

    .card-title {
        font-size: 1.5rem;
    }

    .card-text {
        font-size: 1.1rem;
        line-height: 1.6;
    }
}

.content-section2 h2 {
    margin-top: 50px;
    margin-bottom: 50px;
    align-self: center;
    text-align: center;
    color: #0B1C3C;
}

/* 修复服务区域行元素宽度溢出问题 */
#services .row {
    margin-left: 0 !important;
    margin-right: 0 !important;
    max-width: 100%;
    box-sizing: border-box;
}

.services-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
}

.services-image {
    max-height: 400px;
    width: auto;
    display: block;
    margin: 0 auto;
    object-fit: cover;

    width: 100%;
    height: auto;
    object-fit: cover;
}

.services-text {
    text-align: center;

    padding: 20px;
}

.services-title {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 16px;
}

.services-description {
    font-size: 18px;
    margin-bottom: 24px;
}

.btn {
    background-color: #ff5c2b;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 20px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s ease;
    text-decoration: none;
    display: inline-block;
}

.btn:hover {
    background-color: #e64916;
}

/* 反转左右结构 */
.reverse {
    direction: rtl;
}

.reverse .services-text {
    direction: ltr;
}

@media screen and (max-width: 768px) {
    .services-row {
        grid-template-columns: 1fr;
    }

    .reverse {
        direction: ltr;
    }
}

.content-section3 {
    background: #e3f2fd;
    padding: 40px 0;
    border-bottom: 1px solid #eee;
}

.content-section3 h2 {
    margin-bottom: 50px;
    align-self: center;
    text-align: center;
    color: #0B1C3C;
}

.news-tabs {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 40px;
}

.news-tabs button {
    border: 1px solid #0d2b3e;
    background: transparent;
    color: #0d2b3e;
    padding: 10px 20px;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
}

.news-tabs .active {
    background-color: #0d2b3e;
    color: white;
}

/* 新闻卡片样式优化 */
.news-card {
    background-color: white;
    padding: 20px;
    /* 添加内边距，解决字体紧贴边缘问题 */
    height: 100%;
    /* 确保卡片高度一致 */
    display: flex;
    flex-direction: column;
    border-radius: 6px;
}

.news-card h3 {
    margin: 15px 0;
    /* 调整标题间距 */
}

.news-card p {
    margin-bottom: 15px;
    /* 调整段落间距 */
    flex-grow: 1;
    /* 让内容区域自动填充剩余空间 */
}

.news-grid {
    display: flex;
    flex-wrap: wrap;
}

.news-grid>a {
    flex: 1 0 30%;
    /* 确保卡片宽度均匀分布 */
    margin: 0 10px 20px;
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

.news-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 4px;
    margin-bottom: 10px;
}

.news-card .tag {
    background-color: #60c4bb;
    color: white;
    font-size: 12px;
    padding: 4px 10px;
    border-radius: 2px;
    display: inline-block;
    margin-bottom: 8px;
}

.news-card .date {
    color: #999;
    font-size: 14px;
    margin-bottom: 8px;
}

.news-card h3 {
    font-size: 18px;
    margin: 0 0 10px 0;
}

.news-card p {
    font-size: 15px;
    color: #333;
    line-height: 1.5;
}

.about-section {
    display: flex;
    flex-direction: column;
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

.about-header {
    width: 100%;
    text-align: center;
    margin-bottom: 30px;
}

.about-header h2 {
    font-size: 36px;
    color: #004c73;
    margin: 0;
}

.about-content-wrapper {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    width: 100%;
}

.about-image {
    flex: 1 1 400px;
    padding: 20px;
    order: 1;
}

.about-image img {
    width: 100%;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.about-content {
    flex: 1 1 500px;
    padding: 20px;
    order: 2;
}

.about-content p {
    font-size: 18px;
    line-height: 1.8;
    margin-bottom: 15px;
}

.btn-about {
    background-color: #ff5c2b;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 20px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s ease;
    text-decoration: none;
    display: inline-block;
}

@media screen and (max-width: 768px) {
    .news-tabs {
        flex-direction: column;
        align-items: center;
    }

    .news-grid>a {
        flex: 1 0 100%;
        margin: 0 0 20px 0;
    }

    .about-section {
        flex-direction: column;
    }

    .about-content-wrapper {
        flex-direction: column;
    }
    
    .about-image,
    .about-content {
        padding: 10px;
        order: initial;
    }
    
    .about-header h2 {
        font-size: 28px;
    }
}