/* ==========================================================================
   EazyPCB Modern Theme - 现代化样式
   ========================================================================== */

/* 页头样式 */
.site-header {
    position: fixed !important;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 50;
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    min-height: 64px;
    transition: all 0.3s ease;
}

/* 为页面内容添加顶部边距，避免被固定导航遮挡 */
body {
    padding-top: 64px;
}

/* 滚动时的导航效果 */
.site-header.scrolled {
    background: rgba(255, 255, 255, 0.98) !important;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

/* Logo字体样式 */
.site-header .wp-block-site-title a {
    font-family: cursive, "Pacifico", sans-serif;
    text-decoration: none;
}

.site-logo img {
    border-radius: 50%;
}

.main-navigation .wp-block-navigation__submenu-container {
    background: var(--wp--preset--color--base);
    border: 1px solid var(--wp--preset--color--light-green);
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    min-width: 200px;
}

.main-navigation .wp-block-navigation-item a {
    position: relative;
    padding: 0.5rem 0;
    transition: all 0.3s ease;
    font-weight: 500;
    font-size: 1rem;
    text-decoration: none;
    color: #374151;
}

.main-navigation .wp-block-navigation-item a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--wp--preset--color--secondary);
    transition: width 0.3s ease;
}

.main-navigation .wp-block-navigation-item a:hover {
    color: var(--wp--preset--color--primary) !important;
}

.main-navigation .wp-block-navigation-item a:hover::after,
.main-navigation .wp-block-navigation-item.current-menu-item a::after {
    width: 100%;
}

/* 页头按钮样式 */
.header-actions .wp-block-button__link {
    font-weight: 500;
    transition: all 0.3s ease;
    font-size: 0.875rem;
    border: none;
}

.lang-switcher .wp-block-button__link {
    background: #f3f4f6 !important;
    color: #374151 !important;
}

.lang-switcher .wp-block-button__link:hover {
    background: #e5e7eb !important;
}

.header-cta-btn .wp-block-button__link {
    background: var(--wp--preset--color--primary) !important;
    color: white !important;
}

.header-cta-btn .wp-block-button__link:hover {
    opacity: 0.9;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(26, 95, 122, 0.3);
}

/* 页脚样式 */
.site-footer {
    background: #1f2937 !important;
    color: white;
}

.site-footer .wp-block-group.alignwide {
    max-width: 1280px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 1rem;
    padding-right: 1rem;
}

.site-footer .wp-block-columns {
    margin-bottom: 0;
    justify-content: space-between;
    align-items: flex-start;
    gap: 2rem;
}

.site-footer .wp-block-column {
    margin-bottom: 0;
    flex: 1;
    text-align: left;
}

.footer-description {
    color: #9ca3af !important;
    line-height: 1.6;
    max-width: 300px;
}

.footer-menu {
    list-style: none;
    margin: 0;
    padding: 0;
}

.footer-menu li {
    padding: 0.375rem 0;
    transition: all 0.3s ease;
}

.footer-menu li a {
    color: #9ca3af !important;
    text-decoration: none;
    transition: color 0.3s ease;
    display: block;
}

.footer-menu li a:hover {
    color: white !important;
}

.site-footer .wp-block-social-links {
    justify-content: flex-start;
    margin-top: 1.5rem;
}

.site-footer .wp-block-social-links .wp-block-social-link a {
    transition: all 0.3s ease;
    border-radius: 50%;
    color: #9ca3af !important;
    width: 2.5rem;
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.site-footer .wp-block-social-links .wp-block-social-link a:hover {
    color: white !important;
    transform: scale(1.1);
}

/* 页脚版权区域 */
.footer-copyright {
    color: #9ca3af !important;
    text-align: center;
    margin: 0;
    width: 100%;
}

.site-footer .wp-block-group:last-child .wp-block-group.alignwide {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

/* 环保按钮样式 */
.wp-block-button.is-style-eco-button .wp-block-button__link {
    background: linear-gradient(135deg, var(--wp--preset--color--primary), var(--wp--preset--color--secondary));
    border-radius: 25px;
    padding: 12px 24px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

.wp-block-button.is-style-eco-button .wp-block-button__link:hover {
    background: linear-gradient(135deg, var(--wp--preset--color--secondary), var(--wp--preset--color--accent));
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(21, 87, 36, 0.3);
}

/* 环保卡片样式 */
.wp-block-group.is-style-eco-card {
    background: var(--wp--preset--color--light-gray);
    border: 2px solid var(--wp--preset--color--light-green);
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.wp-block-group.is-style-eco-card:hover {
    border-color: var(--wp--preset--color--accent);
    box-shadow: 0 8px 20px rgba(21, 87, 36, 0.15);
    transform: translateY(-3px);
}

/* 页面卡片样式 */
.post-card {
    transition: all 0.3s ease;
    border: 1px solid var(--wp--preset--color--light-green);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    overflow: hidden;
}

.post-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(21, 87, 36, 0.15);
    border-color: var(--wp--preset--color--accent);
}

/* 现代化卡片效果 */
.card-hover {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card-hover:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* 通用按钮样式 */
.wp-block-button__link {
    border-radius: 4px !important;
    transition: all 0.3s ease;
    font-weight: 500;
}

/* 页面内容区域 */
.wp-block-group.is-style-modern-card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    padding: 2rem;
    transition: all 0.3s ease;
}

.wp-block-group.is-style-modern-card:hover {
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    transform: translateY(-2px);
}

/* 响应式调整 */
@media (max-width: 768px) {
    /* 页头响应式 */
    body {
        padding-top: 70px;
    }
    
    .site-header .wp-block-group.alignwide {
        flex-wrap: wrap;
        padding-left: 1rem;
        padding-right: 1rem;
        min-height: 70px;
    }
    
    .main-navigation-wrapper {
        order: 3;
        width: 100%;
        margin-top: 1rem;
        justify-content: center !important;
    }
    
    .header-actions {
        order: 2;
        gap: 0.5rem;
    }
    
    .main-navigation .wp-block-navigation-item a {
        font-size: 0.875rem;
        padding: 0.5rem 0;
        margin: 0 0.5rem;
    }
    
    .header-actions .wp-block-button__link {
        font-size: 0.8rem;
        padding: 0.5rem 1rem !important;
    }
    
    /* 页脚响应式 */
    .site-footer .wp-block-columns {
        flex-direction: column;
        gap: 2rem !important;
        text-align: center;
    }
    
    .site-footer .wp-block-column {
        margin-bottom: 1.5rem;
        text-align: center;
        flex: none;
    }
    
    .footer-description {
        max-width: none;
        text-align: center;
        margin: 0 auto;
    }
    
    .site-footer .wp-block-social-links {
        justify-content: center;
        margin-top: 1rem;
    }
    
    .footer-menu {
        text-align: center;
    }
    
    .site-footer .wp-block-group.alignwide {
        padding-left: 1.5rem;
        padding-right: 1.5rem;
    }
}

/* 滚动行为优化 */
html {
    scroll-behavior: smooth;
}

/* 选择文本样式 */
::selection {
    background: var(--wp--preset--color--light-green);
    color: var(--wp--preset--color--primary);
}

/* 加载动画 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.post-card,
.wp-block-group.is-style-eco-card {
    animation: fadeInUp 0.6s ease-out;
}

/* 聚焦样式 */
.wp-block-button__link:focus,
.wp-block-navigation-item a:focus {
    outline: 2px solid var(--wp--preset--color--accent);
    outline-offset: 2px;
}

/* 打印样式 */
@media print {
    .site-header,
    .site-footer,
    .wp-block-button {
        display: none;
    }
}
