/**
 * ESS Landing Page Styles
 * 产品介绍页面样式
 */

/* 隐藏WordPress主题的页面标题、日期和元信息 - 扩展选择器 */
body.page .entry-title,
body.page .page-title,
body.page .entry-meta,
body.page .post-meta,
body.page .entry-header,
body.page .page-header,
body.page article > header,
body.page .hentry > header,
body.page .posted-on,
body.page .byline,
body.page .cat-links,
body.page .tags-links,
body.page .entry-date,
body.page .author,
body.page .single-post-header,
body.page .article-header,
body.page .post-header,
body.page .content-header,
body.page .post-title,
body.page .article-title,
body.page time,
body.page .date,
body.page .meta,
body.page .post-date,
body.page .article-meta,
.ess-landing-active .entry-title,
.ess-landing-active .page-title,
.ess-landing-active .entry-meta,
.ess-landing-active .post-meta,
.ess-landing-active .entry-header,
.ess-landing-active .page-header,
.ess-landing-active article > header,
.ess-landing-active .posted-on,
.ess-landing-active .byline,
.ess-landing-active .entry-date,
.ess-landing-active .single-post-header,
.ess-landing-active .article-header,
.ess-landing-active .post-header,
.ess-landing-active time,
.ess-landing-active .date,
.ess-landing-active .meta,
.ess-landing-active .post-date,
.ess-landing-active .article-meta,
.ess-landing-active h1.entry-title,
.ess-landing-active h1.page-title,
.ess-landing-active h1.post-title,
.ess-landing-active .wp-block-post-title,
.ess-landing-active .wp-block-post-date,
.ess-landing-active .wp-block-post-author {
    display: none !important;
    visibility: hidden !important;
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
}

/* 注意：移除了过于激进的隐藏规则，避免意外隐藏页面内容 */

/* 确保WordPress内容容器可见 */
.ess-landing-active .entry-content,
.ess-landing-active .page-content,
.ess-landing-active .post-content,
.ess-landing-active article.page,
.ess-landing-active .type-page {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    overflow: visible !important;
    max-height: none !important;
    height: auto !important;
}

/* 容器重置 - 确保始终可见 */
#ess-landing-page {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #374151;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    background-color: #ffffff;
    min-height: 100vh;
}

/* 确保所有子元素也可见 */
#ess-landing-page * {
    visibility: visible;
}

#ess-landing-page section {
    display: block !important;
}

/* 确保Tailwind文字颜色类能正确覆盖 */
#ess-landing-page .text-white {
    color: #ffffff !important;
}

#ess-landing-page .text-gray-400 {
    color: #9ca3af !important;
}

#ess-landing-page .text-gray-600 {
    color: #4b5563 !important;
}

#ess-landing-page .text-gray-800 {
    color: #1f2937 !important;
}

#ess-landing-page *,
#ess-landing-page *::before,
#ess-landing-page *::after {
    box-sizing: border-box;
}

/* 重置WordPress主题可能的样式影响 */
#ess-landing-page h1,
#ess-landing-page h2,
#ess-landing-page h3,
#ess-landing-page h4,
#ess-landing-page h5,
#ess-landing-page h6 {
    margin: 0;
    padding: 0;
    font-weight: bold;
    line-height: 1.2;
}

#ess-landing-page p {
    margin: 0;
}

#ess-landing-page ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

#ess-landing-page a {
    text-decoration: none;
    color: inherit;
}

#ess-landing-page img {
    max-width: 100%;
    height: auto;
    vertical-align: middle;
}

/* 导航栏固定样式补充 */
#ess-navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
}

/* 模态框样式 */
.modal-backdrop {
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal-backdrop.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    transform: scale(0.9);
    opacity: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.modal-backdrop.active .modal-content {
    transform: scale(1);
    opacity: 1;
}

/* 图片放大效果 */
.image-zoom-container {
    cursor: zoom-in;
    transition: transform 0.3s ease;
    overflow: hidden;
}

.image-zoom-container:hover {
    transform: scale(1.02);
}

.image-zoom-container img {
    transition: transform 0.3s ease;
}

.image-zoom-container:hover img {
    transform: scale(1.05);
}

/* 功能卡片悬停效果 */
.feature-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
}

/* 电压等级徽章 */
.voltage-badge {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
    font-weight: 500;
    border-radius: 9999px;
    background-color: rgba(10, 92, 173, 0.1);
    color: #0A5CAD;
}

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

/* 选择框样式修复 */
#ess-landing-page select option {
    background-color: #0A5CAD;
    color: white;
}

/* 表单输入框聚焦样式 */
#ess-landing-page input:focus,
#ess-landing-page select:focus,
#ess-landing-page textarea:focus {
    outline: none;
}

/* 按钮悬停效果 */
#ess-landing-page .button-hover:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* 响应式调整 */
@media (max-width: 768px) {
    #ess-landing-page .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    #ess-navbar {
        padding: 0.5rem 0;
    }
}

/* 动画效果 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.6s ease forwards;
}

/* 旋转加载图标 */
.fa-spin {
    animation: fa-spin 1s infinite linear;
}

@keyframes fa-spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

/* 文字阴影 */
.text-shadow {
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* 背景模糊 */
.backdrop-blur {
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

/* 渐变背景修复 */
.bg-gradient-to-br {
    background-image: linear-gradient(to bottom right, var(--tw-gradient-stops));
}

.bg-gradient-to-r {
    background-image: linear-gradient(to right, var(--tw-gradient-stops));
}

/* 状态指示器样式 */
.license-status {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 3px;
    font-size: 12px;
}

.license-status.active {
    background: #d4edda;
    color: #155724;
}

.license-status.inactive {
    background: #f8d7da;
    color: #721c24;
}

/* 版本状态样式 */
.version-status {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 3px;
    font-size: 12px;
}

.version-status.active {
    background: #d4edda;
    color: #155724;
}

.version-status.inactive {
    background: #f8d7da;
    color: #721c24;
}

/* 版本更新记录时间轴样式 */
#ess-version-history {
    overflow: hidden;
}

#ess-version-history .space-y-8 > div {
    opacity: 0;
    animation: fadeInUp 0.6s ease forwards;
}

#ess-version-history .space-y-8 > div:nth-child(1) { animation-delay: 0.1s; }
#ess-version-history .space-y-8 > div:nth-child(2) { animation-delay: 0.2s; }
#ess-version-history .space-y-8 > div:nth-child(3) { animation-delay: 0.3s; }
#ess-version-history .space-y-8 > div:nth-child(4) { animation-delay: 0.4s; }
#ess-version-history .space-y-8 > div:nth-child(5) { animation-delay: 0.5s; }
#ess-version-history .space-y-8 > div:nth-child(n+6) { animation-delay: 0.6s; }

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

#ess-version-history .bg-white {
    transition: all 0.3s ease;
}

#ess-version-history .bg-white:hover {
    transform: translateY(-2px);
}

/* 版本标签动画 */
#ess-version-history .bg-primary {
    position: relative;
    overflow: hidden;
}

#ess-version-history .bg-primary::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    animation: shimmer 3s infinite;
}

@keyframes shimmer {
    0% { left: -100%; }
    50%, 100% { left: 100%; }
}

/* 时间轴节点脉冲动画 */
#ess-version-history .ring-4 {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.4);
    }
    50% {
        box-shadow: 0 0 0 8px rgba(99, 102, 241, 0);
    }
}
