/* Product page layout. Shared by every product; the content itself comes
   from the database as structured fields, never as HTML.
   Design tokens live in site.css — do not redeclare them here. */

/* Product page layout. Shared by every product; the content itself comes
   from the database as structured fields, never as HTML. */

.nfm-p * { box-sizing: border-box; margin: 0; padding: 0; font-family: 'Vazirmatn', Tahoma, Arial, sans-serif; }

.nfm-p { color: var(--text); line-height: 1.8; width: 100%; overflow-x: hidden; }

/* HERO BANNER */
.nfm-p-hero {
  position: relative;
  height: 320px;
  overflow: hidden;
  background: linear-gradient(135deg, #2a2839, #39364E);
}

@media(max-width:600px){ .nfm-p-hero { height: 220px; } }

.nfm-p-hero img {
  width: 100%; height: 100%; object-fit: cover; opacity: 0.35; display: block;
}

.nfm-p-hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to left, rgba(130,45,76,0.6) 0%, rgba(42,40,57,0.7) 100%);
  display: flex; align-items: center; padding: 0 40px;
}

@media(max-width:600px){ .nfm-p-hero-overlay { padding: 0 20px; } }

.nfm-p-breadcrumb { font-size: 0.8rem; color: rgba(255,255,255,0.6); margin-bottom: 10px; }

.nfm-p-breadcrumb a { color: rgba(255,255,255,0.6); text-decoration: none; }

.nfm-p-breadcrumb span { color: #d4789a; }

.nfm-p-hero h1 {
  font-size: clamp(1.6rem, 4vw, 2.8rem);
  font-weight: 900; color: #fff;
  text-shadow: 0 2px 20px rgba(0,0,0,0.3);
}

.nfm-p-hero-tag {
  display: inline-block; margin-top: 10px;
  background: rgba(130,45,76,0.7); color: #ffd0e0;
  font-size: 0.8rem; padding: 4px 14px; border-radius: 20px;
  border: 1px solid rgba(255,255,255,0.2);
}

/* LAYOUT */
.nfm-p-body { max-width: 1060px; margin: 0 auto; padding: 50px 20px; }

.nfm-p-grid { display: grid; grid-template-columns: 1fr 340px; gap: 40px; }

@media(max-width:860px){ .nfm-p-grid { grid-template-columns: 1fr; } }

/* MAIN CONTENT */
.nfm-p-main {}

.nfm-p-intro {
  background: var(--wine-bg); border-inline-start: 4px solid var(--wine);
  border-start-start-radius: 12px; border-end-start-radius: 12px; border-start-end-radius: 0; border-end-end-radius: 0; padding: 20px 24px;
  color: var(--body); font-size: 1rem; line-height: 2;
  margin-bottom: 36px;
}

.nfm-p-section { margin-bottom: 36px; }

.nfm-p-section h2 {
  font-size: 1.2rem; font-weight: 800; color: var(--navy);
  margin-bottom: 14px; padding-bottom: 10px;
  border-bottom: 2px solid var(--line);
  display: flex; align-items: center; gap: 10px;
}

.nfm-p-section h2::before {
  content: ''; display: block;
  width: 4px; height: 20px; background: var(--wine);
  border-radius: 2px; flex-shrink: 0;
}

.nfm-p-section p { color: var(--muted); font-size: 0.95rem; line-height: 2.1; }

/* SPECS TABLE */
.nfm-p-table { width: 100%; border-collapse: collapse; margin-top: 10px; }

.nfm-p-table tr:nth-child(even) td { background: var(--soft); }

.nfm-p-table td {
  padding: 11px 16px; font-size: 0.88rem; color: var(--body);
  border-bottom: 1px solid var(--line);
}

.nfm-p-table td:first-child {
  font-weight: 700; color: var(--navy); width: 42%;
  border-inline-end: 1px solid var(--line);
}

/* USES LIST */
.nfm-p-uses { display: flex; flex-direction: column; gap: 10px; margin-top: 10px; }

.nfm-p-use-item {
  display: flex; align-items: flex-start; gap: 12px;
  background: var(--soft); border: 1px solid var(--line);
  border-radius: 10px; padding: 12px 16px;
}

.nfm-p-use-icon {
  width: 32px; height: 32px; border-radius: 8px; flex-shrink: 0;
  background: linear-gradient(135deg, var(--wine), var(--wine-dark));
  display: flex; align-items: center; justify-content: center; font-size: 0.9rem;
}

.nfm-p-use-text h4 { font-size: 0.88rem; font-weight: 700; color: var(--navy); margin-bottom: 2px; }

.nfm-p-use-text p { font-size: 0.8rem; color: var(--muted); line-height: 1.7; }

/* SIDEBAR */
.nfm-p-sidebar {}

.nfm-p-card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: 16px; overflow: hidden;
  box-shadow: 0 4px 20px rgba(57,54,78,0.07);
  margin-bottom: 20px;
}

.nfm-p-card-head {
  background: linear-gradient(135deg, var(--navy), #2a2839);
  padding: 16px 20px;
  display: flex; align-items: center; gap: 10px;
}

.nfm-p-card-head h3 { font-size: 0.95rem; font-weight: 700; color: #fff; }

.nfm-p-card-head-icon { font-size: 1.2rem; }

.nfm-p-card-body { padding: 20px; }

.nfm-p-chain { display: flex; flex-direction: column; }

.nfm-p-chain-item {
  display: flex; align-items: center; gap: 12px; padding: 10px 0;
  border-bottom: 1px solid var(--line); font-size: 0.85rem;
}

.nfm-p-chain-item:last-child { border-bottom: none; }

.nfm-p-chain-num {
  width: 26px; height: 26px; border-radius: 50%; flex-shrink: 0;
  background: var(--wine-bg); border: 1.5px solid var(--wine);
  color: var(--wine); font-size: 0.75rem; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
}

.nfm-p-chain-item.active .nfm-p-chain-num {
  background: var(--wine); color: #fff;
}

.nfm-p-chain-name { color: var(--navy); font-weight: 600; }

.nfm-p-chain-item.active .nfm-p-chain-name { color: var(--wine); }

.nfm-p-chain-arrow { color: var(--muted); font-size: 0.75rem; margin-inline-start: auto; }

/* CTA */
.nfm-p-cta {
  background: linear-gradient(135deg, var(--wine), var(--wine-dark));
  border-radius: 14px; padding: 24px 20px; text-align: center;
  margin-bottom: 20px;
}

.nfm-p-cta p { color: rgba(255,255,255,0.8); font-size: 0.85rem; margin-bottom: 14px; line-height: 1.8; }

.nfm-p-cta a {
  display: block; background: var(--surface); color: var(--wine);
  font-weight: 800; font-size: 0.9rem; padding: 11px;
  border-radius: 10px; text-decoration: none;
  transition: opacity 0.2s;
}

.nfm-p-cta a:hover { opacity: 0.9; }

.nfm-p-info-row {
  display: flex; justify-content: space-between; align-items: center;
  padding: 9px 0; border-bottom: 1px solid var(--line);
  font-size: 0.83rem;
}

.nfm-p-info-row:last-child { border-bottom: none; }

.nfm-p-info-label { color: var(--muted); }

.nfm-p-info-val { font-weight: 700; color: var(--navy); }

.nfm-p-hero { position: relative; height: 320px; overflow: hidden; background: linear-gradient(135deg, #2a2839, #39364E); }

.nfm-p-body { max-width: 1060px; margin: 0 auto; padding: 50px 20px; }

.nfm-p-table { width: 100%; border-collapse: collapse; margin-top: 10px; }

/* PROCESS STEPS */
.nfm-p-steps { display: flex; flex-direction: column; gap: 0; margin-top: 10px; position: relative; }

.nfm-p-steps::before {
  content: ''; position: absolute; right: 15px; top: 0; bottom: 0;
  width: 2px; background: linear-gradient(to bottom, var(--wine), transparent);
}

.nfm-p-step { display: flex; gap: 16px; padding: 14px 0; }

.nfm-p-step-num {
  width: 32px; height: 32px; border-radius: 50%; flex-shrink: 0;
  background: var(--wine); color: #fff; font-size: 0.8rem; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
  position: relative; z-index: 1; box-shadow: 0 0 0 4px #fff;
}

.nfm-p-step-text h4 { font-size: 0.9rem; font-weight: 700; color: var(--navy); margin-bottom: 3px; }

.nfm-p-step-text p { font-size: 0.82rem; color: var(--muted); line-height: 1.7; }

.nfm-p-uses { display: flex; flex-direction: column; gap: 10px; margin-top: 10px; }

.nfm-p-sidebar {}

.nfm-p-cta {
  background: linear-gradient(135deg, var(--wine), var(--wine-dark));
  border-radius: 14px; padding: 24px 20px; text-align: center; margin-bottom: 20px;
}

/* TABLE */
.nfm-p-table { width: 100%; border-collapse: collapse; margin-top: 10px; }

/* TYPES GRID */
.nfm-p-types { display: grid; grid-template-columns: repeat(3,1fr); gap: 14px; margin-top: 10px; }

@media(max-width:600px){ .nfm-p-types { grid-template-columns: 1fr; } }

.nfm-p-type-card {
  border: 1px solid var(--line); border-top: 3px solid var(--wine);
  border-radius: 12px; padding: 22px 18px; background: var(--soft);
}

.nfm-p-type-card h4 { font-size: 0.95rem; font-weight: 800; color: var(--navy); margin-bottom: 8px; }

.nfm-p-type-card p { font-size: 0.82rem; color: var(--muted); line-height: 1.8; }

/* STEPS */
.nfm-p-steps { display: flex; flex-direction: column; gap: 0; margin-top: 10px; position: relative; }

/* ADVANTAGES */
.nfm-p-advs { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 10px; }

@media(max-width:600px){ .nfm-p-advs { grid-template-columns: 1fr; } }

.nfm-p-adv {
  display: flex; gap: 12px; align-items: flex-start;
  background: var(--soft); border: 1px solid var(--line);
  border-radius: 10px; padding: 14px;
}

.nfm-p-adv-icon {
  width: 30px; height: 30px; border-radius: 8px; flex-shrink: 0;
  background: linear-gradient(135deg, var(--wine), var(--wine-dark));
  display: flex; align-items: center; justify-content: center; font-size: 0.85rem;
}

.nfm-p-adv h4 { font-size: 0.82rem; font-weight: 700; color: var(--navy); margin-bottom: 2px; }

.nfm-p-adv p { font-size: 0.77rem; color: var(--muted); line-height: 1.6; }

/* SIDEBAR */
.nfm-p-card { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; box-shadow: 0 4px 20px rgba(57,54,78,0.07); margin-bottom: 20px; }

@media(max-width:600px){ .nfm-p-types2 { grid-template-columns: 1fr; } }

.nfm-p-type-card table { width: 100%; margin-top: 12px; border-collapse: collapse; }

.nfm-p-type-card table td { font-size: 0.78rem; padding: 6px 10px; border-bottom: 1px solid var(--line); color: var(--body); }

.nfm-p-type-card table td:first-child { font-weight: 700; color: var(--navy); width: 45%; }

.nfm-p-type-card table tr:last-child td { border-bottom: none; }

.nfm-p-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 20px; }

.nfm-p-stat-box {
  background: linear-gradient(135deg, var(--wine-bg), #fff);
  border: 1px solid rgba(130,45,76,0.2);
  border-radius: 12px; padding: 16px 12px; text-align: center;
}

.nfm-p-stat-box .num { font-size: 1.6rem; font-weight: 900; color: var(--wine); display: block; }

.nfm-p-stat-box .lbl { font-size: 0.72rem; color: var(--muted); margin-top: 2px; }

.nfm-iran-badge {
  background: linear-gradient(135deg, #1a3a1a, #2a5a2a);
  border-radius: 12px; padding: 16px 20px;
  display: flex; align-items: center; gap: 14px; margin-top: 20px;
}

.nfm-iran-badge .flag { font-size: 2rem; flex-shrink: 0; }

.nfm-iran-badge h4 { color: #fff; font-size: 0.85rem; font-weight: 700; margin-bottom: 3px; }

.nfm-iran-badge p { color: rgba(255,255,255,0.7); font-size: 0.78rem; line-height: 1.6; }

/* COMPARE TABLE */
.nfm-p-compare { width: 100%; border-collapse: collapse; margin-top: 10px; }

.nfm-p-compare th {
  background: var(--navy); color: #fff; padding: 12px 16px;
  font-size: 0.85rem; font-weight: 700; text-align: start;
}

.nfm-p-compare th:first-child { border-radius: 0 8px 0 0; }

.nfm-p-compare th:last-child { border-radius: 8px 0 0 0; }

.nfm-p-compare td { padding: 11px 16px; font-size: 0.83rem; color: var(--body); border-bottom: 1px solid var(--line); vertical-align: middle; }

.nfm-p-compare tr:nth-child(even) td { background: var(--soft); }

.nfm-p-compare td:first-child { font-weight: 700; color: var(--navy); }

.nfm-p-compare .win { color: #2a7a40; font-weight: 700; }

.nfm-p-compare .neutral { color: var(--muted); }

/* TYPES */
.nfm-p-types3 { display: grid; grid-template-columns: repeat(3,1fr); gap: 14px; margin-top: 10px; }

@media(max-width:600px){ .nfm-p-types3 { grid-template-columns: 1fr; } }

/* USES */
.nfm-p-uses { display: flex; flex-direction: column; gap: 10px; margin-top: 10px; }

/* STAT BOXES */
.nfm-p-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 20px; }

/* IRAN BADGE */
.nfm-iran-badge {
  background: linear-gradient(135deg, #1a3a1a, #2a5a2a);
  border-radius: 12px; padding: 16px 20px;
  display: flex; align-items: center; gap: 14px;
  margin-top: 20px;
}

/* grid widths driven by ProductSection.columns */
.nfm-cols-2 { grid-template-columns: repeat(2, 1fr); }

.nfm-cols-3 { grid-template-columns: repeat(3, 1fr); }

.nfm-cols-4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 700px) {
  .nfm-cols-2, .nfm-cols-3, .nfm-cols-4 { grid-template-columns: 1fr; }
}

.nfm-p-stat-box b { display: block; font-size: 1.25rem; font-weight: 900; color: var(--wine); }

.nfm-p-stat-box span { display: block; font-size: .75rem; color: var(--muted); }

.nfm-iran-badge b { display: block; margin-bottom: 6px; color: var(--navy); }

.nfm-iran-badge span { font-size: .84rem; color: var(--muted); line-height: 1.9; }
