/* —— 搜索条 —— */
.search-wrapper {
    margin: 20px auto;
    padding: 0;
    max-width: 600px;
    box-sizing: border-box;
    position: relative;
}
/* mobile: inset everything by 16px left & right */
@media screen and (max-width: 600px) {
    .search-wrapper {
    padding: 0 20px;
    /* if you want it truly full-bleed, remove max-width */
    /* max-width: none; */
    }
}
#search-input {
    width: 100%;
    /* make room on the left for the icon */
    padding: 12px 16px 12px 48px;
    border: 1px solid #ccc;
    border-radius: 12px;
    box-shadow: 2px 4px 4px 2px rgba(113, 108, 108, 0.25);
    font-size: 1rem;

    /* insert your magnifier */
    background: 
    #fff url('/images/search-icon.png') no-repeat 16px center;
    background-size: 16px 16px;
    outline: none;
}
#search-suggestions {
    display: none;       /* hide when empty */
    position: absolute;
    top: 100%;
    left: 0;
    position: absolute;
    width: 100%;
    top: 100%;
    background: #fff;
    border: 1px solid #ccc;
    border-radius: 4px;
    max-height: 240px;
    overflow-y: auto;
    list-style: none;
    margin: 4px 0 0;
    padding: 0;
    z-index: 1000;
}
#search-suggestions:not(:empty) {
    display: block;      /* show when there’s at least one <li> */
}
#search-suggestions li {
    display: flex;
    align-items: center;
    padding: 8px 12px;
    cursor: pointer;
    transition: background-color 0.2s;
}
#search-suggestions li:hover {
    background-color: #e6f4ea;
}
/* 建议里的小图标（可换成你自己的 bearing 图标） */
#search-suggestions .suggestion-icon {
    width: 24px;
    height: 24px;
    margin-right: 8px;
    background: url('/images/bearing-icon.png') center/contain no-repeat;
}

/* —— 启用平滑滚动 —— */
html {
    scroll-behavior: smooth;
}

/* —— 全局重置 & 通用样式 —— */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
html, body {
    font-family: "Microsoft YaHei", Arial, sans-serif;
    background-color: #f5f5f5;
    color: #333;
    line-height: 1.6;
}
a {
    text-decoration: none;
    color: inherit;
}
img {
    max-width: 100%;
    display: block;
}

/* —— 顶部导航 —— */
.header {
    background-color: #ffffff;
    border-bottom: 1px solid #e0e0e0;
    position: sticky;
    top: 0;
    z-index: 1000;
}
.header-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 20px;
    position: relative;
}
.logo {
    display: flex;
    align-items: center;
}
.logo img {
    width: 50px;
    height: 50px;
    object-fit: contain;
}
.logo-text {
    font-size: 1.5rem;
    font-weight: bold;
    color: #004080;
    margin-left: 10px;
}
.nav-menu {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}
.nav-menu a {
    font-size: 0.95rem;
    color: #555;
    padding: 8px 12px;
    border-radius: 4px;
    transition: background-color 0.2s;
}
.nav-menu a:hover {
    background-color: #e6f4ea;
    color: #004080;
}

/* —— 移动端折叠菜单 —— */
.mobile-nav {
    display: none;
}
@media (max-width: 768px) {
    .nav-menu {
    display: none;
    }
    .header-container {
    padding: 8px 10px;
    justify-content: space-between;
    align-items: center;
    }
    .logo-text {
    font-size: 1.2rem;
    line-height: 1.2;
    white-space: normal;
    margin-left: 6px;
    }
    .mobile-nav {
    display: block;
    position: relative;
    }
    .mobile-nav summary {
    padding: 6px 8px;
    font-size: 1rem;
    border: 2px solid #004080;
    border-radius: 4px;
    background-color: #ffffff;
    cursor: pointer;
    transition: background-color 0.2s, color 0.2s;
    width: 75px;
    }
    .mobile-nav summary::-webkit-details-marker {
    display: none !important;
    }
    .mobile-nav summary::marker {
    content: none !important;
    display: none !important;
    }
    .mobile-nav summary::-moz-details-marker {
    display: none !important;
    }
    .mobile-nav summary:hover {
    background-color: #004080;
    color: #ffffff;
    }
    .mobile-nav nav {
    position: absolute;
    top: 100%;
    right: 0;
    width: 130px;
    margin-top: 0;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    background-color: #fff;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
    z-index: 1001;
    }
    .mobile-nav nav a {
    display: block;
    padding: 10px 12px;
    font-size: 0.95rem;
    color: #333;
    border-bottom: 1px solid #e0e0e0;
    background-color: #fff;
    transition: background-color 0.2s, color 0.2s;
    }
    .mobile-nav nav a:last-child {
    border-bottom: none;
    }
    .mobile-nav nav a:hover {
    background-color: #e6f4ea;
    color: #004080;
    }
}

/* —— 响应式调整 —— */
@media (max-width: 992px) {
    .three-columns {
    flex-direction: column;
    }
    .cards-section {
    flex-direction: column;
    }
    .nav-menu {
    flex-wrap: wrap;
    }
    .footer-container {
    flex-direction: column;
    }
    .slide .overlay-text {
    font-size: 1.5rem !important;
    padding: 0 8px;
    }
}

/* —— 轮播横幅（带圆角）—— */
.hero-slides {
    position: relative;
    max-width: 1200px;
    margin: 30px auto;
    overflow: hidden;
    border-radius: 8px;
}
/* 移动端按宽高比撑高 */
@media (max-width: 992px) {
    .hero-slides {
    padding-top: 50%;
    }
}
/* 桌面端固定高度 */
@media (min-width: 992px) {
    .hero-slides {
    padding-top: 0 !important;
    height: 400px;
    max-height: 400px;
    }
    .hero-slides .slide {
    background-repeat: no-repeat;
    background-position: center;
    height: 100%;
    width: 100%;
    }
    .hero-slides .slide-schaeffler {
    background-size: contain !important;
    background-color: #016a2d !important;
    }
    .hero-slides .slide-bearings {
    background-size: cover !important;
    }
    .slide .overlay-text {
    font-size: 2.5rem !important;
    padding: 0;
    }
}
.hero-slides .slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #f5f4f0;
    opacity: 0;
    z-index: 1;
    transition: opacity 0.6s ease;
}
.hero-slides .slide.active {
    opacity: 1;
    z-index: 2;
}
.slide .overlay-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #ffffff;
    font-size: 2rem;
    font-weight: bold;
    text-shadow: 0 2px 5px rgba(0,0,0,0.5);
    white-space: nowrap;
    padding: 0 8px;
}
.slide-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 60px;
    background-color: rgba(0, 0, 0, 0.3);
    border: none;
    color: #fff;
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 3;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s;
}
.slide-btn:hover {
    background-color: rgba(0, 0, 0, 0.5);
}
.slide-btn.prev {
    left: 16px;
}
.slide-btn.next {
    right: 16px;
}
.dots {
    position: absolute;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 3;
}
.dot {
    width: 10px;
    height: 10px;
    background-color: rgba(255,255,255,0.6);
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.2s;
}
.dot.active {
    background-color: #ffffff;
}

/* —— 主体内容 & 三栏 & 卡片 & 页脚 —— */
.container {
    max-width: 1200px;
    margin: 30px auto;
    padding: 0 20px;
}
.three-columns {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}
.column {
    background-color: #ffffff;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    padding: 20px;
    flex: 1 1 300px;
}
.column h3 {
    font-size: 1.2rem;
    margin-bottom: 12px;
    color: #004080;
    border-left: 4px solid #004080;
    padding-left: 8px;
}
.brand-list {
    padding-top: 10px;
    list-style: none;
}
.brand-list li {
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.brand-list img {
    width: 40px;
    height: 40px;
    object-fit: contain;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    background-color: #fafafa;
    padding: 4px;
}
.company-intro p {
    font-size: 0.95rem;
    color: #555;
    text-indent: 2em;
    margin-bottom: 10px;
}
.culture-item {
    margin-bottom: 10px;
}
.culture-item span {
    font-weight: bold;
    color: #004080;
}
.culture-item p {
    font-size: 0.9rem;
    color: #555;
    margin-top: 4px;
    margin-left: 1em;
}
.cards-section {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    margin-top: 40px;
}
.card {
    background-color: #ffffff;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    overflow: hidden;
    flex: 1 1 350px;
    display: flex;
    flex-direction: column;
}
.card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
}
.card-content {
    padding: 12px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}
.card-content h4 {
    font-size: 1.2rem;            /* 跟 .column h3 一致 */
    color: #004080;
    margin-bottom: 12px;          /* 多一点空隙 */
    border-left: 4px solid #004080;
    padding-left: 8px;
}
.card-content p {
    flex-grow: 0;
    font-size: 0.9rem;
    color: #555;
    margin-bottom: 8px;
}
.card-content a.btn {
    align-self: flex-start;
    background-color: #004080;
    color: #fff;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.9rem;
    transition: background-color 0.2s;
}
.card-content a.btn:hover {
    background-color: #005d26;
}
.card-content ul {
    margin: 0 0 12px 0;
    padding-left: 0;
}
.card-content ul a {
    color: #004080;
    position: relative;
    padding-right: 18px;
}
.card-content ul a::after {
    content: "→";
    position: absolute;
    right: 0;
    opacity: 0;
    transition: all 0.2s;
}
.card-content ul a:hover {
    color: #005d26;
}
.card-content ul a:hover::after {
    opacity: 1;
    right: -4px;
}

.footer {
    background-color: #f0f0f0;
    border-top: 1px solid #e0e0e0;
    color: #555;
}
.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    padding: 30px 20px;
}
.footer-col {
    flex: 1 1 250px;
    margin: 10px 0;
}
.footer-col h5 {
    font-size: 1rem;
    color: #004080;
    margin-bottom: 8px;
}
.footer-col ul {
    list-style: none;
}
.footer-col ul li {
    margin-bottom: 6px;
}
.footer-col ul li a {
    font-size: 0.9rem;
    color: #555;
}
.footer-bottom {
    background-color: #004080;
    color: #fff;
    text-align: center;
    padding: 20px 10px;
    font-size: 0.9rem;
    line-height: 1.5;
}
.footer-bottom a {
    color: #ffd966;
    text-decoration: underline;
}

/* 1. friend-links ul 仍然使用默认的黑点（disc inside），只调整上方间距 */
.friend-links {
    list-style: disc inside; /* 保留“•”，并且让它与文字左侧对齐 */
    margin-top: 12px;        /* 上面段落和列表之间保持 12px 空隙 */
    padding-left: 0;         /* 去掉 ul 的默认缩进，让“•”贴近容器左侧 */
}

/* 2. li 行高/间距可选，保证列表看起来不拥挤 */
.friend-links li {
    margin-bottom: 6px;  /* 每行之间留一点垂直空间 */
    line-height: 1.5;
}

/* 3. 把 <a> 文字设为蓝色，默认没有下划线 */
.friend-links li a {
    color: #004080 !important;         /* 典型深蓝色，可以自行替换其他蓝色 */
    text-decoration: none;  /* 默认无下划线 */
    transition: color 0.2s, text-decoration 0.2s;
}

/* 4. 鼠标移到链接上时，文字变深并出现下划线 */
.friend-links li a:hover {
    color: #0056a3 !important;         /* 鼠标悬停时的深蓝色 */
    text-decoration: underline;
}

/* —— Logo 下方的英文名称样式 —— */
.logo-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2; /* 让中文和英文行距稍微紧凑 */
}
.logo-text .logo-english {
    font-size: 0.9rem;        /* 比中文稍小 */
    font-weight: normal;      /* 不用加粗，保持层次 */
    color: #666666;           /* 颜色比中文浅一些 */
    margin-top: 2px;          /* 跟上面的中文留点空隙 */
}

/* —— 红色高亮光晕动画 —— */
@keyframes halo {
    0%, 100% {
    box-shadow: 0 0 0 rgba(255,0,0,0);
    }
    50% {
    box-shadow: 0 0 12px rgba(255,0,0,0.8);
    }
}

/* 给需要高亮的卡片加上这个类就会播放 3s 光晕效果 */
.highlight {
    animation: halo 3s ease-out;
}

@media (max-width: 768px) {
    .slide-btn {
    display: none;
    }
    .slide .overlay-text {
    white-space: normal;
    text-align: center;
    font-size: 1.7rem !important;
    padding: 0 12px !important;
    }
    /* force each phrase to be one unbroken line */
    .slide .overlay-text .overlay-line1,
    .slide .overlay-text .overlay-line2 {
    display: block;
    white-space: nowrap;
    }
}
