/* DFM design guide page */

.dfm-hero {
  position: relative;
  min-height: 520px;
  display: flex;
  align-items: center;
  overflow: hidden;
  background: #0c1438;
}

.dfm-hero-bg {
  position: absolute;
  inset: 0;
  background-image: url("../images/材料指南/设计指南.png");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.dfm-hero .container {
  position: relative;
  z-index: 1;
  padding: 96px 24px 88px;
}

.dfm-hero-label {
  font-size: 15px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.92);
  margin-bottom: 16px;
}

.dfm-hero-title {
  font-size: clamp(28px, 3.8vw, 44px);
  font-weight: 700;
  line-height: 1.22;
  color: #ffffff;
  max-width: 820px;
}

.dfm-main {
  padding: 56px 0 88px;
  background: #f3f4f8;
}

.dfm-layout {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 40px;
  align-items: start;
}

.dfm-toc {
  position: sticky;
  top: 108px;
}

.dfm-toc-card {
  background: #ffffff;
  border-radius: 12px;
  padding: 24px 22px 26px;
  box-shadow: 0 4px 28px rgba(15, 23, 42, 0.08);
  border: 1px solid #eef1f6;
}

.dfm-toc-card h2 {
  font-size: 16px;
  font-weight: 700;
  color: #111111;
  margin-bottom: 16px;
}

.dfm-toc-nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.dfm-toc-link {
  display: block;
  padding: 8px 0;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.45;
  color: #94a3b8;
  text-decoration: none;
  transition: color 0.2s ease;
}

.dfm-toc-link:hover {
  color: #313695;
}

.dfm-toc-link.is-active {
  color: #ef7300;
}

.dfm-toc-link .dfm-section-num {
  color: inherit;
  margin-right: 4px;
}

.dfm-content {
  min-width: 0;
}

.dfm-section {
  padding-bottom: 48px;
  margin-bottom: 48px;
  border-bottom: 1px solid #e2e8f0;
}

.dfm-section:last-child {
  padding-bottom: 0;
  margin-bottom: 0;
  border-bottom: none;
}

.dfm-section-head {
  font-size: clamp(22px, 2.5vw, 28px);
  font-weight: 700;
  line-height: 1.35;
  color: #111111;
  margin-bottom: 20px;
}

.dfm-section-num {
  color: #ef7300;
  margin-right: 6px;
}

.dfm-section-body {
  font-size: 15px;
  color: #64748b;
  line-height: 1.8;
}

.dfm-section-body p {
  margin-bottom: 1.15em;
}

.dfm-section-body p:last-child {
  margin-bottom: 0;
}

.dfm-subtitle {
  margin-top: 28px;
  margin-bottom: 14px;
  font-size: 15px;
  font-weight: 700;
  color: #313695;
}

.dfm-subtitle:first-child {
  margin-top: 8px;
}

.dfm-key-points p {
  margin-bottom: 14px;
}

.dfm-key-points strong {
  color: #334155;
  font-weight: 700;
}

.dfm-table-wrap {
  margin-top: 8px;
  overflow-x: auto;
}

.dfm-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 14px;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid #e2e8f0;
}

.dfm-table thead th {
  padding: 14px 16px;
  text-align: left;
  font-weight: 600;
  color: #ffffff;
  background: #313695;
}

.dfm-table tbody td {
  padding: 14px 16px;
  color: #64748b;
  border-top: 1px solid #e8ecf2;
  vertical-align: top;
  line-height: 1.5;
}

.dfm-table tbody tr:nth-child(even) td {
  background: #f8fafc;
}

.dfm-table tbody tr:nth-child(odd) td {
  background: #ffffff;
}

.dfm-plain-list {
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
  font-size: 15px;
  color: #64748b;
  line-height: 1.75;
}

.dfm-plain-list li {
  margin-bottom: 6px;
}

.dfm-bullet-list {
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
  font-size: 15px;
  color: #64748b;
  line-height: 1.75;
}

.dfm-bullet-list li {
  position: relative;
  padding-left: 16px;
  margin-bottom: 8px;
}

.dfm-bullet-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #ef7300;
}

.dfm-square-list li::before {
  border-radius: 1px;
  width: 5px;
  height: 5px;
}

.dfm-callout-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 28px;
}

.dfm-callout {
  padding: 22px 20px;
  border-radius: 10px;
  border: 1px solid #e2e8f0;
  background: #ffffff;
}

.dfm-callout h4 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 12px;
}

.dfm-callout--do {
  border-color: #a7e3d0;
}

.dfm-callout--do h4 {
  color: #0d9488;
}

.dfm-callout--do .dfm-bullet-list li::before {
  background: #14b8a6;
}

.dfm-callout--avoid {
  border-color: #f5c4c4;
}

.dfm-callout--avoid h4 {
  color: #dc2626;
}

.dfm-callout--avoid .dfm-bullet-list li::before {
  background: #ef4444;
}

.dfm-callout .dfm-bullet-list {
  margin-top: 0;
}

.dfm-checklist li strong {
  color: #475569;
  font-weight: 600;
}

.dfm-checklist a {
  color: #313695;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.dfm-checklist a:hover {
  color: #ef7300;
}

@media (max-width: 1024px) {
  .dfm-layout {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .dfm-toc {
    position: static;
  }

  .dfm-toc-nav {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 8px 14px;
  }

  .dfm-callout-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .dfm-hero {
    margin-top: 72px;
    min-height: 440px;
  }

  .dfm-main {
    padding: 40px 0 64px;
  }
}
