@charset "utf-8";
/* ========================
   pctop1.css - 顶部导航样式（自 style123.css 提取，供 pctop1.asp 使用）
======================== */

:root {
    --primary-green: #0D6B46;
    --deep-green: #085233;
    --light-green: #1A8C5E;
    --accent-green: #2ECC71;
    --pale-green: #E8F5EE;
    --bg-light: #F8FAF9;
    --bg-white: #FFFFFF;
    --text-dark: #1A1A1A;
    --text-body: #333333;
    --text-muted: #666666;
    --text-light: #888888;
    --border-color: #E0EBE5;
    --shadow-sm: 0 2px 8px rgba(13, 107, 70, 0.06);
    --shadow-md: 0 8px 30px rgba(13, 107, 70, 0.10);
    --shadow-lg: 0 16px 50px rgba(13, 107, 70, 0.14);
    --transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* 基础重置 */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Helvetica, Arial, sans-serif;
    color: var(--text-body);
    background-color: var(--bg-white);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul, ol {
    list-style: none;
}

.container {
    width: 100%;
    max-width: 1540px;
    margin: 0 auto;
    padding: 0 32px;
}
.wenqin{ width:100%; text-align:center; margin:20px auto 20px;}
.wenqin img{margin:auto; display:block; max-width:100%; height:auto;}

/* ========================
   顶部信息栏
======================== */
.top-bar {
    background: linear-gradient(90deg, var(--deep-green) 0%, var(--primary-green) 100%);
    color: rgba(255, 255, 255, 0.92);
    font-size: 15px;
    padding: 16px 0;
    position: relative;
    z-index: 1001;
}

.top-bar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.top-bar-left,
.top-bar-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.top-bar .divider {
    opacity: 0.4;
    font-weight: 300;
}

.top-bar-left span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.top-bar-left span::before {
    content: '';
    display: inline-block;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--accent-green);
}

/* ========================
   主导航
======================== */
/* ========================
   主导航
======================== */
.main-header {
    background: var(--bg-white);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: var(--transition);
}

.main-header.scrolled {
    box-shadow: var(--shadow-md);
}

.main-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 14px;
}

.logo img {
    width: 110px;
    height: auto;
    object-fit: contain;
    flex-shrink: 0;
}

.logo-img-mobile {
    display: none;
}

.logo-text h1 {
    font-size: 26px;
    font-weight: 700;
    color: var(--text-dark);
    letter-spacing: 0.5px;
    line-height: 1.2;
}

.logo-text p {
    font-size: 15px;
    color: var(--primary-green);
    margin-top: 3px;
    font-weight: 500;
    letter-spacing: 0.5px;
}

.main-nav {
    margin-left: auto;
    height: 100%;
}

.main-nav ul {
    display: flex;
    align-items: stretch;
    gap: 24px;
    height: 100%;
}

/* 下拉菜单（参照中国电力建设集团官网风格） */
.main-nav > ul > li {
    position: relative;
    display: flex;
    align-items: center;
}

.main-nav li.has-dropdown:hover .dropdown-overlay {
    display: block;
}

.dropdown-overlay {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    width: auto;
    min-width: 720px;
    max-width: calc(100vw - 32px);
    background: rgba(253, 250, 245, 0.92);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    border-top: 3px solid var(--primary-green);
    box-shadow: var(--shadow-lg);
    display: none;
    overflow: hidden;
    z-index: 1001;
}

.dropdown-overlay::before {
    content: '';
    position: absolute;
    right: 0;
    bottom: -30px;
    width: 200px;
    height: 200px;
    background: url('../img8/shibg.png') no-repeat center/contain;
    opacity: 0.06;
    pointer-events: none;
    z-index: 0;
}

.dropdown-container {
    position: relative;
    padding: 22px 26px;
    z-index: 1;
}

.dropdown-content {
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 28px;
    z-index: 1;
}

.link-grid {
    display: grid;
    grid-template-columns: repeat(2, 180px);
    gap: 0 20px;
}

/* 资质荣誉：三栏平均分布，各占三分之一（两栏子菜单 + 一栏标语） */
.dropdown-overlay.wide {
    min-width: 960px;
    /* 居中对齐"资质荣誉"一级菜单字样 */
    left: 50%;
    right: auto;
    transform: translateX(-50%);
}

.dropdown-overlay.wide .dropdown-content {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0 24px;
    align-items: center;
}

.dropdown-overlay.wide .link-grid {
    grid-column: 1 / 3;
    grid-template-columns: 1fr 1fr;
    /* 按列填充：第1栏3行、第2栏2行 */
    grid-auto-flow: column;
    grid-template-rows: repeat(3, auto);
    gap: 0 24px;
    flex-shrink: 0;
}

.dropdown-overlay.wide .slogan-box {
    grid-column: 3;
}

.dropdown-overlay.wide .link-item a {
    white-space: nowrap;
    padding: 6px 14px;
}

.link-item a {
    display: block;
    padding: 4px 12px;
    font-size: 14px;
    line-height: 1.15;
    color: var(--text-body);
    border-radius: 6px;
    text-align: center;
    transition: color 0.3s, background 0.3s;
}

.link-item a:hover {
    color: var(--primary-green);
    background: var(--pale-green);
}

.slogan-box {
    flex-shrink: 0;
    text-align: right;
    font-weight: 600;
    line-height: 1.4;
}

.slogan-box h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 400;
    color: #666666;
}

.slogan-box h2 {
    margin: 6px 0 0;
    font-size: 20px;
    font-weight: 700;
    color: var(--primary-green);
}

.main-nav a {
    display: block;
    padding: 12px 22px;
    font-size: 17px;
    font-weight: 700;
    color: var(--text-body);
    position: relative;
    border-radius: 4px;
}

.main-nav a::after {
    content: '';
    position: absolute;
    bottom: 4px;
    left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: calc(100% - 28px);
    height: 2px;
    background: var(--primary-green);
    transition: var(--transition);
}

.main-nav a:hover,
.main-nav a.active {
    color: var(--primary-green);
}

.main-nav a:hover::after,
.main-nav a.active::after {
    transform: translateX(-50%) scaleX(1);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.header-actions .btn-primary {
    padding: 12px 28px;
    font-size: 15px;
}

/* ========================
   移动端菜单按钮
======================== */
/* 移动端菜单按钮 */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 26px;
    height: 20px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
}

.mobile-menu-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--text-dark);
    transition: var(--transition);
    transform-origin: center;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}

@media (max-width: 1200px) {
    .main-nav a {
        padding: 10px 10px;
        font-size: 14px;
    }
}

@media (max-width: 992px) {
    .main-header .container {
        flex-wrap: wrap;
        width: 92%;
        padding: 10px 4%; /* 上下留白增加 header 第一行高度，logo 与三横菜单尺寸不变 */
        height: auto;
    }

    .logo-img-desktop {
        display: none;
    }

    .logo-text {
        display: none;
    }

    .logo .logo-img-mobile {
        display: block;
        width: auto;
        height: 40px;
        object-fit: contain;
        margin: 4px 0;
    }

    /* 移动端菜单：参照 aaa/er.asp —— header 内第二行深色面板，点击展开子菜单 */
    .main-nav {
        order: 3;
        position: static;
        flex: 0 0 auto;
        /* 100% 只到 container 内容区(约84%屏宽)，负边距抵消 container 的 4% 内边距，
           使面板与整个 header 齐宽(92%屏宽) */
        width: calc(100% + 8vw);
        height: auto;
        margin: 0.35rem -4vw 1.25rem; /* 上留白少一点，下方留白多一点，水平居中 */
        padding: 0.6rem 0.8rem 1rem;
        background: linear-gradient(135deg, var(--deep-green) 0%, var(--primary-green) 100%);
        border-radius: 14px;
        border-top: 1px solid rgba(255, 255, 255, 0.08);
        box-shadow: 0 10px 24px rgba(0, 40, 80, 0.25);
        overflow: visible;
        transform: none;
        transition: none;
        display: none;
    }

    .main-nav.active {
        display: block;
    }

    .main-nav ul {
        flex-direction: column;
        align-items: stretch;
        gap: 0.2rem;
        height: auto;
    }

    /* 关键：一级 li 桌面端是横向 flex，移动端必须改为纵向排列，
       否则展开的子菜单会出现在一级菜单的右侧而不是下方 */
    .main-nav > ul > li {
        display: block;
    }

    .main-nav a {
        width: 100%;
        padding: 0.7rem 1rem;
        font-size: 0.95rem;
        font-weight: 500;
        color: #e6f0ff;
        border-bottom: none;
        border-radius: 10px;
    }

    .main-nav a:hover {
        background: rgba(255, 255, 255, 0.15);
        color: #ffffff;
    }

    .main-nav a.active {
        background: #ffffff;
        color: var(--deep-green);
        font-weight: 600;
    }

    .main-nav a::after {
        display: none;
    }

    .has-dropdown > a {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 6px;
    }

    .has-dropdown > a::after {
        display: block;
        position: static;
        content: '';
        width: 10px;
        height: 10px;
        background: transparent;
        border-right: 2px solid rgba(255, 255, 255, 0.85);
        border-bottom: 2px solid rgba(255, 255, 255, 0.85);
        transform: rotate(45deg);
        transition: transform 0.3s;
        flex-shrink: 0;
        margin-right: 2px;
    }

    .has-dropdown.open > a::after {
        transform: rotate(225deg);
    }

    .mobile-menu-toggle {
        display: flex;
    }

    .header-actions .btn-primary {
        display: none;
    }

    .main-nav li.has-dropdown:hover .dropdown-overlay {
        display: none;
    }

    .dropdown-overlay {
        position: static;
        display: none;
        width: auto;
        min-width: 0;
        max-width: 100%;
        transform: none;
        background: rgba(255, 255, 255, 0.06);
        -webkit-backdrop-filter: none;
        backdrop-filter: none;
        border: none;
        border-top: none;
        border-radius: 10px;
        margin: 4px 0 4px 0.8rem;
        box-shadow: none;
        overflow: visible;
        z-index: auto;
    }

    .dropdown-overlay.wide {
        min-width: 0;
        left: auto;
        right: auto;
        transform: none;
    }

    .dropdown-overlay.wide .dropdown-content {
        display: block;
    }

    .dropdown-overlay.wide .link-grid {
        display: block;
        grid-template-columns: none;
        grid-auto-flow: row;
        grid-template-rows: none;
        grid-column: auto;
        gap: 0;
    }

    .dropdown-overlay.wide .slogan-box {
        grid-column: auto;
    }

    .dropdown-overlay.wide .link-item a {
        white-space: normal;
    }

    .main-nav li.has-dropdown.open > .dropdown-overlay {
        display: block;
    }

    .dropdown-overlay::before {
        display: none;
    }

    .dropdown-container {
        position: static;
        max-width: 100%;
        padding: 0.3rem 0;
    }

    .dropdown-content {
        display: block;
        gap: 0;
    }

    .link-grid {
        display: block;
        gap: 0;
    }

    .link-item a {
        padding: 0.55rem 0.9rem;
        font-size: 0.85rem;
        color: #dbe9ff;
        background: transparent;
        border-radius: 8px;
        text-align: left;
        line-height: 1.4;
    }

    .link-item a:hover {
        background: rgba(255, 255, 255, 0.12);
        color: #ffffff;
        padding-left: 1rem;
    }

    .slogan-box {
        display: none;
    }
}

@media (max-width: 768px) {
    .top-bar {
        display: none;
    }

    .top-bar .container {
        flex-direction: column;
        gap: 6px;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .logo {
        gap: 8px;
    }

    .logo-text h1 {
        font-size: 18px;
    }

    .logo img {
        width: 80px;
        height: auto;
    }
}
