/* ============================================================
   OFICINA VIRTUAL (page-oficina-virtual.php) — mobile first
   ============================================================ */

/* ── Tarjetas de trámites ── */
.ov-card {
  background: white; border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm); border: 1.5px solid var(--gray-200);
  transition: border-color 0.2s;
}
.ov-card:hover { border-color: var(--blue); }
.ov-card-head { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; }
.ov-icon {
  width: 48px; height: 48px; border-radius: 14px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center; font-size: 20px;
}
.ov-card-title { font-weight: 800; font-size: 17px; margin-bottom: 2px; line-height: 1.3; }
.ov-card-sub { font-size: 13px; color: var(--gray-500); }
.ov-card-text { font-size: 14px; color: var(--gray-600); line-height: 1.75; }
.ov-docs { background: var(--gray-50); border-radius: 14px; padding: 16px; margin-bottom: 20px; }
.ov-docs-title { font-size: 11px; font-weight: 700; color: var(--gray-500); text-transform: uppercase; letter-spacing: 1.2px; margin-bottom: 12px; }
.ov-doc { display: flex; align-items: flex-start; gap: 8px; font-size: 13px; color: var(--gray-600); margin-bottom: 6px; }
.ov-doc span { color: var(--blue); font-weight: 700; }
.ov-btn-ghost {
  display: inline-flex; align-items: center; justify-content: center; min-height: 44px;
  background: var(--gray-100); color: var(--black);
  padding: 12px 24px; border-radius: 22px; font-size: 14px; font-weight: 700; text-decoration: none;
}
.ov-btn-ghost:hover { background: var(--gray-200); }

/* ── Área de familias y descargas ── */
.ov-h3 { font-size: 22px; font-weight: 800; letter-spacing: -0.6px; margin-bottom: 20px; line-height: 1.2; }
.ov-list { display: flex; flex-direction: column; }

.ov-row {
  background: var(--gray-50); border-radius: var(--radius-md);
  padding: 14px 16px; display: flex; align-items: center; gap: 14px;
  text-decoration: none; color: inherit; min-height: 64px;
  transition: background 0.2s;
}
.ov-row:hover { background: var(--gray-100); }
.ov-row-icon {
  width: 44px; height: 44px; flex-shrink: 0; border-radius: 12px;
  background: rgba(192,17,43,0.08);
  display: flex; align-items: center; justify-content: center; font-size: 20px;
}
.ov-row-body { flex: 1; min-width: 0; }
.ov-row-title { font-weight: 700; margin-bottom: 2px; line-height: 1.35; }
.ov-row-sub { font-size: 13px; color: var(--gray-500); }
.ov-row-cta { color: var(--blue); font-size: 13px; font-weight: 700; white-space: nowrap; }

.ov-dl {
  background: var(--gray-50); border-radius: var(--radius-md);
  padding: 12px 14px; display: flex; align-items: center; gap: 12px;
}
.ov-dl-icon { font-size: 22px; flex-shrink: 0; }
.ov-dl-body { flex: 1; min-width: 0; }
.ov-dl-title { font-weight: 700; font-size: 14px; line-height: 1.35; }
.ov-dl-meta { font-size: 12px; color: var(--gray-500); }
.ov-dl-btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 40px;
  background: var(--blue); color: white; padding: 8px 14px; border-radius: 20px;
  font-size: 13px; font-weight: 700; text-decoration: none; white-space: nowrap; flex-shrink: 0;
}
.ov-dl-btn:hover { background: var(--pink); }

@media (min-width: 768px) {
  .ov-card { border-radius: var(--radius-lg); }
  .ov-card-head { gap: 16px; margin-bottom: 20px; }
  .ov-icon { width: 52px; height: 52px; font-size: 22px; }
  .ov-card-title { font-size: 18px; }
  .ov-docs { padding: 18px; }
  .ov-h3 { font-size: 26px; letter-spacing: -0.8px; margin-bottom: 28px; }
  .ov-row { padding: 20px 24px; gap: 16px; }
  .ov-row-sub { color: var(--gray-400); }
  .ov-dl { padding: 18px 20px; }
  .ov-dl-title { font-size: 13px; line-height: 1.6; }
  .ov-row-title, .ov-card-title { line-height: 1.6; }
  .ov-dl-meta { font-size: 11px; color: var(--gray-400); }
  .ov-dl-btn { min-height: 0; padding: 7px 16px; font-size: 12px; }
}
@media (min-width: 1024px) {
  .ov-card-sub { color: var(--gray-400); }
}

/* Si uno de los dos bloques (Familias / Descargas) está oculto, el otro ocupa el ancho disponible */
.ov-zona .grid > :only-child { grid-column: 1 / -1; width: 100%; max-width: 760px; }

/* ── Botón sin enlace configurado ── */
.ov-btn-soon {
  display: inline-flex; align-items: center; justify-content: center; text-align: center;
  min-height: 44px; padding: 12px 20px; border-radius: 30px;
  background: var(--gray-100); color: var(--gray-500);
  font-size: 14px; font-weight: 600; cursor: not-allowed;
}

/* ── Fila sin contenido todavía ── */
.ov-row.is-soon { cursor: default; }
.ov-row.is-soon:hover { background: var(--gray-50); }
.ov-row-cta.is-soon { color: var(--gray-500); font-weight: 600; }

/* ── Comunicados: fila desplegable ── */
.ov-details > summary { list-style: none; cursor: pointer; }
.ov-details > summary::-webkit-details-marker { display: none; }
.ov-caret {
  display: inline-block; width: 7px; height: 7px; margin-left: 4px; vertical-align: 2px;
  border-right: 2px solid currentColor; border-bottom: 2px solid currentColor;
  transform: rotate(45deg); transition: transform .2s;
}
.ov-details[open] .ov-caret { transform: rotate(225deg); vertical-align: -1px; }
.ov-details[open] > summary { border-bottom-left-radius: 0; border-bottom-right-radius: 0; }

.ov-doclist {
  list-style: none; margin: 0; padding: 6px;
  background: white; border: 1px solid var(--gray-100); border-top: 0;
  border-radius: 0 0 var(--radius-md) var(--radius-md);
}
.ov-doclist a {
  display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; align-items: center;
  min-height: 48px; padding: 10px 12px; border-radius: 10px;
  color: var(--black); text-decoration: none;
}
.ov-doclist a:hover { background: var(--gray-50); }
.ov-doclist-date { grid-column: 1; font-size: 12px; color: var(--gray-500); }
.ov-doclist-title { grid-column: 1; font-size: 14px; font-weight: 600; line-height: 1.35; }
.ov-doclist-type { grid-column: 2; grid-row: 1 / span 2; color: var(--blue); font-size: 13px; font-weight: 700; white-space: nowrap; }
.ov-doclist li + li { border-top: 1px solid var(--gray-100); }
@media (min-width: 768px) {
  .ov-doclist a { grid-template-columns: 96px 1fr auto; }
  .ov-doclist-date, .ov-doclist-title { grid-column: auto; }
  .ov-doclist-type { grid-column: auto; grid-row: auto; }
}

.ov-empty { color: var(--gray-500); font-size: 14px; }
