/**
 * 绿翊合规 - service 目录公共样式
 * 适用于 service/index.php 和 service/detail.php
 * 包含：Reset、顶部导航、移动端菜单按钮
 */

/* ===== Reset & Base ===== */
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
    background: #f0f2f5;
    color: #333;
    line-height: 1.8;
}
a { transition: color 0.3s ease; }
:focus-visible {
    outline: 2px solid #1c499e;
    outline-offset: 2px;
    border-radius: 4px;
}
button:focus-visible,
a:focus-visible {
    outline: 2px solid #1c499e;
    outline-offset: 2px;
    border-radius: 4px;
}

/* ===== 顶部导航 ===== */
.top-bar {
    background: #fff;
    border-bottom: 1px solid #e8e8e8;
    padding: 0 20px;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
}
.top-bar-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 64px;
}
.logo {
    font-size: 22px;
    font-weight: 700;
    color: #1c499e;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
}
.logo-icon {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    object-fit: cover;
}
.nav-menu { display: flex; gap: 0; list-style: none; margin: 0; padding: 0; }
.nav-menu > li { position: relative; }
.nav-menu > li > a {
    display: block;
    padding: 0 16px;
    text-decoration: none;
    color: #555;
    font-size: 14px;
    line-height: 64px;
    transition: color 0.3s;
    white-space: nowrap;
}
.nav-menu > li > a:hover { color: #1c499e; }
.nav-menu .has-submenu > a::after {
    content: ' \25BC';
    font-size: 10px;
    color: #999;
}
.submenu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: #fff;
    border: 1px solid #e8e8e8;
    border-radius: 12px;
    box-shadow: 0 12px 40px rgba(0,0,0,0.12);
    min-width: 180px;
    z-index: 100;
    padding: 8px 0;
}
.submenu a {
    display: block;
    padding: 10px 20px;
    text-decoration: none;
    color: #555;
    font-size: 13px;
    transition: all 0.2s;
}
.submenu a:hover {
    background: #f0f4ff;
    color: #1c499e;
    padding-left: 24px;
}
.has-submenu:hover .submenu { display: block; }

/* ===== 移动端菜单按钮 ===== */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    flex-direction: column;
    gap: 5px;
}
.menu-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: #333;
    border-radius: 2px;
    transition: all 0.3s;
}
.menu-toggle.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.menu-toggle.active span:nth-child(2) { opacity: 0; }
.menu-toggle.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }
