/* =====================================================================
 * blog-detail.css — 博客详情页样式
 * 
 * 【代码规范】
 * 1. 不重写 h1/h2/h3 标题元素（由 common.css 统一定义）
 * 2. 优先复用 common.css 工具类
 * 3. 本文件只写博客详情页独有的样式
 * ===================================================================== */

.blog-detail {
  margin-top: 85px;
  background: #f2f2f2;
}

/* ==================== Breadcrumb ==================== */
.breadcrumb-section {
  background: #f8f8f8;
  padding: 20px 0;
}

.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: #666;
}

.breadcrumb a {
  color: #666;
  text-decoration: none;
  transition: color 0.3s ease;
}

.breadcrumb a:hover {
  color: var(--primary);
}

.breadcrumb .separator {
  color: #ccc;
}

.breadcrumb .current {
  color: #1a1a1a;
  font-weight: 500;
}

/* ==================== Article Layout ==================== */
.article-container.section-container {
  padding: 20px 0 60px;
}

.article-layout {
  display: grid;
  grid-template-columns: 1fr 350px;
  gap: 20px;
}

/* ==================== Main Article ==================== */
.article-main {
  min-width: 0;
}

/* ==================== Advertisement Banner ==================== */
.ad-banner-container{
    background-color: #fff;
    padding: 15px;
}
.ad-banner {
  position: relative;
  display: flex;
  /* min-height: 180px; */
  gap: 0;
}

.ad-banner-footer{
    display: flex;
}

.ad-left {
  flex: 1;
  background:rgba(0, 0, 0, 0.5) url('/img/banner/cta.webp');
  background-size: cover;
  background-position: center;
  background-blend-mode: multiply;
  padding: 30px;
  color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
  clip-path: polygon(0 0, 100%, 0, 100% 100%, 0 100%);
}

.ad-title {
  font-size: 20px;
  font-weight: 600;
  line-height: 1.5;
  /*text-transform: uppercase;*/
  color: #fff;
}

.ad-features {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  gap: 30px;
  background-color: var(--primary);
  padding: 15px 20px;
}

.ad-features li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: #fff;
}

.ad-features i {
  color: #ffd700;
  font-size: 16px;
}

.ad-right {
  flex: 1;
  background:rgba(66, 74, 210, 0.4) url('/img/banner/banner_01.webp');
  background-size: cover;
  background-position: center;
  background-blend-mode: multiply;
  padding: 30px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  position: relative;
  clip-path: polygon(40px 0, 100% 0, 100% 100%, 0 100%);
  margin-left: -40px;
}

.ad-right .ad-title {
    margin-left: 5%;
}

.ad-contact {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 20px;
}

.contact-label {
  font-size: 14px;
  color: #666;
  font-weight: 500;
}

.contact-phone {
  font-size: 28px;
  font-weight: 700;
  color: var(--primary);
  text-decoration: none;
  letter-spacing: 1px;
  transition: all 0.3s ease;
}

.contact-phone:hover {
  color: #3640b8;
  transform: scale(1.05);
}

.rfq-container{
    background-color:var(--accent);
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.rfq-container a{
    color: #fff;
    text-decoration: none;
    text-transform: uppercase;

}

.rfq-container a:hover{
    text-decoration: underline;
}

.rfq-btn {
  display: inline-flex;
  align-items: center;
  padding: 12px 28px;
  background: var(--primary);
  color: #fff;
  text-decoration: none;
  border-radius: 6px;
  font-weight: 600;
  font-size: 15px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(66, 74, 210, 0.3);
}

.rfq-btn:hover {
  background: #3640b8;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(66, 74, 210, 0.4);
}


.contact-phone:hover {
  color: #3640b8;
  transform: scale(1.05);
}

.article{
    background-color: #fff;
    padding: 30px 15px;
    margin-top: 20px;
}

.article-header {
  margin-bottom: 30px;
  padding-bottom: 20px;
  border-bottom: 1px solid #ccc;
}

.article-header h1{
    font-size: 32px;
    line-height: 36px;
}

.article-meta-top {
  display: flex;
  align-items: center;
  gap: 24px;
  justify-content: space-between;
  margin-top: 20px;
  font-size: 14px;
  color: #666;
}

.article-meta-top i {
  color: var(--primary);
  margin-right: 6px;
}

/* 只调整 h1 的颜色，不重写字号 */
.article-header h1 {
  color: #1a1a1a;
  margin-bottom: 0;
}

.article-featured-image {
  width: 100%;
  margin-bottom: 40px;
  border-radius: 12px;
  overflow: hidden;
}

.article-featured-image img {
  width: 100%;
  height: auto;
  display: block;
}

.article-content {
  font-size: 16px;
  line-height: 1.8;
  color: #333;
}

.article-content .lead-paragraph {
  font-size: 18px;
  line-height: 1.7;
  color: #555;
  margin-bottom: 30px;
  padding-left: 20px;
  border-left: 4px solid var(--primary);
}

.article-content h2 {
  color: #1a1a1a;
  margin-top: 40px;
  margin-bottom: 20px;
  padding-bottom: 10px;
  border-bottom: 2px solid #f0f0f0;
  font-size: 28px !important;
}

.article-content h3 {
  color: #1a1a1a;
  margin-top: 30px;
  margin-bottom: 15px;
}

.article-content p {
  margin-bottom: 20px;
}

.article-content ul,
.article-content ol {
  margin-bottom: 20px;
  padding-left: 30px;
}

.article-content li {
  margin-bottom: 10px;
}

.article-content strong {
  color: #1a1a1a;
  font-weight: 600;
}

.article-content a {
  color: var(--primary);
  text-decoration: underline;
  transition: color 0.3s ease;
}

.article-content a:hover {
  color: #3640b8;
}

/* ==================== Article Footer ==================== */
.article-footer {
  margin-top: 50px;
  padding-top: 30px;
  border-top: 2px solid #f0f0f0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}

.article-tags {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.tags-label {
  font-weight: 600;
  color: #1a1a1a;
}

.tag {
  display: inline-block;
  padding: 6px 16px;
  background: #f5f5f5;
  border-radius: 20px;
  font-size: 14px;
  color: #666;
  text-decoration: none;
  transition: all 0.3s ease;
}

.tag:hover {
  background: var(--primary);
  color: #fff;
}

.article-share {
  display: flex;
  align-items: center;
  gap: 12px;
}

.share-label {
  font-weight: 600;
  color: #1a1a1a;
}

.share-btn {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f5f5f5;
  border-radius: 50%;
  color: #666;
  text-decoration: none;
  transition: all 0.3s ease;
}

.share-btn:hover {
  background: var(--primary);
  color: #fff;
  transform: translateY(-2px);
}

/* ==================== Author Bio ==================== */
.author-bio {
  margin-top: 50px;
  padding: 30px;
  background: #f8f8f8;
  border-radius: 12px;
  display: flex;
  gap: 24px;
}

.author-bio .author-avatar {
  width: 80px;
  height: 80px;
  border-radius: 8px;
  object-fit: contain;
  flex-shrink: 0;
  background: #fff;
}

.author-bio .author-info {
  flex: 1;
}

/* 只调整 h3 的颜色和间距，不重写字号 */
.author-bio .author-name {
  color: #1a1a1a;
  margin-bottom: 5px;
}

.author-bio .author-title {
  font-size: 14px;
  color: var(--primary);
  margin-bottom: 10px;
}

.author-bio .author-description {
  font-size: 15px;
  line-height: 1.6;
  color: #666;
  margin: 0;
}

/* ==================== Related Articles ==================== */
.related-articles {
    margin-top: 20px;
  background-color: #fff;
  padding: 30px 15px;
}

/* 只调整 h2 的颜色，不重写字号 */
.related-articles h2 {
  color: #1a1a1a;
  margin-bottom: 30px;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
}

.related-card {
  background: #fff;
  border: 1px solid #e5e5e5;
  border-radius: 5px;
  overflow: hidden;
  transition: all 0.3s ease;
}


.related-card a {
  display: block;
  text-decoration: none;
}

.related-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
}

/* 只调整 h3 的颜色，不重写字号 */
.related-card h3 {
  color: var(--text-dark);
  padding: 15px;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

.related-card h3:hover{
    color: var(--primary);
}

.related-card p {
  font-size: 16px;
    padding: 15px;
  color: var(--text-dark);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

.article-sidebar {
  align-self: stretch;
}

.sidebar-widget {
  background: #fff;
  padding: 15px;
  margin-bottom: 20px;
}

/* 只让联系表单 widget 固定 */
.contact-widget {
  position: sticky;
  top: 100px;
  background-color: #fff;
}

/* 只调整 widget-title 的颜色，不重写字号 */
.widget-title {
  color: #1a1a1a;
  margin-bottom: 20px;
  padding-bottom: 15px;
  border-bottom: 2px solid #e5e5e5;
}

/* Table of Contents */
.toc-nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.toc-nav li {
  margin-bottom: 12px;
}

.toc-nav a {
  display: block;
  color: #666;
  text-decoration: none;
  font-size: 15px;
  padding: 8px 12px;
  border-radius: 6px;
  transition: all 0.3s ease;
}

.toc-nav a:hover {
  background: #fff;
  color: var(--primary);
  padding-left: 16px;
}

table {
  width: 100%;
  border-collapse: collapse;
  background-color: #ffffff;
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 10px;
  text-align: left;

}

table th,
table td {
  padding: 15px;
  text-align: left;
  border: 1px solid #e1e8ed;
}

table th {
  background-color: var(--primary);
  color: #ffffff;
  font-weight: 600;
}

table tr:nth-child(even) {
  background-color: #f8f9fa;
}

/* About Widget */
.about-description {
  margin-bottom: 20px;
}

.widget-btn {
  width: 100%;
  display: inline-block;
  padding: 10px 24px;
  background: var(--primary);
  color: #fff;
  text-decoration: none;
  border-radius: 6px;
  font-weight: 500;
  transition: all 0.3s ease;
  text-align: center;
}

.widget-btn:hover {
  background: var(--accent);
}

/* Contact Form Widget */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-group {
  display: flex;
  flex-direction: column;
}

.form-group label {
  font-size: 14px;
  font-weight: 500;
  color: #1a1a1a;
  margin-bottom: 8px;
}

.required {
  color: #e53e3e;
}

.form-group input,
.form-group textarea {
  padding: 8px 10px;
  border: 1px solid #e5e5e5;
  border-radius: 6px;
  font-size: 15px;
  transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(66, 74, 210, 0.1);
}

.form-group textarea {
  resize: vertical;
  min-height: 100px;
}

.submit-btn {
  padding: 12px 24px;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 6px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.submit-btn:hover {
  background: #3640b8;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(66, 74, 210, 0.3);
}
img{
    width:100%;
}
/* ==================== Responsive Design ==================== */

/* Tablet */
@media (max-width: 1024px) {
  .article-layout {
    grid-template-columns: 1fr 320px;
    gap: 20px;
  }

  .related-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }

  .ad-features {
    gap: 20px;
    font-size: 13px;
  }
}

/* Mobile */
@media (max-width: 768px) {
  .blog-detail {
    margin-top: 60px;
  }

  .breadcrumb-section {
    padding: 15px 0;
  }

  .article-container.section-container {
    padding: 20px 0 40px;
  }

  .article-layout {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .article-sidebar {
    position: static;
  }

  /* 广告横幅优化 */
  .ad-banner-container {
    padding: 10px;
  }

  .ad-banner {
    flex-direction: column;
    min-height: auto;
  }

  .ad-left,
  .ad-right {
    padding: 20px 15px;
    clip-path: none;
    margin-left: 0;
  }

  .ad-right .ad-title {
    margin-left: 0;
  }

  .ad-title {
    font-size: 16px;
    line-height: 1.4;
  }

  .ad-banner-footer {
    flex-direction: column;
    gap: 0;
  }

  .ad-features {
    flex-direction: column;
    gap: 12px;
    padding: 15px;
  }

  .ad-features li {
    font-size: 13px;
  }

  .rfq-container {
    padding: 15px;
  }

  .rfq-container a {
    font-size: 14px;
  }

  .contact-phone {
    font-size: 24px;
  }

  /* 文章内容优化 */
  .article {
    padding: 20px 15px;
    margin-top: 10px;
  }

  .article-header {
    margin-bottom: 20px;
    padding-bottom: 15px;
  }

  .article-header h1 {
    font-size: 24px;
    line-height: 1.3;
  }

  .article-meta-top {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    font-size: 13px;
  }

  .article-content {
    font-size: 15px;
    line-height: 1.7;
  }

  .article-content .lead-paragraph {
    font-size: 16px;
    padding-left: 15px;
    margin-bottom: 20px;
  }

  .article-content h2 {
    font-size: 20px;
    margin-top: 30px;
    margin-bottom: 15px;
  }

  .article-content h3 {
    font-size: 18px;
    margin-top: 20px;
    margin-bottom: 12px;
  }

  .article-content p {
    margin-bottom: 15px;
  }

  .article-content ul,
  .article-content ol {
    padding-left: 20px;
    margin-bottom: 15px;
  }

  .article-content li {
    margin-bottom: 8px;
  }

  /* 作者信息优化 */
  .author-bio {
    margin-top: 30px;
    padding: 20px 15px;
    flex-direction: column;
    gap: 15px;
    text-align: center;
  }

  .author-bio .author-avatar {
    width: 70px;
    height: 70px;
    margin: 0 auto;
  }

  .author-bio .author-name {
    font-size: 18px;
  }

  .author-bio .author-title {
    font-size: 13px;
  }

  .author-bio .author-description {
    font-size: 14px;
    text-align: left;
  }

  /* 相关文章优化 */
  .related-articles {
    margin-top: 10px;
    padding: 20px 15px;
  }

  .related-articles h2 {
    font-size: 20px;
    margin-bottom: 20px;
  }

  .related-grid {
    grid-template-columns: 1fr;
    gap: 15px;
  }

  .related-card img {
    height: 200px;
  }

  .related-card h3 {
    font-size: 16px;
    padding: 12px 15px;
  }

  .related-card p {
    font-size: 14px;
    padding: 0 15px 12px;
  }

  /* 侧边栏优化 */
  .sidebar-widget {
    padding: 20px 15px;
  }

  .contact-widget {
    position: static;
    top: auto;
  }

  .widget-title {
    font-size: 18px;
    margin-bottom: 15px;
    padding-bottom: 12px;
  }

  .about-description {
    font-size: 14px;
    margin-bottom: 15px;
  }

  .widget-btn {
    display: block;
    text-align: center;
    padding: 10px 20px;
  }

  /* 表单优化 */
  .contact-form {
    gap: 14px;
  }

  .form-group label {
    font-size: 13px;
  }

  .form-group input,
  .form-group textarea {
    padding: 10px 12px;
    font-size: 14px;
  }

  .submit-btn {
    padding: 12px 20px;
    font-size: 14px;
    width: 100%;
  }

  .article-footer {
    margin-top: 30px;
    padding-top: 20px;
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
  }

  .article-tags,
  .article-share {
    width: 100%;
  }

  .tag {
    font-size: 13px;
    padding: 5px 14px;
  }
}

@media (max-width: 480px) {
  /* 面包屑导航 */
  .breadcrumb {
    font-size: 12px;
    flex-wrap: wrap;
    gap: 6px;
  }

  .breadcrumb .current {
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  /* 广告横幅 */
  .ad-banner-container {
    padding: 8px;
  }

  .ad-left,
  .ad-right {
    padding: 15px 12px;
  }

  .ad-title {
    font-size: 14px;
  }

  .ad-features {
    padding: 12px;
    gap: 10px;
  }

  .ad-features li {
    font-size: 12px;
  }

  .ad-features i {
    font-size: 14px;
  }

  .rfq-container {
    padding: 12px;
  }

  .rfq-container a {
    font-size: 13px;
  }

  /* 文章主体 */
  .article {
    padding: 15px 12px;
  }

  .article-header h1 {
    font-size: 20px;
    line-height: 1.3;
  }

  .article-meta-top {
    font-size: 12px;
  }

  .article-content {
    font-size: 14px;
  }

  .article-content .lead-paragraph {
    font-size: 15px;
    padding-left: 12px;
    border-left-width: 3px;
  }

  .article-content h2 {
    font-size: 18px;
    margin-top: 25px;
    margin-bottom: 12px;
  }

  .article-content h3 {
    font-size: 16px;
    margin-top: 18px;
    margin-bottom: 10px;
  }

  .article-content ul,
  .article-content ol {
    padding-left: 18px;
  }

  /* 作者信息 */
  .author-bio {
    padding: 15px 12px;
  }

  .author-bio .author-avatar {
    width: 60px;
    height: 60px;
  }

  .author-bio .author-name {
    font-size: 16px;
  }

  .author-bio .author-description {
    font-size: 13px;
  }

  /* 相关文章 */
  .related-articles {
    padding: 15px 12px;
  }

  .related-articles h2 {
    font-size: 18px;
    margin-bottom: 15px;
  }

  .related-card img {
    height: 180px;
  }

  .related-card h3 {
    font-size: 15px;
    padding: 10px 12px;
  }

  .related-card p {
    font-size: 13px;
    padding: 0 12px 10px;
  }

  /* 侧边栏 */
  .sidebar-widget {
    padding: 15px 12px;
  }

  .widget-title {
    font-size: 16px;
  }

  .about-description {
    font-size: 13px;
  }

  .widget-btn {
    padding: 10px 18px;
    font-size: 14px;
  }

  /* 表单 */
  .form-group input,
  .form-group textarea {
    padding: 10px;
    font-size: 14px;
  }

  .form-group textarea {
    min-height: 90px;
  }

  .submit-btn {
    padding: 11px 18px;
  }

  /* 标签和分享 */
  .tag {
    font-size: 12px;
    padding: 4px 12px;
  }

  .share-btn {
    width: 32px;
    height: 32px;
    font-size: 14px;
  }
}

