/* ========================================
   EnSoul 文章排版样式
   嫩绿色科技感风格
   ======================================== */

/* 基础排版 */
.article-content,
.entry-content,
.single-post .post-content {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
    font-size: 17px;
    line-height: 1.9;
    color: #2d3748;
    letter-spacing: 0.02em;
}

/* 段落 */
.article-content p,
.entry-content p {
    margin-bottom: 1.8em;
    text-align: justify;
}



/* 标题样式 */
.article-content h1,
.entry-content h1 {
    font-size: 32px;
    font-weight: 800;
    color: #1a202c;
    margin: 48px 0 24px;
    position: relative;
    padding-bottom: 16px;
}

.article-content h1::after,
.entry-content h1::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, #4f46e5, #818cf8);
    border-radius: 2px;
}

.article-content h2,
.entry-content h2 {
    font-size: 26px;
    font-weight: 700;
    color: #1a202c;
    margin: 40px 0 20px;
    padding-left: 16px;
    border-left: 4px solid #4f46e5;
    position: relative;
}

.article-content h2::before,
.entry-content h2::before {
    content: '';
    position: absolute;
    left: -4px;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 28px;
    background: linear-gradient(180deg, #4f46e5, #818cf8);
    border-radius: 2px;
}

.article-content h3,
.entry-content h3 {
    font-size: 21px;
    font-weight: 600;
    color: #2d3748;
    margin: 32px 0 16px;
    display: flex;
    align-items: center;
}

.article-content h3::before,
.entry-content h3::before {
    content: '▸';
    color: #4f46e5;
    margin-right: 8px;
    font-size: 18px;
}

.article-content h4,
.entry-content h4 {
    font-size: 18px;
    font-weight: 600;
    color: #4a5568;
    margin: 24px 0 12px;
}

/* 强调文本 */
.article-content strong,
.entry-content strong {
    color: #7c3aed;
    font-weight: 700;
}

.article-content em,
.entry-content em {
    color: #4a5568;
    font-style: italic;
}

/* 链接样式 */
.article-content a,
.entry-content a {
    color: #4f46e5;
    text-decoration: none;
    border-bottom: 1px solid rgba(79, 70, 229, 0.3);
    transition: all 0.2s ease;
}

.article-content a:hover,
.entry-content a:hover {
    color: #7c3aed;
    border-bottom-color: #7c3aed;
}

/* 引用块 */
.article-content blockquote,
.entry-content blockquote {
    background: linear-gradient(135deg, #f5f3ff 0%, #ede9fe 100%);
    border-left: 4px solid #4f46e5;
    padding: 24px 28px;
    margin: 32px 0;
    border-radius: 0 12px 12px 0;
    font-style: italic;
    color: #5b21b6;
    position: relative;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.08);
}

.article-content blockquote::before,
.entry-content blockquote::before {
    content: '"';
    position: absolute;
    top: -10px;
    left: 16px;
    font-size: 64px;
    color: #4f46e5;
    opacity: 0.3;
    font-family: Georgia, serif;
}

.article-content blockquote p,
.entry-content blockquote p {
    margin-bottom: 0;
    color: inherit;
}

/* 列表样式 */
.article-content ul,
.entry-content ul,
.article-content ol,
.entry-content ol {
    margin: 24px 0;
    padding-left: 32px;
}

.article-content li,
.entry-content li {
    margin-bottom: 12px;
    position: relative;
}

.article-content ul li::marker,
.entry-content ul li::marker {
    color: #4f46e5;
}

.article-content ol li::marker,
.entry-content ol li::marker {
    color: #4f46e5;
    font-weight: 700;
}

/* 科技卡片组件 */
.article-content .tech-card,
.entry-content .tech-card,
.article-content .wp-block-group.tech-card {
    background: linear-gradient(135deg, #f5f3ff 0%, #ffffff 100%);
    border: 1px solid #ddd6fe;
    border-radius: 16px;
    padding: 28px;
    margin: 32px 0;
    box-shadow: 0 4px 20px rgba(79, 70, 229, 0.1);
    position: relative;
    overflow: hidden;
}

.article-content .tech-card::before,
.entry-content .tech-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #4f46e5, #818cf8, #a5b4fc);
}

.article-content .tech-card h4,
.entry-content .tech-card h4 {
    color: #7c3aed;
    margin-top: 0;
    margin-bottom: 16px;
}

/* 高亮信息框 */
.article-content .highlight-box,
.entry-content .highlight-box {
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
    color: white;
    padding: 24px 28px;
    border-radius: 12px;
    margin: 32px 0;
    box-shadow: 0 8px 24px rgba(79, 70, 229, 0.3);
    position: relative;
    overflow: hidden;
}

.article-content .highlight-box::after,
.entry-content .highlight-box::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    border-radius: 50%;
}

.article-content .highlight-box h4,
.entry-content .highlight-box h4 {
    color: white;
    margin-top: 0;
}

.article-content .highlight-box a,
.entry-content .highlight-box a {
    color: #ede9fe;
    border-bottom-color: rgba(220, 252, 231, 0.5);
}

/* 警告/提示框 */
.article-content .info-box,
.entry-content .info-box {
    background: #f5f3ff;
    border: 1px solid #ddd6fe;
    border-radius: 12px;
    padding: 20px 24px;
    margin: 24px 0;
    position: relative;
    padding-left: 56px;
}

.article-content .info-box::before,
.entry-content .info-box::before {
    content: '💡';
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 24px;
}

/* 代码块 */
.article-content code,
.entry-content code {
    background: #f1f5f9;
    color: #7c3aed;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.9em;
    font-family: 'Fira Code', 'Monaco', 'Consolas', monospace;
}

.article-content pre,
.entry-content pre {
    background: #1e293b;
    color: #e2e8f0;
    padding: 20px 24px;
    border-radius: 12px;
    overflow-x: auto;
    margin: 24px 0;
    border: 1px solid #334155;
}

.article-content pre code,
.entry-content pre code {
    background: transparent;
    color: #e2e8f0;
    padding: 0;
}

/* 表格样式 */
.article-content table,
.entry-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 28px 0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.article-content th,
.entry-content th {
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
    color: white;
    font-weight: 600;
    padding: 16px 20px;
    text-align: left;
}

.article-content td,
.entry-content td {
    padding: 14px 20px;
    border-bottom: 1px solid #e2e8f0;
}

.article-content tr:nth-child(even),
.entry-content tr:nth-child(even) {
    background: #f8fafc;
}

.article-content tr:hover,
.entry-content tr:hover {
    background: #f5f3ff;
}

/* 分割线 */
.article-content hr,
.entry-content hr {
    border: none;
    height: 1px;
    background: linear-gradient(90deg, transparent, #4f46e5, transparent);
    margin: 40px 0;
}

/* 图片样式 */
.article-content img,
.entry-content img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    margin: 24px 0;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

.article-content figcaption,
.entry-content figcaption {
    text-align: center;
    color: #64748b;
    font-size: 14px;
    margin-top: -16px;
    margin-bottom: 24px;
}

/* 文章结尾署名区 */
.article-content .article-footer,
.entry-content .article-footer {
    background: linear-gradient(135deg, #f5f3ff 0%, #ede9fe 100%);
    border-radius: 16px;
    padding: 32px;
    margin-top: 48px;
    text-align: center;
    border: 1px solid #ddd6fe;
}

.article-content .article-footer p,
.entry-content .article-footer p {
    margin-bottom: 16px;
    color: #5b21b6;
}

.article-content .article-footer a,
.entry-content .article-footer a {
    display: inline-block;
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
    color: white;
    padding: 12px 32px;
    border-radius: 24px;
    text-decoration: none;
    font-weight: 600;
    border: none;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
    transition: all 0.3s ease;
}

.article-content .article-footer a:hover,
.entry-content .article-footer a:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(79, 70, 229, 0.4);
}

/* 响应式调整 */
@media (max-width: 768px) {
    .article-content,
    .entry-content {
        font-size: 16px;
        line-height: 1.8;
    }
    
    .article-content h2,
    .entry-content h2 {
        font-size: 22px;
    }
    
    .article-content h3,
    .entry-content h3 {
        font-size: 19px;
    }
    
    .article-content blockquote,
    .entry-content blockquote {
        padding: 20px 24px;
    }
    
    .article-content .highlight-box,
    .entry-content .highlight-box {
        padding: 20px 24px;
    }
}

/* 打印样式 */
@media print {
    .article-content a,
    .entry-content a {
        color: #7c3aed;
        border-bottom: none;
    }
    
    .article-content .highlight-box,
    .entry-content .highlight-box {
        background: #f5f3ff;
        color: #5b21b6;
        border: 2px solid #4f46e5;
    }
}

/* 强制取消首字下沉效果 */
.article-content p:first-of-type::first-letter,
.entry-content p:first-of-type::first-letter,
.post-content p:first-of-type::first-letter,
.single-post .post-content p:first-of-type::first-letter,
.page-content p:first-of-type::first-letter,
p:first-of-type::first-letter {
    font-size: inherit !important;
    font-weight: inherit !important;
    float: none !important;
    line-height: inherit !important;
    margin-right: 0 !important;
    color: inherit !important;
    text-shadow: none !important;
    display: inline !important;
}
