/* ═══════════════════════════════════════════════════════════════
   PORTAL VIAS3D — content.css
   Estilos para fragmentos de contenido cargados via fetch()
   Este archivo es el "contrato" visual que deben respetar
   los HTMLs entregados por el equipo de Soporte.
   v1.0 · Junio 2026
═══════════════════════════════════════════════════════════════ */

/* ── Área de contenido (contenedor del fetch) ─────────────────── */
.content-area {
  flex: 1;
  overflow-y: auto;
  background: var(--bg-light);
  height: calc(100vh - var(--topbar-h));
}

/* ── Wrapper interno del fragmento cargado ────────────────────── */
.content-wrap {
  max-width: 860px;
  margin: 0 auto;
  padding: 32px 36px 60px;
  animation: fadeIn .2s ease;
}

/* ── Encabezado de página ─────────────────────────────────────── */
.pg-eyebrow {
  display: flex; align-items: center; gap: 6px;
  font-size: 10px; font-weight: 700; letter-spacing: .1em;
  text-transform: uppercase; color: var(--tx-muted);
  margin-bottom: 10px;
}
.pg-eyebrow .dot { width: 4px; height: 4px; border-radius: 50%; background: var(--orange); }

.pg-title {
  font-size: clamp(20px, 2.5vw, 28px);
  font-weight: 800;
  letter-spacing: -.025em;
  line-height: 1.15;
  color: var(--tx-dark);
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 8px;
}
.pg-title::before {
  content: '';
  width: 4px; height: 28px; flex-shrink: 0;
  background: var(--gradient); border-radius: 2px;
}

.pg-subtitle {
  font-size: 14px; color: var(--tx-muted);
  line-height: 1.7; max-width: 60ch;
  padding-left: 16px; margin-bottom: 28px;
}

/* ── Sección de contenido base (card) ────────────────────────── */
.content-card {
  background: var(--surface);
  border: 1px solid var(--border-light);
  border-radius: var(--r-l);
  padding: 22px 24px;
  margin-bottom: 14px;
  box-shadow: var(--shadow-s);
}
.content-card h2 {
  font-size: 16px; font-weight: 800;
  color: var(--tx-dark); margin-bottom: 8px;
  display: flex; align-items: center; gap: 9px;
  letter-spacing: -.01em;
}
.content-card h2::before {
  content: ''; width: 3px; height: 18px; flex-shrink: 0;
  background: var(--gradient); border-radius: 2px;
}
.content-card h3 {
  font-size: 14px; font-weight: 700;
  color: var(--tx-dark); margin-bottom: 6px; margin-top: 16px;
}
.content-card p {
  font-size: 13px; color: var(--tx-mid);
  line-height: 1.75; margin-bottom: 8px;
}
.content-card ul, .content-card ol {
  margin: 8px 0 8px 4px;
}
.content-card li {
  font-size: 13px; color: var(--tx-mid);
  line-height: 1.65; padding: 3px 0;
  display: flex; align-items: flex-start; gap: 9px;
}
.content-card ul li::before {
  content: '';
  flex-shrink: 0; width: 16px; height: 16px; margin-top: 3px;
  border-radius: 4px;
  background: var(--orange-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath fill='%23ed8020' d='M6.5 11.5L3 8l1-1 2.5 2.5 5-5 1 1z'/%3E%3C/svg%3E") no-repeat center / 10px;
  border: 1px solid var(--orange-border);
}
.content-card ol { counter-reset: item; }
.content-card ol li::before {
  counter-increment: item;
  content: counter(item);
  flex-shrink: 0; width: 20px; height: 20px; margin-top: 1px;
  border-radius: 50%; background: var(--orange);
  color: #fff; font-size: 10px; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
}

/* ── Pasos numerados (guías técnicas) ─────────────────────────── */
.step-list { display: flex; flex-direction: column; gap: 14px; margin: 12px 0; }
.step {
  display: flex; gap: 14px; align-items: flex-start;
}
.step-num {
  width: 30px; height: 30px; border-radius: 50%;
  background: var(--orange); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 800; flex-shrink: 0; margin-top: 1px;
}
.step-body h4 { font-size: 13px; font-weight: 700; color: var(--tx-dark); margin-bottom: 4px; }
.step-body p  { font-size: 13px; color: var(--tx-mid); line-height: 1.65; }

/* ── Nota / Alerta ────────────────────────────────────────────── */
.note {
  display: flex; gap: 10px; align-items: flex-start;
  padding: 12px 14px; border-radius: var(--r-s);
  font-size: 12px; line-height: 1.65; margin: 12px 0;
}
.note .mi { font-size: 16px; flex-shrink: 0; margin-top: 1px; }
.note-info    { background: #eff6ff; border-left: 3px solid #3b82f6; color: #1e3a5f; }
.note-info .mi { color: #3b82f6; }
.note-warning { background: var(--amber-bg); border-left: 3px solid #f59e0b; color: var(--amber); }
.note-warning .mi { color: #f59e0b; }
.note-success { background: var(--green-bg); border-left: 3px solid #22c55e; color: var(--green); }
.note-success .mi { color: #22c55e; }
.note-orange  { background: var(--orange-soft); border-left: 3px solid var(--orange); color: var(--tx-dark); }
.note-orange .mi { color: var(--orange); }

/* ── Tabla ────────────────────────────────────────────────────── */
.content-table { width: 100%; border-collapse: collapse; margin: 12px 0; }
.content-table th {
  background: var(--surface2); padding: 9px 13px;
  text-align: left; font-size: 11px; font-weight: 700;
  color: var(--tx-muted); text-transform: uppercase;
  letter-spacing: .05em; border-bottom: 1px solid var(--border-mid);
}
.content-table td {
  padding: 9px 13px; font-size: 12px; color: var(--tx-dark);
  border-bottom: 1px solid var(--border-light);
}
.content-table tr:last-child td { border-bottom: none; }
.content-table tr:hover td { background: var(--surface2); }

/* ── Código inline ────────────────────────────────────────────── */
code {
  font-family: 'Courier New', monospace;
  font-size: 11px;
  background: var(--surface3);
  padding: 2px 6px; border-radius: 4px;
  border: 1px solid var(--border-mid);
  color: var(--tx-dark);
}
pre {
  background: var(--bg-dark2);
  border-radius: var(--r-m);
  padding: 16px 18px; margin: 12px 0;
  overflow-x: auto;
}
pre code {
  background: none; border: none; padding: 0;
  font-size: 12px; color: #e2e8f0;
  line-height: 1.7;
}

/* ── Imágenes de contenido ────────────────────────────────────── */
.content-img {
  width: 100%; border-radius: var(--r-m);
  border: 1px solid var(--border-light);
  margin: 12px 0;
  box-shadow: var(--shadow-s);
}
.content-img-caption {
  font-size: 11px; color: var(--tx-muted);
  text-align: center; margin-top: -6px; margin-bottom: 12px;
  font-style: italic;
}

/* ── Botones de acción en contenido ───────────────────────────── */
.content-actions {
  display: flex; gap: 10px; flex-wrap: wrap; margin-top: 16px;
}

/* ── Recursos descargables ────────────────────────────────────── */
.resource-card {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px; border-radius: var(--r-m);
  border: 1px solid var(--border-light);
  background: var(--surface);
  cursor: pointer; transition: all var(--t); margin-bottom: 8px;
}
.resource-card:hover { border-color: rgba(237,128,32,.3); background: rgba(237,128,32,.03); }
.resource-icon {
  width: 38px; height: 38px; border-radius: 9px;
  background: #fce4d6; color: #c0392b;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; flex-shrink: 0;
}
.resource-info h4 { font-size: 12px; font-weight: 700; color: var(--tx-dark); margin-bottom: 2px; }
.resource-info p  { font-size: 11px; color: var(--tx-muted); }
.resource-action  { margin-left: auto; color: var(--tx-muted); transition: color var(--t); }
.resource-card:hover .resource-action { color: var(--orange); }

/* ── Placeholder (sección en construcción) ────────────────────── */
.section-placeholder {
  display: flex; flex-direction: column; align-items: center;
  text-align: center; gap: 14px;
  padding: 48px 24px;
  background: var(--surface);
  border: 1px dashed rgba(237,128,32,.25);
  border-radius: var(--r-l);
  margin-top: 8px;
}
.ph-icon {
  width: 58px; height: 58px; border-radius: 14px;
  background: var(--orange-soft); border: 1px solid var(--orange-border);
  display: flex; align-items: center; justify-content: center;
}
.ph-icon .mi { font-size: 26px; color: var(--orange); }
.ph-tag {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 12px; border-radius: 20px;
  background: var(--orange-soft); border: 1px solid var(--orange-border);
  font-size: 10px; font-weight: 700; color: var(--orange);
  letter-spacing: .05em;
}
.ph-title { font-size: 15px; font-weight: 700; color: var(--tx-dark); }
.ph-desc  { font-size: 12px; color: var(--tx-muted); max-width: 38ch; line-height: 1.65; }

/* ── Responsive contenido ─────────────────────────────────────── */
@media (max-width: 768px) {
  .content-wrap { padding: 20px 16px 40px; }
  .pg-title { font-size: 20px; }
}
